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
train.py fails on both training from scratch and using a pre-trained model with the following error:
File "/RelationNetworks-CLEVR/utils.py", line 120, in collate_samples
question=torch.stack(padded_questions)
TypeError: stack(): argument 'tensors' (position 1) must be tuple of Tensors, not Tensor
The text was updated successfully, but these errors were encountered:
I think this issue is related with pytorch version you're using. Have you installed dependencies from the requirements.txt inside a virtualenv as explained in README?
As of now, this code works with pytorch 0.3.1. In later versions torch.stack() takes a sequence of Tensors as argument, so, if you are using a newer version of pytorch, torch.stack(list(padded_questions)) should work.
However, other things should be adjusted if you use another version. Hence, I encourage you to install version 0.3.1 inside a virtualenv.
train.py
fails on both training from scratch and using a pre-trained model with the following error:The text was updated successfully, but these errors were encountered: