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
when I run the code of dense modul, a error arise: RuntimeError: input must have 3 dimensions, got 2
File "F:\jupyter project\菜鸟的自我拯救\20Urban Traffic Prediction36\Dense module\training.py", line 203, in
y_time = evaluate_temp_att(temporal_encoder, temporal_decoder, x_time, opt.n_out_sp, device)
File "F:\jupyter project\菜鸟的自我拯救\20Urban Traffic Prediction36\Dense module\utils.py", line 201, in evaluate_temp_att
encoder_output, h = encoder(batch,h)
File "E:\anconda\lib\site-packages\torch\nn\modules\module.py", line 722, in _call_impl
result = self.forward(*input, **kwargs)
File "../Temporal module\bahdanau_att.py", line 48, in forward
output, hidden = self.lstm(inputs, hidden)
File "E:\anconda\lib\site-packages\torch\nn\modules\module.py", line 722, in _call_impl
result = self.forward(*input, **kwargs)
File "E:\anconda\lib\site-packages\torch\nn\modules\rnn.py", line 574, in forward
self.check_forward_args(input, hx, batch_sizes)
File "E:\anconda\lib\site-packages\torch\nn\modules\rnn.py", line 525, in check_forward_args
self.check_input(input, batch_sizes)
File "E:\anconda\lib\site-packages\torch\nn\modules\rnn.py", line 175, in check_input
expected_input_dim, input.dim()))
RuntimeError: input must have 3 dimensions, got 2
The text was updated successfully, but these errors were encountered:
when I run the code of dense modul, a error arise: RuntimeError: input must have 3 dimensions, got 2
File "F:\jupyter project\菜鸟的自我拯救\20Urban Traffic Prediction36\Dense module\training.py", line 203, in
y_time = evaluate_temp_att(temporal_encoder, temporal_decoder, x_time, opt.n_out_sp, device)
File "F:\jupyter project\菜鸟的自我拯救\20Urban Traffic Prediction36\Dense module\utils.py", line 201, in evaluate_temp_att
encoder_output, h = encoder(batch,h)
File "E:\anconda\lib\site-packages\torch\nn\modules\module.py", line 722, in _call_impl
result = self.forward(*input, **kwargs)
File "../Temporal module\bahdanau_att.py", line 48, in forward
output, hidden = self.lstm(inputs, hidden)
File "E:\anconda\lib\site-packages\torch\nn\modules\module.py", line 722, in _call_impl
result = self.forward(*input, **kwargs)
File "E:\anconda\lib\site-packages\torch\nn\modules\rnn.py", line 574, in forward
self.check_forward_args(input, hx, batch_sizes)
File "E:\anconda\lib\site-packages\torch\nn\modules\rnn.py", line 525, in check_forward_args
self.check_input(input, batch_sizes)
File "E:\anconda\lib\site-packages\torch\nn\modules\rnn.py", line 175, in check_input
expected_input_dim, input.dim()))
RuntimeError: input must have 3 dimensions, got 2
The text was updated successfully, but these errors were encountered: