From d04553d74bb0c4d6f6800a0db71828abfce7483a Mon Sep 17 00:00:00 2001 From: nnop Date: Wed, 4 Sep 2024 20:17:30 +0800 Subject: [PATCH] Fix points projection when sampling patches for training fix https://github.com/nerfstudio-project/gsplat/issues/381 --- examples/datasets/colmap.py | 3 --- 1 file changed, 3 deletions(-) diff --git a/examples/datasets/colmap.py b/examples/datasets/colmap.py index db3a921b0..5aeeec5be 100644 --- a/examples/datasets/colmap.py +++ b/examples/datasets/colmap.py @@ -304,9 +304,6 @@ def __getitem__(self, item: int) -> Dict[str, Any]: points_proj = (K @ points_cam.T).T points = points_proj[:, :2] / points_proj[:, 2:3] # (M, 2) depths = points_cam[:, 2] # (M,) - if self.patch_size is not None: - points[:, 0] -= x - points[:, 1] -= y # filter out points outside the image selector = ( (points[:, 0] >= 0)