utils: raspberrypi: ctt: Fix NaNs in chromatic aberration tables
NaNs can appear if no black dots can be found and analysed in a particular region of the calibration image. There needs to be at least one such dot in every 8x8 cell covering the image. This is now detected, and an error message issued. No CAC tables are generated, so CAC is disabled. Bug: https://github.com/raspberrypi/libcamera/issues/254 Signed-off-by: David Plowman <david.plowman@raspberrypi.com> Reviewed-by: Naushir Patuck <naush@raspberrypi.com> Acked-by: Kieran Bingham <kieran.bingham@ideasonboard.com> Signed-off-by: Kieran Bingham <kieran.bingham@ideasonboard.com>
This commit is contained in:
parent
36ba0e5515
commit
17e41b2a3a
2 changed files with 33 additions and 8 deletions
|
@ -198,9 +198,12 @@ class Camera:
|
|||
"""
|
||||
Write output to json
|
||||
"""
|
||||
self.json['rpi.cac']['cac'] = cacs
|
||||
self.log += '\nCAC calibration written to json file'
|
||||
print('Finished CAC calibration')
|
||||
if cacs:
|
||||
self.json['rpi.cac']['cac'] = cacs
|
||||
self.log += '\nCAC calibration written to json file'
|
||||
print('Finished CAC calibration')
|
||||
else:
|
||||
self.log += "\nCAC calibration failed"
|
||||
|
||||
|
||||
"""
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue