You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Recently I was using the gnn module to predict the classification task, and I wanted to use the interpretation model to explain the predicted data, but the model had edge_attr during use, so when using PGExplainer, the parameters were wrong. So I checked the code in the explain module and found that the model parameter does not have edge_attr, so I wanted to ask if I could use the gnn model with edge_attr.
Errors Encountered
for batch in testloader:
21 loss = explainer.algorithm.train(
---> 22 epoch, model, batch.x, batch.edge_index, batch.edge_attr,target=batch.y)
23
24 # Generate the explanation for a particular graph:
TypeError: train() takes 5 positional arguments but 6 positional arguments (and 1 keyword-only argument) were given
reacted with thumbs up emoji reacted with thumbs down emoji reacted with laugh emoji reacted with hooray emoji reacted with confused emoji reacted with heart emoji reacted with rocket emoji reacted with eyes emoji
Uh oh!
There was an error while loading. Please reload this page.
-
Recently I was using the gnn module to predict the classification task, and I wanted to use the interpretation model to explain the predicted data, but the model had edge_attr during use, so when using PGExplainer, the parameters were wrong. So I checked the code in the explain module and found that the model parameter does not have edge_attr, so I wanted to ask if I could use the gnn model with edge_attr.
Errors Encountered
for batch in testloader:
21 loss = explainer.algorithm.train(
---> 22 epoch, model, batch.x, batch.edge_index, batch.edge_attr,target=batch.y)
23
24 # Generate the explanation for a particular graph:
TypeError: train() takes 5 positional arguments but 6 positional arguments (and 1 keyword-only argument) were given
Beta Was this translation helpful? Give feedback.
All reactions