未验证 提交 282e4890 编写于 作者: L LielinJiang 提交者: GitHub

fix save model bug when use distributed traning (#4533)

上级 269b1767
......@@ -288,7 +288,7 @@ def train(args):
if args.use_dali:
test_iter.reset()
if pass_id % args.save_step == 0:
if trainer_id == 0 and pass_id % args.save_step == 0:
save_model(args, exe, train_prog, pass_id)
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册