How to use Gaussian Process Regression with multidimension input with meanfunc?

조회 수: 14 (최근 30일)
zhan sui
zhan sui 2015년 10월 22일
답변: LUIS PEJENDINO 2021년 8월 5일
I have downloaded the Gaussian Processes for Machine Learning (GPML) package (gpml-matlab-v3.6-2015-07-07) from the website. The demo_regression for one dimension works just fine in the matlab.
Now I have my own data for regression where the xtrain (training data) is a 20*5 matrix (20 samples, 5 input vars), and the ytrain ( training target) is 20x1, test data xtest is (1x5), The problem is that I do not understand how to calculate the meanFunction, the code provided for the regression example does not work for multiple input datasets.
This is the error which appeared to me when I run the code:
..................................................................
Error using gp (line 90)
Number of mean function hyperparameters disagree with mean function
Error in minimize (line 75)
[f0 df0] = feval(f, X, varargin{:}); % get function value and gradient
Error in GPMLexample1 (line 108)
Ncg =50;hyp = minimize(hyp0,'gp', -Ncg, inf, mean, cov, lik,TrainingSetX_x, TrainingSetY_x); % opt hypers
...................................................................
Are there anybody who has tried this, and maybe can show an example?
  댓글 수: 2
Karim kim
Karim kim 2017년 6월 18일
I've the same problem, please let me know if you figure out how to fix it.
Best regads
Karim
somi
somi 2018년 2월 6일
you should use The ARD SE covariance function for multi-dimensional inputs.

댓글을 달려면 로그인하십시오.

답변 (2개)

Don Mathis
Don Mathis 2018년 2월 7일
I suggest using the FITRGP function in the Statistics & Machine Learning Toolbox instead of GPML

LUIS PEJENDINO
LUIS PEJENDINO 2021년 8월 5일
what is meanfunc used for?

카테고리

Help CenterFile Exchange에서 Gaussian Process Regression에 대해 자세히 알아보기

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by