Ask Your Question

Revision history [back]

click to hide/show revision 1
initial version

CascadeClassifier_GPU NCV Assertion Failed

Hello, I'm trying to use Haar cascade classifier on GPU

gpu::CascadeClassifier_GPU ccG;
if (ccG.load(cascadeFileName))
{
    printf("Loaded\n");
}
gpu::GpuMat imGPU, objsGPU;
imGPU.upload(im);
int detections_number = ccG.detectMultiScale(imGPU, objsGPU, 1.05, 0, cv::Size(32, 32));

CascadeClassifier_GPU loads from file, but I have an exception on detectMultiScale.

OpenCV Error: Gpu API call (NCV Assertion Failed: NcvStat=28, file=......\modules\gpu\src\cascadeclassifier.cpp, line=117) in unknown function, file ......\modules\gpu\src\cascadeclassifier.cpp, line 131

As I can understand 28 means NCV_WARNING_HAAR_DETECTIONS_VECTOR_OVERFLOW. Does it mean that I can't use my cascade file to run detection on GPU.

P.S. CPU CascadeDetector can do detectMultiScale.