ATLAS Offline Software
ElectronValidationPlots.cxx
Go to the documentation of this file.
1 /*
2  Copyright (C) 2002-2022 CERN for the benefit of the ATLAS collaboration
3 */
4 
7 
9  m_oCentralElecPlots(this,"Central/", "Central"),
10  m_oFrwdElecPlots(this, "Frwd/", "Forward"),
11  m_oTruthAllPlots(this, "Truth/All/", "Truth Electron All"),
12  m_oTruthAllIsoPlots(this, "Truth/All/Iso/", "Truth Electron Prompt"),
13  m_oTruthIsoPlots(this, "Truth/Iso/", "Truth Electron Prompt"),
14  m_oTruthAllPromptPlots(this, "Truth/All/Prompt/", "Truth Electron Prompt"),
15  m_oTruthPromptElecPlots(this, "Truth/Prompt_elec/", "Truth Electron Prompt from EgammaTruthContainer"),
16  author(nullptr),
17  res_et(nullptr),
18  res_eta(nullptr),
19  res_et_cut(nullptr),
20  res_eta_cut(nullptr),
21  res_et_cut_pt_20(nullptr),
22  res_eta_cut_pt_20(nullptr),
23  //pt_ratio(nullptr),
24  matrix(nullptr)
25 
26 {}
27 
29 
30  author = Book1D("author", "Electron Author ; author;Events", 20, -0.5, 19.5);
31  res_et = BookTProfile("res_et"," IsoElectron;E_{T}^{Truth}, [GeV];(E_{T} - E_{T}^{Truth})/E_{T}^{Truth}",100, 0., 200.);
32  res_eta = BookTProfile("res_eta"," IsoElectron;#eta;(E_{T} - E_{T}^{Truth})/E_{T}^{Truth}",50, -2.5, 2.5);
33  res_et_cut = BookTProfile("res_et_cut"," IsoElectron;E_{T}^{Truth}, [GeV];(E_{T} - E_{T}^{Truth})/E_{T}^{Truth}",100, 0., 200.);
34  res_eta_cut = BookTProfile("res_eta_cut"," IsoElectron;#eta;(E_{T} - E_{T}^{Truth})/E_{T}^{Truth}",50, -2.5, 2.5);
35  res_et_cut_pt_20 = BookTProfile("res_et_cut_pt_20"," Prompt Electron;E_{T}^{Truth}, [GeV];(E_{T} - E_{T}^{Truth})/E_{T}^{Truth}",100, 0., 200.);
36  res_eta_cut_pt_20 = BookTProfile("res_eta_cut_pt_20"," Prompt Electron;#eta;(E_{T} - E_{T}^{Truth})/E_{T}^{Truth}",50, -2.5, 2.5);
37  matrix = Book2D("matrix","reco vs truth pt",200,0.,200.,200,0.,200.);
38 
39 }
40 
42 
43  float weight = 1.;
44  weight = eventInfo.beamSpotWeight();
45 
46  author->Fill(electron.author(),weight);
47 
51  }
54  }
55 }
ElectronValidationPlots.h
Egamma::ElectronPlots::fill
void fill(const xAOD::Electron &electron, const xAOD::EventInfo &eventInfo, bool isPrompt)
Definition: ElectronPlots.cxx:67
ElectronValidationPlots::res_eta_cut
TProfile * res_eta_cut
Definition: ElectronValidationPlots.h:38
PlotBase
Definition: PlotBase.h:34
python.copyTCTOutput.sDir
sDir
Definition: copyTCTOutput.py:60
ElectronValidationPlots::matrix
TH2 * matrix
Definition: ElectronValidationPlots.h:41
PlotBase::Book2D
TH2F * Book2D(const std::string &name, const std::string &labels, int nBinsX, float startX, float endX, int nBinsY, float startY, float endY, bool prependDir=true)
Book a TH2F histogram.
Definition: PlotBase.cxx:123
xAOD::EgammaParameters::AuthorFwdElectron
const uint16_t AuthorFwdElectron
Electron reconstructed by the Forward cluster-based algorithm.
Definition: EgammaDefs.h:30
ElectronValidationPlots::initializePlots
virtual void initializePlots()
Definition: ElectronValidationPlots.cxx:28
dqt_zlumi_pandas.weight
int weight
Definition: dqt_zlumi_pandas.py:189
PlotBase::Book1D
TH1D * Book1D(const std::string &name, const std::string &labels, int nBins, float start, float end, bool prependDir=true)
Book a TH1D histogram.
Definition: PlotBase.cxx:94
ElectronValidationPlots::res_et_cut_pt_20
TProfile * res_et_cut_pt_20
Definition: ElectronValidationPlots.h:39
ElectronValidationPlots::ElectronValidationPlots
ElectronValidationPlots(PlotBase *pParent, const std::string &sDir)
Definition: ElectronValidationPlots.cxx:8
xAOD::EgammaParameters::AuthorAmbiguous
const uint16_t AuthorAmbiguous
Object Reconstructed by standard cluster-based algorithm.
Definition: EgammaDefs.h:32
ElectronValidationPlots::fill
void fill(const xAOD::Electron &electron, const xAOD::EventInfo &eventInfo, bool isPrompt)
Definition: ElectronValidationPlots.cxx:41
ElectronValidationPlots::res_et_cut
TProfile * res_et_cut
Definition: ElectronValidationPlots.h:37
ElectronValidationPlots::res_et
TProfile * res_et
Definition: ElectronValidationPlots.h:35
Egamma::ElectronFrwdPlots::fill
void fill(const xAOD::Electron &electron, const xAOD::EventInfo &eventInfo, bool isPrompt)
Definition: ElectronFrwdPlots.cxx:28
xAOD::Electron_v1
Definition: Electron_v1.h:34
xAOD::EventInfo_v1
Class describing the basic event information.
Definition: EventInfo_v1.h:43
python.testIfMatch.matrix
matrix
Definition: testIfMatch.py:66
MCTruthPartClassifier::isPrompt
int isPrompt(const unsigned int classify, bool allow_prompt_tau_decays=true)
Definition: TruthClassifiers.h:180
ElectronValidationPlots::m_oFrwdElecPlots
Egamma::ElectronFrwdPlots m_oFrwdElecPlots
Definition: ElectronValidationPlots.h:27
ElectronValidationPlots::res_eta_cut_pt_20
TProfile * res_eta_cut_pt_20
Definition: ElectronValidationPlots.h:40
CaloCondBlobAlgs_fillNoiseFromASCII.author
string author
Definition: CaloCondBlobAlgs_fillNoiseFromASCII.py:26
EgammaDefs.h
xAOD::EgammaParameters::electron
@ electron
Definition: EgammaEnums.h:18
PlotBase::BookTProfile
TProfile * BookTProfile(const std::string &name, const std::string &labels, int nBinsX, float startX, float endX, float startY=-1, float endY=-1, bool prependDir=true, bool useRMS=false)
Book a TProfile histogram.
Definition: PlotBase.cxx:186
ElectronValidationPlots::m_oCentralElecPlots
Egamma::ElectronPlots m_oCentralElecPlots
Definition: ElectronValidationPlots.h:26
ElectronValidationPlots::author
TH1 * author
Definition: ElectronValidationPlots.h:34
xAOD::EventInfo_v1::beamSpotWeight
float beamSpotWeight() const
Weight for beam spot size reweighting.
Definition: EventInfo_v1.cxx:970
xAOD::EgammaParameters::AuthorElectron
const uint16_t AuthorElectron
Object Reconstructed by standard cluster-based algorithm.
Definition: EgammaDefs.h:24
ElectronValidationPlots::res_eta
TProfile * res_eta
Definition: ElectronValidationPlots.h:36