MrIsland / Thesis_Reproduction1

<Accurate Camera Calibration using Iterative Refinement of Control Points>
10 stars 3 forks source link

about “find4QuadCornerSubpix” used in opencv_circle pattern #1

Closed saiwing closed 3 months ago

saiwing commented 4 months ago

In opencv_circle_iterative.cpp, findCirclesGrid() followed by find4QuadCornerSubpix I think "find4QuadCornerSubpix" is used to refine chessboard corner, but not circle pattern. I don't know if I am right. If I comment "find4QuadCornerSubpix", iteration doesn't seem to improve reprojection error

MrIsland commented 3 months ago

Thank you very much for your question, and I apologize for not seeing your inquiry sooner due to my busy schedule. This was indeed an oversight on my part. The find4QuadCornerSubpix() function in OpenCV optimizes corner detection based on image gradients, which is ineffective for circle patterns. This is because the area around the circle center has the same color, resulting in a gradient of zero. So you are right.

By the way, if you want to achieve lower reprojection error, you can use a circular pattern or markers(like CCTAG), which is a part of this repo that was not yet completed. Additionally, you can choose a state-of-the-art ellipse detection algorithm. Removing erroneous corner points when projecting the bird's-eye view can also effectively improve calibration accuracy, as outliers significantly affect the calibration algorithms in OpenCV.