suppress errors in vision/fair/pytorch3d

Differential Revision: D30479084

fbshipit-source-id: 6b22dd0afe4dfb1be6249e43a56657519f11dcf1
This commit is contained in:
Pyre Bot Jr
2021-08-22 23:38:17 -07:00
committed by Facebook GitHub Bot
parent 1ea2b7272a
commit fadec970c9
7 changed files with 41 additions and 6 deletions

View File

@@ -95,7 +95,11 @@ class TensorProperties(nn.Module):
"""
def __init__(
self, dtype: torch.dtype = torch.float32, device: Device = "cpu", **kwargs
self,
# pyre-fixme[9]: dtype has type `dtype`; used as `Type[torch.float32]`.
dtype: torch.dtype = torch.float32,
device: Device = "cpu",
**kwargs,
) -> None:
"""
Args:
@@ -273,7 +277,10 @@ class TensorProperties(nn.Module):
def format_tensor(
input, dtype: torch.dtype = torch.float32, device: Device = "cpu"
input,
# pyre-fixme[9]: dtype has type `dtype`; used as `Type[torch.float32]`.
dtype: torch.dtype = torch.float32,
device: Device = "cpu",
) -> torch.Tensor:
"""
Helper function for converting a scalar value to a tensor.
@@ -301,7 +308,10 @@ def format_tensor(
def convert_to_tensors_and_broadcast(
*args, dtype: torch.dtype = torch.float32, device: Device = "cpu"
*args,
# pyre-fixme[9]: dtype has type `dtype`; used as `Type[torch.float32]`.
dtype: torch.dtype = torch.float32,
device: Device = "cpu",
):
"""
Helper function to handle parsing an arbitrary number of inputs (*args)