-
Notifications
You must be signed in to change notification settings - Fork 14
Open
Description
Insightful work!!!
During the study of your paper, I have some questions (My English is not very good, and I am not aggressive, just some confusion):
- The first problem is Figure 2. After Sigmoid, everything should be >= 0, but the figure still use threshold 0 to make decision. From the paper, I think there should be 0.5; or No Sigmoid used.
- The second problem is about the code.
if gumbel_noise:
eps = self.eps
U1, U2 = torch.rand_like(x), torch.rand_like(x)
g1, g2 = -torch.log(-torch.log(U1 + eps)+eps), - \
torch.log(-torch.log(U2 + eps)+eps)
x = x + g1 - g2
soft = torch.sigmoid(x / gumbel_temp)
hard = ((soft >= 0.5).float() - soft).detach() + soft
However, the paper said, "Note that this formulation has no logarithms or exponentials in the forward pass, typically expensive computations on hardware platforms"
So in the code, why not just use soft >= 0, and no sigmoid operation.
Thanks for your kind help!
LinyeLi60
Metadata
Metadata
Assignees
Labels
No labels