TL;DR
This paper introduces Curiosity Cross-Entropy Method (CCEM), a novel approach that brings curiosity-driven exploration to real-time model-based reinforcement learning. By training a $Q$-function to estimate both extrinsic and intrinsic rewards and utilizing contrastive learning for robust representations, the authors achieve state-of-the-art sample efficiency on complex continuous control tasks, significantly outperforming previous model-based methods.
What Problem Does This Paper Address?
Model-based Reinforcement Learning (MBRL) is prized for its sample efficiency—it learns a "world model" to imagine the consequences of actions. However, standard planning algorithms like the Cross-Entropy Method (CEM) often struggle in complex environments because they are "greedy": they only try to maximize known extrinsic rewards. This leads to poor exploration, especially in "sparse reward" settings where the agent gets no feedback until a task is completed.
A common fix in model-free RL is curiosity, where the agent receives an "intrinsic reward" for reaching novel or hard-to-predict states. But there is a catch for MBRL: real-time planning happens in a compact latent space where future observations are unavailable. You can't calculate a prediction error (the basis of curiosity) for a future state you haven't actually seen yet. This makes it technically challenging to use curiosity during the planning phase.
Methods
The authors propose TD-MPC with CCEM, which combines three key components:
- Curiosity CEM (CCEM): Instead of planning by summing predicted rewards (which are "blind" to curiosity), the planner maximizes a discounted sum of state-action $Q$-values. Crucially, these $Q$-values are trained offline to estimate the sum of both extrinsic and intrinsic rewards. This allows the planner to "foresee" the curiosity value of future latent trajectories.
- Intrinsic Curiosity Module (ICM): To generate the intrinsic rewards used during training, the model uses an inverse dynamics model (predicting the action taken between two states) and a forward dynamics model. The intrinsic reward is defined as the error in the forward model's prediction of the next latent state.
- Contrastive Representation Learning: To ensure the latent space is informative and robust to noise, the authors use a temporal contrastive loss (InfoNCE). This maximizes the mutual information between the current state-action pair and the resulting next state, helping the model learn features that are actually useful for prediction.
Datasets
The method was evaluated on six image-based continuous control tasks from the DeepMind Control (DMC) Suite:
- Finger Spin, Cartpole Swingup, Reacher Easy, Cheetah Run, Walker Walk, and Ball-in-cup Catch. These tasks represent a variety of challenges, including sparse rewards (Ball-in-cup), complex dynamics (Cheetah), and high-dimensional action spaces.
Key Insights and Ideas
- Planning with "Hallucinated" Curiosity: The core "aha" moment is realizing that while you can't compute curiosity during planning, you can bake the expectation of curiosity into a $Q$-function during the training phase. This allows a real-time planner to gravitate toward novel areas of the state space.
- Decoupling Representation and Policy: By using contrastive learning alongside the standard dynamics losses, the model learns a latent space that is temporally consistent. The authors found that while contrastive learning helps, the CCEM planning mechanism is the primary driver of the performance gains.
- Efficiency over Ensembles: Unlike previous attempts (like Plan2Explore) that require an expensive ensemble of models to estimate uncertainty, this method uses a single dynamics model and an ICM, making it more computationally streamlined.
Key Results
- Superior Sample Efficiency: At the 100k environment step mark (a standard benchmark for "fast" learning), TD-MPC with CCEM outperformed all other model-based baselines (like PlaNet and Dreamer) by a large margin.
- Competitive with Model-Free: It performed comparably to, and often better than, state-of-the-art model-free algorithms like DrQ and CURL, which typically require more samples to reach the same performance.
- Robustness: In ablation studies, the "Curiosity" component proved vital. Removing the curiosity-based planning (Non-CCEM) led to significantly lower scores in almost all tasks, confirming that exploration was the missing ingredient in previous MBRL planners.
Limitations and Future Work
- Hyperparameter Sensitivity: The "intrinsic weight" ($C$)—which determines how much the agent values curiosity vs. the actual task—is currently task-dependent. Finding a way to tune this automatically would make the algorithm more general.
- Static Environments: Like many MBRL methods, it assumes the environment's underlying "rules" don't change.
- Future Directions: The authors suggest evaluating CCEM on even more complex robotic manipulation tasks and exploring ways to further reduce the computational overhead of the training updates.
Summary updated