(self, joints)
| 31 | |
| 32 | # joints (batch_size, joints_num, 3) |
| 33 | def get_offsets_joints_batch(self, joints): |
| 34 | assert len(joints.shape) == 3 |
| 35 | _offsets = self._raw_offset.expand(joints.shape[0], -1, -1).clone() |
| 36 | for i in range(1, self._raw_offset.shape[0]): |
| 37 | _offsets[:, i] = torch.norm(joints[:, i] - joints[:, self._parents[i]], p=2, dim=1)[:, None] * _offsets[:, i] |
| 38 | |
| 39 | self._offset = _offsets.detach() |
| 40 | return _offsets |
| 41 | |
| 42 | # joints (joints_num, 3) |
| 43 | def get_offsets_joints(self, joints): |
no outgoing calls
no test coverage detected