ensuring the shape of the mean vector at predict time fixes bug in EP prediction

This commit is contained in:
James Hensman 2015-09-01 22:38:49 +01:00
parent 938cc49aed
commit ce9ee6c758

View file

@ -201,6 +201,8 @@ class GP(Model):
Kx = kern.K(self.X, Xnew)
mu = np.dot(Kx.T, self.posterior.woodbury_vector)
if len(mu.shape)==1:
mu = mu.reshape(-1,1)
if full_cov:
Kxx = kern.K(Xnew)
if self.posterior.woodbury_inv.ndim == 2: