RNN — PyTorch 1.10.1 documentation
https://pytorch.org/docs/stable/generated/torch.nn.RNN.htmlwhere h t h_t h t is the hidden state at time t, x t x_t x t is the input at time t, and h (t − 1) h_{(t-1)} h (t − 1) is the hidden state of the previous layer at time t-1 or the initial hidden state at time 0.If nonlinearity is 'relu', then ReLU \text{ReLU} ReLU is used instead of tanh \tanh tanh.. Parameters. input_size – The number of expected features in the input x