[Paper Review] Variational Inference in Sparse Gaussian Process Regression and Latent Variable Models - a Gentle Tutorial
This tutorial presents a comprehensive derivation of variational inference for sparse Gaussian process regression and the Gaussian process latent variable model (GPLVM), introducing a reparameterization that enables distributed, scalable inference on large datasets. The key contribution is a unified, fully derivable framework with explicit partial derivatives for hyperparameters, inducing points, and latent variables—essential for extending and implementing parallel GP models.
In this tutorial we explain the inference procedures developed for the sparse Gaussian process (GP) regression and Gaussian process latent variable model (GPLVM). Due to page limit the derivation given in Titsias (2009) and Titsias & Lawrence (2010) is brief, hence getting a full picture of it requires collecting results from several different sources and a substantial amount of algebra to fill-in the gaps. Our main goal is thus to collect all the results and full derivations into one place to help speed up understanding this work. In doing so we present a re-parametrisation of the inference that allows it to be carried out in parallel. A secondary goal for this document is, therefore, to accompany our paper and open-source implementation of the parallel inference scheme for the models. We hope that this document will bridge the gap between the equations as implemented in code and those published in the original papers, in order to make it easier to extend existing work. We assume prior knowledge of Gaussian processes and variational inference, but we also include references for further reading where appropriate.
Motivation & Objective
- To bridge the gap between published equations and their implementation in code for sparse Gaussian process models.
- To provide a complete, self-contained derivation of the variational lower bound for sparse GP regression and GPLVM, filling in gaps often omitted in the literature.
- To enable scalable, distributed inference by reparameterizing the models to conditionally decouple data, allowing efficient optimization on large datasets.
- To offer explicit analytical derivations of partial derivatives for all key variables: kernel hyperparameters, inducing point locations, and latent inputs (embeddings).
- To support code extension and implementation by linking equations directly to their computational counterparts in open-source software.
Proposed method
- The paper derives the variational lower bound for sparse GP regression and GPLVM using a reparameterization that conditionally decouples data, enabling distributed optimization.
- It employs a Gaussian approximation $ q(F|X) $ over function values and a variational distribution $ q(X_i) = \mathcal{N}(X_i; \mu_i, S_i) $ for latent inputs.
- The lower bound $ \mathcal{F} $ is derived by integrating out latent functions and approximating expectations over input distributions using moment matching.
- Key components include the expectation of kernel matrices $ \langle K_{mi}^{X_i} \rangle_{q(X_i)} $, $ \langle K_{mi}^{X_i}K_{im}^{X_i} \rangle_{q(X_i)} $, and the KL divergence between variational and prior distributions over inputs.
- Analytical partial derivatives are derived for all parameters: $ \mu_i $, $ S_i $, kernel hyperparameters (e.g., RBF with ARD), $ \beta $, and inducing point locations.
- The method supports optimization of both kernel hyperparameters and latent variables using exact gradients, enabling end-to-end training.
Experimental results
Research questions
- RQ1How can the variational lower bound for sparse GP regression and GPLVM be derived in full, with all intermediate steps?
- RQ2What reparameterization enables distributed and scalable inference in these models?
- RQ3How can exact partial derivatives be computed for all model parameters, including latent inputs and inducing points?
- RQ4What is the analytical form of the gradient with respect to the noise precision $ \beta $ in the variational objective?
- RQ5How can the KL divergence between the variational and prior distributions over latent inputs be efficiently computed and differentiated?
Key findings
- The derived variational lower bound is mathematically equivalent to that in Titsias & Lawrence (2010), but with a reparameterization enabling distributed inference.
- The partial derivatives of the lower bound with respect to $ \mu_{iq} $, $ S_{iq} $, and $ \beta $ are derived explicitly, enabling gradient-based optimization of all model parameters.
- The gradient with respect to $ \mu_{iq} $ involves terms proportional to $ \alpha_q(\mu_{iq} - Z_{mq}) / (\alpha_q S_{iq} + 1) $, capturing sensitivity to latent input location.
- The derivative of the KL divergence $ KL(q(X_i) || p(X_i)) $ with respect to $ \mu_i $ is $ \mu_i $, and with respect to $ S_{iq} $ is $ \frac{1}{2}(1 - 1/S_{iq}) $.
- The gradient with respect to $ \beta $ includes terms involving traces of matrix inverses and products, derived using matrix calculus identities.
- The full derivation supports scalable, parallel optimization of both kernel hyperparameters and latent variables, enabling application to large-scale datasets.
Read this paper
Open the full text in the Nubint reader and ask about any passage as you read.
Read this paper on NubintThis review was generated by AI from the original paper. Please check the paper before citing it.