Skip to main content

nvitop-cluster

Multi-node GPU monitor for training clusters: read MPI/OpenMPI hostfile, query each host (local NVML / remote SSH), show nvitop-style UTIL/MEM bars, temperatures, power, and resolved process command lines.

Designed for multi-node jobs (e.g. DeepSpeed / torchrun / MPI) where plain nvitop only sees the current machine.

Screenshot

nvitop-cluster sample

Sample from a 2-node × 8-GPU job (/etc/mpi/hostfile). Bars = GPU util (left) / memory (right). Second line per GPU is the process command (Ctrl-A / Ctrl-E switch head vs tail when truncated).

Features

  • Hostfile discovery: /etc/mpi/hostfile, /etc/mpi/mpi-hostfile, or -f PATH
  • Local + remote: local probe without SSH; peers via ssh (optional KML-style ssh_config)
  • Wide dual bars: GPU-Util and Memory-Usage (width scales with terminal)
  • Process names: optional host-PID → container-PID remap for Kubernetes/container jobs
  • Watch mode by default (2s); keys:
    • Ctrl-A / a — CMD head (like nvitop)
    • Ctrl-E / e — CMD tail
    • v — verbose full cmdline
    • q — quit

Install

Zero third-party Python deps (stdlib only). Needs Python ≥ 3.9, nvidia-smi on each node, and SSH to peers for multi-node.

pip / uv (recommended)

pip install nvitop-cluster
# or
uv pip install nvitop-cluster

# one-shot without installing into the env
uvx nvitop-cluster

# from GitHub (latest main)
pip install "git+https://github.com/Micuks/nvitop-cluster.git"

Then:

nvitop-cluster
# or
python -m nvitop_cluster

Multi-node tip: either install the package in the same image/env on every rank, or put the repo on a shared path and set NVITOP_CLUSTER_HOME so remote SSH probes can find the script.

From source (no install)

git clone https://github.com/Micuks/nvitop-cluster.git
cd nvitop-cluster
python3 -m nvitop_cluster
# or
./nvitop-cluster

Optional (local interactive nvitop + container PID fix):

pip install 'nvitop-cluster[nvitop]'
# then: nvitop_cluster/nvitop --cluster

Usage

# multi-node table (default: watch 2s)
nvitop-cluster

# once
nvitop-cluster -1

# custom hostfile / SSH config
nvitop-cluster -f /path/to/hostfile
export NVITOP_CLUSTER_SSH_CONFIG=~/.ssh/config

# via nvitop-compatible wrapper (optional extra)
python3 -m nvitop_cluster  # same as nvitop-cluster

Hostfile format

10.0.0.1 slots=8
10.0.0.2 slots=8

(Also accepts bare hostnames / host:slots.)

Environment

Variable Meaning
NVITOP_CLUSTER_HOME Directory containing probe scripts (default: package dir)
NVITOP_CLUSTER_SSH_CONFIG SSH config for peers (default: /etc/kml/ssh/ssh_config if present)
NVITOP_HOSTFILE Extra hostfile path candidate
NVITOP_CLUSTER=1 Force cluster mode when using the nvitop wrapper

Container / Kubernetes note

On many GPU pods, NVML reports host PIDs while /proc only has namespace PIDs, so process names become N/A. nvitop_pid_map.py remaps host→local PIDs (heuristic: rank / device / RSS). Works on each node when share storage holds the same scripts (or install the package everywhere).

Layout (vs plain nvitop)

nvitop nvitop-cluster
Scope Current host All hostfile hosts
UI Full interactive TUI Watch table + keys
Remote SSH probe
Processes Yes Yes (resolved when possible)

License

Apache-2.0 (see LICENSE).

Related

  • nvitop — single-node interactive viewer
  • all-smi — multi-host accelerator TUI
  • gpustat-web — multi-node web dashboard

Download files

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

Source Distribution

nvitop_cluster-0.1.1.tar.gz (20.7 kB view details)

Uploaded Source

Built Distribution

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

nvitop_cluster-0.1.1-py3-none-any.whl (20.9 kB view details)

Uploaded Python 3

File details

Details for the file nvitop_cluster-0.1.1.tar.gz.

File metadata

  • Download URL: nvitop_cluster-0.1.1.tar.gz
  • Upload date:
  • Size: 20.7 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: uv/0.12.2 {"installer":{"name":"uv","version":"0.12.2","subcommand":["publish"]},"python":null,"implementation":{"name":null,"version":null},"distro":{"name":"Ubuntu","version":"24.04","id":"noble","libc":null},"system":{"name":null,"release":null},"cpu":null,"openssl_version":null,"setuptools_version":null,"rustc_version":null,"ci":true}

File hashes

Hashes for nvitop_cluster-0.1.1.tar.gz
Algorithm Hash digest
SHA256 388297ef4d36e5d23b90ea36072b9f40e4e5c25781b05cb206d243b511d621d4
MD5 33940f8803e7d1f00314dc4842c3c27c
BLAKE2b-256 26429debfa296cacc75a8d332f98f53435fdbe93880a45e03c5f42398b02dc0f

See more details on using hashes here.

File details

Details for the file nvitop_cluster-0.1.1-py3-none-any.whl.

File metadata

  • Download URL: nvitop_cluster-0.1.1-py3-none-any.whl
  • Upload date:
  • Size: 20.9 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: uv/0.12.2 {"installer":{"name":"uv","version":"0.12.2","subcommand":["publish"]},"python":null,"implementation":{"name":null,"version":null},"distro":{"name":"Ubuntu","version":"24.04","id":"noble","libc":null},"system":{"name":null,"release":null},"cpu":null,"openssl_version":null,"setuptools_version":null,"rustc_version":null,"ci":true}

File hashes

Hashes for nvitop_cluster-0.1.1-py3-none-any.whl
Algorithm Hash digest
SHA256 56e061cbdccb091e05dcd4745b57ee71e6accb0a3cbf7990a63c24ef3b24f778
MD5 e49159e7e97f6ba7c7cf46588a15e7a0
BLAKE2b-256 89cecf1e3b922c7ed6e3e07befbcde6719c8c51c8fb01ac4b97a9b8f190d6cd6

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