mirror of
https://github.com/SheffieldML/GPy.git
synced 2026-05-01 15:52:39 +02:00
Merge branch 'master' of github.com:SheffieldML/GPy
This commit is contained in:
commit
9c6d4e9241
1 changed files with 25 additions and 0 deletions
25
GPy/examples/unsupervised.py
Normal file
25
GPy/examples/unsupervised.py
Normal file
|
|
@ -0,0 +1,25 @@
|
||||||
|
"""
|
||||||
|
Usupervised learning with Gaussian Processes.
|
||||||
|
"""
|
||||||
|
import pylab as pb
|
||||||
|
import numpy as np
|
||||||
|
import GPy
|
||||||
|
|
||||||
|
|
||||||
|
######################################
|
||||||
|
## Oil data subsampled to 100 points.
|
||||||
|
def oil_100():
|
||||||
|
data = GPy.util.datasets.oil_100()
|
||||||
|
|
||||||
|
# create simple GP model
|
||||||
|
m = GPy.models.GPLVM(data['X'], 2)
|
||||||
|
|
||||||
|
|
||||||
|
# optimize
|
||||||
|
m.ensure_default_constraints()
|
||||||
|
m.optimize()
|
||||||
|
|
||||||
|
# plot
|
||||||
|
print(m)
|
||||||
|
return m
|
||||||
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue