Add APIs to get extrinsic/distortion matrix and timestamp, etc.#121
Open
davidliyutong wants to merge 2 commits into
Open
Add APIs to get extrinsic/distortion matrix and timestamp, etc.#121davidliyutong wants to merge 2 commits into
davidliyutong wants to merge 2 commits into
Conversation
…be very helpful for researchers of robotics Changes: - [feature] add `get_timestamp_usec` method to capture - [feature] add `get_device_timestamp_usec` to capture - [feature] add `get_system_timestamp_nsec` to capture - [feature] add `get_extrinsic_matrix` to calibration for getting extrinsic matrix of cameras - [feature] add `get_distortion_parameters` for getting distortion parameters of cameras
Author
|
Here is an example to test: import pykinect_azure as pykinect
pykinect.initialize_libraries()
def test_new_api(path: str):
pb: pykinect.Playback = pykinect.start_playback(path)
while True:
ret, capture = pb.update()
if ret:
print("Extrinsic Matrix: ", capture.calibration.get_extrinsic_matrix())
print("Distortion Matrix: ", capture.calibration.get_distortion_parameters())
color_obj = capture.get_color_image_object()
print("timestamp usec: ", color_obj.get_timestamp_usec())
print("Device timestamp usec: ", color_obj.get_device_timestamp_usec())
print("System timestamp nsec: ", color_obj.get_system_timestamp_nsec())
else:
break
test_new_api(r"recording.mkv") |
refactor: get_extrinsic_matrix support camera parameter refactor: get_distortion_parameters support camera parameter feat: add create_custom16 / create_bgra32 api to support 16bit depth
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Timestamps are helpful for researchers of robotics
Changes:
get_timestamp_usecmethod to captureget_device_timestamp_usecto captureget_system_timestamp_nsecto captureget_extrinsic_matrixto calibration for getting extrinsic matrix of camerasget_distortion_parametersfor getting distortion parameters of cameras