Skip to content

[Fix] Correct scale factor in rotation propagation (use scalar_type(0.5))#28

Open
Daehan2Lee wants to merge 1 commit into
HViktorTsoi:masterfrom
Daehan2Lee:bugFix
Open

[Fix] Correct scale factor in rotation propagation (use scalar_type(0.5))#28
Daehan2Lee wants to merge 1 commit into
HViktorTsoi:masterfrom
Daehan2Lee:bugFix

Conversation

@Daehan2Lee

Copy link
Copy Markdown

Summary

In the predict step of the filter, the rotation propagation is computed by applying an exponential map via MTK::exp. Previously, scalar_type(1/2) was used as the scale factor, but because of integer division, this evaluated to 0 instead of the intended 0.5. This resulted in an incorrect (negative or NaN) input being passed to MTK::cos_sinc_sqrt, causing an assertion failure.

Changes

  • Replaced scalar_type(1/2) with scalar_type(0.5) in the rotation propagation code within the predict step.
  • This change ensures that the correct scale factor (0.5) is used when computing the exponential map for SO3 updates.

Testing

  • Verified that after this fix, the predict step runs without assertion failures and the rotation propagation behaves as expected.

Notes

This fix addresses the propagation of the rotation state (in the predict step), ensuring numerical correctness by using the proper scale factor.

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