You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I checked the ONNX using Pythin and onnx, as well as onnxruntime. Both claim that the model is OK. OpenCV, however, reports:
[ERROR:0@0.104] global D:\a\opencv-python\opencv-python\opencv\modules\dnn\src\onnx\onnx_importer.cpp (1044) cv::dnn::dnn5_v20220821::ONNXImporter::handleNode DNN/ONNX: ERROR during processing node with 3 inputs and 1 outputs: [Where]:(onnx_node!Where_46) from domain='ai.onnx'
Traceback (most recent call last):
File "d:\Local\devel\Python\OpenCV\image_classification_rexnet_lite\inference.py", line 94, in <module>
model = cv2.dnn.readNet(model_path)
cv2.error: OpenCV(5.0.0-pre) D:\a\opencv-python\opencv-python\opencv\modules\dnn\src\onnx\onnx_importer.cpp:1063: error: (-2:Unspecified error) in function 'cv::dnn::dnn5_v20220821::ONNXImporter::handleNode'
> Node [Where@ai.onnx]:(onnx_node!Where_46) parse error: OpenCV(5.0.0-pre) d:\a\opencv-python\opencv-python\opencv\modules\dnn\src\layer_internals.hpp:110: error: (-2:Unspecified error) Can't create layer "onnx_node!Where_46" of type "Where" in function 'cv::dnn::dnn5_v20220821::detail::LayerData::getLayerInstance'>
Steps to reproduce
model = cv2.dnn.readNet(model_path)
Reproducible: yes
Enforceable: yes
Issue submission checklist
I report the issue, it's not a question
I checked the problem with documentation, FAQ, open issues,
I updated to the latest OpenCV version and the issue is still there
There is reproducer code and related data files: videos, images, onnx, etc
The text was updated successfully, but these errors were encountered:
I can see this model still have some operators not supported in the current version of OpenCV DNN, such as ScatterND. There is a pull request working on the support of ScatterND.
Confirmed with opencv-python-rolling 5.0.0.20220903 and a version of the model that I simplified myself. I am left with not supported ScatterND.
The PR for supporting ScatterND has been merged. Please have a try with latest OpenCV. You need to either compile OpenCV from source for now, or wait for the release of opencv-python-rolling on this Saturday (20221022).
Detailed description
I converted a model to ONNX and tried to load it with OpenCV 5.6 Windows 10 (Python) and got the same error message. Find the model here:
https://drive.google.com/file/d/15wdXCiS1Yr7a4wFTUb7jQB_GjbkB_a-G/view?usp=sharing
Original model from here: https://github.com/clovaai/rexnet
I checked the ONNX using Pythin and onnx, as well as onnxruntime. Both claim that the model is OK. OpenCV, however, reports:
Steps to reproduce
model = cv2.dnn.readNet(model_path)
Issue submission checklist
I report the issue, it's not a question
I checked the problem with documentation, FAQ, open issues,
I updated to the latest OpenCV version and the issue is still there
There is reproducer code and related data files: videos, images, onnx, etc
The text was updated successfully, but these errors were encountered: