File tree Expand file tree Collapse file tree 1 file changed +32
-2
lines changed Expand file tree Collapse file tree 1 file changed +32
-2
lines changed Original file line number Diff line number Diff line change 1
- # numpy-array-api-compat
2
- Compatibility layer for NumPy to support the Array API
1
+ # NumPy Array API compatibility library
2
+
3
+ This is a small wrapper around NumPy that is compatible with the [ Array API
4
+ standard] ( https://data-apis.org/array-api/latest/ ) . See also [ NEP 47] ( https://numpy.org/neps/nep-0047-array-api-standard.html ) .
5
+
6
+ Unlike ` numpy.array_api ` , this is not a strict minimal implementation of the
7
+ Array API, but rather just an extension of the main NumPy namespace with
8
+ changes needed to be compliant with the Array API. See
9
+ https://numpy.org/doc/stable/reference/array_api.html for a full list of
10
+ changes. In particular, unlike ` numpy.array_api ` , this package does not use a
11
+ separate Array object, but rather just uses ` numpy.ndarray ` directly.
12
+
13
+ Note that some of the functionality in this library is backwards incompatible
14
+ with NumPy.
15
+
16
+ Library authors using the Array API may wish to test against ` numpy.array_api `
17
+ to ensure they are not using functionality outside of the standard, but prefer
18
+ this implementation for end users who use NumPy arrays.
19
+
20
+ ## Usage
21
+
22
+ To use this library replace
23
+
24
+ ``` py
25
+ import numpy as np
26
+ ```
27
+
28
+ with
29
+
30
+ ``` py
31
+ import numpy_array_api_compat as np
32
+ ```
You can’t perform that action at this time.
0 commit comments