remove white kernel in new GPR
This commit is contained in:
parent
5654d23637
commit
fd7f111c26
|
@ -98,10 +98,7 @@ class BasicGP(BaseModel):
|
||||||
[
|
[
|
||||||
'GPRC/kern/kernels/0/variance',
|
'GPRC/kern/kernels/0/variance',
|
||||||
'GPRC/kern/kernels/0/lengthscales',
|
'GPRC/kern/kernels/0/lengthscales',
|
||||||
],
|
]
|
||||||
[
|
|
||||||
'GPRC/kern/kernels/1/variance',
|
|
||||||
],
|
|
||||||
]
|
]
|
||||||
|
|
||||||
def _get_kernel_kwargs(self, **kwargs):
|
def _get_kernel_kwargs(self, **kwargs):
|
||||||
|
@ -110,19 +107,14 @@ class BasicGP(BaseModel):
|
||||||
{
|
{
|
||||||
'input_dim': X_dim,
|
'input_dim': X_dim,
|
||||||
'ARD': False
|
'ARD': False
|
||||||
},
|
}
|
||||||
{
|
|
||||||
'input_dim': X_dim,
|
|
||||||
},
|
|
||||||
]
|
]
|
||||||
|
|
||||||
def _build_kernel(self, kernel_kwargs, **kwargs):
|
def _build_kernel(self, kernel_kwargs, **kwargs):
|
||||||
k0 = gpflow.kernels.Exponential(**kernel_kwargs[0])
|
k = gpflow.kernels.Exponential(**kernel_kwargs[0])
|
||||||
k1 = gpflow.kernels.White(**kernel_kwargs[1])
|
|
||||||
if kwargs.pop('optimize_hyperparameters'):
|
if kwargs.pop('optimize_hyperparameters'):
|
||||||
k0.lengthscales.transform = gpflow.transforms.Logistic(
|
k.lengthscales.transform = gpflow.transforms.Logistic(
|
||||||
*self._LENGTHSCALE_BOUNDS)
|
*self._LENGTHSCALE_BOUNDS)
|
||||||
k = k0 + k1
|
|
||||||
return k
|
return k
|
||||||
|
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue