#onnx #metal #tensorflow #neural-network

tract-metal

Tiny, no-nonsense, self contained, TensorFlow and ONNX inference

8 releases

Uses new Rust 2024

0.22.0 Aug 26, 2025
0.21.13 May 15, 2025
0.21.12 Apr 10, 2025
0.21.11 Mar 19, 2025
0.21.7 Sep 23, 2024

#1969 in Machine learning

Download history 119/week @ 2025-07-09 58/week @ 2025-07-16 187/week @ 2025-07-23 59/week @ 2025-07-30 39/week @ 2025-08-06 74/week @ 2025-08-13 78/week @ 2025-08-20 94/week @ 2025-08-27 113/week @ 2025-09-03 27/week @ 2025-09-10 59/week @ 2025-09-17 22/week @ 2025-09-24 73/week @ 2025-10-01 9/week @ 2025-10-08 22/week @ 2025-10-15 33/week @ 2025-10-22

139 downloads per month
Used in 4 crates (2 directly)

MIT/Apache

1.5MB
42K SLoC

tract-metal

Updating Metal Flash Attention library

git clone https://github.com/philipturner/metal-flash-attention.git
cd metal-flash-attention

# for iOS
swift build.swift --platform iOS --xcode-path /Applications/Xcode.app
cp build/lib/libMetalFlashAttention.metallib path/to/tract/metal/src/kernels/libMetalFlashAttention-ios.metallib

# for MacOS
swift build.swift --platform macOS --xcode-path /Applications/Xcode.app
cp build/lib/libMetalFlashAttention.metallib path/to/tract/metal/src/kernels/libMetalFlashAttention-macos.metallib

Dependencies

~20–35MB
~480K SLoC