mirror of
https://github.com/huggingface/kernels.git
synced 2025-10-20 21:10:02 +08:00
Add macOS requirements (#95)
This commit is contained in:
@ -37,8 +37,14 @@ to resolve the version constraints.
|
|||||||
## Native Python module
|
## Native Python module
|
||||||
|
|
||||||
Kernels will typically contain a native Python module with precompiled
|
Kernels will typically contain a native Python module with precompiled
|
||||||
compute kernels and bindings. This module must fulfill the following
|
compute kernels and bindings. This module must fulfill the requirements
|
||||||
requirements:
|
outlined in this section. For all operating systems, a kernel must not
|
||||||
|
have dynamic library dependencies outside:
|
||||||
|
|
||||||
|
- Torch;
|
||||||
|
- CUDA/ROCm libraries installed as dependencies of Torch.
|
||||||
|
|
||||||
|
### Linux
|
||||||
|
|
||||||
- Use [ABI3/Limited API](https://docs.python.org/3/c-api/stable.html#stable-application-binary-interface)
|
- Use [ABI3/Limited API](https://docs.python.org/3/c-api/stable.html#stable-application-binary-interface)
|
||||||
for compatibility with Python 3.9 and later.
|
for compatibility with Python 3.9 and later.
|
||||||
@ -50,12 +56,18 @@ requirements:
|
|||||||
- CXXABI 1.3.11
|
- CXXABI 1.3.11
|
||||||
- GCC 7.0.0
|
- GCC 7.0.0
|
||||||
|
|
||||||
These requirement can be checked with the ABI checker (see below).
|
These requirement can be checked with the ABI checker (see below).
|
||||||
|
|
||||||
- No dynamic library dependencies outside:
|
### macOS
|
||||||
|
|
||||||
- Torch;
|
- Use [ABI3/Limited API](https://docs.python.org/3/c-api/stable.html#stable-application-binary-interface)
|
||||||
- CUDA/ROCm libraries installed as dependencies of Torch.
|
for compatibility with Python 3.9 and later.
|
||||||
|
- macOS deployment target 15.0.
|
||||||
|
- Metal 3.0 (`-std=metal3.0`).
|
||||||
|
|
||||||
|
The ABI3 requirement can be checked with the ABI checker (see below).
|
||||||
|
|
||||||
|
### ABI checker
|
||||||
|
|
||||||
The manylinux_2_28 and Python ABI 3.9 version requirements can be checked with
|
The manylinux_2_28 and Python ABI 3.9 version requirements can be checked with
|
||||||
[`kernel-abi-check`](https://crates.io/crates/kernel-abi-check):
|
[`kernel-abi-check`](https://crates.io/crates/kernel-abi-check):
|
||||||
|
Reference in New Issue
Block a user