Running OpenDroneMap on some test images generated the error:
Traceback (most recent call last): File "../../OpenDroneMap/run.py", line 986, in <module> prepare_objects() File "../../OpenDroneMap/run.py", line 415, in prepare_objects fileObject["ccd"] = float(ccdWidths[fileObject["id"]]) KeyError: u'PENTAX Corporation PENTAX Optio S5i'
The issue is that the camera description was not found in the ccd_defs.json file.
However, the camera description is there (line 269):
"PENTAX Corporation PENTAX Optio S5i": 5.76,
But, of course, the key it was seeking was slightly different:
PENTAX Corporation PENTAX Optio S5i
The difference being an extra space between the manufacturer name and the model description.
Duplicating this line and removing the extra space in the ccd_defs.json file resolved this error.
Seems the fix should involve using some regex pattern matching on spaces in the camera descriptions to avoid one-off errors like this.
Good catch, however in the current dev branch we rely solely on Mapillary's sensor data, so I'm not sure if we should spend time fixing this problem. AFAIK OpenSfM handles parsing EXIF data robustly.
Running OpenDroneMap on some test images generated the error:
Traceback (most recent call last): File "../../OpenDroneMap/run.py", line 986, in <module> prepare_objects() File "../../OpenDroneMap/run.py", line 415, in prepare_objects fileObject["ccd"] = float(ccdWidths[fileObject["id"]]) KeyError: u'PENTAX Corporation PENTAX Optio S5i'
The issue is that the camera description was not found in the ccd_defs.json file.
However, the camera description is there (line 269):
"PENTAX Corporation PENTAX Optio S5i": 5.76,
But, of course, the key it was seeking was slightly different:
PENTAX Corporation PENTAX Optio S5i
The difference being an extra space between the manufacturer name and the model description. Duplicating this line and removing the extra space in the ccd_defs.json file resolved this error.
Seems the fix should involve using some regex pattern matching on spaces in the camera descriptions to avoid one-off errors like this.