[PR #39] [MERGED] feat(gui/metrics): add process metrics screen #132

Closed
opened 2026-05-05 03:26:28 -06:00 by gitea-mirror · 0 comments
Owner

📋 Pull Request Information

Original PR: https://github.com/XuehaiPan/nvitop/pull/39
Author: @XuehaiPan
Created: 9/24/2022
Status: Merged
Merged: 9/26/2022
Merged by: @XuehaiPan

Base: mainHead: process-metrics


📝 Commits (10+)

  • b7b2491 feat(gui/metrics): add process metrics screen
  • b77f85b feat(gui/metrics): 256-color support
  • 1bb0002 chore(core/process): handle gone processes in update_gpu_status
  • e2a0aba chore(gui/metrics): update keybinding
  • 006743b chore(gui/metrics): use dynamic bound for all graphs
  • 68fc898 chore(gui/metrics): add graph ticks
  • 75c2567 chore(gui/metrics): support metric graphs for no-Unicode mode
  • 0a36e66 chore(gui/metrics): update y ticks
  • 1a6ab2d chore(gui/metrics): update x ticks
  • 50cb90b chore(gui): update return value of update_size

📊 Changes

18 files changed (+723 additions, -55 deletions)

View changed files

📝 README.md (+13 -4)
📝 docs/source/index.rst (+1 -1)
📝 nvitop/core/process.py (+2 -0)
📝 nvitop/gui/library/__init__.py (+1 -0)
📝 nvitop/gui/library/history.py (+42 -5)
📝 nvitop/gui/library/libcurses.py (+4 -2)
📝 nvitop/gui/library/process.py (+21 -0)
📝 nvitop/gui/library/selection.py (+2 -5)
📝 nvitop/gui/library/utils.py (+3 -0)
📝 nvitop/gui/screens/__init__.py (+1 -0)
📝 nvitop/gui/screens/environ.py (+2 -0)
📝 nvitop/gui/screens/help.py (+12 -10)
📝 nvitop/gui/screens/main/__init__.py (+2 -0)
📝 nvitop/gui/screens/main/host.py (+4 -4)
📝 nvitop/gui/screens/main/process.py (+12 -11)
nvitop/gui/screens/metrics.py (+552 -0)
📝 nvitop/gui/screens/treeview.py (+3 -1)
📝 nvitop/gui/top.py (+46 -12)

📄 Description

Issue Type

  • Improvement/feature implementation

Runtime Environment

  • Operating system and version: Ubuntu 20.04 LTS
  • Terminal emulator and version: GNOME Terminal 3.36.2
  • Python version: 3.9.13
  • NVML version (driver version): 470.129.06
  • nvitop version or commit: main
  • python-ml-py version: 11.450.51
  • Locale: en_US.UTF-8

Description

Add process metrics screen. Watch metrics for a specific process in the terminal.

In addition to metrics (GPU-MEM, %SM, %CPU, %MEM, TIME) already on the main screen, it adds:

  • live graph for %CPU and metric for max %CPU
  • live graph for HOST-MEM and %MEM, and metric for max HOST-MEM
  • live graph for GPU-MEM and %GPU-MEM, and metric for max GPU-MEM
  • live graph for %SM and metric for max %SM
  • metric %GMBW: GPU memory bandwidth utilization
  • metric %ENC: encoder utilization
  • metric %DEC: decoder utilization

Motivation and Context

Resolves #36

Testing

Images / Videos

Process Metrics Screen
Watch metrics for a specific process (shortcut: Enter / Return).


🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.

## 📋 Pull Request Information **Original PR:** https://github.com/XuehaiPan/nvitop/pull/39 **Author:** [@XuehaiPan](https://github.com/XuehaiPan) **Created:** 9/24/2022 **Status:** ✅ Merged **Merged:** 9/26/2022 **Merged by:** [@XuehaiPan](https://github.com/XuehaiPan) **Base:** `main` ← **Head:** `process-metrics` --- ### 📝 Commits (10+) - [`b7b2491`](https://github.com/XuehaiPan/nvitop/commit/b7b249113ddce5479a98c2fe1f8b0e71b8614e69) feat(gui/metrics): add process metrics screen - [`b77f85b`](https://github.com/XuehaiPan/nvitop/commit/b77f85ba457d1d2532ce060c4eae61c8ea4816de) feat(gui/metrics): 256-color support - [`1bb0002`](https://github.com/XuehaiPan/nvitop/commit/1bb0002b7198877efd17dbd2fcabddc364178b3b) chore(core/process): handle gone processes in `update_gpu_status` - [`e2a0aba`](https://github.com/XuehaiPan/nvitop/commit/e2a0aba398635b6df7d658ae73c873bbe78155c1) chore(gui/metrics): update keybinding - [`006743b`](https://github.com/XuehaiPan/nvitop/commit/006743b7c06d457c48a7059c639b81a061751f23) chore(gui/metrics): use dynamic bound for all graphs - [`68fc898`](https://github.com/XuehaiPan/nvitop/commit/68fc898c68389794428ba9a9079975bcc6833feb) chore(gui/metrics): add graph ticks - [`75c2567`](https://github.com/XuehaiPan/nvitop/commit/75c2567d1d71d54f5e9f00da67ad33b664a90b95) chore(gui/metrics): support metric graphs for no-Unicode mode - [`0a36e66`](https://github.com/XuehaiPan/nvitop/commit/0a36e6677e7f0be2b1cd1bb02a9efbc07ec3e0e8) chore(gui/metrics): update y ticks - [`1a6ab2d`](https://github.com/XuehaiPan/nvitop/commit/1a6ab2dc059468ec1b5ebdcb19e8e4f0a6984522) chore(gui/metrics): update x ticks - [`50cb90b`](https://github.com/XuehaiPan/nvitop/commit/50cb90b46b39aaa5106b7561713e64ca28549dcd) chore(gui): update return value of `update_size` ### 📊 Changes **18 files changed** (+723 additions, -55 deletions) <details> <summary>View changed files</summary> 📝 `README.md` (+13 -4) 📝 `docs/source/index.rst` (+1 -1) 📝 `nvitop/core/process.py` (+2 -0) 📝 `nvitop/gui/library/__init__.py` (+1 -0) 📝 `nvitop/gui/library/history.py` (+42 -5) 📝 `nvitop/gui/library/libcurses.py` (+4 -2) 📝 `nvitop/gui/library/process.py` (+21 -0) 📝 `nvitop/gui/library/selection.py` (+2 -5) 📝 `nvitop/gui/library/utils.py` (+3 -0) 📝 `nvitop/gui/screens/__init__.py` (+1 -0) 📝 `nvitop/gui/screens/environ.py` (+2 -0) 📝 `nvitop/gui/screens/help.py` (+12 -10) 📝 `nvitop/gui/screens/main/__init__.py` (+2 -0) 📝 `nvitop/gui/screens/main/host.py` (+4 -4) 📝 `nvitop/gui/screens/main/process.py` (+12 -11) ➕ `nvitop/gui/screens/metrics.py` (+552 -0) 📝 `nvitop/gui/screens/treeview.py` (+3 -1) 📝 `nvitop/gui/top.py` (+46 -12) </details> ### 📄 Description #### Issue Type <!-- Pick relevant types and delete the rest --> - Improvement/feature implementation #### Runtime Environment <!-- Details of your runtime environment --> - Operating system and version: Ubuntu 20.04 LTS - Terminal emulator and version: GNOME Terminal 3.36.2 - Python version: `3.9.13` - NVML version (driver version): `470.129.06` - `nvitop` version or commit: `main` - `python-ml-py` version: `11.450.51` - Locale: `en_US.UTF-8` #### Description <!-- Describe the changes in detail --> Add process metrics screen. Watch metrics for a specific process in the terminal. In addition to metrics (`GPU-MEM`, `%SM`, `%CPU`, `%MEM`, `TIME`) already on the main screen, it adds: - live graph for `%CPU` and metric for max `%CPU` - live graph for `HOST-MEM` and `%MEM`, and metric for max `HOST-MEM` - live graph for `GPU-MEM` and `%GPU-MEM`, and metric for max `GPU-MEM` - live graph for `%SM` and metric for max `%SM` - metric `%GMBW`: GPU memory bandwidth utilization - metric `%ENC`: encoder utilization - metric `%DEC`: decoder utilization #### Motivation and Context <!-- Why are these changes required? --> <!-- What problems do these changes solve? --> <!-- Link to relevant issues --> Resolves #36 #### Testing <!-- What tests have been run? --> <!-- How does the changes affect other areas of the codebase? --> #### Images / Videos <!-- Only if relevant --> <!-- Link or embed images and videos of screenshots, sketches etc. --> <p align="center"> <img width="100%" src="https://user-images.githubusercontent.com/16078332/192108815-37c03705-be44-47d4-9908-6d05175db230.png" alt="Process Metrics Screen"> </br> Watch metrics for a specific process (shortcut: <kbd>Enter</kbd> / <kbd>Return</kbd>). </p> --- <sub>🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.</sub>
gitea-mirror 2026-05-05 03:26:28 -06:00
Sign in to join this conversation.
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference: github-starred/nvitop#132
No description provided.