Skip to content

Fix normalization of planar pose products - #319

Open
kaushikgunasekaren wants to merge 2 commits into
rai-opensource:masterfrom
kaushikgunasekaren:fix-planar-product-normalization-nov22
Open

kaushikgunasekaren wants to merge 2 commits into
rai-opensource:masterfrom
kaushikgunasekaren:fix-planar-product-normalization-nov22

Conversation

@kaushikgunasekaren

Copy link
Copy Markdown

Bug

prod(norm=True) always calls the 3D trnorm helper, including for SO2 and SE2 sequences. SO2 products raise a dimension error. An SE2 matrix is instead treated as a 3D rotation, which can alter the translation and bottom row before construction fails.

Change

Dispatch normalization by the pose dimension, using trnorm2 for planar groups and retaining trnorm for 3D groups, as the existing norm() method already does. The multiplication order and unnormalized path are unchanged.

Validation

  • 36 focused regression/control cases: 14 fail before the fix; all 36 pass after it.
  • All four pose classes; empty, singleton, three-element and 90-element sequences; checking enabled/disabled; valid group membership, result type, translation/bottom-row preservation, unchanged inputs and unnormalized controls.
  • Full local suite: 602 passed, 3 skipped, 99 subtests passed (21 warnings), versus 566 passed on unchanged master.
  • Regression-test Black 23.10.0, fatal changed-file flake8 and added-line whitespace checks pass. Existing unrelated source formatting is preserved. Whole-repository fatal lint has two pre-existing undefined-name findings in tests/test_dualquaternion.py.

AI assistance was used for investigation, implementation and tests. Validation is local Python testing only; no hardware validation is claimed.

This branch has not been deployed

No deployments
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant