-
Notifications
You must be signed in to change notification settings - Fork 52
Adding Graphormer layer #275
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
Conversation
Codecov Report
@@ Coverage Diff @@
## master #275 +/- ##
==========================================
- Coverage 82.36% 80.74% -1.62%
==========================================
Files 17 19 +2
Lines 1911 1958 +47
==========================================
+ Hits 1574 1581 +7
- Misses 337 377 +40
... and 11 files with indirect coverage changes Help us with your feedback. Take ten seconds to tell us how you rate us. Have a feature suggestion? Share it here. |
src/layers/conv.jl
Outdated
@@ -1688,3 +1688,83 @@ function Base.show(io::IO, l::TransformerConv) | |||
(in, ein), out = l.channels | |||
print(io, "TransformerConv(($in, $ein) => $out, heads=$(l.heads))") | |||
end | |||
|
|||
@doc raw""" | |||
GraphormerLayer constructor. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
make the docstring style consistent with the other layers
src/layers/conv.jl
Outdated
Wx = reshape(Wx, chout, heads, :) | ||
|
||
# a hand-written message passing | ||
m = apply_edges((xi, xj, e) -> message(l, xi, xj, e), g, Wx, Wx, e) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
where is the message function defined?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Apologies I missed writing it I added the comment to go back and add that let me get on to this
This is not capturing the essential features of the paper:
|
Why you checked the tests as done? I see no tests... |
I have written some tests you can check here |
Co-authored-by: Carlo Lucibello <carlo.lucibello@gmail.com>
@CarloLucibello Hi can you look into the updates and see the tests? |
can you make the tests part of this PR? it's weird they are somewhere else |
Hello @CarloLucibello Sorry for delayed response on this I believe we still need this layer, I redone each line of code after reading through the paper and more Julia blogs (mostly linked to flux) to have better understanding. |
Continued from #265
fixes #251
To do: