I want to run yolov5 with opencv dnn in C++, for this, I have converted PyTorch model to onnx, from this link But that onnx is not working with opencv dnn module. Anyhelp would be appreciated.
whch opencv version did you try ?
what are the errors ?
it seems, opencv’s dnn module still needs some fixes or this
I have build opencv from source with cuda for fast processing.
Version
OPENCV : 4.5.3
CUDA : 11.4
I converted yolov5.pt file to onnx from this link
I have read onnx file with module readNetFromONNX
C++ code compiled successfully but when inferencing, it throw error.
Error:
terminate called after throwing an instance of ‘cv::Exception’
(-215:Assertion failed) 0 in function ‘operator()’