ATLAS Offline Software
Loading...
Searching...
No Matches
InDetIterativePriVxFinderTool.h
Go to the documentation of this file.
1/*
2 Copyright (C) 2002-2024 CERN for the benefit of the ATLAS collaboration
3*/
4
32
33// implemented using as template the InDetPriVxFinderTool class of A. Wildauer
34// and F. Akesson
35
36#ifndef INDETPRIVXFINDERTOOL_INDETITERATIVEPRIVXFINDERTOOL_H
37#define INDETPRIVXFINDERTOOL_INDETITERATIVEPRIVXFINDERTOOL_H
38
41#include "GaudiKernel/ToolHandle.h"
45#include "TrkTrack/TrackCollection.h" // type def ...
49
54
60
61namespace Trk {
62class Track;
63class ITrackLink;
64}
65
66namespace InDet {
67
69 : public AthAlgTool
70 , virtual public IVertexFinder
71{
72
73public:
77
78 InDetIterativePriVxFinderTool(const std::string& t,
79 const std::string& n,
80 const IInterface* p);
81
85
87
88 virtual StatusCode initialize() override;
89
93 virtual std::pair<xAOD::VertexContainer*, xAOD::VertexAuxContainer*>
94 findVertex(const EventContext& ctx,
95 const TrackCollection* trackTES) const override;
99 virtual std::pair<xAOD::VertexContainer*, xAOD::VertexAuxContainer*>
100 findVertex(const EventContext& ctx,
101 const xAOD::TrackParticleContainer* trackParticles) const override;
102
103 virtual StatusCode finalize() override;
104
105private:
106 std::pair<xAOD::VertexContainer*, xAOD::VertexAuxContainer*> findVertex(
107 const EventContext& ctx,
108 const std::vector<Trk::ITrackLink*>& trackVector) const;
109
111 xAOD::Vertex* myxAODVertex,
112 std::vector<const Trk::TrackParameters*>& perigeesToFit,
113 std::vector<Trk::ITrackLink*>& seedTracks) const;
114
115 void removeAllFrom(std::vector<const Trk::TrackParameters*>& perigeesToFit,
116 std::vector<Trk::ITrackLink*>& seedTracks) const;
117
118 double compatibility(const Trk::TrackParameters& measPerigee,
119 const xAOD::Vertex& vertex) const;
120
121 static void countTracksAndNdf(xAOD::Vertex* myxAODVertex,
122 double& ndf,
123 int& ntracks) ;
124
125 ToolHandle<Trk::IVertexFitter> m_iVertexFitter{ this,
126 "VertexFitterTool",
127 "Trk::AdaptiveVertexFitter" };
128 ToolHandle<InDet::IInDetTrackSelectionTool> m_trkFilter{
129 this,
130 "TrackSelector",
131 "InDet::InDetTrackSelection"
132 };
133
134 ToolHandle<Trk::IVertexSeedFinder> m_SeedFinder{ this,
135 "SeedFinder",
136 "Trk::ZScanSeedFinder" };
137 ToolHandle<Trk::IImpactPoint3dEstimator> m_ImpactPoint3dEstimator{
138 this,
139 "ImpactPoint3dEstimator",
140 "Trk::ImpactPoint3dEstimator"
141 };
142
143 ToolHandle<Trk::IVertexLinearizedTrackFactory> m_LinearizedTrackFactory{
144 this,
145 "LinearizedTrackFactory",
146 "Trk::FullLinearizedTrackFactory"
147 };
148
150 this,
151 "BeamSpotKey",
152 "BeamSpotData",
153 "SG key for beam spot"
154 };
155
156 BooleanProperty m_useBeamConstraint{this, "useBeamConstraint", false};
158 {this, "significanceCutSeeding", 10.};
160 {this, "maximumChi2cutForSeeding", 36.};
161 IntegerProperty m_maxVertices{this, "maxVertices", 25};
162
163 BooleanProperty m_createSplitVertices{this, "createSplitVertices", false};
165 {this, "splitVerticesTrkInvFraction", 2, "inverse fraction to split tracks (1:N)"};
166
168 {this, "reassignTracksAfterFirstFit", false};
169
170 BooleanProperty m_doMaxTracksCut{this, "doMaxTracksCut", false};
171 UnsignedIntegerProperty m_maxTracks{this, "MaxTracks", 5000};
172
177
178}; // end of class definitions
179} // end of namespace definitions
180#endif
181
DataVector< Trk::Track > TrackCollection
This typedef represents a collection of Trk::Track objects.
AthAlgTool(const std::string &type, const std::string &name, const IInterface *parent)
Constructor with parameters:
ToolHandle< InDet::IInDetTrackSelectionTool > m_trkFilter
void printParameterSettings()
Internal method to print the parameters setting.
void removeCompatibleTracks(xAOD::Vertex *myxAODVertex, std::vector< const Trk::TrackParameters * > &perigeesToFit, std::vector< Trk::ITrackLink * > &seedTracks) const
InDetIterativePriVxFinderTool(const std::string &t, const std::string &n, const IInterface *p)
Constructor.
ToolHandle< Trk::IVertexFitter > m_iVertexFitter
virtual ~InDetIterativePriVxFinderTool()
Destructor.
double compatibility(const Trk::TrackParameters &measPerigee, const xAOD::Vertex &vertex) const
void removeAllFrom(std::vector< const Trk::TrackParameters * > &perigeesToFit, std::vector< Trk::ITrackLink * > &seedTracks) const
virtual std::pair< xAOD::VertexContainer *, xAOD::VertexAuxContainer * > findVertex(const EventContext &ctx, const TrackCollection *trackTES) const override
Finding method for Trk::Track collection.
ToolHandle< Trk::IVertexSeedFinder > m_SeedFinder
static void countTracksAndNdf(xAOD::Vertex *myxAODVertex, double &ndf, int &ntracks)
SG::ReadCondHandleKey< InDet::BeamSpotData > m_beamSpotKey
ToolHandle< Trk::IImpactPoint3dEstimator > m_ImpactPoint3dEstimator
ToolHandle< Trk::IVertexLinearizedTrackFactory > m_LinearizedTrackFactory
Primary Vertex Finder.
Ensure that the ATLAS eigen extensions are properly loaded.
ParametersBase< TrackParametersDim, Charged > TrackParameters
Vertex_v1 Vertex
Define the latest version of the vertex class.
TrackParticleContainer_v1 TrackParticleContainer
Definition of the current "TrackParticle container version".