Convert ONNX models into MLX callables for inference on Apple Silicon.
Project description
onnx2mlx
Convert ONNX models into MLX callables for accelerating inference on Apple Silicon.
Setup Instructions
Open a terminal and run the following command:
# Install onnx2mlx
$ pip install --upgrade onnx2mlx
Converting from ONNX to MLX
Use the onnx2mlx function to create a callable that uses MLX to run the model:
import mlx.core as mx
import onnx
from onnx2mlx import onnx2mlx
# Load an ONNX model
model = onnx.load("model.onnx")
# Convert to MLX
model_mlx = onnx2mlx(onnx_model)
# Run the MLX model
outputs = model_mlx(mx.array(...))
Useful Links
- Join our Slack community.
- Check out the docs.
- Read our blog.
- Reach out to us at hi@muna.ai.
Project details
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file onnx2mlx-0.0.1.tar.gz.
File metadata
- Download URL: onnx2mlx-0.0.1.tar.gz
- Upload date:
- Size: 18.2 kB
- Tags: Source
- Uploaded using Trusted Publishing? Yes
- Uploaded via: twine/6.1.0 CPython/3.13.7
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
58f777e67dc3e5e50dba0f369b3fbd794a257492fcd2031b47b1339477a2fc2c
|
|
| MD5 |
7779960d1fdada337aa786e3023972ca
|
|
| BLAKE2b-256 |
13d7369c9f0237a6453ffebe0bee0efa2ba39b673df14762869f9d7c42ca05b7
|
Provenance
The following attestation bundles were made for onnx2mlx-0.0.1.tar.gz:
Publisher:
pypi.yml on muna-ai/onnx2mlx
-
Statement:
-
Statement type:
https://in-toto.io/Statement/v1 -
Predicate type:
https://docs.pypi.org/attestations/publish/v1 -
Subject name:
onnx2mlx-0.0.1.tar.gz -
Subject digest:
58f777e67dc3e5e50dba0f369b3fbd794a257492fcd2031b47b1339477a2fc2c - Sigstore transparency entry: 1022083830
- Sigstore integration time:
-
Permalink:
muna-ai/onnx2mlx@4035a7f1a5410253292c1f628c9e975623ff838f -
Branch / Tag:
refs/tags/0.0.1 - Owner: https://github.com/muna-ai
-
Access:
public
-
Token Issuer:
https://token.actions.githubusercontent.com -
Runner Environment:
github-hosted -
Publication workflow:
pypi.yml@4035a7f1a5410253292c1f628c9e975623ff838f -
Trigger Event:
release
-
Statement type:
File details
Details for the file onnx2mlx-0.0.1-py3-none-any.whl.
File metadata
- Download URL: onnx2mlx-0.0.1-py3-none-any.whl
- Upload date:
- Size: 22.2 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? Yes
- Uploaded via: twine/6.1.0 CPython/3.13.7
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
1d6b5c4ee9e1189382096cf30bbd814f6aae8a072740d0bb0be2997ab07f49c3
|
|
| MD5 |
a64bf417f9554045acebd580eafd3ae7
|
|
| BLAKE2b-256 |
66e03091fc07c1d6091f561f44f37ea7ac159cdf654aa8b0ee7a9e629ee25f36
|
Provenance
The following attestation bundles were made for onnx2mlx-0.0.1-py3-none-any.whl:
Publisher:
pypi.yml on muna-ai/onnx2mlx
-
Statement:
-
Statement type:
https://in-toto.io/Statement/v1 -
Predicate type:
https://docs.pypi.org/attestations/publish/v1 -
Subject name:
onnx2mlx-0.0.1-py3-none-any.whl -
Subject digest:
1d6b5c4ee9e1189382096cf30bbd814f6aae8a072740d0bb0be2997ab07f49c3 - Sigstore transparency entry: 1022083901
- Sigstore integration time:
-
Permalink:
muna-ai/onnx2mlx@4035a7f1a5410253292c1f628c9e975623ff838f -
Branch / Tag:
refs/tags/0.0.1 - Owner: https://github.com/muna-ai
-
Access:
public
-
Token Issuer:
https://token.actions.githubusercontent.com -
Runner Environment:
github-hosted -
Publication workflow:
pypi.yml@4035a7f1a5410253292c1f628c9e975623ff838f -
Trigger Event:
release
-
Statement type: