mirror of
https://github.com/XuehaiPan/nvitop.git
synced 2026-05-15 14:15:55 -06:00
[PR #26] [MERGED] feat(core/libcuda): add Python bindings for CUDA driver APIs #127
Labels
No labels
api
bug
bug
cli / tui
dependencies
documentation
documentation
documentation
duplicate
enhancement
exporter
invalid
pull-request
pynvml
question
question
upstream
wontfix
No milestone
No project
No assignees
1 participant
Notifications
Due date
No due date set.
Dependencies
No dependencies set.
Reference: github-starred/nvitop#127
Loading…
Add table
Add a link
Reference in a new issue
No description provided.
Delete branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
📋 Pull Request Information
Original PR: https://github.com/XuehaiPan/nvitop/pull/26
Author: @XuehaiPan
Created: 7/17/2022
Status: ✅ Merged
Merged: 7/21/2022
Merged by: @XuehaiPan
Base:
main← Head:libcuda📝 Commits (9)
4df53bffeat(core/libcuda): add Python bindings for CUDA driver APIsf8f60d0feat(core/device): add methodCudaDevice.is_available()cf12842feat(core/device): parseCUDA_VISIBLE_DEVICESin a subprocess1a84b98fix(core/libcuda): fix string truncation by char '\00'6d2d654fix(core/libcuda): fix pointer type for string buffers89770e1docs(core/device): update docstrings1435f76fix(gui/process): fix messages for no processes found in one time print59c61a7feat(core/device): refactorCUDA_VISIBLE_DEVICESparsing5eadd7efix(core/device): fix missing attributes for Python < 3.7📊 Changes
6 files changed (+893 additions, -77 deletions)
View changed files
➕
docs/source/apis/core/libcuda.rst(+8 -0)📝
docs/source/apis/index.rst(+1 -0)📝
nvitop/core/__init__.py(+2 -1)📝
nvitop/core/device.py(+229 -75)➕
nvitop/core/libcuda.py(+651 -0)📝
nvitop/gui/screens/main/process.py(+2 -1)📄 Description
Issue Type
Runtime Environment
3.9.13470.129.06nvitopversion or commit:main@0a9048python-ml-pyversion:11.450.51en_US.UTF-8Description
Add Python bindings for CUDA driver APIs.
Motivation and Context
This would simplify the
CUDA_VISIBLE_DEVICESenvironment variable parsing. Handles non-standardCUDA_VISIBLE_DEVICESformat. For example:The new
CUDA_VISIBLE_DEVICESparser supports abbreviated UUIDs and MIG devices:🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.