lhoyer / DAFormer

[CVPR22] Official Implementation of DAFormer: Improving Network Architectures and Training Strategies for Domain-Adaptive Semantic Segmentation
Other
470 stars 93 forks source link

Different batch sizes for source and target data #54

Closed kaigelee closed 1 year ago

kaigelee commented 1 year ago

I'm wondering how I can adopt a batchsize where source domain and target domain images are inconsistent? e.g., for GTA-V, batchsize = 4 while for cityscapes, batchsize = 2.

Looking forward to your answer! Thank you.

lhoyer commented 1 year ago

Hi @kaigelee,

This behavior is not supported by this repository out-of-the-box. To implement it, you probably need to adapt https://github.com/lhoyer/DAFormer/blob/master/mmseg/datasets/builder.py and https://github.com/lhoyer/DAFormer/blob/master/mmseg/datasets/uda_dataset.py.

Best, Lukas