liveBook · Manning

Recurrent neural network

As explained in Data Without Labels

A recurrent neural network is a neural-network architecture designed to model sequences through recurrent state or connections.

A recurrent neural network (RNN) models ordered data by carrying information from earlier inputs into later computations. It is suited to time-series data, videos, natural language, and other sequential datasets where order matters. section 8.7 section 8.7.1

An RNN processes a sequence one time step at a time:

  • Receives the current input xₜ together with the previous hidden state hₜ₋₁. section 8.7.1
  • Updates the hidden state hₜ through a nonlinear function, preserving information from earlier inputs. section 8.7.1
  • Produces an output at every time step or uses only the final output, depending on the task. section 8.7.1
  • Reuses the same weights across time steps, reducing the number of parameters while applying one network throughout the sequence. section 8.7.1

The recurrent connection feeds each time step's output information into the next. This persistent state acts as memory and helps the network recognize temporal dependencies. A basic RNN can struggle with long-term dependencies because gradients may vanish or explode, limiting its ability to retain information from far back in a sequence. section 8.7.1

Where RNNs fit

Use sequence models for time-series data, video, natural-language processing, speech recognition, or other data whose order carries meaning. For longer dependencies, long short-term memory (LSTM) networks use input, forget, and output gates to regulate information flow; gated recurrent units provide another related option. section 8.7 section 8.7.1

Figure 8.14 The RNN process. RNNs have internal memory, which allows them to use information from the previous inputs to influence the current input and outputs.
figure

Trace how internal memory carries previous inputs forward to influence current inputs and outputs. section 8.7.1

How Data Without Labels covers it

How deep it goes
Defines recurrent state, shared weights, outputs, and gradient limits, but defers detailed LSTM and gated-unit treatment.
Examples
Uses time-series data, videos, natural language, speech recognition, and other ordered datasets as application contexts.
What you can do after
Evaluate sequence-modeling choices by relating order, recurrent memory, and long-term dependency limits to data requirements.
How it connects
Connects recurrent state to sequential data, feed-forward networks, temporal dependencies, LSTM, and gated recurrent units.

Also explained in

Compare how 10 books explain recurrent neural network →

Related concepts

This explainer was generated by Manning's knowledge graph from the text of Data Without Labels. The section links point to the parts of the book it draws on.