MichSchli / GraphMask

Official implementation of GraphMask as presented in our paper Interpreting Graph Neural Networks for NLP With Differentiable Edge Masking.
MIT License
41 stars 10 forks source link

WARNING:allennlp.models.model:Encountered the antecedent_indices key in the model's return dictionary which couldn't be split by the batch size. Key will be ignored. #2

Open louiswng opened 3 years ago

louiswng commented 3 years ago

Hi, I run your code to train the model on QA dataset using command python train_model.py --configuration configurations/qa.json. However, there is a WARNING bug when it begins as:

Building the train set (or loading from cache if possible): 4%| | 1965/43738 [00:09<04:01, WARNING:allennlp.models.model:Encountered the antecedent_indices key in the model's return dictionary which couldn't be split by the batch size. Key will be ignored.

And then, the Building the train set process have no response all the day.

Why is that? Can you help me with it?

My Environment:

MichSchli commented 3 years ago

Hi, that sounds quite strange. I haven't been able to replicate this behaviour. This error originates from the AllenNLP coreference resolver. Would you please try with PyTorch 1.8.1 to ensure that we have the same versions, and verify that you do have the right version of AllenNLP (the model only works with 0.9.0)?

louiswng commented 3 years ago

I am sure the version of AllenNLP in my environment is 0.9.0, and I will try the pytorch version you mention.