ATLAS Offline Software
Toggle main menu visibility
Loading...
Searching...
No Matches
MuonSpectrometer
MuonValidation
MuonDQA
MuonTrackMonitoring
src
RecoVertexPlots.cxx
Go to the documentation of this file.
1
/*
2
Copyright (C) 2002-2024 CERN for the benefit of the ATLAS collaboration
3
*/
4
5
#include "
MuonTrackMonitoring/RecoVertexPlots.h
"
6
#include "
AthContainers/ConstAccessor.h
"
7
8
9
RecoVertexPlots::RecoVertexPlots
(
PlotBase
*pParent,
const
std::string& sDir):
PlotBase
(pParent, sDir),
10
m_nMDT
(nullptr),
11
m_nRPC
(nullptr),
12
m_nTGC
(nullptr),
13
m_nTracklets
(nullptr),
14
m_VertexEtaPhi
(nullptr)
15
{}
16
17
void
RecoVertexPlots::initializePlots
(){
18
19
m_nMDT
=
Book1D
(
"m_MSVx_nMDT"
,
"m MSVx nMDT: M MSVx MDT Hits;;N_{MDT}"
, 100, 0.0, 3000.);
20
m_nRPC
=
Book1D
(
"m_MSVx_nRPC"
,
"m MSVx nRPC: M MSVx RPC Hits;;N_{RPC}"
, 100, 0.0, 1000.);
21
m_nTGC
=
Book1D
(
"m_MSVx_nTGC"
,
"m MSVx nTGC: M MSVx TGC Hits;;N_{TGC}"
, 100, 0.0, 1000.);
22
23
m_nTracklets
=
Book1D
(
"m_MSVx_nTracklets"
,
"MSVx nTracklets: M MSVx Number of Tracklets; N_{trackletS}"
, 20, 0.0, 20.);
24
m_VertexEtaPhi
=
Book2D
(
"m_VertexEtaPhi"
,
"Vertex Eta Phi: M MSVx #eta vs. #phi; #eta; #phi"
, 25, -2.5, 25, 32, -3.2, 3.2);
25
26
}
27
28
void
RecoVertexPlots::fill
(
const
xAOD::Vertex
& msVx){
29
TVector3 tmp_vx; tmp_vx.SetXYZ(msVx.
x
(),msVx.
y
(),msVx.
z
());
30
static
const
SG::ConstAccessor< int >
nMDTAcc(
"nMDT"
);
31
static
const
SG::ConstAccessor< int >
nRPCAcc(
"nRPC"
);
32
static
const
SG::ConstAccessor< int >
nTGCAcc(
"nTGC"
);
33
m_nMDT
->Fill(nMDTAcc(msVx));
34
m_nRPC
->Fill(nRPCAcc(msVx));
35
m_nTGC
->Fill(nTGCAcc(msVx));
36
m_nTracklets
->Fill(msVx.
numberDoF
()+1.);
37
m_VertexEtaPhi
->Fill(tmp_vx.Eta(),tmp_vx.Phi());
38
}
ConstAccessor.h
Helper class to provide constant type-safe access to aux data.
RecoVertexPlots.h
PlotBase::Book1D
TH1D * Book1D(std::string_view name, std::string_view labels, int nBins, float start, float end, bool prependDir=true)
Book a TH1D histogram.
Definition
PlotBase.cxx:94
PlotBase::PlotBase
PlotBase(PlotBase *parent, std::string_view sDir)
Definition
PlotBase.cxx:29
PlotBase::Book2D
TH2F * Book2D(std::string_view name, std::string_view labels, int nBinsX, float startX, float endX, int nBinsY, float startY, float endY, bool prependDir=true)
Book a TH2F histogram.
Definition
PlotBase.cxx:123
RecoVertexPlots::m_VertexEtaPhi
TH2 * m_VertexEtaPhi
Definition
RecoVertexPlots.h:22
RecoVertexPlots::m_nMDT
TH1 * m_nMDT
Definition
RecoVertexPlots.h:18
RecoVertexPlots::m_nRPC
TH1 * m_nRPC
Definition
RecoVertexPlots.h:19
RecoVertexPlots::fill
void fill(const xAOD::Vertex &msVx)
Definition
RecoVertexPlots.cxx:28
RecoVertexPlots::initializePlots
void initializePlots()
Definition
RecoVertexPlots.cxx:17
RecoVertexPlots::m_nTGC
TH1 * m_nTGC
Definition
RecoVertexPlots.h:20
RecoVertexPlots::m_nTracklets
TH1 * m_nTracklets
Definition
RecoVertexPlots.h:21
RecoVertexPlots::RecoVertexPlots
RecoVertexPlots(PlotBase *pParent, const std::string &sDir)
Definition
RecoVertexPlots.cxx:9
SG::ConstAccessor< int >
xAOD::Vertex_v1::z
float z() const
Returns the z position.
xAOD::Vertex_v1::y
float y() const
Returns the y position.
xAOD::Vertex_v1::numberDoF
float numberDoF() const
Returns the number of degrees of freedom of the vertex fit as float.
xAOD::Vertex_v1::x
float x() const
Returns the x position.
xAOD::Vertex
Vertex_v1 Vertex
Define the latest version of the vertex class.
Definition
Event/xAOD/xAODTracking/xAODTracking/Vertex.h:16
Generated on
for ATLAS Offline Software by
1.17.0