sqrt pi term was missing in variational expectations

This commit is contained in:
James Hensman 2015-06-12 16:58:29 +01:00
parent 60fabe41e2
commit 24e759199e

View file

@ -267,7 +267,7 @@ class Likelihood(Parameterized):
if self.size: if self.size:
dF_dtheta = self.dlogpdf_dtheta(X, Y[:,None]) # Ntheta x (orig size) x N_{quad_points} dF_dtheta = self.dlogpdf_dtheta(X, Y[:,None]) # Ntheta x (orig size) x N_{quad_points}
dF_dtheta = np.dot(dF_dtheta, gh_w) dF_dtheta = np.dot(dF_dtheta, gh_w)/np.sqrt(np.pi)
dF_dtheta = dF_dtheta.reshape(self.size, shape[0], shape[1]) dF_dtheta = dF_dtheta.reshape(self.size, shape[0], shape[1])
else: else:
dF_dtheta = None # Not yet implemented dF_dtheta = None # Not yet implemented