PyTorch-GAN icon indicating copy to clipboard operation
PyTorch-GAN copied to clipboard

Problem in ClusterGAN

Open zhiqi-li opened this issue 5 years ago • 2 comments

The problem is in clustergan.py:

443:     ge_loss = torch.mean(D_gen) + betan * zn_loss + betac * zc_loss
465      d_loss = torch.mean(D_real) - torch.mean(D_gen) + grad_penalty

I think it shoud be

443     ge_loss = -torch.mean(D_gen) + betan * zn_loss + betac * zc_loss
465     d_loss = -torch.mean(D_real) + torch.mean(D_gen) + grad_penalty

zhiqi-li avatar Oct 23 '19 13:10 zhiqi-li

I think you're right. Because that's what wgan's formula is supposed to be. Have you seen the difference between the two? thank you!

yangjunting100 avatar Jul 20 '20 10:07 yangjunting100

I did an experiment and found that the two formulas loss converges to almost the same. The quality of image generation is similar. Wonder if MNIST is too simple or the formula itself??

yangjunting100 avatar Jul 20 '20 14:07 yangjunting100