Public Member Functions | Protected Member Functions | Protected Attributes | List of all members
pma::PMAlgTrackingBase Class Reference

#include <PMAlgTracking.h>

Inheritance diagram for pma::PMAlgTrackingBase:
pma::PMAlgFitter pma::PMAlgTracker

Public Member Functions

const pma::TrkCandidateCollresult ()
 
std::vector< std::pair< TVector3, std::vector< std::pair< size_t, bool > > > > getVertices (bool onlyBranching=false) const
 
std::vector< std::pair< TVector3, size_t > > getKinks () const
 

Protected Member Functions

 PMAlgTrackingBase (const std::vector< art::Ptr< recob::Hit >> &allhitlist, const pma::ProjectionMatchingAlg::Config &pmalgConfig, const pma::PMAlgVertexing::Config &pmvtxConfig)
 
 ~PMAlgTrackingBase ()
 
void guideEndpoints (detinfo::DetectorPropertiesData const &detProp, pma::TrkCandidateColl &tracks)
 

Protected Attributes

pma::cryo_tpc_view_hitmap fHitMap
 
pma::ProjectionMatchingAlg fProjectionMatchingAlg
 
pma::PMAlgVertexing fPMAlgVertexing
 
pma::TrkCandidateColl fResult
 

Detailed Description

Definition at line 58 of file PMAlgTracking.h.

Constructor & Destructor Documentation

pma::PMAlgTrackingBase::PMAlgTrackingBase ( const std::vector< art::Ptr< recob::Hit >> &  allhitlist,
const pma::ProjectionMatchingAlg::Config pmalgConfig,
const pma::PMAlgVertexing::Config pmvtxConfig 
)
protected

Definition at line 57 of file PMAlgTracking.cxx.

60  : fProjectionMatchingAlg(pmalgConfig), fPMAlgVertexing(pmvtxConfig)
61 {
62  unsigned int cryo, tpc, view;
63  for (auto const& h : allhitlist) {
64  cryo = h->WireID().Cryostat;
65  tpc = h->WireID().TPC;
66  view = h->WireID().Plane;
67 
68  fHitMap[cryo][tpc][view].push_back(h);
69  }
70 }
pma::ProjectionMatchingAlg fProjectionMatchingAlg
Definition: PMAlgTracking.h:89
pma::PMAlgVertexing fPMAlgVertexing
Definition: PMAlgTracking.h:90
pma::cryo_tpc_view_hitmap fHitMap
Definition: PMAlgTracking.h:87
pma::PMAlgTrackingBase::~PMAlgTrackingBase ( )
protected

Definition at line 73 of file PMAlgTracking.cxx.

74 {
75  for (auto t : fResult.tracks())
76  t.DeleteTrack();
77 }
pma::TrkCandidateColl fResult
Definition: PMAlgTracking.h:92
std::vector< TrkCandidate > const & tracks() const

Member Function Documentation

std::vector<std::pair<TVector3, size_t> > pma::PMAlgTrackingBase::getKinks ( ) const
inline

Definition at line 73 of file PMAlgTracking.h.

74  {
76  }
std::vector< std::pair< TVector3, size_t > > getKinks(const pma::TrkCandidateColl &tracks) const
pma::TrkCandidateColl fResult
Definition: PMAlgTracking.h:92
pma::PMAlgVertexing fPMAlgVertexing
Definition: PMAlgTracking.h:90
std::vector<std::pair<TVector3, std::vector<std::pair<size_t, bool> > > > pma::PMAlgTrackingBase::getVertices ( bool  onlyBranching = false) const
inline

Definition at line 67 of file PMAlgTracking.h.

68  {
69  return fPMAlgVertexing.getVertices(fResult, onlyBranching);
70  }
std::vector< std::pair< TVector3, std::vector< std::pair< size_t, bool > > > > getVertices(const pma::TrkCandidateColl &tracks, bool onlyBranching=false) const
pma::TrkCandidateColl fResult
Definition: PMAlgTracking.h:92
pma::PMAlgVertexing fPMAlgVertexing
Definition: PMAlgTracking.h:90
void pma::PMAlgTrackingBase::guideEndpoints ( detinfo::DetectorPropertiesData const &  detProp,
pma::TrkCandidateColl tracks 
)
protected

Definition at line 81 of file PMAlgTracking.cxx.

83 {
84  for (auto const& t : tracks.tracks()) {
85  auto& trk = *(t.Track());
86 
87  unsigned int tpc = trk.FrontTPC(), cryo = trk.FrontCryo();
88  if ((tpc == trk.BackTPC()) && (cryo == trk.BackCryo())) {
89  fProjectionMatchingAlg.guideEndpoints(detProp, trk, fHitMap[cryo][tpc]);
90  }
91  else {
93  detProp, trk, pma::Track3D::kBegin, fHitMap[trk.FrontCryo()][trk.FrontTPC()]);
95  detProp, trk, pma::Track3D::kEnd, fHitMap[trk.BackCryo()][trk.BackTPC()]);
96  }
97  }
98 }
pma::ProjectionMatchingAlg fProjectionMatchingAlg
Definition: PMAlgTracking.h:89
void guideEndpoints(const detinfo::DetectorPropertiesData &clockData, pma::Track3D &trk, const std::map< unsigned int, std::vector< art::Ptr< recob::Hit >>> &hits) const
std::vector< TrkCandidate > const & tracks() const
pma::cryo_tpc_view_hitmap fHitMap
Definition: PMAlgTracking.h:87
const pma::TrkCandidateColl& pma::PMAlgTrackingBase::result ( )
inline

Definition at line 61 of file PMAlgTracking.h.

62  {
63  return fResult;
64  }
pma::TrkCandidateColl fResult
Definition: PMAlgTracking.h:92

Member Data Documentation

pma::cryo_tpc_view_hitmap pma::PMAlgTrackingBase::fHitMap
protected

Definition at line 87 of file PMAlgTracking.h.

pma::PMAlgVertexing pma::PMAlgTrackingBase::fPMAlgVertexing
protected

Definition at line 90 of file PMAlgTracking.h.

pma::ProjectionMatchingAlg pma::PMAlgTrackingBase::fProjectionMatchingAlg
protected

Definition at line 89 of file PMAlgTracking.h.

pma::TrkCandidateColl pma::PMAlgTrackingBase::fResult
protected

Definition at line 92 of file PMAlgTracking.h.


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