9 #include "Pandora/AlgorithmHeaders.h"
21 using namespace lar_content;
23 namespace lar_dl_content
26 StatusCode DlTrackShowerStreamSelectionAlgorithm::AllocateToStreams(
const Cluster *
const pCluster)
28 const OrderedCaloHitList &orderedCaloHitList{pCluster->GetOrderedCaloHitList()};
30 orderedCaloHitList.FillCaloHitList(caloHits);
31 const CaloHitList &isolatedHits{pCluster->GetIsolatedCaloHitList()};
32 caloHits.insert(caloHits.end(), isolatedHits.begin(), isolatedHits.end());
33 FloatVector trackLikelihoods;
36 for (
const CaloHit *pCaloHit : caloHits)
40 const float pShower{pLArCaloHit->GetShowerProbability()};
41 if ((pTrack + pShower) > std::numeric_limits<float>::epsilon())
42 trackLikelihoods.emplace_back(pTrack / (pTrack + pShower));
45 const unsigned long N{trackLikelihoods.size()};
50 m_clusterListMap.at(m_trackListName).emplace_back(pCluster);
52 m_clusterListMap.at(m_showerListName).emplace_back(pCluster);
55 catch (
const StatusCodeException &)
59 return STATUS_CODE_SUCCESS;
63 StatusCode DlTrackShowerStreamSelectionAlgorithm::ReadSettings(
const TiXmlHandle xmlHandle)
65 PANDORA_RETURN_RESULT_IF(STATUS_CODE_SUCCESS, !=, StreamSelectionAlgorithm::ReadSettings(xmlHandle));
66 PANDORA_RETURN_RESULT_IF(STATUS_CODE_SUCCESS, !=, XmlHelper::ReadValue(xmlHandle,
"TrackListName", m_trackListName));
67 PANDORA_RETURN_RESULT_IF(STATUS_CODE_SUCCESS, !=, XmlHelper::ReadValue(xmlHandle,
"ShowerListName", m_showerListName));
69 m_listNames.emplace_back(m_trackListName);
70 m_listNames.emplace_back(m_showerListName);
72 return STATUS_CODE_SUCCESS;
Header file for the lar calo hit class.
Header file for the lar monitoring helper helper class.
Header file for the lar monte carlo particle helper helper class.
auto end(FixedBins< T, C > const &) noexcept
auto begin(FixedBins< T, C > const &) noexcept
double mean(const std::vector< short > &wf, size_t start, size_t nsample)
required by fuzzyCluster table::sbnd_g4_services gaushitTruthMatch pandora
process_name largeant stream1 can override from command line with o or output physics producers generator N
Header file for the deep learning track shower cluster streaming algorithm.
float GetTrackProbability() const
Get the probability that the hit is track-like.