irtk.io.to_torch¶
- irtk.io.to_torch(data: ndarray, dtype: torch.dtype) torch.Tensor ¶
Converts a numpy array to a torch tensor.
- Parameters:
data – The input numpy array.
dtype – The desired torch data type.
- Returns:
The torch tensor.
Converts a numpy array to a torch tensor.
data – The input numpy array.
dtype – The desired torch data type.
The torch tensor.