Add support for ArUco 7x7 tag family#1835
Merged
fspindle merged 1 commit intolagadic:masterfrom Nov 25, 2025
Merged
Conversation
Codecov Report❌ Patch coverage is
Additional details and impacted files@@ Coverage Diff @@
## master #1835 +/- ##
==========================================
- Coverage 47.93% 47.87% -0.06%
==========================================
Files 531 531
Lines 68822 68870 +48
Branches 32157 32169 +12
==========================================
- Hits 32988 32973 -15
+ Misses 31833 25399 -6434
- Partials 4001 10498 +6497 ☔ View full report in Codecov by Sentry. 🚀 New features to boost your workflow:
|
Contributor
|
@s-trinh Thanks. Very nice feature. |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
ArUco
7x7have bigger Hamming distance between two codes and the id decoding should be more reliable.Support for ArUco 4x4, 5x5 and 6x6 was much easier since we can use
tag16h5,tag25h7,tag36h11as a starting point.For ArUco
7x7support"bit-pattern"
First compute the correct "bit-pattern" for the considered family, see: tf->bit_x / tf->bit_y
With fiducial marker detection, it goes roughly as "quad_rectangle extraction" --> "perspective correction using estimated homography" --> "pattern decoding".
In OpenCV, one tag id is stored using 4 values to cover the 4 orientations: https://github.com/opencv/opencv/blob/3c3596c6efcabd0e5ee021e2048a30ec38a8d4e1/modules/objdetect/src/aruco/predefined_dictionaries.hpp#L21-L25
With the AprilTag library, some kind of bitwise operations are used to cover the 4 tag orientations, saving some memory at the cost of extra cpu work.
For a
5x5family, the previous image shows thetf->bit_x / tf->bit_yvalues to extract the tag pattern into a full codedata such that using bitwise operations it is possible to cover the 4 tag orientations. More information here.Codedata
Once the
tf->bit_x / tf->bit_yvalues are computed for a7x7family, correspondingcodedataneed to be filled, using: