From d67662d13ce497e746196f68cfd90b61954fea23 Mon Sep 17 00:00:00 2001 From: Nikhila Ravi Date: Tue, 21 Dec 2021 05:45:32 -0800 Subject: [PATCH] Update use of `select_cameras` Summary: Removed `select_cameras.py` from implicitron and updated all callsites to directly index the cameras. Reviewed By: bottler Differential Revision: D33187605 fbshipit-source-id: aaf5b36aef9d72db0c7e89dec519f23646f6aa05 --- pytorch3d/renderer/cameras.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pytorch3d/renderer/cameras.py b/pytorch3d/renderer/cameras.py index 09cdc72b..837670de 100644 --- a/pytorch3d/renderer/cameras.py +++ b/pytorch3d/renderer/cameras.py @@ -383,7 +383,7 @@ class CamerasBase(TensorProperties): kwargs = {} - if not isinstance(index, (int, list, torch.LongTensor)): + if not isinstance(index, (int, list, torch.LongTensor, torch.cuda.LongTensor)): msg = "Invalid index type, expected int, List[int] or torch.LongTensor; got %r" raise ValueError(msg % type(index))