Lightweight monitoring toolkit for Hygon DCU clusters
Project description
hytop - monitoring tools
Quick start
Install from PyPI
Using pipx (recommended):
pipx install hytop
hytop --help
Using uv:
uv tool install hytop
hytop --help
Install from source
uv:
uv run hytop --help
pip:
pip install .
hytop --help
pipx:
pipx install .
hytop --help
Prerequisites
- Python >= 3.10
- Python packages:
rich,typer - Passwordless SSH for remote
hytop
# Show the version number
hytop --version
# Specify a timeout for the subcommand
hytop --timeout 300 [COMMAND]
# 0.5-second interval and 5-second rolling window for the subcommand
hytop -n 0.5 --window 5 [COMMAND]
# Specify a list of nodes for the subcommand
hytop -H node01,node02 [COMMAND]
hytop gpu
A lightweight script for live hy-smi polling with rolling averages across multiple hosts. It features a modern terminal UI and can be used as a blocking scheduler for GPU jobs.
Usage
Simple examples:
# Local node, all GPUs
hytop gpu
# Two nodes, 0.5-second interval
hytop -H node01,node02 -n 0.5 gpu
# Exit with code 0 when all monitored GPUs are available
hytop gpu --devices 0,1 --wait-idle
# Wait for GPUs to be idle for 30 seconds before exiting
hytop gpu --devices 0,1 --wait-idle --wait-idle-seconds 30
# Wait at most 300s for availability (exit 124 on timeout)
hytop gpu --devices 0,1 --wait-idle --timeout 300
# Fine-grained columns (output order follows show-flag order)
hytop gpu --showtemp --showpower
hytop gpu --showpower --showtemp
Queue jobs in shared environments:
if hytop -H node01,node02 gpu --timeout 300 --wait-idle; then
echo "GPUs available, starting workload..."
# YOUR COMMAND HERE (e.g., python train.py)
else
echo "Error: GPUs not available in time, aborting pipeline."
fi
Exit codes
Designed to be script-friendly:
0: Availability condition met (GPUs are idle).124: Timeout reached before the availability condition was met.130: Interrupted by the user (Ctrl+C).2: Argument or input error.
Fine-grained metric flags
hytop gpu uses formatted hy-smi --json output and supports a subset of hy-smi --show* flags:
--showtemp: GPU core temperature (Temp)--showpower: average package power (AvgPwr, plusAvgPwr@window)--showsclk: sclk frequency (sclk)--showmemuse: VRAM usage (VRAM%)--showuse: GPU utilization (GPU%, plusGPU%@window)
If no --show* flags are specified, hytop defaults to:
--showtemp --showpower --showsclk --showmemuse --showuse.
Development
Clone the repo and run make setup to create the virtual environment, install all dependencies (including dev), and configure pre-commit hooks:
make setup
Common development commands:
make format # Auto-fix and format code (ruff)
make lint # Check code style and errors without modifying files
make test # Run all unit tests (pytest)
make bump part=patch # Bump version (patch/minor/major or X.Y.Z)
make clean # Remove build caches and the virtual environment
Version bump
Version is sourced from src/hytop/__init__.py (__version__).
make bump part=patch # 0.1.0 -> 0.1.1
make bump part=minor # 0.1.1 -> 0.2.0
make bump part=major # 0.2.0 -> 1.0.0
make bump part="set 1.2.3" # set an explicit version
Publish
Releases are automatically published to PyPI when pushing a version tag:
# Bump version and commit
make bump part=patch
git commit -am "Bump version to 0.1.1"
# Tag and push to trigger GitHub Actions release
git tag hytop-0.1.1
git push origin hytop-0.1.1
To test building distributions locally:
make build
Project details
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.
Source Distribution
Built Distribution
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file hytop-0.1.1.tar.gz.
File metadata
- Download URL: hytop-0.1.1.tar.gz
- Upload date:
- Size: 33.5 kB
- Tags: Source
- Uploaded using Trusted Publishing? Yes
- Uploaded via: twine/6.1.0 CPython/3.13.7
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
b3cc3e67ce75ffd4e4c09c43ad9f958f76d18190afdfef26cb7523bccdb9dd09
|
|
| MD5 |
3b67024db899bcaa6d16ed74be89762b
|
|
| BLAKE2b-256 |
6eb028ef59f78b83f926edaf3e6eb5b63ba52a0009fc5fec4274ac26a716d063
|
Provenance
The following attestation bundles were made for hytop-0.1.1.tar.gz:
Publisher:
hytop-publish.yml on alephpiece/hg-misc-tools
-
Statement:
-
Statement type:
https://in-toto.io/Statement/v1 -
Predicate type:
https://docs.pypi.org/attestations/publish/v1 -
Subject name:
hytop-0.1.1.tar.gz -
Subject digest:
b3cc3e67ce75ffd4e4c09c43ad9f958f76d18190afdfef26cb7523bccdb9dd09 - Sigstore transparency entry: 1002875953
- Sigstore integration time:
-
Permalink:
alephpiece/hg-misc-tools@9e829f84cced255e10d056ddd7d7c6625fd7067d -
Branch / Tag:
refs/tags/hytop-0.1.1 - Owner: https://github.com/alephpiece
-
Access:
private
-
Token Issuer:
https://token.actions.githubusercontent.com -
Runner Environment:
github-hosted -
Publication workflow:
hytop-publish.yml@9e829f84cced255e10d056ddd7d7c6625fd7067d -
Trigger Event:
push
-
Statement type:
File details
Details for the file hytop-0.1.1-py3-none-any.whl.
File metadata
- Download URL: hytop-0.1.1-py3-none-any.whl
- Upload date:
- Size: 19.9 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? Yes
- Uploaded via: twine/6.1.0 CPython/3.13.7
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
5e7000e12feb02f5806ce0aa4705e60bf24f4dab74a4c874a13e91a12dc11484
|
|
| MD5 |
2759d65d8c656fcd780f79e4e6fcec9f
|
|
| BLAKE2b-256 |
6dbfc2c928a97dbaa55dd081be8f833c20d9bca23c03bfffb687da52a521744f
|
Provenance
The following attestation bundles were made for hytop-0.1.1-py3-none-any.whl:
Publisher:
hytop-publish.yml on alephpiece/hg-misc-tools
-
Statement:
-
Statement type:
https://in-toto.io/Statement/v1 -
Predicate type:
https://docs.pypi.org/attestations/publish/v1 -
Subject name:
hytop-0.1.1-py3-none-any.whl -
Subject digest:
5e7000e12feb02f5806ce0aa4705e60bf24f4dab74a4c874a13e91a12dc11484 - Sigstore transparency entry: 1002875956
- Sigstore integration time:
-
Permalink:
alephpiece/hg-misc-tools@9e829f84cced255e10d056ddd7d7c6625fd7067d -
Branch / Tag:
refs/tags/hytop-0.1.1 - Owner: https://github.com/alephpiece
-
Access:
private
-
Token Issuer:
https://token.actions.githubusercontent.com -
Runner Environment:
github-hosted -
Publication workflow:
hytop-publish.yml@9e829f84cced255e10d056ddd7d7c6625fd7067d -
Trigger Event:
push
-
Statement type: