(self, joints)
| 41 | |
| 42 | # joints (joints_num, 3) |
| 43 | def get_offsets_joints(self, joints): |
| 44 | assert len(joints.shape) == 2 |
| 45 | _offsets = self._raw_offset.clone() |
| 46 | for i in range(1, self._raw_offset.shape[0]): |
| 47 | # print(joints.shape) |
| 48 | _offsets[i] = torch.norm(joints[i] - joints[self._parents[i]], p=2, dim=0) * _offsets[i] |
| 49 | |
| 50 | self._offset = _offsets.detach() |
| 51 | return _offsets |
| 52 | |
| 53 | # face_joint_idx should follow the order of right hip, left hip, right shoulder, left shoulder |
| 54 | # joints (batch_size, joints_num, 3) |
no outgoing calls
no test coverage detected