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

error in "traditional" Gumbel Softmax trick #1

Closed
balcilar opened this issue Nov 13, 2021 · 4 comments
Closed

error in "traditional" Gumbel Softmax trick #1

balcilar opened this issue Nov 13, 2021 · 4 comments

Comments

@balcilar
Copy link

Thanks for the Discete VAE demo.
Seems there is small error in "def sample_gumbel(self, shape, eps=1e-20): " function.
U is not assigned. It seems to be U= tf.random.uniform(shape, minval=0, maxval=1) ?

@mniepert
Copy link
Collaborator

Yes thanks a lot. This was a problem I probably introduced when cleaning up the code. I’ll push the fix tomorrow.

@mniepert
Copy link
Collaborator

Fixed the typo

@balcilar
Copy link
Author

Thanks. But this time seems temperature is treated as it is eps parameter in "def sample_gumbel(self, shape, eps=1e-20)" function.
It seems to be called by
y = logits + self.sample_gumbel(tf.shape(logits)) ?

@mniepert
Copy link
Collaborator

Fixed as well. The temperature as second argument is not correct. It is not used in sample_gumbel()

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