erwincoumans / tiny-differentiable-simulator

Tiny Differentiable Simulator is a header-only C++ and CUDA physics library for reinforcement learning and robotics with zero dependencies.
Apache License 2.0
1.23k stars 130 forks source link

Fix quaternion normalize #96

Closed ErikGartner closed 3 years ago

ErikGartner commented 3 years ago

Hi!

I noticed that the API wasn't consistent for Eigen and Tiny when it comes to normalize(Quaternion). Tiny returned a new quaternion and Eigen normalized the quaternion in place.

I have updated the code to be consistent with the Tiny implementation.

Unfortunately this pull-requests follows on #93 so Github included the changes from it in the diff.

erwincoumans commented 3 years ago

Maybe close and synchronize (git pull etc) and make a new pull request? I merge the other two.