Ask Your Question

Revision history [back]

Parralel creation of cv::Mat crashes? Bug?

Hi there,

I'm using OpenCV 3.0rc1 and Windows 7 (Visual Studio 2010) My problem is that the following code crashes randomly when using OpenMP for parallization. If I remove the OpenMP loop parallelization everything works fine.

#pragma omp parallel for
for(int i = 0; i < 100; i++)
    cv::Mat blub;
    blub.create(3456, 5184, 16);
    cout << ".";

The following exception is thrown OpenCV Error: Assertion failed (u != 0) in cv::Mat::create, file src\matrix.cpp, line 412

Can anyone reproduce / confirm this behavior?