The unit test testDistortion.py tests a few things but those do not include the actual distortion computation (instead it prints a series of values that includes an error. The test contains outdated data (the camera geometry has changed) so some error values are unreasonably large.
I propose to do the following:
- Update the test to optionally write the expected results to a file (e.g. by setting a constant).
- Have the test read the data from a file instead of as text in the file.
- Instead of printing output it will test on the difference.
Unfortunately this assumes that the current distortion function operates correctly, so it's not quite as thorough a test as we might like, but it will be an improvement and will greatly help
DM-5922 which changes to a new distortion function.