Repolode
wookayin

wookayin/gpustat

A command-line tool that shows NVIDIA, AMD and Huawei Ascend GPU status (utilization, memory, temperature, processes) in a compact, readable format.

Open-source alternative to:nvidia-smi

Stars
4,389
Forks
287
Open issues
27
Last commit
29 days ago

What is it?

gpustat is a small Python command-line utility for querying and monitoring GPU status. It prints one line per device with the GPU name, temperature, utilization, memory usage and the processes currently running on it, offering a more compact view than nvidia-smi.

The tool supports NVIDIA GPUs through NVML, AMD GPUs through ROCm SMI, and Huawei Ascend 910B NPUs through npu-smi. The backend is detected automatically or can be chosen with a flag. Optional columns cover users, PIDs, full commands, fan speed, encoder/decoder use and power draw, and a watch mode refreshes the output at a set interval.

Besides the CLI, gpustat exposes a Python API for querying GPU stats from your own code, and it can emit JSON output for scripts.

Key features

  • 01Shows GPU name, temperature, utilization and memory usage on one line per device.
  • 02Lists processes on each GPU with owner, PID and memory use.
  • 03Supports NVIDIA (NVML), AMD (ROCm SMI) and Huawei Ascend 910B backends.
  • 04Offers a watch mode that refreshes output at a chosen interval.
  • 05Provides JSON output and a Python API for scripting.

Use cases

  • Checking which GPUs on a shared workstation or server are free before launching a training job.
  • Watching GPU memory and utilization while a long-running model trains.
  • Collecting GPU metrics as JSON inside monitoring scripts.
  • Viewing GPU status over SSH in a quick, readable format.

Quick start

  1. 1

    Install gpustat from PyPI

    pip install gpustat
  2. 2

    Install NVIDIA's official NVML binding (not pynvml) if you have NVIDIA GPUs

    pip install nvidia-ml-py
  3. 3

    Run gpustat to show GPU status

    gpustat

Things to know

  • Requires an NVIDIA driver (450.00 or higher for gpustat 1.0+) for NVIDIA GPUs.
  • Using the pynvml package instead of nvidia-ml-py will not work.

In collections

Topics

FAQ

What is gpustat?
A command-line tool that shows NVIDIA, AMD and Huawei Ascend GPU status (utilization, memory, temperature, processes) in a compact, readable format. gpustat is a small Python command-line utility for querying and monitoring GPU status. It prints one line per device with the GPU name, temperature, utilization, memory usage and the processes currently running on it, offering a more compact view than nvidia-smi.
Is gpustat free to use? What license does it have?
gpustat is open source under the MIT license. Check the license terms before using it in commercial products.
Is gpustat still maintained?
Actively maintained. The last commit to gpustat was on Oct 8, 2026.
What can I use gpustat for?
Checking which GPUs on a shared workstation or server are free before launching a training job. Watching GPU memory and utilization while a long-running model trains. Collecting GPU metrics as JSON inside monitoring scripts. Viewing GPU status over SSH in a quick, readable format.
How do I install gpustat?
Install gpustat from PyPI: pip install gpustat Install NVIDIA's official NVML binding (not pynvml) if you have NVIDIA GPUs: pip install nvidia-ml-py Run gpustat to show GPU status: gpustat
Where can I get gpustat?
The source code and installation instructions are on GitHub: https://github.com/wookayin/gpustat

Summary generated by AI from the project's README. GitHub stats refresh daily.

Related projects