Top Banner
Product Kernel Interpolation for Scalable Gaussian Processes Jacob R. Gardner 1 , Geoff Pleiss 1 , Ruihan Wu 1,2 , Kilian Q. Weinberger 1 , Andrew Gordon Wilson 1 1 Cornell University, 2 Tsinghua University Abstract Recent work shows that inference for Gaus- sian processes can be performed efficiently using iterative methods that rely only on matrix-vector multiplications (MVMs). Structured Kernel Interpolation (SKI) ex- ploits these techniques by deriving approxi- mate kernels with very fast MVMs. Unfortu- nately, such strategies suffer badly from the curse of dimensionality. We develop a new technique for MVM based learning that ex- ploits product kernel structure. We demon- strate that this technique is broadly applica- ble, resulting in linear rather than exponen- tial runtime with dimension for SKI, as well as state-of-the-art asymptotic complexity for multi-task GPs. 1 INTRODUCTION Gaussian processes (GPs) provide a powerful approach to regression and extrapolation, with applications as varied as time series analysis (Wilson and Adams, 2013; Duvenaud et al., 2013), blackbox optimization (Jones et al., 1998; Snoek et al., 2012), and personal- ized medicine and counterfactual prediction (D¨ urichen et al., 2015; Schulam and Saria, 2015; Herlands et al., 2016; Gardner et al., 2015). Historically, one of the key limitations of Gaussian process regression has been the computational intractability of inference when dealing with more than a few thousand data points. This com- plexity stems from the need to solve linear systems and compute log determinants involving an n × n symmet- ric positive definite covariance matrix K. This task is commonly performed by computing the Cholesky decomposition of K (Rasmussen and Williams, 2006), incurring O(n 3 ) complexity. To reduce this complex- ity, inducing point methods make use of a small set Proceedings of the 21 st International Conference on Ar- tificial Intelligence and Statistics (AISTATS) 2018, Lan- zarote, Spain. PMLR: Volume 84. Copyright 2018 by the author(s). of m<n points to form a rank m approximation of K (Qui˜ nonero-Candela and Rasmussen, 2005; Snelson and Ghahramani, 2006; Hensman et al., 2013; Titsias, 2009). Using the matrix inversion and determinant lemmas, inference can be performed in O(nm 2 ) time (Snelson and Ghahramani, 2006). Recently, however, an alternative class of inference techniques for Gaussian processes have emerged based on iterative numerical linear algebra techniques (Wil- son and Nickisch, 2015; Dong et al., 2017). Rather than explicitly decomposing the full covariance ma- trix, these methods leverage Krylov subspace methods (Golub and Van Loan, 2012) to perform linear solves and log determinants using only matrix-vector mul- tiples (MVMs) with the covariance matrix. Letting μ(K) denote the time complexity of computing Kv given a vector v, these methods provide excellent ap- proximations to linear solves and log determinants in O((K)) time, where r is typically some small con- stant Golub and Van Loan (2012). 1 This approach has led to scalable GP methods that differ radically from previous approaches – the goal shifts from com- puting efficient Cholesky decompositions to computing efficient MVMs. Structured kernel interpolation (SKI) (Wilson and Nickisch, 2015) is a recently proposed in- ducing point method that, given a regular grid of m inducing points, allows for MVMs to be performed in an impressive O(n + m log m) time. These MVM approaches have two fundamental draw- backs. First, Wilson and Nickisch (2015) use Kro- necker factorizations for SKI to take advantage of fast MVMs, constraining the number of inducing points m to grow exponentially with the dimensionality of the inputs, limiting the applicability of SKI to problems with fewer than about 5 input dimensions. Second, the computational benefits of iterative MVM inference methods come at the cost of reduced modularity. If all we know about a kernel is that it decomposes as K = K 1 K 2 , it is not obvious how to efficiently per- form MVMs with K, even if we have access to fast MVMs with both K 1 and K 2 . In order for MVM infer- 1 In practice, r depends on the conditioning of K, but is independent of n. arXiv:1802.08903v1 [cs.LG] 24 Feb 2018
11

Abstract m

Jul 30, 2020

Download

Documents

dariahiddleston
Welcome message from author
This document is posted to help you gain knowledge. Please leave a comment to let me know what you think about it! Share it to your friends and learn new things together.
Transcript
Page 1: Abstract m<n arXiv:1802.08903v1 [cs.LG] 24 Feb 2018 · Jacob R. Gardner 1, Geo Pleiss , Ruihan Wu 1;2, Kilian Q. Weinberger , Andrew Gordon Wilson1 (CG). This technique exploits

Product Kernel Interpolation for Scalable Gaussian Processes

Jacob R. Gardner1, Geoff Pleiss1, Ruihan Wu1,2, Kilian Q. Weinberger1, Andrew Gordon Wilson1

1Cornell University, 2Tsinghua University

Abstract

Recent work shows that inference for Gaus-sian processes can be performed efficientlyusing iterative methods that rely onlyon matrix-vector multiplications (MVMs).Structured Kernel Interpolation (SKI) ex-ploits these techniques by deriving approxi-mate kernels with very fast MVMs. Unfortu-nately, such strategies suffer badly from thecurse of dimensionality. We develop a newtechnique for MVM based learning that ex-ploits product kernel structure. We demon-strate that this technique is broadly applica-ble, resulting in linear rather than exponen-tial runtime with dimension for SKI, as wellas state-of-the-art asymptotic complexity formulti-task GPs.

1 INTRODUCTION

Gaussian processes (GPs) provide a powerful approachto regression and extrapolation, with applications asvaried as time series analysis (Wilson and Adams,2013; Duvenaud et al., 2013), blackbox optimization(Jones et al., 1998; Snoek et al., 2012), and personal-ized medicine and counterfactual prediction (Durichenet al., 2015; Schulam and Saria, 2015; Herlands et al.,2016; Gardner et al., 2015). Historically, one of the keylimitations of Gaussian process regression has been thecomputational intractability of inference when dealingwith more than a few thousand data points. This com-plexity stems from the need to solve linear systems andcompute log determinants involving an n×n symmet-ric positive definite covariance matrix K. This taskis commonly performed by computing the Choleskydecomposition of K (Rasmussen and Williams, 2006),incurring O(n3) complexity. To reduce this complex-ity, inducing point methods make use of a small set

Proceedings of the 21st International Conference on Ar-tificial Intelligence and Statistics (AISTATS) 2018, Lan-zarote, Spain. PMLR: Volume 84. Copyright 2018 by theauthor(s).

of m < n points to form a rank m approximation ofK (Quinonero-Candela and Rasmussen, 2005; Snelsonand Ghahramani, 2006; Hensman et al., 2013; Titsias,2009). Using the matrix inversion and determinantlemmas, inference can be performed in O(nm2) time(Snelson and Ghahramani, 2006).

Recently, however, an alternative class of inferencetechniques for Gaussian processes have emerged basedon iterative numerical linear algebra techniques (Wil-son and Nickisch, 2015; Dong et al., 2017). Ratherthan explicitly decomposing the full covariance ma-trix, these methods leverage Krylov subspace methods(Golub and Van Loan, 2012) to perform linear solvesand log determinants using only matrix-vector mul-tiples (MVMs) with the covariance matrix. Lettingµ(K) denote the time complexity of computing Kvgiven a vector v, these methods provide excellent ap-proximations to linear solves and log determinants inO(rµ(K)) time, where r is typically some small con-stant Golub and Van Loan (2012).1 This approachhas led to scalable GP methods that differ radicallyfrom previous approaches – the goal shifts from com-puting efficient Cholesky decompositions to computingefficient MVMs. Structured kernel interpolation (SKI)(Wilson and Nickisch, 2015) is a recently proposed in-ducing point method that, given a regular grid of minducing points, allows for MVMs to be performed inan impressive O(n+m logm) time.

These MVM approaches have two fundamental draw-backs. First, Wilson and Nickisch (2015) use Kro-necker factorizations for SKI to take advantage of fastMVMs, constraining the number of inducing points mto grow exponentially with the dimensionality of theinputs, limiting the applicability of SKI to problemswith fewer than about 5 input dimensions. Second,the computational benefits of iterative MVM inferencemethods come at the cost of reduced modularity. Ifall we know about a kernel is that it decomposes asK = K1 ◦K2, it is not obvious how to efficiently per-form MVMs with K, even if we have access to fastMVMs with both K1 and K2. In order for MVM infer-

1 In practice, r depends on the conditioning of K, butis independent of n.

arX

iv:1

802.

0890

3v1

[cs

.LG

] 2

4 Fe

b 20

18

Page 2: Abstract m<n arXiv:1802.08903v1 [cs.LG] 24 Feb 2018 · Jacob R. Gardner 1, Geo Pleiss , Ruihan Wu 1;2, Kilian Q. Weinberger , Andrew Gordon Wilson1 (CG). This technique exploits

Product Kernel Interpolation for Scalable Gaussian Processes

ence to be truly modular, we should be able to performinference equipped with nothing but the ability to per-form MVMs with K. One of the primary advantages ofGPs is the ability to construct very expressive kernelsby composing simpler ones (Rasmussen and Williams,2006; Gonen and Alpaydın, 2011; Durrande et al.,2011; Duvenaud et al., 2013; Wilson, 2014). One ofthe most common kernel compositions is the element-wise product of kernels. This composition can encodedifferent functional properties for each input dimen-sion (e.g., Rasmussen and Williams, 2006; Gonen andAlpaydın, 2011; Duvenaud et al., 2013; Wilson, 2014),or express correlations between outputs in multi-tasksettings (MacKay, 1998; Bonilla et al., 2008; Alvarezand Lawrence, 2011). Moreover, the RBF and ARDkernels – arguably the most popular kernels in use –decompose into product kernels.

In this paper, we propose a single solution which ad-dresses both of these limitations of iterative methods –improving modularity while simultaneously alleviatingthe curse of dimensionality. In particular:

1. We demonstrate that MVMs with product ker-nels can be approximated efficiently by computing theLanczos decomposition of each component kernel. IfMVMs with a kernel K can be performed in O(µ(K))time, then MVMs with the element-wise product of dkernels can be approximated in O(drµ(K) + r3n log d)time, where r is typically a very small constant.

2. Our fast product-kernel MVM algorithm, entitledSKIP, enables the use of structured kernel interpo-lation with product kernels without resorting to theexponential complexity of Kronecker products. SKIPcan be applied even when the product kernels use dif-ferent interpolation grids, and enables GP inferenceand learning in O(dn + dm logm) for products of dkernels.

3. We apply SKIP to high-dimensional regressionproblems by expressing d-dimensional kernels as theproduct of d one-dimensional kernels. This formula-tion affords an exponential improvement over the stan-dard SKI complexity of O(n+dmd logm), and achiev-ing state of the art performance over popular inducingpoint methods (Hensman et al., 2013; Titsias, 2009).

4. We demonstrate that SKIP can reduce the complex-ity of multi-task GPs (MTGPs) to O(n+m logm+ s)for a problem with s tasks. We exploit this fast in-ference, developing a model that discovers cluster oftasks using Gibbs sampling.

5. We make our GPU implementations available aseasy to use code as part of a new package for Gaussianprocesses, GPyTorch, available at https://github.

com/cornellius-gp/gpytorch.

2 BACKGROUND

In this section, we provide a brief review of Gaus-sian process regression and an overview of iterativeinference techniques for Gaussian processes based onmatrix-vector multiplies.

2.1 Gaussian Processes

A Gaussian process generalizes multivariate normaldistributions to distributions over functions that arespecified by a prior mean function and a prior covari-ance function f(x) ∼ GP (µ(x), k(x,x′)). By defini-tion, the function values of a GP at any finite set ofinputs [x1, ...,xn] are jointly Gaussian distributed:

f = [f(x1), ..., f(xn)] ∼ N (µX ,KXX)

where µX = [µ(x1), ..., µ(xn)]> and KXX =[k(xi,xj)]

ni,j=1. Generally, KAB denotes a matrix of

cross-covariances between the sets A and B.

Under a Gaussian noise observation model, p(y(x) |f(x)) ∼ N (y(x); f(x), σ2), the predictive distributionat x∗ given data D = {(xi, yi)}ni=1 is

p(f(x∗) | D) ∼ GP(µf |D(x∗), kf |D(x∗,x∗

′)),

µf |D(x) = µ(x∗) +Kx∗XK−1XXy, (1)

kf |D(x∗,x∗) = Kx∗x∗ −Kx∗XK−1XXK

>x∗X , (2)

where KXX = KXX + σ2I and y =(y(x1), . . . , y(xn))>. All kernel matrices implic-itly depend on hyperparameters θ. The log marginallikelihood of the data, conditioned only on thesehyperparameters, is given by

log p(y | θ) = −1

2y>K−1XXy − 1

2log |KXX |+ c , (3)

which provides a utility function for kernel learning.

2.2 Inference with matrix-vector multiplies

In order to compute the predictive mean in (1), thepredictive covariance in (2), and the marginal loglikelihood in (3), we need to perform linear solves(i.e. [KXX + σ2I]−1v) and log determinants (i.e.log |KXX + σ2I|). Traditionally, these operations areachieved using the Cholesky decomposition of KXX

(Rasmussen and Williams, 2006). Computing this de-composition requires O(n3) operations and storing theresult requires O(n2) space. Given the Cholesky de-composition, linear solves can be computed in O(n2)time and log determinants in O(n) time.

There exist alternative approaches (e.g. Wilson andNickisch, 2015) that require only matrix-vector mul-tiplies (MVMs) with [KXX + σ2I]. To compute lin-ear solves, we use the method of conjugate gradients

Page 3: Abstract m<n arXiv:1802.08903v1 [cs.LG] 24 Feb 2018 · Jacob R. Gardner 1, Geo Pleiss , Ruihan Wu 1;2, Kilian Q. Weinberger , Andrew Gordon Wilson1 (CG). This technique exploits

Jacob R. Gardner1, Geoff Pleiss1, Ruihan Wu1,2, Kilian Q. Weinberger1, Andrew Gordon Wilson1

(CG). This technique exploits that the solution toAx = b is the unique minimizer of the quadratic func-tion 1

2x>Ax−x>b, which can be found by iterating asimple three term recurrence. Each iteration requiresa single MVM with the matrix A (Shewchuk et al.,1994). Letting µ(A) denote the time complexity of anMVM with A, p iterations of CG requires O(pµ(A))time. If A is n × n, then CG is exact when p = n.However, the linear solve can often be approximatedby p < n iterations, since the magnitude of the residualr = Ax−b often decays exponentially. In practice thevalue of k required for convergence to high precision isa small constant that depends on the conditioning ofA rather than n (Golub and Van Loan, 2012). A sim-ilar technique known as stochastic Lanczos quadratureexists for approximating log determinants in O(pµ(A))time (Dong et al., 2017; Ubaru et al., 2017). In short,inference and learning for GP regression can be donein O(pµ(KXX)) time using these iterative approaches.

Critically, if the kernel matrices admit fast MVMs –either through the structure of the data (Saatci, 2012;Cunningham et al., 2008) or the structure of a generalpurpose kernel approximation (Wilson and Nickisch,2015) – this iterative approach offers massive scalabil-ity gains over conventional Cholesky-based methods.

2.3 Structured kernel interpolation

Structured kernel interpolation (SKI) (Wilson andNickisch, 2015) replaces a user-specified kernel k(x,x′)with an approximate kernel that affords very fastmatrix-vector multiplies. Assume we are given a setof m inducing points U that we will use to approxi-mate kernel values. Instead of computing kernel val-ues between data points directly, SKI computes kernelvalues between inducing points and interpolates thesekernel values to approximate the true data kernel val-ues. This leads to the approximate SKI kernel:

k(x, z) ≈ wxKUUw>z , (4)

where wx is a sparse vector that contains interpola-tion weights. For example, when using local cubicinterpolation (Keys, 1981), wx contains four nonzeroelements. Applying this approximation for all datapoints in the training set, we see that:

KXX ≈WXKUUW>X (5)

With arbitrary inducing points U , matrix-vector mul-tiplies with [WKUUW

>]v require O(n+m2) time. Inone dimension, we can reduce this running time byinstead choosing U to be a regular grid, which re-sults in KUU being Toeplitz. In higher dimensions,a multi-dimensional grid results in KUU being theKronecker product of Toeplitz matrices. This decom-positions enables matrix-vector multiplies in at most

=K(2)

XX

n⇥ n

K(1)XX

n⇥ n

�( )n

v

( )K(2)XX

n⇥ nn⇥ n

vK(1)XX

n⇥ n

⇡M (1,2)

( )T (1)

n⇥ r

r ⇥ r r ⇥ n

Q(1) Q(1)>

n⇥ r

r ⇥ r r ⇥ n

Q(2) T (2) Q(2)>

n⇥ n

v

Figure 1: Computing fast matrix-vector multiplies

(MVMs) with the product kernel K(1)XX ◦ K

(2)XX . 1:

Rewrite the element-wise product as the diagonal ∆(·)of a product of matrices. 2: Compute the rank-r Lanc-

zos decomposition of K(1)XX and K

(2)XX .

O(n+m logm) time, and O(n+m) storage. However,a Kronecker decomposition of KUU leads to an expo-nential time complexity in d, the dimensionality of theinputs x (Wilson and Nickisch, 2015).

3 MVMs WITH PRODUCTKERNELS

In this section we derive an approach to exploit prod-uct kernel structure for fast MVMs, towards allevi-ating the curse of dimensionality in SKI. Suppose akernel separates as a product as follows:

k(x,x′) =

d∏i=1

k(i)(x,x′). (6)

Given a training data set X = [x1, . . .xn], the kernelmatrix K resulting from the product of kernels in (6)

can be expressed as K = K(1)XX◦· · ·◦K

(d)XX , where ◦ rep-

resents element-wise multiplication. In other words:[K

(1)XX ◦K

(2)XX

]ij

=[K

(1)XX

]ij

[K

(2)XX

]ij. (7)

The key limitation we must deal with is that, unlikea sum of matrices, vector multiplication does not dis-tribute over the elementwise product:(

K(1) ◦K(2))

v 6=(K(1)v

)◦(K(2)v

). (8)

Page 4: Abstract m<n arXiv:1802.08903v1 [cs.LG] 24 Feb 2018 · Jacob R. Gardner 1, Geo Pleiss , Ruihan Wu 1;2, Kilian Q. Weinberger , Andrew Gordon Wilson1 (CG). This technique exploits

Product Kernel Interpolation for Scalable Gaussian Processes

We will assume we have access to fast MVMs for eachcomponent kernel matrix K(i). Without fast MVMs,there is a trivial solution to computing the elementwisematrix vector product: explicitly compute the kernelmatrix K in O(dn2) time and then compute Kv. Wefurther assume that K(i) admits a low rank approxi-mation, following prior work on inducing point meth-ods following prior work on inducing point methods(Snelson and Ghahramani, 2006; Titsias, 2009; Wil-son and Nickisch, 2015; Hensman et al., 2013).

A naive algorithm for a two-kernel product.We initially assume for simplicity that there are onlyd = 2 components kernels in the product. We willthen show how to extend the two kernel case to ar-bitrarily sized product kernels. We seek to performmatrix vector multiplies:

(K(1)XX ◦K

(2)XX)v (9)

Eq. (9) may be expressed in terms of matrix-matrixmultiplication using the following identity:

Kv = (K(1)XX ◦K

(2)XX)v = ∆(K

(1)XX Dv K

(2)>XX ), (10)

where Dv is a diagonal matrix whose elements are v(Figure 1), and ∆(M) denotes the diagonal of M . Be-cause Dv is an n× n matrix, computing the entries ofKv naively requires n matrix-vector multiplies with

K(1)XX and K

(2)XX . The time complexity to compute

(10) is therefore O(nµ(K(1)XX) + nµ(K

(2)XX)). This re-

formulation does not naively offer any time savings.

Exploiting low-rank structure. Suppose however

that we have access to rank-r approximations of K(1)XX

and K(2)XX :

K(1)XX ≈ Q

(1)T (1)Q(1)>, K(2)XX ≈ Q

(2)T (2)Q(2)>,

where Q(1), Q(2) are n × r and T (1), T (2) are r × r(Figure 1). This rank decomposition makes the MVMsignificantly cheaper to compute. Plugging these de-compositions in to (10), we derive:

Kv = ∆(Q(1)T (1)Q(1)> Dv Q

(2)T (2)Q(2)>). (11)

We prove the following key lemma in the supplemen-tary materials about (11):

Lemma 3.1. Suppose that K(1)XX = Q(1)T (1)Q(1)> and

K(2)XX = Q(1)T (1)Q(1)>, where Q(1) and Q(2) are n× r

matrices and T (1) and T (2) are r × r. Then (K(1)XX ◦

K(2)XX)v can be computed with (11) in O(r2n) time.

Therefore, if we can efficiently compute low-rank de-compositions of K(1) and K(2), then we immediatelyapply Lemma 3.1 to perform fast MVMs.

Computing low-rank structure. WithLemma 3.1, we have reduced the problem ofcomputing MVMs with K to that of constructing

low-rank decompositions for K(1)XX and K

(2)XX . Since

we are assuming we can take fast MVMs with thesekernel matrices, we now turn to the Lanczos decom-position (Lanczos, 1950; Paige, 1972). The Lanczosdecomposition is an iterative algorithm that takes asymmetric matrix A and probe vector b and returnsQ and T such that A ≈ QTQ>, with Q orthogonal.

This decomposition is exact after n iterations. How-ever, if we only compute r < n columns of Q, thenQrTrQ

>r is an effective low-rank approximation of A

(Nickisch et al., 2009; Simon and Zha, 2000). Unlikestandard low rank approximations (such as the singu-lar value decomposition), the algorithm for computing

the Lanczos decomposition K(i)XX = Q(i)T (i)Q(i)> re-

quires only r MVMs, leading to the following lemma:

Lemma 3.2. Suppose that MVMs with K(i)XX can be

computed in O(µ(K(i)XX)) time. Then the rank-r Lanc-

zos decomposition K(i)XX ≈ Q

(i)r T

(i)r Q

(i)>r can be com-

puted in O(rµ(K(i)XX)) time.

The above discussion motivates the following algo-

rithm for computing (K(1)XX · K

(2)XX)v, which is sum-

marized by Figure 1: First, compute the rank-r Lanc-zos decomposition of each matrix; then, apply (11).Lemmas 3.2 and 3.1 together imply that this takes

O(rµ(K(1)XX) + rµ(K

(2)XX) + r2n) time.

Extending to product kernels with three com-ponents. Now consider a kernel that decomposesas the product of three components, k(x,x′) =k(1)(x,x′)k(2)(x,x′)k(3)(x,x′). An MVM with this

kernel is given by Kv = (K(1)XX ◦K

(2)XX ◦K

(3)XX)v. Define

K(1)XX = K

(1)XX ◦K

(2)XX and K

(2)XX = K

(3)XX . Then

Kv = (K(1)XX ◦ K

(2)XX)v , (12)

reducing the three component problem back to twocomponents. To compute the Lanczos decomposition

of K(1)XX , we use the method described above for com-

puting MVMs with K(1)XX ◦K

(2)XX .

Extending to product kernels with many com-ponents. The approach for the three component set-ting leads naturally to a divide and conquer strategy.

Given a kernel matrix K = K(1)XX ◦· · ·◦K

(d)XX we define

K(1)XX = K

(1)XX ◦ · · · ◦K

( d2 )

XX (13)

K(2)XX = K

( d2+1)

XX ◦ · · · ◦K(d)XX , (14)

which lets us rewrite K = K(1)XX ◦ K

(2)XX . By apply-

ing this splitting recursively, we can compute matrix-

Page 5: Abstract m<n arXiv:1802.08903v1 [cs.LG] 24 Feb 2018 · Jacob R. Gardner 1, Geo Pleiss , Ruihan Wu 1;2, Kilian Q. Weinberger , Andrew Gordon Wilson1 (CG). This technique exploits

Jacob R. Gardner1, Geoff Pleiss1, Ruihan Wu1,2, Kilian Q. Weinberger1, Andrew Gordon Wilson1

0 20 40 60 80 100

Number of Lanczos iterations (rank)

10−7

10−5

10−3

10−1

Ave

rage

MV

Mer

ror

1% error

0.1% error

Accuracy of Lanczos Decomposition

12 terms

8 terms

4 terms

101 102 103 104

Number of inducing points per dimension

101

102

103

104

Tra

inin

gti

me

(s)

Scaling with Inducing Points

SKIP

SGPR

KISS-GP

Figure 2: Left: Relative error of MVMs computed using SKIP compared to the exact value Kv. Right: Trainingtime as a function of the number of inducing points per dimension. KISS-GP (SKI with Kronecker factorization)scales well with the total number of inducing points, but badly with number of inducing points per dimension,because the required total number of inducing points scales exponentially with the number of dimensions.

vector multiplies with K, leading to the following run-ning time complexity:

Theorem 3.3. Suppose that K = K(1)XX ◦ · · · ◦K

(d)XX ,

and that computing a matrix-vector multiply with any

K(i)XX requires O(µ(K

(1)XX)) operations. Computing an

MVM with K requires O(drµ(K(i)) + r3n log d+ r2n)time, where r is the rank of the Lanczos decompositionused.

Sequential MVMs. If we are computing manyMVMs with the same matrix, then we can further re-duce this complexity by caching the Lanczos decom-

position. The terms O(drµ(K(i)XX) + r3n log d) rep-

resent the time to construct the Lanczos decomposi-tion. However, note that this decomposition is not de-pendent on the vector that we wish to multiply with.Therefore, if we save the decomposition for future com-putation, we have the following corollary:

Corollary 3.4. Any subsequent MVMs with K requireO(r2n) time.

If matrix-vector multiplications with K(i)XX can be per-

formed with significantly fewer than n2 operations,this results in a significant complexity improvementover explicitly computing the full kernel matrix K.

3.1 Structured kernel interpolation forproducts (SKIP)

So far we have assumed access to fast MVMs witheach constituent kernel matrix of an elementwise(Hadamard) product: K = K

(1)XX ◦ · · · ◦ K

(d)XX . To

achieve this, we apply the SKI approximation (Sec-tion 2.3) to each component:

K(i)XX = W (i)KUUW

(i)>. (15)

When using SKI approximations, the running time ofour product kernel inference technique with p itera-tions of CG becomes O(dr(n+m logm) + r3n log d+pr2n). The running time of SKIP is compared to thatof other inference techniques in Table 2.

4 MVM ACCURACY ANDSCALABILITY

We first evaluate the accuracy of our proposed ap-proach with product kernels in a controlled syntheticsetting. We draw 2500 data points in d dimensionsfrom N (0, I) and compute an RBF kernel matrix withlengthscale 1 over these data points. We evaluate therelative error of SKIP compared exact MVMs as afunction of r – the number of Lanczos iterators. Weperform this test for for 4, 8, and 12 dimensional data,resulting in a product kernel with 4, 8, and 12 com-ponents respectively. The results, averaged over 100trials, are shown in Figure 2 (left). Even in the 12dimensional setting, an extremely small value of r issufficient to get very accurate MVMs: less than 1%error is achieved when k = 30. For a discussion ofincreasing error with dimensionality, see Section 7. Infuture experiments, we set the maximum number ofLanczos iterations to 100, but note that the conver-gence criteria is typically met far sooner. In the rightside of Figure 2, we demonstrate the improved scalingof our method with the number of inducing points perdimension over KISS-GP. To do this, we use the d = 4dimensional Power dataset from the UCI repository,and plot inference step time as a function of m. Whileour method clearly scales better with m than bothKISS-GP and SGPR, we also note that because SKIPonly applies the inducing point approximation to one-dimensional kernels, we anticipate ultimately needingsignificantly fewer inducing points than either SGPRor KISS-GP which need to cover the full d dimensional

Page 6: Abstract m<n arXiv:1802.08903v1 [cs.LG] 24 Feb 2018 · Jacob R. Gardner 1, Geo Pleiss , Ruihan Wu 1;2, Kilian Q. Weinberger , Andrew Gordon Wilson1 (CG). This technique exploits

Product Kernel Interpolation for Scalable Gaussian Processes

space with inducing points.

5 APPLICATION 1: ANEXPONENTIAL IMPROVEMENTTO SKI

Wilson and Nickisch (2015) use a Kronecker decom-position of KUU to apply SKI for d > 1 dimensions,which requires a fully connected multi-dimensionalgrid of inducing points U . Thus if we wish to havem distinct inducing point values for each dimension,the grid requires md inducing points – i.e. MVMs withthe SKI approximate KXX require O(n + dmd logm)time. It is therefore computationally infeasible to ap-ply SKI with a Kronecker factorization, referred to inWilson and Nickisch (2015) as KISS-GP, to more thanabout five dimensions. However, using the proposedSKIP method of Section 3, we can reduce the runningtime complexity of SKI in d dimensions from exponen-tial O(n + dmd logm) to linear O(dn + dm logm)! Ifwe express a d-dimensional kernel as the product of done-dimensional kernels, then each component kernelrequires only m grid points, rather than md. For theRBF and ARD kernels, decomposing the kernel in thisway yields the same kernel function.

Datasets. We evaluate SKIP on six benchmarkdatasets. The precipitation dataset contains hourlyrainfall measurements from hundreds of stationsaround the country. The remaining datasets are takenfrom the UCI machine learning dataset repository.KISS-GP (SKI with a Kronecker factorization) is notapplicable when d > 5, and the full GP is not applica-ble on the four largest datasets.

Methods. We compare against the popular sparsevariational Gaussian processes (SGPR) (Titsias, 2009;Hensman et al., 2013) implemented in GPflow(Matthews et al., 2017). We also compare to our GPUimplementation of KISS-GP where possible, as well asour GPU implementation of the full GP on the twosmallest datasets. All experiments were run on anNVIDIA Titan Xp. We evaluate SGPR using 200, 400and 800 inducing points. All models use the RBF ker-nel and a constant prior mean function. We optimizehyperparameters with ADAM using default optimiza-tion parameters.

Discussion. The results of our experiments areshown in Table 1. On the two smallest datasets, theFull GP model outperforms all other methods in termsof speed. This is due to the overhead added by in-ducing point methods significantly outweighing simplesolves with conjugate gradients with such little data.SKIP is able to match the error of the full GP model

on elevators, and all methods have comparable erroron the Pumadyn dataset.

On the precipitation dataset, inference with standardKISS-GP is still tractable due to the low dimension-ality, and KISS-GP is both fast and accurate. Us-ing SKIP results in higher error than KISS-GP, be-cause we were able to use significantly fewer Lanczositerations for our approximate MVMs than on otherdatasets due to the space complexity. We discuss thespace complexity limitation further in the discussionsection. Nevertheless, SKIP still performs better thanSGPR. SGPR results with 400 and 800 inducing pointsare unavailable due to GPU memory constraints. Onthe remaining datasets, SKIP is able to achieve com-parable or better overall error than SGPR, but with asignificantly lower runtime.

6 APPLICATION 2: MULTI-TASKLEARNING

We demonstrate how the fast elementwise matrix vec-tor products with SKIP can also be applied to accel-erate multi-task Gaussian processes (MTGPs). Addi-tionally, because SKIP provides cheap marginal like-lihood computations, we extend standard MTGPs toconstruct an interpretable and robust multi-task GPmodel which discovers latent clusters among tasks us-ing Gibbs’ sampling. We apply this model to a par-ticularly consequential child development dataset fromthe Gates foundation.

Motivating problem. The Gates foundation hascollected an aggregate longitudinal dataset of child de-velopment, from studies performed around the world.We are interested in predicting the future developmentfor a given child (as measured by weight) using a lim-ited number of existing measurements. Children in thedataset have a varying number of measurements (rang-ing from 5 to 30), taken at irregular times throughouttheir development. We therefore model this problemwith a multitask approach, where we treat each child’sdevelopment as a task. This approach is the basis ofseveral medical forecasting models (Alaa et al., 2017;Cheng et al., 2017; Xu et al., 2016).

Multi-task learning with GPs. The com-mon multi-task setup involves s datasets cor-responding to a set of different tasks, Di :{

(x(i)1 , y

(i)1 ), ..., (x

(i)ni , y

(i)ni )}si=1

. The multi-task Gaus-

sian process (MTGP) of Bonilla et al. (2008) extendsstandard GP regression to share information betweenseveral related tasks. MTGPs assume that the co-variance between data points factors as the productof kernels over (e.g. spatial or temporal) inputs and

Page 7: Abstract m<n arXiv:1802.08903v1 [cs.LG] 24 Feb 2018 · Jacob R. Gardner 1, Geo Pleiss , Ruihan Wu 1;2, Kilian Q. Weinberger , Andrew Gordon Wilson1 (CG). This technique exploits

Jacob R. Gardner1, Geoff Pleiss1, Ruihan Wu1,2, Kilian Q. Weinberger1, Andrew Gordon Wilson1

Table 1: Comparison of SKIP and other methods on higher dimensional datasets. In this table, m is the totalnumber of inducing points, rather than number of inducing points per dimension. (*We use m = 100 for SKIPon all datasets except precipitation, where we use m = 120K.)

Dataset Metric Full GPSGPR

(m = 200)SGPR

(m = 400)SGPR

(m = 800)KISS-GP

(m = 120K)SKIP

(m = 100)*

Pumadyn(n = 8192, d = 32)

Test MAE 0.721 0.766 0.766 0.766 – 0.766Train Time (s) 4 28 67 235 – 65

Elevators(n = 16599, d = 18)

Test MAE 0.072 0.157 0.157 0.157 – 0.072Train Time (s) 12 46 122 425 – 23

Precipitation(n = 628474, d = 3)

Test MAE – 14.79 – – 9.81 14.08Train Time (s) – 1432 – – 615 34.16

KEGG(n = 48827, d = 22)

Test MAE – 0.101 0.093 0.087 – 0.065Train Time (s) – 116 299 9926 – 66

Protein(n = 45730, d = 9)

Test MAE – 7.219 4.97 4.72 – 1.97Train Time (s) – 139 397 1296 – 35

Video(n = 68784, d = 16)

Test MAE – 6.836 6.463 6.270 – 5.621Train Time (s) – 113 334 1125 – 57

0 5 10 15

Time (Normalized)

0

5

10

15

Child

50W

eigh

t(N

orm

aliz

ed) New Task

Clus. 1

Clus. 2

Clus. 3

New Task

Existing Tasks

0 5 10 15

Time (Normalized)

Clus. 1 (p=0.20)Clus. 2 (p=0.40)Clus. 3 (p=0.40)

3 Observed Measurements

Train

Test

Pred

0 5 10 15

Time (Normalized)

Clus. 1 (p=0.00)Clus. 2 (p=0.80)Clus. 3 (p=0.20)

5 Observed Measurements

Train

Test

Pred

0 5 10 15

Time (Normalized)

Clus. 1 (p=0.00)Clus. 2 (p=1.00)Clus. 3 (p=0.00)

9 Observed Measurements

Train

Test

PredWei

ght (

Nor

mal

ized

)

Figure 3: Applying the cluster-based MTGP model to new tasks.

Table 2: Asymptotic complexities of a single calcu-lation of Equation 3 with n data points, m induc-ing points, r Lanczos iterations and p CG iterations.The first two rows correspond to an exact GP withCholesky and CG.

Method Complexity of 1 Inference StepGP (Chol) O(n3)GP (MVM) O(pn2)

SVGP O(nm2 +m3 + dnm)KISS-GP O(pn+ pdmd logm)

SKIP O(drn+ drm logm+ r3n log d+ pr2n)

40 60

Number of tasks

5

10

15

MS

E

Shared GP

MTGP - w/o clusters

MTGP - with clusters

40 60

Number of tasks

200

250

300

350

400

NL

L

Figure 4: Predictive performance on childhood devel-opment dataset as a function of the number of tasks.

tasks. Specifically, given data points x and x′ from

tasks i and j, the MTGP kernel is given by

k((x, i), (x′, j)) = kinput(x,x)ktask(i, j), (16)

where kinput is a kernel over inputs, and ktask(i, j) – thecoregionalization kernel – is commonly parameterizedby a low-rank covariance matrix M = BB> ∈ Rs×sthat encodes pairwise correlations between all pairs oftasks. The entries of B are learned by maximizing (3).We can express the covariance matrix Kmulti for all nmeasurements as

Kmulti = K(data)XX ◦

(V BB>V

),

where V is an n×s matrix with one-hot rows: Vij = 1if the ith observation belongs to task j. We can ap-ply SKIP to multi-task problems by using a SKI ap-proximation of K(data) and computing its Lanczos de-composition. If B is rank-q, with q < n, then we donot need to decompose V BB>V > since the matrixaffords O(n + sq) MVMs.2 For one-dimensional in-puts, the time complexity of an MVM with Kmulti isO(n+m logm+ sq) – a substantial improvement overstandard inducing-point methods with MTGPs, which

2 MVMs are O(n + sq) because V has O(n) nonzeroelements and B is an s× q matrix.

Page 8: Abstract m<n arXiv:1802.08903v1 [cs.LG] 24 Feb 2018 · Jacob R. Gardner 1, Geo Pleiss , Ruihan Wu 1;2, Kilian Q. Weinberger , Andrew Gordon Wilson1 (CG). This technique exploits

Product Kernel Interpolation for Scalable Gaussian Processes

typically require at least O(nm2q) time (Bonilla et al.,2008; Alvarez and Lawrence, 2011). For n = 4000,SKIP speeds up marginal likelihood computations bya factor of 20.

Learning clusters of tasks. Motivated by the workof Rasmussen and Ghahramani (2002), Shi et al.(2005), Schulam and Saria (2015), Hensman et al.(2015), and Xu et al. (2016), we propose a modificationto the standard MTGP framework. We hypothesizethat similarities between tasks can be better expressedthrough c latent subpopulations, or clusters, ratherthan through pairwise associations. We place an inde-pendent uniform categorical prior over λi ∈ [1, . . . , c],the cluster assignment for task i. Given measurementsxi,x

′j for tasks i and j, we propose a kernel consisting

of product and sum structure that captures cluster-level trends and individual-level trends:

k(xi,x′j) = kcluster(x,x

′)δλi=λj+ kindiv(x,x′)δi=j .

Here, kcluster and kindiv are both Matern kernels (ν =52 ) operating on x, and the δ terms represent indica-tor functions. Both terms can be easily expressed asproduct kernels. We infer the posterior distributionof cluster assignments through Gibbs sampling. Givenλ−i, the cluster assignments for all tasks except theith, we sample an assignment for the ith task from themarginal posterior distribution

p(λi|y, λ−i) ∝ p(y | λ−i, λi = aθ)p(λ−i, λi = a)

Drawing a sample for the full vector λ requires O(cs)calculations of (3), an operation made relatively inex-pensive by applying SKIP to the underlying model.

Results. We compare the cluster-based MTGPagainst two baselines: 1) a single-task GP baseline,which treats all available data as a single task, and 2)the standard MTGP. In Figure 4, we measure the ex-trapolation accuracy for 25 children as additional chil-dren (tasks) are added to the model. As the modelsare supplied with data from additional children, theyare able to refine the extrapolations on all children.The predictions of the cluster model slightly outper-form the standard MTGP, and significantly outper-form the single-task model. Perhaps the key advantageof the clustering approach is interpretability: in Fig-ure 3 (left), we see three distinct development types:above-average, average, and below average. We thendemonstrate that as more data is observed when weapply the model to a new child with limited measure-ments, the model becomes increasingly certain thatthe child belongs to the above-average subpopulation.

7 DISCUSSION

It is our hope that this work highlights a questionof foundational importance for scalable GP inference:given the ability to compute Av and Bv quickly formatrices A and B, how do we compute (A ◦ B)v ef-ficiently? We have shown an answer to this questioncan exponentially improve the scalability and generalapplicability of MVM-based methods for fast Gaussianprocesses.

Stochastic diagonal estimation. Our method re-lies primarily on quickly computing the diagonal inEquation (10). Techniques exist for stochastic di-agonal estimation (Fitzsimons et al., 2016; Hutchin-son, 1990; Selig et al., 2012; Bekas et al., 2007). Wefound that these techniques converged slower than ourmethod in practice, but they may be more appropriatefor kernels with high rank structure.

Higher-order product kernels. A fundamentalproperty of the Hadamard product is that rank(A ◦B) ≤ rank(A)rank(B) suggesting that we may needhigher rank approximations with increasing dimen-sion. In the limit, the SKI approximation WKUUW

>

can be used in place of the Lanczos decomposition inequation (10), resulting in an exact algorithm withO(dnm + dm2 logm) runtime: simply set Qk = Wand MVMs require O(n) time instead of O(nk), andset Tk = KUU and MVMs now require O(m logm) in-stead of O(k2). This adaptation is rarely necessary, asthe accuracy of MVMs with SKIP increases expone-tially in k in practice.

Space complexity. To perform the matrix-vectormultiplication algorithm described above, we muststore the Lanczos decomposition of each componentkernel matrix and intermediate matrices in the mergestep for O(dkn) storage. This is better storage thanthe O(n2) storage required in full GP regression, orO(nm) storage for standard inducing point methods,but worse than the linear storage requirements of SKI.In practice, we note that GPU memory is indeed oftenthe major limitation of our method, as storing evenk = 20 or k = 30 copies of a dataset in GPU memorycan be expensive.

Acknowledgments

JRG, GP, and KQW are supported in part by grantsfrom the National Science Foundation (III-1525919,IIS-1550179, IIS-1618134, S&AS 1724282, and CCF-1740822), the Office of Naval Research DOD (N00014-17-1-2175), and the Bill and Melinda Gates Founda-tion. AGW is supported by NSF IIS-1563887.

Page 9: Abstract m<n arXiv:1802.08903v1 [cs.LG] 24 Feb 2018 · Jacob R. Gardner 1, Geo Pleiss , Ruihan Wu 1;2, Kilian Q. Weinberger , Andrew Gordon Wilson1 (CG). This technique exploits

Jacob R. Gardner1, Geoff Pleiss1, Ruihan Wu1,2, Kilian Q. Weinberger1, Andrew Gordon Wilson1

References

Alaa, A. M., Yoon, J., Hu, S., and van der Schaar,M. (2017). Personalized risk scoring for criticalcare prognosis using mixtures of gaussian processes.IEEE Transactions on Biomedical Engineering.

Alvarez, M. A. and Lawrence, N. D. (2011). Compu-tationally efficient convolved multiple output Gaus-sian processes. Journal of Machine Learning Re-search, 12(May):1459–1500.

Bekas, C., Kokiopoulou, E., and Saad, Y. (2007). Anestimator for the diagonal of a matrix. Applied nu-merical mathematics, 57(11):1214–1229.

Bonilla, E. V., Chai, K. M., and Williams, C. (2008).Multi-task Gaussian process prediction. In NIPS,pages 153–160.

Cheng, L.-F., Darnell, G., Chivers, C., Draugelis,M. E., Li, K., and Engelhardt, B. E. (2017). Sparsemulti-output gaussian processes for medical time se-ries prediction. arXiv preprint arXiv:1703.09112.

Cunningham, J. P., Shenoy, K. V., and Sahani, M.(2008). Fast gaussian process methods for point pro-cess intensity estimation. In Proceedings of the 25thinternational conference on Machine learning, pages192–199. ACM.

Dong, K., Eriksson, D., Nickisch, H., Bindel, D., andWilson, A. G. (2017). Scalable log determinants forgaussian process kernel learning. In NIPS.

Durichen, R., Pimentel, M. A., Clifton, L., Schweikard,A., and Clifton, D. A. (2015). Multitask gaussianprocesses for multivariate physiological time-seriesanalysis. IEEE Transactions on Biomedical Engi-neering, 62(1):314–322.

Durrande, N., Ginsbourger, D., and Roustant, O.(2011). Additive kernels for gaussian process mod-eling. arXiv preprint arXiv:1103.4023.

Duvenaud, D., Lloyd, J. R., Grosse, R., Tenenbaum,J. B., and Ghahramani, Z. (2013). Structure dis-covery in nonparametric regression through compo-sitional kernel search. In Proceedings of the 30th In-ternational Conference on Machine Learning, pages1166–1174.

Fitzsimons, J. K., Osborne, M. A., Roberts, S. J., andFitzsimons, J. F. (2016). Improved stochastic traceestimation using mutually unbiased bases. arXivpreprint arXiv:1608.00117.

Gardner, J. R., Song, X., Weinberger, K. Q., Barbour,D. L., and Cunningham, J. P. (2015). Psychophys-ical detection testing with bayesian active learning.In UAI, pages 286–295.

Golub, G. H. and Van Loan, C. F. (2012). Matrixcomputations, volume 3. JHU Press.

Gonen, M. and Alpaydın, E. (2011). Multiple kernellearning algorithms. Journal of machine learningresearch, 12(Jul):2211–2268.

Hensman, J., Fusi, N., and Lawrence, N. D. (2013).Gaussian processes for big data. arXiv preprintarXiv:1309.6835.

Hensman, J., Rattray, M., and Lawrence, N. D. (2015).Fast nonparametric clustering of structured time-series. IEEE transactions on pattern analysis andmachine intelligence, 37(2):383–393.

Herlands, W., Wilson, A., Nickisch, H., Flaxman, S.,Neill, D., Van Panhuis, W., and Xing, E. (2016).Scalable gaussian processes for characterizing mul-tidimensional change surfaces. In Artificial Intelli-gence and Statistics, pages 1013–1021.

Hutchinson, M. F. (1990). A stochastic estimatorof the trace of the influence matrix for laplaciansmoothing splines. Communications in Statistics-Simulation and Computation, 19(2):433–450.

Jones, D. R., Schonlau, M., and Welch, W. J. (1998).Efficient global optimization of expensive black-box functions. Journal of Global optimization,13(4):455–492.

Keys, R. (1981). Cubic convolution interpolation fordigital image processing. IEEE transactions onacoustics, speech, and signal processing, 29(6):1153–1160.

Lanczos, C. (1950). An iteration method for the so-lution of the eigenvalue problem of linear differen-tial and integral operators. United States Governm.Press Office Los Angeles, CA.

MacKay, D. J. (1998). Introduction to Gaussian pro-cesses. In Bishop, C. M., editor, Neural Networksand Machine Learning, chapter 11, pages 133–165.Springer-Verlag.

Matthews, A. G. d. G., van der Wilk, M., Nickson,T., Fujii, K., Boukouvalas, A., Leon-Villagra, P.,Ghahramani, Z., and Hensman, J. (2017). Gpflow:A gaussian process library using tensorflow. Journalof Machine Learning Research, 18(40):1–6.

Nickisch, H., Pohmann, R., Scholkopf, B., and Seeger,M. (2009). Bayesian experimental design of mag-netic resonance imaging sequences. In NIPS, pages1441–1448.

Paige, C. C. (1972). Computational variants of thelanczos method for the eigenproblem. IMA Journalof Applied Mathematics, 10(3):373–381.

Quinonero-Candela, J. and Rasmussen, C. E. (2005).A unifying view of sparse approximate gaussian pro-cess regression. Journal of Machine Learning Re-search, 6(Dec):1939–1959.

Page 10: Abstract m<n arXiv:1802.08903v1 [cs.LG] 24 Feb 2018 · Jacob R. Gardner 1, Geo Pleiss , Ruihan Wu 1;2, Kilian Q. Weinberger , Andrew Gordon Wilson1 (CG). This technique exploits

Product Kernel Interpolation for Scalable Gaussian Processes

Rasmussen, C. E. and Ghahramani, Z. (2002). Infinitemixtures of gaussian process experts. In NIPS, pages881–888.

Rasmussen, C. E. and Williams, C. K. (2006). Gaus-sian processes for machine learning, volume 1. MITpress Cambridge.

Saatci, Y. (2012). Scalable inference for structuredGaussian process models. PhD thesis, University ofCambridge.

Schulam, P. and Saria, S. (2015). A framework for indi-vidualizing predictions of disease trajectories by ex-ploiting multi-resolution structure. In NIPS, pages748–756.

Selig, M., Oppermann, N., and Enßlin, T. A. (2012).Improving stochastic estimates with inference meth-ods: Calculating matrix diagonals. Physical ReviewE, 85(2):021134.

Shewchuk, J. R. et al. (1994). An introduction to theconjugate gradient method without the agonizingpain.

Shi, J. Q., Murray-Smith, R., and Titterington, D.(2005). Hierarchical gaussian process mixtures forregression. Statistics and computing, 15(1):31–41.

Simon, H. D. and Zha, H. (2000). Low-rank matrixapproximation using the lanczos bidiagonalizationprocess with applications. SIAM Journal on Scien-tific Computing, 21(6):2257–2274.

Snelson, E. and Ghahramani, Z. (2006). Sparse Gaus-sian processes using pseudo-inputs. In NIPS, pages1257–1264.

Snoek, J., Larochelle, H., and Adams, R. P. (2012).Practical bayesian optimization of machine learningalgorithms. In Advances in neural information pro-cessing systems, pages 2951–2959.

Titsias, M. K. (2009). Variational learning of induc-ing variables in sparse gaussian processes. In In-ternational Conference on Artificial Intelligence andStatistics, pages 567–574.

Ubaru, S., Chen, J., and Saad, Y. (2017). Fast estima-tion of tr (f (a)) via stochastic lanczos quadrature.SIAM Journal on Matrix Analysis and Applications,38(4):1075–1099.

Wilson, A. and Adams, R. (2013). Gaussian processkernels for pattern discovery and extrapolation. InICML, pages 1067–1075.

Wilson, A. G. (2014). Covariance kernels for fast au-tomatic pattern discovery and extrapolation withgaussian processes. University of Cambridge.

Wilson, A. G. and Nickisch, H. (2015). Kernel inter-polation for scalable structured gaussian processes(kiss-gp). In ICML, pages 1775–1784.

Xu, Y., Xu, Y., and Saria, S. (2016). A bayesian non-parametric approach for estimating individualizedtreatment-response curves. In Machine Learning forHealthcare Conference, pages 282–300.

Page 11: Abstract m<n arXiv:1802.08903v1 [cs.LG] 24 Feb 2018 · Jacob R. Gardner 1, Geo Pleiss , Ruihan Wu 1;2, Kilian Q. Weinberger , Andrew Gordon Wilson1 (CG). This technique exploits

Jacob R. Gardner1, Geoff Pleiss1, Ruihan Wu1,2, Kilian Q. Weinberger1, Andrew Gordon Wilson1

Supplementary Materials for:Product Kernel Interpolation for Scalable Gaussian Processes

Jacob R. Gardner1, Geoff Pleiss1, Ruihan Wu1,2, Kilian Q. Weinberger1, Andrew Gordon Wilson1

1Cornell University, 2Tsinghua University

S1 Proof of Lemma 3.1

Letting q(1)i denote the ith row of Q(1) and q

(2)i denote

the ith row of Q(2), we can express the ith entry Kv,[Kv]i as:

[Kv]i = q(1)i T (1)Q(1)> Dv Q

(2)T (2)q(2)>i

To evaluate this for all i, we first once compute thek × k matrix:

M (1,2) = T (1)Q(1)> Dv Q(2)T (2).

This can be done in O(nk2) time. T (1)Q(1)> andQ(2)T (2) can each be computed in O(nk2) time, asthe Q matrices are n×k and the T matrices are n×k.Multiplying one of the results by Dv takes O(nk) timeas it is diagonal. Finally, multiplying the two resultingn× k matrices together takes O(nk2) time.

After computing M (1,2), we can compute each elementof the matrix-vector multiply as:

[Kv]i = q(1)i M (1,2)q

(2)>i .

Because M (1,2) is k× k, each of these takes O(k) timeto compute. Since there are n entries to evaluate inthe MVM Kv in total, the total time requirement aftercomputing M (1,2) is O(kn) time. Thus, given low rankstructure, we can compute Kv in O(k2n) time total.

S2 Proof of Theorem 3.3

Given the Lanczos decompositions of K(1) = K(1)XX ◦

· · · ◦ K(a)XX and K(2) = K

(a+1)XX ◦ · · · ◦ K(d)

XX , we can

compute matrix-vector multiplies with K(1) ◦ K(2) inO(k2n) time each. This lets us compute the Lanczosdecomposition of K(1) ◦ K(2) in O(k3n) time.

For clarity, suppose first that d = 3, i.e., K = K(1)XX ◦

K(2)XX ◦K

(3)XX . We first Lanczos decompose K

(1)XX , K

(2)XX

and K(3)XX . Assuming for simplicty that MVMs with

each matrix take the same amount of time, This takes

O(kµ(K(i)XX)) time total. We then use these Lanc-

zos decompositions to compute matrix-vector multi-

ples with K(1)XX in O(k2n)time each. This allows us

to Lanczos decompose it in O(k3n) time total. Wecan then compute matrix-vector multiplications Kvin O(k2n) time.

In the most general setting where K = K(1)XX ◦ · · · ◦

K(d)XX , we first Lanczos decompose the d component

matrices in O(dkµ(K(i))) and then perform O(log d)merges as described above, each of which takes O(k3n)time. After computing all necessary Lanczos decom-positions, matrix-vector multiplications with K can beperformed in O(k2n) time.

As a result, a single matrix-vector multiply with Ktakes O(dkµ(K(i)) + k3n log d + k2n) time. Withthe Lanczos decompositions precomputed, multipleMVMs in a row can be performed significantly faster.For example, running p iterations of conjugate gra-dients with K takes O(dkµ(K(i)) + k3n log d + pk2n)time.