English Français

Documentation / Manuel développeur

Modules disponibles

Calibration,  DataServer,  Launcher,  MetaModelOptim,  Modeler,  Optimizer,  ReLauncher,  Reliability,  ReOptimizer,  Sampler,  Sensitivity,  UncertModeler,  XmlProblem,   Uranie / Modeler: TGPCostFunction.h Source File
Uranie / Modeler v4.9.0
/* @license-end */
TGPCostFunction.h
Go to the documentation of this file.
1
2// Copyright (C) 2013-2024 CEA/DES
3//
4// This program is free software: you can redistribute it and/or modify
5// it under the terms of the GNU Lesser General Public License as published
6// by the Free Software Foundation, either version 3 of the License, or any
7// later version.
8//
9// This program is distributed in the hope that it will be useful,
10// but WITHOUT ANY WARRANTY; without even the implied warranty of
11// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
12// GNU Lesser General Public License for more details.
13//
14// You should have received a copy of the GNU Lesser General Public License
15// along with this program. If not, see <http://www.gnu.org/licenses/>.
18// $Id$
19// $Author$
20// $Date$
21// $Revision$
22// $State$
24
44#ifndef TGPCOSTFUNCTION_H
45#define TGPCOSTFUNCTION_H
46
48#include "Modeler.h"
49#include "TGPBuilder.h"
50#include "TShareEval.h"
51
52namespace URANIE
53{
54namespace Modeler
55{
56//class TGPBuilder;
57class TGPCostFunction: public URANIE::Relauncher::TSimpleEval
58{
59
60 // Attributes
61protected:
62 Double_t* _H;
63 Double_t* _K;
64 Double_t* _C;
65 Double_t* _yObs;
66 Int_t _n;
67 Int_t _p;
68
69public:
70 Bool_t _blog;
72
73 // Operations
74public:
75 //---------------------------------------------
79
86
90
91 //---------------------------------------------
95
97 {
98 return gpBuilder;
99 }
100
103 {
104 return _K;
105 }
106
109 {
110 return _C;
111 }
112
115 {
116 return _yObs;
117 }
118
120 Int_t getNObs()
121 {
122 return _n;
123 }
124
126 {
127 gpBuilder = gpb;
128 }
130
131 //---------------------------------------------
135
136 virtual Int_t eval(Double_t* theta, Double_t* res, int=0) = 0;
138
139 //---------------------------------------------
143 void setLog()
144 {
145 _blog = kTRUE;
146 }
147 void unsetLog()
148 {
149 _blog = kFALSE;
150 }
152 {
153 _blog = !_blog;
154 }
155 Bool_t getLog()
156 {
157 return _blog;
158 }
159 virtual void printLog(Option_t *option = "");
161
162 ClassDef(URANIE::Modeler::TGPCostFunction, ID_MODELER)
163 //Classe de
164
165protected:
166 void duplicateGPB();
167};
168
169} // Fin du namespace Modeler
170} // Fin du namespace URANIE
171#endif
Interface de la classe URANIE::Modeler::TGPBuilder.
Description of the class TGPBuilder.
Definition TGPBuilder.h:87
Description of the class TGPCostFunction.
Definition TGPCostFunction.h:58
Bool_t getLog()
Definition TGPCostFunction.h:155
Double_t * _H
pointer to the deterministic trend matrix (size: _n * _p)
Definition TGPCostFunction.h:62
Double_t * getObservationVector()
Return a pointer to the observations outputs.
Definition TGPCostFunction.h:114
Int_t _p
number of deterministic trend coefficients
Definition TGPCostFunction.h:67
void changeLog()
Definition TGPCostFunction.h:151
Double_t * _K
pointer to the covariance matrix (size: _n * _n)
Definition TGPCostFunction.h:63
void setBuilder(TGPBuilder *gpb)
Definition TGPCostFunction.h:125
Bool_t _blog
Boolean to decide if the log information is shown or not.
Definition TGPCostFunction.h:70
void unsetLog()
Definition TGPCostFunction.h:147
TGPBuilder * gpBuilder
pointer to a gaussian process builder object.
Definition TGPCostFunction.h:71
Double_t * getCorrelationMatrix()
Return a pointer to the GP Builder correlation matrix.
Definition TGPCostFunction.h:108
TGPBuilder * getBuilder()
Return a pointer to the GP Builder.
Definition TGPCostFunction.h:96
Int_t getNObs()
Return the number of observations.
Definition TGPCostFunction.h:120
Int_t _n
number of observations
Definition TGPCostFunction.h:66
Double_t * getCovarianceMatrix()
Return a pointer to the GP Builder covariance matrix.
Definition TGPCostFunction.h:102
void setLog()
Definition TGPCostFunction.h:143
Double_t * _yObs
pointer to the vector of observations outputs (size: _n)
Definition TGPCostFunction.h:65
virtual Int_t eval(Double_t *theta, Double_t *res, int=0)=0
Evaluate the cost function (implemented in the children classes)
virtual void printLog(Option_t *option="")
TGPCostFunction(TGPBuilder *gpb)
Standard constructor.
Double_t * _C
pointer to the correlation matrix (size: _n * _n)
Definition TGPCostFunction.h:64
virtual ~TGPCostFunction()
Default destructor.
ROOT.
Definition TAnisp.h:164