-
Hi pytorch-geo community! I have a GNN for graph classification - it is basically an extension of GAT with an encoder/decoder followed by some pooling and an MLP for classification. The number of possible nodes in my dataset is around 80,000. The input features are either learned using When I create my graph datasets, I do the following node_features = self.embedding.transform(torch.arange(self.num_nodes).long())
data = [Data(x=node_features, edge_index=y.long(),) for y in edge_index]
batch = Batch.from_data_list(data) In this case, we have the observed edges for each graph stored in Is there a way to get around this? I initially tried only passing features of the observed nodes such as Many thanks for any suggestions :) |
Beta Was this translation helpful? Give feedback.
Replies: 1 comment 6 replies
-
AFAIK, |
Beta Was this translation helpful? Give feedback.
AFAIK,
edge_index
does not contain connections of all 80,000 nodes, right? With that, you can probably convertdata
into a subgraph that only hold the nodes that are contained inedge_index.unique()
, e.g., viatorch_geometric.utils.subgraph
.