crosspy.to#
- crosspy.to(input, device: int)#
Move CrossPy arrays to the device identified by device.
- Parameters:
input (class:CrossPyArray) – The input array
device (int | class:cupy.cuda.Device) – If
device
is a negative integer, the target device is CPU; otherwise GPU with the corresponding ID.
- Returns:
NumPy array if
device
refers to CPU, otherwise CuPy array.