Skip to content

Commit

Permalink
Update message_passing.py (#4418)
Browse files Browse the repository at this point in the history
When using a bipartite graph for reverse message passing(set flow == 'target_to_source'), the message construction fails due to incorrect dim_size, although it doesn't matter, and different adjacency matrices can be used to achieve the same effect.
  • Loading branch information
irrational1005 authored Apr 6, 2022
1 parent 2f6fdef commit c30d371
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions torch_geometric/nn/conv/message_passing.py
Original file line number Diff line number Diff line change
Expand Up @@ -241,8 +241,8 @@ def __collect__(self, args, edge_index, size, kwargs):

out['index'] = out['edge_index_i']
out['size'] = size
out['size_i'] = size[1] if size[1] is not None else size[0]
out['size_j'] = size[0] if size[0] is not None else size[1]
out['size_i'] = size[i] if size[i] is not None else size[j]
out['size_j'] = size[j] if size[j] is not None else size[i]
out['dim_size'] = out['size_i']

return out
Expand Down

0 comments on commit c30d371

Please sign in to comment.