d6883d26b557cbeeaceba38643bf5b98819fbed3,testing/test_model.py,TestKeyboardCatching,test_optimize_np,#TestKeyboardCatching#,176
Before Change
x0 = self.m.get_free_state()
self.m.compile()
self.m._objective = KeyboardRaiser(15, self.m._objective)
self.m.optimize(disp=0, maxiter=1000, ftol=0, gtol=0)
x1 = self.m.get_free_state()
self.assertFalse(np.allclose(x0, x1))
def test_optimize_tf(self):
After Change
x_before = m.read_trainable_values()
options = {"disp": 0, "maxiter": 1000, "ftol": 0, "gtol": 0}
opt = gpflow.train.ScipyOptimizer(options=options)
with self.assertRaises(KeyboardInterrupt):
opt.minimize(m, step_callback=KeyboardRaiser(15))
x_after = m.read_trainable_values()
self.assertFalse(np.allclose(x_before, x_after))
In pattern: SUPERPATTERN
Frequency: 3
Non-data size: 2
Instances
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: TestKeyboardCatching
Method Name: test_optimize_np
Project Name: pfnet/optuna
Commit Name: f4da1d51694289a40e96fef16e946e6cb3dbd027
Time: 2018-10-24
Author: toshihiko.yanase@gmail.com
File Name: tests/test_study.py
Class Name:
Method Name: test_optimize_with_direction
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