Propagate one object's pose through another object's rigid motion. Returns: (new_pos2, new_quat2_wxyz)
(
current_pos1: np.ndarray, current_quat1_wxyz: np.ndarray,
prev_pos1: np.ndarray, prev_quat1_wxyz: np.ndarray,
prev_pos2: np.ndarray, prev_quat2_wxyz: np.ndarray,
)
| 123 | |
| 124 | |
| 125 | def propagate_pose( |
| 126 | current_pos1: np.ndarray, current_quat1_wxyz: np.ndarray, |
| 127 | prev_pos1: np.ndarray, prev_quat1_wxyz: np.ndarray, |
| 128 | prev_pos2: np.ndarray, prev_quat2_wxyz: np.ndarray, |
| 129 | ) -> Tuple[np.ndarray, np.ndarray]: |
| 130 | """ |
| 131 | Propagate one object's pose through another object's rigid motion. |
| 132 | |
| 133 | Returns: |
| 134 | (new_pos2, new_quat2_wxyz) |
| 135 | """ |
| 136 | T_curr1 = pose_to_transform(current_pos1, current_quat1_wxyz) |
| 137 | T_prev1 = pose_to_transform(prev_pos1, prev_quat1_wxyz) |
| 138 | T_prev2 = pose_to_transform(prev_pos2, prev_quat2_wxyz) |
| 139 | T_new2 = T_prev2 @ np.linalg.inv(T_prev1) @ T_curr1 |
| 140 | return transform_to_pose(T_new2) |
nothing calls this directly
no test coverage detected