layerpool
pypi.org- Category
- AI Tools
- Rank
- No. 4820Tools index
- Type
- TOOL
- Use case
- Models: Train & Run
- Date
About
layerpool splits one model by layers across several machines, including NVIDIA GPUs, Apple Silicon and CPUs, so their memory is pooled for training with existing training code. Devices keep checkpoints, and if one drops out the others take over its layers and redo lost steps. Devices outside the local network can join through a tunnel with a token on each connection.
At a glance
layerpool is an MIT-licensed Python package that splits one model's layers across several of your machines so their memory adds up and they train it together. Your computer runs the training script and keeps the embeddings and output head; the other devices hold consecutive blocks and pass activations and gradients along. It is alpha software at version 0.1.2.
Good fit
Someone who wants to fine-tune a Hugging Face transformers model that does not fit on any one of their machines, using a mix of NVIDIA GPUs, Apple Silicon Macs and plain CPUs. It wraps the Trainer and TRL's SFT, DPO and KTO trainers, and also supports LoRA, QLoRA, full fine-tuning and a no-code layerpool train command.
Consider something else when
Your model already fits on one GPU. Devices exchange activations every step, so the project says it runs slower than a single GPU holding the whole model. Also skip it for image generation or convolutional vision models, models that need trust_remote_code, or repos without .safetensors weights, which are listed as unsupported.
Start here
Run pip install layerpool and layerpool up on your main computer; the dashboard opens with that machine as the first device. Click Add device and run the layerpool join command it gives you on each other machine. Before training, layerpool plan <model> reports whether the model fits your devices and how it would be split.
Cost and requirements
Free under MIT. Needs Python 3.11 or newer on Linux, Windows or an Apple Silicon Mac. Windows NVIDIA machines need the CUDA build of PyTorch and AMD machines the ROCm build installed first. Gated models need a Hugging Face login on every device, since each downloads its own layers. Devices outside your network join through a Cloudflare tunnel.
Limits to know
Network speed often sets the pace: the README's example of QLoRA on Qwen3-8B across a MacBook, a cloud T4 and a Kaggle notebook ran at about 75 tokens per second. Blocks on remote devices run without dropout. Traffic on your local network is not encrypted, and each device runs part of the model, so add and join only devices you trust. Using Colab or Kaggle this way may break their terms.
Sources checked 2026-11-25. Source-based assessment.
Similar tools
Tags
Editorially curated, with community endorsements as a secondary signal. Corrections welcome.