Changing optimization technique for Gaussian process regression model

25 ビュー (過去 30 日間)
Josh
Josh 2022 年 7 月 6 日
コメント済み: Josh 2022 年 7 月 14 日
By default, GPR model uses 'bayesopt' optimizer to optimize the hyperparameters. I wish to use 'particle swarm optimization'
to optimize the hyperparamaters i.e. to minimize the loss function or the MSE. Please help.
clear;clc;close all
load('data001.mat')
x = data001(:,1);
y = data001(:,2);
rng default
gprMdl = fitrgp(x,y,'KernelFunction','squaredexponential',...
'OptimizeHyperparameters','auto','HyperparameterOptimizationOptions',...
struct('AcquisitionFunctionName','expected-improvement-plus'));
ypred = resubPredict(gprMdl);
figure();
plot(x,y,'r.');
hold on
plot(x,ypred,'k','LineWidth',2);
xlabel('x');
ylabel('y');
hold off

採用された回答

Alan Weiss
Alan Weiss 2022 年 7 月 6 日
Alan Weiss
MATLAB mathematical toolbox documentation
  7 件のコメント
Josh
Josh 2022 年 7 月 14 日
Thanks for being generous with your patience to my questions and elaborating on it with some information.
Appreciate for responding. Thank you.

サインインしてコメントする。

その他の回答 (0 件)

製品

Community Treasure Hunt

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

Start Hunting!

Translated by