How to input edge_attr into heterogeneous graph model #9097
-
Here I excerpt an example from the docs. If I want to input edge_attr into the model, how do I modify the following code?
How about modifying the code like this? But this method doesn’t seem to work. Because I tried to do this on my own dataset, but I got an error about dimension mismatch.
|
Beta Was this translation helpful? Give feedback.
Replies: 2 comments 4 replies
-
This generally works, but it depends a bit how your GNN layers are defined. Can you share more details about how your model |
Beta Was this translation helpful? Give feedback.
-
Hi, I have a related question- during the batch sampling, my Here's my data:
Loader:
Batch:
|
Beta Was this translation helpful? Give feedback.
You need to also specify
edge_dim=-1
when defining your GNN layers.