pytorch_pfn_extras.as_numpy_dtype

pytorch_pfn_extras.as_numpy_dtype(torch_dtype: torch.dtype) numpy.dtype

Returns NumPy dtype for the given PyTorch dtype.

Parameters

torch_dtype – PyTorch’s dtype object.

Returns

NumPy type object.