Skip to main content

Lightweight Distributed ML Experiments Management 🛠️

Pyversions Docs Latest PyPI version Code style: black Status codecov Colab

Coming up with the right hypothesis is hard - testing it should be easy.

ML researchers need to coordinate different types of experiments on separate remote resources. The Machine Learning Experiment (MLE)-Toolbox is designed to facilitate the workflow by providing a simple interface, standardized logging, many common ML experiment types (multi-seed/configurations, grid-searches and hyperparameter optimization pipelines). You can run experiments on your local machine, high-performance compute clusters (Slurm and Sun Grid Engine) as well as on cloud VMs (GCP). The results are archived (locally/GCS bucket) and can easily be retrieved or automatically summarized/reported.


What Does The mle-toolbox Provide? 🧑‍🔧

  1. API for launching jobs on cluster/cloud computing platforms (Slurm, GridEngine, GCP).
  2. Common machine learning research experiment setups:
    • Launching and collecting multiple random seeds in parallel/batches or async.
    • Hyperparameter searches: Random, Grid, SMBO, PBT, Nevergrad, etc.
    • Pre- and post-processing pipelines for data preparation/result visualization.
  3. Automated report generation for hyperparameter search experiments.
  4. Storage/retrieval of results and database in Google Cloud Storage Bucket.
  5. Resource monitoring with dashboard visualization.


The 4 Step mle-toolbox Cooking Recipe 🍲

  1. Follow the instructions below to install the mle-toolbox and set up your credentials/configuration.
  2. Learn more about the individual infrastructure subpackages with the dedicated tutorial.
  3. Read the docs explaining the pillars of the toolbox & the experiment meta-configuration job .yaml files .
  4. Check out the example workflows 📄 to get started.
  5. Run your own experiment using the template files/project and mle run.

Installation ⏳

If you want to use the toolbox on your local machine follow the instructions locally. Otherwise do so on your respective cluster resource (Slurm/SGE). A PyPI installation is available via:

pip install mle-toolbox

If you want to get the most recent commit, please install directly from the repository:

pip install git+https://github.com/mle-infrastructure/mle-toolbox.git@main

The Core Toolbox Subcommands 🌱

You are now ready to dive deeper into the specifics of experiment configuration and can start running your first experiments from the cluster (or locally on your machine) with the following commands:

Command Description
🚀 mle run Start up an experiment (multi-config/seeds, search).
🖥️ mle monitor Monitor resource utilisation (mle-monitor wrapper).
📥 mle retrieve Retrieve experiment result from GCS/cluster.
💌 mle report Create an experiment report with figures.
mle init Setup of credentials & toolbox settings.
🔄 mle sync Extract all GCS-stored results to your local drive.
🗂 mle project Initialize a new project by cloning mle-project.
📝 mle protocol List a summary of the most recent experiments.

You can find more documentation for each subcommand here.

Examples 📄 & Notebook Walkthroughs 📓

Job Types Description
📄 Single-Objective multi-configs, hyperparameter-search Core experiment types.
📄 Multi-Objective hyperparameter-search Multi-objective tuning.
📄 Multi Bash multi-configs Bash-based jobs.
📄 Quadratic PBT hyperparameter-search PBT on toy quadratic surrogate.
📄 Hyperband hyperparameter-search Hyperband on toy polynomial problem.
Description Colab
📓 Getting Started Get started with the toolbox. Colab
📓 Subpackages Get started with the toolbox subpackages. Colab
📓 MLExperiment Introduction to MLExperiment wrapper. Colab
📓 Evaluation Evaluation of gridsearch results. Colab
📓 GIF Animations Walk through a set of animation helpers. Colab
📓 Testing Perform hypothesis tests on logs. Colab

Acknowledgements & Citing the MLE-Infrastructure ✏️

If you use parts the mle-toolbox in your research, please cite it as follows:

@software{mle_infrastructure2021github,
  author = {Robert Tjarko Lange},
  title = {{MLE-Infrastructure}: A Set of Lightweight Tools for Distributed Machine Learning Experimentation},
  url = {http://github.com/mle-infrastructure},
  year = {2021},
}

Development 👷

You can run the test suite via python -m pytest -vv tests/. If you find a bug or are missing your favourite feature, feel free to create an issue and/or start contributing 🤗.

Release files for mle-toolbox 0.3.5

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for mle-toolbox 0.3.5
File Size Uploaded
mle_toolbox-0.3.5.tar.gz 56.8 kB Details

Built distribution (wheel)

Table of built distributions (wheels) for mle-toolbox 0.3.5
File Interpreter ABI Platform
mle_toolbox-0.3.5-py3-none-any.whl Python 3 none any Details

Total release size: 127.4 kB

Release files / mle_toolbox-0.3.5.tar.gz

Download URL mle_toolbox-0.3.5.tar.gz
Size 56.8 kB
Tags Source
SHA-256 checksum
How to use checksums
cba71799d948d5ae2c566be3234c7622e8efe1d58e6c28004e83dc50c6e2476b
BLAKE2b-256 checksum
How to use checksums
940c6815f7d238193e47a0cd369453fb3bc9471bed2770c27993241156d14cf0
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/5.1.1 CPython/3.12.5

Release files / mle_toolbox-0.3.5-py3-none-any.whl

Download URL mle_toolbox-0.3.5-py3-none-any.whl
Size 70.6 kB
Tags Python 3
SHA-256 checksum
How to use checksums
236a0f14dde7627504086dcb6ba6865c5252c30c8c7544a30fd2018764160dfc
BLAKE2b-256 checksum
How to use checksums
86bcf2ee3323b274a1fbd43822f8b010a17fece3aa5aeb8e5ea21effec7b5f34
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/5.1.1 CPython/3.12.5

Release history Release notifications | RSS feed

This release

0.3.5 This release

2 release files

0.3.4

2 release files

0.3.3

2 release files

0.3.2

2 release files

0.3.1

2 release files

0.3.0

2 release files

0.2.9

2 release files

0.2.8

2 release files

0.2.7

2 release files

0.2.6

2 release files

0.2.5

2 release files

0.2.4

2 release files

0.2.3

2 release files

0.2.2

2 release files

0.2.1

2 release files

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page