Add re-timing, minimum dt robustness
This commit is contained in:
@@ -47,7 +47,9 @@ def project_depth_to_pointcloud(depth_image: torch.Tensor, intrinsics_matrix: to
|
||||
|
||||
|
||||
@get_torch_jit_decorator()
|
||||
def get_projection_rays(height: int, width: int, intrinsics_matrix: torch.Tensor):
|
||||
def get_projection_rays(
|
||||
height: int, width: int, intrinsics_matrix: torch.Tensor, depth_to_meter: float = 0.001
|
||||
):
|
||||
"""Projects numpy depth image to point cloud.
|
||||
|
||||
Args:
|
||||
@@ -82,7 +84,7 @@ def get_projection_rays(height: int, width: int, intrinsics_matrix: torch.Tensor
|
||||
rays = torch.stack([output_x, output_y, input_z], -1).reshape(
|
||||
intrinsics_matrix.shape[0], width * height, 3
|
||||
)
|
||||
rays = rays * (1.0 / 1000.0)
|
||||
rays = rays * depth_to_meter
|
||||
return rays
|
||||
|
||||
|
||||
|
||||
Reference in New Issue
Block a user