THUNLP-MT / THUMT

An open-source neural machine translation toolkit developed by Tsinghua Natural Language Processing Group
BSD 3-Clause "New" or "Revised" License
703 stars 197 forks source link

the thumt transformer model no implement early stopping to prevent overfitting? #47

Closed XiaoqingNLP closed 6 years ago

XiaoqingNLP commented 6 years ago

the early stopping to prevent overfitting is very useful to train a NMT model,but I didn't found it in thumt transformer.

Glaceon31 commented 6 years ago

Early stopping can be achieved in two ways in THUMT:

  1. When --validation <your validation source file> --references <your validation reference files> is set in training, THUMT will evaluate on the validation set periodically. The checkpoints that achieves highest BLEU scores on the validation set will be saved in the train/eval folder. (You can halt or resume the training whenever you want.)
  2. Setting keep_checkpoint_max in parameters to reserve as many checkpoints as you want.