I’d like to retrieve to rotation and and translation between left and right cameras with one or another as reference.
calibration_params = camera.get_camera_information().camera_configuration.calibration_parameters
attributes = [attr for attr in dir(calibration_params) if not callable(getattr(calibration_params, attr)) and not attr.startswith("__")]
print(attributes)
tz = calibration_params.T.z
Result:
['left_cam', 'right_cam', 'stereo_transform']
Traceback (most recent call last):
tz = calibration_params.T.z
^^^^^^^^^^^^^^^^^^^^
AttributeError: 'pyzed.sl.CalibrationParameters' object has no attribute 'T'
Hi @Adrien
Sorry for the confusion, this sample of code in the doc is obsolete, I will update it. Thank you for the report!
Instead of:
tz = calibration_params.T.z
Please do:
tz = calibration_params.stereo_transform.get_translation().get()[2]
Note that it will always give you 0, the length of the camera is on the X axis, so you should do get()[0]
to access it.