Can't load onnx model converted from pythorch model with opencv

Hi, I got the following error when I tried to read it with opencv (ort_session = cv2.dnn.readNetFromONNX("test.onnx") ):

File "", line 12, in <module> ort_session = cv2.dnn.readNetFromONNX("test.onnx") cv2.error: OpenCV(4.4.0) /tmp/pip-req-build-njn2fp78/opencv/modules/dnn/include/opencv2/dnn/shape_utils.hpp:222: error: (-215:Assertion failed) clamped.start < clamped.end in function 'clamp'

However, I can read it with python onnx module. How can I fix this problem? Thanks.

I fixed this problem by upgrading my opencv version.