align rotation-matrix FFI to row-major convention#186
Conversation
|
👋 Thanks for requesting a review from the team! We aim to review PRs within one business day. If this is urgent |
| elements: *const [f64; 9], | ||
| ) -> *mut Rotation3<f64> { | ||
| null_pointer_check!(elements); | ||
| let matrix = Matrix3::from_vec(Vec::from(*elements)); |
There was a problem hiding this comment.
https://docs.rs/nalgebra/latest/nalgebra/base/struct.Matrix.html#method.from_vec states
Creates a matrix with its elements filled with the components provided by a slice in column-major order
Nick Franczak (nfranczak)
left a comment
There was a problem hiding this comment.
math checks out.
i defer approval to the sdk team.
please make sure that universal-robots still remains working as it uses rust-utils through FFI
Yep already noted this in the rdk pr audit - universal-robots rust_utils.h only imports OV/Quaternion/Euler/AxisAngle FFI symbols, zero rotation-matrix functions. This PR only touches rotation-matrix symbols so its imports are untouched |
Naveed Jooma (njooma)
left a comment
There was a problem hiding this comment.
Releases are done weekly. Sorry to have missed today's release, but if needed we can do a second release today. Or it can wait till next week.
the python -sdk will automatically pick up a new rust-utils when we do a release
|
Hey Joseph Borodach (@JosephBorodach) — this PR has been approved and CI has been green for 3+ business days. Ready to merge? Auto-comment from overwatch. Will not re-nudge for 7 days. |
Synced offline with Naveed Jooma (@njooma), will release Python sdk before rust utils next week to give me time to make the Python sdk fix |
Applying the analogous fix to what shipped in rdk#6193 (viamrobotics/rdk#6193).
Two motivations:
The behavior change to both rust_utils and the python sdk are safe bc we have no users of these APIs yet. Best to fix it before we do.
Question for rust-utils maintainers: what's the release cadence here? viam-python-sdk's postinstall.sh pulls rust-utils/releases/latest, so I'll need to know when this ships as a release to time the Python SDK follow-up