5#ifndef TRKALIGNGENTOOLS_BEAMSPOTVERTEXPREPROCESSOR_H
6#define TRKALIGNGENTOOLS_BEAMSPOTVERTEXPREPROCESSOR_H
8#include "GaudiKernel/ToolHandle.h"
9#include "GaudiKernel/IAlgTool.h"
59 virtual StatusCode
finalize()
override;
94 this,
"TrackFitter",
"Trk::GlobalChi2Fitter/InDetTrackFitter",
95 "normal track fitter"};
97 this,
"SLTrackFitter",
"",
"straight line track fitter"};
99 this,
"Extrapolator",
"Trk::Extrapolator/AtlasExtrapolator"};
101 this,
"TrackSelector",
"",
"new track selector tool"};
103 this,
"BSConstraintTrackSelector",
"",
104 "new track selector tool for tracks to be used with beam-spot constraint"};
106 this,
"TrackToVertexIPEstimatorTool",
""};
110 this,
"AlignModuleTool",
"InDet::InDetAlignModuleTool/InDetAlignModuleTool"};
113 this,
"BeamSpotKey",
"BeamSpotData",
"SG key for beam spot" };
116 this,
"PVContainerName",
"PrimaryVertices"};
119 "switch whether to run outlier logics or not"};
121 "type of material interaction in extrapolation, 3=pion, 0=non-interacting"};
123 "to activate the preprocessor track selection"};
125 "the selection mechanism which is based on cutting the perigee parameters, pt, etc."};
127 this,
"DoAssociatedToPVSelection",
true,
128 "the selection mechanism that only use the tracks associated to PV"};
132 std::vector< std::pair< const xAOD::Vertex*, std::vector<VxTrackAtVertex> > >
m_allTracksVector;
135 "Constrain tracks to the beamspot (x,y) position"};
137 "Constrain tracks to the associated primary vertex (x,y,z) position"};
139 "Full 3D vertex constraint. Note DoPVConstraint needs to be set to true to use this option. If DoBSConstraint vertex position will be constrained to the BS"};
141 "provide tracks in the case failed BS, PV and FullVertex constraints."};
144 "Max pT range for refitting tracks"};
147 "flag to refit tracks"};
149 "flag to store derivative and covariance matrices after refit"};
151 "only use 1 fitter for refitting track"};
153 "scaling factor on beasmpot width"};
155 "scaling factor on primary vertex position error"};
158 "requirement to the minimal number of tracks in the vertex"};
#define AmgSymMatrix(dim)
Property holding a SG store/key/clid from which a ReadHandle is made.
Property holding a SG store/key/clid from which a ReadHandle is made.
bool doBeamspotConstraintTrackSelection(const Track *track)
PublicToolHandle< IAlignModuleTool > m_alignModuleTool
Pointer to AlignModuleTool.
IntegerProperty m_minTrksInVtx
SG::ReadHandleKey< xAOD::VertexContainer > m_PVContainerName
void accumulateVTX(AlignTrack *alignTrack) override
methods added for the full VTX fit:
BooleanProperty m_doTrkSelection
const VertexOnTrack * provideVotFromVertex(const Track *track, const xAOD::Vertex *&vtx) const
bool selectVertices(const xAOD::Vertex *vtx) const
virtual ~BeamspotVertexPreProcessor()
DoubleProperty m_BSScalingFactor
BooleanProperty m_doNormalRefit
BooleanProperty m_storeFitMatrices
BooleanProperty m_doFullVertexConstraint
bool isAssociatedToVertex(const Track *track, const xAOD::Vertex *vertex)
std::vector< int > m_trackTypeCounter
ToolHandle< InDet::IInDetTrackSelectionTool > m_trkSelector
bool isAssociatedToPV(const Track *track, const xAOD::VertexContainer *vertices)
ToolHandle< IGlobalTrackFitter > m_trackFitter
int m_nFailedNormalRefits
void prepareAllTracksVector()
const xAOD::Vertex * findVertexCandidate(const Track *track) const
AlignTrack * doTrackRefit(const Track *track)
virtual DataVector< Track > * processTrackCollection(const DataVector< Track > *trks) override
Main processing of track collection.
IntegerProperty m_particleNumber
void provideVtxBeamspot(const AlignVertex *b, AmgSymMatrix(3) *q, Amg::Vector3D *v) const
UnsignedIntegerProperty m_constraintMode
ToolHandle< IExtrapolator > m_extrapolator
DataVector< AlignVertex > m_AlignVertices
collection of AlignVertices used in FullVertex constraint option
std::vector< std::pair< const xAOD::Vertex *, std::vector< VxTrackAtVertex > > > m_allTracksVector
DoubleProperty m_PVScalingFactor
const Track * doConstraintRefit(ToolHandle< IGlobalTrackFitter > &fitter, const Track *track, const VertexOnTrack *vot, const ParticleHypothesis &particleHypothesis) const
BooleanProperty m_useSingleFitter
virtual StatusCode finalize() override
BooleanProperty m_runOutlierRemoval
ToolHandle< IGlobalTrackFitter > m_SLTrackFitter
virtual StatusCode initialize() override
SG::ReadCondHandleKey< InDet::BeamSpotData > m_beamSpotKey
ToolHandle< InDet::IInDetTrackSelectionTool > m_BSTrackSelector
ToolHandle< ITrackToVertexIPEstimator > m_trackToVertexIPEstimatorTool
BooleanProperty m_refitTracks
BooleanProperty m_doBeamspotConstraint
BooleanProperty m_doBSTrackSelection
virtual void printSummary() override
Print processing summary to logfile.
bool selectUpdatedVertices(const xAOD::Vertex *updatedVtx) const
BooleanProperty m_doPrimaryVertexConstraint
BeamspotVertexPreProcessor(const std::string &type, const std::string &name, const IInterface *parent)
const VertexOnTrack * provideVotFromBeamspot(const Track *track) const
BooleanProperty m_doAssociatedToPVSelection
CompareTwoTracks(const Track *track, const std::string &compareMethod)
bool operator()(VxTrackAtVertex vtxTrk)
Class to handle Vertex On Tracks, it inherits from the common MeasurementBase.
The VxTrackAtVertex is a common class for all present TrkVertexFitters The VxTrackAtVertex is designe...
Eigen::Matrix< double, 3, 1 > Vector3D
Ensure that the ATLAS eigen extensions are properly loaded.
ParticleHypothesis
Enumeration for Particle hypothesis respecting the interaction with material.
VertexContainer_v1 VertexContainer
Definition of the current "Vertex container version".
Vertex_v1 Vertex
Define the latest version of the vertex class.