From 8ba9a694ee33c04ad714506ee4e5dd7f3ea0e127 Mon Sep 17 00:00:00 2001 From: David Novotny Date: Thu, 14 Jul 2022 03:30:51 -0700 Subject: [PATCH] Remove -1 from crop mask Summary: Removing 1 from the crop mask does not seem sensible. Reviewed By: bottler, shapovalov Differential Revision: D37843680 fbshipit-source-id: 70cec80f9ea26deac63312da62b9c8af27d2a010 --- pytorch3d/implicitron/dataset/json_index_dataset.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pytorch3d/implicitron/dataset/json_index_dataset.py b/pytorch3d/implicitron/dataset/json_index_dataset.py index 54a5cd3c..385a7c55 100644 --- a/pytorch3d/implicitron/dataset/json_index_dataset.py +++ b/pytorch3d/implicitron/dataset/json_index_dataset.py @@ -779,7 +779,7 @@ class JsonIndexDataset(DatasetBase, ReplaceableBase): # pyre-fixme[6]: For 2nd param expected `int` but got `Optional[int]`. # pyre-fixme[6]: For 3rd param expected `int` but got `Optional[int]`. mask = torch.zeros(1, self.image_height, self.image_width) - mask[:, 0 : imre.shape[1] - 1, 0 : imre.shape[2] - 1] = 1.0 + mask[:, 0 : imre.shape[1], 0 : imre.shape[2]] = 1.0 return imre_, minscale, mask def _local_path(self, path: str) -> str: