Skip to main content

Experience pipeline parallelism on your laptop. Naive, GPipe, 1F1B — one command.

Project description

pipenaut

Experience pipeline parallelism on your laptop. Naive, GPipe, 1F1B — one command.

No GPUs needed. No cluster setup. Just pip install and run.

Quick Start

pip install pipenaut

# Compare all 3 pipeline schedules
pipenaut compare --workers 4

# Run a single schedule
pipenaut run --schedule 1f1b --workers 4 --steps 20

# Learn about a schedule
pipenaut explain 1f1b

What is this?

Pipeline parallelism splits a neural network across multiple devices (or processes), with each device running one "stage" of the model. Data flows through the pipeline like an assembly line.

pipenaut lets you experience 3 classic pipeline schedules on your local CPU:

Schedule Strategy Bubble Overhead
Naive Forward all → Backward all (sequential) ~75%
GPipe Forward all chunks → Backward all chunks ~43%
1F1B Interleave forward and backward ~19%

Commands

pipenaut compare

Runs all 3 schedules and prints a side-by-side comparison with pipeline timelines and a results table.

pipenaut run

Run a single schedule with detailed output.

Flag Default Description
--schedule, -s 1f1b Schedule: naive, gpipe, 1f1b
--workers, -w 4 Number of pipeline stages
--steps 30 Training steps
--chunks, -c 8 Micro-batches
--batch-size 32 Batch size
--dim 128 Hidden dimension
--layers 16 Total model layers

pipenaut explain

Learn how a schedule works with ASCII diagrams and explanations.

pipenaut explain naive
pipenaut explain gpipe
pipenaut explain 1f1b

Requirements

  • Python >= 3.10
  • PyTorch >= 2.0
  • Works on macOS, Linux, and Windows
  • CPU only (CUDA used automatically if available)

License

MIT

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

pipenaut-0.1.0.tar.gz (13.1 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

pipenaut-0.1.0-py3-none-any.whl (18.2 kB view details)

Uploaded Python 3

File details

Details for the file pipenaut-0.1.0.tar.gz.

File metadata

  • Download URL: pipenaut-0.1.0.tar.gz
  • Upload date:
  • Size: 13.1 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.2.0 CPython/3.12.4

File hashes

Hashes for pipenaut-0.1.0.tar.gz
Algorithm Hash digest
SHA256 6a712bc52ca00cb686287df2442de3b775bc77ff21ed440ad473607bc87224e7
MD5 7b7756987f15e14e4d0787bc4d8bf3f1
BLAKE2b-256 5bc6a0473c9c2aff2ab88b66ee8ab78ba70d05ff89ec3d0436366ac2c6c347f8

See more details on using hashes here.

File details

Details for the file pipenaut-0.1.0-py3-none-any.whl.

File metadata

  • Download URL: pipenaut-0.1.0-py3-none-any.whl
  • Upload date:
  • Size: 18.2 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.2.0 CPython/3.12.4

File hashes

Hashes for pipenaut-0.1.0-py3-none-any.whl
Algorithm Hash digest
SHA256 77e2a6d9d5104194d97be5b63e1161d89ad082ee790bf2785b2bdd4361e2b1d6
MD5 898ea1054a86fef9c7a945854f24448e
BLAKE2b-256 99e885a3fa8db5483beaf1fe03ea8ff6857468c9d68eb288584524ef9fdc833d

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page