hustvl / MIMDet

[ICCV 2023] You Only Look at One Partial Sequence
https://arxiv.org/abs/2204.02964
MIT License
330 stars 30 forks source link

How to change the config to train Benchmarking-ViT-B with batch size 16 ? #13

Closed Yingdong-Hu closed 2 years ago

Yingdong-Hu commented 2 years ago

Hi, thanks for the great project! How is this max_iter=184375 in Benchmarking-ViT-B calculated ? (num_images * epochs) / batch_size ? I want to train a Benchmarking-ViT-B model with batch size 16 on 8-GPUs environment, but I am confused by the config file. Could you advise how to adjust hyper-parameters like max_iter, eval_period if I change the batch size to 16?

https://github.com/hustvl/MIMDet/blob/9e1dea10fd5eb26567cb2bac51f2b652d81620b9/configs/benchmarking/benchmarking_mask_rcnn_base_FPN_100ep_LSJ_mae.py#L150-L163

Yuxin-CV commented 2 years ago

Hi @Alxead, thanks for your interest in our work. You are right: max_iter = (num_images * epochs) / batch_size (num_images = ~118000 for COCO).

I suggest you change max_iter = 184375 * 4 & eval_period = 1844 * 4 if your bsz = 16. Also, I recommend changing the lr = 4e-5.

But notice that this config cannot guarantee to re-produce the original accuracy.

Yuxin-CV commented 2 years ago

I believe the issue at hand was addressed, as such I'm closing this. Feel free to ask if you have further questions.