0368a2665b52b843785ffe0b18b3154fd32539b0,pro_gan_pytorch/Losses.py,CondLSGAN_SIGMOID,gen_loss,#CondLSGAN_SIGMOID#,388

Before Change



    def gen_loss(self, _, fake_samps, labels, height, alpha):
        from torch.nn.functional import sigmoid
        scores = th.mean(sigmoid(self.dis(fake_samps, labels, height, alpha)))
        return 0.5 * ((scores - 1) ** 2)


class CondHingeGAN(ConditionalGANLoss):

After Change



    def gen_loss(self, _, fake_samps, labels, height, alpha):
        from torch.nn.functional import sigmoid
        scores = sigmoid(self.dis(fake_samps, labels, height, alpha))
        return 0.5 * (th.mean((scores - 1) ** 2))


class CondHingeGAN(ConditionalGANLoss):
Italian Trulli
In pattern: SUPERPATTERN

Frequency: 4

Non-data size: 6

Instances


Project Name: akanimax/pro_gan_pytorch
Commit Name: 0368a2665b52b843785ffe0b18b3154fd32539b0
Time: 2019-01-04
Author: akanimax@gmail.com
File Name: pro_gan_pytorch/Losses.py
Class Name: CondLSGAN_SIGMOID
Method Name: gen_loss


Project Name: akanimax/pro_gan_pytorch
Commit Name: 0368a2665b52b843785ffe0b18b3154fd32539b0
Time: 2019-01-04
Author: akanimax@gmail.com
File Name: pro_gan_pytorch/Losses.py
Class Name: CondLSGAN_SIGMOID
Method Name: dis_loss


Project Name: akanimax/pro_gan_pytorch
Commit Name: 0368a2665b52b843785ffe0b18b3154fd32539b0
Time: 2019-01-04
Author: akanimax@gmail.com
File Name: pro_gan_pytorch/Losses.py
Class Name: LSGAN_SIGMOID
Method Name: dis_loss


Project Name: akanimax/pro_gan_pytorch
Commit Name: 0368a2665b52b843785ffe0b18b3154fd32539b0
Time: 2019-01-04
Author: akanimax@gmail.com
File Name: pro_gan_pytorch/Losses.py
Class Name: LSGAN_SIGMOID
Method Name: gen_loss