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

about lesson8:DCGAN #1

Open
backkon opened this issue Oct 21, 2020 · 5 comments
Open

about lesson8:DCGAN #1

backkon opened this issue Oct 21, 2020 · 5 comments

Comments

@backkon
Copy link

backkon commented Oct 21, 2020

Why do I get the log as shown below:

[0/20][0/32]	Loss_D: 1.8010	Loss_G: 8.0963	D(x): 0.4317	D(G(z)): 0.3617 / 0.0005
[0/20][10/32]	Loss_D: 7.5290	Loss_G: 38.1183	D(x): 0.9269	D(G(z)): 0.9958 / 0.0000
[0/20][20/32]	Loss_D: 0.0425	Loss_G: 58.4481	D(x): 0.9731	D(G(z)): 0.0000 / 0.0000
[0/20][30/32]	Loss_D: 0.2492	Loss_G: 57.3842	D(x): 0.9787	D(G(z)): 0.0000 / 0.0000
[1/20][0/32]	Loss_D: 0.0000	Loss_G: 56.7433	D(x): 1.0000	D(G(z)): 0.0000 / 0.0000
[1/20][10/32]	Loss_D: 0.0000	Loss_G: 56.9849	D(x): 1.0000	D(G(z)): 0.0000 / 0.0000
[1/20][20/32]	Loss_D: 0.0001	Loss_G: 56.8024	D(x): 0.9999	D(G(z)): 0.0000 / 0.0000
[1/20][30/32]	Loss_D: 0.0000	Loss_G: 57.0740	D(x): 1.0000	D(G(z)): 0.0000 / 0.0000

The outputs have always been noise, I am running according to the source code, where is the problem?

@zhangxiann
Copy link
Owner

zhangxiann commented Oct 22, 2020

I haven`t encountered this problem.
here is my log:

[0/20][0/32]	Loss_D: 2.2277	Loss_G: 15.5083	D(x): 0.5273	D(G(z)): 0.6209 / 0.0000
[0/20][10/32]	Loss_D: 0.2962	Loss_G: 46.8450	D(x): 0.9128	D(G(z)): 0.0000 / 0.0000
[0/20][20/32]	Loss_D: 0.0020	Loss_G: 52.9141	D(x): 0.9982	D(G(z)): 0.0000 / 0.0000
[0/20][30/32]	Loss_D: 0.2574	Loss_G: 51.1907	D(x): 0.9840	D(G(z)): 0.0000 / 0.0000
[1/20][0/32]	Loss_D: 0.0000	Loss_G: 51.1631	D(x): 1.0000	D(G(z)): 0.0000 / 0.0000
[1/20][10/32]	Loss_D: 0.0005	Loss_G: 51.2719	D(x): 0.9995	D(G(z)): 0.0000 / 0.0000
[1/20][20/32]	Loss_D: 0.0001	Loss_G: 50.5107	D(x): 0.9999	D(G(z)): 0.0000 / 0.0000
[1/20][30/32]	Loss_D: 0.0000	Loss_G: 50.6817	D(x): 1.0000	D(G(z)): 0.0000 / 0.0000
[2/20][0/32]	Loss_D: 0.0000	Loss_G: 50.4814	D(x): 1.0000	D(G(z)): 0.0000 / 0.0000
[2/20][10/32]	Loss_D: 0.0000	Loss_G: 50.3472	D(x): 1.0000	D(G(z)): 0.0000 / 0.0000
[2/20][20/32]	Loss_D: 0.0000	Loss_G: 50.2126	D(x): 1.0000	D(G(z)): 0.0000 / 0.0000

Perhaps you can try to run more epochs.

@backkon
Copy link
Author

backkon commented Oct 22, 2020

Your log is about the same as mine. Why is D(G(z)) 0/0? The second term of D(G(z)) should be getting closer and closer to 1?

@zhangxiann
Copy link
Owner

  • D(G(z)) denotes the predicted probability of generate(fake) images.
  • D(x) denotes the predicted probability of real images.
    I think, for the discriminator,it should try to distinguish the real and fake images.
    So the D(x) is getting closer to 1, the D(G(z)) is getting closer to 0.

@backkon
Copy link
Author

backkon commented Oct 22, 2020

I got results as shown below:
屏幕截图 2020-10-22 104309
loss

@zhangxiann
Copy link
Owner

zhangxiann commented Nov 16, 2020

Wait, I will try to find out waht`s happening.

Repository owner deleted a comment Feb 2, 2024
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