Eigen pred
- Add dummy print gtest macro
PRINT_TEST_FINISHED
-> simply prints test & test-case name once test-case has finished. - Moved (well copied)
MatrixSizeCheck
to separate file & addedVectorSizeCheck
&RowVectorSizeCheck
aliases - Add plenty of predicates (lambdas functions) to test Eigen-related things - e.g. later use in gtest test macro
- Add a
getYaw
function torotation.h
Merge request reports
Activity
@jsola could you please review the
src/eigen_predicates.h
file ??mentioned in commit c6999729
@jsola I did not modify the gtest macros as I was looking for a way to compose lambda in those macro.
The 'predicates' functions are are indeed meant for testing. That's why I was asking you to review them (e.g.pred_quat_is_approx
) to make sure the math make sens.Jeremie, your code:
pred_zero( log_q(rhs * lhs.inverse())
is correct. I however would prefer:
pred_zero( log_q(rhs.inverse() * lhs)
because it better fits our definitions for operator
diff()
in manifolds.Also, we may use
conjugate()
instead ofinverse()
, which for unit quaternions is the same but faster:pred_zero( log_q(rhs.conjugate() * lhs)
Finally, instead of
log_q
, one can simply look at the vector part for zero-ness, and therefore this is even faster:pred_zero( (rhs.conjugate() * lhs).vec() )
I believe going faster than this involves going inside the quaternion math, and I would not recommend it.
Edited by Joan Solà Ortega