Is cuda::detectMultiScale method thread safe for Cuda?
Hi, I tried sample with threads for CPU all ok, for Cuda I had Assertion:
OpenCV Error: Gpu API call (NCV Assertion Failed: cudaError_t=4, file=/Users/User/Documents/Dev/OpenCV/modules/cudalegacy/src/cuda/NCVHaarObjectDetection.cu, line=1313) in NCVDebugOutputHandler, file /Users/User/Documents/Dev/OpenCV/modules/cudaobjdetect/src/cascadeclassifier.cpp, line 156
If run only one thread for Cuda all ok.
I saw the same problem: https://github.com/opencv/opencv/issu...
but it was in 2015 (
You can see my sample here link text.
Platform: MacOsX OpenCV 3.2.0-dev Cuda: 8.0.61
Other strange situation when I tried use Stream for method cuda::detectMultiScale but I can't use in method I found line CV_Assert( !stream );
I hope it helps : read this issue and this one too
Thanks, but I can't use Stream I wrote in the end question but I didn't try remove line CV_Assert( !stream ); May be it is not right change source OpenCV but I will thinking about it.
right or not try it if it works write an issue
If I comment line with assert I see the same above assert:
OpenCV Error: Gpu API call (NCV Assertion Failed: cudaError_t=4, file=/Users/User/Documents/Dev/OpenCV/modules/cudalegacy/src/cuda/NCVHaarObjectDetection.cu, line=1313) in NCVDebugOutputHandler, file /Users/User/Documents/Dev/OpenCV/modules/cudaobjdetect/src/cascadeclassifier.cpp, line 156
Seems with streams and without detectMultiScale doesn't thread safe (