symforce-org / symforce

Fast symbolic computation, code generation, and nonlinear optimization for robotics
https://symforce.org
Apache License 2.0
1.44k stars 147 forks source link

C++ Values LocalCoordinates is backwards #399

Open aaron-skydio opened 2 months ago

aaron-skydio commented 2 months ago

https://github.com/symforce-org/symforce/issues/395#issuecomment-2294152796

Values::LocalCoordinates(v) produces v - this, which is the negative of what's used everywhere else. On the geo types and cam types, and Values.local_coordinates in Python, it returns this - v

aaron-skydio commented 2 months ago

As far as which is correct, I think the convention everything else uses is more intuitive, plus it's much less of a breakage to change Values::LocalCoordinates than everything else.

Above all else though, they should all be consistent (all of the instance methods, at least)