From 2b8ef1041bf95d7f67ca4fc4d4a3d73cb7e909ff Mon Sep 17 00:00:00 2001 From: Mike Croucher Date: Thu, 26 Feb 2015 13:43:55 +0000 Subject: [PATCH] Exception fixes for Python 3 compat --- GPy/likelihoods/likelihood.py | 2 +- GPy/likelihoods/link_functions.py | 4 ++-- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/GPy/likelihoods/likelihood.py b/GPy/likelihoods/likelihood.py index 33698eb2..813f912f 100644 --- a/GPy/likelihoods/likelihood.py +++ b/GPy/likelihoods/likelihood.py @@ -203,7 +203,7 @@ class Likelihood(Parameterized): def _conditional_mean(self, f): """Quadrature calculation of the conditional mean: E(Y_star|f)""" - raise NotImplementedError, "implement this function to make predictions" + raise NotImplementedError("implement this function to make predictions") def predictive_variance(self, mu,variance, predictive_mean=None, Y_metadata=None): """ diff --git a/GPy/likelihoods/link_functions.py b/GPy/likelihoods/link_functions.py index a4ddc760..60e260e7 100644 --- a/GPy/likelihoods/link_functions.py +++ b/GPy/likelihoods/link_functions.py @@ -182,7 +182,7 @@ class Heaviside(GPTransformation): return np.where(f>0, 1, 0) def dtransf_df(self,f): - raise NotImplementedError, "This function is not differentiable!" + raise NotImplementedError("This function is not differentiable!") def d2transf_df2(self,f): - raise NotImplementedError, "This function is not differentiable!" + raise NotImplementedError("This function is not differentiable!")