This commit is contained in:
wukesong 2021-08-24 17:04:02 +08:00
parent c3c9dbd0a4
commit 41d045e59c
2 changed files with 8 additions and 1 deletions

View File

@ -201,3 +201,10 @@ In dataset.py, we set the seed inside ```create_dataset``` function.
## [ModelZoo Homepage](#contents) ## [ModelZoo Homepage](#contents)
Please check the official [homepage](https://gitee.com/mindspore/mindspore/tree/master/model_zoo). Please check the official [homepage](https://gitee.com/mindspore/mindspore/tree/master/model_zoo).
## FAQ
Please refer to [ModelZoo FAQ](https://gitee.com/mindspore/mindspore/tree/master/model_zoo#FAQ) to get some common FAQ.
- **Q**: Get "out of memory" error in PYNATIVE_MODE.
**A**: You can set smaller batch size, e.g. 32, 16.

View File

@ -273,7 +273,7 @@ def get_args(phase):
device_id=int(os.environ["DEVICE_ID"])) device_id=int(os.environ["DEVICE_ID"]))
context.reset_auto_parallel_context() context.reset_auto_parallel_context()
context.set_auto_parallel_context( context.set_auto_parallel_context(
parallel_mode=ParallelMode.AUTO_PARALLEL, parallel_mode=ParallelMode.DATA_PARALLEL,
gradients_mean=True, gradients_mean=True,
device_num=args.device_num) device_num=args.device_num)
init() init()