pyg-team / pytorch_geometric

Graph Neural Network Library for PyTorch
https://pyg.org
MIT License
21.01k stars 3.62k forks source link

errors about DiffPool for IMDB-B. IMDB-M datasets. #3079

Closed dongZheX closed 3 years ago

dongZheX commented 3 years ago

🐛 Bug

To Reproduce

Steps to reproduce the behavior:

  1. I use benchmark/kernel/ to evaluate DiffPool on IMDB-M, IMDB-B datasets.
  2. I use latest code.

I meet the error:

File "J:###\xxxx\train_eval.py", line 19, in cross_validation_with_val_set ) in enumerate(zip(k_fold(dataset, folds))): File "J:###\xxxx\train_eval.py", line 83, in kfold for , idx in skf.split(torch.zeros(len(dataset)), dataset.data.y): File "D:\Anaconda3\envs\torch\lib\site-packages\sklearn\model_selection_split.py", line 324, in split X, y, groups = indexable(X, y, groups) File "D:\Anaconda3\envs\torch\lib\site-packages\sklearn\utils\validation.py", line 356, in indexable check_consistent_length(result) File "D:\Anaconda3\envs\torch\lib\site-packages\sklearn\utils\validation.py", line 320, in check_consistent_length " samples: %r" % [int(l) for l in lengths]) ValueError: Found input variables with inconsistent numbers of samples: [****, ####]

It is ok for DiffPool on other datasets e.g NCI1, MUTAG.

rusty1s commented 3 years ago

Thanks for letting me know. This is now fixed in master, see here.

dongZheX commented 3 years ago

Thanks for letting me know. This is now fixed in master, see here.

Thanks !!!!!!!!!!!!!!!!!!! God bless you!!!