mirror of
https://github.com/SheffieldML/GPy.git
synced 2026-05-08 19:42:39 +02:00
Merge branch 'params' of github.com:SheffieldML/GPy into input_dims
This commit is contained in:
commit
603b70bb6e
2 changed files with 7 additions and 0 deletions
|
|
@ -46,6 +46,9 @@ class Add(CombinationKernel):
|
|||
def update_gradients_diag(self, dL_dK, X):
|
||||
[p.update_gradients_diag(dL_dK, X) for p in self.parts]
|
||||
|
||||
def update_gradients_diag(self, dL_dKdiag, X):
|
||||
[p.update_gradients_diag(dL_dKdiag, X[:,i_s]) for p, i_s in zip(self._parameters_, self.input_slices)]
|
||||
|
||||
def gradients_X(self, dL_dK, X, X2=None):
|
||||
"""Compute the gradient of the objective function with respect to X.
|
||||
|
||||
|
|
|
|||
|
|
@ -62,6 +62,10 @@ class Kern(Parameterized):
|
|||
def gradients_X_diag(self, dL_dKdiag, X):
|
||||
raise NotImplementedError
|
||||
|
||||
def update_gradients_diag(self, dL_dKdiag, X):
|
||||
""" update the gradients of all parameters when using only the diagonal elements of the covariance matrix"""
|
||||
raise NotImplementedError
|
||||
|
||||
def update_gradients_full(self, dL_dK, X, X2):
|
||||
"""Set the gradients of all parameters when doing full (N) inference."""
|
||||
raise NotImplementedError
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue