Skip to content

Commit

Permalink
fix numpy v2
Browse files Browse the repository at this point in the history
  • Loading branch information
hanjinliu committed May 31, 2024
1 parent 90efea3 commit 4e9fb75
Showing 1 changed file with 5 additions and 2 deletions.
7 changes: 5 additions & 2 deletions impy/core.py
Original file line number Diff line number Diff line change
Expand Up @@ -121,8 +121,11 @@ def array(
dtype = arr.dtype

axes, name = _normalize_params(axes, name, like)

_arr = np.array(arr, dtype=dtype, copy=copy)

if copy:
_arr = np.array(arr, dtype=dtype)
else:
_arr = np.asarray(arr, dtype=dtype)

# Automatically determine axes
if axes is None:
Expand Down

0 comments on commit 4e9fb75

Please sign in to comment.