Handling Linear layer dimesions with graph sizes across batches #4260
-
Hi everyone, Now, I am unsure how to use another linear layer on top of this |
Beta Was this translation helpful? Give feedback.
Replies: 1 comment 1 reply
-
You need to make use of permutation-invariant pooling operators to go from node-level features/scalars to graph-level ones, e.g., via x = self.lin1(x)
x = global_mean_pool(x, cluster_index)
x = self.lin2(x) |
Beta Was this translation helpful? Give feedback.
You need to make use of permutation-invariant pooling operators to go from node-level features/scalars to graph-level ones, e.g., via
torch_geometric.nn.global_mean_pool
: