ATLAS Offline Software
Classes | Public Member Functions | Protected Member Functions | Private Types | Private Member Functions | Private Attributes | List of all members
TrigVSI::TrigVrtSecInclusive Class Reference

#include <TrigVrtSecInclusive.h>

Inheritance diagram for TrigVSI::TrigVrtSecInclusive:
Collaboration diagram for TrigVSI::TrigVrtSecInclusive:

Classes

struct  WrkVrt
 

Public Member Functions

 TrigVrtSecInclusive (const std::string &name, ISvcLocator *pSvcLocator)
 
virtual ~TrigVrtSecInclusive ()
 
virtual StatusCode initialize () override
 
virtual StatusCode execute (const EventContext &ctx) const override
 
virtual StatusCode finalize () override
 
virtual StatusCode sysInitialize () override
 Override sysInitialize. More...
 
virtual bool isClonable () const override
 Specify if the algorithm is clonable. More...
 
virtual unsigned int cardinality () const override
 Cardinality (Maximum number of clones that can exist) special value 0 means that algorithm is reentrant. More...
 
virtual StatusCode sysExecute (const EventContext &ctx) override
 Execute an algorithm. More...
 
virtual const DataObjIDColl & extraOutputDeps () const override
 Return the list of extra output dependencies. More...
 
virtual bool filterPassed (const EventContext &ctx) const
 
virtual void setFilterPassed (bool state, const EventContext &ctx) const
 
ServiceHandle< StoreGateSvc > & evtStore ()
 The standard StoreGateSvc (event store) Returns (kind of) a pointer to the StoreGateSvc. More...
 
const ServiceHandle< StoreGateSvc > & evtStore () const
 The standard StoreGateSvc (event store) Returns (kind of) a pointer to the StoreGateSvc. More...
 
const ServiceHandle< StoreGateSvc > & detStore () const
 The standard StoreGateSvc/DetectorStore Returns (kind of) a pointer to the StoreGateSvc. More...
 
virtual StatusCode sysStart () override
 Handle START transition. More...
 
virtual std::vector< Gaudi::DataHandle * > inputHandles () const override
 Return this algorithm's input handles. More...
 
virtual std::vector< Gaudi::DataHandle * > outputHandles () const override
 Return this algorithm's output handles. More...
 
Gaudi::Details::PropertyBase & declareProperty (Gaudi::Property< T > &t)
 
Gaudi::Details::PropertyBase * declareProperty (const std::string &name, SG::VarHandleKey &hndl, const std::string &doc, const SG::VarHandleKeyType &)
 Declare a new Gaudi property. More...
 
Gaudi::Details::PropertyBase * declareProperty (const std::string &name, SG::VarHandleBase &hndl, const std::string &doc, const SG::VarHandleType &)
 Declare a new Gaudi property. More...
 
Gaudi::Details::PropertyBase * declareProperty (const std::string &name, SG::VarHandleKeyArray &hndArr, const std::string &doc, const SG::VarHandleKeyArrayType &)
 
Gaudi::Details::PropertyBase * declareProperty (const std::string &name, T &property, const std::string &doc, const SG::NotHandleType &)
 Declare a new Gaudi property. More...
 
Gaudi::Details::PropertyBase * declareProperty (const std::string &name, T &property, const std::string &doc="none")
 Declare a new Gaudi property. More...
 
void updateVHKA (Gaudi::Details::PropertyBase &)
 
MsgStream & msg () const
 
MsgStream & msg (const MSG::Level lvl) const
 
bool msgLvl (const MSG::Level lvl) const
 

Protected Member Functions

void renounceArray (SG::VarHandleKeyArray &handlesArray)
 remove all handles from I/O resolution More...
 
std::enable_if_t< std::is_void_v< std::result_of_t< decltype(&T::renounce)(T)> > &&!std::is_base_of_v< SG::VarHandleKeyArray, T > &&std::is_base_of_v< Gaudi::DataHandle, T >, void > renounce (T &h)
 
void extraDeps_update_handler (Gaudi::Details::PropertyBase &ExtraDeps)
 Add StoreName to extra input/output deps as needed. More...
 

Private Types

enum  TrkParameter {
  k_d0 =0, k_z0 =1, k_theta =2, k_phi =3,
  k_qOverP =4, k_nTP =5
}
 
enum  TrkParameterUnc { k_d0d0 =0, k_z0z0 =1, k_nTPU =2 }
 
using xAODContainers = std::pair< std::unique_ptr< xAOD::VertexContainer >, std::unique_ptr< xAOD::VertexAuxContainer > >
 
using WrkVrtContainer = std::vector< WrkVrt >
 
typedef ServiceHandle< StoreGateSvcStoreGateSvc_t
 

Private Member Functions

bool selectTrack (const xAOD::TrackParticle *trk) const
 
bool selectTrack_hitPattern (const xAOD::TrackParticle *trk) const
 
bool selectTrack_d0Cut (const xAOD::TrackParticle *trk) const
 
bool selectTrack_z0Cut (const xAOD::TrackParticle *trk) const
 
bool selectTrack_pTCut (const xAOD::TrackParticle *trk) const
 
bool selectTrack_chi2Cut (const xAOD::TrackParticle *trk) const
 
StatusCode fillVtxContainer (xAODContainers &, const WrkVrtContainer &, std::vector< const xAOD::TrackParticle * > &) const
 
size_t nTrkCommon (WrkVrtContainer &, const std::pair< unsigned, unsigned > &) const
 
StatusCode cleanUp (WrkVrtContainer &) const
 
StatusCode trackSelection (const xAOD::TrackParticleContainer *, const xAOD::TrackParticleContainer *, std::vector< const xAOD::TrackParticle * > &) const
 
StatusCode findDiTrackVertex (WrkVrtContainer &, std::vector< std::pair< size_t, size_t >> &, std::vector< const xAOD::TrackParticle * > &, const EventContext &, const xAOD::Vertex *) const
 
StatusCode findDiTrackVertexVSI (WrkVrtContainer &, std::vector< std::pair< size_t, size_t >> &, std::vector< const xAOD::TrackParticle * > &, const EventContext &, const xAOD::Vertex *) const
 
StatusCode findNtrackVerticesVSI (WrkVrtContainer &, std::vector< std::pair< size_t, size_t >> &, std::vector< const xAOD::TrackParticle * > &, const EventContext &) const
 
template<typename VrtType , typename Coord >
StatusCode findNTrackVertex (WrkVrtContainer &, TrigVSI::VtxMap< VrtType, Coord > &, const std::vector< const xAOD::TrackParticle * > &, const EventContext &) const
 
StatusCode fitVertexFromTracks (WrkVrt &, const std::vector< const xAOD::TrackParticle * > &, const EventContext &) const
 Reconstruct vertex from given tracks. More...
 
StatusCode mergeVertexFromDiTrkVrt (WrkVrtContainer &, const std::vector< std::pair< size_t, size_t >> &, const std::vector< size_t > &, const std::vector< const xAOD::TrackParticle * > &, const EventContext &) const
 Reconstruct multi-track vertices from incompatible track pair lists. More...
 
Gaudi::Details::PropertyBase & declareGaudiProperty (Gaudi::Property< T > &hndl, const SG::VarHandleKeyType &)
 specialization for handling Gaudi::Property<SG::VarHandleKey> More...
 
Gaudi::Details::PropertyBase & declareGaudiProperty (Gaudi::Property< T > &hndl, const SG::VarHandleKeyArrayType &)
 specialization for handling Gaudi::Property<SG::VarHandleKeyArray> More...
 
Gaudi::Details::PropertyBase & declareGaudiProperty (Gaudi::Property< T > &hndl, const SG::VarHandleType &)
 specialization for handling Gaudi::Property<SG::VarHandleBase> More...
 
Gaudi::Details::PropertyBase & declareGaudiProperty (Gaudi::Property< T > &t, const SG::NotHandleType &)
 specialization for handling everything that's not a Gaudi::Property<SG::VarHandleKey> or a <SG::VarHandleKeyArray> More...
 

Private Attributes

Gaudi::Property< int > m_vtxAlgorithm {this, "vtxAlgorithm", 0, "Vertexing algorithm. 0 : TrigVSI algorithm, 1 : Offline VSI like algorithm"}
 
Gaudi::Property< bool > m_recordTrkPair {this, "recordTrkPair", false, "Output EDM : Flag for record TrkPair vertices"}
 
Gaudi::Property< int > m_cutPixelHits {this, "CutPixelHits", 0, "Track selection : Hit requirements"}
 
Gaudi::Property< int > m_cutSctHits {this, "CutSctHits", 2, "Track selection : Hit requirements"}
 
Gaudi::Property< int > m_cutSharedHits {this, "CutSharedHits", 99, "Track selection : Hit requirements"}
 
Gaudi::Property< int > m_cutSiHits {this, "CutSiHits", 0, "Track selection : Hit requirements"}
 
Gaudi::Property< int > m_cutBLayHits {this, "CutBLayHits", 0, "Track selection : Hit requirements"}
 
Gaudi::Property< double > m_trkChi2Cut {this, "TrkChi2Cut", 50.0, "Track selection : Chi2 requirements"}
 
Gaudi::Property< double > m_trkPtCut {this, "TrkPtCut", (m_vtxAlgorithm == 0)? 2000. : 1000., "Track selection : pT requirements. 2 GeV in TrigVSI, 1 GeV in VSI"}
 
Gaudi::Property< double > m_d0TrkPVDstMinCut {this, "d0TrkPVDstMinCut", 2.0, "Track selection : Impact parameter requirements [mm]"}
 
Gaudi::Property< double > m_d0TrkPVDstMaxCut {this, "d0TrkPVDstMaxCut", 300.0, "Track selection : Impact parameter requirements [mm]"}
 
Gaudi::Property< double > m_z0TrkPVDstMinCut {this, "z0TrkPVDstMinCut", 0.0, "Track selection : Impact parameter requirements [mm]"}
 
Gaudi::Property< double > m_z0TrkPVDstMaxCut {this, "z0TrkPVDstMaxCut", 1500.0, "Track selection : Impact parameter requirements [mm]"}
 
Gaudi::Property< double > m_twoTrkVtxFormingD0Cut {this, "twoTrkVtxFormingD0Cut", 1., "Track selection : Impact parameter requirements [mm]"}
 
Gaudi::Property< double > m_maxR {this, "maxR", 563., "Track-pair selection : Max value for R of vertex position"}
 
Gaudi::Property< bool > m_doTwoCircRCut {this, "doTwoCircRCut", false, "Track-pair selection : Flag for R cut derived from two-circles-intersection-point"}
 
Gaudi::Property< bool > m_doFastRCut {this, "doFastRCut", false, "Track-pair selection : Flag for R cut derived from VKalVrtFitFast"}
 
Gaudi::Property< double > m_fastD0minCut {this, "fastD0minCut", 5., "Track-pair selection : Threshold for rough d0 cut"}
 
Gaudi::Property< double > m_fastD0deltaCut {this, "fastD0deltaCut", 4.2, "Track-pair selection : Threshold for rough d0 cut"}
 
Gaudi::Property< double > m_fastZ0minCut {this, "fastZ0minCut", 120., "Track-pair selection : Threshold for rough z0 cut"}
 
Gaudi::Property< double > m_fastZ0deltaCut {this, "fastZ0deltaCut", 8., "Track-pair selection : Threshold for rough z0 cut"}
 
Gaudi::Property< double > m_selVrtChi2Cut {this, "SelVrtChi2Cut", 4.5, "Track-pair selection : Threshold for the chi2 value of track pair fitting with VKalVrtFit"}
 
Gaudi::Property< bool > m_doPVCompatibilityCut {this, "doPVCompatibilityCut", false, "Track-pair selection : When set to true, require track pairs to be compatible with PV"}
 
Gaudi::Property< double > m_dphiPVCut {this, "dphiPVCut", -0.8, "Track-pair selection : Threshold for the cos of angle of the tracks and the momentum of the track pair"}
 
Gaudi::Property< double > m_pvCompatibilityCut {this, "PVcompatibilityCut", -20., "Track-pair selection : Threshold for the track pair position along the momentum vector"}
 
Gaudi::Property< bool > m_doMaterialMapVeto {this, "doMaterialMapVeto", false, "Track-pair selection : When set to true, perform material map veto on track pairs"}
 
Gaudi::Property< bool > m_skipLargeCluster {this, "skipLargeCluster", true, "Flag to skip vertexing on clusters with too many tracks"}
 
Gaudi::Property< size_t > m_maxTrks {this, "maxTrks", 100, "Max track number to run vertexing"}
 
Gaudi::Property< size_t > m_minTrkPairsMerge {this, "minTrkPairsMerge", 6, "Clusters with track pairs less than minTrkPairsMerge and tracks less than minTrksMerge will be merged into single vertex"}
 
Gaudi::Property< size_t > m_minTrksMerge {this, "minTrksMerge", 4, "Clusters with track pairs less than minTrkPairsMerge and tracks less than minTrksMerge will be merged into single vertex"}
 
Gaudi::Property< bool > m_truncateWrkVertices {this, "truncateWrkVertices", true, "Offline VSI option"}
 
Gaudi::Property< size_t > m_maxWrkVertices {this, "maxWrkVertices", 10000, "Offline VSI option"}
 
Gaudi::Property< double > m_improveChi2ProbThreshold {this, "improveChi2ProbThreshold", 4.5, "Offline VSI option"}
 
TH3Sm_materialMapInner =0
 
TH3Sm_materialMapOuter =0
 
TMatrixT< double > * m_materialMapMatrix =0
 
std::string m_materialMapInnerFileName
 
std::string m_materialMapInnerHistName
 
std::string m_materialMapInnerMatrixName
 
std::string m_materialMapOuterFileName
 
std::string m_materialMapOuterHistName
 
SG::ReadHandleKey< xAOD::TrackParticleContainerm_firstPassTracksName { this,"FirstPassTracksName","InDetTrackParticles","xAOD::TrackParticle Collection used in Vertexing" }
 
SG::ReadHandleKey< xAOD::TrackParticleContainerm_secondPassTracksName { this,"SecondPassTracksName","InDetTrackParticles","xAOD::TrackParticle Collection used in Vertexing" }
 
SG::WriteHandleKey< xAOD::VertexContainerm_vxCandidatesOutputName { this,"VxCandidatesOutputName","InclusiveSecVtx","Output Vertex Collection" }
 
SG::WriteHandleKey< xAOD::VertexContainerm_trkPairOutputName { this,"TrkPairOutputName","InclusiveSecVtx","Track pair Collection" }
 
SG::ReadHandleKey< xAOD::VertexContainerm_PrimaryVxInputName { this,"PrimaryVertexInputName","PrimaryVertices","Input Vertex Collection" }
 
ToolHandle< Trk::TrkVKalVrtFitterm_fitSvc { this, "VertexFitter", "", "VKalVrtFitter tool to fit tracks into the common vertex" }
 
ToolHandle< InDet::VertexPointEstimatorm_vertexPointEstimator { this, "VertexPointEstimator", "", "tool to find starting point for the vertex fitter"}
 
ToolHandle< GenericMonitoringToolm_monTool { this, "MonTool", "", "Monitoring tool" }
 
DataObjIDColl m_extendedExtraObjects
 Extra output dependency collection, extended by AthAlgorithmDHUpdate to add symlinks. More...
 
StoreGateSvc_t m_evtStore
 Pointer to StoreGate (event store by default) More...
 
StoreGateSvc_t m_detStore
 Pointer to StoreGate (detector store by default) More...
 
std::vector< SG::VarHandleKeyArray * > m_vhka
 
bool m_varHandleArraysDeclared
 

Detailed Description

Author
Kunihiro Nagano kunih.nosp@m.iro..nosp@m.nagan.nosp@m.o@ce.nosp@m.rn.ch - KEK

Definition at line 36 of file TrigVrtSecInclusive.h.

Member Typedef Documentation

◆ StoreGateSvc_t

typedef ServiceHandle<StoreGateSvc> AthCommonDataStore< AthCommonMsg< Gaudi::Algorithm > >::StoreGateSvc_t
privateinherited

Definition at line 388 of file AthCommonDataStore.h.

◆ WrkVrtContainer

Definition at line 174 of file TrigVrtSecInclusive.h.

◆ xAODContainers

using TrigVSI::TrigVrtSecInclusive::xAODContainers = std::pair< std::unique_ptr<xAOD::VertexContainer>, std::unique_ptr<xAOD::VertexAuxContainer> >
private

Definition at line 48 of file TrigVrtSecInclusive.h.

Member Enumeration Documentation

◆ TrkParameter

Enumerator
k_d0 
k_z0 
k_theta 
k_phi 
k_qOverP 
k_nTP 

Definition at line 169 of file TrigVrtSecInclusive.h.

169 { k_d0=0, k_z0=1, k_theta=2, k_phi=3, k_qOverP=4 ,k_nTP=5 };

◆ TrkParameterUnc

Enumerator
k_d0d0 
k_z0z0 
k_nTPU 

Definition at line 170 of file TrigVrtSecInclusive.h.

170 { k_d0d0=0, k_z0z0=1, k_nTPU=2 };

Constructor & Destructor Documentation

◆ TrigVrtSecInclusive()

TrigVSI::TrigVrtSecInclusive::TrigVrtSecInclusive ( const std::string &  name,
ISvcLocator *  pSvcLocator 
)

Definition at line 29 of file TrigVrtSecInclusive.cxx.

30  : AthReentrantAlgorithm(name, pSvcLocator),
31  m_materialMapInnerFileName("MaterialMap_v3.2_Inner.root"),
32  m_materialMapInnerHistName("FinalMap_inner"),
33  m_materialMapInnerMatrixName("FoldingInfo"),
34  m_materialMapOuterFileName("MaterialMap_v3_Outer.root"),
35  m_materialMapOuterHistName("matmap_outer")
36 {}

◆ ~TrigVrtSecInclusive()

TrigVSI::TrigVrtSecInclusive::~TrigVrtSecInclusive ( )
virtual

Definition at line 1590 of file TrigVrtSecInclusive.cxx.

1590 {}

Member Function Documentation

◆ cardinality()

unsigned int AthReentrantAlgorithm::cardinality ( ) const
overridevirtualinherited

Cardinality (Maximum number of clones that can exist) special value 0 means that algorithm is reentrant.

Override this to return 0 for reentrant algorithms.

Override this to return 0 for reentrant algorithms.

Definition at line 55 of file AthReentrantAlgorithm.cxx.

56 {
57  return 0;
58 }

◆ cleanUp()

StatusCode TrigVSI::TrigVrtSecInclusive::cleanUp ( WrkVrtContainer workVerticesContainer) const
private

Definition at line 1560 of file TrigVrtSecInclusive.cxx.

1562 {
1563  //-Remove vertices fully contained in other vertices
1564  ATH_MSG_VERBOSE(" > " << __FUNCTION__ << ": Remove vertices fully contained in other vertices .");
1565  size_t n_vtx = workVerticesContainer.size();
1566 
1567  for (size_t iv = 0; iv < n_vtx; iv++) {
1568  for (size_t jv = iv+1; jv < n_vtx; jv++) {
1569 
1570  if ( !workVerticesContainer.at(iv).isGood ) continue;
1571  if ( !workVerticesContainer.at(jv).isGood ) continue;
1572 
1573  const auto nTCom = nTrkCommon( workVerticesContainer, {iv, jv} );
1574 
1575  if( nTCom == workVerticesContainer.at(iv).selectedTrackIndices().size() ) { workVerticesContainer.at(iv).isGood = false; continue; }
1576  else if( nTCom == workVerticesContainer.at(jv).selectedTrackIndices().size() ) { workVerticesContainer.at(jv).isGood = false; continue; }
1577 
1578  }
1579  }
1580 
1581  return StatusCode::SUCCESS;
1582 }

◆ declareGaudiProperty() [1/4]

Gaudi::Details::PropertyBase& AthCommonDataStore< AthCommonMsg< Gaudi::Algorithm > >::declareGaudiProperty ( Gaudi::Property< T > &  hndl,
const SG::VarHandleKeyArrayType  
)
inlineprivateinherited

specialization for handling Gaudi::Property<SG::VarHandleKeyArray>

Definition at line 170 of file AthCommonDataStore.h.

172  {
173  return *AthCommonDataStore<PBASE>::declareProperty(hndl.name(),
174  hndl.value(),
175  hndl.documentation());
176 
177  }

◆ declareGaudiProperty() [2/4]

Gaudi::Details::PropertyBase& AthCommonDataStore< AthCommonMsg< Gaudi::Algorithm > >::declareGaudiProperty ( Gaudi::Property< T > &  hndl,
const SG::VarHandleKeyType  
)
inlineprivateinherited

specialization for handling Gaudi::Property<SG::VarHandleKey>

Definition at line 156 of file AthCommonDataStore.h.

158  {
159  return *AthCommonDataStore<PBASE>::declareProperty(hndl.name(),
160  hndl.value(),
161  hndl.documentation());
162 
163  }

◆ declareGaudiProperty() [3/4]

Gaudi::Details::PropertyBase& AthCommonDataStore< AthCommonMsg< Gaudi::Algorithm > >::declareGaudiProperty ( Gaudi::Property< T > &  hndl,
const SG::VarHandleType  
)
inlineprivateinherited

specialization for handling Gaudi::Property<SG::VarHandleBase>

Definition at line 184 of file AthCommonDataStore.h.

186  {
187  return *AthCommonDataStore<PBASE>::declareProperty(hndl.name(),
188  hndl.value(),
189  hndl.documentation());
190  }

◆ declareGaudiProperty() [4/4]

Gaudi::Details::PropertyBase& AthCommonDataStore< AthCommonMsg< Gaudi::Algorithm > >::declareGaudiProperty ( Gaudi::Property< T > &  t,
const SG::NotHandleType  
)
inlineprivateinherited

specialization for handling everything that's not a Gaudi::Property<SG::VarHandleKey> or a <SG::VarHandleKeyArray>

Definition at line 199 of file AthCommonDataStore.h.

200  {
201  return PBASE::declareProperty(t);
202  }

◆ declareProperty() [1/6]

Gaudi::Details::PropertyBase* AthCommonDataStore< AthCommonMsg< Gaudi::Algorithm > >::declareProperty ( const std::string &  name,
SG::VarHandleBase hndl,
const std::string &  doc,
const SG::VarHandleType  
)
inlineinherited

Declare a new Gaudi property.

Parameters
nameName of the property.
hndlObject holding the property value.
docDocumentation string for the property.

This is the version for types that derive from SG::VarHandleBase. The property value object is put on the input and output lists as appropriate; then we forward to the base class.

Definition at line 245 of file AthCommonDataStore.h.

249  {
250  this->declare(hndl.vhKey());
251  hndl.vhKey().setOwner(this);
252 
253  return PBASE::declareProperty(name,hndl,doc);
254  }

◆ declareProperty() [2/6]

Gaudi::Details::PropertyBase* AthCommonDataStore< AthCommonMsg< Gaudi::Algorithm > >::declareProperty ( const std::string &  name,
SG::VarHandleKey hndl,
const std::string &  doc,
const SG::VarHandleKeyType  
)
inlineinherited

Declare a new Gaudi property.

Parameters
nameName of the property.
hndlObject holding the property value.
docDocumentation string for the property.

This is the version for types that derive from SG::VarHandleKey. The property value object is put on the input and output lists as appropriate; then we forward to the base class.

Definition at line 221 of file AthCommonDataStore.h.

225  {
226  this->declare(hndl);
227  hndl.setOwner(this);
228 
229  return PBASE::declareProperty(name,hndl,doc);
230  }

◆ declareProperty() [3/6]

Gaudi::Details::PropertyBase* AthCommonDataStore< AthCommonMsg< Gaudi::Algorithm > >::declareProperty ( const std::string &  name,
SG::VarHandleKeyArray hndArr,
const std::string &  doc,
const SG::VarHandleKeyArrayType  
)
inlineinherited

Definition at line 259 of file AthCommonDataStore.h.

263  {
264 
265  // std::ostringstream ost;
266  // ost << Algorithm::name() << " VHKA declareProp: " << name
267  // << " size: " << hndArr.keys().size()
268  // << " mode: " << hndArr.mode()
269  // << " vhka size: " << m_vhka.size()
270  // << "\n";
271  // debug() << ost.str() << endmsg;
272 
273  hndArr.setOwner(this);
274  m_vhka.push_back(&hndArr);
275 
276  Gaudi::Details::PropertyBase* p = PBASE::declareProperty(name, hndArr, doc);
277  if (p != 0) {
278  p->declareUpdateHandler(&AthCommonDataStore<PBASE>::updateVHKA, this);
279  } else {
280  ATH_MSG_ERROR("unable to call declareProperty on VarHandleKeyArray "
281  << name);
282  }
283 
284  return p;
285 
286  }

◆ declareProperty() [4/6]

Gaudi::Details::PropertyBase* AthCommonDataStore< AthCommonMsg< Gaudi::Algorithm > >::declareProperty ( const std::string &  name,
T &  property,
const std::string &  doc,
const SG::NotHandleType  
)
inlineinherited

Declare a new Gaudi property.

Parameters
nameName of the property.
propertyObject holding the property value.
docDocumentation string for the property.

This is the generic version, for types that do not derive from SG::VarHandleKey. It just forwards to the base class version of declareProperty.

Definition at line 333 of file AthCommonDataStore.h.

337  {
338  return PBASE::declareProperty(name, property, doc);
339  }

◆ declareProperty() [5/6]

Gaudi::Details::PropertyBase* AthCommonDataStore< AthCommonMsg< Gaudi::Algorithm > >::declareProperty ( const std::string &  name,
T &  property,
const std::string &  doc = "none" 
)
inlineinherited

Declare a new Gaudi property.

Parameters
nameName of the property.
propertyObject holding the property value.
docDocumentation string for the property.

This dispatches to either the generic declareProperty or the one for VarHandle/Key/KeyArray.

Definition at line 352 of file AthCommonDataStore.h.

355  {
356  typedef typename SG::HandleClassifier<T>::type htype;
357  return declareProperty (name, property, doc, htype());
358  }

◆ declareProperty() [6/6]

Gaudi::Details::PropertyBase& AthCommonDataStore< AthCommonMsg< Gaudi::Algorithm > >::declareProperty ( Gaudi::Property< T > &  t)
inlineinherited

Definition at line 145 of file AthCommonDataStore.h.

145  {
146  typedef typename SG::HandleClassifier<T>::type htype;
148  }

◆ detStore()

const ServiceHandle<StoreGateSvc>& AthCommonDataStore< AthCommonMsg< Gaudi::Algorithm > >::detStore ( ) const
inlineinherited

The standard StoreGateSvc/DetectorStore Returns (kind of) a pointer to the StoreGateSvc.

Definition at line 95 of file AthCommonDataStore.h.

95 { return m_detStore; }

◆ evtStore() [1/2]

ServiceHandle<StoreGateSvc>& AthCommonDataStore< AthCommonMsg< Gaudi::Algorithm > >::evtStore ( )
inlineinherited

The standard StoreGateSvc (event store) Returns (kind of) a pointer to the StoreGateSvc.

Definition at line 85 of file AthCommonDataStore.h.

85 { return m_evtStore; }

◆ evtStore() [2/2]

const ServiceHandle<StoreGateSvc>& AthCommonDataStore< AthCommonMsg< Gaudi::Algorithm > >::evtStore ( ) const
inlineinherited

The standard StoreGateSvc (event store) Returns (kind of) a pointer to the StoreGateSvc.

Definition at line 90 of file AthCommonDataStore.h.

90 { return m_evtStore; }

◆ execute()

StatusCode TrigVSI::TrigVrtSecInclusive::execute ( const EventContext &  ctx) const
overridevirtual

Definition at line 90 of file TrigVrtSecInclusive.cxx.

91 {
92  // Setup output container for vertex
94 
95  std::unique_ptr<xAOD::VertexContainer> theXAODContainer = std::make_unique<xAOD::VertexContainer>();
96  std::unique_ptr<xAOD::VertexAuxContainer> theXAODAuxContainer = std::make_unique<xAOD::VertexAuxContainer>();
97  theXAODContainer->setStore( theXAODAuxContainer.get() );
98  xAODContainers theXAODContainers = std::make_pair( std::move(theXAODContainer), std::move(theXAODAuxContainer) );
99 
100  // Setup output container for track pair
102 
103  std::unique_ptr<xAOD::VertexContainer> theXAODTrkPairContainer = std::make_unique<xAOD::VertexContainer>();
104  std::unique_ptr<xAOD::VertexAuxContainer> theXAODTrkPairAuxContainer = std::make_unique<xAOD::VertexAuxContainer>();
105  theXAODTrkPairContainer->setStore( theXAODTrkPairAuxContainer.get() );
106  xAODContainers theXAODTrkPairContainers = std::make_pair( std::move(theXAODTrkPairContainer), std::move(theXAODTrkPairAuxContainer) );
107 
108  // retrieve primary vertices
109  //_________________________________________________________________________
111  const xAOD::Vertex* privtx = nullptr;
112  if( vtxCont.isValid() ){
113  const xAOD::VertexContainer* vertex_container = vtxCont.get();
114  privtx = vertex_container->at(0);
115  if ( !( privtx->vertexType() == xAOD::VxType::PriVtx
116  && privtx->nTrackParticles() >= 2 ) ){
117  ATH_MSG_WARNING( "Illed primary vertex, keeping null privtx" );
118  privtx = nullptr;
119  } else {
120  ATH_MSG_DEBUG( "primary vertex successfully retrieved" );
121  }
122  }
123  else {
124  ATH_MSG_WARNING( "couldn't retrieve primary vertex, keeping null privtx" );
125  }
126 
127  // retrieve the tracks
128  //_________________________________________________________________________
129  SG::ReadHandle<xAOD::TrackParticleContainer> firstPassTrackParticleCollection(m_firstPassTracksName, ctx);
130  SG::ReadHandle<xAOD::TrackParticleContainer> secondPassTrackParticleCollection(m_secondPassTracksName, ctx);
131  bool isFirstTrackValid = firstPassTrackParticleCollection.isValid();
132  bool isSecondTrackValid = secondPassTrackParticleCollection.isValid();
133  if( ! isFirstTrackValid ) ATH_MSG_WARNING( "couldn't retrieve first pass tracks: " << m_firstPassTracksName);
134  if( ! isSecondTrackValid ) ATH_MSG_WARNING( "couldn't retrieve second pass tracks: " << m_secondPassTracksName);
135 
136  // monitoring
137  //_________________________________________________________________________
138  auto timerTrackSel = Monitored::Timer<std::chrono::nanoseconds> ("TIME_TrackSel");
139  auto timerTwoTrackVertex = Monitored::Timer<std::chrono::milliseconds> ("TIME_TwoTrackVertex");
140  auto timerMapClustering = Monitored::Timer<std::chrono::microseconds> ("TIME_MapClustering");
141  auto timerNTrackVertex = Monitored::Timer<std::chrono::milliseconds> ("TIME_NTrackVertex");
142  auto timerNTrackVtxOffVSI = Monitored::Timer<std::chrono::milliseconds> ("TIME_NTrackVtxOffVSI");
143  auto timerCleanUp = Monitored::Timer<std::chrono::nanoseconds> ("TIME_CleanUp");
144  auto timerWriteVertices = Monitored::Timer<std::chrono::milliseconds> ("TIME_WriteVertices");
145  auto timerOverall = Monitored::Timer<std::chrono::milliseconds> ("TIME_Overall");
146 
147  auto monTime = Monitored::Group(m_monTool, timerTrackSel, timerTwoTrackVertex, timerMapClustering, timerNTrackVertex, timerNTrackVtxOffVSI, timerCleanUp, timerWriteVertices, timerOverall);
148 
149  timerOverall.start();
150 
151  // Reset incompatible pair list and selectedTracks
152  //_________________________________________________________________________
153  std::vector<std::pair<size_t,size_t>> v_incomp;
154  std::vector<const xAOD::TrackParticle*> v_selectedTracks;
155 
156  // tracks selection
157  //_________________________________________________________________________
158  timerTrackSel.start();
159 
160  if( isFirstTrackValid ) {
161  if( isSecondTrackValid ) {
162  ATH_CHECK( trackSelection( firstPassTrackParticleCollection.cptr(), secondPassTrackParticleCollection.cptr(), v_selectedTracks ) );
163  }
164  else {
165  ATH_CHECK( trackSelection( firstPassTrackParticleCollection.cptr(), nullptr, v_selectedTracks ) );
166  }
167  }
168  timerTrackSel.stop();
169 
170 
171  // Vertex reconstruction
172  //_________________________________________________________________________
173 
174  // Find compatible track pairs and record as di-trakc vertex
175  // ===============================
176  WrkVrtContainer v_diwrkvrt;
177  v_diwrkvrt.reserve(5000);
178 
179  if ( m_vtxAlgorithm == 0 ) {
180  // TrigVSI
181  timerTwoTrackVertex.start();
182  ATH_CHECK( findDiTrackVertex( v_diwrkvrt, v_incomp, v_selectedTracks, ctx, privtx ) );
183  timerTwoTrackVertex.stop();
184  } else {
185  // Offline VSI like
186  timerTwoTrackVertex.start();
187  ATH_CHECK( findDiTrackVertexVSI( v_diwrkvrt, v_incomp, v_selectedTracks, ctx, privtx ) );
188  timerTwoTrackVertex.stop();
189  }
190 
191  // Reconstruct N track vertices
192  // ===============================
193  // Ensure that the adress of each di-track wrkvrt can't be changed.
194  const WrkVrtContainer v_diTrkVertices = std::move(v_diwrkvrt);
195 
196  // define vertex map
197  namespace vsic = TrigVSI::AlgConsts;
198  TrigVSI::VtxMap<WrkVrt, TrigVSI::Coordinate::Pseudo> vtxmap( std::make_unique<TH3D>("TrigVrtSecInclusive_VtxMap", "TrigVrtSecInclusive_VtxMap", vsic::binNumR, vsic::IDrInner, vsic::IDrInner+vsic::mapBinWid*vsic::binNumR, vsic::nEta, -vsic::maxEta, vsic::maxEta, vsic::nPhi, -TMath::Pi(), TMath::Pi()) );
199 
200  // Container for reconstructed N-track vertices
201  WrkVrtContainer v_wrkvrt;
202  v_wrkvrt.reserve(1000);
203 
204  if ( m_vtxAlgorithm == 0 ) {
205  // TrigVSI
206  int trkpair_cnt = 0;
207 
208  // Fill vertex map
209  timerMapClustering.start();
210  for (auto wrkvrt_iter = v_diTrkVertices.begin(); wrkvrt_iter != v_diTrkVertices.end(); ++wrkvrt_iter ) {
211  if ( wrkvrt_iter->isGood && wrkvrt_iter->cuts.isFullPass() ) {
212  vtxmap.Fill( &(*wrkvrt_iter) );
213  trkpair_cnt++;
214  }
215  }
216  vtxmap.lock();
217  ATH_MSG_DEBUG( "filled vertex map with " << trkpair_cnt << " pairs" );
218  vtxmap.ClusterizeCells(1.,1);
219  timerMapClustering.stop();
220  ATH_MSG_DEBUG( "vertex map clustering successfully completed : " << vtxmap.nClusters() << " clusters" );
221 
222  // N track vertexing
223  timerNTrackVertex.start();
224  ATH_CHECK( findNTrackVertex( v_wrkvrt, vtxmap, v_selectedTracks, ctx ) );
225  timerNTrackVertex.stop();
226 
227  // Cleanup vertex fully included in other vertex.
228  timerCleanUp.start();
229  size_t n_pre_clean = v_wrkvrt.size();
230  ATH_CHECK( cleanUp(v_wrkvrt) );
231  size_t n_post_clean = v_wrkvrt.size();
232  timerCleanUp.stop();
233  ATH_MSG_DEBUG( "cleaned up " << n_pre_clean - n_post_clean << " out of " << n_pre_clean );
234 
235  } else {
236  // Offline VSI like
237  timerNTrackVtxOffVSI.start();
238  ATH_CHECK( findNtrackVerticesVSI( v_wrkvrt, v_incomp, v_selectedTracks, ctx ) );
239  timerNTrackVtxOffVSI.stop();
240 
241  }
242 
243  // Fill Vertex in the VertexContainer
244  timerWriteVertices.start();
245 
246  ATH_CHECK( fillVtxContainer( theXAODContainers, v_wrkvrt, v_selectedTracks ) );
247  if (m_recordTrkPair) {
248  ATH_CHECK( fillVtxContainer( theXAODTrkPairContainers, v_diTrkVertices, v_selectedTracks ) );
249  }
250 
251  // record AOD object
252  ATH_MSG_DEBUG( "Record vertices into container." );
253  ATH_CHECK(outputVertices.record(std::move(theXAODContainers.first), std::move(theXAODContainers.second)));
254  ATH_CHECK(outputTrkPairs.record(std::move(theXAODTrkPairContainers.first), std::move(theXAODTrkPairContainers.second)));
255  ATH_MSG_DEBUG( "Recorded Vertices with key: " << m_vxCandidatesOutputName.key() );
256 
257  timerWriteVertices.stop();
258 
259  timerOverall.stop();
260  ATH_MSG_DEBUG( "::execute() finished successfully." );
261 
262  return StatusCode::SUCCESS;
263 }

◆ extraDeps_update_handler()

void AthCommonDataStore< AthCommonMsg< Gaudi::Algorithm > >::extraDeps_update_handler ( Gaudi::Details::PropertyBase &  ExtraDeps)
protectedinherited

Add StoreName to extra input/output deps as needed.

use the logic of the VarHandleKey to parse the DataObjID keys supplied via the ExtraInputs and ExtraOuputs Properties to add the StoreName if it's not explicitly given

◆ extraOutputDeps()

const DataObjIDColl & AthReentrantAlgorithm::extraOutputDeps ( ) const
overridevirtualinherited

Return the list of extra output dependencies.

This list is extended to include symlinks implied by inheritance relations.

Definition at line 79 of file AthReentrantAlgorithm.cxx.

80 {
81  // If we didn't find any symlinks to add, just return the collection
82  // from the base class. Otherwise, return the extended collection.
83  if (!m_extendedExtraObjects.empty()) {
85  }
86  return Algorithm::extraOutputDeps();
87 }

◆ fillVtxContainer()

StatusCode TrigVSI::TrigVrtSecInclusive::fillVtxContainer ( xAODContainers theXAODContainers,
const WrkVrtContainer workVerticesContainer,
std::vector< const xAOD::TrackParticle * > &  selectedTracks 
) const
private

Definition at line 288 of file TrigVrtSecInclusive.cxx.

289 {
290  xAOD::VertexContainer* theVertexContainer = theXAODContainers.first.get();
291 
292  for (const auto& wrkvrt : workVerticesContainer) {
293 
294  if ( !wrkvrt.isGood && !wrkvrt.isPair ) continue;
295 
296  std::vector<const xAOD::TrackParticle*> baseTracks;
297  for ( auto i : wrkvrt.selectedTrackIndices() ) {
298  baseTracks.emplace_back( selectedTracks.at(i) );
299  }
300 
301  // Create a xAOD::Vertex instance
303  vertex->makePrivateStore();
304  theVertexContainer->emplace_back( vertex );
305 
306  for( auto *trk: baseTracks ) {
307  // Acquire link to the track
308  ElementLink<xAOD::TrackParticleContainer> trackElementLink( *( dynamic_cast<const xAOD::TrackParticleContainer*>( trk->container() ) ), trk->index() );
309  // Register link to the vertex
310  vertex->addTrackAtVertex( trackElementLink, 1. );
311  }
312 
313  vertex->setVertexType( xAOD::VxType::SecVtx );
314  vertex->setPosition( wrkvrt.vertex );
315  vertex->setFitQuality( wrkvrt.chi2, 1 ); // Ndof is always 1
316 
317  static const SG::Accessor<float> vsi_massAcc("vsi_mass");
318  static const SG::Accessor<float> vsi_pTAcc("vsi_pT");
319  static const SG::Accessor<float> vsi_chargeAcc("vsi_charge");
320  static const SG::Accessor<char> vsi_isFakeAcc("vsi_isFake");
321  vsi_massAcc(*vertex) = wrkvrt.vertexMom.M();
322  vsi_pTAcc(*vertex) = wrkvrt.vertexMom.Perp();
323  vsi_chargeAcc(*vertex) = wrkvrt.charge;
324  vsi_isFakeAcc(*vertex) = 0;
325 
326  static const SG::Accessor<float> vsi_twoCirc_drAcc("vsi_twoCirc_dr");
327  static const SG::Accessor<float> vsi_twoCirc_dphiAcc("vsi_twoCirc_dphi");
328  static const SG::Accessor<float> vsi_twoCirc_int_rAcc("vsi_twoCirc_int_r");
329  static const SG::Accessor<float> vsi_vrtFast_rAcc("vsi_vrtFast_r");
330  static const SG::Accessor<float> vsi_vrtFast_etaAcc("vsi_vrtFast_eta");
331  static const SG::Accessor<float> vsi_vrtFast_phiAcc("vsi_vrtFast_phi");
332  static const SG::Accessor< std::vector<float> > vsi_vrtFast_trkd0Acc("vsi_vrtFast_trkd0");
333  static const SG::Accessor< std::vector<float> > vsi_vrtFast_trkz0Acc("vsi_vrtFast_trkz0");
334  static const SG::Accessor<float> vsi_vrtFit_rAcc("vsi_vrtFit_r");
335  static const SG::Accessor<float> vsi_vrtFit_chi2Acc("vsi_vrtFit_chi2");
336  static const SG::Accessor<float> vsi_vPosAcc("vsi_vPos");
337  static const SG::Accessor<float> vsi_vPosMomAngTAcc("vsi_vPosMomAngT");
338  static const SG::Accessor<float> vsi_dphi1Acc("vsi_dphi1");
339  static const SG::Accessor<float> vsi_dphi2Acc("vsi_dphi2");
340  static const SG::Accessor<char> vsi_isPassMMVAcc("vsi_isPassMMV");
341  vsi_twoCirc_drAcc(*vertex) = wrkvrt.param.twoCirc_dr;
342  vsi_twoCirc_dphiAcc(*vertex) = wrkvrt.param.twoCirc_dphi;
343  vsi_twoCirc_int_rAcc(*vertex) = wrkvrt.param.twoCirc_int_r;
344  vsi_vrtFast_rAcc(*vertex) = wrkvrt.param.vrtFast_r;
345  vsi_vrtFast_etaAcc(*vertex) = wrkvrt.param.vrtFast_eta;
346  vsi_vrtFast_phiAcc(*vertex) = wrkvrt.param.vrtFast_phi;
347  vsi_vrtFast_trkd0Acc(*vertex) = wrkvrt.param.vrtFast_trkd0;
348  vsi_vrtFast_trkz0Acc(*vertex) = wrkvrt.param.vrtFast_trkz0;
349  vsi_vrtFit_rAcc(*vertex) = wrkvrt.vertex.perp();
350  vsi_vrtFit_chi2Acc(*vertex) = wrkvrt.chi2;
351  vsi_vPosAcc(*vertex) = wrkvrt.param.vPos;
352  vsi_vPosMomAngTAcc(*vertex) = wrkvrt.param.vPosMomAngT;
353  vsi_dphi1Acc(*vertex) = wrkvrt.param.dphi1;
354  vsi_dphi2Acc(*vertex) = wrkvrt.param.dphi2;
355  vsi_isPassMMVAcc(*vertex) = wrkvrt.param.isPassMMV ? 1 : 0;
356 
357  static const SG::Accessor<char> vsi_trkd0cutAcc("vsi_trkd0cut");
358  static const SG::Accessor<char> vsi_twoCircErrcutAcc("vsi_twoCircErrcut");
359  static const SG::Accessor<char> vsi_twoCircRcutAcc("vsi_twoCircRcut");
360  static const SG::Accessor<char> vsi_fastErrcutAcc("vsi_fastErrcut");
361  static const SG::Accessor<char> vsi_fastRcutAcc("vsi_fastRcut");
362  static const SG::Accessor<char> vsi_fitErrcutAcc("vsi_fitErrcut");
363  static const SG::Accessor<char> vsi_chi2cutAcc("vsi_chi2cut");
364  vsi_trkd0cutAcc(*vertex) = wrkvrt.cuts.trkd0cut ? 1 : 0;
365  vsi_twoCircErrcutAcc(*vertex) = wrkvrt.cuts.twoCircErrcut ? 1 : 0;
366  vsi_twoCircRcutAcc(*vertex) = wrkvrt.cuts.twoCircRcut ? 1 : 0;
367  vsi_fastErrcutAcc(*vertex) = wrkvrt.cuts.fastErrcut ? 1 : 0;
368  vsi_fastRcutAcc(*vertex) = wrkvrt.cuts.fastRcut ? 1 : 0;
369  vsi_fitErrcutAcc(*vertex) = wrkvrt.cuts.fitErrcut ? 1 : 0;
370  vsi_chi2cutAcc(*vertex) = wrkvrt.cuts.chi2cut ? 1 : 0;
371 
372  }
373  //
374  return StatusCode::SUCCESS;
375 }

◆ filterPassed()

virtual bool AthReentrantAlgorithm::filterPassed ( const EventContext &  ctx) const
inlinevirtualinherited

Definition at line 135 of file AthReentrantAlgorithm.h.

135  {
136  return execState( ctx ).filterPassed();
137  }

◆ finalize()

StatusCode TrigVSI::TrigVrtSecInclusive::finalize ( )
overridevirtual

Definition at line 1585 of file TrigVrtSecInclusive.cxx.

1586 {
1587  return StatusCode::SUCCESS;
1588 }

◆ findDiTrackVertex()

StatusCode TrigVSI::TrigVrtSecInclusive::findDiTrackVertex ( WrkVrtContainer workVerticesContainer,
std::vector< std::pair< size_t, size_t >> &  incomp,
std::vector< const xAOD::TrackParticle * > &  selectedTracks,
const EventContext &  ctx,
const xAOD::Vertex primVertex 
) const
private

Definition at line 378 of file TrigVrtSecInclusive.cxx.

380 {
381  // monitoring
382  auto timerTwoCircIntsect = Monitored::Timer<std::chrono::nanoseconds> ("TIME_TwoCircIntsect");
383  auto timerVrtFitFast = Monitored::Timer<std::chrono::nanoseconds> ("TIME_VrtFitFast");
384  auto timerVrtFit = Monitored::Timer<std::chrono::microseconds>("TIME_VrtFit");
385 
386  std::vector<float> mnt_pair_dphi;
387  std::vector<float> mnt_pair_dr;
388  std::vector<float> mnt_intersect_r;
389  std::vector<float> mnt_init_r;
390  std::vector<float> mnt_init_trkd0;
391  std::vector<float> mnt_init_trkz0;
392  std::vector<float> mnt_vtxfit_chi2;
393  std::vector<float> mnt_vtxfit_r;
394  std::vector<float> mnt_vtx_chi2;
395  std::vector<float> mnt_vtx_mass;
396  std::vector<float> mnt_vtx_mass_high;
397  std::vector<float> mnt_vtx_pt;
398  std::vector<float> mnt_vtx_charge;
399  std::vector<float> mnt_vtx_r;
400  auto mon_pair_dphi = Monitored::Collection("pair_dphi", mnt_pair_dphi);
401  auto mon_pair_dr = Monitored::Collection("pair_dr", mnt_pair_dr);
402  auto mon_intersect_r = Monitored::Collection("intersect_r", mnt_intersect_r);
403  auto mon_init_r = Monitored::Collection("init_r", mnt_init_r);
404  auto mon_init_trkd0 = Monitored::Collection("init_trkd0", mnt_init_trkd0);
405  auto mon_init_trkz0 = Monitored::Collection("init_trkz0", mnt_init_trkz0);
406  auto mon_vtxfit_chi2 = Monitored::Collection("vtxfit_chi2", mnt_vtxfit_chi2);
407  auto mon_vtxfit_r = Monitored::Collection("vtxfit_r", mnt_vtxfit_r);
408  auto mon_vtx_chi2 = Monitored::Collection("vtx_chi2", mnt_vtx_chi2);
409  auto mon_vtx_mass = Monitored::Collection("vtx_mass", mnt_vtx_mass);
410  auto mon_vtx_mass_high= Monitored::Collection("vtx_mass_high",mnt_vtx_mass);
411  auto mon_vtx_pt = Monitored::Collection("vtx_pt", mnt_vtx_pt);
412  auto mon_vtx_charge = Monitored::Collection("vtx_charge", mnt_vtx_charge);
413  auto mon_vtx_r = Monitored::Collection("vtx_r", mnt_vtx_r);
414  auto monVertex = Monitored::Group(m_monTool, mon_pair_dphi, mon_pair_dr, mon_intersect_r, mon_init_r, mon_init_trkd0, mon_init_trkz0, mon_vtxfit_chi2, mon_vtxfit_r,
415  mon_vtx_chi2,mon_vtx_mass,mon_vtx_mass_high,mon_vtx_pt,mon_vtx_charge,mon_vtx_r);
416 
417  // vertexing
418  unsigned int nPairsAll = 0;
419  unsigned int nPairsTrkd0 = 0;
420  unsigned int nPairsIntersect = 0;
421  unsigned int nPairsIntersectPos = 0;
422  unsigned int nPairsInitPos = 0;
423  unsigned int nPairsInitTrkd0z0 = 0;
424  unsigned int nPairsVtxFit = 0;
425  unsigned int nPairsVtxChi2 = 0;
426  unsigned int nPairsVtxComp = 0;
427  unsigned int nPairsVtxMatveto = 0;
428 
429  for( auto itrkIter = selectedTracks.begin(); itrkIter != selectedTracks.end(); ++itrkIter ) {
430  const xAOD::TrackParticle* itrk = *itrkIter;
431  for( auto jtrkIter = std::next(itrkIter); jtrkIter != selectedTracks.end(); ++jtrkIter ) { // for starts from here
432  const xAOD::TrackParticle* jtrk = *jtrkIter;
433  nPairsAll++;
434 
435  auto monTimeStep = Monitored::Group(m_monTool, timerTwoCircIntsect, timerVrtFitFast, timerVrtFit);
436 
437  //
438  const int itrk_id = std::distance(selectedTracks.begin(), itrkIter);
439  const int jtrk_id = std::distance(selectedTracks.begin(), jtrkIter);
440 
441  WrkVrt::AlgCuts wrkcuts;
442  WrkVrt::AlgParam wrkprm;
443  WrkVrt wrkvrt;
444 
445  // Set track indices
446  wrkvrt.selectedTrackIndices().clear();
447  wrkvrt.selectedTrackIndices().emplace_back(itrk_id);
448  wrkvrt.selectedTrackIndices().emplace_back(jtrk_id);
449 
450  // trk d0
451  wrkcuts.trkd0cut = std::abs( itrk->d0() ) < m_twoTrkVtxFormingD0Cut && std::abs( jtrk->d0() ) < m_twoTrkVtxFormingD0Cut;
452  nPairsTrkd0++;
453 
454  // Attempt to think the combination is incompatible by default
455  incomp.emplace_back( std::pair<size_t, size_t>(itrk_id, jtrk_id) );
456 
457  // two circles intersection
458  const Trk::Perigee& perigee1 = itrk->perigeeParameters();
459  const Trk::Perigee& perigee2 = jtrk->perigeeParameters();
460  int flag = 0;
461  int errorcode = 0;
463  timerTwoCircIntsect.start();
464  Amg::Vector3D circIntersect = m_vertexPointEstimator->getCirclesIntersectionPoint(&perigee1, &perigee2, flag, errorcode, decors);
465  timerTwoCircIntsect.stop();
466  if (errorcode != 0) {
467  ATH_MSG_VERBOSE( ": two circles intersect failed");
468  wrkcuts.twoCircErrcut = true;
469  wrkvrt.param = wrkprm;
470  wrkvrt.cuts = wrkcuts;
471  wrkvrt.isPair = true;
472 
473  workVerticesContainer.push_back( std::move(wrkvrt) );
474  continue;
475  }
476  float dphi = std::abs(decors["deltaPhiTracks"]);
477  float dr = std::abs(decors["DR1R2"]);
478  float intersect_r = circIntersect.perp();
479  mnt_pair_dphi.push_back(dphi);
480  mnt_pair_dr.push_back(dr);
481  mnt_intersect_r.push_back(intersect_r);
482 
483  wrkprm.twoCirc_dphi = dphi;
484  wrkprm.twoCirc_dr = dr;
485  wrkprm.twoCirc_int_r = intersect_r;
486 
487  nPairsIntersect++;
488  wrkcuts.twoCircRcut = intersect_r > m_maxR;
489  if (m_doTwoCircRCut && intersect_r > m_maxR) continue;
490  nPairsIntersectPos++;
491 
492  // initial fast fitting
493  std::vector<const xAOD::TrackParticle*> baseTracks;
494  baseTracks.emplace_back( itrk );
495  baseTracks.emplace_back( jtrk );
496  Amg::Vector3D initVertex;
497 
498  timerVrtFitFast.start();
499  auto fitterState = m_fitSvc->makeState(ctx);
500  m_fitSvc->setApproximateVertex( circIntersect.x(), circIntersect.y(), circIntersect.z(), *fitterState );
501 
502  StatusCode sc = m_fitSvc->VKalVrtFitFast( baseTracks, initVertex, *fitterState );
503  timerVrtFitFast.stop();
504  if( sc.isFailure() ) {
505  ATH_MSG_VERBOSE( ": fast crude estimation fails ");
506  wrkcuts.fastErrcut = true;
507  wrkvrt.param = wrkprm;
508  wrkvrt.cuts = wrkcuts;
509  wrkvrt.isPair = true;
510 
511  workVerticesContainer.push_back( std::move(wrkvrt) );
512  continue;
513  }
514 
515  // position of initial fast fitting
516  mnt_init_r.push_back(initVertex.perp());
517  wrkprm.vrtFast_r = initVertex.perp();
518  wrkprm.vrtFast_eta = initVertex.eta();
519  wrkprm.vrtFast_phi = initVertex.phi();
520 
521  wrkcuts.fastRcut = initVertex.perp() > m_maxR;
522  if( m_doFastRCut && initVertex.perp() > m_maxR ) continue;
523  nPairsInitPos++;
524 
525  // impact parameter on initial fast fitting
526  std::vector<double> impactParameters;
527  std::vector<double> impactParErrors;
528  if( ! m_fitSvc->VKalGetImpact(itrk, initVertex, static_cast<int>( itrk->charge() ), impactParameters, impactParErrors) ) continue;
529  const auto roughD0_itrk = impactParameters.at(TrkParameter::k_d0);
530  const auto roughZ0_itrk = impactParameters.at(TrkParameter::k_z0);
531  mnt_init_trkd0.push_back(std::abs(roughD0_itrk));
532  mnt_init_trkz0.push_back(std::abs(roughZ0_itrk));
533  wrkprm.vrtFast_trkd0.push_back(std::abs(roughD0_itrk));
534  wrkprm.vrtFast_trkz0.push_back(std::abs(roughZ0_itrk));
535 
536  if( ! m_fitSvc->VKalGetImpact(jtrk, initVertex, static_cast<int>( jtrk->charge() ), impactParameters, impactParErrors) ) continue;
537  const auto roughD0_jtrk = impactParameters.at(TrkParameter::k_d0);
538  const auto roughZ0_jtrk = impactParameters.at(TrkParameter::k_z0);
539  mnt_init_trkd0.push_back(std::abs(roughD0_jtrk));
540  mnt_init_trkz0.push_back(std::abs(roughZ0_jtrk));
541  wrkprm.vrtFast_trkd0.push_back(std::abs(roughD0_jtrk));
542  wrkprm.vrtFast_trkz0.push_back(std::abs(roughZ0_jtrk));
543 
544  if ( std::min(roughD0_itrk, roughD0_jtrk) > m_fastD0minCut || std::abs(roughD0_itrk - roughD0_jtrk) > m_fastD0deltaCut ) continue;
545  if ( std::min(roughZ0_itrk, roughZ0_jtrk) > m_fastZ0minCut || std::abs(roughZ0_itrk - roughZ0_jtrk) > m_fastZ0deltaCut ) continue;
546 
547  nPairsInitTrkd0z0++;
548 
549  // Vertex VKal Fitting
550  std::vector<const xAOD::NeutralParticle*> dummyNeutrals;
551  timerVrtFit.start();
552  m_fitSvc->setApproximateVertex( initVertex.x(), initVertex.y(), initVertex.z(), *fitterState );
553  sc = m_fitSvc->VKalVrtFit( baseTracks,
554  dummyNeutrals,
555  wrkvrt.vertex, wrkvrt.vertexMom, wrkvrt.charge,
556  wrkvrt.vertexCov, wrkvrt.chi2PerTrk,
557  wrkvrt.trkAtVrt, wrkvrt.chi2, *fitterState, false );
558  timerVrtFit.stop();
559  if( sc.isFailure() ) {
560  wrkcuts.fitErrcut = true;
561  wrkvrt.param = wrkprm;
562  wrkvrt.cuts = wrkcuts;
563  wrkvrt.isPair = true;
564 
565  workVerticesContainer.push_back( std::move(wrkvrt) );
566  continue;
567  }
568  nPairsVtxFit++;
569 
570  // Chi2 cut
571  mnt_vtxfit_chi2.push_back(wrkvrt.chi2);
572  if( wrkvrt.chi2 > m_selVrtChi2Cut) {
573  ATH_MSG_VERBOSE( ": failed to pass chi2 threshold." );
574  wrkcuts.chi2cut = true;
575  wrkvrt.param = wrkprm;
576  wrkvrt.cuts = wrkcuts;
577  wrkvrt.isPair = true;
578 
579  workVerticesContainer.push_back( std::move(wrkvrt) );
580  continue;
581  }
582  nPairsVtxChi2++;
583  mnt_vtxfit_r.push_back(wrkvrt.vertex.perp());
584 
585  // Compatibility to the primary vertex
586  Amg::Vector3D vDist = (primVertex!=nullptr)? wrkvrt.vertex - primVertex->position() : wrkvrt.vertex;
587  const double vPos = ( vDist.x()*wrkvrt.vertexMom.Px()+vDist.y()*wrkvrt.vertexMom.Py()+vDist.z()*wrkvrt.vertexMom.Pz() )/wrkvrt.vertexMom.Rho();
588  const double vPosMomAngT = ( vDist.x()*wrkvrt.vertexMom.Px()+vDist.y()*wrkvrt.vertexMom.Py() ) / vDist.perp() / wrkvrt.vertexMom.Pt();
589 
590  double dphi1 = vDist.phi() - itrk->phi(); while( dphi1 > TMath::Pi() ) { dphi1 -= TMath::TwoPi(); } while( dphi1 < -TMath::Pi() ) { dphi1 += TMath::TwoPi(); }
591  double dphi2 = vDist.phi() - jtrk->phi(); while( dphi2 > TMath::Pi() ) { dphi2 -= TMath::TwoPi(); } while( dphi2 < -TMath::Pi() ) { dphi2 += TMath::TwoPi(); }
592 
593  wrkprm.vPos = vPos;
594  wrkprm.vPosMomAngT = vPosMomAngT;
595  wrkprm.dphi1 = dphi1;
596  wrkprm.dphi2 = dphi2;
597 
599 
600  if( std::cos( dphi1 ) < m_dphiPVCut && std::cos( dphi2 ) < m_dphiPVCut ) {
601  ATH_MSG_DEBUG( ": failed to pass the vPos cut. (both tracks are opposite against the vertex pos)" );
602  continue;
603  }
604  if( vPosMomAngT < m_dphiPVCut ) {
605  ATH_MSG_DEBUG( ": failed to pass the vPos cut. (pos-mom directions are opposite)" );
606  continue;
607  }
608 
609  if( vPos < m_pvCompatibilityCut ) {
610  ATH_MSG_DEBUG( ": failed to pass the vPos cut." );
611  continue;
612  }
613 
614  }
615  nPairsVtxComp++;
616 
617  // material map veto
618  wrkprm.isPassMMV = true;
619  if (m_doMaterialMapVeto) {
620  if (wrkvrt.vertex.perp() > 150) {
621  wrkprm.isPassMMV = ( m_materialMapOuter->GetBinContent(m_materialMapOuter->FindFixBin( wrkvrt.vertex.perp(), wrkvrt.vertex.phi(), wrkvrt.vertex.z() ) ) == 0);
622  }
623  else {
624  const TMatrixT<double>& mmm = *m_materialMapMatrix;
625  for (int i=0;i<5;i++){
626  if (wrkvrt.vertex.perp() < mmm[i][0]) {
627  float test_x = wrkvrt.vertex.x() + mmm[i][1];
628  float test_y = wrkvrt.vertex.y() + mmm[i][2];
629  double calc_phi = std::fmod( TMath::ATan2(test_y,test_x),TMath::Pi()/mmm[i][3] );
630  if (calc_phi <0) calc_phi = calc_phi + TMath::Pi()/mmm[i][3];
631  wrkprm.isPassMMV = ( m_materialMapInner->GetBinContent(m_materialMapInner->FindFixBin(sqrt(test_x*test_x + test_y*test_y), calc_phi, wrkvrt.vertex.z() ) ) == 0);
632  }
633  }
634  }
635  if( ! wrkprm.isPassMMV ) continue;
636  }
637  nPairsVtxMatveto++;
638 
639  // Now this vertex passed all criteria and considred to be a compatible vertices.
640  // Therefore the track pair is removed from the incompatibility list.
641  if (wrkcuts.isFullPass()) incomp.pop_back();
642 
643  wrkvrt.param = wrkprm;
644  wrkvrt.cuts = wrkcuts;
645  wrkvrt.isGood = true;
646  wrkvrt.isPair = true;
647 
648  workVerticesContainer.push_back( std::move(wrkvrt) );
649  }
650  }
651  ATH_MSG_DEBUG("Of " << nPairsAll << " pairs : trkd0" << " / " << "intersect" << " / " << "intersectPos" << " / " << "initPos" << " / " << "initD0Z0" << " / " << "vtxFit" << " / " << "vtxChi2" << " / " << "vtxComp" << " / " << "matVeto = "
652  << nPairsTrkd0 << " / " << nPairsIntersect << " / " << nPairsIntersectPos << " / " << nPairsInitPos << " / " << nPairsInitTrkd0z0 << " / " << nPairsVtxFit << " / " << nPairsVtxChi2 << " / " << nPairsVtxComp << " / " << nPairsVtxMatveto);
653  //
654  return StatusCode::SUCCESS;
655 }

◆ findDiTrackVertexVSI()

StatusCode TrigVSI::TrigVrtSecInclusive::findDiTrackVertexVSI ( WrkVrtContainer workVerticesContainer,
std::vector< std::pair< size_t, size_t >> &  incomp,
std::vector< const xAOD::TrackParticle * > &  selectedTracks,
const EventContext &  ctx,
const xAOD::Vertex primVertex 
) const
private

Definition at line 658 of file TrigVrtSecInclusive.cxx.

660 {
661  // monitoring
662  auto timerTwoCircIntsect = Monitored::Timer<std::chrono::nanoseconds> ("TIME_TwoCircIntsect");
663  auto timerVrtFitFast = Monitored::Timer<std::chrono::nanoseconds> ("TIME_VrtFitFast");
664  auto timerVrtFit = Monitored::Timer<std::chrono::microseconds>("TIME_VrtFit");
665 
666  std::vector<float> mnt_pair_dphi;
667  std::vector<float> mnt_pair_dr;
668  std::vector<float> mnt_intersect_r;
669  std::vector<float> mnt_init_r;
670  std::vector<float> mnt_init_trkd0;
671  std::vector<float> mnt_init_trkz0;
672  std::vector<float> mnt_vtxfit_chi2;
673  std::vector<float> mnt_vtxfit_r;
674  std::vector<float> mnt_vtx_chi2;
675  std::vector<float> mnt_vtx_mass;
676  std::vector<float> mnt_vtx_mass_high;
677  std::vector<float> mnt_vtx_pt;
678  std::vector<float> mnt_vtx_charge;
679  std::vector<float> mnt_vtx_r;
680  auto mon_pair_dphi = Monitored::Collection("pair_dphi", mnt_pair_dphi);
681  auto mon_pair_dr = Monitored::Collection("pair_dr", mnt_pair_dr);
682  auto mon_intersect_r = Monitored::Collection("intersect_r", mnt_intersect_r);
683  auto mon_init_r = Monitored::Collection("init_r", mnt_init_r);
684  auto mon_init_trkd0 = Monitored::Collection("init_trkd0", mnt_init_trkd0);
685  auto mon_init_trkz0 = Monitored::Collection("init_trkz0", mnt_init_trkz0);
686  auto mon_vtxfit_chi2 = Monitored::Collection("vtxfit_chi2", mnt_vtxfit_chi2);
687  auto mon_vtxfit_r = Monitored::Collection("vtxfit_r", mnt_vtxfit_r);
688  auto mon_vtx_chi2 = Monitored::Collection("vtx_chi2", mnt_vtx_chi2);
689  auto mon_vtx_mass = Monitored::Collection("vtx_mass", mnt_vtx_mass);
690  auto mon_vtx_mass_high= Monitored::Collection("vtx_mass_high",mnt_vtx_mass);
691  auto mon_vtx_pt = Monitored::Collection("vtx_pt", mnt_vtx_pt);
692  auto mon_vtx_charge = Monitored::Collection("vtx_charge", mnt_vtx_charge);
693  auto mon_vtx_r = Monitored::Collection("vtx_r", mnt_vtx_r);
694  auto monVertex = Monitored::Group(m_monTool, mon_pair_dphi, mon_pair_dr, mon_intersect_r, mon_init_r, mon_init_trkd0, mon_init_trkz0, mon_vtxfit_chi2, mon_vtxfit_r,
695  mon_vtx_chi2,mon_vtx_mass,mon_vtx_mass_high,mon_vtx_pt,mon_vtx_charge,mon_vtx_r);
696 
697  // vertexing
698  const double roughD0Cut{ 100. };
699  const double roughZ0Cut{ 50. };
700 
701  unsigned int nPairsAll = 0;
702  unsigned int nPairsTrkd0 = 0;
703  unsigned int nPairsIntersect = 0;
704  unsigned int nPairsIntersectPos = 0;
705  unsigned int nPairsInitPos = 0;
706  unsigned int nPairsInitTrkd0z0 = 0;
707  unsigned int nPairsVtxFit = 0;
708  unsigned int nPairsVtxChi2 = 0;
709  unsigned int nPairsVtxComp = 0;
710 
711  for( auto itrkIter = selectedTracks.begin(); itrkIter != selectedTracks.end(); ++itrkIter ) {
712  const xAOD::TrackParticle* itrk = *itrkIter;
713  for( auto jtrkIter = std::next(itrkIter); jtrkIter != selectedTracks.end(); ++jtrkIter ) { // for starts from here
714  const xAOD::TrackParticle* jtrk = *jtrkIter;
715  nPairsAll++;
716 
717  auto monTimeStep = Monitored::Group(m_monTool, timerTwoCircIntsect, timerVrtFitFast, timerVrtFit);
718 
719  //
720  const int itrk_id = std::distance(selectedTracks.begin(), itrkIter);
721  const int jtrk_id = std::distance(selectedTracks.begin(), jtrkIter);
722 
723  WrkVrt::AlgCuts wrkcuts;
724  WrkVrt::AlgParam wrkprm;
725  WrkVrt wrkvrt;
726 
727  // Set track indices
728  wrkvrt.selectedTrackIndices().clear();
729  wrkvrt.selectedTrackIndices().emplace_back(itrk_id);
730  wrkvrt.selectedTrackIndices().emplace_back(jtrk_id);
731 
732  // trk d0
733  if( std::abs( itrk->d0() ) < m_twoTrkVtxFormingD0Cut && std::abs( jtrk->d0() ) < m_twoTrkVtxFormingD0Cut ) continue;
734  nPairsTrkd0++;
735 
736  // Attempt to think the combination is incompatible by default
737  incomp.emplace_back( std::pair<size_t, size_t>(itrk_id, jtrk_id) );
738 
739  // two circles intersection
740  const Trk::Perigee& perigee1 = itrk->perigeeParameters();
741  const Trk::Perigee& perigee2 = jtrk->perigeeParameters();
742  int flag = 0;
743  int errorcode = 0;
745  timerTwoCircIntsect.start();
746  Amg::Vector3D circIntersect = m_vertexPointEstimator->getCirclesIntersectionPoint(&perigee1, &perigee2, flag, errorcode, decors);
747  timerTwoCircIntsect.stop();
748  if (errorcode != 0) {
749  ATH_MSG_VERBOSE( ": two circles intersect failed");
750  wrkcuts.twoCircErrcut = true;
751  wrkvrt.param = wrkprm;
752  wrkvrt.cuts = wrkcuts;
753  wrkvrt.isPair = true;
754 
755  workVerticesContainer.push_back( std::move(wrkvrt) );
756  continue;
757  }
758  float dphi = std::abs(decors["deltaPhiTracks"]);
759  float dr = std::abs(decors["DR1R2"]);
760  float intersect_r = circIntersect.perp();
761  mnt_pair_dphi.push_back(dphi);
762  mnt_pair_dr.push_back(dr);
763  mnt_intersect_r.push_back(intersect_r);
764 
765  wrkprm.twoCirc_dphi = dphi;
766  wrkprm.twoCirc_dr = dr;
767  wrkprm.twoCirc_int_r = intersect_r;
768 
769  nPairsIntersect++;
770  wrkcuts.twoCircRcut = intersect_r > m_maxR;
771  nPairsIntersectPos++;
772 
773  // initial fast fitting
774  std::vector<const xAOD::TrackParticle*> baseTracks;
775  baseTracks.emplace_back( itrk );
776  baseTracks.emplace_back( jtrk );
777  Amg::Vector3D initVertex;
778  timerVrtFitFast.start();
779  auto fitterState = m_fitSvc->makeState(ctx);
780  m_fitSvc->setApproximateVertex( 0., 0., 0., *fitterState );
781  StatusCode sc = m_fitSvc->VKalVrtFitFast( baseTracks, initVertex, *fitterState );
782  timerVrtFitFast.stop();
783  if( sc.isFailure() ) {
784  ATH_MSG_VERBOSE( ": fast crude estimation fails ");
785  wrkcuts.fastErrcut = true;
786  wrkvrt.param = wrkprm;
787  wrkvrt.cuts = wrkcuts;
788  wrkvrt.isPair = true;
789 
790  workVerticesContainer.push_back( std::move(wrkvrt) );
791  continue;
792  }
793 
794  // position of initial fast fitting
795  mnt_init_r.push_back(initVertex.perp());
796  wrkprm.vrtFast_r = initVertex.perp();
797  wrkprm.vrtFast_eta = initVertex.eta();
798  wrkprm.vrtFast_phi = initVertex.phi();
799  wrkcuts.fastRcut = initVertex.perp() > m_maxR;
800 
801  nPairsInitPos++;
802 
803  // impact parameter on initial fast fitting
804  std::vector<double> impactParameters;
805  std::vector<double> impactParErrors;
806  if( ! m_fitSvc->VKalGetImpact(itrk, initVertex, static_cast<int>( itrk->charge() ), impactParameters, impactParErrors) ) continue;
807  const auto roughD0_itrk = impactParameters.at(TrkParameter::k_d0);
808  const auto roughZ0_itrk = impactParameters.at(TrkParameter::k_z0);
809  mnt_init_trkd0.push_back(std::abs(roughD0_itrk));
810  mnt_init_trkz0.push_back(std::abs(roughZ0_itrk));
811  wrkprm.vrtFast_trkd0.push_back(std::abs(roughD0_itrk));
812  wrkprm.vrtFast_trkz0.push_back(std::abs(roughZ0_itrk));
813  if( std::abs(roughD0_itrk) > roughD0Cut || std::abs(roughZ0_itrk) > roughZ0Cut ) continue;
814 
815  if( ! m_fitSvc->VKalGetImpact(jtrk, initVertex, static_cast<int>( jtrk->charge() ), impactParameters, impactParErrors) ) continue;
816  const auto roughD0_jtrk = impactParameters.at(TrkParameter::k_d0);
817  const auto roughZ0_jtrk = impactParameters.at(TrkParameter::k_z0);
818  mnt_init_trkd0.push_back(std::abs(roughD0_jtrk));
819  mnt_init_trkz0.push_back(std::abs(roughZ0_jtrk));
820  wrkprm.vrtFast_trkd0.push_back(std::abs(roughD0_jtrk));
821  wrkprm.vrtFast_trkz0.push_back(std::abs(roughZ0_jtrk));
822  if( std::abs(roughD0_jtrk) > roughD0Cut || std::abs(roughZ0_jtrk) > roughZ0Cut ) continue;
823 
824  nPairsInitTrkd0z0++;
825 
826  // Vertex VKal Fitting
827  std::vector<const xAOD::NeutralParticle*> dummyNeutrals;
828  timerVrtFit.start();
829  m_fitSvc->setApproximateVertex( initVertex.x(), initVertex.y(), initVertex.z(), *fitterState );
830  sc = m_fitSvc->VKalVrtFit( baseTracks,
831  dummyNeutrals,
832  wrkvrt.vertex, wrkvrt.vertexMom, wrkvrt.charge,
833  wrkvrt.vertexCov, wrkvrt.chi2PerTrk,
834  wrkvrt.trkAtVrt, wrkvrt.chi2, *fitterState, false );
835  timerVrtFit.stop();
836  if( sc.isFailure() ) {
837  wrkcuts.fitErrcut = true;
838  wrkvrt.param = wrkprm;
839  wrkvrt.cuts = wrkcuts;
840  wrkvrt.isPair = true;
841 
842  workVerticesContainer.push_back( std::move(wrkvrt) );
843  continue;
844  }
845 
846  nPairsVtxFit++;
847 
848  // Chi2 cut
849  mnt_vtxfit_chi2.push_back(wrkvrt.chi2);
850  if( wrkvrt.chi2 > m_selVrtChi2Cut) {
851  ATH_MSG_VERBOSE( ": failed to pass chi2 threshold." );
852  wrkcuts.chi2cut = true;
853  wrkvrt.param = wrkprm;
854  wrkvrt.cuts = wrkcuts;
855  wrkvrt.isPair = true;
856 
857  workVerticesContainer.push_back( std::move(wrkvrt) );
858  continue;
859  }
860  nPairsVtxChi2++;
861  mnt_vtxfit_r.push_back(wrkvrt.vertex.perp());
862 
863  // Compatibility to the primary vertex
864  Amg::Vector3D vDist = (primVertex!=nullptr)? wrkvrt.vertex - primVertex->position() : wrkvrt.vertex;
865  const double vPos = ( vDist.x()*wrkvrt.vertexMom.Px()+vDist.y()*wrkvrt.vertexMom.Py()+vDist.z()*wrkvrt.vertexMom.Pz() )/wrkvrt.vertexMom.Rho();
866  const double vPosMomAngT = ( vDist.x()*wrkvrt.vertexMom.Px()+vDist.y()*wrkvrt.vertexMom.Py() ) / vDist.perp() / wrkvrt.vertexMom.Pt();
867 
868  double dphi1 = vDist.phi() - itrk->phi(); while( dphi1 > TMath::Pi() ) { dphi1 -= TMath::TwoPi(); } while( dphi1 < -TMath::Pi() ) { dphi1 += TMath::TwoPi(); }
869  double dphi2 = vDist.phi() - jtrk->phi(); while( dphi2 > TMath::Pi() ) { dphi2 -= TMath::TwoPi(); } while( dphi2 < -TMath::Pi() ) { dphi2 += TMath::TwoPi(); }
870 
871  wrkprm.vPos = vPos;
872  wrkprm.vPosMomAngT = vPosMomAngT;
873  wrkprm.dphi1 = dphi1;
874  wrkprm.dphi2 = dphi2;
875 
876  if( std::cos( dphi1 ) < m_dphiPVCut && std::cos( dphi2 ) < m_dphiPVCut ) {
877  ATH_MSG_DEBUG( ": failed to pass the vPos cut. (both tracks are opposite against the vertex pos)" );
878  continue;
879  }
880  if( vPosMomAngT < m_dphiPVCut ) {
881  ATH_MSG_DEBUG( ": failed to pass the vPos cut. (pos-mom directions are opposite)" );
882  continue;
883  }
884  if( vPos < m_pvCompatibilityCut ) {
885  ATH_MSG_DEBUG( ": failed to pass the vPos cut." );
886  continue;
887  }
888  nPairsVtxComp++;
889 
890  // Now this vertex passed all criteria and considred to be a compatible vertices.
891  // Therefore the track pair is removed from the incompatibility list.
892  if (wrkcuts.isFullPass()) incomp.pop_back();
893 
894  wrkvrt.param = wrkprm;
895  wrkvrt.cuts = wrkcuts;
896  wrkvrt.isGood = true;
897  wrkvrt.isPair = true;
898 
899  workVerticesContainer.push_back( std::move(wrkvrt) );
900  }
901  }
902  ATH_MSG_DEBUG("Of " << nPairsAll << " pairs : trkd0" << " / " << "intersect" << " / " << "intersectPos" << " / " << "initPos" << " / " << "initD0Z0" << " / " << "vtxFit" << " / " << "vtxChi2" << " / " << "vtxComp = "
903  << nPairsTrkd0 << " / " << nPairsIntersect << " / " << nPairsIntersectPos << " / " << nPairsInitPos << " / " << nPairsInitTrkd0z0 << " / " << nPairsVtxFit << " / " << nPairsVtxChi2 << " / " << nPairsVtxComp );
904  //
905  return StatusCode::SUCCESS;
906 }

◆ findNTrackVertex()

template<typename VrtType , typename Coord >
template StatusCode TrigVSI::TrigVrtSecInclusive::findNTrackVertex ( WrkVrtContainer ,
TrigVSI::VtxMap< VrtType, Coord > &  ,
const std::vector< const xAOD::TrackParticle * > &  ,
const EventContext &   
) const
private

Definition at line 1150 of file TrigVrtSecInclusive.cxx.

1152 {
1153  ATH_MSG_DEBUG( "findNTrackVertex start" );
1154 
1155  // monitoring
1156  auto timerRetrvFromMap = Monitored::Timer<std::chrono::nanoseconds> ("TIME_RetrvFromMap");
1157  auto timerMergeParGraph = Monitored::Timer<std::chrono::microseconds> ("TIME_MergeParGraph");
1158  auto timerMergeSimple = Monitored::Timer<std::chrono::microseconds> ("TIME_MergeSimple");
1159 
1160  size_t n_clst = vtxmap.nClusters();
1161  size_t n_vtx_pargraph = 0;
1162  size_t n_vtx_simple = 0;
1163 
1164  for (size_t i_clst = 0; i_clst < n_clst; i_clst++) {
1165  auto monTimeClust = Monitored::Group(m_monTool, timerRetrvFromMap, timerMergeParGraph, timerMergeSimple);
1166  timerRetrvFromMap.start();
1167 
1168  ATH_MSG_DEBUG( "Retrieve cluster, track indices and incompatible pairs" );
1169 
1170  auto clst = vtxmap.getCluster(i_clst);
1171  auto selected_track_indices = clst.getSelectedTrackIndices();
1172  auto incomp = clst.getIncompIndices();
1173 
1174  ATH_MSG_DEBUG( "Convert set to vector" );
1175 
1176  std::vector<size_t> v_track_indices( selected_track_indices.begin(), selected_track_indices.end() );
1177 
1178  timerRetrvFromMap.stop();
1179 
1180  ATH_MSG_DEBUG( "Cluster number : " << i_clst << " | " << incomp.size() << " incompatible pairs | " << v_track_indices.size() << " tracks" );
1181  ATH_MSG_DEBUG( "Pos avr : ( R: " << clst.PosCoord().at(0) << ", eta: " << clst.PosCoord().at(1) << ", phi: " << clst.PosCoord().at(2) << " )" );
1182  ATH_MSG_DEBUG( "Number of cells : " << clst.nPoints() );
1183 
1184  if ( v_track_indices.size() > m_maxTrks ) {
1185  ATH_MSG_DEBUG( "Skipped the cluster. Too many tracks" );
1186  continue;
1187  }
1188 
1189  if ( clst.nVtx() >= m_minTrkPairsMerge || selected_track_indices.size() >= m_minTrksMerge ) {
1190 
1191  timerMergeParGraph.start();
1192  ATH_CHECK( mergeVertexFromDiTrkVrt( workVerticesContainer, incomp, v_track_indices, selectedTracks, ctx ) );
1193  timerMergeParGraph.stop();
1194 
1195  n_vtx_pargraph++;
1196 
1197  } else {
1198 
1199  timerMergeSimple.start();
1200 
1201  WrkVrt wrkvrt;
1202  wrkvrt.isGood = true;
1203  wrkvrt.selectedTrackIndices().clear();
1204 
1205  for (size_t i_trk = 0; i_trk < v_track_indices.size(); i_trk++) {
1206  wrkvrt.selectedTrackIndices().emplace_back( v_track_indices.at(i_trk) );
1207  }
1208 
1209  if ( fitVertexFromTracks(wrkvrt, selectedTracks, ctx) == StatusCode::SUCCESS ) {
1210  workVerticesContainer.emplace_back( std::move(wrkvrt) );
1211  }
1212 
1213  timerMergeSimple.stop();
1214 
1215  n_vtx_simple++;
1216 
1217  }
1218 
1219  }
1220 
1221  ATH_MSG_DEBUG( "Partial graph method / Simple method / All vertex = " << n_vtx_pargraph << " / " << n_vtx_simple << " / " << n_vtx_pargraph+n_vtx_simple );
1222  return StatusCode::SUCCESS;
1223 
1224 }

◆ findNtrackVerticesVSI()

StatusCode TrigVSI::TrigVrtSecInclusive::findNtrackVerticesVSI ( WrkVrtContainer workVerticesContainer,
std::vector< std::pair< size_t, size_t >> &  incomp,
std::vector< const xAOD::TrackParticle * > &  selectedTracks,
const EventContext &  ctx 
) const
private

Definition at line 909 of file TrigVrtSecInclusive.cxx.

911 {
912  ATH_MSG_DEBUG(" > " << __FUNCTION__ << ": begin");
913 
914  const auto compSize = selectedTracks.size()*(selectedTracks.size() - 1)/2 - incomp.size();
915 
916  auto pgraph = std::make_unique<Trk::PGraph>();
917 
918  ATH_MSG_DEBUG(" > " << __FUNCTION__ << ": compatible track pair size = " << compSize );
919  ATH_MSG_DEBUG(" > " << __FUNCTION__ << ": incompatible track pair size = " << incomp.size() );
920 
921  ATH_MSG_DEBUG(" > " << __FUNCTION__ << ": incompatibility graph finder mode" );
922 
923  // clear the container
924  workVerticesContainer.clear();
925 
926  // Graph method: Trk::pgraphm_()
927  // used in order to find compatible sub-graphs from the incompatible graph
928 
929  // List of edges between incompatible nodes
930  // This weight is the data model of incompatible graph used in Trk::pgraphm_().
931  std::vector<long int> weight;
932 
933  for( auto& pair : incomp ) {
934  weight.emplace_back( pair.first + 1 ); /* +1 is needed for PGRAPH due to FORTRAN-style counting */
935  weight.emplace_back( pair.second + 1 ); /* +1 is needed for PGRAPH due to FORTRAN-style counting */
936  }
937 
938  // Solution of the graph method routine (minimal covering of the graph)
939  // The size of the solution is returned by NPTR (see below)
940  std::vector<long int> solution( selectedTracks.size() );
941 
942  // Number of edges in the list is the size of incompatibility track pairs.
943  long int nEdges = incomp.size();
944 
945  // input number of nodes in the graph.
946  long int nTracks = static_cast<long int>( selectedTracks.size() );
947 
948  // Input variable: the threshold. Solutions shorter than nth are not returned (ignored).
949  long int nth = 2; //VK some speed up
950 
951  // NPTR: I/O variable (Destructive FORTRAN Style!!!)
952  // - on input: =0 for initialization, >0 to get next solution
953  // - on output: >0 : length of the solution stored in set; =0 : no more solutions can be found
954  long int solutionSize { 0 };
955 
956  // This is just a unused strawman needed for m_fitSvc->VKalVrtFit()
957  std::vector<const xAOD::TrackParticle*> baseTracks;
958  std::vector<const xAOD::NeutralParticle*> dummyNeutrals;
959 
960  // Main iteration
961  while(true) {
962  // Find a solution from the given set of incompatible tracks (==weight)
963  pgraph->pgraphm_( weight.data(), nEdges, nTracks, solution.data(), &solutionSize, nth);
964 
965  ATH_MSG_VERBOSE(" > " << __FUNCTION__ << ": Trk::pgraphm_() output: solutionSize = " << solutionSize );
966 
967  if(solutionSize <= 0) break; // No more solutions ==> Exit
968  if(solutionSize == 1) continue; // i.e. single node ==> Not a good solution
969 
970  baseTracks.clear();
971 
972  std::string msg = "solution = [ ";
973  for( int i=0; i< solutionSize; i++) {
974  msg += Form( "%ld, ", solution[i]-1 );
975  }
976  msg += " ]";
977  ATH_MSG_DEBUG( " > " << __FUNCTION__ << ": " << msg );
978 
979  // varaible of new vertex
980  WrkVrt wrkvrt;
981 
982  // Try to compose a new vertex using the solution nodes
983  // Here the track ID is labelled with array
984  wrkvrt.isGood = true;
985  wrkvrt.selectedTrackIndices().clear();
986 
987  for(long int i = 0; i<solutionSize; i++) {
988  wrkvrt.selectedTrackIndices().emplace_back(solution[i]-1);
989  baseTracks.emplace_back( selectedTracks.at(solution[i]-1) );
990  }
991 
992  // Perform vertex fitting
993  Amg::Vector3D initVertex;
994  auto fitterState = m_fitSvc->makeState(ctx);
995 
996  StatusCode sc = m_fitSvc->VKalVrtFitFast( baseTracks, initVertex, *fitterState );/* Fast crude estimation */
997  if(sc.isFailure()) ATH_MSG_DEBUG(" > " << __FUNCTION__ << ": fast crude estimation fails ");
998 
999  m_fitSvc->setApproximateVertex( initVertex.x(), initVertex.y(), initVertex.z(), *fitterState );
1000 
1001  sc = m_fitSvc->VKalVrtFit(baseTracks, dummyNeutrals,
1002  wrkvrt.vertex,
1003  wrkvrt.vertexMom,
1004  wrkvrt.charge,
1005  wrkvrt.vertexCov,
1006  wrkvrt.chi2PerTrk,
1007  wrkvrt.trkAtVrt,
1008  wrkvrt.chi2,
1009  *fitterState, false);
1010 
1011  ATH_MSG_VERBOSE(" > " << __FUNCTION__ << ": FoundAppVrt=" << solutionSize << ", (r, z) = " << wrkvrt.vertex.perp() << ", " << wrkvrt.vertex.z() << ", chi2/ndof = " << wrkvrt.fitQuality() );
1012 
1013  if( sc.isFailure() ) {
1014 
1015  if( wrkvrt.selectedTrackIndices().size() <= 2 ) {
1016  ATH_MSG_DEBUG(" > " << __FUNCTION__ << ": VKalVrtFit failed in 2-trk solution ==> give up.");
1017  continue;
1018  }
1019 
1020  ATH_MSG_DEBUG(" > " << __FUNCTION__ << ": VKalVrtFit failed ==> retry...");
1021 
1022  WrkVrt tmp;
1023  tmp.isGood = false;
1024 
1025  // Create 2-trk vertex combination and find any compatible vertex
1026  for( auto& itrk: wrkvrt.selectedTrackIndices() ) {
1027  for( auto& jtrk: wrkvrt.selectedTrackIndices() ) {
1028  if( itrk == jtrk ) continue;
1029  if( tmp.isGood ) break;
1030 
1031  tmp.selectedTrackIndices().clear();
1032  tmp.selectedTrackIndices().emplace_back( itrk );
1033  tmp.selectedTrackIndices().emplace_back( jtrk );
1034 
1035  baseTracks.clear();
1036  baseTracks.emplace_back( selectedTracks.at( itrk ) );
1037  baseTracks.emplace_back( selectedTracks.at( jtrk ) );
1038 
1039  // Perform vertex fitting
1040  Amg::Vector3D initVertex;
1041 
1042  sc = m_fitSvc->VKalVrtFitFast( baseTracks, initVertex, *fitterState );
1043  if( sc.isFailure() ) ATH_MSG_DEBUG(" > " << __FUNCTION__ << ": fast crude estimation fails ");
1044 
1045  m_fitSvc->setApproximateVertex( initVertex.x(), initVertex.y(), initVertex.z(), *fitterState );
1046 
1047  sc = m_fitSvc->VKalVrtFit(baseTracks, dummyNeutrals,
1048  tmp.vertex,
1049  tmp.vertexMom,
1050  tmp.charge,
1051  tmp.vertexCov,
1052  tmp.chi2PerTrk,
1053  tmp.trkAtVrt,
1054  tmp.chi2,
1055  *fitterState, false);
1056 
1057  if( sc.isFailure() ) continue;
1058 
1059  tmp.isGood = true;
1060 
1061  }
1062  }
1063 
1064  if( !tmp.isGood ) {
1065  ATH_MSG_DEBUG(" > " << __FUNCTION__ << ": Did not find any viable vertex in all 2-trk combinations. Give up.");
1066  continue;
1067  }
1068 
1069  // Now, found at least one seed 2-track vertex. ==> attempt to attach other tracks
1070  for( auto& itrk: wrkvrt.selectedTrackIndices() ) {
1071 
1072  if( std::find( tmp.selectedTrackIndices().begin(), tmp.selectedTrackIndices().end(), itrk ) != tmp.selectedTrackIndices().end() ) continue;
1073 
1074  auto backup = tmp;
1075 
1076  tmp.selectedTrackIndices().emplace_back( itrk );
1077  baseTracks.clear();
1078  for( auto& jtrk : tmp.selectedTrackIndices() ) { baseTracks.emplace_back( selectedTracks.at(jtrk) ); }
1079 
1080  // Perform vertex fitting
1081  Amg::Vector3D initVertex;
1082 
1083  sc = m_fitSvc->VKalVrtFitFast( baseTracks, initVertex, *fitterState );/* Fast crude estimation */
1084  if(sc.isFailure()) ATH_MSG_DEBUG(" > " << __FUNCTION__ << ": fast crude estimation fails ");
1085 
1086  m_fitSvc->setApproximateVertex( initVertex.x(), initVertex.y(), initVertex.z(), *fitterState );
1087  sc = m_fitSvc->VKalVrtFit(baseTracks, dummyNeutrals,
1088  tmp.vertex,
1089  tmp.vertexMom,
1090  tmp.charge,
1091  tmp.vertexCov,
1092  tmp.chi2PerTrk,
1093  tmp.trkAtVrt,
1094  tmp.chi2,
1095  *fitterState, false);
1096 
1097  if( sc.isFailure() ) {
1098  tmp = backup;
1099  continue;
1100  }
1101 
1102  }
1103 
1104  wrkvrt = tmp;
1105  ATH_MSG_DEBUG(" > " << __FUNCTION__ << ": VKalVrtFit succeeded; register the vertex to the list.");
1106  wrkvrt.isGood = true;
1107  wrkvrt.closestWrkVrtIndex = std::numeric_limits<unsigned>::max();
1108  wrkvrt.closestWrkVrtValue = std::numeric_limits<double>::max();
1109  workVerticesContainer.emplace_back( wrkvrt );
1110 
1111  } else {
1112 
1113  ATH_MSG_DEBUG(" > " << __FUNCTION__ << ": VKalVrtFit succeeded; register the vertex to the list.");
1114  wrkvrt.isGood = true;
1115  wrkvrt.closestWrkVrtIndex = std::numeric_limits<unsigned>::max();
1116  wrkvrt.closestWrkVrtValue = std::numeric_limits<double>::max();
1117  workVerticesContainer.emplace_back( wrkvrt );
1118 
1119  }
1120 
1121  }
1122 
1123 
1124 
1125 
1126  if (m_truncateWrkVertices){
1127  if (workVerticesContainer.size() > m_maxWrkVertices){
1128  ATH_MSG_INFO("WrkVertex truncated. Too many vertices");
1129  workVerticesContainer.resize(m_maxWrkVertices);
1130  }
1131  }
1132 
1133  ATH_CHECK( cleanUp(workVerticesContainer) );
1134 
1135  //-Identify remaining 2-track vertices with very bad Chi2 and mass (b-tagging)
1136  ATH_MSG_VERBOSE(" > " << __FUNCTION__ << ": Identify remaining 2-track vertices with very bad Chi2 and mass (b-tagging).");
1137  for( auto& wrkvrt : workVerticesContainer ) {
1138 
1139  if( TMath::Prob( wrkvrt.chi2, wrkvrt.ndof() ) < m_improveChi2ProbThreshold ) wrkvrt.isGood = false;
1140  if( wrkvrt.selectedTrackIndices().size() != 2 ) continue;
1141  }
1142 
1143  return StatusCode::SUCCESS;
1144 
1145 }

◆ fitVertexFromTracks()

StatusCode TrigVSI::TrigVrtSecInclusive::fitVertexFromTracks ( WrkVrt wrkvrt,
const std::vector< const xAOD::TrackParticle * > &  selectedTracks,
const EventContext &  ctx 
) const
private

Reconstruct vertex from given tracks.

Parameters
[in,out]wrkvrtBase object to be fitted. This algorithm runs fitting using tracks in wrkvrt.selectedTrackIndices(). Information gained from fitting will be stored in this object.
[in]selectedTracksFull list of tracks that passed the track selection.
[in]ctxThe event context. Needed for fitting vertex and extraporate tracks.
Returns
Returns SUCCESS and set wrkvrt.isGood true when a vertex is successfully reconstructed from all of given tracks or some of them. In the case that even a seed di-track vertex can't be reconstructed, returns FAILURE and set wrkvrt.isGood false.

Definition at line 1350 of file TrigVrtSecInclusive.cxx.

1352 {
1353 
1354  std::vector<const xAOD::TrackParticle*> baseTracks;
1355  std::vector<const xAOD::NeutralParticle*> dummyNeutrals; // This is just a unused strawman needed for m_fitSvc->VKalVrtFit()
1356 
1357  baseTracks.clear();
1358 
1359  // Try to compose a new vertex using the solution nodes
1360  // Here the track ID is labelled with array
1361  wrkvrt.isGood = true;
1362 
1363  size_t n_trk = wrkvrt.selectedTrackIndices().size();
1364 
1365  for(size_t i = 0; i<n_trk; i++) {
1366  baseTracks.emplace_back( selectedTracks.at( wrkvrt.selectedTrackIndices().at(i) ) );
1367  }
1368 
1369  // Perform vertex fitting
1370  Amg::Vector3D initVertex;
1371  auto fitterState = m_fitSvc->makeState(ctx);
1372 
1373  StatusCode sc = m_fitSvc->VKalVrtFitFast( baseTracks, initVertex, *fitterState );/* Fast crude estimation */
1374  if(sc.isFailure()) ATH_MSG_DEBUG(" > " << __FUNCTION__ << ": fast crude estimation fails ");
1375 
1376  m_fitSvc->setApproximateVertex( initVertex.x(), initVertex.y(), initVertex.z(), *fitterState );
1377 
1378  sc = m_fitSvc->VKalVrtFit(baseTracks, dummyNeutrals,
1379  wrkvrt.vertex,
1380  wrkvrt.vertexMom,
1381  wrkvrt.charge,
1382  wrkvrt.vertexCov,
1383  wrkvrt.chi2PerTrk,
1384  wrkvrt.trkAtVrt,
1385  wrkvrt.chi2,
1386  *fitterState, false);
1387 
1388  ATH_MSG_VERBOSE(" > " << __FUNCTION__ << ": FoundAppVrt=" << n_trk << ", (r, z) = " << wrkvrt.vertex.perp() << ", " << wrkvrt.vertex.z() << ", chi2/ndof = " << wrkvrt.fitQuality() );
1389 
1390  if( sc.isFailure() ) {
1391 
1392  ATH_MSG_DEBUG(" > " << __FUNCTION__ << ": VKalVrtFit failed ==> retry...");
1393 
1394  WrkVrt tmp;
1395  tmp.isGood = false;
1396 
1397  // Create 2-trk vertex combination and find any compatible vertex
1398  for( auto& itrk: wrkvrt.selectedTrackIndices() ) {
1399  for( auto& jtrk: wrkvrt.selectedTrackIndices() ) {
1400  if( itrk == jtrk ) continue;
1401  if( tmp.isGood ) break;
1402 
1403  tmp.selectedTrackIndices().clear();
1404  tmp.selectedTrackIndices().emplace_back( itrk );
1405  tmp.selectedTrackIndices().emplace_back( jtrk );
1406 
1407  baseTracks.clear();
1408  baseTracks.emplace_back( selectedTracks.at( itrk ) );
1409  baseTracks.emplace_back( selectedTracks.at( jtrk ) );
1410 
1411  // Perform vertex fitting
1412  Amg::Vector3D initVertex;
1413 
1414  sc = m_fitSvc->VKalVrtFitFast( baseTracks, initVertex, *fitterState );
1415  if( sc.isFailure() ) ATH_MSG_DEBUG(" > " << __FUNCTION__ << ": fast crude estimation fails ");
1416 
1417  m_fitSvc->setApproximateVertex( initVertex.x(), initVertex.y(), initVertex.z(), *fitterState );
1418 
1419  sc = m_fitSvc->VKalVrtFit(baseTracks, dummyNeutrals,
1420  tmp.vertex,
1421  tmp.vertexMom,
1422  tmp.charge,
1423  tmp.vertexCov,
1424  tmp.chi2PerTrk,
1425  tmp.trkAtVrt,
1426  tmp.chi2,
1427  *fitterState, false);
1428 
1429  if( sc.isFailure() ) continue;
1430  if( tmp.chi2 > m_selVrtChi2Cut ) continue;
1431 
1432  tmp.isGood = true;
1433 
1434  }
1435  }
1436 
1437  if( !tmp.isGood ) {
1438  ATH_MSG_DEBUG(" > " << __FUNCTION__ << ": Did not find any viable vertex in all 2-trk combinations. Give up.");
1439  wrkvrt = std::move(tmp);
1440  return StatusCode::FAILURE;
1441  }
1442 
1443  // Now, found at least one seed 2-track vertex. ==> attempt to attach other tracks
1444  for( auto& itrk: wrkvrt.selectedTrackIndices() ) {
1445 
1446  if( std::find( tmp.selectedTrackIndices().begin(), tmp.selectedTrackIndices().end(), itrk ) != tmp.selectedTrackIndices().end() ) continue;
1447 
1448  auto backup = tmp;
1449 
1450  tmp.selectedTrackIndices().emplace_back( itrk );
1451  baseTracks.clear();
1452  for( auto& jtrk : tmp.selectedTrackIndices() ) { baseTracks.emplace_back( selectedTracks.at(jtrk) ); }
1453 
1454  // Perform vertex fitting
1455  Amg::Vector3D initVertex;
1456 
1457  sc = m_fitSvc->VKalVrtFitFast( baseTracks, initVertex, *fitterState );/* Fast crude estimation */
1458  if(sc.isFailure()) ATH_MSG_DEBUG(" > " << __FUNCTION__ << ": fast crude estimation fails ");
1459 
1460  m_fitSvc->setApproximateVertex( initVertex.x(), initVertex.y(), initVertex.z(), *fitterState );
1461  sc = m_fitSvc->VKalVrtFit(baseTracks, dummyNeutrals,
1462  tmp.vertex,
1463  tmp.vertexMom,
1464  tmp.charge,
1465  tmp.vertexCov,
1466  tmp.chi2PerTrk,
1467  tmp.trkAtVrt,
1468  tmp.chi2,
1469  *fitterState, false);
1470 
1471  if( sc.isFailure() ) {
1472  tmp = backup;
1473  continue;
1474  }
1475 
1476  }
1477 
1478  wrkvrt = std::move(tmp);
1479 
1480  }
1481 
1482  ATH_MSG_DEBUG(" > " << __FUNCTION__ << ": VKalVrtFit succeeded; register the vertex to the list.");
1483  wrkvrt.isGood = true;
1484  wrkvrt.closestWrkVrtIndex = std::numeric_limits<unsigned>::max();
1485  wrkvrt.closestWrkVrtValue = std::numeric_limits<double>::max();
1486 
1487  return StatusCode::SUCCESS;
1488 }

◆ initialize()

StatusCode TrigVSI::TrigVrtSecInclusive::initialize ( )
overridevirtual

Definition at line 38 of file TrigVrtSecInclusive.cxx.

39 {
40  // read material maps
41  if (m_doMaterialMapVeto) {
42 
44  if ( inFileName.empty()) {
45  ATH_MSG_ERROR("Cannot find material map inner file: " << m_materialMapInnerFileName);
46  return StatusCode::FAILURE;
47  }
48  std::unique_ptr<TFile> materialMapInnerFile = std::make_unique<TFile>(inFileName.c_str(), "READ");
49  if(materialMapInnerFile->IsOpen()){
50  materialMapInnerFile->GetObject(m_materialMapInnerHistName.c_str(), m_materialMapInner);
51  materialMapInnerFile->GetObject(m_materialMapInnerMatrixName.c_str(), m_materialMapMatrix);
52  if(m_materialMapInner) m_materialMapInner->SetDirectory(0);
53  }
54  materialMapInnerFile->Close();
55 
57  if ( outFileName.empty()) {
58  ATH_MSG_ERROR("Cannot find material map outer file: " << m_materialMapOuterFileName);
59  return StatusCode::FAILURE;
60  }
61  std::unique_ptr<TFile> materialMapOuterFile = std::make_unique<TFile>(outFileName.c_str(), "READ");
62  if(materialMapOuterFile->IsOpen()){
63  materialMapOuterFile->GetObject(m_materialMapOuterHistName.c_str(), m_materialMapOuter);
64  if(m_materialMapOuter) m_materialMapOuter->SetDirectory(0);
65  }
66  materialMapOuterFile->Close();
67  ATH_MSG_DEBUG("material maps are read correctly" );
68 
69  }
70 
71  // monitoring tool
72  if ( !m_monTool.empty() ) ATH_CHECK(m_monTool.retrieve());
73 
74  // vertex fitters
75  ATH_CHECK( m_fitSvc.retrieve() );
76  ATH_CHECK( m_vertexPointEstimator.retrieve() );
77 
78  // collection names
81  ATH_CHECK(m_vxCandidatesOutputName.initialize());
82  ATH_CHECK(m_trkPairOutputName.initialize());
83  ATH_CHECK(m_PrimaryVxInputName.initialize());
84 
85  //
86  ATH_MSG_INFO( "Initialization completed successfully" );
87  return StatusCode::SUCCESS;
88 }

◆ inputHandles()

virtual std::vector<Gaudi::DataHandle*> AthCommonDataStore< AthCommonMsg< Gaudi::Algorithm > >::inputHandles ( ) const
overridevirtualinherited

Return this algorithm's input handles.

We override this to include handle instances from key arrays if they have not yet been declared. See comments on updateVHKA.

◆ isClonable()

bool AthReentrantAlgorithm::isClonable ( ) const
overridevirtualinherited

◆ mergeVertexFromDiTrkVrt()

StatusCode TrigVSI::TrigVrtSecInclusive::mergeVertexFromDiTrkVrt ( TrigVrtSecInclusive::WrkVrtContainer workVerticesContainer,
const std::vector< std::pair< size_t, size_t >> &  incomp,
const std::vector< size_t > &  trkIdx,
const std::vector< const xAOD::TrackParticle * > &  selectedTracks,
const EventContext &  ctx 
) const
private

Reconstruct multi-track vertices from incompatible track pair lists.

Parameters
[out]workVerticesContainerVertex container to add reconstructed vertices.
[in]incompIncompatible track pair lists. Tracks are written in indices in the full selected track lists.
[in]trkIdxThe partial list of indices of tracks to be used in reconstruction.
[in]selectedTracksFull list of tracks that passed the track selection.
[in]ctxThe event context. Needed for fitting vertex and extraporate tracks.

Definition at line 1243 of file TrigVrtSecInclusive.cxx.

1245 {
1246 
1247  ATH_MSG_DEBUG(" > " << __FUNCTION__ << ": begin");
1248  ATH_MSG_DEBUG("TrigVrtSecInclusive::mergeVertexFromDiTrkVrt : start");
1249 
1250  // Graph method: Trk::pgraphm_()
1251  // used in order to find compatible sub-graphs from the incompatible graph
1252  auto pgraph = std::make_unique<Trk::PGraph>();
1253 
1254  std::unordered_map<size_t,size_t> dict_trk_idx;
1255  size_t n_trk = trkIdx.size(); // Dictionary: global trkId -> local trkId
1256 
1257  for (size_t i = 0; i < n_trk; i++) {
1258  dict_trk_idx.emplace( trkIdx.at(i), i );
1259  }
1260 
1261  const auto compSize = (n_trk*(n_trk - 1))/2 - incomp.size();
1262 
1263  ATH_MSG_DEBUG(" > " << __FUNCTION__ << ": compatible track pair size = " << compSize );
1264  ATH_MSG_DEBUG(" > " << __FUNCTION__ << ": incompatible track pair size = " << incomp.size() );
1265 
1266  // List of edges between incompatible nodes
1267  // This weight is the data model of incompatible graph used in Trk::pgraphm_().
1268  std::vector<long int> weight;
1269 
1270  for( auto& pair : incomp ) {
1271  weight.emplace_back( dict_trk_idx[pair.first] + 1 ); /* +1 is needed for PGRAPH due to FORTRAN-style counting */
1272  weight.emplace_back( dict_trk_idx[pair.second] + 1 ); /* +1 is needed for PGRAPH due to FORTRAN-style counting */
1273  }
1274 
1275  // Solution of the graph method routine (minimal covering of the graph)
1276  // The size of the solution is returned by NPTR (see below)
1277  std::vector<long int> solution( n_trk );
1278 
1279  // Number of edges in the list is the size of incompatibility track pairs.
1280  long int nEdges = incomp.size();
1281 
1282  // input number of nodes in the graph.
1283  long int nTracks = static_cast<long int>( n_trk );
1284 
1285  // Input variable; the threshold. Solutions shorter than nth are not returned (ignored).
1286  long int nth = 2; //VK some speed up
1287 
1288  // NPTR: I/O variable (Destructive FORTRAN Style!!!)
1289  // - on input: =0 for initialization, >0 to get next solution
1290  // - on output: >0 : length of the solution stored in set; =0 : no more solutions can be found
1291  long int solutionSize { 0 };
1292 
1293  ATH_MSG_DEBUG( "TrigVrtSecInclusive::mergeVertexFromDiTrkVrt : while loop start" );
1294 
1295  // Main iteration
1296  while(true) {
1297 
1298  // Find a solution from the given set of incompatible tracks (==weight)
1299  pgraph->pgraphm_( weight.data(), nEdges, nTracks, solution.data(), &solutionSize, nth);
1300 
1301  ATH_MSG_VERBOSE(" > " << __FUNCTION__ << ": Trk::pgraphm_() output: solutionSize = " << solutionSize );
1302  ATH_MSG_DEBUG( "TrigVrtSecInclusive::mergeVertexFromDiTrkVrt : Trk::pgraphm_() output: solutionSize = " << solutionSize );
1303 
1304  if(solutionSize <= 0) break; // No more solutions ==> Exit
1305  if(solutionSize == 1) continue; // i.e. single node ==> Not a good solution
1306 
1307  // Print solution
1308  std::string msg = "solution = [ ";
1309  for( int i=0; i< solutionSize; i++) {
1310  msg += Form( "%ld, ", trkIdx[ solution[i]-1 ] );
1311  }
1312  msg += " ]";
1313  ATH_MSG_DEBUG( " > " << __FUNCTION__ << ": " << msg );
1314 
1315  // varaible of new vertex
1316  WrkVrt wrkvrt;
1317 
1318  // Try to compose a new vertex using the solution nodes
1319  // Here the track ID is labelled with array
1320  wrkvrt.isGood = true;
1321  wrkvrt.selectedTrackIndices().clear();
1322 
1323  for(long int i = 0; i<solutionSize; i++) {
1324  wrkvrt.selectedTrackIndices().emplace_back( trkIdx[ solution[i]-1 ] );
1325  }
1326 
1327  if ( fitVertexFromTracks(wrkvrt, selectedTracks, ctx) == StatusCode::SUCCESS ) {
1328  workVerticesContainer.emplace_back( std::move(wrkvrt) );
1329  }
1330 
1331  }
1332 
1333  return StatusCode::SUCCESS;
1334 }

◆ msg() [1/2]

MsgStream& AthCommonMsg< Gaudi::Algorithm >::msg ( ) const
inlineinherited

Definition at line 24 of file AthCommonMsg.h.

24  {
25  return this->msgStream();
26  }

◆ msg() [2/2]

MsgStream& AthCommonMsg< Gaudi::Algorithm >::msg ( const MSG::Level  lvl) const
inlineinherited

Definition at line 27 of file AthCommonMsg.h.

27  {
28  return this->msgStream(lvl);
29  }

◆ msgLvl()

bool AthCommonMsg< Gaudi::Algorithm >::msgLvl ( const MSG::Level  lvl) const
inlineinherited

Definition at line 30 of file AthCommonMsg.h.

30  {
31  return this->msgLevel(lvl);
32  }

◆ nTrkCommon()

size_t TrigVSI::TrigVrtSecInclusive::nTrkCommon ( WrkVrtContainer workVerticesContainer,
const std::pair< unsigned, unsigned > &  pairIndex 
) const
private

Definition at line 1538 of file TrigVrtSecInclusive.cxx.

1539 {
1540  //
1541  // Number of common tracks for 2 vertices
1542  //
1543 
1544  auto& trackIndices1 = workVerticesContainer.at( pairIndex.first ).selectedTrackIndices();
1545  auto& trackIndices2 = workVerticesContainer.at( pairIndex.second ).selectedTrackIndices();
1546 
1547  if( trackIndices1.size() < 2 ) return 0;
1548  if( trackIndices2.size() < 2 ) return 0;
1549 
1550  size_t nTrkCom = 0;
1551 
1552  for( auto& index : trackIndices1 ) {
1553  if( std::find(trackIndices2.begin(),trackIndices2.end(), index) != trackIndices2.end()) nTrkCom++;
1554  }
1555 
1556  return nTrkCom;
1557 }

◆ outputHandles()

virtual std::vector<Gaudi::DataHandle*> AthCommonDataStore< AthCommonMsg< Gaudi::Algorithm > >::outputHandles ( ) const
overridevirtualinherited

Return this algorithm's output handles.

We override this to include handle instances from key arrays if they have not yet been declared. See comments on updateVHKA.

◆ renounce()

std::enable_if_t<std::is_void_v<std::result_of_t<decltype(&T::renounce)(T)> > && !std::is_base_of_v<SG::VarHandleKeyArray, T> && std::is_base_of_v<Gaudi::DataHandle, T>, void> AthCommonDataStore< AthCommonMsg< Gaudi::Algorithm > >::renounce ( T &  h)
inlineprotectedinherited

Definition at line 380 of file AthCommonDataStore.h.

381  {
382  h.renounce();
383  PBASE::renounce (h);
384  }

◆ renounceArray()

void AthCommonDataStore< AthCommonMsg< Gaudi::Algorithm > >::renounceArray ( SG::VarHandleKeyArray handlesArray)
inlineprotectedinherited

remove all handles from I/O resolution

Definition at line 364 of file AthCommonDataStore.h.

364  {
365  handlesArray.renounce();
366  }

◆ selectTrack()

bool TrigVSI::TrigVrtSecInclusive::selectTrack ( const xAOD::TrackParticle trk) const
private

Definition at line 1491 of file TrigVrtSecInclusive.cxx.

1492 {
1493  if( ! selectTrack_pTCut(trk) ) return false;
1494  if( ! selectTrack_d0Cut(trk) ) return false;
1495  if( ! selectTrack_z0Cut(trk) ) return false;
1496  if( ! selectTrack_chi2Cut(trk) ) return false;
1497  if( ! selectTrack_hitPattern(trk) ) return false;
1498  return true;
1499 }

◆ selectTrack_chi2Cut()

bool TrigVSI::TrigVrtSecInclusive::selectTrack_chi2Cut ( const xAOD::TrackParticle trk) const
private

Definition at line 1505 of file TrigVrtSecInclusive.cxx.

1505 { return trk->chiSquared() / (trk->numberDoF()+1e-9) < m_trkChi2Cut; }

◆ selectTrack_d0Cut()

bool TrigVSI::TrigVrtSecInclusive::selectTrack_d0Cut ( const xAOD::TrackParticle trk) const
private

Definition at line 1502 of file TrigVrtSecInclusive.cxx.

1502 { return ( std::abs( trk->d0() ) > m_d0TrkPVDstMinCut && std::abs( trk->d0() ) < m_d0TrkPVDstMaxCut ); }

◆ selectTrack_hitPattern()

bool TrigVSI::TrigVrtSecInclusive::selectTrack_hitPattern ( const xAOD::TrackParticle trk) const
private

Definition at line 1508 of file TrigVrtSecInclusive.cxx.

1509 {
1510  uint8_t PixelHits = 0;
1511  uint8_t SCTHits = 0;
1512  uint8_t BLayHits = 0;
1513  uint8_t PixShare = 0;
1514  uint8_t SCTShare = 0;
1515  uint8_t TRTHits = 0;
1516 
1517  if( !(trk->summaryValue( PixelHits, xAOD::numberOfPixelHits ) ) ) PixelHits =0;
1518  if( !(trk->summaryValue( SCTHits, xAOD::numberOfSCTHits ) ) ) SCTHits =0;
1519  if( !(trk->summaryValue( BLayHits, xAOD::numberOfInnermostPixelLayerHits ) ) ) BLayHits =0;
1520  if( !(trk->summaryValue( PixShare, xAOD::numberOfPixelSharedHits ) ) ) PixShare =0;
1521  if( !(trk->summaryValue( SCTShare, xAOD::numberOfSCTSharedHits ) ) ) SCTShare =0;
1522  if( !(trk->summaryValue( TRTHits, xAOD::numberOfTRTHits ) ) ) TRTHits =0;
1523 
1524  uint8_t SharedHits = PixShare + SCTShare;
1525 
1526  // do Pixel/SCT/SiHits only if we exclude StandAlone TRT hits
1527  if(PixelHits < m_cutPixelHits) return false;
1528  if(SCTHits < m_cutSctHits) return false;
1529  if((PixelHits+SCTHits) < m_cutSiHits) return false;
1530  if(BLayHits < m_cutBLayHits) return false;
1531  if(SharedHits > m_cutSharedHits) return false;
1532 
1533  // passed
1534  return true;
1535 }

◆ selectTrack_pTCut()

bool TrigVSI::TrigVrtSecInclusive::selectTrack_pTCut ( const xAOD::TrackParticle trk) const
private

Definition at line 1504 of file TrigVrtSecInclusive.cxx.

1504 { return trk->pt() > m_trkPtCut; }

◆ selectTrack_z0Cut()

bool TrigVSI::TrigVrtSecInclusive::selectTrack_z0Cut ( const xAOD::TrackParticle trk) const
private

Definition at line 1503 of file TrigVrtSecInclusive.cxx.

1503 { return ( std::abs( trk->z0() ) > m_z0TrkPVDstMinCut && std::abs( trk->z0() ) < m_z0TrkPVDstMaxCut ); }

◆ setFilterPassed()

virtual void AthReentrantAlgorithm::setFilterPassed ( bool  state,
const EventContext &  ctx 
) const
inlinevirtualinherited

Definition at line 139 of file AthReentrantAlgorithm.h.

139  {
140  execState( ctx ).setFilterPassed( state );
141  }

◆ sysExecute()

StatusCode AthReentrantAlgorithm::sysExecute ( const EventContext &  ctx)
overridevirtualinherited

Execute an algorithm.

We override this in order to work around an issue with the Algorithm base class storing the event context in a member variable that can cause crashes in MT jobs.

Definition at line 67 of file AthReentrantAlgorithm.cxx.

68 {
69  return Gaudi::Algorithm::sysExecute (ctx);
70 }

◆ sysInitialize()

StatusCode AthReentrantAlgorithm::sysInitialize ( )
overridevirtualinherited

Override sysInitialize.

Override sysInitialize from the base class.

Loop through all output handles, and if they're WriteCondHandles, automatically register them and this Algorithm with the CondSvc

Scan through all outputHandles, and if they're WriteCondHandles, register them with the CondSvc

Reimplemented from AthCommonDataStore< AthCommonMsg< Gaudi::Algorithm > >.

Reimplemented in InputMakerBase, and HypoBase.

Definition at line 96 of file AthReentrantAlgorithm.cxx.

96  {
98 
99  if (sc.isFailure()) {
100  return sc;
101  }
102 
103  ServiceHandle<ICondSvc> cs("CondSvc",name());
104  for (auto h : outputHandles()) {
105  if (h->isCondition() && h->mode() == Gaudi::DataHandle::Writer) {
106  // do this inside the loop so we don't create the CondSvc until needed
107  if ( cs.retrieve().isFailure() ) {
108  ATH_MSG_WARNING("no CondSvc found: won't autoreg WriteCondHandles");
109  return StatusCode::SUCCESS;
110  }
111  if (cs->regHandle(this,*h).isFailure()) {
112  sc = StatusCode::FAILURE;
113  ATH_MSG_ERROR("unable to register WriteCondHandle " << h->fullKey()
114  << " with CondSvc");
115  }
116  }
117  }
118  return sc;
119 }

◆ sysStart()

virtual StatusCode AthCommonDataStore< AthCommonMsg< Gaudi::Algorithm > >::sysStart ( )
overridevirtualinherited

Handle START transition.

We override this in order to make sure that conditions handle keys can cache a pointer to the conditions container.

◆ trackSelection()

StatusCode TrigVSI::TrigVrtSecInclusive::trackSelection ( const xAOD::TrackParticleContainer firstPassTrackParticles,
const xAOD::TrackParticleContainer secondPassTrackParticles,
std::vector< const xAOD::TrackParticle * > &  selectedTracks 
) const
private

Definition at line 266 of file TrigVrtSecInclusive.cxx.

267 {
268  // Pack TrackParticleContainers to one vector
269  std::vector<const xAOD::TrackParticleContainer*> v_containers;
270  if( firstPassTrackParticles != nullptr ) v_containers.push_back(firstPassTrackParticles);
271  if( secondPassTrackParticles != nullptr ) v_containers.push_back(secondPassTrackParticles);
272 
273  typedef DataVector<xAOD::TrackParticle>::const_iterator TrackParticleDataVecIter;
274 
275  for(unsigned int i=0; i<v_containers.size(); i++) {
276  const xAOD::TrackParticleContainer* trackParticles = v_containers[i];
277  size_t n_trk = 0;
278  for (TrackParticleDataVecIter itr = trackParticles->begin(); itr != trackParticles->end(); ++itr) {
279  if( selectTrack(*itr) ) { selectedTracks.push_back(*itr); n_trk++; }
280  }
281  ATH_MSG_DEBUG("Of " << trackParticles->size() << " tracks " << n_trk << " survived the preselection.");
282  }
283  ATH_MSG_DEBUG(selectedTracks.size() << " tracks in total passed the selection.");
284  return StatusCode::SUCCESS;
285 }

◆ updateVHKA()

void AthCommonDataStore< AthCommonMsg< Gaudi::Algorithm > >::updateVHKA ( Gaudi::Details::PropertyBase &  )
inlineinherited

Definition at line 308 of file AthCommonDataStore.h.

308  {
309  // debug() << "updateVHKA for property " << p.name() << " " << p.toString()
310  // << " size: " << m_vhka.size() << endmsg;
311  for (auto &a : m_vhka) {
312  std::vector<SG::VarHandleKey*> keys = a->keys();
313  for (auto k : keys) {
314  k->setOwner(this);
315  }
316  }
317  }

Member Data Documentation

◆ m_cutBLayHits

Gaudi::Property<int> TrigVSI::TrigVrtSecInclusive::m_cutBLayHits {this, "CutBLayHits", 0, "Track selection : Hit requirements"}
private

Definition at line 59 of file TrigVrtSecInclusive.h.

◆ m_cutPixelHits

Gaudi::Property<int> TrigVSI::TrigVrtSecInclusive::m_cutPixelHits {this, "CutPixelHits", 0, "Track selection : Hit requirements"}
private

Definition at line 55 of file TrigVrtSecInclusive.h.

◆ m_cutSctHits

Gaudi::Property<int> TrigVSI::TrigVrtSecInclusive::m_cutSctHits {this, "CutSctHits", 2, "Track selection : Hit requirements"}
private

Definition at line 56 of file TrigVrtSecInclusive.h.

◆ m_cutSharedHits

Gaudi::Property<int> TrigVSI::TrigVrtSecInclusive::m_cutSharedHits {this, "CutSharedHits", 99, "Track selection : Hit requirements"}
private

Definition at line 57 of file TrigVrtSecInclusive.h.

◆ m_cutSiHits

Gaudi::Property<int> TrigVSI::TrigVrtSecInclusive::m_cutSiHits {this, "CutSiHits", 0, "Track selection : Hit requirements"}
private

Definition at line 58 of file TrigVrtSecInclusive.h.

◆ m_d0TrkPVDstMaxCut

Gaudi::Property<double> TrigVSI::TrigVrtSecInclusive::m_d0TrkPVDstMaxCut {this, "d0TrkPVDstMaxCut", 300.0, "Track selection : Impact parameter requirements [mm]"}
private

Definition at line 65 of file TrigVrtSecInclusive.h.

◆ m_d0TrkPVDstMinCut

Gaudi::Property<double> TrigVSI::TrigVrtSecInclusive::m_d0TrkPVDstMinCut {this, "d0TrkPVDstMinCut", 2.0, "Track selection : Impact parameter requirements [mm]"}
private

Definition at line 64 of file TrigVrtSecInclusive.h.

◆ m_detStore

StoreGateSvc_t AthCommonDataStore< AthCommonMsg< Gaudi::Algorithm > >::m_detStore
privateinherited

Pointer to StoreGate (detector store by default)

Definition at line 393 of file AthCommonDataStore.h.

◆ m_doFastRCut

Gaudi::Property<bool> TrigVSI::TrigVrtSecInclusive::m_doFastRCut {this, "doFastRCut", false, "Track-pair selection : Flag for R cut derived from VKalVrtFitFast"}
private

Definition at line 74 of file TrigVrtSecInclusive.h.

◆ m_doMaterialMapVeto

Gaudi::Property<bool> TrigVSI::TrigVrtSecInclusive::m_doMaterialMapVeto {this, "doMaterialMapVeto", false, "Track-pair selection : When set to true, perform material map veto on track pairs"}
private

Definition at line 87 of file TrigVrtSecInclusive.h.

◆ m_doPVCompatibilityCut

Gaudi::Property<bool> TrigVSI::TrigVrtSecInclusive::m_doPVCompatibilityCut {this, "doPVCompatibilityCut", false, "Track-pair selection : When set to true, require track pairs to be compatible with PV"}
private

Definition at line 83 of file TrigVrtSecInclusive.h.

◆ m_doTwoCircRCut

Gaudi::Property<bool> TrigVSI::TrigVrtSecInclusive::m_doTwoCircRCut {this, "doTwoCircRCut", false, "Track-pair selection : Flag for R cut derived from two-circles-intersection-point"}
private

Definition at line 73 of file TrigVrtSecInclusive.h.

◆ m_dphiPVCut

Gaudi::Property<double> TrigVSI::TrigVrtSecInclusive::m_dphiPVCut {this, "dphiPVCut", -0.8, "Track-pair selection : Threshold for the cos of angle of the tracks and the momentum of the track pair"}
private

Definition at line 84 of file TrigVrtSecInclusive.h.

◆ m_evtStore

StoreGateSvc_t AthCommonDataStore< AthCommonMsg< Gaudi::Algorithm > >::m_evtStore
privateinherited

Pointer to StoreGate (event store by default)

Definition at line 390 of file AthCommonDataStore.h.

◆ m_extendedExtraObjects

DataObjIDColl AthReentrantAlgorithm::m_extendedExtraObjects
privateinherited

Extra output dependency collection, extended by AthAlgorithmDHUpdate to add symlinks.

Empty if no symlinks were found.

Definition at line 153 of file AthReentrantAlgorithm.h.

◆ m_fastD0deltaCut

Gaudi::Property<double> TrigVSI::TrigVrtSecInclusive::m_fastD0deltaCut {this, "fastD0deltaCut", 4.2, "Track-pair selection : Threshold for rough d0 cut"}
private

Definition at line 77 of file TrigVrtSecInclusive.h.

◆ m_fastD0minCut

Gaudi::Property<double> TrigVSI::TrigVrtSecInclusive::m_fastD0minCut {this, "fastD0minCut", 5., "Track-pair selection : Threshold for rough d0 cut"}
private

Definition at line 76 of file TrigVrtSecInclusive.h.

◆ m_fastZ0deltaCut

Gaudi::Property<double> TrigVSI::TrigVrtSecInclusive::m_fastZ0deltaCut {this, "fastZ0deltaCut", 8., "Track-pair selection : Threshold for rough z0 cut"}
private

Definition at line 79 of file TrigVrtSecInclusive.h.

◆ m_fastZ0minCut

Gaudi::Property<double> TrigVSI::TrigVrtSecInclusive::m_fastZ0minCut {this, "fastZ0minCut", 120., "Track-pair selection : Threshold for rough z0 cut"}
private

Definition at line 78 of file TrigVrtSecInclusive.h.

◆ m_firstPassTracksName

SG::ReadHandleKey<xAOD::TrackParticleContainer> TrigVSI::TrigVrtSecInclusive::m_firstPassTracksName { this,"FirstPassTracksName","InDetTrackParticles","xAOD::TrackParticle Collection used in Vertexing" }
private

Definition at line 195 of file TrigVrtSecInclusive.h.

◆ m_fitSvc

ToolHandle<Trk::TrkVKalVrtFitter> TrigVSI::TrigVrtSecInclusive::m_fitSvc { this, "VertexFitter", "", "VKalVrtFitter tool to fit tracks into the common vertex" }
private

Definition at line 201 of file TrigVrtSecInclusive.h.

◆ m_improveChi2ProbThreshold

Gaudi::Property<double> TrigVSI::TrigVrtSecInclusive::m_improveChi2ProbThreshold {this, "improveChi2ProbThreshold", 4.5, "Offline VSI option"}
private

Definition at line 97 of file TrigVrtSecInclusive.h.

◆ m_materialMapInner

TH3S* TrigVSI::TrigVrtSecInclusive::m_materialMapInner =0
private

Definition at line 177 of file TrigVrtSecInclusive.h.

◆ m_materialMapInnerFileName

std::string TrigVSI::TrigVrtSecInclusive::m_materialMapInnerFileName
private

Definition at line 180 of file TrigVrtSecInclusive.h.

◆ m_materialMapInnerHistName

std::string TrigVSI::TrigVrtSecInclusive::m_materialMapInnerHistName
private

Definition at line 181 of file TrigVrtSecInclusive.h.

◆ m_materialMapInnerMatrixName

std::string TrigVSI::TrigVrtSecInclusive::m_materialMapInnerMatrixName
private

Definition at line 182 of file TrigVrtSecInclusive.h.

◆ m_materialMapMatrix

TMatrixT<double>* TrigVSI::TrigVrtSecInclusive::m_materialMapMatrix =0
private

Definition at line 179 of file TrigVrtSecInclusive.h.

◆ m_materialMapOuter

TH3S* TrigVSI::TrigVrtSecInclusive::m_materialMapOuter =0
private

Definition at line 178 of file TrigVrtSecInclusive.h.

◆ m_materialMapOuterFileName

std::string TrigVSI::TrigVrtSecInclusive::m_materialMapOuterFileName
private

Definition at line 183 of file TrigVrtSecInclusive.h.

◆ m_materialMapOuterHistName

std::string TrigVSI::TrigVrtSecInclusive::m_materialMapOuterHistName
private

Definition at line 184 of file TrigVrtSecInclusive.h.

◆ m_maxR

Gaudi::Property<double> TrigVSI::TrigVrtSecInclusive::m_maxR {this, "maxR", 563., "Track-pair selection : Max value for R of vertex position"}
private

Definition at line 71 of file TrigVrtSecInclusive.h.

◆ m_maxTrks

Gaudi::Property<size_t> TrigVSI::TrigVrtSecInclusive::m_maxTrks {this, "maxTrks", 100, "Max track number to run vertexing"}
private

Definition at line 90 of file TrigVrtSecInclusive.h.

◆ m_maxWrkVertices

Gaudi::Property<size_t> TrigVSI::TrigVrtSecInclusive::m_maxWrkVertices {this, "maxWrkVertices", 10000, "Offline VSI option"}
private

Definition at line 96 of file TrigVrtSecInclusive.h.

◆ m_minTrkPairsMerge

Gaudi::Property<size_t> TrigVSI::TrigVrtSecInclusive::m_minTrkPairsMerge {this, "minTrkPairsMerge", 6, "Clusters with track pairs less than minTrkPairsMerge and tracks less than minTrksMerge will be merged into single vertex"}
private

Definition at line 92 of file TrigVrtSecInclusive.h.

◆ m_minTrksMerge

Gaudi::Property<size_t> TrigVSI::TrigVrtSecInclusive::m_minTrksMerge {this, "minTrksMerge", 4, "Clusters with track pairs less than minTrkPairsMerge and tracks less than minTrksMerge will be merged into single vertex"}
private

Definition at line 93 of file TrigVrtSecInclusive.h.

◆ m_monTool

ToolHandle<GenericMonitoringTool> TrigVSI::TrigVrtSecInclusive::m_monTool { this, "MonTool", "", "Monitoring tool" }
private

Definition at line 204 of file TrigVrtSecInclusive.h.

◆ m_PrimaryVxInputName

SG::ReadHandleKey<xAOD::VertexContainer> TrigVSI::TrigVrtSecInclusive::m_PrimaryVxInputName { this,"PrimaryVertexInputName","PrimaryVertices","Input Vertex Collection" }
private

Definition at line 199 of file TrigVrtSecInclusive.h.

◆ m_pvCompatibilityCut

Gaudi::Property<double> TrigVSI::TrigVrtSecInclusive::m_pvCompatibilityCut {this, "PVcompatibilityCut", -20., "Track-pair selection : Threshold for the track pair position along the momentum vector"}
private

Definition at line 85 of file TrigVrtSecInclusive.h.

◆ m_recordTrkPair

Gaudi::Property<bool> TrigVSI::TrigVrtSecInclusive::m_recordTrkPair {this, "recordTrkPair", false, "Output EDM : Flag for record TrkPair vertices"}
private

Definition at line 53 of file TrigVrtSecInclusive.h.

◆ m_secondPassTracksName

SG::ReadHandleKey<xAOD::TrackParticleContainer> TrigVSI::TrigVrtSecInclusive::m_secondPassTracksName { this,"SecondPassTracksName","InDetTrackParticles","xAOD::TrackParticle Collection used in Vertexing" }
private

Definition at line 196 of file TrigVrtSecInclusive.h.

◆ m_selVrtChi2Cut

Gaudi::Property<double> TrigVSI::TrigVrtSecInclusive::m_selVrtChi2Cut {this, "SelVrtChi2Cut", 4.5, "Track-pair selection : Threshold for the chi2 value of track pair fitting with VKalVrtFit"}
private

Definition at line 81 of file TrigVrtSecInclusive.h.

◆ m_skipLargeCluster

Gaudi::Property<bool> TrigVSI::TrigVrtSecInclusive::m_skipLargeCluster {this, "skipLargeCluster", true, "Flag to skip vertexing on clusters with too many tracks"}
private

Definition at line 89 of file TrigVrtSecInclusive.h.

◆ m_trkChi2Cut

Gaudi::Property<double> TrigVSI::TrigVrtSecInclusive::m_trkChi2Cut {this, "TrkChi2Cut", 50.0, "Track selection : Chi2 requirements"}
private

Definition at line 61 of file TrigVrtSecInclusive.h.

◆ m_trkPairOutputName

SG::WriteHandleKey<xAOD::VertexContainer> TrigVSI::TrigVrtSecInclusive::m_trkPairOutputName { this,"TrkPairOutputName","InclusiveSecVtx","Track pair Collection" }
private

Definition at line 198 of file TrigVrtSecInclusive.h.

◆ m_trkPtCut

Gaudi::Property<double> TrigVSI::TrigVrtSecInclusive::m_trkPtCut {this, "TrkPtCut", (m_vtxAlgorithm == 0)? 2000. : 1000., "Track selection : pT requirements. 2 GeV in TrigVSI, 1 GeV in VSI"}
private

Definition at line 62 of file TrigVrtSecInclusive.h.

◆ m_truncateWrkVertices

Gaudi::Property<bool> TrigVSI::TrigVrtSecInclusive::m_truncateWrkVertices {this, "truncateWrkVertices", true, "Offline VSI option"}
private

Definition at line 95 of file TrigVrtSecInclusive.h.

◆ m_twoTrkVtxFormingD0Cut

Gaudi::Property<double> TrigVSI::TrigVrtSecInclusive::m_twoTrkVtxFormingD0Cut {this, "twoTrkVtxFormingD0Cut", 1., "Track selection : Impact parameter requirements [mm]"}
private

Definition at line 68 of file TrigVrtSecInclusive.h.

◆ m_varHandleArraysDeclared

bool AthCommonDataStore< AthCommonMsg< Gaudi::Algorithm > >::m_varHandleArraysDeclared
privateinherited

Definition at line 399 of file AthCommonDataStore.h.

◆ m_vertexPointEstimator

ToolHandle<InDet::VertexPointEstimator> TrigVSI::TrigVrtSecInclusive::m_vertexPointEstimator { this, "VertexPointEstimator", "", "tool to find starting point for the vertex fitter"}
private

Definition at line 202 of file TrigVrtSecInclusive.h.

◆ m_vhka

std::vector<SG::VarHandleKeyArray*> AthCommonDataStore< AthCommonMsg< Gaudi::Algorithm > >::m_vhka
privateinherited

Definition at line 398 of file AthCommonDataStore.h.

◆ m_vtxAlgorithm

Gaudi::Property<int> TrigVSI::TrigVrtSecInclusive::m_vtxAlgorithm {this, "vtxAlgorithm", 0, "Vertexing algorithm. 0 : TrigVSI algorithm, 1 : Offline VSI like algorithm"}
private

Definition at line 51 of file TrigVrtSecInclusive.h.

◆ m_vxCandidatesOutputName

SG::WriteHandleKey<xAOD::VertexContainer> TrigVSI::TrigVrtSecInclusive::m_vxCandidatesOutputName { this,"VxCandidatesOutputName","InclusiveSecVtx","Output Vertex Collection" }
private

Definition at line 197 of file TrigVrtSecInclusive.h.

◆ m_z0TrkPVDstMaxCut

Gaudi::Property<double> TrigVSI::TrigVrtSecInclusive::m_z0TrkPVDstMaxCut {this, "z0TrkPVDstMaxCut", 1500.0, "Track selection : Impact parameter requirements [mm]"}
private

Definition at line 67 of file TrigVrtSecInclusive.h.

◆ m_z0TrkPVDstMinCut

Gaudi::Property<double> TrigVSI::TrigVrtSecInclusive::m_z0TrkPVDstMinCut {this, "z0TrkPVDstMinCut", 0.0, "Track selection : Impact parameter requirements [mm]"}
private

Definition at line 66 of file TrigVrtSecInclusive.h.


The documentation for this class was generated from the following files:
xAOD::TrackParticle_v1::pt
virtual double pt() const override final
The transverse momentum ( ) of the particle.
Definition: TrackParticle_v1.cxx:73
TrigVSI::TrigVrtSecInclusive::m_doMaterialMapVeto
Gaudi::Property< bool > m_doMaterialMapVeto
Definition: TrigVrtSecInclusive.h:87
TrigVSI::TrigVrtSecInclusive::findDiTrackVertex
StatusCode findDiTrackVertex(WrkVrtContainer &, std::vector< std::pair< size_t, size_t >> &, std::vector< const xAOD::TrackParticle * > &, const EventContext &, const xAOD::Vertex *) const
Definition: TrigVrtSecInclusive.cxx:379
DataModel_detail::const_iterator
Const iterator class for DataVector/DataList.
Definition: DVLIterator.h:82
TrigVSI::TrigVrtSecInclusive::fillVtxContainer
StatusCode fillVtxContainer(xAODContainers &, const WrkVrtContainer &, std::vector< const xAOD::TrackParticle * > &) const
Definition: TrigVrtSecInclusive.cxx:288
TrigDefs::Group
Group
Properties of a chain group.
Definition: GroupProperties.h:13
TrigVSI::TrigVrtSecInclusive::findDiTrackVertexVSI
StatusCode findDiTrackVertexVSI(WrkVrtContainer &, std::vector< std::pair< size_t, size_t >> &, std::vector< const xAOD::TrackParticle * > &, const EventContext &, const xAOD::Vertex *) const
Definition: TrigVrtSecInclusive.cxx:659
xAOD::Vertex_v1::nTrackParticles
size_t nTrackParticles() const
Get the number of tracks associated with this vertex.
Definition: Vertex_v1.cxx:270
TrigVSI::TrigVrtSecInclusive::m_materialMapInner
TH3S * m_materialMapInner
Definition: TrigVrtSecInclusive.h:177
python.PerfMonSerializer.p
def p
Definition: PerfMonSerializer.py:743
max
#define max(a, b)
Definition: cfImp.cxx:41
TrigVSI::TrigVrtSecInclusive::m_materialMapOuterFileName
std::string m_materialMapOuterFileName
Definition: TrigVrtSecInclusive.h:183
xAOD::numberOfSCTSharedHits
@ numberOfSCTSharedHits
number of SCT hits shared by several tracks [unit8_t].
Definition: TrackingPrimitives.h:272
xAOD::Vertex
Vertex_v1 Vertex
Define the latest version of the vertex class.
Definition: Event/xAOD/xAODTracking/xAODTracking/Vertex.h:16
DataVector::emplace_back
value_type emplace_back(value_type pElem)
Add an element to the end of the collection.
TrigVSI::TrigVrtSecInclusive::k_qOverP
@ k_qOverP
Definition: TrigVrtSecInclusive.h:169
ATH_MSG_INFO
#define ATH_MSG_INFO(x)
Definition: AthMsgStreamMacros.h:31
xAOD::uint8_t
uint8_t
Definition: Muon_v1.cxx:575
find
std::string find(const std::string &s)
return a remapped string
Definition: hcg.cxx:135
PathResolver::find_file
static std::string find_file(const std::string &logical_file_name, const std::string &search_path, SearchType search_type=LocalSearch)
Definition: PathResolver.cxx:251
TrigVSI::TrigVrtSecInclusive::fitVertexFromTracks
StatusCode fitVertexFromTracks(WrkVrt &, const std::vector< const xAOD::TrackParticle * > &, const EventContext &) const
Reconstruct vertex from given tracks.
Definition: TrigVrtSecInclusive.cxx:1351
SG::Accessor< float >
TrigVSI::TrigVrtSecInclusive::m_maxWrkVertices
Gaudi::Property< size_t > m_maxWrkVertices
Definition: TrigVrtSecInclusive.h:96
TrigVSI::TrigVrtSecInclusive::m_minTrksMerge
Gaudi::Property< size_t > m_minTrksMerge
Definition: TrigVrtSecInclusive.h:93
xAOD::TrackParticle_v1::charge
float charge() const
Returns the charge.
Definition: TrackParticle_v1.cxx:150
TrigVSI::TrigVrtSecInclusive::m_materialMapInnerFileName
std::string m_materialMapInnerFileName
Definition: TrigVrtSecInclusive.h:180
SG::ReadHandle
Definition: StoreGate/StoreGate/ReadHandle.h:70
index
Definition: index.py:1
AthCommonDataStore::declareProperty
Gaudi::Details::PropertyBase & declareProperty(Gaudi::Property< T > &t)
Definition: AthCommonDataStore.h:145
Trk::ParametersT
Dummy class used to allow special convertors to be called for surfaces owned by a detector element.
Definition: EMErrorDetail.h:25
TrigVSI::TrigVrtSecInclusive::k_phi
@ k_phi
Definition: TrigVrtSecInclusive.h:169
TrigVSI::TrigVrtSecInclusive::findNTrackVertex
StatusCode findNTrackVertex(WrkVrtContainer &, TrigVSI::VtxMap< VrtType, Coord > &, const std::vector< const xAOD::TrackParticle * > &, const EventContext &) const
Definition: TrigVrtSecInclusive.cxx:1151
xAOD::TrackParticle_v1::summaryValue
bool summaryValue(uint8_t &value, const SummaryType &information) const
Accessor for TrackSummary values.
Definition: TrackParticle_v1.cxx:736
TrigVSI::TrigVrtSecInclusive::m_trkPtCut
Gaudi::Property< double > m_trkPtCut
Definition: TrigVrtSecInclusive.h:62
TrigVSI::TrigVrtSecInclusive::mergeVertexFromDiTrkVrt
StatusCode mergeVertexFromDiTrkVrt(WrkVrtContainer &, const std::vector< std::pair< size_t, size_t >> &, const std::vector< size_t > &, const std::vector< const xAOD::TrackParticle * > &, const EventContext &) const
Reconstruct multi-track vertices from incompatible track pair lists.
Definition: TrigVrtSecInclusive.cxx:1244
TrigVSI::TrigVrtSecInclusive::k_theta
@ k_theta
Definition: TrigVrtSecInclusive.h:169
AthCommonDataStore::renounce
std::enable_if_t< std::is_void_v< std::result_of_t< decltype(&T::renounce)(T)> > &&!std::is_base_of_v< SG::VarHandleKeyArray, T > &&std::is_base_of_v< Gaudi::DataHandle, T >, void > renounce(T &h)
Definition: AthCommonDataStore.h:380
TrigVSI::TrigVrtSecInclusive::m_doTwoCircRCut
Gaudi::Property< bool > m_doTwoCircRCut
Definition: TrigVrtSecInclusive.h:73
TrigVSI::TrigVrtSecInclusive::m_minTrkPairsMerge
Gaudi::Property< size_t > m_minTrkPairsMerge
Definition: TrigVrtSecInclusive.h:92
TrigVSI::TrigVrtSecInclusive::m_z0TrkPVDstMaxCut
Gaudi::Property< double > m_z0TrkPVDstMaxCut
Definition: TrigVrtSecInclusive.h:67
xAOD::TrackParticle_v1::z0
float z0() const
Returns the parameter.
AthCommonDataStore< AthCommonMsg< Gaudi::Algorithm > >::m_evtStore
StoreGateSvc_t m_evtStore
Pointer to StoreGate (event store by default)
Definition: AthCommonDataStore.h:390
xAOD::TrackParticle_v1::chiSquared
float chiSquared() const
Returns the of the overall track fit.
AthCommonDataStore< AthCommonMsg< Gaudi::Algorithm > >::m_vhka
std::vector< SG::VarHandleKeyArray * > m_vhka
Definition: AthCommonDataStore.h:398
DataVector::get
const T * get(size_type n) const
Access an element, as an rvalue.
TrigVSI::TrigVrtSecInclusive::m_doPVCompatibilityCut
Gaudi::Property< bool > m_doPVCompatibilityCut
Definition: TrigVrtSecInclusive.h:83
xAOD::numberOfPixelHits
@ numberOfPixelHits
these are the pixel hits, including the b-layer [unit8_t].
Definition: TrackingPrimitives.h:259
xAOD::numberOfTRTHits
@ numberOfTRTHits
number of TRT hits [unit8_t].
Definition: TrackingPrimitives.h:275
xAOD::Vertex_v1::position
const Amg::Vector3D & position() const
Returns the 3-pos.
python.TurnDataReader.dr
dr
Definition: TurnDataReader.py:112
read_hist_ntuple.t
t
Definition: read_hist_ntuple.py:5
drawFromPickle.cos
cos
Definition: drawFromPickle.py:36
TrigVSI::TrigVrtSecInclusive::selectTrack_pTCut
bool selectTrack_pTCut(const xAOD::TrackParticle *trk) const
Definition: TrigVrtSecInclusive.cxx:1504
ATH_MSG_VERBOSE
#define ATH_MSG_VERBOSE(x)
Definition: AthMsgStreamMacros.h:28
TrigVSI::TrigVrtSecInclusive::m_doFastRCut
Gaudi::Property< bool > m_doFastRCut
Definition: TrigVrtSecInclusive.h:74
TrigVSI::TrigVrtSecInclusive::xAODContainers
std::pair< std::unique_ptr< xAOD::VertexContainer >, std::unique_ptr< xAOD::VertexAuxContainer > > xAODContainers
Definition: TrigVrtSecInclusive.h:48
TrigVSI::TrigVrtSecInclusive::m_fastZ0deltaCut
Gaudi::Property< double > m_fastZ0deltaCut
Definition: TrigVrtSecInclusive.h:79
xAOD::Vertex_v1::vertexType
VxType::VertexType vertexType() const
The type of the vertex.
TrigVSI::AlgConsts::nPhi
constexpr int nPhi
Default bin number of phi for vertex map.
Definition: Trigger/TrigTools/TrigVrtSecInclusive/TrigVrtSecInclusive/Constants.h:27
TrigVSI::TrigVrtSecInclusive::trackSelection
StatusCode trackSelection(const xAOD::TrackParticleContainer *, const xAOD::TrackParticleContainer *, std::vector< const xAOD::TrackParticle * > &) const
Definition: TrigVrtSecInclusive.cxx:266
xAOD::TrackParticle_v1::d0
float d0() const
Returns the parameter.
AthenaPoolTestRead.sc
sc
Definition: AthenaPoolTestRead.py:27
TrigVSI::TrigVrtSecInclusive::m_fitSvc
ToolHandle< Trk::TrkVKalVrtFitter > m_fitSvc
Definition: TrigVrtSecInclusive.h:201
PUfitVar::maxEta
constexpr float maxEta
Definition: GepMETPufitAlg.cxx:13
Monitored::Collection
ValuesCollection< T > Collection(std::string name, const T &collection)
Declare a monitored (double-convertible) collection.
Definition: MonitoredCollection.h:38
TrigVSI::TrigVrtSecInclusive::m_vertexPointEstimator
ToolHandle< InDet::VertexPointEstimator > m_vertexPointEstimator
Definition: TrigVrtSecInclusive.h:202
SG::VarHandleKeyArray::setOwner
virtual void setOwner(IDataHandleHolder *o)=0
TrigVSI::TrigVrtSecInclusive::m_firstPassTracksName
SG::ReadHandleKey< xAOD::TrackParticleContainer > m_firstPassTracksName
Definition: TrigVrtSecInclusive.h:195
TrigVSI::TrigVrtSecInclusive::m_trkPairOutputName
SG::WriteHandleKey< xAOD::VertexContainer > m_trkPairOutputName
Definition: TrigVrtSecInclusive.h:198
TrigVSI::TrigVrtSecInclusive::selectTrack_z0Cut
bool selectTrack_z0Cut(const xAOD::TrackParticle *trk) const
Definition: TrigVrtSecInclusive.cxx:1503
TrigVSI::TrigVrtSecInclusive::m_vtxAlgorithm
Gaudi::Property< int > m_vtxAlgorithm
Definition: TrigVrtSecInclusive.h:51
dqt_zlumi_pandas.weight
int weight
Definition: dqt_zlumi_pandas.py:200
InDet::VertexPointEstimator::Values_t
std::map< std::string, float > Values_t
Definition: VertexPointEstimator.h:33
TrigVSI::TrigVrtSecInclusive::k_d0
@ k_d0
Definition: TrigVrtSecInclusive.h:169
DumpGeoConfig.outFileName
string outFileName
Definition: DumpGeoConfig.py:238
xAOD::TrackParticle_v1::perigeeParameters
const Trk::Perigee & perigeeParameters() const
Returns the Trk::MeasuredPerigee track parameters.
Definition: TrackParticle_v1.cxx:485
TrigVSI::TrigVrtSecInclusive::m_trkChi2Cut
Gaudi::Property< double > m_trkChi2Cut
Definition: TrigVrtSecInclusive.h:61
xAOD::numberOfPixelSharedHits
@ numberOfPixelSharedHits
number of Pixel all-layer hits shared by several tracks [unit8_t].
Definition: TrackingPrimitives.h:262
TrigVSI::TrigVrtSecInclusive::findNtrackVerticesVSI
StatusCode findNtrackVerticesVSI(WrkVrtContainer &, std::vector< std::pair< size_t, size_t >> &, std::vector< const xAOD::TrackParticle * > &, const EventContext &) const
Definition: TrigVrtSecInclusive.cxx:910
TrigVSI::TrigVrtSecInclusive::selectTrack_d0Cut
bool selectTrack_d0Cut(const xAOD::TrackParticle *trk) const
Definition: TrigVrtSecInclusive.cxx:1502
AthCommonDataStore
Definition: AthCommonDataStore.h:52
TrigVSI::TrigVrtSecInclusive::m_z0TrkPVDstMinCut
Gaudi::Property< double > m_z0TrkPVDstMinCut
Definition: TrigVrtSecInclusive.h:66
AthReentrantAlgorithm::AthReentrantAlgorithm
AthReentrantAlgorithm()
Default constructor:
ATH_MSG_ERROR
#define ATH_MSG_ERROR(x)
Definition: AthMsgStreamMacros.h:33
ConvertOldHistosToNewHistos.inFileName
inFileName
Definition: ConvertOldHistosToNewHistos.py:21
TrigVSI::AlgConsts::mapBinWid
constexpr float mapBinWid
Default bin width for vertex map.
Definition: Trigger/TrigTools/TrigVrtSecInclusive/TrigVrtSecInclusive/Constants.h:23
TrigVSI::TrigVrtSecInclusive::m_materialMapMatrix
TMatrixT< double > * m_materialMapMatrix
Definition: TrigVrtSecInclusive.h:179
TrigVSI::TrigVrtSecInclusive::k_z0z0
@ k_z0z0
Definition: TrigVrtSecInclusive.h:170
AthCommonDataStore< AthCommonMsg< Gaudi::Algorithm > >::outputHandles
virtual std::vector< Gaudi::DataHandle * > outputHandles() const override
Return this algorithm's output handles.
fillPileUpNoiseLumi.next
next
Definition: fillPileUpNoiseLumi.py:52
lumiFormat.i
int i
Definition: lumiFormat.py:92
TrigVSI::TrigVrtSecInclusive::m_truncateWrkVertices
Gaudi::Property< bool > m_truncateWrkVertices
Definition: TrigVrtSecInclusive.h:95
EL::StatusCode
::StatusCode StatusCode
StatusCode definition for legacy code.
Definition: PhysicsAnalysis/D3PDTools/EventLoop/EventLoop/StatusCode.h:22
xAOD::VxType::SecVtx
@ SecVtx
Secondary vertex.
Definition: TrackingPrimitives.h:572
ATH_MSG_DEBUG
#define ATH_MSG_DEBUG(x)
Definition: AthMsgStreamMacros.h:29
TrigVSI::TrigVrtSecInclusive::cleanUp
StatusCode cleanUp(WrkVrtContainer &) const
Definition: TrigVrtSecInclusive.cxx:1561
master.flag
bool flag
Definition: master.py:29
TrigVSI::TrigVrtSecInclusive::m_cutSharedHits
Gaudi::Property< int > m_cutSharedHits
Definition: TrigVrtSecInclusive.h:57
TrigVSI::TrigVrtSecInclusive::m_improveChi2ProbThreshold
Gaudi::Property< double > m_improveChi2ProbThreshold
Definition: TrigVrtSecInclusive.h:97
xAOD::VxType::PriVtx
@ PriVtx
Primary vertex.
Definition: TrackingPrimitives.h:571
TrigVSI::VtxMap::nClusters
size_t nClusters() const
Return the number of the clusters.
Definition: VtxMap.h:188
TrigVSI::VtxMap::getCluster
CellCluster getCluster(size_t)
Retrieve clustering result as CellCluster object.
Definition: VtxMap.h:420
TrigVSI::TrigVrtSecInclusive::m_recordTrkPair
Gaudi::Property< bool > m_recordTrkPair
Definition: TrigVrtSecInclusive.h:53
ATH_CHECK
#define ATH_CHECK
Definition: AthCheckMacros.h:40
TrigVSI::TrigVrtSecInclusive::m_materialMapOuterHistName
std::string m_materialMapOuterHistName
Definition: TrigVrtSecInclusive.h:184
AthCommonDataStore< AthCommonMsg< Gaudi::Algorithm > >::m_detStore
StoreGateSvc_t m_detStore
Pointer to StoreGate (detector store by default)
Definition: AthCommonDataStore.h:393
SG::VarHandleKey::initialize
StatusCode initialize(bool used=true)
If this object is used as a property, then this should be called during the initialize phase.
Definition: AthToolSupport/AsgDataHandles/Root/VarHandleKey.cxx:103
DeMoUpdate.tmp
string tmp
Definition: DeMoUpdate.py:1167
TrigVSI::TrigVrtSecInclusive::selectTrack
bool selectTrack(const xAOD::TrackParticle *trk) const
Definition: TrigVrtSecInclusive.cxx:1491
DataVector
Derived DataVector<T>.
Definition: DataVector.h:581
AthReentrantAlgorithm::m_extendedExtraObjects
DataObjIDColl m_extendedExtraObjects
Extra output dependency collection, extended by AthAlgorithmDHUpdate to add symlinks.
Definition: AthReentrantAlgorithm.h:153
min
#define min(a, b)
Definition: cfImp.cxx:40
TrigVSI::TrigVrtSecInclusive::k_nTPU
@ k_nTPU
Definition: TrigVrtSecInclusive.h:170
SG::VarHandleKeyArray::renounce
virtual void renounce()=0
TrigVSI::TrigVrtSecInclusive::selectTrack_hitPattern
bool selectTrack_hitPattern(const xAOD::TrackParticle *trk) const
Definition: TrigVrtSecInclusive.cxx:1508
TrigVSI::TrigVrtSecInclusive::m_vxCandidatesOutputName
SG::WriteHandleKey< xAOD::VertexContainer > m_vxCandidatesOutputName
Definition: TrigVrtSecInclusive.h:197
SG::HandleClassifier::type
std::conditional< std::is_base_of< SG::VarHandleKeyArray, T >::value, VarHandleKeyArrayType, type2 >::type type
Definition: HandleClassifier.h:54
TrigVSI::TrigVrtSecInclusive::m_d0TrkPVDstMaxCut
Gaudi::Property< double > m_d0TrkPVDstMaxCut
Definition: TrigVrtSecInclusive.h:65
merge_scale_histograms.doc
string doc
Definition: merge_scale_histograms.py:9
name
std::string name
Definition: Control/AthContainers/Root/debug.cxx:195
TH3S::GetBinContent
double GetBinContent(int) const
Definition: rootspy.cxx:480
TrigVSI::TrigVrtSecInclusive::m_materialMapInnerMatrixName
std::string m_materialMapInnerMatrixName
Definition: TrigVrtSecInclusive.h:182
TrigVSI::VtxMap
The vertex map class to be used to find multi-track vertices.
Definition: VtxMap.h:40
TrigVSI::TrigVrtSecInclusive::m_cutSctHits
Gaudi::Property< int > m_cutSctHits
Definition: TrigVrtSecInclusive.h:56
AthReentrantAlgorithm::sysInitialize
virtual StatusCode sysInitialize() override
Override sysInitialize.
Definition: AthReentrantAlgorithm.cxx:96
TrigVSI::AlgConsts
Namespace for constants.
Definition: Trigger/TrigTools/TrigVrtSecInclusive/TrigVrtSecInclusive/Constants.h:19
TrigVSI::TrigVrtSecInclusive::m_monTool
ToolHandle< GenericMonitoringTool > m_monTool
Definition: TrigVrtSecInclusive.h:204
TrigVSI::TrigVrtSecInclusive::m_materialMapInnerHistName
std::string m_materialMapInnerHistName
Definition: TrigVrtSecInclusive.h:181
Amg::Vector3D
Eigen::Matrix< double, 3, 1 > Vector3D
Definition: GeoPrimitives.h:47
TrigVSI::TrigVrtSecInclusive::m_cutPixelHits
Gaudi::Property< int > m_cutPixelHits
Definition: TrigVrtSecInclusive.h:55
TrigVSI::TrigVrtSecInclusive::m_dphiPVCut
Gaudi::Property< double > m_dphiPVCut
Definition: TrigVrtSecInclusive.h:84
TrigVSI::TrigVrtSecInclusive::m_fastD0deltaCut
Gaudi::Property< double > m_fastD0deltaCut
Definition: TrigVrtSecInclusive.h:77
TrigVSI::TrigVrtSecInclusive::m_fastD0minCut
Gaudi::Property< double > m_fastD0minCut
Definition: TrigVrtSecInclusive.h:76
DataVector::end
const_iterator end() const noexcept
Return a const_iterator pointing past the end of the collection.
SG::WriteHandle
Definition: StoreGate/StoreGate/WriteHandle.h:76
Trk::vertex
@ vertex
Definition: MeasurementType.h:21
DiTauMassTools::MaxHistStrategyV2::e
e
Definition: PhysicsAnalysis/TauID/DiTauMassTools/DiTauMassTools/HelperFunctions.h:26
a
TList * a
Definition: liststreamerinfos.cxx:10
TrigVSI::AlgConsts::binNumR
constexpr int binNumR
Default bin number of R for vertex map.
Definition: Trigger/TrigTools/TrigVrtSecInclusive/TrigVrtSecInclusive/Constants.h:29
TrigVSI::TrigVrtSecInclusive::m_maxTrks
Gaudi::Property< size_t > m_maxTrks
Definition: TrigVrtSecInclusive.h:90
h
xAOD::Vertex_v1
Class describing a Vertex.
Definition: Vertex_v1.h:42
ATH_MSG_WARNING
#define ATH_MSG_WARNING(x)
Definition: AthMsgStreamMacros.h:32
TrigVSI::TrigVrtSecInclusive::WrkVrtContainer
std::vector< WrkVrt > WrkVrtContainer
Definition: TrigVrtSecInclusive.h:174
AthCommonMsg< Gaudi::Algorithm >::msg
MsgStream & msg() const
Definition: AthCommonMsg.h:24
TrigVSI::TrigVrtSecInclusive::selectTrack_chi2Cut
bool selectTrack_chi2Cut(const xAOD::TrackParticle *trk) const
Definition: TrigVrtSecInclusive.cxx:1505
SG::VarHandleBase::vhKey
SG::VarHandleKey & vhKey()
Return a non-const reference to the HandleKey.
Definition: StoreGate/src/VarHandleBase.cxx:616
TrigVSI::TrigVrtSecInclusive::k_z0
@ k_z0
Definition: TrigVrtSecInclusive.h:169
TrigVSI::TrigVrtSecInclusive::m_cutBLayHits
Gaudi::Property< int > m_cutBLayHits
Definition: TrigVrtSecInclusive.h:59
declareProperty
#define declareProperty(n, p, h)
Definition: BaseFakeBkgTool.cxx:15
xAOD::numberOfSCTHits
@ numberOfSCTHits
number of hits in SCT [unit8_t].
Definition: TrackingPrimitives.h:268
TrigVSI::TrigVrtSecInclusive::m_selVrtChi2Cut
Gaudi::Property< double > m_selVrtChi2Cut
Definition: TrigVrtSecInclusive.h:81
TrigVSI::AlgConsts::IDrInner
constexpr float IDrInner
Minimum R of ID volume.
Definition: Trigger/TrigTools/TrigVrtSecInclusive/TrigVrtSecInclusive/Constants.h:21
xAOD::TrackParticle_v1::numberDoF
float numberDoF() const
Returns the number of degrees of freedom of the overall track or vertex fit as float.
python.Bindings.keys
keys
Definition: Control/AthenaPython/python/Bindings.py:790
xAOD::TrackParticle_v1
Class describing a TrackParticle.
Definition: TrackParticle_v1.h:43
LHEF::Writer
Pythia8::Writer Writer
Definition: Prophecy4fMerger.cxx:12
TrigVSI::TrigVrtSecInclusive::nTrkCommon
size_t nTrkCommon(WrkVrtContainer &, const std::pair< unsigned, unsigned > &) const
Definition: TrigVrtSecInclusive.cxx:1538
DataVector::at
const T * at(size_type n) const
Access an element, as an rvalue.
TrigVSI::TrigVrtSecInclusive::k_nTP
@ k_nTP
Definition: TrigVrtSecInclusive.h:169
TrigVSI::AlgConsts::nEta
constexpr int nEta
Default bin number of eta for vertex map.
Definition: Trigger/TrigTools/TrigVrtSecInclusive/TrigVrtSecInclusive/Constants.h:26
TrigVSI::TrigVrtSecInclusive::m_PrimaryVxInputName
SG::ReadHandleKey< xAOD::VertexContainer > m_PrimaryVxInputName
Definition: TrigVrtSecInclusive.h:199
TrigVSI::TrigVrtSecInclusive::m_twoTrkVtxFormingD0Cut
Gaudi::Property< double > m_twoTrkVtxFormingD0Cut
Definition: TrigVrtSecInclusive.h:68
TrigVSI::TrigVrtSecInclusive::m_materialMapOuter
TH3S * m_materialMapOuter
Definition: TrigVrtSecInclusive.h:178
TrigVSI::TrigVrtSecInclusive::m_fastZ0minCut
Gaudi::Property< double > m_fastZ0minCut
Definition: TrigVrtSecInclusive.h:78
Amg::distance
float distance(const Amg::Vector3D &p1, const Amg::Vector3D &p2)
calculates the distance between two point in 3D space
Definition: GeoPrimitivesHelpers.h:54
TrigVSI::TrigVrtSecInclusive::m_pvCompatibilityCut
Gaudi::Property< double > m_pvCompatibilityCut
Definition: TrigVrtSecInclusive.h:85
DataVector::size
size_type size() const noexcept
Returns the number of elements in the collection.
AthCommonDataStore::declareGaudiProperty
Gaudi::Details::PropertyBase & declareGaudiProperty(Gaudi::Property< T > &hndl, const SG::VarHandleKeyType &)
specialization for handling Gaudi::Property<SG::VarHandleKey>
Definition: AthCommonDataStore.h:156
Monitored::Timer
A monitored timer.
Definition: MonitoredTimer.h:32
TrigVSI::TrigVrtSecInclusive::m_cutSiHits
Gaudi::Property< int > m_cutSiHits
Definition: TrigVrtSecInclusive.h:58
TrigVSI::TrigVrtSecInclusive::m_d0TrkPVDstMinCut
Gaudi::Property< double > m_d0TrkPVDstMinCut
Definition: TrigVrtSecInclusive.h:64
TrigVSI::TrigVrtSecInclusive::m_secondPassTracksName
SG::ReadHandleKey< xAOD::TrackParticleContainer > m_secondPassTracksName
Definition: TrigVrtSecInclusive.h:196
TrigVSI::TrigVrtSecInclusive::k_d0d0
@ k_d0d0
Definition: TrigVrtSecInclusive.h:170
DataVector::begin
const_iterator begin() const noexcept
Return a const_iterator pointing at the beginning of the collection.
xAOD::TrackParticle_v1::phi
virtual double phi() const override final
The azimuthal angle ( ) of the particle (has range to .)
fitman.k
k
Definition: fitman.py:528
xAOD::numberOfInnermostPixelLayerHits
@ numberOfInnermostPixelLayerHits
these are the hits in the 0th pixel barrel layer
Definition: TrackingPrimitives.h:237
ServiceHandle< ICondSvc >
LArGeo::ATan2
GeoGenfun::FunctionNoop ATan2(GeoGenfun::GENFUNCTION y, GeoGenfun::GENFUNCTION x)
Definition: BarrelAuxFunctions.cxx:50
TrigVSI::TrigVrtSecInclusive::m_maxR
Gaudi::Property< double > m_maxR
Definition: TrigVrtSecInclusive.h:71