Skip to content

GPU Monitoring

GPU monitoring from the terminal. nvidia-smi gives a snapshot or a refreshed view via watch. nvtop is an interactive monitor that handles multiple GPUs and shows utilization graphs over time.

Print a single snapshot of GPU utilization, memory used and free, temperature, and running processes.

Terminal window
nvidia-smi

Run nvidia-smi on a fixed interval and refresh the display in place. Useful for watching utilization and memory during training runs.

Terminal window
watch -n 1 nvidia-smi

Adjust the refresh interval as needed:

Terminal window
watch -n 2 nvidia-smi # refresh every 2 seconds
watch -n 0.5 nvidia-smi # refresh every 500ms

Exit with Ctrl+c.

nvtop is a interactive monitor for GPUs. It shows per-GPU utilization graphs over time, memory usage, temperature, and the processes using each GPU. Better than watch + nvidia-smi when monitoring multiple GPUs or watching utilization patterns over time.

Install on Ubuntu and Debian:

Terminal window
sudo apt install nvtop

Install on Arch:

Terminal window
sudo pacman -S nvtop

Run:

Terminal window
nvtop

Exit with q.