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

What is the fix matrix that you multiply with the pose? #270

Open
mehditlili opened this issue Dec 14, 2022 · 1 comment
Open

What is the fix matrix that you multiply with the pose? #270

mehditlili opened this issue Dec 14, 2022 · 1 comment

Comments

@mehditlili
Copy link

I am trying to understand the different elements of the code. However, I fail to see why you multiply by a matrix called fix when computing the tag pose. I have an intuition that it has something to do with the direction of the Z axis pointing away or to the camera but why can't that be directly estimated via the homography?

Here is the matrix in question
https://github.com/AprilRobotics/apriltag/blob/master/apriltag_pose.c#L463

Could one of the authors please elaborate on this or point to an article where they describe why this is necessary?

Thank you

@christian-rauch
Copy link
Collaborator

I did not write that code but your intuition is correct. That matrix is flipping the y- and z-axes so that the z-axis of the tag frame is pointing away from the tag surface towards the camera.

This is essentially also done in the ROS node by setting the objectPoints for cv::solvePnP accordingly. The relation of the 3D points (objectPoints) and the order of the corresponding 2D coordinates (imagePoints) of the detected tag define a coordinate system where z is also "flipped".

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

2 participants