152 auto const clockData =
153 art::ServiceHandle<detinfo::DetectorClocksService const>()->DataFor(
evt);
155 art::ServiceHandle<detinfo::DetectorPropertiesService const>()->DataFor(
evt, clockData);
158 for (
auto trackIter =
fTracks.begin(); trackIter !=
fTracks.end(); ++trackIter) {
161 std::vector<double> eVals, eVecs;
165 if (eVals[0] < 0.0001)
168 evalRatio = std::sqrt(eVals[1] * eVals[1] + eVals[2] * eVals[2]) / eVals[0];
170 double coreHaloRatio, concentration, conicalness;
171 this->
_Var_Shape(sortedObj, coreHaloRatio, concentration, conicalness);
186 if (dEdxPenultimate < 0.1)
199 for (
auto showerIter =
fShowers.begin(); showerIter !=
fShowers.end(); ++showerIter) {
202 std::vector<double> eVals, eVecs;
208 if (eVals[0] < 0.0001)
211 evalRatio = std::sqrt(eVals[1] * eVals[1] + eVals[2] * eVals[2]) / eVals[0];
213 this->
SortShower(*showerIter, isStoppingReco, sortedObj);
215 double coreHaloRatio, concentration, conicalness;
216 this->
_Var_Shape(sortedObj, coreHaloRatio, concentration, conicalness);
225 (*showerIter)->ID() + 1000;
233 if (dEdxPenultimate < 0.1)
std::vector< art::Ptr< recob::Shower > > fShowers
anab::MVAPIDResult fResHolder
void RunPCA(std::vector< art::Ptr< recob::Hit >> &hits, std::vector< double > &eVals, std::vector< double > &eVecs)
std::vector< std::string > fMVAMethods
std::map< art::Ptr< recob::Track >, std::vector< art::Ptr< recob::Hit > > > fTracksToHits
void PrepareEvent(const art::Event &event, const detinfo::DetectorClocksData &clockData)
void SortShower(art::Ptr< recob::Shower > shower, int &isStoppingReco, mvapid::MVAAlg::SortedObj &sortedShower)
std::map< double, const art::Ptr< recob::Hit > > hitMap
std::map< art::Ptr< recob::Shower >, std::vector< art::Ptr< recob::Hit > > > fShowersToHits
double CalcSegmentdEdxFrac(const detinfo::DetectorClocksData &clock_data, const detinfo::DetectorPropertiesData &det_prop, const SortedObj &track, double start, double end)
bool CreateAssn(art::Event &evt, std::vector< T > const &a, art::Ptr< U > const &b, art::Assns< U, T > &assn, std::string a_instance, size_t index=UINT_MAX)
Creates a single one-to-one association.
void _Var_Shape(const SortedObj &track, double &coreHaloRatio, double &concentration, double &conicalness)
std::vector< art::Ptr< recob::Track > > fTracks
std::map< std::string, double > mvaOutput
void FitAndSortTrack(art::Ptr< recob::Track > track, int &isStoppingReco, SortedObj &sortedObj)