33 m_minShowerHits3D(50),
34 m_showerSlidingFitWindow(1000),
35 m_maxCoincidenceTransverseSeparation(5.f),
36 m_minSpinePurity(0.7f),
37 m_trainingMode(false),
38 m_trainingFileName(
"ConnectionPathwayTrain.txt"),
39 m_unambiguousThreshold(0.5f),
40 m_maxConnectionDistance(1.f),
41 m_minNConnectedHits(2),
42 m_minElectronCompleteness(0.33f),
43 m_minElectronPurity(0.5f),
44 m_maxSeparationFromHit(3.f),
45 m_maxProjectionSeparation(5.f),
46 m_maxXSeparation(0.5f)
57 if (showerPfoVector.empty())
58 return STATUS_CODE_SUCCESS;
72 return STATUS_CODE_SUCCESS;
79 const PfoList *pPfoList(
nullptr);
84 if (!pPfoList || pPfoList->empty())
86 std::cout <<
"ElectronInitialRegionRefinementAlgorithm: unable to find shower pfo list " <<
m_showerPfoListName << std::endl;
90 showerPfoVector.insert(showerPfoVector.begin(), pPfoList->begin(), pPfoList->end());
115 if (protoShowerMatchVector.empty())
152 if (this->
IsElectron(pShowerPfo, electronHitMap))
172 if (statusCode != STATUS_CODE_SUCCESS)
175 if (!pNuVertexList || (pNuVertexList->size() != 1))
179 <<
" if it does exist, it may have more than one nu vertex" << std::endl;
181 return STATUS_CODE_NOT_INITIALIZED;
184 nuVertex3D = pNuVertexList->front()->GetPosition();
186 return STATUS_CODE_SUCCESS;
202 showerVertexPosition = this->
GetShowerVertex(pShowerPfo, hitType, nuVertex3D);
220 if (
m_pShowerSpineFinderTool->
Run(nuVertex3D, pViewHitList, hitType, peakDirection, unavailableHitList, showerSpineHitList) != STATUS_CODE_SUCCESS)
223 this->
RefineShowerVertex(pShowerPfo, hitType, nuVertex3D, peakDirection, showerVertexPosition);
226 if (!this->
IsSpineCoincident(pShowerPfo, nuVertex3D, hitType, showerVertexPosition, showerSpineHitList))
233 if (
m_pShowerStartFinderTool->
Run(pShowerPfo, peakDirection, hitType, showerSpineHitList, showerStartPosition, showerStartDirection) != STATUS_CODE_SUCCESS)
246 const float showerVertexL(std::max(
247 peakDirection.GetDotProduct(showerStartPosition - nuVertex2D), peakDirection.GetDotProduct(showerVertexPosition - nuVertex2D)));
249 for (
const CaloHit *
const pCaloHit : showerSpineHitList)
251 if (std::find(viewShowerHitList.begin(), viewShowerHitList.end(), pCaloHit) != viewShowerHitList.end())
255 const float showerL(peakDirection.GetDotProduct(hitPosition - nuVertex2D));
257 if ((showerL > 0.f) && (showerL < showerVertexL))
261 protoShowerVector.push_back(protoShower);
262 unavailableHitList.insert(unavailableHitList.begin(), showerSpineHitList.begin(), showerSpineHitList.end());
274 if (!pCaloHitList || pCaloHitList->empty())
277 std::cout <<
"ShowerStartRefinementBaseTool: unable to find calo hit list " << typeHitListName << std::endl;
279 return STATUS_CODE_NOT_INITIALIZED;
282 return STATUS_CODE_SUCCESS;
293 if (viewCusterList.empty())
302 if ((nuVertex2D.
GetZ() > minLayerPosition.
GetZ()) && (nuVertex2D.
GetZ() < maxLayerPosition.
GetZ()))
305 const float minSeparation((nuVertex2D - minLayerPosition).GetMagnitudeSquared());
306 const float maxSeparation((nuVertex2D - maxLayerPosition).GetMagnitudeSquared());
307 CartesianVector showerVertexPosition(minSeparation < maxSeparation ? minLayerPosition : maxLayerPosition);
309 return (minSeparation < maxSeparation ? minLayerPosition : maxLayerPosition);
324 float minL(std::numeric_limits<float>::max());
326 for (
const CaloHit *
const pCaloHit : viewShowerHitList)
328 const CartesianVector displacement(pCaloHit->GetPositionVector() - nuVertex2D);
329 const float longitudinalSeparation(peakDirection.
GetDotProduct(displacement));
331 if ((longitudinalSeparation < (-1.f)) || (longitudinalSeparation > minL))
334 const float transverseSeparation((peakDirection.
GetCrossProduct(displacement)).GetMagnitude());
338 showerVertexPosition = pCaloHit->GetPositionVector();
339 minL = longitudinalSeparation;
352 const float longitudinalSeparation(peakDirection.
GetDotProduct(displacement));
354 if (longitudinalSeparation < (-1.f))
357 const float transverseSeparation((peakDirection.
GetCrossProduct(displacement)).GetMagnitude());
376 const float showerDistanceFromNuSquared((showerVertex - nuVertex2D).GetMagnitudeSquared());
378 for (
const CaloHit *
const pSpineHit : showerSpineHitList)
381 const float separationSquared((hitPosition - nuVertex2D).GetMagnitudeSquared());
383 if (separationSquared > showerDistanceFromNuSquared)
384 postShowerVertexSpineHits.push_back(pSpineHit);
387 if (postShowerVertexSpineHits.size() == 0)
392 const float spinePurity(
static_cast<float>(sharedHitList.size()) /
static_cast<float>(postShowerVertexSpineHits.size()));
420 if (
m_pEventPathwayFinderTool->
Run(nuVertex3D, pViewHitList, hitType, eventPeakDirection, unavailableHitList, pathwayHitList) != STATUS_CODE_SUCCESS)
426 viewPathways.push_back(connectionPathway);
427 unavailableHitList.insert(unavailableHitList.begin(), pathwayHitList.begin(), pathwayHitList.end());
447 const float thisT((peakDirection.
GetCrossProduct(displacement)).GetMagnitudeSquared());
451 const CartesianVector &eventPeakDirection(connectionPathway.GetStartDirection());
456 const float otherT((eventPeakDirection.
GetCrossProduct(displacement)).GetMagnitudeSquared());
470 found ? protoShower.
AddAmbiguousHit(pHitToAdd) : refinedHitList.push_back(pHitToAdd);
484 continuousHitList.clear();
486 CaloHitVector refinedHitVector(refinedHitList.begin(), refinedHitList.end());
489 unsigned int startIndex(refinedHitVector.size());
491 for (
unsigned int i = 0; i < refinedHitVector.size(); ++i)
494 connectedHitList.push_back(refinedHitVector[i]);
502 for (
unsigned int j = (i + 1); j < refinedHitVector.size(); ++j)
504 const CaloHit *
const pCaloHit(refinedHitVector[j]);
506 if (std::find(connectedHitList.begin(), connectedHitList.end(), pCaloHit) != connectedHitList.end())
512 connectedHitList.push_back(pCaloHit);
518 if ((connectedHitList.size() >=
m_minNConnectedHits) || (connectedHitList.size() == refinedHitVector.size()))
525 for (
unsigned int i = startIndex; i < refinedHitVector.size(); ++i)
526 continuousHitList.push_back(refinedHitVector[i]);
535 metadata.m_propertiesToAdd[
"FoundConnectionPathway"] =
true;
537 if (featureMap.find(
"LArInitialRegionFeatureTool_initialGapSize") != featureMap.end())
538 metadata.m_propertiesToAdd[
"MaxInitialGapSize"] = featureMap.at(
"LArInitialRegionFeatureTool_initialGapSize").Get();
540 if (featureMap.find(
"LArInitialRegionFeatureTool_largestGapSize") != featureMap.end())
541 metadata.m_propertiesToAdd[
"MinLargestProjectedGapSize"] = featureMap.at(
"LArInitialRegionFeatureTool_largestGapSize").Get();
543 if (featureMap.find(
"LArConnectionRegionFeatureTool_pathwayLength") != featureMap.end())
544 metadata.m_propertiesToAdd[
"PathwayLengthMin"] = featureMap.at(
"LArConnectionRegionFeatureTool_pathwayLength").Get();
546 if (featureMap.find(
"LArConnectionRegionFeatureTool_pathwayScatteringAngle2D") != featureMap.end())
547 metadata.m_propertiesToAdd[
"MaxShowerStartPathwayScatteringAngle2D"] =
548 featureMap.at(
"LArConnectionRegionFeatureTool_pathwayScatteringAngle2D").Get();
550 if (featureMap.find(
"LArShowerRegionFeatureTool_nShowerHits") != featureMap.end())
551 metadata.m_propertiesToAdd[
"MaxNPostShowerStartHits"] = featureMap.at(
"LArShowerRegionFeatureTool_nShowerHits").Get();
553 if (featureMap.find(
"LArShowerRegionFeatureTool_foundHitRatio") != featureMap.end())
554 metadata.m_propertiesToAdd[
"MaxFoundHitRatio"] = featureMap.at(
"LArShowerRegionFeatureTool_foundHitRatio").Get();
556 if (featureMap.find(
"LArShowerRegionFeatureTool_scatterAngle") != featureMap.end())
557 metadata.m_propertiesToAdd[
"MaxPostShowerStartScatterAngle"] = featureMap.at(
"LArShowerRegionFeatureTool_scatterAngle").Get();
559 if (featureMap.find(
"LArShowerRegionFeatureTool_openingAngle") != featureMap.end())
560 metadata.m_propertiesToAdd[
"MaxPostShowerStartOpeningAngle"] = featureMap.at(
"LArShowerRegionFeatureTool_openingAngle").Get();
562 if (featureMap.find(
"LArShowerRegionFeatureTool_nuVertexEnergyAsymmetry") != featureMap.end())
563 metadata.m_propertiesToAdd[
"MaxPostShowerStartNuVertexEnergyAsymmetry"] =
564 featureMap.at(
"LArShowerRegionFeatureTool_nuVertexEnergyAsymmetry").Get();
566 if (featureMap.find(
"LArShowerRegionFeatureTool_nuVertexEnergyWeightedMeanRadialDistance") != featureMap.end())
567 metadata.m_propertiesToAdd[
"MaxPostShowerStartNuVertexEnergyWeightedMeanRadialDistance"] =
568 featureMap.at(
"LArShowerRegionFeatureTool_nuVertexEnergyWeightedMeanRadialDistance").Get();
570 if (featureMap.find(
"LArShowerRegionFeatureTool_showerStartEnergyAsymmetry") != featureMap.end())
571 metadata.m_propertiesToAdd[
"MaxPostShowerStartShowerStartEnergyAsymmetry"] =
572 featureMap.at(
"LArShowerRegionFeatureTool_showerStartEnergyAsymmetry").Get();
574 if (featureMap.find(
"LArShowerRegionFeatureTool_showerStartMoliereRadius") != featureMap.end())
575 metadata.m_propertiesToAdd[
"MinPostShowerStartShowerStartMoliereRadius"] =
576 featureMap.at(
"LArShowerRegionFeatureTool_showerStartMoliereRadius").Get();
578 if (featureMap.find(
"LArAmbiguousRegionFeatureTool_nAmbiguousViews") != featureMap.end())
579 metadata.m_propertiesToAdd[
"NViewsWithAmbiguousHits"] = featureMap.at(
"LArAmbiguousRegionFeatureTool_nAmbiguousViews").Get();
581 if (featureMap.find(
"LArAmbiguousRegionFeatureTool_maxUnaccountedEnergy") != featureMap.end())
582 metadata.m_propertiesToAdd[
"AmbiguousHitMaxUnaccountedEnergy"] = featureMap.at(
"LArAmbiguousRegionFeatureTool_maxUnaccountedEnergy").Get();
591 electronHitMap.clear();
600 for (
const CaloHit *
const pCaloHit : *pViewHitList)
605 for (
const auto &mapEntry : weightMap)
606 contributingMCParticleVector.push_back(mapEntry.first);
610 float highestWeight(0.f);
611 const MCParticle *highestElectronContributor(
nullptr);
613 for (
const MCParticle *
const pMCParticle : contributingMCParticleVector)
615 const bool isLeadingElectron((std::abs(pMCParticle->GetParticleId()) == 11) &&
618 if (isLeadingElectron)
620 const float weight(weightMap.at(pMCParticle));
622 if (weight > highestWeight)
624 highestWeight = weight;
625 highestElectronContributor = pMCParticle;
630 if (highestElectronContributor)
631 electronHitMap[highestElectronContributor].push_back(pCaloHit);
642 for (
auto &entry : electronHitMap)
643 mcElectronVector.push_back(entry.first);
650 for (
const MCParticle *
const pMCElectron : mcElectronVector)
652 const CaloHitList &mcElectronHitList(electronHitMap.at(pMCElectron));
655 const float completeness(
static_cast<float>(sharedHitList.size()) /
static_cast<float>(mcElectronHitList.size()));
656 const float purity(
static_cast<float>(sharedHitList.size()) /
static_cast<float>(pfoHitList.size()));
685 return STATUS_CODE_INVALID_PARAMETER;
692 return STATUS_CODE_INVALID_PARAMETER;
699 return STATUS_CODE_INVALID_PARAMETER;
706 return STATUS_CODE_INVALID_PARAMETER;
713 return STATUS_CODE_INVALID_PARAMETER;
720 return STATUS_CODE_INVALID_PARAMETER;
767 for (
auto const &[pAlgorithmToolName, pAlgorithmTool] : algorithmToolMap)
770 return STATUS_CODE_SUCCESS;
Header file for the electron initial region refinement algorithm class.
Header file for the cluster helper class.
Header file for the connection pathway helper class.
Header file for the geometry helper class.
Header file for the lar monte carlo particle helper helper class.
Header file for the pfo helper class.
Header file for the ProtoShower class.
Header file for the lar two dimensional sliding shower fit result class.
#define PANDORA_THROW_RESULT_IF_AND_IF(StatusCode1, StatusCode2, Operator, Command)
#define PANDORA_THROW_RESULT_IF(StatusCode1, Operator, Command)
#define PANDORA_RETURN_RESULT_IF_AND_IF(StatusCode1, StatusCode2, Operator, Command)
#define PANDORA_RETURN_RESULT_IF(StatusCode1, Operator, Command)
static pandora::StatusCode GetList(const pandora::Algorithm &algorithm, const std::string &listName, const T *&pT)
Get a named list.
static const pandora::PandoraSettings * GetSettings(const pandora::Algorithm &algorithm)
Get the pandora settings instance.
const pandora::CartesianVector & GetStartDirection() const
Get the start direction of the connection pathway.
void FindContinuousPath(const pandora::CaloHitList &refinedHitList, const pandora::CartesianVector &nuVertex2D, pandora::CaloHitList &continuousHitList) const
Find the continuous path of hits that lies closest to a given point.
void RefineShower(const pandora::ParticleFlowObject *const pShowerPfo) const
Find and evaluate shower connection pathway, removing if necessary.
void FillShowerPfoVector(pandora::PfoVector &showerPfoVector) const
Obtain a sorted vector of the reconstructed shower pfos.
unsigned int m_minNConnectedHits
The number of connected hits needed for a conntected pathway.
pandora::StatusCode GetNeutrinoVertex(pandora::CartesianVector &nuVertex3D) const
Obtain the reconstructed neutrino vertex.
std::string m_caloHitListNameW
The W calo hit list name.
pandora::CartesianVector GetShowerVertex(const pandora::ParticleFlowObject *const pShowerPfo, const pandora::HitType hitType, const pandora::CartesianVector &nuVertex3D) const
Fit the shower to obtain a 2D shower vertex.
std::string m_trainingFileName
The name of the output training file name.
std::map< const pandora::MCParticle *, pandora::CaloHitList > HitOwnershipMap
unsigned int m_showerSlidingFitWindow
The sliding fit window for shower fits.
float m_maxXSeparation
The max. drift-coordinate separation between a 3D shower start and a matched 2D shower hit.
float m_maxSeparationFromHit
The max. separation between the projected 3D shower start and the closest 2D shower hit.
pandora::StatusCode Run()
Run the algorithm.
std::string m_caloHitListNameU
The U calo hit list name.
bool IsElectron(const pandora::ParticleFlowObject *const pShowerPfo, const HitOwnershipMap &electronHitMap) const
To determine whether a pfo is a true leading electron via its completeness and purity.
bool IsShowerConnected(const pandora::CartesianVector &showerVertexPosition, const pandora::CartesianVector &nuVertex2D, const pandora::CartesianVector &peakDirection) const
To determine whether the shower vertex lies on the connection pathway.
PeakDirectionFinderTool * m_pEventPeakDirectionFinderTool
The other (not incl. shower) initial pathway direction finder tool.
pandora::StringVector m_algorithmToolNames
The algorithm tool names.
ElectronInitialRegionRefinementAlgorithm()
Default constructor.
ConnectionPathwayFeatureTool::FeatureToolMap m_featureToolMap
The feature tool map.
float m_minElectronPurity
The min. purity of an electron-like pfo.
pandora::StatusCode GetHitListOfType(const pandora::HitType hitType, const pandora::CaloHitList *&pCaloHitList) const
Obtain the event hit list of a given view.
float m_maxConnectionDistance
The max. distance between connected hits.
float m_maxProjectionSeparation
The max. separation between the projected 3D shower start and the shower start of that view.
ProtoShowerMatchingTool * m_pProtoShowerMatchingTool
The 2D -> 3D ProtoShower matching tool.
PeakDirectionFinderTool * m_pShowerPeakDirectionFinderTool
The shower initial pathway direction finder tool.
void FillElectronHitMap(HitOwnershipMap &electronHitMap) const
Determine the one-to-one mapping of leading MCParticle electrons and the hits which contain their ene...
std::string m_caloHitListNameV
The V calo hit list name.
void SetMetadata(const pandora::ParticleFlowObject *const pShowerPfo, const LArMvaHelper::MvaFeatureMap &featureMap) const
Add the shower characterisation information to the pfo metadata.
ShowerStartFinderTool * m_pShowerStartFinderTool
The shower start finder tool.
void BuildViewProtoShowers(const pandora::ParticleFlowObject *const pShowerPfo, const pandora::CartesianVector &nuVertex3D, pandora::HitType hitType, ProtoShowerVector &protoShowerVector) const
Build the 2D ProtoShower objects for a given view.
std::string m_showerPfoListName
The shower pfo list name.
void BuildViewPathways(const pandora::ParticleFlowObject *const pShowerPfo, const pandora::CaloHitList &protectedHits, const pandora::CartesianVector &nuVertex3D, pandora::HitType hitType, ConnectionPathwayVector &viewPathways) const
Build the connection pathways of all other particles in the event.
void RefineShowerVertex(const pandora::ParticleFlowObject *const pShowerPfo, const pandora::HitType hitType, const pandora::CartesianVector &nuVertex3D, const pandora::CartesianVector &peakDirection, pandora::CartesianVector &showerVertexPosition) const
Move the shower vertex closer to the connection pathway.
float m_minSpinePurity
The min. purity of a coincident shower spine downstream of the shower vertex.
bool m_trainingMode
Whether to run the algorithm to train the BDT.
float m_minElectronCompleteness
The min. completeness of an electron-like pfo.
void RefineHitsToAdd(const pandora::CartesianVector &nuVertex3D, const pandora::HitType hitType, const ConnectionPathwayVector &viewPathways, ProtoShower &protoShower) const
Determine the continuous and unambiguous hits to add to an electron-like shower pfo.
ShowerSpineFinderTool * m_pShowerSpineFinderTool
The shower spine finder tool for the shower.
float m_maxCoincidenceTransverseSeparation
The max. transverse distance from the pathway direction of a coincident shower vertex.
std::string m_neutrinoVertexListName
The neutrino vertex list name.
bool IsSpineCoincident(const pandora::ParticleFlowObject *const pShowerPfo, const pandora::CartesianVector &nuVertex3D, const pandora::HitType hitType, const pandora::CartesianVector &showerVertex, const pandora::CaloHitList &showerSpineHitList) const
To determine if the hits downstream of the shower vertex lie within the shower.
unsigned int m_minShowerHits3D
The min. number of hits of a significant shower.
ShowerSpineFinderTool * m_pEventPathwayFinderTool
The shower spine finder tool for all other event particles.
pandora::StatusCode ReadSettings(const pandora::TiXmlHandle xmlHandle)
Read the algorithm settings.
float m_unambiguousThreshold
The min. transverse distance of an unambiguous shower hit from another pathway direction.
static float GetClosestDistance(const pandora::ClusterList &clusterList1, const pandora::ClusterList &clusterList2)
Get closest distance between clusters in a pair of cluster lists.
SortByDistanceToPoint class.
static bool FindShowerStarts3D(const pandora::Algorithm *const pAlgorithm, const pandora::ParticleFlowObject *const pShowerPfo, const ProtoShowerMatch &protoShowerMatch, const pandora::CartesianVector &nuVertexPosition, const float maxSeparationFromHit, const float maxProjectionSeparation, const float maxXSeparation, pandora::CartesianPointVector &showerStarts3D)
Create 3D shower start position(s) from three input 2D positions.
static float GetWirePitch(const pandora::Pandora &pandora, const pandora::HitType view, const float maxWirePitchDiscrepancy=0.01)
Return the wire pitch.
static pandora::CartesianVector ProjectPosition(const pandora::Pandora &pandora, const pandora::CartesianVector &position3D, const pandora::HitType view)
Project 3D position into a given 2D view.
static pandora::CaloHitList GetSharedHits(const pandora::CaloHitList &hitListA, const pandora::CaloHitList &hitListB)
Get the hits in the intersection of two hit lists.
static const pandora::MCParticle * GetPrimaryMCParticle(const pandora::MCParticle *const pMCParticle)
Get the primary parent mc particle.
static pandora::StatusCode ProcessAlgorithmToolListToMap(const pandora::Algorithm &algorithm, const pandora::TiXmlHandle &xmlHandle, const std::string &listName, pandora::StringVector &algorithToolNameVector, AlgorithmToolMap &algorithmToolMap)
Process a list of algorithms tools in an xml file, using a map. Idea is for this to go to XmlHelper i...
std::map< std::string, pandora::AlgorithmTool * > AlgorithmToolMap
static MvaFeatureVector CalculateFeatures(const MvaFeatureToolVector< Ts... > &featureToolVector, TARGS &&... args)
Calculate the features in a given feature tool vector.
static pandora::StatusCode AddFeatureToolToMap(pandora::AlgorithmTool *const pFeatureTool, std::string pFeatureToolName, MvaFeatureToolMap< Ts... > &featureToolMap)
Add a feature tool to a map of feature tools.
static pandora::StatusCode ProduceTrainingExample(const std::string &trainingOutputFile, const bool result, TCONTAINER &&featureContainer)
Produce a training example with the given features and result.
MvaTypes::MvaFeatureMap MvaFeatureMap
static bool SortByNHits(const pandora::ParticleFlowObject *const pLhs, const pandora::ParticleFlowObject *const pRhs)
Sort pfos by number of constituent hits.
static void GetClusters(const pandora::PfoList &pfoList, const pandora::HitType &hitType, pandora::ClusterList &clusterList)
Get a list of clusters of a particular hit type from a list of pfos.
static void GetCaloHits(const pandora::PfoList &pfoList, const pandora::HitType &hitType, pandora::CaloHitList &caloHitList)
Get a list of calo hits of a particular hit type from a list of pfos.
pandora::StatusCode Run(const pandora::ParticleFlowObject *const pShowerPfo, const pandora::CartesianVector &nuVertex3D, const pandora::CaloHitList *const pViewHitList, const pandora::HitType hitType, pandora::CartesianPointVector &peakDirectionVector)
void SetHitsToAddList(const pandora::CaloHitList &hitsToAddList)
Set the hits to add list.
const pandora::CaloHitList & GetHitsToAddList() const
Get the hits to add list.
void AddHitToAdd(const pandora::CaloHit *const hitToAdd)
Add a hit to the hits to add list.
const ConnectionPathway & GetConnectionPathway() const
Get the connection pathway.
void AddAmbiguousDirection(const pandora::CartesianVector &ambiguousDirection)
Add an ambiguous direction to the ambiguous direction vector.
void AddAmbiguousHit(const pandora::CaloHit *const ambiguousHit)
Add an ambiguous hit to the ambiguous hit list.
const pandora::CartesianPointVector & GetAmbiguousDirectionVector() const
Get the ambiguous direction vector.
pandora::StatusCode Run(const ProtoShowerVector &protoShowerVectorU, const ProtoShowerVector &protoShowerVectorV, const ProtoShowerVector &protoShowerVectorW, ProtoShowerMatchVector &protoShowerMatchVector)
pandora::StatusCode Run(const pandora::CartesianVector &nuVertex3D, const pandora::CaloHitList *const pViewHitList, const pandora::HitType hitType, const pandora::CartesianVector &peakDirection, pandora::CaloHitList &unavailableHitList, pandora::CaloHitList &showerSpineHitList)
pandora::StatusCode Run(const pandora::ParticleFlowObject *const pShowerPfo, const pandora::CartesianVector &peakDirection, const pandora::HitType hitType, const pandora::CaloHitList &showerSpineHitList, pandora::CartesianVector &showerStartPosition, pandora::CartesianVector &showerStartDirection)
pandora::CartesianVector GetGlobalMinLayerPosition() const
Get global position corresponding to the fit result in minimum fit layer.
pandora::CartesianVector GetGlobalMaxLayerPosition() const
Get global position corresponding to the fit result in maximum fit layer.
TwoDSlidingShowerFitResult class.
const TwoDSlidingFitResult & GetShowerFitResult() const
Get the sliding fit result for the full shower cluster.
const CartesianVector & GetPositionVector() const
Get the position vector of center of calorimeter cell, units mm.
float GetZ() const
Get the cartesian z coordinate.
float GetDotProduct(const CartesianVector &rhs) const
Get the dot product of the cartesian vector with a second cartesian vector.
CartesianVector GetCrossProduct(const CartesianVector &rhs) const
Get the cross product of the cartesian vector with a second cartesian vector.
float GetOpeningAngle(const CartesianVector &rhs) const
Get the opening angle of the cartesian vector with respect to a second cartesian vector.
bool ShouldDisplayAlgorithmInfo() const
Whether to display algorithm information during processing.
ParticleFlowObject class.
StatusCode AlterMetadata(const object_creation::ParticleFlowObject::Metadata &metadata)
Alter particle flow object metadata parameters.
Enable ordering of pointers based on properties of target objects.
const Pandora & GetPandora() const
Get the associated pandora instance.
StatusCodeException class.
static StatusCode ReadValue(const TiXmlHandle &xmlHandle, const std::string &xmlElementName, T &t)
Read a value from an xml element.
static StatusCode ProcessAlgorithmToolList(const Algorithm &algorithm, const TiXmlHandle &xmlHandle, const std::string &listName, AlgorithmToolVector &algorithmToolVector)
Process a list of algorithms tools in an xml file.
static StatusCode ProcessAlgorithmTool(const Algorithm &algorithm, const TiXmlHandle &xmlHandle, const std::string &description, AlgorithmTool *&pAlgorithmTool)
Process an algorithm tool described in an xml element with a matching "description = ....
std::vector< ProtoShower > ProtoShowerVector
std::vector< ProtoShowerMatch > ProtoShowerMatchVector
std::vector< ConnectionPathway > ConnectionPathwayVector
HitType
Calorimeter hit type enum.
std::vector< const CaloHit * > CaloHitVector
std::unordered_map< const MCParticle *, float > MCParticleWeightMap
MANAGED_CONTAINER< const Cluster * > ClusterList
std::vector< const ParticleFlowObject * > PfoVector
std::vector< std::string > StringVector
std::vector< CartesianVector > CartesianPointVector
std::vector< AlgorithmTool * > AlgorithmToolVector
MANAGED_CONTAINER< const CaloHit * > CaloHitList
std::vector< const MCParticle * > MCParticleVector
MANAGED_CONTAINER< const Vertex * > VertexList
StatusCode
The StatusCode enum.
MANAGED_CONTAINER< const ParticleFlowObject * > PfoList