49a385eae93032125a6718433b3ca1753aee3b1e,testing/test_method_equivalence.py,TestEquivalence,test_all,#TestEquivalence#,87

Before Change


                    variances.append(m.kern.variance.value)
                    lengthscales.append(m.kern.lengthscales.value)
            variances, lengthscales = np.array(variances), np.array(lengthscales)
            self.assertTrue(np.allclose(variances, variances[0], 1e-5))
            self.assertTrue(np.allclose(lengthscales, lengthscales.mean(), 1e-4))
            mu0, var0 = self.models[0].predict_y(self.Xtest)
            for m in self.models[1:]:
                mu, var = m.predict_y(self.Xtest)

After Change


            likelihoods = []
            for m in self.models:
                m.compile()
                opt = gpflow.train.ScipyOptimizer()
                opt.minimize(m, maxiter=300)
                neg_obj = tf.negative(m.objective)
                likelihoods.append(m.session.run(neg_obj).squeeze())
            assert_allclose(likelihoods, likelihoods[0], rtol=1e-6)
            variances, lengthscales = [], []
Italian Trulli
In pattern: SUPERPATTERN

Frequency: 3

Non-data size: 5

Instances


Project Name: GPflow/GPflow
Commit Name: 49a385eae93032125a6718433b3ca1753aee3b1e
Time: 2017-11-02
Author: art.art.v@gmail.com
File Name: testing/test_method_equivalence.py
Class Name: TestEquivalence
Method Name: test_all


Project Name: GPflow/GPflow
Commit Name: d6883d26b557cbeeaceba38643bf5b98819fbed3
Time: 2017-09-26
Author: art.art.v@gmail.com
File Name: testing/test_model.py
Class Name: TestOptimize
Method Name: test_adam


Project Name: GPflow/GPflow
Commit Name: 3ae87f9718babe8b7385527b0298ca68b6a75699
Time: 2017-10-29
Author: art.art.v@gmail.com
File Name: testing/test_session.py
Class Name: TestSessionConfiguration
Method Name: test_option_persistance