Skip to main content

Config-driven PyTorch training framework: assemble nets, data, losses and trainers from YAML

Project description

echelon3

Config-driven PyTorch training framework. Every component of a training run — network, dataset, augmentations, losses, metrics, optimizer, scheduler, trainer, export — is described in a YAML config as a module / type / config triple and instantiated dynamically:

net:
  module: echelon3.nets.classifier   # import path (or a path to a .py file)
  type: ClassifierNet                # class or factory function in that module
  config: { ... }                    # constructor kwargs

There is no component registry: anything importable can be plugged in — classes from echelon3, from torch/timm/torchmetrics/albumentations, or from your own project code living next to your configs.

Documentation: https://veryviolet.github.io/echelon3/

Install

pip install echelon3

Train

echelon3-train --config-dir ./configs --config-name my_experiment

CLIs: echelon3-train, echelon3-finetune (warm-start / freeze / head-only), echelon3-evaluate, echelon3-run (inference), echelon3-export (ONNX).

Multi-GPU — built in, no torchrun

Name the GPUs and echelon3 spawns one DDP worker per GPU itself:

echelon3-train --config-dir ./configs --config-name my_experiment gpus=[0,1,2,3]

gpus is a root config key — leave it out and echelon3 uses every visible GPU on the node. dataloaders.train.config.batch_size is the global batch size; it is split across ranks automatically. torchrun (and SLURM srun) still work unchanged for multi-node / elastic jobs.

DataParallel was removed in 0.5.0 — multiple GPUs always run as DDP.

Mixed precision

Training, evaluation and inference use bf16 automatic mixed precision by default on capable GPUs (fp32 on CPU / unsupported GPUs) — a large speedup on modern hardware. Force full fp32 with precision: fp32 under trainer.config (or precision: fp32 at the config root for evaluate / run).

Quick start

examples/ has self-contained smoke runs — a classifier, a CenterNet-style detector and semantic segmentation — each with a synthetic-data generator and a minimal config that trains, validates and checkpoints on CPU or GPU.

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

echelon3-0.6.0.tar.gz (118.5 kB view details)

Uploaded Source

Built Distribution

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

echelon3-0.6.0-py3-none-any.whl (124.7 kB view details)

Uploaded Python 3

File details

Details for the file echelon3-0.6.0.tar.gz.

File metadata

  • Download URL: echelon3-0.6.0.tar.gz
  • Upload date:
  • Size: 118.5 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/6.1.0 CPython/3.13.12

File hashes

Hashes for echelon3-0.6.0.tar.gz
Algorithm Hash digest
SHA256 cf190ddd3c6b7d35bd0781d0e16cddf5b85ac796bc3dab1170587aef4e40745a
MD5 629b637c3397318e291d26b0f9c2767f
BLAKE2b-256 c273a25c16eb4bc5e7e4772875a8f704d3f3512bdd47fabeb6de3e75be87dcf0

See more details on using hashes here.

Provenance

The following attestation bundles were made for echelon3-0.6.0.tar.gz:

Publisher: publish.yml on veryviolet/echelon3

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

File details

Details for the file echelon3-0.6.0-py3-none-any.whl.

File metadata

  • Download URL: echelon3-0.6.0-py3-none-any.whl
  • Upload date:
  • Size: 124.7 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/6.1.0 CPython/3.13.12

File hashes

Hashes for echelon3-0.6.0-py3-none-any.whl
Algorithm Hash digest
SHA256 2d918ecc3ec22490c09bc4963c09f59ab2205a23aac4dd119ead4535e196d6b4
MD5 d0ba3c6afb79b1f986c88006aad231d3
BLAKE2b-256 a2f97b38e54bfde65388907870377e73ef467416ae952b56a9cf7f9896ef6198

See more details on using hashes here.

Provenance

The following attestation bundles were made for echelon3-0.6.0-py3-none-any.whl:

Publisher: publish.yml on veryviolet/echelon3

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

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