Skip to content
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

Dimension mismatch in GCN with DisjointLoader and node_level=True #452

Open
prevay opened this issue May 2, 2024 · 0 comments
Open

Dimension mismatch in GCN with DisjointLoader and node_level=True #452

prevay opened this issue May 2, 2024 · 0 comments

Comments

@prevay
Copy link

prevay commented May 2, 2024

I have a custom dataset with multiple graphs that I want to run a node classification task on using a GCN. As a proof of concept I start with the Citation GCN example, and instead read in one of the included datasets with multiple graphs (like QM7) and load the data using DisjointLoader with node_level=True. However, this results in a dimension mismatch when applying the second convolutional layer. Specifically, I get the following error:

Dimensions must be equal, but are 1 and 289 for '{{node gcn_1/gcn_conv_1_2/MatMul_1}} = MatMul[T=DT_FLOAT, grad_a=false, grad_b=false, transpose_a=false, transpose_b=false](inputs_3, gcn_1/gcn_conv_1_2/MatMul)' with input shapes: [289,1], [289,14].

This particular example is for a single graph (batch_size=1) with a (16,16) SparseTensor for the adjacency matrix, a (256,1) ndarray for edge features and a (16,) ndarray for node features.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant