Warped Gaussian Processes

Edward Snelson, Carl Edward Rasmussen, Zoubin GhahramaniNeurIPS 2003

Gaussian Processes (GPs) are a cornerstone of Bayesian machine learning, providing elegant, non-parametric priors over functions. However, they come with a significant limitation: they assume the target data is distributed as a multivariate Gaussian with homoscedastic (constant) Gaussian noise.

In the real world, data is rarely that well-behaved. Observations might be strictly positive, span several orders of magnitude, or exhibit skewed noise. The traditional fix is to manually transform the data—for example, by taking the logarithm—before fitting the GP. Warped Gaussian Processes (WGPs) argue that such transformations should not be an "ad-hoc" preprocessing step, but rather an integral part of the probabilistic model that is learned directly from the data.

The Warped Gaussian Process Model

The core idea behind WGPs is to assume that there exists a latent space $z$ where the data is well-modeled by a standard GP, but we only observe a "warped" version of this space, $t$.

To connect these spaces, the authors define a monotonic warping function $f$ such that $z_n = f(t_n; \Psi)$, where $\Psi$ represents learnable parameters. To ensure the function is flexible yet strictly monotonic, they use a combination of a linear trend and a sum of tanh functions:

$$f(t; \Psi) = t + \sum_{i=1}^I a_i \tanh(b_i(t + c_i))$$

The model parameters—both the GP hyperparameters $\Theta$ and the warping parameters $\Psi$—are learned simultaneously by maximizing the log-likelihood. Crucially, the likelihood function includes a Jacobian term to account for how the transformation $f$ stretches or compresses the probability density.

While the prediction in the latent space $z$ is a standard Gaussian, passing it back through the inverse warping function $f^{-1}$ results in a non-Gaussian predictive distribution in the observation space $t$.

Warped GP on synthetic 1D data showing asymmetric confidence intervals and a skewed predictive distribution.

As seen in the synthetic example above, unlike a standard GP which must predict a symmetric "bell curve" for every point, the WGP can predict highly skewed distributions. This is vital for datasets where errors are more likely in one direction than the other.

Automatic Preprocessing and Key Insights

One of the most powerful aspects of the WGP is its ability to "discover" the necessary transformation automatically.

Learned warping functions across four datasets.

When evaluated on real-world datasets like creep (predicting the rupture stress of steel) and abalone (predicting age from physical measurements), the learned warping functions looked remarkably like log-transforms. This validates standard statistical intuition but removes the need for manual guesswork.

Other notable insights include:

  • Computational Efficiency: Since the computational bottleneck of GP regression is inverting the covariance matrix ($O(N^3)$), adding a few parameters for the warping function adds negligible overhead.
  • Prediction Mechanics: Because the warping is monotonic, the median of the predictive distribution in the observation space is simply the inverse warp of the latent mean. Calculating the predictive mean, however, requires numerical integration (Gauss-Hermite quadrature).

Performance Results

The WGP consistently outperforms both the standard GP and a "GP + log transform" baseline across multiple metrics, including Mean Absolute Error, Mean Squared Error, and Negative Log Predictive Density (NLPD).

Dataset Model Absolute Error Squared Error NLPD (lower is better)
Creep Warped GP 15.0 554 4.19
Standard GP 16.4 654 4.46
Abalone Warped GP 1.47 4.63 1.96
Standard GP 1.53 4.79 2.19

The improvement in NLPD is particularly telling. It demonstrates that the WGP isn't just improving the "point" prediction—it is modeling the uncertainty and the shape of the distribution much more accurately.

Limitations and Future Directions

While powerful, the WGP framework has a few limitations. Most notably, there is no analytical form for the inverse function $f^{-1}$, so the model relies on iterative methods like Newton-Raphson to map latent predictions back to the observation space. Additionally, the current warping function struggles with "censored" data, where many observations are clumped at a single boundary value.

Future work suggested by the authors includes exploring input warping (to handle non-stationary or non-isotropic data) as a parallel direction to this paper's focus on output warping.

Summary updated

BibTeX
@inproceedings{snelson2003warped,
  author = {Edward Snelson and Carl Edward Rasmussen and Zoubin Ghahramani},
  title = {{Warped Gaussian Processes}},
  booktitle = {Advances in Neural Information Processing Systems},
  year = {2003},
  url = {https://openreview.net/forum?id=HJVX0vb_Wr},
}
Figure