mirror of
https://github.com/SheffieldML/GPy.git
synced 2026-06-29 15:59:41 +02:00
Merge branch 'master' of github.com:SheffieldML/GPy
This commit is contained in:
commit
129bb3924e
1 changed files with 3 additions and 3 deletions
|
|
@ -120,7 +120,7 @@ def sparse_toy_linear_1d_classification(seed=default_seed):
|
||||||
Y[Y == -1] = 0
|
Y[Y == -1] = 0
|
||||||
|
|
||||||
# Kernel object
|
# Kernel object
|
||||||
kernel = GPy.kern.rbf(1)
|
kernel = GPy.kern.rbf(1) + GPy.kern.white(1)
|
||||||
|
|
||||||
# Likelihood object
|
# Likelihood object
|
||||||
distribution = GPy.likelihoods.likelihood_functions.probit()
|
distribution = GPy.likelihoods.likelihood_functions.probit()
|
||||||
|
|
@ -129,8 +129,8 @@ def sparse_toy_linear_1d_classification(seed=default_seed):
|
||||||
Z = np.random.uniform(data['X'].min(),data['X'].max(),(10,1))
|
Z = np.random.uniform(data['X'].min(),data['X'].max(),(10,1))
|
||||||
|
|
||||||
# Model definition
|
# Model definition
|
||||||
m = GPy.models.sparse_GP(data['X'],likelihood=likelihood,kernel=kernel,Z=Z,normalize_X=True)
|
m = GPy.models.sparse_GP(data['X'],likelihood=likelihood,kernel=kernel,Z=Z,normalize_X=False)
|
||||||
m.set('len',.5)
|
m.set('len',2.)
|
||||||
|
|
||||||
m.ensure_default_constraints()
|
m.ensure_default_constraints()
|
||||||
# Optimize
|
# Optimize
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue