获取设备信息
工具介绍
Profiling采集完成后可以通过“get_msprof_info.py”脚本工具在PROF_XXX目录下的device_{id}或host目录文件获取设备信息。“get_msprof_info.py”功能及安装路径如下。
脚本名 |
功能 |
路径 |
---|---|---|
“get_msprof_info.py” |
获取设备信息 |
CANN软件安装目录/ascend-toolkit/latest/tools/profiler/profiler_tool/analysis/interface/ |
操作步骤
- 以运行用户登录Ascend-cann-toolkit开发套件包所在环境。
- 切换至msprof.py脚本所在目录,如/home/HwHiAiUser/Ascend/ascend-toolkit/latest/tools/profiler/profiler_tool/analysis/interface。
- 执行“get_msprof_info.py”脚本,命令示例如下。
- 非集群场景
python3 get_msprof_info.py -dir /home/1/PROF_000001_20220129014731273_KEDKPORHMAGPGD/device_0
- 集群场景
python3 get_msprof_info.py -dir /home/1/
表1 参数说明 参数名
描述
可选/必选
-dir, --collection-dir
收集到的Profiling数据目录。非集群场景须指定为PROF_XXX目录下的host或device_{id}目录;集群场景须PROF_XXX目录的父目录。
必选
-h,--help
显示帮助信息,仅在获取使用方式时使用。
可选
- 非集群场景
- 查看输出结果。
非集群场景以打屏形式输出结果,如图1所示,各字段含义如表2所示;集群场景在-dir参数指定目录下生成/query/cluster_info.json文件保存集群场景各节点信息,如图2所示,各字段含义如表3所示。
表2 字段说明(非集群场景) 字段
说明
collection_info
信息收集。
Collection end time
信息收集结束时间。
Collection start time
信息收集开始时间。
Result Size
信息数据大小,单位MB。
device_info
设备信息。
AI Core Number
AI Core数量。
AI CPU Number
AI CPU数量。
Control CPU Number
Control CPU数量。
Control CPU Type
Control CPU类型。
Device Id
设备ID。
TS CPU Number
TS CPU数量。
host_info
Host信息。
cpu_info
Host CPU信息。
CPU ID
Host CPU ID。
Name
Host CPU名称。
Type
Host CPU类型。
Frequency
Host CPU频率。
Logical_CPU_Count
Host逻辑CPU数量。
cpu_num
Host CPU数量。
Host Computer Name
Host设备名。
Host Operating System
Host操作系统。
model_info
模型信息。
Device Id
设备ID。
iterations
迭代统计。
Iteration Number
迭代次数。
Model Id
模型ID,根据模型数量显示。
version_info
版本信息。
analysis_version
解析版本信息。
collection_version
采集版本信息。
drv_version
驱动版本信息。