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

VAE costs are nan #23

Closed
dantkz opened this issue Aug 19, 2016 · 2 comments
Closed

VAE costs are nan #23

dantkz opened this issue Aug 19, 2016 · 2 comments

Comments

@dantkz
Copy link

dantkz commented Aug 19, 2016

Hi!

First of all, thanks for the tutorials, I could pick up tensorflow really fast because of them!

I was running the variational autoencoder example (11_variational_autoencoder.py) and noticed that the reported costs are "nan". I suspect the problem is in line 77, where "tanh" can create negative values for "y" that are later fed into "log" in lines 81 and 82. I suggest changing "tanh" in line 77 to "sigmoid" (I checked and it solves the problem).

Cheers,

Daniyar

@dantkz
Copy link
Author

dantkz commented Aug 19, 2016

Also, the convergence is much faster with only two layers in both the encoder and decoder.

@pkmital
Copy link
Owner

pkmital commented Aug 23, 2016

ty! I have updated!

@pkmital pkmital closed this as completed Aug 23, 2016
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