Skip to content

Hidden Size Error #22

@Brandon-EME

Description

@Brandon-EME

Hi,

Apologies if this question seems rudimentary however when running train.py I am getting a hidden state size error for the RNN module within torch.nn. Reviewing the code it seems that the hidden state size defined in forward is based on the previous state, rather than the output required for the current state, is this correct. I'm quite surprised this issue isn't present for anyone else as it occurs just by my running train.py so don't know if I am misunderstanding something or if there is a version error somewhere.

Error in Ipython terminal:

File ~\AppData\Local\anaconda3\envs\ntmselfbuild\Lib\site-packages\torch\nn\modules\rnn.py:260 in check_hidden_size
raise RuntimeError(msg.format(expected_hidden_size, list(hx.size())))

RuntimeError: Expected hidden[0] size (1, 1, 100), got [1, 1, 29]

Many thanks.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions