Scalable mixed-domain Gaussian processes

Juho Timonen, Harri Lähdesmäki · OpenReview

Abstract

Gaussian process (GP) models that combine both categorical and continuous input variables have found use in longitudinal data analysis and computer experiments. However, standard inference for these models has the typical cubic scaling, and common scalable approximation schemes for GPs cannot be applied since the covariance function is non-continuous. In this work, we derive a basis function approximation scheme for mixed-domain covariance functions, which scales linearly with respect to the number of observations and total number of basis functions. The proposed approach is naturally applicable to Bayesian GP regression with arbitrary observation models. We demonstrate the approach in a longitudinal data modelling context and show that it approximates the exact GP model accurately, requiring only a fraction of the runtime compared to fitting the corresponding exact model.

Introduction

Gaussian Processes (GPs) are widely regarded as the "gold standard" for non-parametric modeling due to their ability to provide elegant, principled uncertainty estimates. In longitudinal studies—where researchers track subjects over time—GPs are particularly valuable for capturing complex, non-linear trajectories. However, two significant hurdles have historically limited their application to large-scale real-world data: the $O(N^3)$ computational bottleneck and the "mixed-domain" gap.

Standard GP inference scales cubically with the number of observations ($N$), making datasets with more than a few thousand points prohibitively slow to process. Furthermore, most existing "fast" GP approximations, such as inducing point methods, assume a continuous and differentiable input space. Longitudinal data rarely fits this mold, as it frequently combines continuous variables (like age or time) with categorical variables (like patient ID, sex, or treatment group). This paper introduces a scalable basis function approximation designed specifically to bridge this gap, enabling fast and flexible modeling for mixed-domain data.

Methodology: Bridging the Mixed-Domain Gap

The authors propose a basis function approximation scheme that decomposes the covariance function into a finite set of basis functions, effectively transforming the GP into a linear model. This approach targets both continuous and categorical inputs through distinct mathematical treatments:

1. Hilbert Space Approximation for Continuous Inputs

For continuous variables such as time, the method utilizes a reduced-rank approximation based on the Laplacian eigenfunctions of the domain. This allows the model to capture the smooth, underlying trends in the data using a manageable number of basis functions.

2. Categorical Eigendecomposition

Categorical variables are handled using the exact eigendecomposition of the categorical kernel (e.g., the "Zero-Sum" kernel). Because the number of categories ($C$) is typically much smaller than the total number of observations ($N$), this decomposition is computationally efficient and provides a robust way to handle discrete group effects.

3. Product Kernels and Mixed-Domain Basis

The core innovation lies in the combination of these two approaches. By multiplying the continuous and categorical basis functions, the authors create "mixed-domain" basis functions. These functions can model complex interactions, such as how a specific treatment effect evolves over time for a particular group, while maintaining computational efficiency.

4. Model Reduction and Variable Selection

To handle high-dimensional datasets where many variables may be noise, the authors implement two key techniques:

  • Additive Variance Decomposition (AVD): This ranks variables based on their contribution to the explained variance.
  • Projection Predictive Selection: This method projects a complex "reference" model onto simpler submodels to identify the minimal set of predictors required to maintain predictive performance.

Experimental Evaluation

The proposed method was evaluated across four distinct scenarios to test accuracy, scalability, and robustness:

  • Simulated Longitudinal Data: Confirmed that the approximation converges to the exact GP result as the number of basis functions increases.
  • Canadian Weather Data: Using 12,775 daily temperature measurements across 35 stations, the authors demonstrated that the approximate model could fit in a few hours, whereas an exact GP would have taken days or failed due to memory constraints.
  • US Presidential Election Data (1976–2016): By modeling Republican vote shares using a non-Gaussian (Beta-Binomial) likelihood, the study proved the method's flexibility with diverse observation models.
  • High-Dimensional Simulation: In a test involving 32 "nuisance" variables, the Projection Predictive method successfully identified the true predictors, outperforming simpler variance-based ranking.

Key Insights and Results

The transition from cubic to linear scaling ($O(NM + M)$, where $M$ is the number of basis functions) is a significant advancement. It allows GPs to handle tens of thousands of data points on standard hardware. In practice, the authors found that with only 16 to 32 basis functions, the predictive mean of the approximation was virtually indistinguishable from the exact GP.

Furthermore, the use of Zero-Sum (ZS) kernels for categorical interactions allows for better interpretability. Researchers can disentangle "shared" effects (trends common to all subjects) from "group-specific" effects. Because the model is additive, individual components can be plotted and analyzed, providing a "white-box" alternative to more opaque machine learning models.

Limitations and Future Directions

While the method offers substantial improvements, some limitations remain. The continuous approximation currently requires stationary kernels, though "warping" techniques may offer a path toward handling non-stationary data. Additionally, while the GP mathematics are now linear, the reliance on Markov Chain Monte Carlo (MCMC) for inference can still become a bottleneck as $N$ approaches one million. Future research may explore Variational Inference (VI) to further push these boundaries.

In conclusion, this scalable mixed-domain GP framework provides a powerful tool for researchers dealing with large, complex longitudinal datasets, offering a rare combination of computational efficiency, interpretability, and rigorous uncertainty quantification.

Summary updated

BibTeX
@misc{timonen2021scalable,
  author = {Juho Timonen and Harri Lähdesmäki},
  title = {{Scalable mixed-domain Gaussian processes}},
  year = {2021},
  eprint = {2111.02019},
  archivePrefix = {arXiv},
  url = {https://arxiv.org/abs/2111.02019},
}
Figure