mirror of
https://github.com/SheffieldML/GPy.git
synced 2026-05-01 07:46:22 +02:00
fixed stationary
This commit is contained in:
parent
06dd27c634
commit
b32929a8a5
1 changed files with 2 additions and 2 deletions
|
|
@ -102,8 +102,8 @@ class Exponential(Stationary):
|
||||||
def __init__(self, input_dim, variance=1., lengthscale=None, ARD=False, name='Exponential'):
|
def __init__(self, input_dim, variance=1., lengthscale=None, ARD=False, name='Exponential'):
|
||||||
super(Exponential, self).__init__(input_dim, variance, lengthscale, ARD, name)
|
super(Exponential, self).__init__(input_dim, variance, lengthscale, ARD, name)
|
||||||
|
|
||||||
def K(self, X, X2=None):
|
def K_of_r(self, r):
|
||||||
return self.variance * np.exp(-0.5 * dist)
|
return self.variance * np.exp(-0.5 * r)
|
||||||
|
|
||||||
def dK_dr(self, r):
|
def dK_dr(self, r):
|
||||||
return -0.5*self.K_of_r(r)
|
return -0.5*self.K_of_r(r)
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue