Skip to content

Commit 3648ef5

Browse files
authored
Merge 65aa671 into 27051e5
2 parents 27051e5 + 65aa671 commit 3648ef5

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

dpnp/dpnp_utils/dpnp_algo_utils.pyx

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -76,9 +76,9 @@ cdef ERROR_PREFIX = "DPNP error:"
7676

7777

7878
def convert_item(item):
79-
if getattr(item, "__sycl_usm_array_interface__", False):
79+
if hasattr(item, "__sycl_usm_array_interface__"):
8080
item_converted = dpnp.asnumpy(item)
81-
elif getattr(item, "__array_interface__", False): # detect if it is a container (TODO any better way?)
81+
elif hasattr(item, "__array_interface__"): # detect if it is a container (TODO any better way?)
8282
mod_name = getattr(item, "__module__", 'none')
8383
if (mod_name != 'numpy'):
8484
item_converted = dpnp.asnumpy(item)

0 commit comments

Comments
 (0)