ynu-yangpeng / GLMC

[CVPR2023] Global and Local Mixture Consistency Cumulative Learning for Long-tailed Visual Recognitions
69 stars 12 forks source link

Training args for CIFAR10-LT #3

Open ug-kim opened 1 year ago

ug-kim commented 1 year ago

I have some questions about the training arguments (hyper-parameters) of CIFAR10-LT.

Is it the same with CIFAR100-LT?

scutfrank commented 1 year ago

Yes, I also wonder if the training epoch is still 200? I can't get top-1 acc 92.4% mentioned in the paper if 200 epoch.@ynu-yangpeng

CxC-ssjg commented 1 year ago

I have the same question!

ynu-yangpeng commented 1 year ago

Apologies for the oversight in our paper regarding the incorrect upload of the results for CIFAR-10. We have updated our GitHub repository and reported the final results for CIFAR-10. Compared to the latest state-of-the-art work by BCL[1], our results are still 3% higher! We will upload the latest paper on arXiv as soon as possible.

The experimental setup was as follows: python main.py --dataset cifar10 -a resnet32 --num_classes 10 --imbanlance_rate 0.01 --beta 0.5 --lr 0.01 --epochs 200 -b 64 --momentum 0.9 --weight_decay 5e-3 --resample_weighting 0.0 --label_weighting 1.2 --contrast_weight 4.

Thank you very much for your question, which has helped us improve our work!

[1] Jianggang Zhu, ZhengWang, Jingjing Chen, Yi-Ping Phoebe Chen, and Yu-Gang Jiang. Balanced contrastive learning for long-tailed visual recognition. In Proceedings of the IEEE/CVF Conference on Computer Vision and Pattern Recognition, pages 6908–6917, 2022. 2, 3, 5, 6 @scutfrank @ug-kim @CxC-ssjg

ynu-yangpeng commented 1 year ago

Yes, you get better performance with a weight of 4 than with a weight of 10. Meanwhile, we have uploaded our arxiv link https://arxiv.org/abs/2305.08661, thanks for your question! @ug-kim

CxC-ssjg commented 1 year ago

In the Cifar10Imbanlance class ,which you make, the produce_imbanlance_data function,index = np.random.choice(data_num, data_percent[i - 1]) ,you do not make the replace=False,(it's defaults=True). If test like this,each class will obtain many same sample,I make a test ,about 643/1000, it mean nealy 357 samples are repeated.

If use your defalut codes,I find the test outcome is related wtih the seed ,which can cause an accuracy error of about 1%. So,why use the random function rather than loading the data directly? @ynu-yangpeng

ynu-yangpeng commented 1 year ago

Thank you very much, @CxC-ssjg , for your question. In our code for the Cifar10Imbalance and Cifar100Imbalance classes, when generating imbalanced data, we used np.random.choice for random sampling of samples. However, we did not set the "replace" parameter in the method to False, which could result in multiple repeated samples of a particular sample, thereby reducing the diversity of the dataset. Based on @CxC-ssjg advice, we set replace to False and fine-tuned our model accordingly. As a result, we observed a significant improvement in performance compared to the results reported in the paper. We have provided an update on the latest results and made the model publicly available. Once again, thank you, @CxC-ssjg , for your valuable question.

wan3333 commented 1 year ago

Hello, i have a question, you training on Imagenet only use a GPU?