uber-research / UPSNet

UPSNet: A Unified Panoptic Segmentation Network
Other
649 stars 120 forks source link

The actual batch size of upsnet_resnet50_cityscapes_4gpu.yaml #116

Closed hsfzxjy closed 4 years ago

hsfzxjy commented 4 years ago

Hi. I notice that you set batch_size = 1 and use_horovod = False in upsnet_resnet50_cityscapes_4gpu.yaml. And in upsnet_end2end_train.py, the batch_size you passed to DataLoader is config.train.batch_size. It seems that under this settings, UPSNet will be trained with batch size 1? Is it the desired behavior?


And I found that there are ~6k iterations in one epoch for Cityscapes, which seems to be too many.

YuwenXiong commented 4 years ago

Yes, you can check https://github.com/uber-research/UPSNet/blob/master/upsnet/upsnet_end2end_train.py#L256, every iteration we will get one batch with batch_size=1 for each gpu, so the effective batch size should be 4.

With the 4gpu config file one epoch should be ~1.5k iterations, please make sure your code/config are unmodified or modified on purpose.