Skip to content

Train and run neural networks on any GPU

MuNet is a deep learning framework built on Vulkan. The same code trains and runs models on AMD, Intel, NVIDIA, Apple and Android GPUs, with no CUDA or ROCm. Use the PyTorch-style API, or import ONNX and PyTorch models and run them in fp16, int8 or int4.

Get started Run an ONNX model GitHub
# pip install munet-nn from munet.interop import from_onnx model = from_onnx("yolo11n.onnx", precision="fp16", input_shapes={"images": (1, 3, 640, 640)}) out = model(image) # on whichever GPU you have # or train, PyTorch style @mu.compile # the whole step is one GPU program def train_step(x, y): loss = mu.nn.functional.cross_entropy(model(x), y) loss.backward() optimizer.step()
5GPU makers: AMD, Intel, NVIDIA, Apple, Qualcomm / Arm
0CUDA, ROCm or vendor SDKs needed: just a Vulkan driver
fp32 → int4precisions, with kernels autotuned for your GPU
4languages: Python, C, C++ and Rust

How it works

Your model

  • PyTorch-style Python training
  • ONNX and PyTorch import, int4 / int8 models included
  • C and C++ API
  • Rust crate
  • Android (JNI)
→

MuNet compiler

  • Fuses the graph into one GPU program
  • Autotunes kernels for your GPU
  • fp32, fp16, bf16, int8, int4
  • Uses tensor / matrix cores where present
  • Multi-GPU and multi-machine training
→

Any Vulkan GPU

  • AMD Radeon
  • Intel Arc and integrated
  • NVIDIA GeForce and RTX
  • Apple Silicon (MoltenVK)
  • Android: Adreno, Mali

Performance

Same model, two GPU vendors

fp16 GPU time per image in milliseconds. Lower is better.

YOLO11n
1.2
1.6
RT-DETR R18
4.0
4.4
DINOv2-S
1.2
2.3
Depth Anything v2 S
7.0
12.3
MobileSAM encoder
9.2
8.0
MODNet
4.7
4.3
NVIDIA RTX 3060 Intel Arc B580

fp16 speed-up over fp32

fp32 GPU time divided by fp16 GPU time. Higher is better.

YOLO11n
2.6×
2.7×
RT-DETR R18
4.0×
4.1×
DINOv2-S
4.4×
2.2×
Depth Anything v2 S
5.5×
3.1×
MobileSAM encoder
2.9×
3.0×
MODNet
2.6×
4.5×
NVIDIA RTX 3060 Intel Arc B580

Batch 1, minimum GPU time over 20 runs, MuNet 0.12.0, November 2026. Every charted result matches ONNX Runtime within the bench suite's tolerances. Run the suite on your own GPUs to compare.

Documentation

Guides

I want to... Guide
Install MuNet and check my GPU Install
Train a model (loop, losses, optimizers, schedules, checkpoints, precision) Training
Load training data (datasets, augmentation, workers, prefetch, sharding) Data loading
Train on several GPUs, including different sizes and vendors Multiple GPUs
Train across machines with nodes that join and leave Training pool
Import / export ONNX, import PyTorch ONNX
Make inference fast (precision, autotuning, batching, measuring) Inference and performance
Quantize (int8 convolutions, int8 / int4 linear layers, pre-quantized ONNX) Quantization
Configure NVIDIA, Intel, AMD, mobile GPUs and containers GPU vendors
Report how MuNet runs on my GPU (munet.diagnose) Hardware report
Deploy from C or C++ C and C++
Add MuNet to an Android app Android
Deploy from Rust Rust crate
Detect objects in video without copies (frame pipeline, FFmpeg, Vulkan interop) Zero copy and video
Look up an environment variable Environment variables
Fix an error Troubleshooting
Look up a Python function Python API

Examples

Example Shows
examples/python/train_classifier.py data loader, training, evaluation, LR schedule, checkpoint/resume, export to .mnet + ONNX
examples/python/train_multi_gpu.py DataParallel over all GPUs, split="auto" / "memory", max_rows
examples/python/infer_onnx.py any ONNX model: run, time, compare with ONNX Runtime, save .mnet
examples/python/detect_yolo.py YOLO detection end to end (letterbox, NMS, drawing)
examples/python/quantize_int8.py int8 calibration, accuracy and speed vs fp16
examples/python/infer_multi_gpu.py batch inference on every GPU from a shared queue
examples/c/run_model.cpp C/C++: load and run a .mnet
rust/examples/detect_frame.rs Rust: NV12 frames → detections on the GPU, tiled
examples/c/vulkan_interop.cpp zero copy with your own Vulkan code
examples/bench correctness and speed of ~40 public models on your GPUs, vs ONNX Runtime and TensorRT

Reference