All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Groups Pages
TCVertex.h
Go to the documentation of this file.
1 ////////////////////////////////////////////////////////////////////////
2 //
3 //
4 // TCAlg vertex code
5 //
6 // Bruce Baller
7 //
8 ///////////////////////////////////////////////////////////////////////
9 #ifndef TRAJCLUSTERALGVERTEX_H
10 #define TRAJCLUSTERALGVERTEX_H
11 
12 // C/C++ standard libraries
13 #include <string>
14 #include <vector>
15 
16 // LArSoft libraries
18 namespace detinfo {
19  class DetectorPropertiesData;
20 }
21 
22 namespace tca {
23 
24  extern TCEvent evt;
25  extern TCConfig tcc;
26  // vector of hits, tjs, etc in each slice
27  extern std::vector<TCSlice> slices;
28 
29  void MakeJunkVertices(TCSlice& slc, const CTP_t& inCTP);
31  TCSlice& slc,
32  const CTP_t& inCTP,
33  unsigned short pass);
34  void MakeJunkTjVertices(TCSlice& slc, const CTP_t& inCTP);
35  bool MergeWithVertex(TCSlice& slc, VtxStore& vx2, unsigned short existingVxID);
36  void FindHammerVertices(TCSlice& slc, const CTP_t& inCTP);
37  void FindHammerVertices2(TCSlice& slc, const CTP_t& inCTP);
38  void SplitTrajCrossingVertices(TCSlice& slc, CTP_t inCTP);
39  void Reconcile2Vs(TCSlice& slc);
40  bool Reconcile2VTs(TCSlice& slc, std::vector<int>& vx2cls, bool prt);
41  void Find3DVertices(detinfo::DetectorPropertiesData const& detProp, TCSlice& slc);
44  TCSlice& slc);
45  bool RefineVtxPosition(TCSlice& slc,
46  const Trajectory& tj,
47  unsigned short& nearPt,
48  short nPtsToChk,
49  bool prt);
50  unsigned short TPNearVertex(const TCSlice& slc, const TrajPoint& tp);
51  bool AttachToAnyVertex(TCSlice& slc, PFPStruct& pfp, float maxSep, bool prt);
52  bool AttachAnyVertexToTraj(TCSlice& slc, int tjID, bool prt);
53  bool AttachAnyTrajToVertex(TCSlice& slc, unsigned short iv, bool prt);
54  bool AttachTrajToVertex(TCSlice& slc, Trajectory& tj, VtxStore& vx, bool prt);
55  float TrajPointVertexPull(const TCSlice& slc, const TrajPoint& tp, const VtxStore& vx);
56  float VertexVertexPull(const TCSlice& slc, const Vtx3Store& vx1, const Vtx3Store& vx2);
57  float VertexVertexPull(const TCSlice& slc, const VtxStore& vx1, const VtxStore& vx2);
58  bool FitVertex(TCSlice& slc, VtxStore& vx, bool prt);
59  bool FitVertex(TCSlice& slc, VtxStore& vx, std::vector<TrajPoint>& vxTp, bool prt);
60  bool StoreVertex(TCSlice& slc, VtxStore& vx);
61  bool ChkVtxAssociations(TCSlice& slc, const CTP_t& inCTP);
62  void ScoreVertices(TCSlice& slc);
63  void KillPoorVertices(TCSlice& slc);
64  void SetVx2Score(TCSlice& slc);
65  void SetVx2Score(TCSlice& slc, VtxStore& vx2);
66  void SetVx3Score(TCSlice& slc, Vtx3Store& vx3);
67  void SetHighScoreBits(TCSlice& slc, Vtx3Store& vx3);
68  bool MakeVertexObsolete(std::string fcnLabel, TCSlice& slc, VtxStore& vx2, bool forceKill);
69  bool MakeVertexObsolete(TCSlice& slc, Vtx3Store& vx3);
70  std::vector<int> GetVtxTjIDs(const TCSlice& slc, const VtxStore& vx2);
71  std::vector<int> GetVtxTjIDs(const TCSlice& slc, const Vtx3Store& vx3, float& score);
73  const TCSlice& slc,
74  const Vtx3Store& vx3,
75  unsigned short plane,
76  Point2_t& pos);
77  unsigned short IsCloseToVertex(const TCSlice& slc, const VtxStore& vx);
78  unsigned short IsCloseToVertex(const TCSlice& slc, const Vtx3Store& vx3);
79 } // namespace
80 
81 #endif // ifndef TRAJCLUSTERALGVERTEX_H
bool MergeWithVertex(TCSlice &slc, VtxStore &vx, unsigned short oVxID)
Definition: TCVertex.cxx:435
bool MakeVertexObsolete(std::string fcnLabel, TCSlice &slc, VtxStore &vx2, bool forceKill)
Definition: TCVertex.cxx:2726
float TrajPointVertexPull(const TCSlice &slc, const TrajPoint &tp, const VtxStore &vx)
Definition: TCVertex.cxx:1851
bool AttachAnyVertexToTraj(TCSlice &slc, int tjID, bool prt)
Definition: TCVertex.cxx:1641
void CompleteIncomplete3DVerticesInGaps(detinfo::DetectorPropertiesData const &detProp, TCSlice &slc)
Definition: TCVertex.cxx:2396
bool FitVertex(TCSlice &slc, VtxStore &vx, bool prt)
Definition: TCVertex.cxx:1954
void Find3DVertices(detinfo::DetectorPropertiesData const &detProp, TCSlice &slc)
Definition: TCVertex.cxx:1268
TCConfig tcc
Definition: DataStructs.cxx:9
void SplitTrajCrossingVertices(TCSlice &slc, CTP_t inCTP)
Definition: TCVertex.cxx:923
void Reconcile2Vs(TCSlice &slc)
Definition: TCVertex.cxx:1067
BEGIN_PROLOG or score(default)}sbnd_crttrackmatchingalg_crID
bool RefineVtxPosition(TCSlice &slc, const Trajectory &tj, unsigned short &nearPt, short nPtsToChk, bool prt)
Definition: TCVertex.cxx:2690
void PosInPlane(detinfo::DetectorPropertiesData const &detProp, const TCSlice &slc, const Vtx3Store &vx3, unsigned short plane, Point2_t &pos)
Definition: TCVertex.cxx:2879
bool AttachAnyTrajToVertex(TCSlice &slc, unsigned short ivx, bool prt)
Definition: TCVertex.cxx:1683
unsigned short TPNearVertex(const TCSlice &slc, const TrajPoint &tp)
Definition: TCVertex.cxx:1568
void SetVx3Score(TCSlice &slc, Vtx3Store &vx3)
Definition: TCVertex.cxx:2242
void CompleteIncomplete3DVertices(detinfo::DetectorPropertiesData const &detProp, TCSlice &slc)
Definition: TCVertex.cxx:2490
bool StoreVertex(TCSlice &slc, VtxStore &vx)
Definition: TCVertex.cxx:1918
std::array< float, 2 > Point2_t
Definition: DataStructs.h:43
bool ChkVtxAssociations(TCSlice &slc, const CTP_t &inCTP)
Definition: TCVertex.cxx:2071
bool Reconcile2VTs(TCSlice &slc, std::vector< int > &vx2cls, bool prt)
Definition: TCVertex.cxx:1163
void ScoreVertices(TCSlice &slc)
Definition: TCVertex.cxx:2146
std::vector< TCSlice > slices
Definition: DataStructs.cxx:13
unsigned short IsCloseToVertex(const TCSlice &slc, const VtxStore &inVx2)
Definition: TCVertex.cxx:2894
float VertexVertexPull(const TCSlice &slc, const Vtx3Store &vx1, const Vtx3Store &vx2)
Definition: TCVertex.cxx:1887
unsigned int CTP_t
Definition: DataStructs.h:47
void SetHighScoreBits(TCSlice &slc, Vtx3Store &vx3)
Definition: TCVertex.cxx:2193
bool AttachTrajToVertex(TCSlice &slc, Trajectory &tj, VtxStore &vx, bool prt)
Definition: TCVertex.cxx:1728
void MakeJunkTjVertices(TCSlice &slc, const CTP_t &inCTP)
std::vector< int > GetVtxTjIDs(const TCSlice &slc, const VtxStore &vx2)
Definition: TCVertex.cxx:2837
void KillPoorVertices(TCSlice &slc)
Definition: TCVertex.cxx:2174
void SetVx2Score(TCSlice &slc)
Definition: TCVertex.cxx:2264
void FindHammerVertices(TCSlice &slc, const CTP_t &inCTP)
Definition: TCVertex.cxx:797
void MakeJunkVertices(TCSlice &slc, const CTP_t &inCTP)
Definition: TCVertex.cxx:31
TCEvent evt
Definition: DataStructs.cxx:8
void Find2DVertices(detinfo::DetectorPropertiesData const &detProp, TCSlice &slc, const CTP_t &inCTP, unsigned short pass)
Definition: TCVertex.cxx:132
void FindHammerVertices2(TCSlice &slc, const CTP_t &inCTP)
Definition: TCVertex.cxx:604
bool AttachToAnyVertex(TCSlice &slc, PFPStruct &pfp, float maxSep, bool prt)
Definition: TCVertex.cxx:1583
auto const detProp