8 |
|
|
9 |
|
#ifndef MITPHYSICS_UTILS_MVAMet_H |
10 |
|
#define MITPHYSICS_UTILS_MVAMet_H |
11 |
< |
|
11 |
> |
#include <TMatrixD.h> |
12 |
|
#include "MitAna/DataTree/interface/PFJetFwd.h" |
13 |
|
#include "MitAna/DataTree/interface/VertexFwd.h" |
14 |
|
#include "MitAna/DataTree/interface/TrackFwd.h" |
22 |
|
#include "MitCommon/MathTools/interface/MathUtils.h" |
23 |
|
|
24 |
|
#include "MitPhysics/Utils/interface/RecoilTools.h" |
25 |
< |
#include "MitPhysics/Utils/interface/GBRForest.h" |
25 |
> |
#include "CondFormats/EgammaObjects/interface/GBRForest.h" |
26 |
|
|
27 |
|
class TRandom3; |
28 |
+ |
class GBRForest; |
29 |
|
|
30 |
|
namespace mithep { |
31 |
|
class MVAMet { |
49 |
|
TString iJetCutFile ="$CMSSW_BASE/src/MitPhysics/data/mva_RecoilPhiRegress_baseline.weights.xml", |
50 |
|
TString iU1Weights ="$CMSSW_BASE/src/MitPhysics/data/gbrmet.root", |
51 |
|
TString iPhiWeights ="$CMSSW_BASE/src/MitPhysics/data/gbrmetphi.root", |
52 |
+ |
TString iCovU1Weights ="$CMSSW_BASE/src/MitPhysics/data/gbrcovu1_52.root", |
53 |
+ |
TString iCovU2Weights ="$CMSSW_BASE/src/MitPhysics/data/gbrcovu2_52.root", |
54 |
|
MVAMet::MVAType iType=kBaseline); |
55 |
|
|
56 |
|
Bool_t IsInitialized() const { return fIsInitialized; } |
57 |
|
Double_t evaluatePhi(); |
58 |
|
Double_t evaluateU1(); |
59 |
+ |
Double_t evaluateCovU1(); |
60 |
+ |
Double_t evaluateCovU2(); |
61 |
|
Double_t MVAValue( bool iPhi, |
62 |
|
Float_t iPFSumEt, |
63 |
|
Float_t iU , |
97 |
|
Met GetMet( Bool_t iPhi,Float_t iPtVis,Float_t iPhiVis,Float_t iSumEtVis, |
98 |
|
const PFMet *iMet , |
99 |
|
const PFCandidateCol *iCands, |
100 |
< |
const Vertex *iVertex,const VertexCol *iVertices, |
100 |
> |
const Vertex *iVertex,const VertexCol *iVertices,Double_t iRho, |
101 |
|
const PFJetCol *iJets , |
102 |
|
int iNPV, |
103 |
|
Bool_t printDebug=false); |
112 |
|
FactorizedJetCorrector *iJetCorrector, |
113 |
|
const PileupEnergyDensityCol *iPUEnergyDensity, |
114 |
|
int iNPV, |
115 |
< |
Bool_t printDebug); |
115 |
> |
Bool_t printDebug=false); |
116 |
|
|
117 |
|
Met GetMet( Bool_t iPhi, |
118 |
|
Float_t iPt1,Float_t iPhi1,Float_t iEta1, |
119 |
|
Float_t iPt2,Float_t iPhi2,Float_t iEta2, |
120 |
|
const PFMet *iMet , |
121 |
|
const PFCandidateCol *iCands, |
122 |
< |
const Vertex *iVertex,const VertexCol *iVertices, |
122 |
> |
const Vertex *iVertex,const VertexCol *iVertices,Double_t iRho, |
123 |
|
const PFJetCol *iJets , |
124 |
|
int iNPV, |
125 |
< |
Bool_t printDebug); |
126 |
< |
|
125 |
> |
Bool_t printDebug=false); |
126 |
> |
|
127 |
> |
TMatrixD* GetMetCovariance() { return fCov; } |
128 |
> |
Float_t GetSignificance () { return fSignificance;} |
129 |
> |
Float_t GetUncertainty () { return fUncertainty;} |
130 |
|
RecoilTools *fRecoilTools; |
131 |
|
|
132 |
|
protected: |
133 |
|
TString fPhiMethodName; |
134 |
|
TString fU1MethodName; |
135 |
+ |
TString fCovU1MethodName; |
136 |
+ |
TString fCovU2MethodName; |
137 |
|
Bool_t fIsInitialized; |
138 |
|
MVAType fType; |
139 |
|
|
140 |
+ |
Float_t fSumEt ; |
141 |
|
Float_t fU ; |
142 |
|
Float_t fUPhi ; |
143 |
|
Float_t fTKSumEt; |
162 |
|
Float_t fNAllJet; |
163 |
|
Float_t fNPV ; |
164 |
|
Float_t fUPhiMVA; |
165 |
+ |
Float_t fUMVA; |
166 |
|
|
167 |
|
Float_t* fPhiVals; |
168 |
|
Float_t* fU1Vals; |
169 |
< |
|
169 |
> |
Float_t* fCovVals; |
170 |
|
|
171 |
|
GBRForest *fPhiReader; |
172 |
|
GBRForest *fU1Reader; |
173 |
+ |
GBRForest *fCovU1Reader; |
174 |
+ |
GBRForest *fCovU2Reader; |
175 |
+ |
|
176 |
+ |
Float_t fSignificance; |
177 |
+ |
Float_t fUncertainty; |
178 |
+ |
TMatrixD *fCov; |
179 |
+ |
|
180 |
|
//TMVA::Reader* fPhiReader; |
181 |
|
//TMVA::Reader* fU1Reader; |
182 |
|
ClassDef(MVAMet,0) |