luxonis / depthai

DepthAI Python API utilities, examples, and tutorials.
https://docs.luxonis.com
MIT License
938 stars 232 forks source link

[BUG] Callibration does not work with OAK-D-SR. #1149

Open skotif opened 9 months ago

skotif commented 9 months ago

Describe the bug When launching command:

python3 calibrate.py -s 3.76 --board OAK-D-SR -nx 17 -ny 9

I get error:

Traceback (most recent call last):
  File "calibrate.py", line 1192, in <module>
    Main().run()
  File "calibrate.py", line 1181, in run
    self.startPipeline()
  File "calibrate.py", line 474, in startPipeline
    pipeline = self.create_pipeline()
  File "calibrate.py", line 565, in create_pipeline
    sensorName = cam_info['sensorName']
KeyError: 'sensorName'

Minimal Reproducible Example Followed the documentation at: https://docs.luxonis.com/projects/hardware/en/latest/pages/guides/calibration/?highlight=calibrate My depthai repo is at e1c1f58746ff.

Additional context I did little printing from callibrate.py.

cameraProperties = self.device.getConnectedCameraFeatures() is: [{socket: RGB/CENTER/CAM_A, sensorName: OV9782, width: 1280, height: 800, orientation: AUTO, supportedTypes: [COLOR, MONO], hasAutofocus: 0, name: color}]

self.board_config is: {'name': 'OAK-D-SR', 'revision': 'R0M0E0', 'cameras': {'LEFT': {'name': 'left', 'hfov': 71.86, 'type': 'color', 'extrinsics': {'to_cam': 'RIGHT', 'specTranslation': {'x': -2.0, 'y': 0, 'z': 0}, 'rotation': {'r': 0, 'p': 0, 'y': 0}}}, 'RIGHT': {'name': 'right', 'hfov': 71.86, 'type': 'color'}}, 'stereo_config': {'left_cam': 'LEFT', 'right_cam': 'RIGHT'}}

I am able to run

python3 -m depthai_viewer

however the resulting point cloud shows significant barrel distortion when flat wall with dots is viewed: Screenshot from 2024-01-29 19-46-34

jakaskerl commented 9 months ago

pip install depthai -U should fix the issue.

EDIT: actually it won't but for different reason. Forwarded this to FW team.