提交 ce946127 编写于 作者: W wuzewu

Automatically adjust the batch size only when the use_data_parallel switch is turned on

上级 fc6c613b
......@@ -113,7 +113,7 @@ class BasicTask(object):
self.place = self.places[0]
self.device_count = len(self.places)
if self.config.batch_size < self.device_count:
if self.config.use_data_parallel and self.config.batch_size < self.device_count:
logger.warning(
"Batch size({}) is less than the count of devices({}), which is not allowed in current Paddle versions"
.format(self.config.batch_size, self.device_count))
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册