ATLAS Offline Software
Toggle main menu visibility
Loading...
Searching...
No Matches
Tracking
TrkVertexFitter
TrkVertexSeedFinderUtils
src
GaussianDensityTestAlg.h
Go to the documentation of this file.
1
2
3
/*
4
Copyright (C) 2002-2021 CERN for the benefit of the ATLAS collaboration
5
*/
6
7
// GaussianDensityTestAlg.h
8
// Header file for class GaussianDensityTestAlg
9
// Author: D.Casper<dcasper@uci.edu>
11
#ifndef TRKVERTEXSEEDFINDERUTILS_GAUSSIANDENSITYTESTALG_H
12
#define TRKVERTEXSEEDFINDERUTILS_GAUSSIANDENSITYTESTALG_H 1
13
14
// STL includes
15
#include <string>
16
#include <vector>
17
#include <map>
18
19
// FrameWork includes
20
#include "
AthenaBaseComps/AthAlgorithm.h
"
21
#include "GaudiKernel/ToolHandle.h"
22
#include "GaudiKernel/ServiceHandle.h"
23
#include "GaudiKernel/ITHistSvc.h"
24
25
#include "
TrkParticleBase/TrackParticleBaseCollection.h
"
26
#include "
TrkParameters/TrackParameters.h
"
27
#include "
xAODTracking/TrackParticleContainer.h
"
28
#include "
xAODTruth/TruthEventContainer.h
"
29
#include "
xAODTruth/TruthPileupEventContainer.h
"
30
31
#include "
TrkVertexFitterInterfaces/IVertexTrackDensityEstimator.h
"
32
#include "
InDetTrackSelectionTool/IInDetTrackSelectionTool.h
"
33
#include "
TrkVertexFitterInterfaces/ITrackToVertexIPEstimator.h
"
34
35
//Amg
36
#include "
GeoPrimitives/GeoPrimitives.h
"
37
#include "
BeamSpotConditionsData/BeamSpotData.h
"
38
#include "TH1F.h"
39
#include "TTree.h"
40
41
namespace
Trk
42
{
43
class
Track
;
44
class
ITrackLink
;
45
46
class
GaussianDensityTestAlg
47
:
public
::AthAlgorithm
48
{
49
51
// Public methods:
53
public
:
54
55
// Copy constructor:
56
58
GaussianDensityTestAlg
(
const
std::string& name, ISvcLocator* pSvcLocator );
59
61
virtual
~GaussianDensityTestAlg
();
62
63
// Assignment operator:
64
65
// Athena algorithm's Hooks
66
virtual
StatusCode
initialize
();
67
virtual
StatusCode
execute
(
const
EventContext& ctx);
68
virtual
StatusCode
finalize
();
69
70
private
:
72
// Const methods:
74
double
ipSignificance
(
const
Trk::TrackParameters
* params,
const
Amg::Vector3D
*
vertex
)
const
;
75
76
StatusCode
findTruth
(
double
mode,
77
const
std::vector<Trk::ITrackLink*>& trackVector,
78
std::vector<Amg::Vector3D>& truth,
79
TH1* h_truthDensity,
80
TH1* h_modeCheck)
const
;
81
83
// Non-const methods:
85
GaussianDensityTestAlg
();
86
87
void
selectTracks
(
const
xAOD::TrackParticleContainer
* trackParticles, std::vector<Trk::ITrackLink*> & trackVector);
88
89
static
void
analyzeTracks
(
const
std::vector<Trk::ITrackLink*> & trackVector, std::vector<const Trk::TrackParameters*>& perigeeList);
90
92
// Private data:
94
private
:
95
// Properties
96
Gaudi::Property<double>
m_significanceTruthCut
{
this
,
97
"SignificanceTruthCut"
,
98
3.0,
99
"Reco track must pass within this many sigma of pp vertex to be good"
};
100
101
Gaudi::Property<int>
m_truthVertexTracks
{
this
,
102
"MinTruthVertexTracks"
,
103
2,
104
"Minimum associated reconstructed tracks for vertex to be considered visible"
};
105
106
bool
m_useBeamConstraint
;
107
bool
m_firstEvent
;
108
109
// Tools
110
ToolHandle< InDet::IInDetTrackSelectionTool >
m_trackFilter
{
this
,
"TrackSelector"
,
111
"InDet::InDetTrackSelectionTool/InDetDetailedTrackSelectionTool"
,
112
"Track selection tool"
} ;
113
114
ToolHandle< Trk::IVertexTrackDensityEstimator >
m_estimator
{
this
,
"Estimator"
,
"Trk::GaussianTrackDensity"
,
115
"Track density function"
};
116
117
ToolHandle< Trk::ITrackToVertexIPEstimator >
m_ipEstimator
{
this
,
"IPEstimator"
,
"Trk::TrackToVertexIPEstimator"
,
118
"Impact point estimator"
};
119
120
// Non-property private data
121
122
SG::ReadCondHandleKey<InDet::BeamSpotData>
m_beamSpotKey
{
this
,
"BeamSpotKey"
,
"BeamSpotData"
,
"SG key for beam spot"
};
123
ServiceHandle< ITHistSvc >
m_iTHistSvc
;
124
126
SG::ReadHandleKey<xAOD::TrackParticleContainer>
m_trackParticlesKey
{
this
,
"TrackParticles"
,
"InDetTrackParticles"
,
127
"Input track particle collection"
};
128
129
SG::ReadHandleKey<xAOD::TruthEventContainer>
m_truthEventsKey
{
this
,
"TruthEvents"
,
"TruthEvents"
,
130
"Key for truth event collection"
};
131
132
SG::ReadHandleKey<xAOD::TruthPileupEventContainer>
m_pileupEventsKey
{
this
,
"TruthPileupEvents"
,
"TruthPileupEvents"
,
133
"Key for truth pileup event collection"
};
134
136
137
TH1*
m_h_density
{};
138
TH1*
m_h_truthDensity
{};
139
TH1*
m_h_truthVertices
{};
140
TH1*
m_h_modeCheck
{};
141
142
};
// class
143
}
// namespace
144
145
#endif
//> !TRKVERTEXSEEDFINDERUTILS_IMAGINGSEEDTUNINGALG_H
AthAlgorithm.h
BeamSpotData.h
TrackParticleContainer.h
GeoPrimitives.h
IInDetTrackSelectionTool.h
ITrackToVertexIPEstimator.h
IVertexTrackDensityEstimator.h
TrackParticleBaseCollection.h
TrackParameters.h
TruthEventContainer.h
TruthPileupEventContainer.h
AthAlgorithm::AthAlgorithm
AthAlgorithm(const std::string &name, ISvcLocator *pSvcLocator)
Constructor.
Definition
AthAlgorithm.cxx:10
SG::ReadCondHandleKey
Definition
ReadCondHandleKey.h:21
SG::ReadHandleKey
Property holding a SG store/key/clid from which a ReadHandle is made.
Definition
StoreGate/StoreGate/ReadHandleKey.h:40
ServiceHandle< ITHistSvc >
Trk::GaussianDensityTestAlg::finalize
virtual StatusCode finalize()
Definition
GaussianDensityTestAlg.cxx:76
Trk::GaussianDensityTestAlg::m_h_density
TH1 * m_h_density
Histograms and trees.
Definition
GaussianDensityTestAlg.h:137
Trk::GaussianDensityTestAlg::m_useBeamConstraint
bool m_useBeamConstraint
Definition
GaussianDensityTestAlg.h:106
Trk::GaussianDensityTestAlg::GaussianDensityTestAlg
GaussianDensityTestAlg()
Trk::GaussianDensityTestAlg::m_h_modeCheck
TH1 * m_h_modeCheck
Definition
GaussianDensityTestAlg.h:140
Trk::GaussianDensityTestAlg::m_trackParticlesKey
SG::ReadHandleKey< xAOD::TrackParticleContainer > m_trackParticlesKey
Data handle keys.
Definition
GaussianDensityTestAlg.h:126
Trk::GaussianDensityTestAlg::m_estimator
ToolHandle< Trk::IVertexTrackDensityEstimator > m_estimator
Definition
GaussianDensityTestAlg.h:114
Trk::GaussianDensityTestAlg::~GaussianDensityTestAlg
virtual ~GaussianDensityTestAlg()
Destructor:
Trk::GaussianDensityTestAlg::findTruth
StatusCode findTruth(double mode, const std::vector< Trk::ITrackLink * > &trackVector, std::vector< Amg::Vector3D > &truth, TH1 *h_truthDensity, TH1 *h_modeCheck) const
Definition
GaussianDensityTestAlg.cxx:175
Trk::GaussianDensityTestAlg::m_trackFilter
ToolHandle< InDet::IInDetTrackSelectionTool > m_trackFilter
Definition
GaussianDensityTestAlg.h:110
Trk::GaussianDensityTestAlg::GaussianDensityTestAlg
GaussianDensityTestAlg(const std::string &name, ISvcLocator *pSvcLocator)
Constructor with parameters:
Definition
GaussianDensityTestAlg.cxx:31
Trk::GaussianDensityTestAlg::m_firstEvent
bool m_firstEvent
Definition
GaussianDensityTestAlg.h:107
Trk::GaussianDensityTestAlg::m_pileupEventsKey
SG::ReadHandleKey< xAOD::TruthPileupEventContainer > m_pileupEventsKey
Definition
GaussianDensityTestAlg.h:132
Trk::GaussianDensityTestAlg::m_h_truthDensity
TH1 * m_h_truthDensity
Definition
GaussianDensityTestAlg.h:138
Trk::GaussianDensityTestAlg::m_beamSpotKey
SG::ReadCondHandleKey< InDet::BeamSpotData > m_beamSpotKey
Definition
GaussianDensityTestAlg.h:122
Trk::GaussianDensityTestAlg::m_ipEstimator
ToolHandle< Trk::ITrackToVertexIPEstimator > m_ipEstimator
Definition
GaussianDensityTestAlg.h:117
Trk::GaussianDensityTestAlg::m_truthVertexTracks
Gaudi::Property< int > m_truthVertexTracks
Definition
GaussianDensityTestAlg.h:101
Trk::GaussianDensityTestAlg::m_h_truthVertices
TH1 * m_h_truthVertices
Definition
GaussianDensityTestAlg.h:139
Trk::GaussianDensityTestAlg::selectTracks
void selectTracks(const xAOD::TrackParticleContainer *trackParticles, std::vector< Trk::ITrackLink * > &trackVector)
Definition
GaussianDensityTestAlg.cxx:133
Trk::GaussianDensityTestAlg::execute
virtual StatusCode execute(const EventContext &ctx)
Execute method.
Definition
GaussianDensityTestAlg.cxx:82
Trk::GaussianDensityTestAlg::m_truthEventsKey
SG::ReadHandleKey< xAOD::TruthEventContainer > m_truthEventsKey
Definition
GaussianDensityTestAlg.h:129
Trk::GaussianDensityTestAlg::initialize
virtual StatusCode initialize()
Definition
GaussianDensityTestAlg.cxx:50
Trk::GaussianDensityTestAlg::analyzeTracks
static void analyzeTracks(const std::vector< Trk::ITrackLink * > &trackVector, std::vector< const Trk::TrackParameters * > &perigeeList)
Definition
GaussianDensityTestAlg.cxx:124
Trk::GaussianDensityTestAlg::m_iTHistSvc
ServiceHandle< ITHistSvc > m_iTHistSvc
Definition
GaussianDensityTestAlg.h:123
Trk::GaussianDensityTestAlg::m_significanceTruthCut
Gaudi::Property< double > m_significanceTruthCut
Definition
GaussianDensityTestAlg.h:96
Trk::GaussianDensityTestAlg::ipSignificance
double ipSignificance(const Trk::TrackParameters *params, const Amg::Vector3D *vertex) const
Definition
GaussianDensityTestAlg.cxx:321
Trk::ITrackLink
An abstract class which is meant to represent an element link to the Trk::Track or Trk::TrackParticle...
Definition
ITrackLink.h:26
Trk::Track
The ATLAS Track class.
Definition
Tracking/TrkEvent/TrkTrack/TrkTrack/Track.h:73
Amg::Vector3D
Eigen::Matrix< double, 3, 1 > Vector3D
Definition
GeoPrimitives.h:47
Trk
Ensure that the ATLAS eigen extensions are properly loaded.
Definition
FakeTrackBuilder.h:9
Trk::vertex
@ vertex
Definition
MeasurementType.h:21
Trk::TrackParameters
ParametersBase< TrackParametersDim, Charged > TrackParameters
Definition
Tracking/TrkEvent/TrkParameters/TrkParameters/TrackParameters.h:27
xAOD::TrackParticleContainer
TrackParticleContainer_v1 TrackParticleContainer
Definition of the current "TrackParticle container version".
Definition
Event/xAOD/xAODTracking/xAODTracking/TrackParticleContainer.h:14
Generated on
for ATLAS Offline Software by
1.17.0