A hidden state is the recurrent representation that carries sequence information between processing steps. At step t, an RNN combines the current input with the previous state hₜ₋₁, produces an output, and passes the new state hₜ to the next step. section 6.5.1
A recurrent update follows a short pipeline:
- Use a GRU’s update gate to retain or replace information and its reset gate to control what is forgotten. section 6.5.1 section 6.4.2
In spatiotemporal graph models, hidden states can represent nodes rather than an entire sequence. A graph decoder uses edge-derived messages to update each node’s state, then uses the updated representations to predict future frames. section 6.4.2
PyTorch recurrent model
A compact sequence model creates h0 with shape (num_layers, batch_size, hidden_size), moves it to the input device, and calls nn.GRU(x, h0). A linear layer then maps recurrent outputs to predictions, such as the final ten time steps.
