Deep Reinforcement Learning and The Tale of Two Temporal Difference Errors
Organizations: University of Toronto, Canada
Abstract
The temporal difference (TD) error was first formalized in Sutton (1988), where it was first characterized as the difference between temporally successive predictions, and later, in that same work, formulated as the difference between a bootstrapped target and a prediction. Since then, these two interpretations of the TD error have been used interchangeably in the literature, with the latter eventually being adopted as the standard critic loss in deep reinforcement learning (RL) architectures. In this work, we show that these two interpretations of the TD error are not always equivalent. In particular, we show that increasingly-nonlinear deep RL architectures can cause these interpretations of the TD error to yield increasingly different numerical values. Then, building on this insight, we show how choosing one interpretation of the TD error over the other can affect the performance of deep RL algorithms that utilize the TD error to compute other quantities, such as with deep differential (i.e., average-reward) RL methods. All in all, our results show that the default interpretation of the TD error as the difference between a bootstrapped target and a prediction does not always hold in deep RL settings.
Figures & tables
Appendix figures & tables5 assets
Supplementary material from the paper’s appendix.
Appendix
| Layer | Input Shape | Output Shape | Calculation Formula | Parameters |
| conv1 | 4,112 | |||
| conv2 | 8,224 | |||
| conv3 | 9,248 | |||
| fc1 | 1,568 | 256 | 401,664 | |
| fc2 | 256 | 4 | 1,028 | |
| Total | 424,276 |
| Layer | Input Shape | Output Shape | Calculation Formula | Parameters |
| conv1 | 16,448 | |||
| conv2 | 131,200 | |||
| conv3 | 147,584 | |||
| fc1 | 6,272 | 1,024 | 6,423,552 | |
| fc2 | 1,024 | 4 | 4,100 | |
| Total | 6,722,884 |
Temporal-Difference Learning
Temporal-difference learning estimates values by bootstrapping from later predictions, enabling online learning and control from sequential experience.
See all 80 papersA Diffusion Approximation for Temporal-Difference Learning with Linear Features under Markovian Noise
Trace-Mediated Peak Bias: Bridging Temporal Credit Assignment and Cognitive Heuristics in Deep Reinforcement Learning
peaks'' over alternatives with higher cumulative returns. This provides a mechanistic account of the Peak-End Rule: a human memory bias where experiences are judged by their most intense moments rather than integrated utility. We show that TMPB emerges because traces amplify distal Temporal Difference errors into gradient shocks'' that fixed-step-size Stochastic Gradient Descent cannot normalize, leading to global overestimation. Conversely, adaptive optimizers mitigate this pathology via second-moment normalization. Our results suggest that human-like saliency distortions may emerge naturally from the mathematical constraints of credit assignment in distributed systems, and that adaptive optimization is a theoretical necessity for rational value estimation.