You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
An example below raises ValueError exception in NumPy indicating boundary issue, but there is no exception in dpctl and RuntimeWarning regarding divide by zero is issued:
import numpy, dpctl.tensor as dpt
a = numpy.zeros((0,))
a.reshape((-1, 0))
Out:
...
ValueError: cannot reshape array of size 0 into shape (0)
a = dpt.zeros((0,))
dpt.reshape(a, (-1, 0))
/localdisk/work/antonvol/soft/miniconda3/envs/dpnp_py39_ext/lib/python3.9/site-packages/dpctl/tensor/_reshape.py:126: RuntimeWarning: divide by zero encountered in long_scalars
v = X.size // (-np.prod(shape))
Out: usm_ndarray([])