Skip to content

error: (-215:Assertion failed) inputs.size() in function 'getMemoryShapes' #19

Description

@HerrAskinSM

Hello! I'm trying to run the code for c++ ./yolo_example code with yolov5s.onnx, which was converted
by the python command
export.py --weights yolov5s.pt --include onnx.
I get an error

[ERROR:0@0.054] global /home/sergey/opencv/modules/dnn/src/onnx/onnx_importer.cpp (906) handleNode DNN/ONNX: ERROR during processing node with 1 inputs and 1 outputs: [Identity]:(onnx::Reshape_475) from domain='ai.onnx'
terminate called after throwing an instance of 'cv::Exception'
what(): OpenCV(4.5.5) /home/sergey/opencv/modules/dnn/src/onnx/onnx_importer.cpp:928: error: (-2:Unspecified error) in function 'handleNode'
Node [Identity@ai.onnx]:(onnx::Reshape_475) parse error: OpenCV(4.5.5) /home/sergey/opencv/modules/dnn/src/dnn.cpp:6017: error: (-215:Assertion failed) inputs.size() in function 'getMemoryShapes'
Aborted (core dumped)

P.S. but the native yolov5.onnx works fine.

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions