Skip to main content

Organize Machine Learning Experiments

Project description

Organize machine learning experiments and monitor training progress and hardware usage from mobile.

PyPI - Python Version PyPI Status Join Slack Docs Twitter

🔥 Features

  • Monitor running experiments from mobile phone View Run
  • Monitor hardware usage on any computer with a single command
  • Integrate with just 2 lines of code (see examples below)
  • Keeps track of experiments including infomation like git commit, configurations and hyper-parameters
  • Keep Tensorboard logs organized
  • Dashboard to locally browse and manage experiment runs
  • Save and load checkpoints
  • API for custom visualizations Open In Colab Open In Colab
  • Pretty logs of training progress
  • Open source! we also have a small hosted server for the mobile web app


You can install this package using PIP.

pip install labml

PyTorch example

from labml import tracker, experiment

with experiment.record(name='sample', exp_conf=conf):
    for i in range(50):
        loss, accuracy = train(), {'loss': loss, 'accuracy': accuracy})

PyTorch Lightning example

from labml import experiment
from labml.utils.lightning import LabMLLightningLogger

trainer = pl.Trainer(gpus=1, max_epochs=5, progress_bar_refresh_rate=20, logger=LabMLLightningLogger())

with experiment.record(name='sample', exp_conf=conf, disable_screen=True):, data_loader)

TensorFlow 2.X Keras example

from labml import experiment
from labml.utils.keras import LabMLKerasCallback

with experiment.record(name='sample', exp_conf=conf):
    for i in range(50):, y_train, epochs=conf['epochs'], validation_data=(x_test, y_test),
                  callbacks=[LabMLKerasCallback()], verbose=None)

Monitoring hardware usage

pip install labml psutil py3nvml
labml monitor

📚 Documentation

🖥 Screenshots


Dashboard Screenshot

Formatted training loop output

Sample Logs

Custom visualizations based on Tensorboard logs



💬 Slack workspace for discussions

📗 Documentation

👨‍🏫 Samples

Citing LabML

If you use LabML for academic research, please cite the library using the following BibTeX entry.

 author = {Varuna Jayasiri, Nipun Wijerathne},
 title = { A library to organize machine learning experiments},
 year = {2020},
 url = {},

Release history Release notifications | RSS feed

Download files

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

Files for labml, version 0.4.116
Filename, size File type Python version Upload date Hashes
Filename, size labml-0.4.116-py3-none-any.whl (109.0 kB) File type Wheel Python version py3 Upload date Hashes View
Filename, size labml-0.4.116.tar.gz (73.6 kB) File type Source Python version None Upload date Hashes View

Supported by

AWS AWS Cloud computing Datadog Datadog Monitoring DigiCert DigiCert EV certificate Facebook / Instagram Facebook / Instagram PSF Sponsor Fastly Fastly CDN Google Google Object Storage and Download Analytics Pingdom Pingdom Monitoring Salesforce Salesforce PSF Sponsor Sentry Sentry Error logging StatusPage StatusPage Status page