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

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

+ Inheritance diagram for PHTruthSiliconAssociation:
+ Collaboration diagram for PHTruthSiliconAssociation:

Classes

class  Deleter
 rng de-allocator More...
 

Public Member Functions

 PHTruthSiliconAssociation (const std::string &name="PHTruthSiliconAssociation")
 
int Init (PHCompositeNode *topNode) override
 
int InitRun (PHCompositeNode *topNode) override
 
int process_event (PHCompositeNode *topNode) override
 
int ResetEvent (PHCompositeNode *topNode) override
 Clean up internals after each event.
 
int EndRun (const int runnumber) override
 Called at the end of each run.
 
int End (PHCompositeNode *topNode) override
 Called at the end of all processing.
 
int Reset (PHCompositeNode *) override
 Reset.
 
void Print (const std::string &what="ALL") const override
 
- Public Member Functions inherited from SubsysReco
 ~SubsysReco () 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.
 

Private Member Functions

int GetNodes (PHCompositeNode *topNode)
 
unsigned int buildTrackSeed (std::set< TrkrDefs::cluskey > clusters, PHG4Particle *g4particle, TrackSeedContainer *container)
 
std::vector< PHG4Particle * > getG4PrimaryParticle (TrackSeed *track)
 
std::set< TrkrDefs::cluskeygetSiliconClustersFromParticle (PHG4Particle *g4particle)
 
std::set< short int > getInttCrossings (TrackSeed *si_track) const
 

Private Attributes

PHG4TruthInfoContainer_g4truth_container {nullptr}
 
PHG4HitContainer_g4hits_tpc {nullptr}
 
PHG4HitContainer_g4hits_mvtx {nullptr}
 
PHG4HitContainer_g4hits_intt {nullptr}
 
TrkrClusterContainer_cluster_map {nullptr}
 
TrkrClusterContainer_corrected_cluster_map {nullptr}
 
TrkrClusterHitAssoc_cluster_hit_map {nullptr}
 
TrkrHitTruthAssoc_hit_truth_map {nullptr}
 
TrackSeedContainer_tpc_track_map {nullptr}
 
TrackSeedContainer_silicon_track_map {nullptr}
 
TrackSeedContainer_svtx_seed_map {nullptr}
 
TrackSeed_tracklet {nullptr}
 
SvtxVertexMap_vertex_map {nullptr}
 
TrkrClusterCrossingAssoc_cluster_crossing_map {nullptr}
 
ActsGeometry_tgeometry {nullptr}
 
std::unique_ptr< gsl_rng, Deleterm_rng
 random generator that conform with sPHENIX standard
 

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 Member Functions inherited from SubsysReco
 SubsysReco (const std::string &name="NONAME")
 

Detailed Description

Definition at line 28 of file PHTruthSiliconAssociation.h.

View newest version in sPHENIX GitHub at line 28 of file PHTruthSiliconAssociation.h

Constructor & Destructor Documentation

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

Definition at line 44 of file PHTruthSiliconAssociation.cc.

View newest version in sPHENIX GitHub at line 44 of file PHTruthSiliconAssociation.cc

References gsl_rng_set(), m_rng, and seed.

+ Here is the call graph for this function:

Member Function Documentation

unsigned int PHTruthSiliconAssociation::buildTrackSeed ( std::set< TrkrDefs::cluskey clusters,
PHG4Particle g4particle,
TrackSeedContainer container 
)
private

Need to find the right one for the bend angle

We have to pick the right one based on the bend angle, so iterate through until you find the closest phi match

Definition at line 506 of file PHTruthSiliconAssociation.cc.

View newest version in sPHENIX GitHub at line 506 of file PHTruthSiliconAssociation.cc

References _cluster_map, _g4truth_container, _tgeometry, KFPMath::a, KFPMath::b, Acts::PhysicalConstants::c, charge(), eta, PHG4Particle::get_pid(), PHG4Particle::get_px(), PHG4Particle::get_py(), PHG4Particle::get_pz(), PHG4Particle::get_vtx_id(), getInttCrossings(), TrkrDefs::getTrkrId(), PHG4TruthInfoContainer::GetVtx(), TrackSeedContainer::insert(), TrkrDefs::inttId, m_rng, TrkrDefs::mvtxId, particle, ActsTests::PropagationDatasets::phi, physmon_track_finding_ttbar::pt, Acts::IntegrationTest::R, TrackSeedContainer::size(), square(), ActsTests::PropagationDatasets::theta, Fun4AllBase::Verbosity(), ambiguity_solver_full_chain::x, y, and physmon_track_finding_ttbar::z.

Referenced by process_event().

+ Here is the call graph for this function:

+ Here is the caller graph for this function:

int PHTruthSiliconAssociation::End ( PHCompositeNode topNode)
overridevirtual

Called at the end of all processing.

Reimplemented from SubsysReco.

Definition at line 190 of file PHTruthSiliconAssociation.cc.

View newest version in sPHENIX GitHub at line 190 of file PHTruthSiliconAssociation.cc

References Fun4AllReturnCodes::EVENT_OK.

int PHTruthSiliconAssociation::EndRun ( const int  runnumber)
overridevirtual

Called at the end of each run.

Reimplemented from SubsysReco.

Definition at line 184 of file PHTruthSiliconAssociation.cc.

View newest version in sPHENIX GitHub at line 184 of file PHTruthSiliconAssociation.cc

References Fun4AllReturnCodes::EVENT_OK.

std::vector< PHG4Particle * > PHTruthSiliconAssociation::getG4PrimaryParticle ( TrackSeed track)
private

Definition at line 331 of file PHTruthSiliconAssociation.cc.

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

References _cluster_hit_map, _g4hits_intt, _g4hits_mvtx, _g4hits_tpc, _g4truth_container, _hit_truth_map, TrackSeed::begin_cluster_keys(), TrackSeed::end_cluster_keys(), PHG4HitContainer::findHit(), PHG4Hit::get_trkid(), TrkrHitTruthAssoc::getG4Hits(), TrkrClusterHitAssoc::getHits(), TrkrDefs::getHitSetKeyFromClusKey(), PHG4TruthInfoContainer::GetParticle(), TrkrDefs::getTrkrId(), TrkrDefs::inttId, it, TrkrDefs::mvtxId, train_ambiguity_solver::pid, TrkrDefs::tpcId, and Fun4AllBase::Verbosity().

Referenced by process_event().

+ Here is the call graph for this function:

+ Here is the caller graph for this function:

std::set< short int > PHTruthSiliconAssociation::getInttCrossings ( TrackSeed si_track) const
private

Definition at line 471 of file PHTruthSiliconAssociation.cc.

View newest version in sPHENIX GitHub at line 471 of file PHTruthSiliconAssociation.cc

References _cluster_crossing_map, TrackSeed::begin_cluster_keys(), TrackSeed::end_cluster_keys(), TrkrClusterCrossingAssoc::getCrossings(), TrkrDefs::getLayer(), TrkrDefs::getTrkrId(), TrkrDefs::inttId, layer, and Fun4AllBase::Verbosity().

Referenced by buildTrackSeed().

+ Here is the call graph for this function:

+ Here is the caller graph for this function:

int PHTruthSiliconAssociation::GetNodes ( PHCompositeNode topNode)
private

Get the DST Node

Check that it is there

Get the tracking subnode under DST

Check that it is there

Definition at line 223 of file PHTruthSiliconAssociation.cc.

View newest version in sPHENIX GitHub at line 223 of file PHTruthSiliconAssociation.cc

References _cluster_crossing_map, _cluster_hit_map, _cluster_map, _g4hits_intt, _g4hits_mvtx, _g4hits_tpc, _g4truth_container, _hit_truth_map, _silicon_track_map, _svtx_seed_map, _tgeometry, _tpc_track_map, Fun4AllReturnCodes::ABORTEVENT, PHCompositeNode::addNode(), Fun4AllReturnCodes::EVENT_OK, PHNodeIterator::findFirst(), and PHWHERE.

Referenced by InitRun().

+ Here is the call graph for this function:

+ Here is the caller graph for this function:

std::set< TrkrDefs::cluskey > PHTruthSiliconAssociation::getSiliconClustersFromParticle ( PHG4Particle g4particle)
private

Definition at line 411 of file PHTruthSiliconAssociation.cc.

View newest version in sPHENIX GitHub at line 411 of file PHTruthSiliconAssociation.cc

References _cluster_hit_map, _cluster_map, _g4hits_intt, _g4hits_mvtx, _hit_truth_map, clusters, PHG4HitContainer::findHit(), PHG4Particle::get_track_id(), PHG4Hit::get_trkid(), TrkrClusterContainer::getClusters(), TrkrHitTruthAssoc::getG4Hits(), TrkrClusterHitAssoc::getHits(), TrkrDefs::getHitSetKeyFromClusKey(), TrkrClusterContainer::getHitSetKeys(), TrkrDefs::getLayer(), TrkrDefs::getTrkrId(), TrkrDefs::inttId, layer, and TrkrDefs::mvtxId.

Referenced by process_event().

+ Here is the call graph for this function:

+ Here is the caller graph for this function:

int PHTruthSiliconAssociation::Init ( PHCompositeNode )
overridevirtual

Called during initialization. Typically this is where you can book histograms, and e.g. register them to Fun4AllServer (so they can be output to file using Fun4AllServer::dumpHistos() method).

Reimplemented from SubsysReco.

Definition at line 54 of file PHTruthSiliconAssociation.cc.

View newest version in sPHENIX GitHub at line 54 of file PHTruthSiliconAssociation.cc

References Fun4AllReturnCodes::EVENT_OK.

int PHTruthSiliconAssociation::InitRun ( PHCompositeNode )
overridevirtual

Called for first event when run number is known. Typically this is where you may want to fetch data from database, because you know the run number.

Reimplemented from SubsysReco.

Definition at line 61 of file PHTruthSiliconAssociation.cc.

View newest version in sPHENIX GitHub at line 61 of file PHTruthSiliconAssociation.cc

References GetNodes().

+ Here is the call graph for this function:

void PHTruthSiliconAssociation::Print ( const std::string &  what = "ALL") const
overridevirtual

Print out some info about this module.

Parameters
whatcan be used to specify what to print exactly.

Reimplemented from SubsysReco.

Definition at line 202 of file PHTruthSiliconAssociation.cc.

View newest version in sPHENIX GitHub at line 202 of file PHTruthSiliconAssociation.cc

int PHTruthSiliconAssociation::process_event ( PHCompositeNode )
overridevirtual

Called for each event. This is where you do the real work.

Reimplemented from SubsysReco.

Definition at line 69 of file PHTruthSiliconAssociation.cc.

View newest version in sPHENIX GitHub at line 69 of file PHTruthSiliconAssociation.cc

References _silicon_track_map, _svtx_seed_map, _tpc_track_map, _tracklet, buildTrackSeed(), clusters, Fun4AllReturnCodes::EVENT_OK, TrackSeedContainer::get(), TrackSeed::get_silicon_seed_index(), TrackSeed::get_tpc_seed_index(), getG4PrimaryParticle(), getSiliconClustersFromParticle(), TrackSeed::identify(), TrackSeedContainer::insert(), PHObject::Reset(), seed, TrackSeedContainer::size(), and Fun4AllBase::Verbosity().

+ Here is the call graph for this function:

int PHTruthSiliconAssociation::Reset ( PHCompositeNode )
overridevirtual

Reset.

Reimplemented from SubsysReco.

Definition at line 196 of file PHTruthSiliconAssociation.cc.

View newest version in sPHENIX GitHub at line 196 of file PHTruthSiliconAssociation.cc

References Fun4AllReturnCodes::EVENT_OK.

int PHTruthSiliconAssociation::ResetEvent ( PHCompositeNode topNode)
overridevirtual

Clean up internals after each event.

Reimplemented from SubsysReco.

Definition at line 177 of file PHTruthSiliconAssociation.cc.

View newest version in sPHENIX GitHub at line 177 of file PHTruthSiliconAssociation.cc

References Fun4AllReturnCodes::EVENT_OK.

Member Data Documentation

TrkrClusterCrossingAssoc* PHTruthSiliconAssociation::_cluster_crossing_map {nullptr}
private

Definition at line 80 of file PHTruthSiliconAssociation.h.

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

Referenced by getInttCrossings(), and GetNodes().

TrkrClusterHitAssoc* PHTruthSiliconAssociation::_cluster_hit_map {nullptr}
private

Definition at line 73 of file PHTruthSiliconAssociation.h.

View newest version in sPHENIX GitHub at line 73 of file PHTruthSiliconAssociation.h

Referenced by getG4PrimaryParticle(), GetNodes(), and getSiliconClustersFromParticle().

TrkrClusterContainer* PHTruthSiliconAssociation::_cluster_map {nullptr}
private

Definition at line 71 of file PHTruthSiliconAssociation.h.

View newest version in sPHENIX GitHub at line 71 of file PHTruthSiliconAssociation.h

Referenced by buildTrackSeed(), GetNodes(), and getSiliconClustersFromParticle().

TrkrClusterContainer* PHTruthSiliconAssociation::_corrected_cluster_map {nullptr}
private

Definition at line 72 of file PHTruthSiliconAssociation.h.

View newest version in sPHENIX GitHub at line 72 of file PHTruthSiliconAssociation.h

PHG4HitContainer* PHTruthSiliconAssociation::_g4hits_intt {nullptr}
private

Definition at line 69 of file PHTruthSiliconAssociation.h.

View newest version in sPHENIX GitHub at line 69 of file PHTruthSiliconAssociation.h

Referenced by getG4PrimaryParticle(), GetNodes(), and getSiliconClustersFromParticle().

PHG4HitContainer* PHTruthSiliconAssociation::_g4hits_mvtx {nullptr}
private

Definition at line 68 of file PHTruthSiliconAssociation.h.

View newest version in sPHENIX GitHub at line 68 of file PHTruthSiliconAssociation.h

Referenced by getG4PrimaryParticle(), GetNodes(), and getSiliconClustersFromParticle().

PHG4HitContainer* PHTruthSiliconAssociation::_g4hits_tpc {nullptr}
private

Definition at line 67 of file PHTruthSiliconAssociation.h.

View newest version in sPHENIX GitHub at line 67 of file PHTruthSiliconAssociation.h

Referenced by getG4PrimaryParticle(), and GetNodes().

PHG4TruthInfoContainer* PHTruthSiliconAssociation::_g4truth_container {nullptr}
private

Definition at line 66 of file PHTruthSiliconAssociation.h.

View newest version in sPHENIX GitHub at line 66 of file PHTruthSiliconAssociation.h

Referenced by buildTrackSeed(), getG4PrimaryParticle(), and GetNodes().

TrkrHitTruthAssoc* PHTruthSiliconAssociation::_hit_truth_map {nullptr}
private

Definition at line 74 of file PHTruthSiliconAssociation.h.

View newest version in sPHENIX GitHub at line 74 of file PHTruthSiliconAssociation.h

Referenced by getG4PrimaryParticle(), GetNodes(), and getSiliconClustersFromParticle().

TrackSeedContainer* PHTruthSiliconAssociation::_silicon_track_map {nullptr}
private

Definition at line 76 of file PHTruthSiliconAssociation.h.

View newest version in sPHENIX GitHub at line 76 of file PHTruthSiliconAssociation.h

Referenced by GetNodes(), and process_event().

TrackSeedContainer* PHTruthSiliconAssociation::_svtx_seed_map {nullptr}
private

Definition at line 77 of file PHTruthSiliconAssociation.h.

View newest version in sPHENIX GitHub at line 77 of file PHTruthSiliconAssociation.h

Referenced by GetNodes(), and process_event().

ActsGeometry* PHTruthSiliconAssociation::_tgeometry {nullptr}
private

Definition at line 81 of file PHTruthSiliconAssociation.h.

View newest version in sPHENIX GitHub at line 81 of file PHTruthSiliconAssociation.h

Referenced by buildTrackSeed(), and GetNodes().

TrackSeedContainer* PHTruthSiliconAssociation::_tpc_track_map {nullptr}
private

Definition at line 75 of file PHTruthSiliconAssociation.h.

View newest version in sPHENIX GitHub at line 75 of file PHTruthSiliconAssociation.h

Referenced by GetNodes(), and process_event().

TrackSeed* PHTruthSiliconAssociation::_tracklet {nullptr}
private

Definition at line 78 of file PHTruthSiliconAssociation.h.

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

Referenced by process_event().

SvtxVertexMap* PHTruthSiliconAssociation::_vertex_map {nullptr}
private

Definition at line 79 of file PHTruthSiliconAssociation.h.

View newest version in sPHENIX GitHub at line 79 of file PHTruthSiliconAssociation.h

std::unique_ptr<gsl_rng, Deleter> PHTruthSiliconAssociation::m_rng
private

random generator that conform with sPHENIX standard

using a unique_ptr with custom Deleter ensures that the structure is properly freed when parent object is destroyed

Definition at line 93 of file PHTruthSiliconAssociation.h.

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

Referenced by buildTrackSeed(), and PHTruthSiliconAssociation().


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