Ask Your Question

Revision history [back]

click to hide/show revision 1
initial version

Bug? opencv_test_imgproc fails, wrong path to test file

OpenCV 3.x opencv_test_imgproc fails, because some OpenCL tests try to open nonexistent files (eg. "gpu/opticalflow/rubberwhale1.png"). The files are actually in "sources/samples/data" directory. So it seems the paths in the source has not been updated. Affects at least 3.0 and 3.2.

Before I open a bug, I want to check if there is some other cause... like I missed some file copying step in building and testing, or maybe I am building old (deprecated) tests somehow. The source files concerned are:

C:\OpenCV3.2.0\sources\modules\imgproc\perf\opencl\perf_gftt.cpp(60): ::testing::Combine(OCL_PERF_ENUM(String("gpu/opticalflow/rubberwhale1.png")),

C:\OpenCV3.2.0\sources\modules\video\perf\opencl\perf_optflow_farneback.cpp(74): Mat frame0 = imread(getDataPath("gpu/opticalflow/rubberwhale1.png"), cv::IMREAD_GRAYSCALE);

C:\OpenCV3.2.0\sources\modules\video\perf\opencl\perf_optflow_farneback.cpp(77): Mat frame1 = imread(getDataPath("gpu/opticalflow/rubberwhale2.png"), cv::IMREAD_GRAYSCALE);

C:\OpenCV3.2.0\sources\modules\video\perf\opencl\perf_optflow_pyrlk.cpp(64): Mat frame0 = imread(getDataPath("gpu/opticalflow/rubberwhale1.png"), cv::IMREAD_GRAYSCALE);

C:\OpenCV3.2.0\sources\modules\video\perf\opencl\perf_optflow_pyrlk.cpp(67): Mat frame1 = imread(getDataPath("gpu/opticalflow/rubberwhale2.png"), cv::IMREAD_GRAYSCALE);

C:\OpenCV3.2.0\sources\modules\imgproc\test\ocl\test_gftt.cpp(74): Mat frame = readImage("../gpu/opticalflow/rubberwhale1.png", IMREAD_GRAYSCALE);

C:\OpenCV3.2.0\sources\modules\imgproc\test\ocl\test_gftt.cpp(75): ASSERT_FALSE(frame.empty()) << "could not load gpu/opticalflow/rubberwhale1.png";

Netsai