Skip to content

Commit be09f94

Browse files
committed
Use dpnp.copy instead of copy method in nan_to_num
1 parent b730d1f commit be09f94

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

dpnp/dpnp_iface_mathematical.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3128,7 +3128,7 @@ def nan_to_num(x, copy=True, nan=0.0, posinf=None, neginf=None):
31283128
x_type = x.dtype.type
31293129

31303130
if not issubclass(x_type, dpnp.inexact):
3131-
return x.copy() if copy else x
3131+
return dpnp.copy(x) if copy else x
31323132

31333133
max_f, min_f = _get_max_min(x.real.dtype)
31343134
if posinf is not None:

0 commit comments

Comments
 (0)