Append a '1' along the final dimension of the tensor (i.e. convert xyz->xyz1)
(points)
| 24 | # --- Projections --- |
| 25 | |
| 26 | def homogenize_points(points): |
| 27 | """Append a '1' along the final dimension of the tensor (i.e. convert xyz->xyz1)""" |
| 28 | return torch.cat([points, torch.ones_like(points[..., :1])], dim=-1) |
| 29 | |
| 30 | |
| 31 | def normalize_homogenous_points(points): |
no outgoing calls
no test coverage detected