8b4c45a225c4737e2fcd14192891ad386403ef57,train.py,,validate,#Any#Any#Any#Any#Any#Any#,199

Before Change



        val_loss = loss_meter.avg
        fmt = desc + " | valid loss {:2.2f} | valid ppl {:3.2f}".format(
            val_loss, math.pow(2, val_loss))
        fmt += "".join(
            " | {} {:.4f}".format(k, meter.avg)
            for k, meter in extra_meters.items()

After Change



        val_loss = loss_meter.avg
        fmt = desc + " | valid loss {:2.2f} | valid ppl {:3.2f}".format(
            val_loss, get_perplexity(val_loss))
        fmt += "".join(
            " | {} {:.4f}".format(k, meter.avg)
            for k, meter in extra_meters.items()
Italian Trulli
In pattern: SUPERPATTERN

Frequency: 4

Non-data size: 3

Instances


Project Name: pytorch/fairseq
Commit Name: 8b4c45a225c4737e2fcd14192891ad386403ef57
Time: 2017-10-19
Author: louismartin@users.noreply.github.com
File Name: train.py
Class Name:
Method Name: validate


Project Name: elbayadm/attn2d
Commit Name: 8b4c45a225c4737e2fcd14192891ad386403ef57
Time: 2017-10-19
Author: louismartin@users.noreply.github.com
File Name: train.py
Class Name:
Method Name: train