The Surprising Ineffectiveness of Pre-Trained Visual Representations for Model-Based Reinforcement Learning

Moritz Schneider, Robert Krug, Narunas Vaskevicius, Luigi Palmieri, Joschka Boedecker

Abstract

Visual Reinforcement Learning (RL) methods often require extensive amounts of data. As opposed to model-free RL, model-based RL (MBRL) offers a potential solution with efficient data utilization through planning. Additionally, RL lacks generalization capabilities for real-world tasks. Prior work has shown that incorporating pre-trained visual representations (PVRs) enhances sample efficiency and generalization. While PVRs have been extensively studied in the context of model-free RL, their potential in MBRL remains largely unexplored. In this paper, we benchmark a set of PVRs on challenging control tasks in a model-based RL setting. We investigate the data efficiency, generalization capabilities, and the impact of different properties of PVRs on the performance of model-based agents. Our results, perhaps surprisingly, reveal that for MBRL current PVRs are not more sample efficient than learning representations from scratch, and that they do not generalize better to out-of-distribution (OOD) settings. To explain this, we analyze the quality of the trained dynamics model. Furthermore, we show that data diversity and network architecture are the most important contributors to OOD generalization performance.

Introduction

In visual Reinforcement Learning (RL), agents must learn to act based on high-dimensional image data, a process that is notoriously data-hungry. To mitigate this, researchers frequently employ Pre-trained Visual Representations (PVRs)—vision models like CLIP or DINOv2 trained on massive datasets to provide a "head start." While PVRs are often considered "cheat codes" for sample efficiency in model-free RL, their utility in Model-Based RL (MBRL) has remained under-explored. MBRL agents do not just learn a policy; they learn a "world model" to predict future states and rewards. This study investigates whether the features provided by PVRs are compatible with the specific needs of these world models.

Methodology

We conducted an extensive benchmark by integrating eight major PVRs—including CLIP, DINOv2, R3M, VC-1, and VIP—into two state-of-the-art MBRL algorithms: DreamerV3 and TD-MPC2. These PVRs cover diverse architectures (ResNets and Vision Transformers) and training objectives (language-conditioned, masked autoencoding, etc.).

Architectural integration of PVRs into DreamerV3 (left) and TD-MPC2 (right).

In our setup, the PVRs were kept frozen, with only a single linear layer trained to map PVR features into the agent's latent space. This approach was compared against a baseline where the agent learns a convolutional neural network (CNN) encoder from scratch. Agents were evaluated on "In-Distribution" (ID) tasks and subsequently tested in "Out-of-Distribution" (OOD) settings where environment attributes were randomized.

Datasets and Evaluation

The study utilized 10 diverse control tasks across three distinct domains: DeepMind Control Suite (DMC), ManiSkill2, and Miniworld. These environments range from classic locomotion to complex robotic manipulation using wrist-mounted cameras.

A robotic manipulation task from the ManiSkill2 environment.

Key Results: The Failure of PVRs in MBRL

Surprisingly, learning from scratch outperformed all PVR-based agents in both sample efficiency and final performance within the DeepMind Control Suite. Even in OOD settings—where PVRs are theoretically expected to excel—the "from scratch" baseline remained superior or highly competitive.

The only notable exception was VC-1, which showed competitive performance across multiple domains. This is likely due to its training on a massive, diverse mix of ego-centric and manipulation-specific data, suggesting that data relevance is more critical than scale alone.

Analysis: The Reward Prediction Bottleneck

The core reason for the ineffectiveness of PVRs in MBRL appears to be an "Objective Mismatch." While PVRs are trained to recognize objects or align images with text, MBRL world models must predict dynamics and rewards.

Our analysis revealed that while PVRs are reasonably effective at helping an agent learn dynamics (how the world moves), they fail significantly at reward prediction. Analysis of latent spaces showed that representations learned from scratch clearly "disentangle" low-reward states from high-reward states. In contrast, PVR embeddings are often "entangled," making it nearly impossible for the world model to learn an accurate reward predictor. If the agent cannot predict what leads to a reward, it cannot plan effectively, regardless of how well it understands the physics of the environment.

Conclusion

This research highlights that current PVRs are not a universal solution for visual RL. For MBRL, the bottleneck is almost entirely in the reward model. Future work should focus on designing "MBRL-specific" pre-training objectives that prioritize reward-relevant features and temporal dynamics over static image classification. Additionally, while frozen PVRs are currently ineffective, exploring fine-tuning strategies may bridge the performance gap at the cost of increased computation.

Summary updated

Abstract

Visual Reinforcement Learning (RL) methods often require extensive amounts of data. As opposed to model-free RL, model-based RL (MBRL) offers a potential solution with efficient data utilization through planning. Additionally, RL lacks generalization capabilities for real-world tasks. Prior work has shown that incorporating pre-trained visual representations (PVRs) enhances sample efficiency and generalization. While PVRs have been extensively studied in the context of model-free RL, their potential in MBRL remains largely unexplored. In this paper, we benchmark a set of PVRs on challenging control tasks in a model-based RL setting. We investigate the data efficiency, generalization capabilities, and the impact of different properties of PVRs on the performance of model-based agents. Our results, perhaps surprisingly, reveal that for MBRL current PVRs are not more sample efficient than learning representations from scratch, and that they do not generalize better to out-of-distribution (OOD) settings. To explain this, we analyze the quality of the trained dynamics model. Furthermore, we show that data diversity and network architecture are the most important contributors to OOD generalization performance.
BibTeX
@inproceedings{schneider2024surprising,
  author = {Moritz Schneider and Robert Krug and Narunas Vaskevicius and Luigi Palmieri and Joschka Boedecker},
  title = {{The Surprising Ineffectiveness of Pre-Trained Visual Representations for Model-Based Reinforcement Learning}},
  booktitle = {Advances in Neural Information Processing Systems},
  year = {2024},
  url = {https://openreview.net/forum?id=LvAy07mCxU},
}
Figure