Nvidia

您所在的位置:网站首页 医学SMI是什么意思 Nvidia

Nvidia

2024-06-12 15:43| 来源: 网络整理| 查看: 265

【时间】2018.10.10

【题目】Nvidia-smi简介及常用指令及其参数说明

目录

一、什么是Nvidia-smi

二、常用的Nvidia-smi指令

三、各种指令参数总结

一、什么是Nvidia-smi

nvidia-smi是nvidia 的系统管理界面 ,其中smi是System management interface的缩写,它可以收集各种级别的信息,查看显存使用情况。此外, 可以启用和禁用 GPU 配置选项 (如 ECC 内存功能)。

 

二、常用的Nvidia-smi指令

(以下图片主要来自http://hui.sohu.com/infonews/article/6337322514200395777)

1. nvidia-smi

【功能】 显示出当前GPU的所有基础信息。

 

解释相关参数含义:

GPU:本机中的GPU编号

Name:GPU 类型

Persistence-M:

Fan:风扇转速

Temp:温度,单位摄氏度

Perf:表征性能状态,从P0到P12,P0表示最大性能,P12表示状态最小性能

Pwr:Usage/Cap:能耗表示

Bus-Id:涉及GPU总线的相关信息;

Disp.A:Display Active,表示GPU的显示是否初始化

Memory-Usage:显存使用率

Volatile GPU-Util:浮动的GPU利用率

Uncorr. ECC:关于ECC的东西

Compute M.:计算模式

Processes 显示每块GPU上每个进程所使用的显存情况。

 

(更详细的说明可参考https://blog.csdn.net/sallyxyl1993/article/details/62220424)

 

2、  nvidia-smi -L 命令

【功能】 列出所有可用的 NVIDIA 设备

 

3、 nvidia-smi topo --matrix 命令

【功能】查看系统拓扑

【说明】 要正确地利用更先进的 NVIDIA GPU 功能 (如 GPUDirect),使用系统拓扑正确配置往往是至关重要的。该拓扑指的是 PCI Express 设备 (GPUs, InfiniBand HCAs, storage controllers, 等) 如何互相连接以及如何连接到系统的CPU。如果使用不正确的拓扑, 某些功能可能会减慢甚至停止工作

   

4. nvidia-smi -q -d CLOCK 命令

【功能】查看当前的 GPU 时钟速度、默认时钟速度和最大可能的时钟速度

5. nvidia-smi -q -d SUPPORTED_CLOCKS 

【功能】显示每个 GPU 的可用时钟速度列表

 

6. nvidia-smi vgpu

【功能】 查看当前vGPU的状态信息:

【补充说明】 虚拟图形处理单元(vGPU)是在虚拟桌面上渲染图形的一个组件。倘若没有此组件,显示如下:

 

7. nvidia-smi vgpu -p 

【功能】循环显示虚拟桌面中应用程序对GPU资源的占用情况

 

8. nvidia-smi -q

 

 

 

 

【功能】 查看当前所有GPU的信息,也可以通过参数i指定具体的GPU。

通过nvidia-smi -q 我们可以获取以下有用的信息:

系统中的GPU的基本信息

GPU的SN号、VBIOS、PN号等信息:

GPU的总线、PCI-E总线倍速、风扇转速等信息:

补充: PCI是Peripheral Component Interconnect(外设部件互连标准)的缩写,它是目前个人电脑中使用最为广泛的接口,几乎所有的主板产品上都带有这种插槽。

 

GPU的显存、BAR1、所有资源利用率、ECC模式等信息:

 

 

 

三、各种指令参数总结

(参考:https://www.cnblogs.com/xuyuan77/p/7856487.html)

输入指令 nvidia-smi -h

输出如下信息:

NVIDIA System Management Interface – v352.79

 

NVSMI provides monitoring information for Tesla and select Quadro devices. 

The data is presented in either a plain text or an XML format, via stdout or a file. 

NVSMI also provides several management operations for changing the device state.

 

Note that the functionality of NVSMI is exposed through the NVML C-based 

library. See the NVIDIA developer website for more information about NVML. 

Python wrappers to NVML are also available. The output of NVSMI is 

not guaranteed to be backwards compatible; NVML and the bindings are backwards 

compatible.

 

http://developer.nvidia.com/nvidia-management-library-nvml/ 

http://pypi.python.org/pypi/nvidia-ml-py/

Supported products:

Full Support 

All Tesla products, starting with the Fermi architecture

All Quadro products, starting with the Fermi architecture

All GRID products, starting with the Kepler architecture

GeForce Titan products, starting with the Kepler architecture

Limited Support 

All Geforce products, starting with the Fermi architecture

命令

nvidia-smi [OPTION1 [ARG1]] [OPTION2 [ARG2]] ...

 

参数

参数

详解

-h, –help

Print usage information and exit.

LIST OPTIONS:

参数

详解

-L, –list-gpus

Display a list of GPUs connected to the system.

SUMMARY OPTIONS:

参数

详解

-i,–id=

Target a specific GPU.

-f,–filename=

Log to a specified file, rather than to stdout.

-l,–loop=

Probe until Ctrl+C at specified second interval.

QUERY OPTIONS:

参数

详解

-q,

–query

-u,–unit

Show unit, rather than GPU, attributes.

-i,–id=

Target a specific GPU or Unit.

-f,–filename=

Log to a specified file, rather than to stdout.

-x,–xml-format

Produce XML output.

–dtd

When showing xml output, embed DTD.

-d,–display=

Display only selected information: MEMORY,

-l, –loop=

Probe until Ctrl+C at specified second interval.

-lms, –loop-ms=

Probe until Ctrl+C at specified millisecond interval.

SELECTIVE QUERY OPTIONS:

参数

详解

补充

–query-gpu=

Information about GPU.

Call –help-query-gpu for more info.

–query-supported-clocks=

List of supported clocks.

Call –help-query-supported-clocks for more info.

–query-compute-apps=

List of currently active compute processes.

Call –help-query-compute-apps for more info.

–query-accounted-apps=

List of accounted compute processes.

Call –help-query-accounted-apps for more info.

–query-retired-pages=

List of device memory pages that have been retired.

Call –help-query-retired-pages for more info.

[mandatory]

参数

命令

-i, –id=

Target a specific GPU or Unit.

-f, –filename=

Log to a specified file, rather than to stdout.

-l, –loop=

Probe until Ctrl+C at specified second interval.

-lms, –loop-ms=

Probe until Ctrl+C at specified millisecond interval.

DEVICE MODIFICATION OPTIONS:

参数

命令

补充

-pm, –persistence-mode=

Set persistence mode: 0/DISABLED, 1/ENABLED

 

-e, –ecc-config=

Toggle ECC support: 0/DISABLED, 1/ENABLED

 

-p, –reset-ecc-errors=

Reset ECC error counts: 0/VOLATILE, 1/AGGREGATE

 

-c, –compute-mode=

Set MODE for compute applications:

0/DEFAULT,1/EXCLUSIVE_THREAD (deprecated),2/PROHIBITED, 3/EXCLUSIVE_PROCESS

–gom=

Set GPU Operation Mode:

0/ALL_ON, 1/COMPUTE, 2/LOW_DP

-r –gpu-reset

Trigger reset of the GPU.

 

UNIT MODIFICATION OPTIONS:

参数

命令

-t, –toggle-led=

Set Unit LED state: 0/GREEN, 1/AMBER

-i, –id=

Target a specific Unit.

SHOW DTD OPTIONS:

参数

命令

–dtd

Print device DTD and exit.

-f, –filename=

Log to a specified file, rather than to stdout.

-u, –unit

Show unit, rather than device, DTD.

–debug=

Log encrypted debug information to a specified file.

Process Monitoring:

参数

命令

补充

pmon

Displays process stats in scrolling format.

“nvidia-smi pmon -h” for more information.

TOPOLOGY: (EXPERIMENTAL)

参数

命令

补充

topo

Displays device/system topology. “nvidia-smi topo -h” for more information.

Please see the nvidia-smi(1) manual page for more detailed information.

 

 

 



【本文地址】


今日新闻


推荐新闻


CopyRight 2018-2019 办公设备维修网 版权所有 豫ICP备15022753号-3