7#ifndef VRTSECINCLUSIVE_VRTSECINCLUSIVE_H
8#define VRTSECINCLUSIVE_VRTSECINCLUSIVE_H
11#include "VrtSecInclusive/Constants.h"
17#include "GaudiKernel/ToolHandle.h"
18#include "GaudiKernel/ITHistSvc.h"
32#include "GaudiKernel/ServiceHandle.h"
282 ToolHandle<IInDetConditionsTool>
m_pixelCondSummaryTool{
this,
"PixelConditionsSummaryTool",
"PixelConditionsSummaryTool",
"Tool to retrieve Pixel Conditions summary"};
283 ToolHandle<IInDetConditionsTool>
m_sctCondSummaryTool{
this,
"InDetSCT_ConditionsSummaryTool",
"SCT_ConditionsSummaryTool/InDetSCT_ConditionsSummaryTool",
"Tool to retrieve SCT conditions summary"};
368 using PatternBank = std::map<const xAOD::TrackParticle*, std::pair< std::unique_ptr<ExtrapolatedPattern>, std::unique_ptr<ExtrapolatedPattern> > >;
447 void printWrkSet(
const std::vector<WrkVrt> *WrkVrtSet,
const std::string& name);
462 std::vector< std::deque<long int> > *,
463 const long int & ,
const long int & );
465 StatusCode
disassembleVertex(std::vector<WrkVrt> *,
const unsigned& vertexIndex );
467 void trackClassification(std::vector< WrkVrt >* , std::map<
long int, std::vector<long int> >& );
472 static size_t nTrkCommon( std::vector<WrkVrt> *WrkVrtSet,
const std::pair<unsigned, unsigned>& pairIndex ) ;
572 template<
class LeptonFlavor>
Helper class to provide type-safe access to aux data.
Extrapolation for HepMC particles.
This is an Identifier helper class for the Pixel subdetector.
This is an Identifier helper class for the SCT subdetector.
AthAlgorithm(const std::string &name, ISvcLocator *pSvcLocator)
Constructor with parameters:
This class provides an interface to generate or decode an identifier for the upper levels of the dete...
This is an Identifier helper class for the Pixel subdetector.
This is an Identifier helper class for the SCT subdetector.
SG::Decorator< T, ALLOC > Decorator
Manage lookup of vectors of auxiliary data.
Property holding a SG store/key/clid from which a ReadHandle is made.
Property holding a SG store/key/clid/attr name from which a WriteDecorHandle is made.
ITruthToTrack is an interface to create Trk::TrackParameters from a HepMC::GenParticle.
Interface class IVertexMapper.
bool patternCheck(const uint32_t &pattern, const Amg::Vector3D &vertex)
StatusCode selectTracksFromMuons()
SG::AuxElement::Decorator< std::vector< std::vector< float > > > IPDecoratorType
StatusCode associateNonSelectedTracks(std::vector< WrkVrt > *)
in addition to selected tracks, associate as much tracks as possible
VrtSecInclusive(const std::string &name, ISvcLocator *pSvcLocator)
Standard Athena-Algorithm Constructor.
bool selectTrack_pTCut(const xAOD::TrackParticle *) const
std::map< std::string, PatternStrategyFunc > m_patternStrategyFuncs
static const xAOD::TruthParticle * getTrkGenParticle(const xAOD::TrackParticle *)
const xAOD::Vertex * m_thePV
StatusCode refitVertexWithSuggestion(WrkVrt &, const Amg::Vector3D &)
refit the vertex with suggestion
bool passedFakeReject(const Amg::Vector3D &FitVertex, const xAOD::TrackParticle *itrk, const xAOD::TrackParticle *jtrk)
Flag false if the consistituent tracks are not consistent with the vertex position.
StatusCode setupNtupleVariables()
bool checkTrackHitPatternToVertex(const xAOD::TrackParticle *trk, const Amg::Vector3D &vertex)
A classical method with hard-coded geometry.
static bool patternCheckRun1(const uint32_t &pattern, const Amg::Vector3D &vertex)
bool checkTrackHitPatternToVertexByExtrapolationAssist(const xAOD::TrackParticle *trk, const Amg::Vector3D &vertex)
New method with track extrapolation.
void printWrkSet(const std::vector< WrkVrt > *WrkVrtSet, const std::string &name)
print the contents of reconstructed vertices
static bool patternCheckRun2(const uint32_t &pattern, const Amg::Vector3D &vertex)
bool checkTrackHitPatternToVertexByExtrapolation(const xAOD::TrackParticle *trk, const Amg::Vector3D &vertex)
New method with track extrapolation.
ToolHandle< IInDetConditionsTool > m_pixelCondSummaryTool
Condition service.
StatusCode mergeFinalVertices(std::vector< WrkVrt > *)
attempt to merge vertices by lookng at the distance between two vertices
StatusCode refitAndSelectGoodQualityVertices(std::vector< WrkVrt > *)
finalization of the vertex and store to xAOD::VertexContainer
bool selectTrack_chi2Cut(const xAOD::TrackParticle *) const
bool selectTrack_notPVassociated(const xAOD::TrackParticle *) const
track-by-track selection strategies
void lockTrackDecorations(const xAOD::TrackParticle *trk, bool onlySelection) const
lock decorations at the end of the algorithm
virtual StatusCode execute()
void trackClassification(std::vector< WrkVrt > *, std::map< long int, std::vector< long int > > &)
std::map< unsigned, SG::Decorator< float > > m_trkDecors
ExtrapolatedPattern * extrapolatedPattern(const xAOD::TrackParticle *, enum Trk::PropDirection)
void selectTrack(const xAOD::TrackParticle *)
Vertexing Algorithm Member Functions.
StatusCode(VrtSecInclusive::*)(std::vector< WrkVrt > *) vertexingAlg
void lockLeptonDecorations(const SG::AuxVectorData *cont) const
bool selectTrack_hitPatternTight(const xAOD::TrackParticle *) const
StatusCode deleteNtupleVariables()
double findWorstChi2ofMaximallySharedTrack(std::vector< WrkVrt > *, std::map< long int, std::vector< long int > > &, long int &, long int &)
StatusCode reassembleVertices(std::vector< WrkVrt > *)
attempt to merge vertices when all tracks of a vertex A is close to vertex B in terms of impact param...
static bool selectTrack_d0signifCut(const xAOD::TrackParticle *)
bool selectTrack_d0errCut(const xAOD::TrackParticle *) const
std::unique_ptr< NtupleVars > m_ntupleVars
static bool patternCheckRun1OuterOnly(const uint32_t &pattern, const Amg::Vector3D &vertex)
bool getSVImpactParameters(const xAOD::TrackParticle *trk, const Amg::Vector3D &vertex, std::vector< double > &impactParameters, std::vector< double > &impactParErrors)
get secondary vertex impact parameters
StatusCode categorizeVertexTruthTopology(xAOD::Vertex *vertex)
void removeInconsistentTracks(WrkVrt &)
Remove inconsistent tracks from vertices.
StatusCode rearrangeTracks(std::vector< WrkVrt > *)
StatusCode clearNtupleVariables()
ToolHandle< IInDetConditionsTool > m_sctCondSummaryTool
bool selectTrack_hitPattern(const xAOD::TrackParticle *) const
ToolHandle< Trk::IVertexMapper > m_vertexMapper
unsigned m_vertexingAlgorithmStep
StatusCode extractIncompatibleTrackPairs(std::vector< WrkVrt > *)
related to the graph method and verte finding
StatusCode fillAANT_SelectedBaseTracks()
bool checkTrackHitPatternToVertexOuterOnly(const xAOD::TrackParticle *trk, const Amg::Vector3D &vertex)
A classical method with hard-coded geometry.
std::vector< CutFunc > m_trackSelectionFuncs
std::optional< SG::Decorator< char > > m_decor_isSelected
void getIntersection(Track *trk, std::vector< IntersectionPos * > &layers, const Trk::Perigee *per)
ToolHandle< Trk::IExtrapolator > m_extrapolator
ToolHandle< Trk::ITrackToVertexIPEstimator > m_trackToVertexIPEstimatorTool
StatusCode augmentDVimpactParametersToLeptons(const std::string &containerName)
const PixelID * m_pixelId
std::map< std::string, TH1 * > m_hists
static void fillTrackSummary(track_summary &summary, const xAOD::TrackParticle *trk)
retrieve the track hit information
double improveVertexChi2(WrkVrt &)
attempt to improve the vertex chi2 by removing the most-outlier track one by one until the vertex chi...
SG::ReadHandleKey< xAOD::EventInfo > m_eventInfoKey
Read/Write Handle Keys.
double distanceBetweenVertices(const WrkVrt &, const WrkVrt &) const
calculate the physical distance
StatusCode(VrtSecInclusive::*)() TrackSelectionAlg
StatusCode findNtrackVertices(std::vector< WrkVrt > *)
StatusCode monitorVertexingAlgorithmStep(std::vector< WrkVrt > *, const std::string &name, bool final=false)
monitor the intermediate status of vertexing
static size_t nTrkCommon(std::vector< WrkVrt > *WrkVrtSet, const std::pair< unsigned, unsigned > &pairIndex)
returns the number of tracks commonly present in both vertices
static double findMinVerticesNextPair(std::vector< WrkVrt > *, std::pair< unsigned, unsigned > &)
returns the next pair of vertices that give next-to-minimum distance significance
std::tuple< const TVector3, Detector, Bec, Layer, Flag > ExtrapolatedPoint
bool(VrtSecInclusive::*)(const xAOD::TrackParticle *) const CutFunc
track selection
bool selectTrack_LRTR3Cut(const xAOD::TrackParticle *) const
std::optional< SG::Decorator< char > > m_decor_is_svtrk_final
double findMinVerticesPair(std::vector< WrkVrt > *, std::pair< unsigned, unsigned > &, const AlgForVerticesPair &)
returns the pair of vertices that give minimum in terms of some observable (e.g.
std::optional< VertexELType > m_decor_svLink
std::map< const xAOD::TrackParticle *, std::pair< std::unique_ptr< ExtrapolatedPattern >, std::unique_ptr< ExtrapolatedPattern > > > PatternBank
const AtlasDetectorID * m_atlasId
StatusCode refitVertex(WrkVrt &)
refit the vertex.
static void removeTrackFromVertex(std::vector< WrkVrt > *, std::vector< std::deque< long int > > *, const long int &, const long int &)
ToolHandle< Reco::ITrackToVertex > m_trackToVertexTool
get a handle on the Track to Vertex tool
bool selectTrack_d0Cut(const xAOD::TrackParticle *) const
StatusCode processPrimaryVertices()
bool selectTrack_z0Cut(const xAOD::TrackParticle *) const
std::vector< double > m_BeamPosition
SG::AuxElement::Decorator< std::vector< ElementLink< xAOD::VertexContainer > > > VertexELType
std::vector< IPDecoratorType > m_ipDecors
std::vector< ExtrapolatedPoint > ExtrapolatedPattern
const xAOD::VertexContainer * m_primaryVertices
StatusCode mergeVertices(WrkVrt &destination, WrkVrt &source)
the 2nd vertex is merged into the 1st vertex.
std::vector< const xAOD::TrackParticle * > m_associatedTracks
bool selectTrack_z0errCut(const xAOD::TrackParticle *) const
ToolHandle< Trk::ITrkVKalVrtFitter > m_fitSvc
StatusCode selectTracksFromElectrons()
std::vector< const xAOD::TrackParticle * > m_selectedTracks
virtual StatusCode initialize()
StatusCode disassembleVertex(std::vector< WrkVrt > *, const unsigned &vertexIndex)
StatusCode selectTracksInDet()
std::string m_checkPatternStrategy
StatusCode fillAANT_SecondaryVertices(xAOD::VertexContainer *)
double(VrtSecInclusive::*)(const WrkVrt &, const WrkVrt &) const AlgForVerticesPair
StatusCode mergeByShuffling(std::vector< WrkVrt > *)
attempt to merge splitted vertices when they are significantly distant due to the long-tail behavior ...
bool patternCheckOuterOnly(const uint32_t &pattern, const Amg::Vector3D &vertex)
static bool selectTrack_z0signifCut(const xAOD::TrackParticle *)
std::vector< std::pair< std::string, vertexingAlg > > m_vertexingAlgorithms
struct JobProperties m_jp
~VrtSecInclusive()
Default Destructor.
virtual StatusCode finalize()
struct VKalVrtAthena::VrtSecInclusive::track_summary_properties track_summary
SG::WriteDecorHandleKey< xAOD::EventInfo > m_vertexingStatusKey
void setIntersection(Track *trk, IntersectionPos *bec, const Trk::Perigee *per)
std::vector< const xAOD::TrackParticle * > m_leptonicTracks
std::vector< std::pair< int, int > > m_incomp
StatusCode addEventInfo()
ToolHandle< Trk::ITruthToTrack > m_truthToTrack
static bool patternCheckRun2OuterOnly(const uint32_t &pattern, const Amg::Vector3D &vertex)
PatternBank m_extrapolatedPatternBank
StatusCode selectInDetAndGSFTracks()
std::optional< SG::Decorator< char > > m_decor_isAssociated
virtual StatusCode initEvent()
std::vector< const xAOD::TruthVertex * > m_tracingTruthVertices
void dumpTruthInformation()
bool(VrtSecInclusive::*)(const xAOD::TrackParticle *trk, const Amg::Vector3D &vertex) PatternStrategyFunc
double significanceBetweenVertices(const WrkVrt &, const WrkVrt &) const
calculate the significance (Mahalanobis distance) between two reconstructed vertices
std::vector< TrackSelectionAlg > m_trackSelectionAlgs
std::map< const xAOD::TruthVertex *, bool > m_matchMap
Eigen::Matrix< double, 3, 1 > Vector3D
USAGE: openCoraCool.exe "COOLONL_SCT/COMP200".
Ensure that the ATLAS eigen extensions are properly loaded.
PropDirection
PropDirection, enum for direction of the propagation.
ParametersT< TrackParametersDim, Charged, PerigeeSurface > Perigee
TrackParticle_v1 TrackParticle
Reference the current persistent version:
VertexContainer_v1 VertexContainer
Definition of the current "Vertex container version".
Vertex_v1 Vertex
Define the latest version of the vertex class.
TruthParticle_v1 TruthParticle
Typedef to implementation.
std::string mcEventContainerName
unsigned int SelTrkMaxCutoff
double associateMinDistanceToPV
bool doSelectTracksFromElectrons
bool doAugmentDVimpactParametersToMuons
std::string truthParticleContainerName
bool doTightPVcompatibilityCut
bool doRemoveNonLeptonVertices
double reassembleMaxImpactParameterZ0
std::string ElectronLocation
bool doAssociateNonSelectedTracks
double twoTrkVtxFormingD0Cut
double VertexMergeFinalDistScaling
bool FillIntermediateVertices
double twoTrVrtMaxPerigeeDist
bool passThroughTrackSelection
double VertexMergeFinalDistCut
bool doDisappearingTrackVertexing
std::string truthParticleFilter
std::string all2trksVerticesContainerName
double mergeByShufflingMaxSignificance
std::string PrimVrtLocation
bool doMergeFinalVerticesDistance
bool doAugmentDVimpactParametersToElectrons
double pvCompatibilityCut
bool doSelectIDAndGSFTracks
bool doReassembleVertices
double twoTrVrtMinDistFromPV
bool doSuggestedRefitOnMerging
double mergeByShufflingAllowance
double associateMaxZ0Signif
double improveChi2ProbThreshold
std::string TrackLocation
bool doPVcompatibilityCut
bool doSelectTracksWithLRTCuts
bool doRemoveCaloTaggedMuons
bool doSelectTracksFromMuons
double associateMaxD0Signif
double reassembleMaxImpactParameterD0
std::string secondaryVerticesContainerName
double Chi2
VKalVrt fit covariance.
std::vector< double > vertexCov
VKalVrt fit vertex 4-momentum.
std::vector< double > Chi2PerTrk
VKalVrt fit chi2 result.
std::deque< long int > selectedTrackIndices
flagged true for good vertex candidates
std::deque< long int > associatedTrackIndices
list if indices in TrackParticleContainer for selectedBaseTracks
long int Charge
list of VKalVrt fit chi2 for each track
double Chi2_core
VKalVrt fit chi2 result.
double fitQuality() const
Amg::Vector3D vertex
list if indices in TrackParticleContainer for associatedTracks
TLorentzVector vertexMom
VKalVrt fit vertex position.
unsigned nTracksTotal() const
double closestWrkVrtValue
stores the index of the closest WrkVrt in std::vector<WrkVrt>
double ndof() const
stores the value of some observable to the closest WrkVrt ( observable = e.g. significance )
std::vector< std::vector< double > > TrkAtVrt
total charge of the vertex
unsigned long closestWrkVrtIndex
list of track parameters wrt the reconstructed vertex
uint8_t numSctBarrelLayer1_Hits
uint8_t numPixelDisk0_Hits
uint8_t numPixelDisk2_Hits
uint8_t numSctBarrelLayer0_Hits
uint8_t numPixelLayer1_Hits
uint8_t numSctBarrelLayer2_Hits
uint8_t numSctBarrelLayer3_Hits
uint8_t numPixelLayer2_Hits
uint8_t numPixelDisk1_Hits