B
tracel-ai/burn★ 16,395 · Rust
Rust tensor framework for shared training and inference code across CPU and GPU backends
Apache-2.0 · Commercial Friendlyv0.22.1
Side-by-side 2026 comparison in LLMs & Inference: huggingface/candle leads both total GitHub adoption (★ 21.5k) and recent 7-day momentum. Licensing: Apache-2.0 · Commercial Friendly vs Apache-2.0 · Commercial Friendly.
Rust tensor framework for shared training and inference code across CPU and GPU backends
Rust ML SDK for embedding local model inference without a Python runtime
Backed by independent 6-hour D1 snapshots. Embed in GitHub READMEs or technical blogs.
| Dimension | tracel-ai/burn | huggingface/candle |
|---|---|---|
| Total GitHub Stars | ★ 16,395 | ★ 21,505 |
| 24h / 7d Velocity | +7 / +39 | +21 / +81 |
| 7-Day Trend Curve | ||
| Engineering Health | A+ · 94/100 | A+ · 88/100 |
| Deployment Signals | GPU | Local AI · GPU |
| Primary Language | Rust | Rust |
| Commercial License | Apache-2.0 · Commercial Friendly | Apache-2.0 · Commercial Friendly |
| Activity | Updated today | Updated today |
| Latest Release | v0.22.1 | Rolling commits (main) |
| Best For | Rust products that embed models, share forward code between training and inference, or ship the same model across GPU, CPU, and Wasm targets | Rust teams embedding a supported model into a local tool, application, or inference worker, especially when avoiding Python and LibTorch matters and the team can validate the target backend |
use burn::tensor::{Device, Distribution, Tensor}; fn main() { let device = Device::wgpu(Default::default()).autodiff(); let x: Tensor<2> = Tensor::random([32, 32], Distribution::Default, &device); let y: Tensor<2> = Tensor::random([32, 32], Distribution::Default, &device).require_grad(); let tmp = x.clone() + y.clone(); let tmp = tmp.matmul(x); let tmp = tmp.exp(); let grads = tmp.backward(); let y_grad = y.grad(&grads).unwrap(); println!("{y_grad}"); }
candle-core owns tensors and devices, candle-nn supplies neural-network building blocks, and candle-transformers houses model code.candle-kernels, candle-metal-kernels, and separate FlashAttention and FlashAttention v3 directories; FlashAttention v2 is the concrete integration example.cargo run --example quantized --release
Signal-only digest of fast-growing AI repos, SPDX license alerts, and architecture picks. Zero spam.
Zero spam · 1-click unsubscribe · Privacy Policy