[Rotation] Add 6D rotation representation per Zhou et al 2019#368
Open
fagg wants to merge 1 commit into
Open
Conversation
AlexanderFabisch
self-requested a review
July 10, 2026 07:09
Member
|
Hi @fagg , thank you for this contribution. I only have two open points:
What do you think? |
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.
Adds two new functions to pytransform3d.rotations for converting between rotation matrices and continuous 6D rotation representation introduced by Zhou et al (CVPR 2019).
rotation_6d_from_matrix- encode a rotation matrix as a 6D vector (its first two columns stacked)matrix_from_rotation_6d- decode a 6D vector back into a rotation matrix via Gram-Schmidt orthonormalizationMost parameterizations of rotation (quaternion, axis-angle, Euler angles) are discontinuous as functions on SO(3). For classical geometry, this largely doesn't matter. However, the discontiuity is problematic for machine learning. Zhou et al showed that any representation of SO(3) with fewer than 5 dimensions is necessarily discontinuous - and proposed a continuous 6D representation that avoids this. It has become the defacto standard target for learned rotation estimation in pose estimation and other computer vision tasks. This PR makes this representation directly available in pytransform3d.
All of the core functionality already existed, this merely wraps it. A proper test suite has been added to ensure correctness;