Deep Q-networks
Semi-gradient Q-learning, the deadly triad, replay and target networks, Double DQN and Rainbow.
From a table to a network
Tabular Q-learning needs one entry per state. An Atari stack of four grey frames can take values; cart-pole has continuous angles. Values must come from a function with far fewer parameters that also generalizes across similar states.
Semi-gradient Q-learning
Treat Q-learning as regression on its own target (or if terminal), holding fixed in the gradient:
This is a semi-gradient: the full gradient of would also move the target. With a table the update collapses to tabular Q-learning; with a network it comes from backpropagation.
The deadly triad
Function approximation + bootstrapping + off-policy data can diverge even without noise (Sutton and Barto §11.3). Toy: features and , shared weight , transition with reward . The update multiplies by ; for , that factor is , and after updates grows from to about . Remove any one leg and the same example converges. DQN stays inside the triad; it makes each step look more like supervised regression.
Replay and the target network
Key idea. Store transitions in a replay buffer and train on random minibatches; compute targets with a frozen copy refreshed every steps:
Replay breaks correlation and reuses data (off-policy). The target network holds labels still between copies — fitted Q-iteration with a network. On CartPole, without a target network reached millions while true values cannot exceed ; with both devices the pole balances for hundreds of steps. On 49 Atari games one architecture and one hyperparameter set beat prior ML methods on 43.
Double DQN and Rainbow
: ten equal actions with noise overestimate by about . Double DQN chooses with the online net and evaluates with the target net. Dueling heads, prioritized replay, multi-step returns, distributional RL and noisy nets each fix one weakness; Rainbow combines them (median human-normalized score vs DQN’s on 57 games). Prioritized replay and multi-step targets mattered most in ablations.
Limits and next
No convergence guarantee remains. The needs a small discrete action set; continuous torques and softmax policies over tens of thousands of tokens need something else. Next: drop the value table and ascend the gradient of expected return — policy gradients and actor–critic, ending at PPO.
Check your understanding
The same questions as in Pulse. Answers are shared between modes.
Answers are saved on the server and tied to this browser until you sign in.