Python Version: 3.7
OpenCV Version: 4.1.1 / 3.4.X
Mobile Phone: Asus Zenfone Max Pro M1
Initial Setup
Dictionary used : cv2.aruco.DICT_ARUCO_ORIGINAL
.
Aruco Parameters [Edit 9th Dec, 19]:
parameters = cv2.aruco_DetectorParameters.create()
parameters.cornerRefinementMaxIterations = 80
parameters.cornerRefinementMethod = 1
parameters.polygonalApproxAccuracyRate = 0.05
parameters.cornerRefinementWinSize = 20
parameters.cornerRefinementMinAccuracy = 0.05
parameters.perspectiveRemovePixelPerCell = 8
parameters.maxErroneousBitsInBorderRate = 0.04
parameters.errorCorrectionRate = 0.2
parameters.adaptiveThreshWinSizeStep= 3
parameters.adaptiveThreshWinSizeMax= 23
The red marks show rejected points, while the green marks show the corner points.
Screenshot of aruco detection on image. No corners were detected in this case but lots of rejected points.
Case 1: Effects of Cropping
Cropped Image: 200 to 1574 on Y-axis and 883 to 2633 on X-axis. I cropped it using OpenCV so that there is no loss.
There were some instances where it detected the corner points and some instances where it captured more noise than before.
- What I don't understand is, why do the rejected points change?
Screenshot of aruco detection on cropped image. In this case, there are more rejected points than before.
Case 2: Effects of Smoothing
I used Median Blur of 11x11 kernel on this image. The false detection was low and the marker was detected perfectly.
Initially I assumed that it was due to the noise removal in image after applying Median Blur, but the results did not improve by gradually increasing/decreasing the kernel size. For e.x: for one image, corners got detected using 9x9 filter but not using 5x5, 7x7, 11x11, 15x15. On another image, it might work using 11x11.
- Why does it behave that way?
Screenshot of aruco detection after noise removal, zoomed for convenience.
I can't post the original image here since it is more than 2MB.