FindExtrinsicParams2 freezes on certain input (Bug #304)


Added by Rosen Diankov almost 15 years ago. Updated almost 15 years ago.


Status:Done Start date:
Priority:High Due date:
Assignee:Vadim Pisarevsky % Done:

0%

Category:imgproc, video
Target version:-
Affected version: Operating System:
Difficulty: HW Platform:
Pull request:

Description

in the newest opencv, i get this error often when calling cv.FindExtrinsicCameraParams2 from python:
  • On entry to DLASCL, parameter number 4 had an illegal value

The input is

objectPoints:

 0.0328927   0.06368747  0. 
0.00922698  0.0687118   0.
0.00922698  0.0687118   0.
0.00922698  0.0687118   0.

imagePoints =

-0.09685596 -0.01165635
-0.45950995 -0.32760567
-0.48671867 -0.31602137
-0.45217826 -0.33057223

cameraMatrix = identity
distCoeffs - zeros

from simple inspection, it seems that the function cannot handle object points that are collinear. so my question is, does this check belong inside the function, or should the user be doing it before the function call? If so, how can i quickly check if a set of 3d points are collinear (basically 2 or more eigen values of the covariance zero 0)


Associated revisions

Revision 101e9bd4
Added by Andrey Kamaev about 12 years ago

Merge pull request #304 from apavlenko:test_java_fix_double

History

Updated by Rosen Diankov almost 15 years ago

I just want to say that by adding a check on the eigenvalues of the coviariance matrix before calling the function, things stopped freezing for me

Updated by James Bowman almost 15 years ago

Does not seem Python specific. Passing to Vadim for comment.

Updated by Vadim Pisarevsky almost 15 years ago

Thanks! The sample runs fine since r3148, where the problem seems to be fixed

  • Status set to Done
  • (deleted custom field) set to fixed

Also available in: Atom PDF