Error running inference on Single Shot Scale-invariant Face Detector pre trained model
Hi,
I'm trying to use the pre trained models from Single Shot Scale-invariant Face Detector.
I can load the network successfully but when I try to invoke net.forward
the following exception is being raised:
3.3.1:
OpenCV Error: Bad argument (PriorBox layer parameter does not contain flip parameter.) in getParameter, file /opt/opencv-3.3.1/modules/dnn/src/layers/prior_box_layer.cpp, line 87
terminate called after throwing an instance of 'cv::Exception'
what(): /opt/opencv-3.3.1/modules/dnn/src/layers/prior_box_layer.cpp:87: error: (-5) PriorBox layer parameter does not contain flip parameter. in function getParameter
Aborted (core dumped)
3.4.0-rc:
[ INFO:0] Initialize OpenCL runtime...
OpenCV Error: Assertion failed (!_aspectRatios.empty()) in PriorBoxLayerImpl, file /opt/opencv-3.4.0-rc/modules/dnn/src/layers/prior_box_layer.cpp, line 206
terminate called after throwing an instance of 'cv::Exception'
what(): /opt/opencv-3.4.0-rc/modules/dnn/src/layers/prior_box_layer.cpp:206: error: (-215) !_aspectRatios.empty() in function PriorBoxLayerImpl
Aborted (core dumped)
Any help is appreciated.
@fabito, try to remove this assertion.
Hi @dkurt, the good news is that I removed the assertion and it worked!! The bad news is that the
net.forward
is VERY slow: ~0.22 FPS. Maybe its because my OpenCV its not GPU/Cuda enabled. According to the paper it should run at 36 FPS on a Nvidia Titan X (Pascal) for VGA-resolution images@fabito@dkurt i have same error, may i know how assertion can be removed in this issue?
same problem, also tried with 3.4.1 build. error is
/io/opencv/modules/dnn/src/layers/prior_box_layer.cpp:207: error: (-215) !_aspectRatios.empty() in function PriorBoxLayerImpl
@0xFAFAFA, please try the latest version of OpenCV. The problem has been fixed a day ago by https://github.com/opencv/opencv/pull.... Thanks!