DFormer icon indicating copy to clipboard operation
DFormer copied to clipboard

Fluctuations in training results under the same configuration

Open lsm0627 opened this issue 1 year ago • 1 comments

Dear author, thank you for your excellent work. As a beginner, I encountered a problem during the code copying process. I trained with the same configuration, but the results varied between 56.8 and 57.1. Is there a way to ensure consistency in training results? This will enable me to modify your code more effectively.

lsm0627 avatar Aug 16 '24 02:08 lsm0627

Thanks for your attention to our work!

It is suggested that use the fixed random seed in training process and dataloader. You can change line 27 in 'train.sh' from '--no-use_seed' to 'use_seed' and cancel the annotation in line 142-143&187-188 of 'DFormer/utils /dataloader/dataloader.py' to fix the two processes.

However, the training results still cannot be the same every time, and it is normal for the results to fluctuate within a small range. The reported performance in our paper is also obtained by averaging the results of several trainings.

yinbow avatar Aug 16 '24 08:08 yinbow