Analysis Software
Documentation for sPHENIX simulation software
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Groups Pages
PHActsVertexFinder Class Reference

#include <coresoftware/blob/master/offline/packages/trackreco/PHActsVertexFinder.h>

+ Inheritance diagram for PHActsVertexFinder:
+ Collaboration diagram for PHActsVertexFinder:

Public Member Functions

 PHActsVertexFinder (const std::string &name="PHActsVertexFinder")
 
 ~PHActsVertexFinder () override
 
void setMaxVertices (int maxVertices)
 
void setFieldMap (const std::string &fieldMap)
 
- Public Member Functions inherited from PHInitVertexing
 PHInitVertexing (const std::string &name="PHInitVertexing")
 
 ~PHInitVertexing () override=default
 
int InitRun (PHCompositeNode *topNode) override
 
int process_event (PHCompositeNode *topNode) override
 
- Public Member Functions inherited from SubsysReco
 ~SubsysReco () override
 
virtual int EndRun (const int)
 Called at the end of each run.
 
virtual int Init (PHCompositeNode *)
 
virtual int Reset (PHCompositeNode *)
 Reset.
 
void Print (const std::string &="ALL") const override
 
- Public Member Functions inherited from Fun4AllBase
virtual ~Fun4AllBase ()
 
virtual const std::string Name () const
 Returns the name of this module.
 
virtual void Name (const std::string &name)
 Sets the name of this module.
 
virtual void Verbosity (const int ival)
 Sets the verbosity of this module (0 by default=quiet).
 
virtual void Verbosity (enu_Verbosity ival)
 Sets the verbosity of this module (0 by default=quiet).
 
virtual int Verbosity () const
 Gets the verbosity of this module.
 

Protected Member Functions

int Setup (PHCompositeNode *topNode) override
 
int Process (PHCompositeNode *topNode) override
 
int ResetEvent (PHCompositeNode *topNode) override
 Clean up after each event.
 
int End (PHCompositeNode *topNode) override
 Called at the end of all processing.
 

Private Member Functions

int createNodes (PHCompositeNode *topNode)
 
int getNodes (PHCompositeNode *topNode)
 
TrackPtrVector getTracks (KeyMap &keyMap)
 Get list of tracks from PHActsTrkFitter to vertex fit.
 
VertexVector findVertices (TrackPtrVector &tracks)
 Call acts vertex finder.
 
void fillVertexMap (VertexVector &vertices, KeyMap &keyMap)
 Fill maps with relevant vertex information.
 
void updateTrackDCA (const unsigned int trackKey, const Acts::Vector3D vertex)
 
void checkTrackVertexAssociation ()
 

Private Attributes

VertexMapm_actsVertexMap
 An Acts vertex object map.
 
int m_event = 0
 
int m_maxVertices = 20
 
int m_goodFits = 0
 
int m_totalFits = 0
 
std::string m_fieldMap = ""
 
SvtxVertexMapm_svtxVertexMap = nullptr
 
SvtxVertexMapm_svtxVertexMapActs = nullptr
 
ActsTrackingGeometrym_tGeometry = nullptr
 
SvtxTrackMapm_svtxTrackMap = nullptr
 
std::map< const unsigned int,
Trajectory > * 
m_trajectories = nullptr
 

Additional Inherited Members

- Public Types inherited from Fun4AllBase
enum  enu_Verbosity {
  VERBOSITY_QUIET = 0, VERBOSITY_SOME = 1, VERBOSITY_MORE = 2, VERBOSITY_EVEN_MORE = 3,
  VERBOSITY_A_LOT = 4, VERBOSITY_MAX = std::numeric_limits<int>::max() - 10
}
 
- Protected Attributes inherited from PHInitVertexing
TrkrClusterContainer_cluster_map = nullptr
 
SvtxVertexMap_vertex_map = nullptr
 

Detailed Description

This class calls the Acts::IterativeVertexFinder which takes a list of tracks and returns a list of vertices that are found.

Definition at line 37 of file PHActsVertexFinder.h.

View newest version in sPHENIX GitHub at line 37 of file PHActsVertexFinder.h

Constructor & Destructor Documentation

PHActsVertexFinder::PHActsVertexFinder ( const std::string &  name = "PHActsVertexFinder")

Definition at line 52 of file PHActsVertexFinder.cc.

View newest version in sPHENIX GitHub at line 52 of file PHActsVertexFinder.cc

PHActsVertexFinder::~PHActsVertexFinder ( )
inlineoverride

Definition at line 43 of file PHActsVertexFinder.h.

View newest version in sPHENIX GitHub at line 43 of file PHActsVertexFinder.h

Member Function Documentation

void PHActsVertexFinder::checkTrackVertexAssociation ( )
private

Secondary not used in Acts vertex fitting. Assign closest vertex based on z position

Definition at line 129 of file PHActsVertexFinder.cc.

View newest version in sPHENIX GitHub at line 129 of file PHActsVertexFinder.cc

References dz, SvtxVertexMap::get(), m_svtxTrackMap, and m_svtxVertexMap.

Referenced by Process().

+ Here is the call graph for this function:

+ Here is the caller graph for this function:

int PHActsVertexFinder::createNodes ( PHCompositeNode topNode)
private

Definition at line 488 of file PHActsVertexFinder.cc.

View newest version in sPHENIX GitHub at line 488 of file PHActsVertexFinder.cc

References PHCompositeNode::addNode(), Fun4AllReturnCodes::EVENT_OK, PHNodeIterator::findFirst(), m_actsVertexMap, m_svtxVertexMap, and m_svtxVertexMapActs.

Referenced by Setup().

+ Here is the call graph for this function:

+ Here is the caller graph for this function:

int PHActsVertexFinder::End ( PHCompositeNode )
overrideprotectedvirtual

Called at the end of all processing.

Reimplemented from SubsysReco.

Definition at line 120 of file PHActsVertexFinder.cc.

View newest version in sPHENIX GitHub at line 120 of file PHActsVertexFinder.cc

References Fun4AllReturnCodes::EVENT_OK, m_goodFits, and m_totalFits.

void PHActsVertexFinder::fillVertexMap ( VertexVector vertices,
KeyMap keyMap 
)
private

Fill maps with relevant vertex information.

Fill Acts vertex map

Fill SvtxVertexMap

Definition at line 331 of file PHActsVertexFinder.cc.

View newest version in sPHENIX GitHub at line 331 of file PHActsVertexFinder.cc

References SvtxVertexMap::clear(), Acts::UnitConstants::cm, Acts::UnitConstants::cm2, SvtxTrackMap::find(), i, SvtxVertex::identify(), SvtxVertexMap::insert(), j, m_actsVertexMap, m_svtxTrackMap, m_svtxVertexMap, updateTrackDCA(), and Fun4AllBase::Verbosity().

Referenced by Process().

+ Here is the call graph for this function:

+ Here is the caller graph for this function:

VertexVector PHActsVertexFinder::findVertices ( TrackPtrVector tracks)
private

Call acts vertex finder.

Determine the input mag field type from the initial geometry and run the vertex finding with the determined mag field

Setup aliases

Setup vertex finder now

end lambda

end std::visit call

Definition at line 227 of file PHActsVertexFinder.cc.

View newest version in sPHENIX GitHub at line 227 of file PHActsVertexFinder.cc

References Acts::IntegrationTest::bField, filter::Config, Acts::Logging::FATAL, ckf::field, Acts::getDefaultLogger(), ActsTrackingGeometry::getGeoContext(), logger(), telescope_simulation::logLevel, m_goodFits, m_maxVertices, m_tGeometry, m_totalFits, ActsTrackingGeometry::magField, ActsTrackingGeometry::magFieldContext, testing::internal::move(), physmon_track_finding_ttbar::seeder, filter::state, Acts::Logging::VERBOSE, and Fun4AllBase::Verbosity().

Referenced by Process().

+ Here is the call graph for this function:

+ Here is the caller graph for this function:

int PHActsVertexFinder::getNodes ( PHCompositeNode topNode)
private

Definition at line 546 of file PHActsVertexFinder.cc.

View newest version in sPHENIX GitHub at line 546 of file PHActsVertexFinder.cc

References Fun4AllReturnCodes::ABORTEVENT, Fun4AllReturnCodes::EVENT_OK, m_svtxTrackMap, m_tGeometry, m_trajectories, and PHWHERE.

Referenced by Setup().

+ Here is the caller graph for this function:

TrackPtrVector PHActsVertexFinder::getTracks ( KeyMap keyMap)
private

Get list of tracks from PHActsTrkFitter to vertex fit.

Definition at line 161 of file PHActsVertexFinder.cc.

View newest version in sPHENIX GitHub at line 161 of file PHActsVertexFinder.cc

References SvtxTrackMap::get(), ActsTrackingGeometry::getGeoContext(), TrkrDefs::getTrkrId(), TrkrDefs::inttId, m_svtxTrackMap, m_tGeometry, m_trajectories, TrkrDefs::mvtxId, TrkrDefs::tpcId, and Fun4AllBase::Verbosity().

Referenced by Process().

+ Here is the call graph for this function:

+ Here is the caller graph for this function:

int PHActsVertexFinder::Process ( PHCompositeNode topNode)
overrideprotectedvirtual

process event interface for trackers, called in process_event. implemented in derived classes

Create a map that correlates the track momentum to the track key

Get the list of tracks in Acts form

Clean up the track pointer vector memory

Implements PHInitVertexing.

Definition at line 72 of file PHActsVertexFinder.cc.

View newest version in sPHENIX GitHub at line 72 of file PHActsVertexFinder.cc

References checkTrackVertexAssociation(), Fun4AllReturnCodes::EVENT_OK, fillVertexMap(), findVertices(), getTracks(), SvtxVertexMap::insert(), m_event, m_svtxVertexMap, m_svtxVertexMapActs, Fun4AllBase::Verbosity(), and ActsExamples::HepMC3Event::vertices().

+ Here is the call graph for this function:

int PHActsVertexFinder::ResetEvent ( PHCompositeNode )
overrideprotectedvirtual

Clean up after each event.

Reimplemented from SubsysReco.

Definition at line 111 of file PHActsVertexFinder.cc.

View newest version in sPHENIX GitHub at line 111 of file PHActsVertexFinder.cc

References SvtxVertexMap::clear(), Fun4AllReturnCodes::EVENT_OK, m_actsVertexMap, and m_svtxVertexMap.

+ Here is the call graph for this function:

void PHActsVertexFinder::setFieldMap ( const std::string &  fieldMap)
inline

Definition at line 48 of file PHActsVertexFinder.h.

View newest version in sPHENIX GitHub at line 48 of file PHActsVertexFinder.h

References m_fieldMap.

void PHActsVertexFinder::setMaxVertices ( int  maxVertices)
inline

Definition at line 45 of file PHActsVertexFinder.h.

View newest version in sPHENIX GitHub at line 45 of file PHActsVertexFinder.h

References m_maxVertices.

int PHActsVertexFinder::Setup ( PHCompositeNode topNode)
overrideprotectedvirtual

setup interface for trackers, called in InitRun, setup things like pointers to nodes. overrided in derived classes

Reimplemented from PHInitVertexing.

Definition at line 59 of file PHActsVertexFinder.cc.

View newest version in sPHENIX GitHub at line 59 of file PHActsVertexFinder.cc

References createNodes(), Fun4AllReturnCodes::EVENT_OK, and getNodes().

+ Here is the call graph for this function:

void PHActsVertexFinder::updateTrackDCA ( const unsigned int  trackKey,
const Acts::Vector3D  vertex 
)
private

Definition at line 432 of file PHActsVertexFinder.cc.

View newest version in sPHENIX GitHub at line 432 of file PHActsVertexFinder.cc

References SvtxTrackMap::find(), i, j, m_svtxTrackMap, ActsTests::PropagationDatasets::phi, Acts::Test::pos, and physmon_track_finding_ttbar::r.

Referenced by fillVertexMap().

+ Here is the call graph for this function:

+ Here is the caller graph for this function:

Member Data Documentation

VertexMap* PHActsVertexFinder::m_actsVertexMap
private

An Acts vertex object map.

Definition at line 78 of file PHActsVertexFinder.h.

View newest version in sPHENIX GitHub at line 78 of file PHActsVertexFinder.h

Referenced by createNodes(), fillVertexMap(), and ResetEvent().

int PHActsVertexFinder::m_event = 0
private

Definition at line 80 of file PHActsVertexFinder.h.

View newest version in sPHENIX GitHub at line 80 of file PHActsVertexFinder.h

Referenced by Process().

std::string PHActsVertexFinder::m_fieldMap = ""
private

Definition at line 87 of file PHActsVertexFinder.h.

View newest version in sPHENIX GitHub at line 87 of file PHActsVertexFinder.h

Referenced by setFieldMap().

int PHActsVertexFinder::m_goodFits = 0
private

Definition at line 85 of file PHActsVertexFinder.h.

View newest version in sPHENIX GitHub at line 85 of file PHActsVertexFinder.h

Referenced by End(), and findVertices().

int PHActsVertexFinder::m_maxVertices = 20
private

Maximum number of vertices that the Acts finder is allowed to find

Definition at line 83 of file PHActsVertexFinder.h.

View newest version in sPHENIX GitHub at line 83 of file PHActsVertexFinder.h

Referenced by findVertices(), and setMaxVertices().

SvtxTrackMap* PHActsVertexFinder::m_svtxTrackMap = nullptr
private

Definition at line 92 of file PHActsVertexFinder.h.

View newest version in sPHENIX GitHub at line 92 of file PHActsVertexFinder.h

Referenced by checkTrackVertexAssociation(), fillVertexMap(), getNodes(), getTracks(), and updateTrackDCA().

SvtxVertexMap* PHActsVertexFinder::m_svtxVertexMap = nullptr
private

Definition at line 89 of file PHActsVertexFinder.h.

View newest version in sPHENIX GitHub at line 89 of file PHActsVertexFinder.h

Referenced by checkTrackVertexAssociation(), createNodes(), fillVertexMap(), Process(), and ResetEvent().

SvtxVertexMap* PHActsVertexFinder::m_svtxVertexMapActs = nullptr
private

Definition at line 90 of file PHActsVertexFinder.h.

View newest version in sPHENIX GitHub at line 90 of file PHActsVertexFinder.h

Referenced by createNodes(), and Process().

ActsTrackingGeometry* PHActsVertexFinder::m_tGeometry = nullptr
private

Definition at line 91 of file PHActsVertexFinder.h.

View newest version in sPHENIX GitHub at line 91 of file PHActsVertexFinder.h

Referenced by findVertices(), getNodes(), and getTracks().

int PHActsVertexFinder::m_totalFits = 0
private

Definition at line 86 of file PHActsVertexFinder.h.

View newest version in sPHENIX GitHub at line 86 of file PHActsVertexFinder.h

Referenced by End(), and findVertices().

std::map<const unsigned int, Trajectory>* PHActsVertexFinder::m_trajectories = nullptr
private

Definition at line 93 of file PHActsVertexFinder.h.

View newest version in sPHENIX GitHub at line 93 of file PHActsVertexFinder.h

Referenced by getNodes(), and getTracks().


The documentation for this class was generated from the following files: