ac7bb33dd978e2bf6ecb0cf055dd6bf6c9c1ea05,train.py,,,#,21

Before Change


model.apply(weights_init_normal)

if cuda:
    model = model.cuda()

model.train()

// Get dataloader

After Change


        batches_done = len(dataloader) * epoch + batch_i

        // Tensorboard logging
        for loss_name, loss in model.losses.items():
            logger.scalar_summary(loss_name, loss, batches_done)

        model.seen += imgs.size(0)

        torch.cuda.empty_cache()
Italian Trulli
In pattern: SUPERPATTERN

Frequency: 3

Non-data size: 4

Instances


Project Name: eriklindernoren/PyTorch-YOLOv3
Commit Name: ac7bb33dd978e2bf6ecb0cf055dd6bf6c9c1ea05
Time: 2019-04-19
Author: eriklindernoren@live.se
File Name: train.py
Class Name:
Method Name:


Project Name: HsinYingLee/DRIT
Commit Name: 8776ca2dcfa98412a6dafc33d360ee1ba0d1b551
Time: 2018-07-25
Author: james371507@gmail.com
File Name: src/test.py
Class Name:
Method Name: main


Project Name: ncullen93/torchsample
Commit Name: f4ca9b361adb382423c753f7f864a5dd0e454964
Time: 2017-05-12
Author: ncullen.th@dartmouth.edu
File Name: torchsample/transforms/tensor_transforms.py
Class Name: ToCuda
Method Name: __call__