9 #ifndef TRAJCLUSTERALGSHOWERS_H 10 #define TRAJCLUSTERALGSHOWERS_H 20 class DetectorPropertiesData;
33 bool Reconcile3D(std::string inFcnLabel, TCSlice& slc,
bool parentSearchDone,
bool prt);
34 bool Reconcile3D(std::string inFcnLabel, TCSlice& slc, ShowerStruct3D& ss3,
bool prt);
37 int GetCotID(TCSlice& slc,
int ShowerTjID);
43 void Match2DShowers(std::string inFcnLabel, TCSlice& slc,
bool prt);
44 bool UpdateShower(std::string inFcnLabel, TCSlice& slc, ShowerStruct& ss,
bool prt);
45 bool UpdateShower(std::string inFcnLabel, TCSlice& slc, ShowerStruct3D& ss3,
bool prt);
47 std::string inFcnLabel,
53 std::string inFcnLabel,
60 std::string inFcnLabel,
64 void MakeShowerObsolete(std::string inFcnLabel, TCSlice& slc, ShowerStruct3D& ss3,
bool prt);
65 void MakeShowerObsolete(std::string inFcnLabel, TCSlice& slc, ShowerStruct& ss,
bool prt);
67 const std::vector<int>& tjlist1,
68 const std::vector<int>& tjlist2);
76 bool AddPFP(std::string inFcnLabel,
88 bool AddTj(std::string inFcnLabel,
94 bool RemoveTj(std::string inFcnLabel,
100 bool AnalyzeRotPos(std::string inFcnLabel, TCSlice& slc, ShowerStruct& ss,
bool prt);
101 void ReverseShower(std::string inFcnLabel, TCSlice& slc, ShowerStruct& ss,
bool prt);
102 void ReverseShower(std::string inFcnLabel, TCSlice& slc,
int cotID,
bool prt);
104 std::string inFcnLabel,
109 std::string inFcnLabel,
117 unsigned short tjEnd,
119 bool IsShowerLike(TCSlice
const& slc, std::vector<int>
const& TjIDs);
120 float InShowerProb(TCSlice& slc,
const ShowerStruct3D& ss3,
const PFPStruct& pfp);
121 float InShowerProb(TCSlice& slc,
const ShowerStruct& ss,
const Trajectory& tj);
122 void ShowerParams(
double showerEnergy,
double& shMaxAlong,
double& shE95Along);
126 double InShowerProb(
double showerEnergy,
double along,
double trans);
135 unsigned short& tjEnd,
140 void DefineEnvelope(std::string inFcnLabel, TCSlice& slc, ShowerStruct& ss,
bool prt);
142 bool AddLooseHits(std::string inFcnLabel, TCSlice& slc,
int cotID,
bool prt);
143 void FindStartChg(std::string inFcnLabel, TCSlice& slc,
int cotID,
bool prt);
144 std::vector<float>
StartChgVec(TCSlice& slc,
int cotID);
145 void DumpShowerPts(std::string inFcnLabel, TCSlice& slc,
int cotID);
147 void FindCots(std::string inFcnLabel,
153 void FindNearbyTjs(std::string inFcnLabel, TCSlice& slc, ShowerStruct& ss,
bool prt);
157 std::vector<int> list);
164 void MergeOverlap(std::string inFcnLabel, TCSlice& slc,
const CTP_t& inCTP,
bool prt);
168 int MergeShowers(std::string inFcnLabel, TCSlice& slc, std::vector<int> showerIDs,
bool prt);
169 bool MergeShowersAndStore(std::string inFcnLabel, TCSlice& slc,
int icotID,
int jcotID,
bool prt);
171 float ShowerEnergy(TCSlice& slc,
const std::vector<int> tjIDs);
174 bool StoreShower(std::string inFcnLabel, TCSlice& slc, ShowerStruct3D& ss3);
175 bool StoreShower(std::string inFcnLabel, TCSlice& slc, ShowerStruct& ss);
177 ShowerStruct
CreateSS(TCSlice& slc,
const std::vector<int>& tjl);
178 bool ChkAssns(std::string inFcnLabel, TCSlice& slc);
180 std::string someText,
185 bool printKilledShowers);
188 const ShowerStruct& ss,
194 #endif // ifndef TRAJCLUSTERALGSHOWERS_H bool AddTj(std::string inFcnLabel, TCSlice &slc, int tjID, ShowerStruct &ss, bool doUpdate, bool prt)
bool TransferTjHits(TCSlice &slc, bool prt)
void MergeNearby2DShowers(std::string inFcnLabel, TCSlice &slc, const CTP_t &inCTP, bool prt)
void ConfigureMVA(TCConfig &tcc, std::string fMVAShowerParentWeights)
bool AddLooseHits(std::string inFcnLabel, TCSlice &slc, int cotID, bool prt)
bool FindParent(detinfo::DetectorPropertiesData const &detProp, std::string inFcnLabel, TCSlice &slc, ShowerStruct3D &ss3, bool prt)
void ReverseShower(std::string inFcnLabel, TCSlice &slc, ShowerStruct &ss, bool prt)
void MergeShowerChain(std::string inFcnLabel, TCSlice &slc, const CTP_t &inCTP, bool prt)
double InShowerProbLong(double showerEnergy, double along)
bool WrongSplitTj(std::string inFcnLabel, TCSlice &slc, Trajectory &tj, unsigned short tjEnd, bool prt)
bool ChkAssns(std::string inFcnLabel, TCSlice &slc)
ShowerStruct3D CreateSS3(TCSlice &slc)
void PrintShowers(detinfo::DetectorPropertiesData const &detProp, std::string fcnLabel, TCSlice const &slc)
int GetCotID(TCSlice &slc, int ShowerTjID)
bool IsShowerLike(TCSlice const &slc, std::vector< int > const &TjIDs)
bool DontCluster(TCSlice const &slc, const std::vector< int > &tjlist1, const std::vector< int > &tjlist2)
void KillVerticesInShower(std::string inFcnLabel, TCSlice &slc, ShowerStruct &ss, bool prt)
bool FindShowers3D(detinfo::DetectorPropertiesData const &detProp, TCSlice &slc)
double ShowerEnergy(const ShowerStruct3D &ss3)
void TagShowerLike(TCSlice &slc, const CTP_t &inCTP)
double InShowerProbTrans(double showerEnergy, double along, double trans)
bool FindShowerStart(detinfo::DetectorPropertiesData const &detProp, TCSlice &slc, ShowerStruct3D &ss3, bool prt)
ShowerStruct CreateSS(TCSlice &slc, const std::vector< int > &tjl)
void MergeTjList(std::vector< std::vector< int >> &tjList)
double ShowerParamTransRMS(double showerEnergy, double along)
auto vector(Vector const &v)
Returns a manipulator which will print the specified array.
void DefineEnvelope(std::string inFcnLabel, TCSlice &slc, ShowerStruct &ss, bool prt)
void FindCots(std::string inFcnLabel, TCSlice &slc, const CTP_t &inCTP, std::vector< std::vector< int >> &tjLists, bool prt)
void MergeSubShowersTj(std::string inFcnLabel, TCSlice &slc, const CTP_t &inCTP, bool prt)
bool MergeShowerTjsAndStore(TCSlice &slc, unsigned short istj, unsigned short jstj, bool prt)
void AddCloseTjsToList(std::string inFcnLabel, TCSlice &slc, unsigned short itj, std::vector< int > list)
void FindNearbyTjs(std::string inFcnLabel, TCSlice &slc, ShowerStruct &ss, bool prt)
void MergeOverlap(std::string inFcnLabel, TCSlice &slc, const CTP_t &inCTP, bool prt)
double InShowerProb(double showerEnergy, double along, double trans)
General LArSoft Utilities.
bool AddPFP(std::string inFcnLabel, TCSlice &slc, int pID, ShowerStruct3D &ss3, bool doUpdate, bool prt)
float ParentFOM(std::string inFcnLabel, TCSlice &slc, PFPStruct &pfp, ShowerStruct3D &ss3, bool prt)
bool AddTjsInsideEnvelope(std::string inFcnLabel, TCSlice &slc, ShowerStruct &ss, bool prt)
bool MergeShowersAndStore(std::string inFcnLabel, TCSlice &slc, int icotID, int jcotID, bool prt)
std::vector< float > StartChgVec(TCSlice &slc, int cotID)
bool RemoveTj(std::string inFcnLabel, TCSlice &slc, int TjID, ShowerStruct &ss, bool doUpdate, bool prt)
int MergeShowers(std::string inFcnLabel, TCSlice &slc, std::vector< int > ssIDs, bool prt)
void ShowerParams(double showerEnergy, double &shMaxAlong, double &along95)
void PrintShower(std::string someText, TCSlice const &slc, const ShowerStruct &ss, bool printHeader, bool printExtras)
void Match2DShowers(std::string inFcnLabel, TCSlice &slc, bool prt)
void DefineDontCluster(TCSlice &slc, bool prt)
void MergeTjList2(std::string inFcnLabel, TCSlice &slc, std::vector< std::vector< int >> &tjList, bool prt)
void MergeSubShowers(std::string inFcnLabel, TCSlice &slc, const CTP_t &inCTP, bool prt)
void FindStartChg(std::string inFcnLabel, TCSlice &slc, int cotID, bool prt)
void Finish3DShowers(TCSlice &slc)
bool AnalyzeRotPos(std::string inFcnLabel, TCSlice &slc, ShowerStruct &ss, bool prt)
float Match3DFOM(detinfo::DetectorPropertiesData const &detProp, std::string inFcnLabel, TCSlice &slc, ShowerStruct3D &ss3, bool prt)
float ChgToMeV(float chg)
bool UpdateShower(std::string inFcnLabel, TCSlice &slc, ShowerStruct &ss, bool prt)
void Print2DShowers(std::string someText, TCSlice const &slc, CTP_t inCTP, bool printKilledShowers)
bool RemovePFP(std::string inFcnLabel, TCSlice &slc, int pID, ShowerStruct3D &ss3, bool doUpdate, bool prt)
bool CompleteIncompleteShower(std::string inFcnLabel, TCSlice &slc, ShowerStruct3D &ss3, bool prt)
void DumpShowerPts(std::string inFcnLabel, TCSlice &slc, int cotID)
bool SetParent(detinfo::DetectorPropertiesData const &detProp, std::string inFcnLabel, TCSlice &slc, PFPStruct &pfp, ShowerStruct3D &ss3, bool prt)
void MakeShowerObsolete(std::string inFcnLabel, TCSlice &slc, ShowerStruct3D &ss3, bool prt)
bool StoreShower(std::string inFcnLabel, TCSlice &slc, ShowerStruct3D &ss3)
bool Reconcile3D(std::string inFcnLabel, TCSlice &slc, bool parentSearchDone, bool prt)