OpenCV 2 or 1

SirVer sirver at gmx.de
Wed Nov 4 01:44:30 EST 2009


Hi,

currently the following test fails on my system:
test_opencv_cv.TestCalibrateCamera2.test_cvCalibrateCamera2_Identity ...
OpenCV ERROR: Bad argument (Distortion coefficients must be 4x1 or 1x4
floating-point matrix)
	in function cvCalibrateCamera2, cvcalibration.cpp(1350)

This is a bit ironic, since it is a test that I initially wrote.

The Problem is that the function cvCalibrateCamera2 now allocates an
distortion array of size 1x5 while before it allocated a distortion
array of 1x4. I guess that opencv2 uses 1x5 while opencv1 (the one i
currently use) uses 1x4.

The Problem (once again!) rises that we do not link against a
particular version of the opencv but instead to our very own
hotlinking when the lib is loaded. This leads to this obscure crash
without any feedback to the user. Thus, I vote again for autodetection
and proper linking against headers.

OR, if this is too much trouble at least deny loading OpenCV 1 at run
time, because we just can not be too sure what the problems are.

Another point: generated c files in the repository are constantly
comming up as changed or merge conflicts for me. What is the reason to
keep .c files in the repository; i think it is fair to assume that
python developers who have a c compiler installed will also have
cython installed to generate the .c files.

Holger




More information about the scikit-image mailing list