ECCE @ EIC Software
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Groups Pages
PHActsTrackProjection Class Reference

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

+ Inheritance diagram for PHActsTrackProjection:
+ Collaboration diagram for PHActsTrackProjection:

Public Member Functions

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

Private Member Functions

int getNodes (PHCompositeNode *topNode)
 
int projectTracks (PHCompositeNode *topNode, int caloLayer)
 
BoundTrackParamPtrResult propagateTrack (const Acts::BoundTrackParameters &params, const SurfacePtr &targetSurf)
 Propagate the fitted track parameters to a surface with Acts.
 
int setCaloContainerNodes (PHCompositeNode *topNode, const int caloLayer)
 Set the particular calo nodes depending on which layer.
 
int makeCaloSurfacePtrs (PHCompositeNode *topNode)
 Make Acts::CylinderSurface objects corresponding to the calos.
 
void updateSvtxTrack (const Acts::BoundTrackParameters &params, SvtxTrack *svtxTrack, const int caloLayer)
 Update the SvtxTrack object with the track-cluster match.
 
void getSquareTowerEnergies (int phiBin, int etaBin, double &energy3x3, double &energy5x5)
 Get 3x3 and 5x5 tower sums matched to a track.
 
void getClusterProperties (double phi, double eta, double &minIndex, double &minDphi, double &minDeta, double &minE)
 Get the cluster values for a particular matched track.
 
Acts::BoundTrackParameters makeTrackParams (SvtxTrack *track)
 
double deltaPhi (const double &phi)
 
Acts::Vector3D getVertex (SvtxTrack *track)
 

Private Attributes

ActsTrackingGeometrym_tGeometry = nullptr
 Objects containing the Acts track fit results.
 
SvtxTrackMapm_trackMap = nullptr
 
SvtxVertexMapm_vertexMap = nullptr
 
std::map< const unsigned int,
Trajectory > * 
m_trajectories {nullptr}
 
std::vector< std::string > m_caloNames
 
std::vector< SvtxTrack::CAL_LAYERm_caloTypes
 
std::map< std::string, SurfacePtrm_caloSurfaces
 
RawTowerGeomContainerm_towerGeomContainer = nullptr
 
RawTowerContainerm_towerContainer = nullptr
 
RawClusterContainerm_clusterContainer = nullptr
 
bool m_useCemcPosRecalib = false
 
int m_event = 0
 

Static Private Attributes

static const int m_nCaloLayers = 3
 

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

Detailed Description

This class takes final fitted tracks from the Acts track fitting and projects them out to cylinders with radius at the same radius as the three calorimeters. Cluster matching is performed with the projections and the SvtxTrack object is updated.

Definition at line 44 of file PHActsTrackProjection.h.

View newest version in sPHENIX GitHub at line 44 of file PHActsTrackProjection.h

Constructor & Destructor Documentation

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

Definition at line 38 of file PHActsTrackProjection.cc.

View newest version in sPHENIX GitHub at line 38 of file PHActsTrackProjection.cc

References SvtxTrack::CEMC, SvtxTrack::HCALIN, SvtxTrack::HCALOUT, m_caloNames, and m_caloTypes.

Member Function Documentation

double PHActsTrackProjection::deltaPhi ( const double &  phi)
private

Definition at line 488 of file PHActsTrackProjection.cc.

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

References M_PI, and phi.

Referenced by getClusterProperties().

+ Here is the caller graph for this function:

int PHActsTrackProjection::End ( PHCompositeNode )
overridevirtual

Called at the end of all processing.

Reimplemented from SubsysReco.

Definition at line 98 of file PHActsTrackProjection.cc.

View newest version in sPHENIX GitHub at line 98 of file PHActsTrackProjection.cc

References Fun4AllReturnCodes::EVENT_OK.

void PHActsTrackProjection::getClusterProperties ( double  phi,
double  eta,
double &  minIndex,
double &  minDphi,
double &  minDeta,
double &  minE 
)
private

Get the cluster values for a particular matched track.

Definition at line 253 of file PHActsTrackProjection.cc.

View newest version in sPHENIX GitHub at line 253 of file PHActsTrackProjection.cc

References DBL_MAX, deltaPhi(), RawClusterContainer::getClustersMap(), RawClusterUtility::GetPseudorapidity(), m_clusterContainer, and r.

Referenced by updateSvtxTrack().

+ Here is the call graph for this function:

+ Here is the caller graph for this function:

int PHActsTrackProjection::getNodes ( PHCompositeNode topNode)
private

Definition at line 449 of file PHActsTrackProjection.cc.

View newest version in sPHENIX GitHub at line 449 of file PHActsTrackProjection.cc

References Fun4AllReturnCodes::ABORTEVENT, Fun4AllReturnCodes::EVENT_OK, m_tGeometry, m_trackMap, m_trajectories, m_vertexMap, and PHWHERE.

Referenced by InitRun().

+ Here is the caller graph for this function:

void PHActsTrackProjection::getSquareTowerEnergies ( int  phiBin,
int  etaBin,
double &  energy3x3,
double &  energy5x5 
)
private

Get 3x3 and 5x5 tower sums matched to a track.

Check the phi periodic boundary conditions

Check the eta boundary conditions

Definition at line 284 of file PHActsTrackProjection.cc.

View newest version in sPHENIX GitHub at line 284 of file PHActsTrackProjection.cc

References kdfinder::abs(), RawTower::get_energy(), RawTowerGeomContainer::get_etabins(), RawTowerGeomContainer::get_phibins(), RawTowerContainer::getTower(), m_towerContainer, and m_towerGeomContainer.

Referenced by updateSvtxTrack().

+ Here is the call graph for this function:

+ Here is the caller graph for this function:

Acts::Vector3D PHActsTrackProjection::getVertex ( SvtxTrack track)
private

Definition at line 169 of file PHActsTrackProjection.cc.

View newest version in sPHENIX GitHub at line 169 of file PHActsTrackProjection.cc

References Acts::UnitConstants::cm, SvtxVertexMap::get(), SvtxTrack::get_vertex_id(), SvtxVertex::get_x(), SvtxVertex::get_y(), SvtxVertex::get_z(), and m_vertexMap.

Referenced by makeTrackParams().

+ Here is the call graph for this function:

+ Here is the caller graph for this function:

int PHActsTrackProjection::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 93 of file PHActsTrackProjection.cc.

View newest version in sPHENIX GitHub at line 93 of file PHActsTrackProjection.cc

References Fun4AllReturnCodes::EVENT_OK.

int PHActsTrackProjection::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 51 of file PHActsTrackProjection.cc.

View newest version in sPHENIX GitHub at line 51 of file PHActsTrackProjection.cc

References Fun4AllReturnCodes::ABORTEVENT, Fun4AllReturnCodes::EVENT_OK, getNodes(), makeCaloSurfacePtrs(), and Fun4AllBase::Verbosity().

+ Here is the call graph for this function:

int PHActsTrackProjection::makeCaloSurfacePtrs ( PHCompositeNode topNode)
private

Make Acts::CylinderSurface objects corresponding to the calos.

Extend farther so that there is at least surface there, for high curling tracks. Can always reject later

Make a cylindrical surface at (0,0,0) aligned along the z axis

Definition at line 407 of file PHActsTrackProjection.cc.

View newest version in sPHENIX GitHub at line 407 of file PHActsTrackProjection.cc

References Fun4AllReturnCodes::ABORTEVENT, Acts::UnitConstants::cm, Acts::VectorHelpers::eta(), Fun4AllReturnCodes::EVENT_OK, ActsTrackingGeometry::geoContext, RawTowerGeomContainer::get_radius(), m_caloNames, m_caloSurfaces, m_nCaloLayers, m_tGeometry, m_towerGeomContainer, setCaloContainerNodes(), theta(), Acts::Test::transform, and Fun4AllBase::Verbosity().

Referenced by InitRun().

+ Here is the call graph for this function:

+ Here is the caller graph for this function:

Acts::BoundTrackParameters PHActsTrackProjection::makeTrackParams ( SvtxTrack track)
private

Definition at line 142 of file PHActsTrackProjection.cc.

View newest version in sPHENIX GitHub at line 142 of file PHActsTrackProjection.cc

References Acts::UnitConstants::cm, ActsTrackingGeometry::geoContext, SvtxTrack::get_acts_covariance(), SvtxTrack::get_charge(), SvtxTrack::get_p(), SvtxTrack::get_px(), SvtxTrack::get_py(), SvtxTrack::get_pz(), SvtxTrack::get_x(), SvtxTrack::get_y(), SvtxTrack::get_z(), getVertex(), m_tGeometry, momentum, and Acts::UnitConstants::ns.

+ Here is the call graph for this function:

int PHActsTrackProjection::process_event ( PHCompositeNode )
overridevirtual

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

Reimplemented from SubsysReco.

Definition at line 67 of file PHActsTrackProjection.cc.

View newest version in sPHENIX GitHub at line 67 of file PHActsTrackProjection.cc

References Fun4AllReturnCodes::ABORTEVENT, Fun4AllReturnCodes::EVENT_OK, G4TTL::layer, m_caloNames, m_event, m_nCaloLayers, projectTracks(), and Fun4AllBase::Verbosity().

+ Here is the call graph for this function:

int PHActsTrackProjection::projectTracks ( PHCompositeNode topNode,
int  caloLayer 
)
private

Definition at line 104 of file PHActsTrackProjection.cc.

View newest version in sPHENIX GitHub at line 104 of file PHActsTrackProjection.cc

References Fun4AllReturnCodes::ABORTEVENT, Fun4AllReturnCodes::EVENT_OK, SvtxTrackMap::get(), m_caloNames, m_caloSurfaces, m_trackMap, m_trajectories, PHWHERE, propagateTrack(), second, setCaloContainerNodes(), track, updateSvtxTrack(), and Fun4AllBase::Verbosity().

Referenced by process_event().

+ Here is the call graph for this function:

+ Here is the caller graph for this function:

BoundTrackParamPtrResult PHActsTrackProjection::propagateTrack ( const Acts::BoundTrackParameters &  params,
const SurfacePtr targetSurf 
)
private

Propagate the fitted track parameters to a surface with Acts.

Definition at line 319 of file PHActsTrackProjection.cc.

View newest version in sPHENIX GitHub at line 319 of file PHActsTrackProjection.cc

References Acts::Logging::FATAL, ActsTrackingGeometry::geoContext, Acts::getDefaultLogger(), m_tGeometry, ActsTrackingGeometry::magFieldContext, propagation_timing::stepper, Acts::Logging::VERBOSE, and Fun4AllBase::Verbosity().

Referenced by projectTracks().

+ Here is the call graph for this function:

+ Here is the caller graph for this function:

int PHActsTrackProjection::setCaloContainerNodes ( PHCompositeNode topNode,
const int  caloLayer 
)
private

Set the particular calo nodes depending on which layer.

Definition at line 372 of file PHActsTrackProjection.cc.

View newest version in sPHENIX GitHub at line 372 of file PHActsTrackProjection.cc

References Fun4AllReturnCodes::ABORTEVENT, Fun4AllReturnCodes::EVENT_OK, m_caloNames, m_clusterContainer, m_towerContainer, m_towerGeomContainer, m_useCemcPosRecalib, and PHWHERE.

Referenced by makeCaloSurfacePtrs(), and projectTracks().

+ Here is the caller graph for this function:

void PHActsTrackProjection::updateSvtxTrack ( const Acts::BoundTrackParameters &  params,
SvtxTrack svtxTrack,
const int  caloLayer 
)
private

Update the SvtxTrack object with the track-cluster match.

Definition at line 181 of file PHActsTrackProjection.cc.

View newest version in sPHENIX GitHub at line 181 of file PHActsTrackProjection.cc

References ActsTrackingGeometry::geoContext, RawTowerGeomContainer::get_etabin(), RawTowerGeomContainer::get_phibin(), getClusterProperties(), getSquareTowerEnergies(), m_caloTypes, m_tGeometry, m_towerGeomContainer, minE, radius, SvtxTrack::set_cal_cluster_e(), SvtxTrack::set_cal_cluster_id(), SvtxTrack::set_cal_deta(), SvtxTrack::set_cal_dphi(), SvtxTrack::set_cal_energy_3x3(), SvtxTrack::set_cal_energy_5x5(), and Fun4AllBase::Verbosity().

Referenced by projectTracks().

+ Here is the call graph for this function:

+ Here is the caller graph for this function:

Member Data Documentation

std::vector<std::string> PHActsTrackProjection::m_caloNames
private

Definition at line 101 of file PHActsTrackProjection.h.

View newest version in sPHENIX GitHub at line 101 of file PHActsTrackProjection.h

Referenced by makeCaloSurfacePtrs(), PHActsTrackProjection(), process_event(), projectTracks(), and setCaloContainerNodes().

std::map<std::string, SurfacePtr> PHActsTrackProjection::m_caloSurfaces
private

Definition at line 103 of file PHActsTrackProjection.h.

View newest version in sPHENIX GitHub at line 103 of file PHActsTrackProjection.h

Referenced by makeCaloSurfacePtrs(), and projectTracks().

std::vector<SvtxTrack::CAL_LAYER> PHActsTrackProjection::m_caloTypes
private

Definition at line 102 of file PHActsTrackProjection.h.

View newest version in sPHENIX GitHub at line 102 of file PHActsTrackProjection.h

Referenced by PHActsTrackProjection(), and updateSvtxTrack().

RawClusterContainer* PHActsTrackProjection::m_clusterContainer = nullptr
private

Definition at line 107 of file PHActsTrackProjection.h.

View newest version in sPHENIX GitHub at line 107 of file PHActsTrackProjection.h

Referenced by getClusterProperties(), and setCaloContainerNodes().

int PHActsTrackProjection::m_event = 0
private

Definition at line 111 of file PHActsTrackProjection.h.

View newest version in sPHENIX GitHub at line 111 of file PHActsTrackProjection.h

Referenced by process_event().

const int PHActsTrackProjection::m_nCaloLayers = 3
staticprivate

Objects to hold calorimeter information. There are only 3 calo layers

Definition at line 100 of file PHActsTrackProjection.h.

View newest version in sPHENIX GitHub at line 100 of file PHActsTrackProjection.h

Referenced by makeCaloSurfacePtrs(), and process_event().

ActsTrackingGeometry* PHActsTrackProjection::m_tGeometry = nullptr
private

Objects containing the Acts track fit results.

Definition at line 92 of file PHActsTrackProjection.h.

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

Referenced by getNodes(), makeCaloSurfacePtrs(), makeTrackParams(), propagateTrack(), and updateSvtxTrack().

RawTowerContainer* PHActsTrackProjection::m_towerContainer = nullptr
private

Definition at line 106 of file PHActsTrackProjection.h.

View newest version in sPHENIX GitHub at line 106 of file PHActsTrackProjection.h

Referenced by getSquareTowerEnergies(), and setCaloContainerNodes().

RawTowerGeomContainer* PHActsTrackProjection::m_towerGeomContainer = nullptr
private

Definition at line 105 of file PHActsTrackProjection.h.

View newest version in sPHENIX GitHub at line 105 of file PHActsTrackProjection.h

Referenced by getSquareTowerEnergies(), makeCaloSurfacePtrs(), setCaloContainerNodes(), and updateSvtxTrack().

SvtxTrackMap* PHActsTrackProjection::m_trackMap = nullptr
private

Definition at line 93 of file PHActsTrackProjection.h.

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

Referenced by getNodes(), and projectTracks().

std::map<const unsigned int, Trajectory>* PHActsTrackProjection::m_trajectories {nullptr}
private

Definition at line 95 of file PHActsTrackProjection.h.

View newest version in sPHENIX GitHub at line 95 of file PHActsTrackProjection.h

Referenced by getNodes(), and projectTracks().

bool PHActsTrackProjection::m_useCemcPosRecalib = false
private

Definition at line 109 of file PHActsTrackProjection.h.

View newest version in sPHENIX GitHub at line 109 of file PHActsTrackProjection.h

Referenced by setCaloContainerNodes().

SvtxVertexMap* PHActsTrackProjection::m_vertexMap = nullptr
private

Definition at line 94 of file PHActsTrackProjection.h.

View newest version in sPHENIX GitHub at line 94 of file PHActsTrackProjection.h

Referenced by getNodes(), and getVertex().


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