Feature Selection for Value Function Approximation Using Bayesian Model Selection

Tobias Jung, Peter Stone

Abstract

Approximating value functions in Reinforcement Learning (RL) often requires the manual selection of features or basis functions, a process frequently described as a "black art." This paper presents a principled approach to automating this selection by treating it as a Bayesian model selection problem within the Gaussian Process Temporal Difference (GPTD) framework. By optimizing the marginal likelihood, the proposed method identifies relevant state variables and ignores noise, leading to improved generalization and computational efficiency. Experimental results on the Pendulum Swing-Up and a noisy Gridworld task demonstrate that this approach significantly outperforms standard isotropic kernels and manual feature selection.

Introduction

In Reinforcement Learning, an agent's ability to make optimal decisions depends on its estimation of the value function—a mapping of states to expected future rewards. For environments with continuous or high-dimensional state spaces, storing these values in a discrete table is impossible. Instead, researchers use function approximators, which rely on a set of features or basis functions (such as radial basis functions or polynomials) to represent the state space.

Historically, selecting these features has been a manual, iterative process requiring significant domain expertise. Choosing too many features leads to overfitting and high computational costs, while choosing too few prevents the agent from learning the task. This paper addresses the challenge of automatic representation learning: enabling an agent to autonomously determine which dimensions of its input space are relevant to the value function.

Methodology

The GPTD Framework

The authors build their approach on the Gaussian Process Temporal Difference (GPTD) framework. Unlike traditional methods that use fixed basis functions, GPTD utilizes Gaussian Processes (GPs) to define a distribution over possible value functions. The relationship between states is governed by a kernel function, which determines the similarity between different points in the state space.

Bayesian Model Selection

The core innovation of this work is the application of Bayesian Model Selection to the GPTD model. The authors derive closed-form gradients for the marginal likelihood, an objective function that naturally incorporates Occam's Razor. The marginal likelihood rewards models that fit the observed data well while penalizing unnecessary complexity. By maximizing this objective, the system can automatically tune the hyperparameters of the kernel.

Kernel Variants

The paper evaluates three specific kernel configurations to test different levels of feature selection:

  1. Isotropic Kernel: Assumes all state dimensions are equally important, using a single length-scale parameter.
  2. Axis-aligned Automatic Relevance Determination (ARD): Assigns a unique importance weight (length-scale) to every input dimension, allowing the model to ignore irrelevant variables.
  3. Factor Analysis Kernel: Identifies relevant linear combinations of variables (directions) rather than just raw dimensions, providing a more flexible representation of the state space.

Computational Efficiency

To ensure the method scales to large datasets, the authors employ the Subset of Regressors (SR) approach and Incomplete Cholesky Decomposition (ICD). These techniques allow the algorithm to approximate the GP using a small, representative subset of the data, keeping the mathematical operations tractable without sacrificing significant accuracy.

Experimental Results

Pendulum Swing-Up Task

In the classic Pendulum Swing-Up control problem, the agent must learn to balance an underpowered pendulum. The Factor Analysis kernel significantly outperformed the standard isotropic kernel, achieving a Mean Squared Error (MSE) of 12.24 on unseen states, compared to 46.36 for the isotropic version. The model successfully identified that the value function varied most significantly along specific diagonals of the state space, a nuance missed by simpler models.

2D Gridworld with Latent Noise

To specifically test feature selection, the authors designed a Gridworld where only the x-axis was relevant to the reward, while the y-axis consisted of pure noise. The ARD kernel successfully identified the y-coordinate as irrelevant, assigning it a weight of less than $10^{-5}$. This allowed the agent to produce a smooth, accurate value function, whereas standard models produced "wiggly" estimates by attempting to fit the noise.

Performance and Scalability

The optimization process proved to be computationally efficient. For a dataset of 1,000 points, model selection was completed in 15–30 seconds on a 1.5GHz PC. This suggests that the method is viable for near-real-time applications in robotics and autonomous systems.

Discussion and Insights

  • Automatic Sparsity: The ARD kernel effectively performs dimensionality reduction on the fly. By driving the relevance parameters of useless variables toward zero, the model simplifies the learning problem.
  • Generalization: The Bayesian approach excels at predicting the value of states the agent has never encountered. This is a critical advantage over frequentist methods that minimize Bellman error, which often leads to overfitting in data-scarce environments.
  • Eigenspectrum Decay: The authors observed that successful feature selection results in a covariance matrix with a rapidly decaying eigenspectrum. This indicates that the underlying problem is highly compressible, allowing for more efficient use of memory and CPU resources.

Conclusion

This research demonstrates that Bayesian model selection offers a principled, automated alternative to manual feature engineering in Reinforcement Learning. By optimizing the marginal likelihood of a GPTD model, agents can autonomously discover the underlying structure of their environment. Future work includes extending this framework to full control tasks (Q-Learning) and testing the approach on high-dimensional robotic systems with dozens of redundant sensors.

Summary updated

BibTeX
@inproceedings{jung2009feature,
  author = {Tobias Jung and Peter Stone},
  title = {{Feature Selection for Value Function Approximation Using Bayesian Model Selection}},
  booktitle = {ECML/PKDD},
  year = {2009},
  doi = {10.1007/978-3-642-04180-8\_60},
}
Figure