From db73605d124d2f2fcd5a794d10e4803f299b359c Mon Sep 17 00:00:00 2001 From: yelihua Date: Thu, 23 Jul 2020 15:06:51 +0800 Subject: [PATCH] update profiler usage --- tutorials/source_en/advanced_use/performance_profiling.md | 2 +- tutorials/source_zh_cn/advanced_use/performance_profiling.md | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/tutorials/source_en/advanced_use/performance_profiling.md b/tutorials/source_en/advanced_use/performance_profiling.md index b8cd049a..f51f31e2 100644 --- a/tutorials/source_en/advanced_use/performance_profiling.md +++ b/tutorials/source_en/advanced_use/performance_profiling.md @@ -29,7 +29,7 @@ Performance data like operators' execution time is recorded in files and can be ## Preparing the Training Script -To enable the performance profiling of neural networks, MindSpore Profiler APIs should be added into the script. At first, the MindSpore `Profiler` object need to be set after set context and before the network initialization. Then, at the end of the training, `Profiler.analyse()` should be called to finish profiling and generate the perforamnce analyse results. +To enable the performance profiling of neural networks, MindSpore Profiler APIs should be added into the script. At first, the MindSpore `Profiler` object need to be set after set context and before the network and HCCL initialization. Then, at the end of the training, `Profiler.analyse()` should be called to finish profiling and generate the perforamnce analyse results. The sample code is as follows: diff --git a/tutorials/source_zh_cn/advanced_use/performance_profiling.md b/tutorials/source_zh_cn/advanced_use/performance_profiling.md index 0d8fb2d2..6eef098c 100644 --- a/tutorials/source_zh_cn/advanced_use/performance_profiling.md +++ b/tutorials/source_zh_cn/advanced_use/performance_profiling.md @@ -31,7 +31,7 @@ ## 准备训练脚本 为了收集神经网络的性能数据,需要在训练脚本中添加MindSpore Profiler相关接口。 -- 在`set_context`之后和初始化网络之前,需要初始化MindSpore `Profiler`对象。 +- `set_context`之后,初始化网络和HCCL之前,需要初始化MindSpore `Profiler`对象。 - 在训练结束后,调用`Profiler.analyse()`停止性能数据收集并生成性能分析结果。 样例代码如下: -- GitLab