Abstract
Reinforcement Learning (RL) often struggles with sample inefficiency, particularly in state-based continuous control. While self-supervised representation learning has proven effective for image-based inputs, its application to compact state vectors frequently leads to representation collapse. We introduce iQRL (Implicitly Quantized Reinforcement Learning), a novel representation learning method that utilizes Finite Scalar Quantization (FSQ) within a self-supervised latent-state consistency framework. iQRL prevents both complete and dimensional collapse without requiring task-specific reward prediction or observation reconstruction. Our empirical results on the DeepMind Control Suite demonstrate that iQRL achieves state-of-the-art sample efficiency and performance across a wide range of tasks, particularly in high-dimensional locomotion.
Introduction
Reinforcement Learning is notoriously sample-inefficient, often requiring millions of environment interactions to master complex tasks. In the domain of image-based RL, representation learning has significantly mitigated this issue. However, for state-based RL—where inputs are already compact vectors like joint angles and velocities—effective representation learning remains an open challenge.
Standard self-supervised learning (SSL) techniques applied to state-based RL often suffer from two types of failure: complete representation collapse, where the encoder maps all observations to a constant vector, and dimensional collapse, where latent vectors span only a small fraction of the available dimensions. Existing remedies typically involve adding task-specific losses (e.g., reward prediction) or observation reconstruction. However, reconstruction can force the agent to model irrelevant environment details, while reward prediction limits the representation's generalizability. iQRL addresses these issues by providing a robust, task-agnostic representation through implicit quantization.
The iQRL Framework
iQRL is designed as a stand-alone representation learning module that can be integrated with standard model-free RL algorithms, such as TD3. The architecture consists of an encoder and a latent dynamics model trained via a latent-state consistency loss.
Latent-State Consistency and Quantization
The system minimizes the cosine similarity between a predicted future latent state and a target generated by an exponential moving average (EMA) momentum encoder. The core innovation is the use of Finite Scalar Quantization (FSQ). Instead of using continuous latent vectors, iQRL bounds and rounds latent dimensions into a discrete set of codewords. Gradients are propagated through this non-differentiable rounding operation using a Straight-Through Estimator (STE). This quantization naturally regularizes the latent space, allowing iQRL to omit the reward prediction and observation reconstruction heads used in prior works. Once the quantized representation is learned, the RL actor and critic operate entirely within this discrete latent space.
Experimental Evaluation
We evaluated iQRL on the DeepMind Control (DMC) Suite, testing across 20 tasks ranging from simple environments like Acrobot to complex, high-dimensional tasks like Dog Run and Humanoid Walk.
Key Results
- State-of-the-Art Efficiency: iQRL significantly outperforms recent baselines including TCRL, TD7, TACO, and base TD3.
- High-Dimensional Robustness: The performance gap is most evident in complex tasks. In Dog Run, which features a 223-dimensional observation space, iQRL successfully solves the task while most baselines fail to make significant progress.
- Ablation Studies: Removing FSQ quantization leads to a plummet in the representation matrix rank and total failure in complex tasks. Conversely, adding a standard reconstruction loss actually degrades performance, suggesting that modeling every detail of the state vector is counterproductive for control.
Key Insights
- Quantization as Anti-Collapse: Forcing the latent space into a discrete codebook preserves the rank of the representation matrix, elegantly solving dimensional collapse without complex contrastive losses.
- The Reconstruction Trap: In continuous control, reconstruction losses can distort the optimization landscape by forcing the network to waste capacity on uncontrollable or irrelevant environment dynamics.
- Task-Agnostic Viability: By avoiding reward-based stabilization, iQRL learns a representation that is entirely independent of specific task rewards, making it highly suitable for general-purpose feature extraction.
Conclusion and Future Work
iQRL demonstrates that implicit quantization is a powerful tool for learning robust representations in state-based RL. While currently validated on deterministic environments, future work will focus on extending iQRL to stochastic settings and exploring its potential for multi-task RL, where a single shared representation could support a diverse array of distinct control objectives.
Summary updated