Why long model-based rollouts are no reason for bad Q-value estimates

Philipp Wissmann, Daniel Hein, Steffen Udluft, Volker Tresp

Abstract

Conventional wisdom in reinforcement learning (RL) suggests that long model-based rollouts are inherently unreliable due to compounding errors. This paper challenges that assumption by demonstrating that "informed" policies—those that react to simulated states—can produce Q-value estimates that are significantly more accurate and stable than standard model-free bootstrapping methods. By introducing Model-Based Rollout (MBRO) and Bootstrapping-free Neural Fitted Q-iteration (BSF-NFQ), we show that reactivity acts as a stabilizing force, allowing for high-fidelity value estimation even with imperfect models.

Introduction

In offline reinforcement learning, a central debate exists between model-free and model-based methodologies. Model-based methods are frequently criticized for the "compounding error" problem: the theory that small inaccuracies in a transition model accumulate exponentially over time, leading to divergent trajectories. Consequently, many researchers avoid long-term planning with models, favoring model-free bootstrapping instead.

However, this theoretical pessimism often contradicts empirical success in real-world applications. This paper investigates this discrepancy, proposing that the failure of long rollouts is not a property of the model itself, but rather a result of how the model is queried. Specifically, we distinguish between "blind" rollouts and "informed" rollouts to show why the latter are surprisingly robust.

The Power of Reactivity: Blind vs. Informed Rollouts

The core of the compounding error argument typically assumes a blind rollout, where a fixed sequence of actions is applied regardless of the resulting state. In this scenario, errors do indeed compound rapidly because the agent cannot adjust to the drifting simulated state.

In contrast, an informed rollout utilizes a policy ($\pi$) that observes the simulated state and selects actions accordingly. This reactivity acts as a stabilizer; if a model's predicted state drifts slightly, a competent policy will choose an action to correct that drift (e.g., adjusting the cart to balance a pole). This keeps the trajectory within a state-space regime that the model understands, effectively mitigating the accumulation of error.

Methodology

Model-Based Rollout (MBRO)

To leverage this stability, we propose Model-Based Rollout (MBRO) for Q-value estimation. Unlike standard Q-learning, which relies on bootstrapping (updating a value estimate based on another potentially erroneous estimate), MBRO calculates the value by summing rewards over a 1,000-step rollout using a learned transition model. This grounds the value estimate in simulated rewards rather than a recursive feedback loop of value functions.

Bootstrapping-free Neural Fitted Q-iteration (BSF-NFQ)

Building on MBRO, we introduced Bootstrapping-free Neural Fitted Q-iteration (BSF-NFQ). This algorithm modifies the classic NFQ approach by replacing the standard bootstrapping update with the MBRO value estimate. By removing the dependency on a target Q-network for updates, we aim to eliminate the "hallucinated values" that often plague offline RL.

Experimental Setup

We evaluated our approach using the CartPole-v1 environment.

  • Data Collection: A dataset of 20,000 observation tuples was generated using a random policy.
  • Model Training: Transition and reward models were trained using feed-forward neural networks. The transition model consisted of four sub-networks corresponding to the four state variables.
  • Baselines: MBRO was compared against Fitted Q-Evaluation (FQE), a standard model-free baseline for value estimation.

Results and Analysis

Estimation Accuracy

The quantitative results demonstrated a significant advantage for model-based estimation. MBRO achieved a Root Mean Square Error (RMSE) of 3.9 ± 0.2, whereas the model-free FQE baseline suffered from a much higher error of 26.1 ± 0.2. Furthermore, MBRO showed a near-perfect correlation (0.9923) with true returns, while FQE achieved only 0.699.

Learning Stability

BSF-NFQ proved to be substantially more robust than its bootstrapping counterpart. Standard NFQ is notoriously unstable, reaching an optimal policy in only 3.8% of its iterations in our tests. In contrast, BSF-NFQ reached an optimal policy in 23.3% of iterations. Notably, BSF-NFQ achieved these results while running for 10x fewer iterations than the standard version.

Model Quality vs. Horizon

An unexpected insight from our experiments was that the application of the model matters as much as its accuracy. A mediocre model used in an informed rollout consistently outperformed a high-accuracy model used in a blind rollout. This suggests that the self-correcting nature of the policy is a primary driver of success in long-horizon planning.

Conclusion and Future Work

This research demonstrates that long model-based rollouts are not inherently doomed by compounding errors. When paired with an informed, reactive policy, models can provide Q-value estimates that are more accurate and stable than those derived from model-free bootstrapping.

However, these benefits come with a computational trade-off, as 1,000-step rollouts are significantly slower than single-step updates. Future research should explore the scalability of this approach in high-dimensional environments, such as robotics, and investigate its performance in stochastic settings where model errors may be more difficult to correct.

Summary updated

BibTeX
@inproceedings{wissmann2024why,
  author = {Philipp Wissmann and Daniel Hein and Steffen Udluft and Volker Tresp},
  title = {{Why long model-based rollouts are no reason for bad Q-value estimates}},
  booktitle = {ESANN},
  year = {2024},
  doi = {10.14428/esann/2024.es2024-80},
}
Figure