!8175 GPU update alexnet in modelzoo

Merge pull request !8175 from VectorSL/alexnet
This commit is contained in:
mindspore-ci-bot 2020-11-03 21:01:17 +08:00 committed by Gitee
commit 8a261aa3a1
1 changed files with 1 additions and 1 deletions

View File

@ -76,8 +76,8 @@ if __name__ == "__main__":
gradients_mean=True)
init()
elif device_target == "GPU":
init()
if device_num > 1:
init()
context.reset_auto_parallel_context()
context.set_auto_parallel_context(device_num=device_num, parallel_mode=ParallelMode.DATA_PARALLEL,
gradients_mean=True)