675d1e61ca2cac2e6d09781e1c8406466bc32867,loss.py,GeneratorLoss,forward,#GeneratorLoss#Any#Any#Any#,16

Before Change



    def forward(self, out_labels, out_images, target_images):
        // Adversarial Loss
        adversarial_loss = torch.mean(torch.log(1 - out_labels))
        // Perception Loss
        perception_loss = self.mse_loss(self.loss_network(out_images), self.loss_network(target_images))
        // Image Loss
        image_loss = self.mse_loss(out_images, target_images)

After Change



    def forward(self, out_labels, out_images, target_images):
        // Adversarial Loss
        adversarial_loss = - out_labels.mean()
        // Perception Loss
        perception_loss = self.mse_loss(self.loss_network(out_images), self.loss_network(target_images))
        // Image Loss
        image_loss = self.mse_loss(out_images, target_images)
Italian Trulli
In pattern: SUPERPATTERN

Frequency: 3

Non-data size: 5

Instances


Project Name: leftthomas/SRGAN
Commit Name: 675d1e61ca2cac2e6d09781e1c8406466bc32867
Time: 2017-12-02
Author: leftthomas@qq.com
File Name: loss.py
Class Name: GeneratorLoss
Method Name: forward


Project Name: leftthomas/SRGAN
Commit Name: e427b44f4291a663b0181b8319181f470bd9d1cd
Time: 2017-12-02
Author: leftthomas@qq.com
File Name: loss.py
Class Name: GeneratorAdversarialWithContentLoss
Method Name: forward


Project Name: leftthomas/SRGAN
Commit Name: a00032aa2381eac483eb21efd7909ccc70f2f07e
Time: 2017-12-04
Author: leftthomas@qq.com
File Name: loss.py
Class Name: GeneratorLoss
Method Name: forward