File tree Expand file tree Collapse file tree 1 file changed +2
-2
lines changed
array_api_compat/dask/array Expand file tree Collapse file tree 1 file changed +2
-2
lines changed Original file line number Diff line number Diff line change 5
5
6
6
from ..._internal import get_xp
7
7
8
+ from . import numpy as np_compat
8
9
from ._info import __array_namespace_info__
9
10
10
11
import numpy as np
@@ -143,7 +144,7 @@ def asarray(
143
144
144
145
# copy=None to be uniform across dask < 2024.12 and >= 2024.12
145
146
# see https://github.com/dask/dask/pull/11524/
146
- obj = np .asarray (obj , dtype = dtype , copy = True )
147
+ obj = np_compat .asarray (obj , dtype = dtype , copy = True )
147
148
return da .from_array (obj )
148
149
149
150
@@ -183,7 +184,6 @@ def _isscalar(a):
183
184
max_shape = () if _isscalar (max ) else max .shape
184
185
185
186
# TODO: This won't handle dask unknown shapes
186
- import numpy as np
187
187
result_shape = np .broadcast_shapes (x .shape , min_shape , max_shape )
188
188
189
189
if min is not None :
You can’t perform that action at this time.
0 commit comments