Hlings / AsyFOD

(CVPR2023) The PyTorch implementation of the "AsyFOD: An Asymmetric Adaptation Paradigm for Few-Shot Domain Adaptive Object Detection".
MIT License
33 stars 3 forks source link

Performance on cityscapes to foggy cityscapes #9

Closed range428 closed 8 months ago

range428 commented 9 months ago

After I trained several times using the training instructions in README.md, I was unable to achieve the performance reported in the paper. Please provide some suggestions and assistance based on the following log, thanks! python train.py --cache --img 640 --batch 12 --epochs 300 --data ./data/eg/city_and_foggy8_3.yaml --cfg ./models/yolov5x.yaml --hyp ./data/hyp_aug/m1.yaml --weights --name test the results image "hyp": { "desc": null, "value": { "box": 0.05, "cls": 0.5, "lr0": 0.01, "lrf": 0.2, "obj": 1, "hsv_h": 0.015, "hsv_s": 0.7, "hsv_v": 0.4, "iou_t": 0.3, "mixup": 0, "scale": 0.5, "shear": 0, "cls_pw": 1, "fliplr": 0.5, "flipud": 0, "mosaic": 1, "obj_pw": 1, "cp_type": 0, "degrees": 0, "anchor_t": 4, "fl_gamma": 0, "momentum": 0.937, "copypaste": 0, "translate": 0.1, "perspective": 0, "weight_decay": 0.00046875, "warmup_epochs": 3, "warmup_bias_lr": 0.1, "warmup_momentum": 0.8 } }

Hlings commented 9 months ago

Hi From the config, you didn't use the mixup augmentation, which is necessary for Cityscapes to Foggy dataset. Please use the mm.1.yaml for performance reproduce. Wait for your further results and feel free to reach out to me :)

Hlings commented 9 months ago

And I have corrected the command for reproduction. Thanks for your reminder!

range428 commented 9 months ago

Thank you for your advice, which is effective. Also, when changing the batch size, is it necessary to manually adjust the learning rate in the mm.yaml file? If so, how can it be effectively adjusted? When using a single GPU with default mm1.yaml, the convergence speed is slower than 12 with a batch size of 20, and the performance is not good. When using two GPUs with a larger batch size(36 or 40), the model converges even slower and the performance is also not good.

Hlings commented 9 months ago

Yes, I encountered a similar problem. I tried to increase the batchsize but failed to converge on Yolov5 X. The learning rate may not be the key reason. I guess the YOLO v5 detector isn't good at this scenario and probably that's why the SimROD didn't report results on this dataset :)