Skip to content
Discussion options

You must be logged in to vote

I think this looks pretty good, but you are missing the initial coordinates in your function (we usually call them pos in PyG). So that would now look something like:

def forward(self, x, pos, edge_index):
    return x + self.lin(self.propagate(edge_index, x=x, pos=pos))

def message(self, pos_j, pos_i, x_i, x_j):
    return torch.cat([pos_j - pos_i + self.lin(x_i), x_j], dim=-1)

Replies: 1 comment 2 replies

Comment options

You must be logged in to vote
2 replies
@andreasbinder
Comment options

@rusty1s
Comment options

Answer selected by andreasbinder
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Q&A
Labels
None yet
2 participants