-
Notifications
You must be signed in to change notification settings - Fork 81
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Transforming calibration parameters (intrinsics) #69
Comments
I found the function that defines the structure of the code: typedef struct _k4a_camera_calibration_mode_info_t so basically when we use the 1080p resolution we got these values: case K4A_COLOR_RESOLUTION_1080P: so basically according to this code we have to perform this operation: float cx = params->param.cx * mode_info->calibration_image_binned_resolution[0];
And I got these values: cx = 959.3317794799805 The values that we got from this "recording procedure" that open3d offers are: cx = 958.831787109375 So I think that I got it now... "Rt": { According to me, this means the transformation matrix between the RGB camera and the DEPTH camera, is this right? what units are these? what is the structure of the matrix? thanks in advance! |
Hi @FelipeDelgadoR, I think you got it right for the intrinsics paramaters and as you said, it really depends on the resolution. For the extrinsics parameters, those are not normalized and can be used directly in a 4x3 matrix. There is more information in the OpenCV documentation. Yes those the extrinsics parameters between both camera, the translation unit is in meter and for the rotation there is no unit because those are sin and cos values of the rotation by axis. I hope it answer your question! |
I was just thinking that after I posted the question, of course the T values are in meters! |
How can I get Btw, it would be great to have a utility function to convert intrinsic parameters to the OpenCV format. I think more people would appreciate it :-) |
Camera matrix and distortion coefficients in OpenCV-compatible format. These values are already specific to the selected camera resolution (in contrast to those accessed through calibration_raw). related to etiennedub#35, etiennedub#69
Camera matrix and distortion coefficients in OpenCV-compatible format. These values are already specific to the selected camera resolution (in contrast to those accessed through calibration_raw). related to etiennedub#35, etiennedub#69
Camera matrix and distortion coefficients in OpenCV-compatible format. These values are already specific to the selected camera resolution (in contrast to those accessed through calibration_raw). related to etiennedub#35, etiennedub#69
Camera matrix and distortion coefficients in OpenCV-compatible format. These values are already specific to the selected camera resolution (in contrast to those accessed through calibration_raw). related to etiennedub#35, etiennedub#69
- Use clang-format as CPP code formatter/linter (#105) - Available devices count (#107) - Recording support (#106) - Capture color exposure and white balance properties (#110) - Calibration: Add functions to access intrinsics (#113) - Add 3d => 2d conversion function (#114) * Run test with different python versions (#65) * Add matrix to workflow * Change python versions list * Change python versions list * Add k4a versions to matrix * Typofix * Drop k4a from matrix * Add dataclasses requirement for python <3.7 * Fix python 3.6 test behavior * Fix python 3.6 test behavior * Restore fail-fast option * fix conversion seconds to ns * fix conversion seconds to ns * fix timestamp ns to us Co-authored-by: Louis-Philippe Asselin <louisphilippeasselin@gmail.com> * fix install using pip --editable --user (#67) * Codecov support (#64) * Codecov support * Add badge * Order badges * fix capture.transformed_depth_point_cloud (#73) * version 1.0.1 * Added transformed_ir with transform_depth_image_to_color_camera_custom functionality (#76) * Added transform_depth_image_to_color_camera_custom functionality * keeping things c * add interpolation option condition as a parameter * returned the depth image * unpack return value if not None so avoid error * Image timestamp support (#88) * Support for capture images timestamps * Support for capture images timestamps * Add more changes * version 1.1.0 * fix lint * readme fix wrong example version of SDK * Use clang-format as CPP code formatter/linter (#105) * Use clang-format as CPP code formatter/linter * Add missed .clang-format * Available devices count (#107) * Add ability to querying devices count and read serial numbers * Fix test * Rename installed_count => connected_device_count * Recording support (#106) * Recording support * Tests * Small refactoring * Add ability to querying devices count and read serial numbers * Fix test * Fix format * Capture color exposure and white balance properties (#110) * Add color_white_balance and exposure_usec properties to capture * Add color_white_balance and exposure_usec properties to capture Co-authored-by: Louis-Philippe Asselin <lpasselin@users.noreply.github.com> * Calibration: Add functions to access intrinsics (#113) Camera matrix and distortion coefficients in OpenCV-compatible format. These values are already specific to the selected camera resolution (in contrast to those accessed through calibration_raw). related to #35, #69 Co-authored-by: Johan von Forstner <johan.vonforstner@paradoxcat.com> * version 1.2.0 Co-authored-by: Ilya Gruzinov <igruzinov@yandex.ru> Co-authored-by: Samuel Boulanger <samuelrdboulanger@gmail.com> Co-authored-by: Johan von Forstner <johan.forstner@gmail.com> Co-authored-by: Johan von Forstner <johan.vonforstner@paradoxcat.com>
Hi @etiennedub
I've got these values from the RGB camera:
"ModelParameters": [
0.49965196847915649,
0.50621724128723145,
0.47322136163711548,
0.63089394569396973,
0.44268873333930969,
-2.6038174629211426,
1.5527737140655518,
0.32462942600250244,
-2.4303467273712158,
1.4789470434188843,
0,
0,
-0.00035283574834465981,
0.00099612073972821236
]
I know that the first 2 are cx, cy, fx and fy and that they are normalized so I can't use them inside opencv as the intrinsic matrix...
Right now i'm using this configuration:
K4A_FRAMES_PER_SECOND_15
K4A_COLOR_RESOLUTION_1080P
K4A_DEPTH_MODE_WFOV_UNBINNED
You gave me this code to check it out, but I'm not sure if I understand it correctly
I'd appreciate if you give me some help on transforming these values, thanks again!
The text was updated successfully, but these errors were encountered: