Introduction
Deep Reinforcement Learning (RL) is characterized by its high sample complexity and notorious sensitivity to hyperparameters. While we often optimize networks with millions of parameters, the underlying learning process frequently appears unstable. In Supervised Learning (SL), recent research has identified a phenomenon known as gradient subspaces: the discovery that gradients primarily reside in a low-dimensional space spanned by the directions of highest curvature—specifically, the top eigenvectors of the Hessian matrix.
However, RL presents a unique challenge: non-stationarity. Unlike the fixed datasets of SL, an RL agent’s data distribution shifts constantly as its policy evolves. This shifting target led to a prevailing assumption that stable gradient subspaces might not exist in RL. This paper investigates whether these low-dimensional structures persist despite the inherent chaos of RL optimization and whether they can be tracked to improve training efficiency.
Methodology
The researchers conducted an extensive empirical study across 12 benchmark tasks from OpenAI Gym, Gym Robotics, and the DeepMind Control Suite. They focused on two dominant algorithmic paradigms: Proximal Policy Optimization (PPO), representing on-policy methods, and Soft Actor-Critic (SAC), representing off-policy methods.
To identify the subspaces, the authors analyzed the Hessian matrix—the second-order derivative of the loss function that defines the curvature of the optimization landscape. Because computing a full Hessian for deep networks is computationally prohibitive, they employed the Lanczos method to estimate the top $k$ eigenvectors. Two primary metrics were used to evaluate these subspaces:
- Gradient Subspace Fraction ($S_{frac}$): The percentage of the gradient's magnitude that projects into the subspace defined by the top 100 Hessian eigenvectors.
- Subspace Overlap ($S_{overlap}$): A measure of how much the subspace identified at one timestep aligns with a subspace identified at a later timestep, indicating the temporal stability of the learning signal.
Key Insights
The Ill-Conditioned Landscape
The study reveals that the Hessian spectrum in RL is extremely skewed. A very small number of directions exhibit massive curvature, while the vast majority of the parameter space is nearly flat. This suggests that most parameter dimensions contribute primarily noise to the immediate gradient update, while a tiny fraction of dimensions drives the actual learning.
The Critic as an Anchor
In actor-critic architectures, the Critic (responsible for value estimation) demonstrates a significantly more stable and well-defined subspace than the Actor (responsible for action selection). The Critic’s subspace captures a higher fraction of its gradient and evolves more slowly over time, suggesting it provides a more consistent optimization signal than the policy itself.
Off-Policy vs. On-Policy Dynamics
SAC (off-policy) generally exhibits higher gradient subspace fractions than PPO (on-policy). This is likely due to SAC’s use of a replay buffer, which effectively "slows down" the shift in the data distribution. By reusing past experiences, SAC maintains a more consistent Hessian structure compared to PPO, which relies exclusively on fresh samples that reflect the most recent (and potentially volatile) policy changes.
Explaining "Reward Cliffs"
The existence of these high-curvature subspaces provides a geometric explanation for the "reward cliffs" often seen in RL training. These cliffs—where a minor parameter update leads to a catastrophic drop in performance—occur when the agent moves along the high-curvature directions identified in the Hessian. Understanding these subspaces may allow for better-constrained updates that avoid such pitfalls.
Results and Stability
The degree of dimensionality reduction possible is striking. For PPO, a subspace of just 100 dimensions—often representing less than 2% of the total parameters—captures the bulk of the gradient signal. For SAC, the compression is even more extreme, with the subspace representing as little as 0.07% of the parameters while remaining highly informative.
Furthermore, these subspaces are surprisingly persistent. A subspace identified at a specific training step still shows significant overlap with the gradient hundreds of thousands of steps later. This temporal stability suggests that the expensive calculation of Hessian eigenvectors does not need to occur at every iteration to remain useful for optimization.
Future Directions
While calculating Hessian eigenvectors via the Lanczos method introduces computational overhead, the discovery of stable subspaces opens several promising avenues for RL research:
- Subspace Optimization: Performing second-order optimization (such as Newton’s method) exclusively within the low-dimensional subspace. This could provide the convergence benefits of second-order methods without the $O(N^2)$ cost associated with the full Hessian.
- Guided Exploration: Instead of applying isotropic noise to all parameters, agents could inject exploration noise specifically into the high-curvature subspaces to more effectively search for policy improvements.
By identifying order within the high-dimensional chaos of RL, this work suggests that the path to more robust and efficient agents may lie in focusing on the few dimensions that truly matter.
Summary updated