GithubHelp home page GithubHelp logo

Comments (11)

mzucker avatar mzucker commented on May 13, 2024 2

I would recommend in the range of 10-20 images. You will not get good data with 2 or 3 images.

from apriltag.

mzucker avatar mzucker commented on May 13, 2024 1

Right, the problem as I mentioned above is that you are only using a single image file. See the example images I linked to in my last message to get an idea of the number and variety of images you should be using.

from apriltag.

mzucker avatar mzucker commented on May 13, 2024

Hi, please read through issue #10 – I hope you will find some helpful information there. Let me know if you still have questions after reading it.

from apriltag.

maharshi114 avatar maharshi114 commented on May 13, 2024

Thank you for quick replay.
somehow I manage to print pose matrix using camtest.py code
Detection 1 of 1:
Family: tag36h11
ID: 2
Hamming error: 0
Goodness: 0.0
Decision margin: 60.6518554688
Homography: [[-2.63700683e-02 -7.44275243e-01 1.26088787e+00]
[ 6.93561147e-01 -7.26055716e-02 2.31620847e+00]
[-3.56854414e-06 -1.90672384e-04 9.19281710e-03]]
Center: [137.16011768 251.95850647]
Corners: [[216.41851807 180.59469604]
[210.96052551 328.61419678]
[ 54.4800148 326.40319824]
[ 60.2931366 172.11759949]]
Pose: [[-0.12400197 -0.86445901 -0.48716951 -0.41820917]
[ 0.95202461 0.0347795 -0.3040387 -0.18913546]
[ 0.2797725 -0.50149876 0.81867353 1.33183182]
[ 0. 0. 0. 1. ]]
InitError: 11.5416902905
FinalError: 1.26238447089

as according to issue #10, the three values in the 4x4 pose matrix ( -0.41820917, -0.18913546, 1.33183182 ) show me the X, Y, and Z positions respectively.

but the value of Z is wrong in my case. The actual distance in my case is 0.9 meter.
my tag size is 0.16 meter.
after some observation, I figure out the in homography matrix the last value in matrix "9.19281710e-03" show me the accurate number in distance. Just multiplicate with 100 so final value (9.19281710e-03*100) = 0.919 meters with 1 to 2 mm accuracy.

so my question is, Why Pose matrix X, Y, and Z values show me wrong?
and what is homography matrix actually shows?

from apriltag.

mzucker avatar mzucker commented on May 13, 2024

This article I wrote describes what a homography matrix is: https://mzucker.github.io/2016/10/11/unprojecting-text-with-ellipses.html

The homography matrix will not in general correspond directly to physical measurements because it is a product of the camera intrinsics and the pose of the tag. In this case, I believe the fact that the bottom-right entry resembles the distance you measured is a coincidence.

What are the dimensions (resolution) of the images you are detecting tags in, and how did you obtain the calibration values listed above?

from apriltag.

maharshi114 avatar maharshi114 commented on May 13, 2024

calibration values are find via calibrate_camera.py code. Click the image of the chessboard via Logitech C270 camera and run calibrate_camera.py code.
camera resolution = 640x480 pixels

from apriltag.

mzucker avatar mzucker commented on May 13, 2024

I don't trust the camera calibration values you provided for that camera. For the vast majority of desktop webcams you would expect to see focal lengths (fx, fy) on the order of image width and optical center (cx, cy) towards the center of the image. So for that camera, I would expect fx,fy to be in the 500-800 range, and the (cx, cy) point to be much closer to (320, 240) (that is 640/2, 480/2).

If you attach your chessboard calibration images here, I can try verifying your calibration values.

from apriltag.

mzucker avatar mzucker commented on May 13, 2024

I can't access that image on Google drive, but github accepts attachments to replies.

Note you must use multiple images to calibrate the camera. One is not sufficient! See for example https://github.com/swatbotics/apriltag/tree/master/images/mapping_feb_2014/calibration

from apriltag.

maharshi114 avatar maharshi114 commented on May 13, 2024

sorry for google drive link.
here it is the image file.
im3

from apriltag.

maharshi114 avatar maharshi114 commented on May 13, 2024

Ok got it.
Thank you.. sir

from apriltag.

maharshi114 avatar maharshi114 commented on May 13, 2024

Ok sir ..

from apriltag.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.