d1ac7b831ad36cd0e4bdd7980819f83208345148,gpflow/expectations.py,,_expectation,#Any#Any#Any#Any#Any#,560
Before Change
raise NotImplementedError("Different features are not supported")
if kern1 != kern2:
raise NotImplementedError("Calculating the expectation over two different Product kernels is not supported")
kern = kern1
feat = feat1
After Change
:return: NxDxQ
with params_as_tensors_for(mean1), params_as_tensors_for(mean2):
N = tf.shape(p.mu)[0]
e_xxt = p.cov + (p.mu[:, :, None] * p.mu[:, None, :]) // NxDxD
e_xxt_A = tf.matmul(e_xxt, tf.tile(mean2.A[None, ...], (N, 1, 1))) // NxDxQ
e_x_bt = p.mu[:, :, None] * mean2.b[None, None, :] // NxDxQ
return e_xxt_A + e_x_bt
In pattern: SUPERPATTERN
Frequency: 3
Non-data size: 6
Instances
Project Name: GPflow/GPflow
Commit Name: d1ac7b831ad36cd0e4bdd7980819f83208345148
Time: 2018-02-07
Author: alex.ialongo@gmail.com
File Name: gpflow/expectations.py
Class Name:
Method Name: _expectation
Project Name: deepmind/sonnet
Commit Name: ef86d2e73e7ce03c4184a04a336d96caf661269a
Time: 2017-07-03
Author: noreply@google.com
File Name: sonnet/python/modules/conv.py
Class Name: Conv1DTranspose
Method Name: _build
Project Name: GPflow/GPflow
Commit Name: 0f2d9c91b5b2b4f32ca4f1298c2549c2b03bc967
Time: 2016-04-13
Author: alexggmatthews@googlemail.com
File Name: GPflow/sgpr.py
Class Name: GPRFITC
Method Name: build_predict