@@ -49,7 +49,7 @@ def take(self, X, indices, *, axis):
49
49
return self ._namespace .stack (selected , axis = axis )
50
50
51
51
52
- class _NumPyApiWrapper :
52
+ class _NumPyAPIWrapper :
53
53
"""Array API compat wrapper for any numpy version
54
54
55
55
NumPy < 1.22 does not expose the numpy.array_api namespace. This
@@ -98,7 +98,7 @@ def get_namespace(*arrays):
98
98
See: https://numpy.org/neps/nep-0047-array-api-standard.html
99
99
100
100
If `arrays` are regular numpy arrays, an instance of the
101
- `_NumPyApiWrapper ` compatibility wrapper is returned instead.
101
+ `_NumPyAPIWrapper ` compatibility wrapper is returned instead.
102
102
103
103
Namespace support is not enabled by default. To enabled it
104
104
call:
@@ -110,7 +110,7 @@ def get_namespace(*arrays):
110
110
with sklearn.config_context(array_api_dispatch=True):
111
111
# your code here
112
112
113
- Otherwise an instance of the `_NumPyApiWrapper `
113
+ Otherwise an instance of the `_NumPyAPIWrapper `
114
114
compatibility wrapper is always returned irrespective of
115
115
the fact that arrays implement the `__array_namespace__`
116
116
protocol or not.
@@ -133,7 +133,7 @@ def get_namespace(*arrays):
133
133
# Returns a tuple: (array_namespace, is_array_api)
134
134
135
135
if not get_config ()["array_api_dispatch" ]:
136
- return _NumPyApiWrapper (), False
136
+ return _NumPyAPIWrapper (), False
137
137
138
138
namespaces = {
139
139
x .__array_namespace__ () if hasattr (x , "__array_namespace__" ) else None
@@ -152,7 +152,7 @@ def get_namespace(*arrays):
152
152
(xp ,) = namespaces
153
153
if xp is None :
154
154
# Use numpy as default
155
- return _NumPyApiWrapper (), False
155
+ return _NumPyAPIWrapper (), False
156
156
157
157
return _ArrayAPIWrapper (xp ), True
158
158
0 commit comments