DlTrackShowerStreamSelectionAlgorithm class.
More...
#include "DlTrackShowerStreamSelectionAlgorithm.h"
|
virtual pandora::StatusCode | AllocateToStreams (const pandora::Cluster *const pCluster) |
| Allocate a cluster to the appropriate streams. More...
|
|
|
pandora::StatusCode | ReadSettings (const pandora::TiXmlHandle xmlHandle) |
|
lar_dl_content::DlTrackShowerStreamSelectionAlgorithm::DlTrackShowerStreamSelectionAlgorithm |
( |
| ) |
|
|
default |
virtual lar_dl_content::DlTrackShowerStreamSelectionAlgorithm::~DlTrackShowerStreamSelectionAlgorithm |
( |
| ) |
|
|
virtualdefault |
StatusCode lar_dl_content::DlTrackShowerStreamSelectionAlgorithm::AllocateToStreams |
( |
const pandora::Cluster *const |
pCluster | ) |
|
|
protectedvirtual |
Allocate a cluster to the appropriate streams.
- Parameters
-
pCluster | The cluster to allocate to a stream |
- Returns
- The StatusCode
Implements lar_content::StreamSelectionAlgorithm.
Definition at line 26 of file DlTrackShowerStreamSelectionAlgorithm.cc.
References util::begin(), util::end(), f, lar_content::LArCaloHit::GetTrackProbability(), and pmtana::mean().
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()};
55 catch (
const StatusCodeException &)
59 return STATUS_CODE_SUCCESS;
decltype(auto) constexpr end(T &&obj)
ADL-aware version of std::end.
double mean(const std::vector< short > &wf, size_t start, size_t nsample)
std::string m_showerListName
The name of the shower list.
ClusterListMap m_clusterListMap
The map from cluster list names to cluster lists.
decltype(auto) constexpr begin(T &&obj)
ADL-aware version of std::begin.
std::string m_trackListName
The name of the track list.
float GetTrackProbability() const
Get the probability that the hit is track-like.
StatusCode lar_dl_content::DlTrackShowerStreamSelectionAlgorithm::ReadSettings |
( |
const pandora::TiXmlHandle |
xmlHandle | ) |
|
|
private |
Definition at line 63 of file DlTrackShowerStreamSelectionAlgorithm.cc.
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));
72 return STATUS_CODE_SUCCESS;
pandora::StringVector m_listNames
The name of the output lists.
std::string m_showerListName
The name of the shower list.
std::string m_trackListName
The name of the track list.
ClusterListMap lar_content::StreamSelectionAlgorithm::m_clusterListMap |
|
protectedinherited |
std::string lar_content::StreamSelectionAlgorithm::m_inputListName |
|
protectedinherited |
pandora::StringVector lar_content::StreamSelectionAlgorithm::m_listNames |
|
protectedinherited |
std::string lar_content::StreamSelectionAlgorithm::m_listType |
|
protectedinherited |
std::string lar_dl_content::DlTrackShowerStreamSelectionAlgorithm::m_showerListName |
|
private |
std::string lar_dl_content::DlTrackShowerStreamSelectionAlgorithm::m_trackListName |
|
private |
The documentation for this class was generated from the following files: