mirror of
https://github.com/SheffieldML/GPy.git
synced 2026-05-11 04:52:37 +02:00
[minibatch] added coverage for branching, spottet bug in X_variance
This commit is contained in:
parent
88a9b92c80
commit
67043e83d7
2 changed files with 13 additions and 12 deletions
|
|
@ -54,7 +54,7 @@ class BGPLVMTest(unittest.TestCase):
|
|||
def test_lik_comparisons_m0_s0(self):
|
||||
# Test if the different implementations give the exact same likelihood as the full model.
|
||||
# All of the following settings should give the same likelihood and gradients as the full model:
|
||||
m = GPy.models.bayesian_gplvm_minibatch.BayesianGPLVMMiniBatch(self.Y, self.Q, missing_data=False, stochastic=False)
|
||||
m = GPy.models.bayesian_gplvm_minibatch.BayesianGPLVMMiniBatch(self.Y, self.Q, X_variance=self.m_full.X.variance.values, missing_data=False, stochastic=False)
|
||||
m[:] = self.m_full[:]
|
||||
np.testing.assert_almost_equal(m.log_likelihood(), self.m_full.log_likelihood(), 7)
|
||||
np.testing.assert_allclose(m.gradient, self.m_full.gradient)
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue