30a5671297517875caacbf6bd03ae1de0d94ec67,testing/test_mean_functions.py,TestSwitchedMeanFunction,test,#TestSwitchedMeanFunction#,283
Before Change
tf_array = switched_mean.get_free_state()
switched_mean.make_tf_array(tf_array)
sess.run(tf.global_variables_initializer())
fd = {}
switched_mean.update_feed_dict(switched_mean.get_feed_dict_keys(), fd)
with switched_mean.tf_mode():
result = sess.run(switched_mean(X), feed_dict=fd)
np_list = np.array([0., 1.])
After Change
result = sess.run(switched_mean(X))
np_list = np.array([0., 1.])
result_ref = (np_list[X[:, 3].astype(np.int)]).reshape(-1, 1)
assert_allclose(result, result_ref)
class TestBug277Regression(GPflowTestCase):
In pattern: SUPERPATTERN
Frequency: 3
Non-data size: 5
Instances
Project Name: GPflow/GPflow
Commit Name: 30a5671297517875caacbf6bd03ae1de0d94ec67
Time: 2017-11-01
Author: art.art.v@gmail.com
File Name: testing/test_mean_functions.py
Class Name: TestSwitchedMeanFunction
Method Name: test
Project Name: GPflow/GPflow
Commit Name: 126664f626f28f20e9f460c1cf5f6bf4643ce096
Time: 2017-10-30
Author: art.art.v@gmail.com
File Name: testing/test_data_object.py
Class Name: TestDataHolderSimple
Method Name: test_same_shape
Project Name: GPflow/GPflow
Commit Name: 126664f626f28f20e9f460c1cf5f6bf4643ce096
Time: 2017-10-30
Author: art.art.v@gmail.com
File Name: testing/test_data_object.py
Class Name: TestDataHolderIntegers
Method Name: test_same_shape