processes the position + quaternion raw pose from dataset to position + rotation matrix :param poses_in: N x 7 :param rot_mat: N x 3 x 3 :return: processed poses N x 12
(poses_in, rot_mat)
| 31 | return q |
| 32 | |
| 33 | def process_poses_rotmat(poses_in, rot_mat): |
| 34 | """ |
| 35 | processes the position + quaternion raw pose from dataset to position + rotation matrix |
| 36 | :param poses_in: N x 7 |
| 37 | :param rot_mat: N x 3 x 3 |
| 38 | :return: processed poses N x 12 |
| 39 | """ |
| 40 | |
| 41 | poses = np.zeros((poses_in.shape[0], 3, 4)) |
| 42 | poses[:,:3,:3] = rot_mat |
| 43 | poses[...,:3,3] = poses_in[:, :3] |
| 44 | poses = poses.reshape(poses_in.shape[0], 12) |
| 45 | return poses |
| 46 | |
| 47 | from torchvision.datasets.folder import default_loader |
| 48 | def load_image(filename, loader=default_loader): |
nothing calls this directly
no outgoing calls
no test coverage detected