Validate distortion coefficients
OpenCV calibration can return invalid distortion coefficients (resulting in non-monotonic distortion function).
Documented in camera model section: https://docs.opencv.org/master/d9/d0c/group__calib3d.html#details
Calibration should be considered failed if such values are returned and those values should not be used to perform distortion correction.
Calibration app should also report if this happens.
Edited by Sebastian Hahta