-
Notifications
You must be signed in to change notification settings - Fork 373
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
Improved 3D transform ingestion & affine transform support #2102
Conversation
5561273
to
a52d7ee
Compare
Read for review now! Can't repro python linting errors locally, must be version dependent. Those lints don't make sense to me though - sounds like mypi has a built-in quaternion type..? Any advice very welcome |
We also need to update https://www.rerun.io/docs/concepts/spaces-and-transforms |
else: | ||
angle = pa.array([rotation.radians], type=pa.float32()) | ||
angle_variant = "Radians" | ||
angle = build_dense_union(axis_angle_type["angle"].type, angle_variant, angle) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
😭 oof -- the need to jump through these hoops is so painful
examples/python/ros/rerun_urdf.py
Outdated
rr.Translation3D( | ||
trimesh.transformations.translation_from_matrix(world_from_mesh, world_from_mesh[0:3, 0:3]) | ||
), |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
something is wrong here...
rr.Translation3D( | |
trimesh.transformations.translation_from_matrix(world_from_mesh, world_from_mesh[0:3, 0:3]) | |
), | |
rr.TranslationAndMat3( | |
rr.Translation3D( | |
trimesh.transformations.translation_from_matrix(world_from_mesh) | |
), | |
world_from_mesh[0:3, 0:3]) | |
), |
c23fbbb
to
c7ebfc8
Compare
* Transform is now Transform3D and has an affine transform with various options * todo notes on sparse enums in transform3d * from instead of into glam impls * add more utilities, port rust examples * better ui display for transform3d * transform3d now also captures direction parent/child child/parent * Fix images with same render order not layering transparently * nicer draw order sample * every draw order given out is individual again to avoid z fighting * affine3 python interface wip * unified affine transform logging from python * hide zero translations * fix up log_rigid3 and deprecate it * example for log_affine3 * Rename RotationAxisAngle * py-lint fixes * re-enable data_table_sizes_basics test * more docs and doc tests for transform3d * implement pinhole via transform3d.py * spelling * better affine transform error messages on python, fix tensor logging again * linting, small improvements * update all uses of log_rigid3 in python examples * fix old python incompatibility issues * split up transform enum into three different components rust only so far * wire up python sdk again to new components * fix pinhole camera not being categorized as spatial * enable custom pinhole ui * Rename to TranslationAndMat3 * fixup some tests in re_log_types * mono component documentation * fixup test_clean_for_polars_modify * change python api to log_transform3d * explicit quaternion type for python * Translation3D is now its own enum to allow explicit non-logged translation * fix quaternion logging in examples * slightly better error messages on wrong type in python transform api * Rust fmt * rust test fix * Avoid using attr.dataclass * comment and cosmetic fixes, fixes for ros demo * translation/rotation/scale are now options * rename creation methods in rust api fro Transform3D * fixup SpaceInfoConnection to be more versatile * Rigid3D helper class on python * a bit nicer rust api, less word duplication * Quaternion is no longer a dataclass in order to enforce spelling out the ordering * fix documentation of datalayout for matrix on python transform api * test/lint fixes * doc fix * fixup ros demo --------- Co-authored-by: Jeremy Leibs <[email protected]>
Transform 3D type now captures a variety of properties as-is:
The viewer UI reflects this:
https://github.com/rerun-io/rerun/assets/1220815/412be346-b7b7-4c90-8b33-9089aadb7b13
Some transforms in action that we didn't expose so far:
https://github.com/rerun-io/rerun/assets/1220815/f27d6e3f-024b-4989-bea8-4ce95be3f8b0
Component split-up
Pinhole
Transform3D
Assumed to be affine. Not named such for ergonomic reasons
DisconnectedSpace
Python API changes
log_rigid3
deprecatedlog_unknown
deprecatedlog_pinhole
unchangedlog_disconnected_space
log_transform3d
Example:Future Work
rr.transform(rotation=, translation=, matrix=)
scipi
datatypes!translation
) can be passed in torr.log_transform3d
Fixes #1956
Checklist
PR Build Summary: https://build.rerun.io/pr/2102