Skip to content
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

create separate apriltag messages package with different information in message #141

Open
berndpfrommer opened this issue Dec 7, 2022 · 0 comments

Comments

@berndpfrommer
Copy link

Summary: please consider creating a separate apriltag_msgs package with core perception data.

This is good practice as it simplifies the dependency tree. Relevant links concerning this:
https://answers.ros.org/question/45916/building-only-ros-messages-or-services/
https://answers.ros.org/question/11835/when-should-i-split-my-code-into-multiple-packages-and-whats-a-good-way-to-split-it/

The current AprilTag detection message contains external information (like size) and derived information (like pose) that are not direct outputs of the core apriltag perception algorithms. Then on the other hand missing are corner detections (issue #130) and hamming distance (issue #102).

How about creating a separate stand-alone messages package that focuses solely on the core perception data? Although this runs somewhat slower in ROS2, a stamped array of non-primitive types would probably be the cleaner than field arrays.

Suggested fields for the non-primitive detection:

// ------- these come directly from apriltag library's detection_t
int32 id 
int hamming_distance
float64 decision_margin
float64[4][2] corner
float64[3][3]  homography // this is actually derived data, not perceived 
float64[2] center // probably also derived data
// ----- additional fields 
string tag_family
int32 bits  // how many bits the tag has (36h11 would have e.g. 6 bits. This field is somewhat redundant with tag_family)
int32 border   // width of black border (to support older detectors like the MIT detector used by Kalibr)

From what I understand the current ROS node in this package also does pose estimation. There are many people for whom this pose estimation is sufficient. But there are packages out there (like TagSLAM or MulticamCalibration) that do their own homography and pose estimation and thus don't need the tag poses. In fact virtually all camera calibration packages will be unhappy without the corner locations.

So far I've been using (and maintaining) Chao's Apriltag package package but it would be nice to have a ROS-wide package that provides the same primitive service, and produces messages that give full access to the output of the tag detector.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant