Skip to main content

A lightweight Python package that supplies batteries-included abstractions for PyTorch workflows

Project description

torch-batteries

PyPI version License: MIT

torch-batteries
Image generated by AI

A lightweight Python package that supplies batteries-included abstractions for:

  • Data loading pipelines
  • Model training loops
  • Evaluation workflows
  • Metrics computation
  • Experiment tracking (Weights & Biases)

Designed to reduce boilerplate and standardize experiment code.

Installation

pip install torch-batteries

Optional Dependencies

For experiment tracking with Weights & Biases:

pip install torch-batteries[wandb]

Examples

Explore practical examples demonstrating torch-batteries features:

Example Description Notebook Colab
Function Fitting with MLP Train a neural network to approximate a polynomial function using the event-driven training approach function_fitting.ipynb Open In Colab
Image Classification with CNN Train a Convolutional Neural Network (CNN) for image classification image_classification.ipynb Open In Colab
Learning Rate Sweep with Early Stopping Conduct a learning rate sweep on MNIST classification with aggressive early stopping and log results to Weights & Biases lr_sweep_early_stopping.ipynb Open In Colab

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

torch_batteries-0.5.1.tar.gz (29.5 kB view details)

Uploaded Source

Built Distribution

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

torch_batteries-0.5.1-py3-none-any.whl (38.0 kB view details)

Uploaded Python 3

File details

Details for the file torch_batteries-0.5.1.tar.gz.

File metadata

  • Download URL: torch_batteries-0.5.1.tar.gz
  • Upload date:
  • Size: 29.5 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.2.0 CPython/3.12.12

File hashes

Hashes for torch_batteries-0.5.1.tar.gz
Algorithm Hash digest
SHA256 1ea8a8fb7ecf760e2f2fcab1385b512eb8c27f550ebf2a225fcb4934a3b15571
MD5 87cd15aa0033af6d2f4ea9e2e138441b
BLAKE2b-256 1eab5af2d85e80e3cf9b7283f448b21380972df83cd27ae2d794b1aafab329c7

See more details on using hashes here.

File details

Details for the file torch_batteries-0.5.1-py3-none-any.whl.

File metadata

File hashes

Hashes for torch_batteries-0.5.1-py3-none-any.whl
Algorithm Hash digest
SHA256 8deba21aba9098673ad9d0f7ed8393d600ad2ef358dfdfb9584c3cbace91b134
MD5 a3ead83adb2edbbb081d1e1634d68b8c
BLAKE2b-256 dcea247c416e0023881dcd78c615ab6512a36bdd4c039e36a8702495ca44c1b2

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