Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

discriminator error from noise #2

Open
LondaniZuma opened this issue Apr 27, 2022 · 1 comment
Open

discriminator error from noise #2

LondaniZuma opened this issue Apr 27, 2022 · 1 comment

Comments

@LondaniZuma
Copy link

Hi @luisguiserrano , thanks a lot about this friendly intro to GAN, it is really helpful. But I have a question about the code in the notebook where you calculate the error for discriminator. Use calculate the error using <errors_discriminator.append(sum(D.error_from_image(face) + D.error_from_noise(z)))>. When you calculate the error from noise you pass which is the random number, shouldn't you pass the noise generated by the generator i.e <G.forward(z)>. So the error for discriminator is <errors_discriminator.append(D.error_from_image(face) + D.error_from_noise(G.forward(z)))>??

@josedavid220
Copy link

Hi @LondaniZuma, you are correct. The error should be computed with G.forward(z), i.e. a generated image, and not from the z value itself. Maybe it's because the complexity is low that things work nonetheless. I changed this locally and the results are the same.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants