Skip to content

Commit 1d979d2

Browse files
committed
WIP for dpnp.empty_like()
1 parent 1b948c2 commit 1d979d2

File tree

2 files changed

+514
-188
lines changed

2 files changed

+514
-188
lines changed

numba_dpex/core/types/usm_ndarray_type.py

Lines changed: 14 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -33,6 +33,10 @@ def __init__(
3333
):
3434
self.usm_type = usm_type
3535
self.addrspace = addrspace
36+
print(
37+
"---> numba_dpex.core.types.usm_ndarray_type.USMNdArray.__init__():dtype =",
38+
dtype,
39+
)
3640

3741
if queue is not None and device != "unknown":
3842
if not isinstance(device, str):
@@ -73,14 +77,24 @@ def __init__(
7377
self.device = self.queue.sycl_device.filter_string
7478

7579
if not dtype:
80+
print(
81+
"---> numba_dpex.core.types.usm_ndarray_type.USMNdArray.__init__():here.1"
82+
)
7683
dummy_tensor = dpctl.tensor.empty(
7784
sh=1, order=layout, usm_type=usm_type, sycl_queue=self.queue
7885
)
7986
# convert dpnp type to numba/numpy type
8087
_dtype = dummy_tensor.dtype
8188
self.dtype = from_dtype(_dtype)
8289
else:
90+
print(
91+
"---> numba_dpex.core.types.usm_ndarray_type.USMNdArray.__init__():here.2"
92+
)
8393
self.dtype = dtype
94+
print(
95+
"---> numba_dpex.core.types.usm_ndarray_type.USMNdArray.__init__():self.dtype =",
96+
self.dtype,
97+
)
8498

8599
if name is None:
86100
type_name = "usm_ndarray"

0 commit comments

Comments
 (0)