Traceback (most recent call last):


 "train.py", line 440, in <module>

main()


 "train.py", line 436, in main

trainModel(model, trainData, validData, dataset, optim)


 "train.py", line 274, in trainModel

train_stats = trainEpoch(epoch)


 "train.py", line 246, in trainEpoch

dec_state)


 "/home/bpop/anaconda3/lib/python3.6/site-packages/torch/nn/modules/module.py", line 206, in __call__

result = self.forward(*input, **kwargs)


 "/home/bpop/thesis/mg2p/OpenNMT-py/onmt/Models.py", line 400, in forward

else dec_state)


 "/home/bpop/anaconda3/lib/python3.6/site-packages/torch/nn/modules/module.py", line 206, in __call__

result = self.forward(*input, **kwargs)


 "/home/bpop/thesis/mg2p/OpenNMT-py/onmt/Models.py", line 314, in forward

rnn_output, hidden = self.rnn(emb_t, hidden)


 "/home/bpop/anaconda3/lib/python3.6/site-packages/torch/nn/modules/module.py", line 206, in __call__

result = self.forward(*input, **kwargs)


 "/home/bpop/thesis/mg2p/OpenNMT-py/onmt/modules/StackedRNN.py", line 52, in forward

h_1_i = layer(input, hidden[i])


 "/home/bpop/anaconda3/lib/python3.6/site-packages/torch/nn/modules/module.py", line 206, in __call__

result = self.forward(*input, **kwargs)


 "/home/bpop/anaconda3/lib/python3.6/site-packages/torch/nn/modules/rnn.py", line 568, in forward

self.bias_ih, self.bias_hh,


 "/home/bpop/anaconda3/lib/python3.6/site-packages/torch/nn/_functions/rnn.py", line 54, in GRUCell

gh = F.linear(hidden, w_hh, b_hh)


 "/home/bpop/anaconda3/lib/python3.6/site-packages/torch/nn/functional.py", line 449, in linear

return state(input, weight) if bias is None else state(input, weight, bias)


 "/home/bpop/anaconda3/lib/python3.6/site-packages/torch/nn/_functions/linear.py", line 10, in forward

output.addmm_(0, 1, input, weight.t())
RuntimeError: matrices expected, got 3D, 2D tensors at /py/conda-bld/pytorch_1493673470840/work/torch/lib/TH/generic/THTensorMath.c:1232

Traceback (most recent call last):


 "setup.py", line 1337, in build_extensions

torch_version = check_torch_version()


 "setup.py", line 1001, in check_torch_version

'import torch failed, is it installed?\n\n%s' % traceback.format_exc())
distutils.errors.DistutilsPlatformError: import torch failed, is it installed?
