Convert batched points (xyz) to (xyz1).
(
points: Float[Tensor, "*batch dim"],
)
| 9 | |
| 10 | |
| 11 | def homogenize_points( |
| 12 | points: Float[Tensor, "*batch dim"], |
| 13 | ) -> Float[Tensor, "*batch dim+1"]: |
| 14 | """Convert batched points (xyz) to (xyz1).""" |
| 15 | return torch.cat([points, torch.ones_like(points[..., :1])], dim=-1) |
| 16 | |
| 17 | |
| 18 | def homogenize_vectors( |
no test coverage detected