Compact Spectral Bases for Value Function Approximation Using Kronecker Factorization

Jeffrey Johns, Sridhar Mahadevan, Chang WangAAAI 2007

Abstract

Spectral approaches to value function approximation (VFA) offer a powerful way to automatically construct basis functions from environment samples. By diagonalizing a diffusion operator on a graph of connected samples, agents can generate global features known as proto-value functions (PVFs). However, scaling this approach to large domains is computationally prohibitive due to the $O(n^3)$ complexity of eigendecomposition. This paper introduces a method to scale these bases using Kronecker factorization coupled with the Metropolis-Hastings algorithm. By decomposing large transition matrices into smaller components, we achieve significant memory compression—up to 36x in some domains—without sacrificing performance.

Introduction

In Reinforcement Learning (RL), agents in continuous or high-dimensional state spaces rely on VFA to estimate the value of states. While spectral bases like PVFs capture the intrinsic geometry of the environment, they suffer from a major scaling bottleneck: the size of the graph-based transition matrix grows linearly with the number of samples. For complex tasks requiring tens of thousands of samples, storing and processing the resulting basis functions becomes impractical. This work addresses this challenge by making spectral bases compact and computationally efficient.

Methodology

The proposed framework integrates Kronecker factorization into the Representation Policy Iteration (RPI) cycle through several key stages:

1. Greedy Subsampling

To manage the initial density of the state space, a greedy subsampling algorithm is employed. This reduces the number of vertices in the graph while ensuring that the representative subset still covers the explored state space effectively.

Comparison of raw samples (7,459) vs. greedy subsamples (846) in a phase space.

2. Matrix Reordering and Factorization

Factorization is most effective when the underlying matrix exhibits latent structure. We utilize METIS, a graph partitioning tool, to reorder the transition matrix $A$. This reordering clusters similar states, revealing a block-diagonal-like structure that facilitates accurate Kronecker approximation ($A \approx B \otimes C$).

The reordered transition matrix A (1800x1800) showing the block structure revealed by graph partitioning.

3. Metropolis-Hastings Adjustment and Eigendecomposition

To ensure the factor matrices $B$ and $C$ yield stable basis functions with real eigenvalues, we apply a Metropolis-Hastings adjustment to make them reversible. The final basis functions $\Phi$ are never stored in their full, massive form. Instead, we compute the eigenvectors of the much smaller $B$ and $C$ matrices. The full basis is the Kronecker product of these smaller vectors ($\Phi = \Phi_B \otimes \Phi_C$), allowing for on-the-fly reconstruction of specific rows as needed.

Theoretical Insights

The quality of the Kronecker approximation is theoretically linked to the spectral gap—the distance between the eigenvalues of the transition matrix. Using perturbation theory, we demonstrate that a larger spectral gap allows the compact bases to more accurately capture the essential geometry of the environment. Furthermore, this factorization acts as a form of automated state aggregation: matrix $B$ represents transitions between clusters, while $C$ represents transitions within them.

Experimental Results

The method was evaluated on three continuous MDP benchmarks: Inverted Pendulum, Mountain Car, and Acrobot.

  • Compression: In the 4D Acrobot domain, the basis functions were compressed by a factor of 36.0. The agent required only 4,500 values compared to the 162,000 required by the uncompressed method.
  • Performance: Across all benchmarks, agents using Kronecker-factorized bases achieved performance nearly identical to those using full spectral bases.
  • Efficiency: By avoiding the $O(n^3)$ decomposition of the full matrix $A$, the basis construction phase is significantly accelerated, enabling the use of spectral methods in much larger state spaces.

Conclusion

Kronecker factorization provides a robust mechanism for scaling spectral basis functions in reinforcement learning. By exploiting the latent structure of reordered transition matrices, we can generate compact, high-performing features with a fraction of the memory and computational cost. Future work will explore multilevel recursive factorization ($A \approx B \otimes (C \otimes D)$) to achieve even greater compression for high-dimensional problems.

Summary updated

BibTeX
@inproceedings{johns2007compact,
  author = {Jeffrey Johns and Sridhar Mahadevan and Chang Wang},
  title = {{Compact Spectral Bases for Value Function Approximation Using Kronecker Factorization}},
  booktitle = {AAAI Conference on Artificial Intelligence},
  year = {2007},
  url = {https://openreview.net/forum?id=SkZtcAg_br},
}

Loading related content...

Figure