diff --git "a/AscendPytorch\346\250\241\345\236\213\344\274\227\346\231\272FAQ.md" "b/AscendPytorch\346\250\241\345\236\213\344\274\227\346\231\272FAQ.md" index c7be4aa8bfec7baa9c4ab8edfa4b517de56b15d0..41c096996235e52cf3357d26e76bf2098806c8a1 100644 --- "a/AscendPytorch\346\250\241\345\236\213\344\274\227\346\231\272FAQ.md" +++ "b/AscendPytorch\346\250\241\345\236\213\344\274\227\346\231\272FAQ.md" @@ -566,3 +566,17 @@ StopIteration 重装环境中的torch和apex,问题得到解决。 +### FAQ3、在模型运行时,模型训练的精度和loss值多卡之间不同步. + + +* 现象描述 +![](https://gitee.com/wangjiangben_hw/ascend-pytorch-crowdintelligence-doc/raw/master/figures/model_faq2_0301.png) + + +* 原因分析 + + 只填加了train_sampler,没有添加set_epoch,导致不同步问题 + +* 处理方法 + + 在train epoch循环过程中,添加set_epoch,问题得到解决。 \ No newline at end of file diff --git a/figures/model_faq2_0301.png.png b/figures/model_faq2_0301.png.png new file mode 100644 index 0000000000000000000000000000000000000000..bcab2fe32f75ef55317dcdaa4001d9829c4213b2 Binary files /dev/null and b/figures/model_faq2_0301.png.png differ