Byzantine-robust distributed learning with a unified actor runtime, computation-graph scheduler, and batteries-included aggregators/attacks.
- 🔐 Byzantine robustness built-in – drop-in aggregators (Krum, MDA, trimmed mean, etc.) and attack simulators.
- 🎛️ Unified actor runtime – threads, processes, GPUs, TCP/UCX remotes share a single channel abstraction.
- 🧭 Declarative computation graphs – author heterogeneous pipelines while keeping scheduling deterministic.
- 📚 Full docs & CLI – Sphinx site,
byzpyhelper CLI, and contributor-friendly guides.
pip install byzpy # CPU baseline
pip install "byzpy[gpu]" # add CUDA/UCX extras
pip install "byzpy[dev]" # tooling: pytest, coverage, etc.git clone https://github.com/Byzpy/byzpy.git
cd byzpy
python -m venv .venv && source .venv/bin/activate # Windows: .venv\Scripts\activate
pip install -e python[dev]
pip install -e python[gpu] # optional CUDA extras# Parameter server, threaded workers
python examples/ps/thread/mnist.py
# Peer-to-peer UCX demo (server + workers)
python examples/p2p/heterogeneous/server.py &
python examples/p2p/heterogeneous/mnist.pybyzpy version # installed version
byzpy doctor --format json # env + CUDA/UCX status
byzpy list aggregators # discover built-ins| Path | Description |
|---|---|
python/byzpy |
Core library (actors, graphs, aggregators, attacks, nodes). |
examples/ |
Parameter-server (ps) and peer-to-peer (p2p) demos with remote/GPU variants. |
benchmarks/ |
ActorPool + aggregator benchmarks plus plotting helpers. |
docs/ |
Sphinx source for the full documentation site. |
.github/workflows/ |
CI for tests, wheel smoke-tests, publishing, and coverage reporting. |
- Editable installs + full pytest suite run on every push/PR (
.github/workflows/tests.yml). - Wheel smoke-tests ensure
python -m buildartifacts install cleanly before release. - Coverage is uploaded to Codecov and surfaced via the badge above. To refresh locally:
cd python pytest --cov=byzpy --cov-report=term-missing
📖 Full documentation is available at byzpy.github.io/byzpy/
Build the docs locally:
pip install -r docs/requirements.txt
sphinx-build -b html docs/source docs/_build/htmlWe love community contributions!
- Fork + branch.
- Implement your change (tests + docs).
- Run
pytestandsphinx-build. - Open a PR with a concise summary + test output.
See CONTRIBUTING.md, CODE_OF_CONDUCT.md, and SECURITY.md for the full details. Releases are tracked in CHANGELOG.md and published via .github/workflows/publish.yml.