mirror of
https://github.com/priyanshujain/torchmlx.git
synced 2026-10-02 11:07:13 +00:00
build torchmlx
This commit is contained in:
commit
b0ef50eec2
15 files changed
+2008
No files matched your search
@@ -0,0 +1,15 @@
|
||||
# TorchMLX
|
||||
|
||||
TorchMLX is a PyTorch-shaped compatibility layer that uses MLX on Apple silicon and PyTorch elsewhere.
|
||||
|
||||
It is experimental and targets transformer inference and training without per-operation backend fallback.
|
||||
|
||||
```python
|
||||
import torchmlx as torch
|
||||
from torchmlx import nn, optim
|
||||
|
||||
model = nn.Linear(4, 2)
|
||||
optimizer = optim.AdamW(model.parameters(), lr=3e-4)
|
||||
```
|
||||
|
||||
See the [TinyStories example](examples/tinystories-llm/train.py) and [compatibility details](docs/compatibility.md).
|
||||
Reference in new issue
Block a user