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

Equidistant distortion model #17

Closed
NikolausDemmel opened this issue Oct 28, 2014 · 10 comments
Closed

Equidistant distortion model #17

NikolausDemmel opened this issue Oct 28, 2014 · 10 comments

Comments

@NikolausDemmel
Copy link
Contributor

Hi, could you point me to a resource/paper explaining the equidistant distortion model? It seems to me the paper reference on [1] is not discussing that.

Am I right to assume that the standard ROS tools (image_proc) do not support that distortion model, but rather only the pinhole camera model + radtan distorition model (called plumb_bob in CameraInfo) [2,3]?

[1] https://github.com/ethz-asl/kalibr/wiki/supported-models
[2] http://wiki.ros.org/image_pipeline/CameraInfo
[3] http://docs.ros.org/api/sensor_msgs/html/msg/CameraInfo.html

@furgalep
Copy link
Contributor

@rehderj, can you provide a paper with the equidistant model that you implemented?

To the best of my knowledge you are right; the ROS tools only support pinhole + radtan.

@rehderj
Copy link
Contributor

rehderj commented Oct 28, 2014

Hi, please see equation 7 of the referenced paper, which should describe the equidistant distortion model employed in kalibr. While there is a more complete model including additional tangential distortion reported in that work, kalibr uses the radially symmetric model detailed on in section II.A of the paper. Note that this is consistent with the work of other groups, which can be found here, equation 3-8.
My understanding of ROS from here is that it currently does not support this model.
However, we found it to return lower reprojection errors for a wide range of optics, which again is consistent with findings in this paper.

@NikolausDemmel
Copy link
Contributor Author

Thanks for the pointers! I will look them up and possibly come back with any additional questions.

@rehderj
Copy link
Contributor

rehderj commented Oct 28, 2014

Sure, feel free to approach us with additional questions. As an addition, the last comment referred to figure 6 in the Richardson paper, which suggests (for these particular optics) a generally lower reprojection errors as well as a significant gain in accuracy in the peripheral parts of the image.

@schneith
Copy link

If you need to undistort images in ROS using a pinhole camera and an equidistant distortion model, the code in the repo below might be useful for you.

https://github.com/schneith/undistorter

@NikolausDemmel
Copy link
Contributor Author

@schneith: this looks indeed very helpful. Thanks for the pointer! I will test this once I have augmented our data with current calibration in CameraInfo format.

@NikolausDemmel
Copy link
Contributor Author

So while implementing the calibration model in our system an additional question came up about the undistort function:

@schneith uses a fixed number of 20 iterations to compute the undistorted radius. Why 20? Is this value just common wisdom for "large enough"? What could be an appropriate abort criteria?

P.S.: The undistorter ROS package works nicely with our calibration values to rectify recorded sequences, thanks @schneith.

@NikolausDemmel
Copy link
Contributor Author

One more question actually about @schneith 's implementation: Is there a reason that there is no check for really small thetad in undistort, like there is for r in distort.

@rehderj
Copy link
Contributor

rehderj commented Nov 8, 2014

There is little justification for the specific number of 20 iterations. Feels free to implement your favorite abort criterion, good candidates might either be the amount of change in the incidence angle theta in subsequent iterations or the absolute difference between the measured distorted theta and your modelled distorted theta when applying the distortion to the current estimate.
The check for small r is for numerical stability. We have not evaluated if it is necessary, nor whether there cannot arise numerical instabilities in the undistortion under all circumstances.

@NikolausDemmel
Copy link
Contributor Author

That makes perfect sense, thank you!

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

4 participants