-
Notifications
You must be signed in to change notification settings - Fork 251
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
error: (-28:Unknown error code -28) The input arrays should have at least 4 corresponding point sets to calculate Homography in function 'findHomography' #299
Comments
The reason might be because that bug was fixed not long ago, but the fix is still not part of the latest release. Maybe try installing Norfair from the master branch:
Tell me if this fixes the issue. |
Thanks a lot, @aguscas ! Installing from master seemed to work. I do get the following warning though: Does this mean that transformation will be skipped for the frame in case of this issue but everything else will work fine? |
Everything should work fine. That means that the |
Makes sense! Closing this issue. Again, thanks so much for your help! |
If you want to avoid having that warning (so that you always estimate the transformation), you can also try setting the |
For now, it's not an issue for me but I'll experiment with those two parameters. Thanks a lot! |
Hi,
Would you know why I am getting this error? I see in the code here that you check for minimum 4 pairs of points before findHomography but still getting the error:
norfair/norfair/camera_motion.py
Line 220 in 009a1b1
File "/home/aagrawal/face_detection/real_videos/open_source_face_detection.py", line 232, in main
coord_transformation = motion_estimator.update(frame) #, mask)
File "/home/aagrawal/face_detection/face_venv/lib/python3.10/site-packages/norfair/camera_motion.py", line 396, in update
update_prvs, coord_transformations = self.transformations_getter(
File "/home/aagrawal/face_detection/face_venv/lib/python3.10/site-packages/norfair/camera_motion.py", line 216, in call
homography_matrix, points_used = cv2.findHomography(
cv2.error: OpenCV(4.9.0) /io/opencv/modules/calib3d/src/fundam.cpp:385: error: (-28:Unknown error code -28) The input arrays should have at least 4 corresponding point sets to calculate Homography in function 'findHomography'
The text was updated successfully, but these errors were encountered: