ganhacks icon indicating copy to clipboard operation
ganhacks copied to clipboard

Discriminator with accuracy 1, generator fools it perfectly. What's going on?

Open danielegrattarola opened this issue 5 years ago • 5 comments

I'm training a GAN where the discriminator has almost perfect accuracy (generated samples are classified 0, true samples are classified 1), but at the same time the generator is able to produce samples that fool the discriminator perfectly (always classified 1). I'm guessing this is a vanishing gradient problem, but I cannot figure out how to solve it. All usual hacks don't seem to work.

Does anybody have some suggestions?

danielegrattarola avatar Aug 27 '18 13:08 danielegrattarola

I'm training a GAN where the discriminator has almost perfect accuracy (generated samples are classified 0, true samples are classified 1), but at the same time the generator is able to produce samples that fool the discriminator perfectly (always classified 1). I'm guessing this is a vanishing gradient problem, but I cannot figure out how to solve it. All usual hacks don't seem to work.

Does anybody have some suggestions?

What does the output look like by the generator?

davesean avatar Oct 24 '18 12:10 davesean

It is due to mode Collapse. The Generator knows some samples that can fool the discriminator and it always produces the same and fools D

adv-ai-tech avatar Nov 09 '18 13:11 adv-ai-tech

I have the same problem. I solved this by modifying the net architecture of D, perhaps it is because the previous D is easy to fool.

zyong812 avatar Jul 27 '19 01:07 zyong812

It is due to mode Collapse. The Generator knows some samples that can fool the discriminator and it always produces the same and fools D

so, how to solve it?

micklexqg avatar Aug 01 '19 05:08 micklexqg

I have the same problem. I solved this by modifying the net architecture of D, perhaps it is because the previous D is easy to fool.

i used the paper D and did not do any change , but it was still the same. why i came across the problem while they did not?

micklexqg avatar Aug 01 '19 05:08 micklexqg