提交 be87be27 编写于 作者: S shippingwang

fix mix bug

上级 52d5cc81
......@@ -313,8 +313,14 @@ def normalize(feeds, config):
def mix(feeds, config, is_train=True):
batch_size = config.TRAIN.batch_size // paddle.fluid.core.get_cuda_device_count(
)
gpu_num = paddle.fluid.core.get_cuda_device_count() if (
'PADDLE_TRAINERS_NUM') and (
'PADDLE_TRAINER_ID'
) not in env else int(env.get('PADDLE_TRAINERS_NUM', 0))
batch_size = config.TRAIN.batch_size // gpu_num
#batch_imgs = _to_Tensor(feeds['feed_image'], 'float32')
#batch_label = _to_Tensor(feeds['feed_label'], 'int64')
images = feeds['image']
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册