Back to home page

Project CMSSW displayed by LXR

 
 

    


File indexing completed on 2021-02-14 14:31:13

0001 #ifndef TtSemiLepSignalSelEval_h
0002 #define TtSemiLepSignalSelEval_h
0003 
0004 #include "Math/VectorUtil.h"
0005 #include "TMath.h"
0006 
0007 #include "PhysicsTools/MVAComputer/interface/MVAComputerCache.h"
0008 #include "PhysicsTools/MVAComputer/interface/MVAComputer.h"
0009 
0010 #include "DataFormats/PatCandidates/interface/Jet.h"
0011 #include "TopQuarkAnalysis/TopEventSelection/interface/TtSemiLepSignalSel.h"
0012 
0013 inline double evaluateTtSemiLepSignalSel(PhysicsTools::MVAComputerCache& mvaComputer,
0014                                          const TtSemiLepSignalSel& sigsel,
0015                                          float weight = 1.,
0016                                          const bool isSignal = false) {
0017   std::vector<PhysicsTools::Variable::Value> values;
0018 
0019   values.push_back(PhysicsTools::Variable::Value("sumEt", sigsel.sumEt()));
0020   values.push_back(PhysicsTools::Variable::Value("relEt1", sigsel.Et1()));
0021   values.push_back(PhysicsTools::Variable::Value("Abs_lepeta", sigsel.lepeta()));
0022   values.push_back(PhysicsTools::Variable::Value("MET", sigsel.MET()));
0023 
0024   values.push_back(PhysicsTools::Variable::Value("dphiMETlepton", sigsel.dphiMETlepton()));
0025 
0026   values.push_back(PhysicsTools::Variable::Value("detajet2jet3", sigsel.detajet2jet3()));
0027   values.push_back(PhysicsTools::Variable::Value("detajet3jet4", sigsel.detajet3jet4()));
0028 
0029   values.push_back(PhysicsTools::Variable::Value("mindijetmass", sigsel.mindijetmass()));
0030   values.push_back(PhysicsTools::Variable::Value("maxdijetmass", sigsel.maxdijetmass()));
0031 
0032   values.push_back(PhysicsTools::Variable::Value("mindRjetlepton", sigsel.mindRjetlepton()));
0033 
0034   return mvaComputer->eval(values);
0035 }
0036 
0037 #endif