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

Difference of readout function in code vs. paper #12

Open
Dinxin opened this issue Apr 10, 2021 · 1 comment
Open

Difference of readout function in code vs. paper #12

Dinxin opened this issue Apr 10, 2021 · 1 comment

Comments

@Dinxin
Copy link

Dinxin commented Apr 10, 2021

We noticed that the readout function in the original paper is concatenation, while the one in code implementation is addition.

@rusty1s
Copy link
Owner

rusty1s commented Apr 12, 2021

This is actually the same, but utilizing transformation and addition is a bit more memory-efficient:

x = self.lin(torch.cat([x1, x2], dim=-1))

is equal to

x = self.lin1(x1) + self.lin(x2)

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