Skip to content

Commit a3eb12d

Browse files
Fixed type inferencing for nest sequences with no elements
Fixed #696 ```python In [3]: import dpctl.tensor as dpt In [4]: dpt.asarray( [[],]*2) Out[4]: <dpctl.tensor._usmarray.usm_ndarray at 0x7fe5c92a8450> In [5]: Out[4].dtype Out[5]: dtype('float64') ```
1 parent d9cfb43 commit a3eb12d

File tree

1 file changed

+1
-0
lines changed

1 file changed

+1
-0
lines changed

dpctl/tensor/_ctors.py

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -67,6 +67,7 @@ def _array_info_sequence(li):
6767
)
6868
if dim is None:
6969
dim = tuple()
70+
dt = float
7071
device = _host_set
7172
return (n,) + dim, dt, device
7273

0 commit comments

Comments
 (0)