ethz-asl / hand_eye_calibration

Python tools to perform time-synchronization and hand-eye calibration.
BSD 3-Clause "New" or "Revised" License
429 stars 115 forks source link

Fix/dual quaternion to pose conversion. #74

Closed fabianbl closed 6 years ago

fabianbl commented 6 years ago

Problem Description

When extracting the pose vector [x y z qx qy qz qw] from the dual quaternion [q_r, q_t], the method DualQuaternion.to_pose() first gets the rotation quaternion q_r and inverts its components in case the scalar part is negative (q_r_minus). This should be fine as it describes the same rotation. However, when extracting the translation vector t from the "translation quaternion" q_t = 1/2 * t * q_r, we need to use the exact same quaternion q_r. Using the q_r_minus for instead of q_r for the computation of t leads to an inverted translation vector. Is this correct?

Summary