Closed allenanie closed 7 years ago
It's due to a change in the new pytorch.
For pytorch>=0.2, they decided that the .sum(k), .max(k) etc operations would not let an "empty dimension at k" (i.e a dimension k =1). For pytorch<0.2, we needed to do a "squeeze(k), but now the .squeeze(k) has been included in the above operations. That's why it creates a "dimension out of range" because it's trying to do a squeeze(1) on the second dimension, while there's only 1 dimension ("0").
Since we should all move to pytorch 0.2, I'll make these changes (that should only require removing these "squeeze()") asap and change the requirements "Pytorch>=0.2" in the README.
A temporary for you fix would be to remove the "squeeze(1)" here: https://github.com/facebookresearch/SentEval/blob/master/senteval/tools/classifier.py#L144
Made the modifications in https://github.com/facebookresearch/SentEval/commit/91f82751add3fea2cafc8afc16dc45ef72127850 let me know if that fixed the issue. It should.
Hi, I've been running SentEval just fine for a couple of weeks, and today, after transferring to a new machine (with PyTorch 0.2), all of a sudden I can't evaluate on TREC anymore.
This is not a problem for any other tasks, so I'm wondering why. Does this mean my TREC data is corrupted or is this a problem with PyTorch 0.2?
How come all other evaluation tasks (that all use
classifier.py
) are fine except TREC...does anyone have any suggestions?