Skip to main content

A terminal UI for monitoring neural network training in real time

Project description

gradtop

A terminal UI for monitoring neural network training in real time. Inspired by htop.

What it shows

  • Loss curve over training steps
  • Per-layer update/data ratio (log10 scale) — the ratio of gradient updates to weight magnitudes, following Karpathy's diagnostic from the Neural Networks: Zero to Hero series. Values should hover around -3. Above -2 means large updates, below -4 means vanishing gradients.

Installation

pip install gradtop

Development

If you want to build from source, you need Rust and maturin:

git clone https://github.com/yourname/gradtop
cd gradtop
pip install maturin
maturin develop

Usage

import gradtop
from gradtop import gradtop

with GradTop(model, optimizer, every_n_steps=10) as monitor:
    for epoch in range(epochs):
        for data, target in train_loader:
            optimizer.zero_grad()
            output = model(data)
            loss = criterion(output, target)
            loss.backward()
            optimizer.step()
            monitor.tick(loss.item())

Press any key to close the TUI. The terminal is restored automatically on exit.

Project details


Download files

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

Source Distributions

No source distribution files available for this release.See tutorial on generating distribution archives.

Built Distributions

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

gradtop-0.1.1-cp310-cp310-manylinux_2_17_x86_64.manylinux2014_x86_64.whl (554.4 kB view details)

Uploaded CPython 3.10manylinux: glibc 2.17+ x86-64

gradtop-0.1.1-cp310-cp310-manylinux_2_17_aarch64.manylinux2014_aarch64.whl (543.9 kB view details)

Uploaded CPython 3.10manylinux: glibc 2.17+ ARM64

gradtop-0.1.1-cp310-cp310-macosx_11_0_arm64.whl (491.9 kB view details)

Uploaded CPython 3.10macOS 11.0+ ARM64

File details

Details for the file gradtop-0.1.1-cp310-cp310-manylinux_2_17_x86_64.manylinux2014_x86_64.whl.

File metadata

File hashes

Hashes for gradtop-0.1.1-cp310-cp310-manylinux_2_17_x86_64.manylinux2014_x86_64.whl
Algorithm Hash digest
SHA256 b9efe908c036008722b03e2641deea4a41619c85be8374f0bcfd84045a59f58c
MD5 a5c4b3859dee0b232e8392c25021e4f3
BLAKE2b-256 f9ec7a4eaebe358f87438c8324b12d21a479f71d771b960e30d4f59bae86fa0c

See more details on using hashes here.

Provenance

The following attestation bundles were made for gradtop-0.1.1-cp310-cp310-manylinux_2_17_x86_64.manylinux2014_x86_64.whl:

Publisher: release.yml on NavneetKanna/gradtop

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

File details

Details for the file gradtop-0.1.1-cp310-cp310-manylinux_2_17_aarch64.manylinux2014_aarch64.whl.

File metadata

File hashes

Hashes for gradtop-0.1.1-cp310-cp310-manylinux_2_17_aarch64.manylinux2014_aarch64.whl
Algorithm Hash digest
SHA256 9329e4d7ae0f8d97130f7856aa1801789e2a720d0b19ad57b19066aa1dc4b120
MD5 1d4d0ff0aaa0a3d1b3c0b7ead535341f
BLAKE2b-256 76bf4ecacc6e6326a6b2f6cc2d6233441337846db6ff3f10ab7b9b29897e3d97

See more details on using hashes here.

Provenance

The following attestation bundles were made for gradtop-0.1.1-cp310-cp310-manylinux_2_17_aarch64.manylinux2014_aarch64.whl:

Publisher: release.yml on NavneetKanna/gradtop

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

File details

Details for the file gradtop-0.1.1-cp310-cp310-macosx_11_0_arm64.whl.

File metadata

File hashes

Hashes for gradtop-0.1.1-cp310-cp310-macosx_11_0_arm64.whl
Algorithm Hash digest
SHA256 8dbd0600bc0579bdcf6ee97c3660eb70af09704dea2b24c5ed3cbdd799295d6b
MD5 709e3a8a38a49b10e542f7af399c2326
BLAKE2b-256 7a4cec47a6842d115085b875b6cdc3af7af242339ea05e02f7ef3f8eebf18d7b

See more details on using hashes here.

Provenance

The following attestation bundles were made for gradtop-0.1.1-cp310-cp310-macosx_11_0_arm64.whl:

Publisher: release.yml on NavneetKanna/gradtop

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