Thanks to visit codestin.com
Credit goes to github.com

Skip to content

Conversation

smeng9
Copy link
Contributor

@smeng9 smeng9 commented Apr 15, 2023

Pull Request Readiness Checklist

Hi @AleksandrPanov the aruco module is using the wrong variable to check whether it should perform corner refinement.

The previous buggy version of code since opencv 4.7 is using the candidates supplied in the function argument from user instead of the candidates returned from _identifyCandidates.

Our current workaround is always to run the detectMarkers twice, so the second time will use the ids returned from the first run, however that workaround is not optimal and greatly hurt the performance.

Could you please take a look and get this merged? Thanks!

See details at https://github.com/opencv/opencv/wiki/How_to_contribute#making-a-good-pull-request

  • I agree to contribute to the project under Apache 2 License.
  • To the best of my knowledge, the proposed patch is not based on a code under GPL or another license that is incompatible with OpenCV
  • The PR is proposed to the proper branch
  • There is a reference to the original bug report and related work objdetect aruco module CORNER_REFINE_CONTOUR has no effect (regression in opencv 4.7) #23437
  • There is accuracy test, performance test and test data in opencv_extra repository, if applicable
    Patch to opencv_extra has the same branch name.
  • The feature is well documented and sample code can be built with the project CMake

@asmorkalov
Copy link
Contributor

@smeng9 Thanks a lot for the issue debugging and contribution! Could you add small test for the issue or tune some existing?

@asmorkalov asmorkalov added this to the 4.8.0 milestone Apr 15, 2023
@asmorkalov asmorkalov added bug pr: needs test New functionality requires minimal tests set labels Apr 15, 2023
@AleksandrPanov
Copy link
Contributor

AleksandrPanov commented Apr 19, 2023

The fix works.

Copy link
Contributor

@AleksandrPanov AleksandrPanov left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I checked the PR, the fix works. It is difficult to add a good test, I suggest to merge it.

@asmorkalov asmorkalov removed the pr: needs test New functionality requires minimal tests set label Apr 20, 2023
@asmorkalov asmorkalov merged commit 3113b49 into opencv:4.x Apr 20, 2023
@asmorkalov asmorkalov mentioned this pull request May 31, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants