[objective grads] undid the change, as this would lead to dramatic problems in reloading old models using the pickle module

This commit is contained in:
Max Zwiessele 2015-01-13 13:46:49 +00:00
parent 17f42768da
commit 20eff02061

View file

@ -154,7 +154,7 @@ class Model(Parameterized):
"""
return -(self._log_likelihood_gradients() + self._log_prior_gradients())
def _objective_grads(self, x):
def _grads(self, x):
"""
Gets the gradients from the likelihood and the priors.
@ -200,7 +200,7 @@ class Model(Parameterized):
return np.inf
return obj
def _objective_and_grads(self, x):
def _objective_grads(self, x):
try:
self.optimizer_array = x
obj_f, self.obj_grads = self.objective_function(), self._transform_gradients(self.objective_function_gradients())