fairseq icon indicating copy to clipboard operation
fairseq copied to clipboard

Does the training log the bleu score when inferencing on the valid set?

Open hengyicai opened this issue 8 years ago • 3 comments

When checking the training log file, I could not find the bleu score result in each epoch validation record. Is there any options must be set for this?

0, clip=100%, oom=0, loss_scale=8.000, wall=23300, train_wall=20576
| epoch 002:   2000 / 7041 loss=3.200, ppl=9.19, wps=15031, ups=0.4, wpb=41819, bsz=2551, num_updates=9035, lr=0.25, gnorm=0.189, clip=100%, oom=0, loss_scale=16.000, wall=26073, train_wall=23131
| epoch 002:   3000 / 7041 loss=3.164, ppl=8.96, wps=14991, ups=0.4, wpb=41864, bsz=2558, num_updates=10035, lr=0.25, gnorm=0.187, clip=100%, oom=0, loss_scale=16.000, wall=28887, train_wall=25702
| epoch 002:   4000 / 7041 loss=3.133, ppl=8.77, wps=14962, ups=0.4, wpb=41894, bsz=2559, num_updates=11035, lr=0.25, gnorm=0.185, clip=100%, oom=0, loss_scale=32.000, wall=31709, train_wall=28275
| epoch 002:   5000 / 7041 loss=3.104, ppl=8.60, wps=14935, ups=0.4, wpb=41893, bsz=2561, num_updates=12035, lr=0.25, gnorm=0.183, clip=100%, oom=0, loss_scale=32.000, wall=34534, train_wall=30846

hengyicai avatar Nov 23 '18 14:11 hengyicai

Hi, we do not have this implemented as part of the training. You can run generation with each epoch's saved checkpoint though to get the bleu score. An example way to run this generation is here:

https://github.com/fairinternal/fairseq-py/tree/master/examples/translation

huihuifan avatar Nov 25 '18 13:11 huihuifan

Hi Fairseq folks:

Please let me know if this functionality has been added (checking for BLEU score after every epoch). A use-case is MLPerf where the BLEU score needs to be validated after every epoch.

abhinavvishnu avatar Sep 30 '19 15:09 abhinavvishnu

AFAIK, this functionality has not been added. As recommended above, you could run generation with each epoch's saved checkpoint for now.

jiajunshen avatar Sep 30 '19 16:09 jiajunshen