This throws an error: ```python import numpy as np import dpnp import pickle x = dpnp.array( np.sqrt(np.arange(10)).astype(np.float32), device="gpu", ) pickle.dumps(x) ``` ``` File <stringsource>:2, in dpctl.tensor._usmarray.usm_ndarray.__reduce_cython__() TypeError: no default __reduce__ due to non-trivial __cinit__ ```
Activity
ndgrigorian commentedon Apr 30, 2026
The problem here is that
usm_ndarrayis not pickleable becausedpctl.SyclQueueis not pickleablePrevious issues about this:
IntelPython/dpctl#1206
IntelPython/dpctl#1716
In theory, this could maybe, be changed, or at least investigated again