sigpy.from_pytorch¶
-
sigpy.
from_pytorch
(tensor, iscomplex=False)[source]¶ Zero-copy conversion from pytorch tensor to numpy/cupy array.
If iscomplex, then tensor must have the last dimension as 2, and the output will be viewed as a complex valued array.
Parameters: - tensor (PyTorch tensor) – input.
- iscomplex (bool) – whether input represents complex valued tensor.
Returns: Numpy/cupy array.