dpnp.ndarray.__reduce__

method

ndarray.__reduce__()

Used by pickle to serialize the array.

The data is copied to the host and pickled together with the array type and the USM type. Unpickling allocates the array on the default SYCL device with the original USM type, so it may end up on a different device than the one it was pickled from.

Unpickling raises ValueError if the default device does not support the data type, e.g. float64 on a device without double-precision support.