Pandora
Pandora source code navigator
Loading...
Searching...
No Matches
CheatingVertexSelectionAlgorithm.cc
Go to the documentation of this file.
1
10
12
13using namespace pandora;
14
15namespace lar_content
16{
17
18void CheatingVertexSelectionAlgorithm::GetVertexScoreList(const VertexVector &vertexVector, const BeamConstants & /*beamConstants*/,
19 HitKDTree2D & /*kdTreeU*/, HitKDTree2D & /*kdTreeV*/, HitKDTree2D & /*kdTreeW*/, VertexScoreList &vertexScoreList) const
20{
21 const Vertex *pBestVertex(nullptr);
22 float bestVertexDr(std::numeric_limits<float>::max());
23 this->GetBestVertex(vertexVector, pBestVertex, bestVertexDr);
24 if (pBestVertex)
25 vertexScoreList.emplace_back(pBestVertex, 1.0f);
26}
27
28//------------------------------------------------------------------------------------------------------------------------------------------
29
31{
32 // ATTN : Need access to base class member variables at this point, so call read settings prior to end of this function
34
35 if (m_mcParticleListName.empty())
36 {
37 std::cout << "CheatingVertexSelectionAlgorithm: MCParticleListName required for cheated vertex selection" << std::endl;
38 return STATUS_CODE_INVALID_PARAMETER;
39 }
40
41 return STATUS_CODE_SUCCESS;
42}
43
44} // namespace lar_content
Grouping of header files for many classes of use in particle flow algorithms.
Header file for the cheating vertex selection algorithm class.
#define PANDORA_RETURN_RESULT_IF(StatusCode1, Operator, Command)
Definition StatusCodes.h:19
void GetVertexScoreList(const pandora::VertexVector &vertexVector, const BeamConstants &beamConstants, HitKDTree2D &kdTreeU, HitKDTree2D &kdTreeV, HitKDTree2D &kdTreeW, VertexScoreList &vertexScoreList) const
Get the vertex score list.
pandora::StatusCode ReadSettings(const pandora::TiXmlHandle xmlHandle)
Read the algorithm settings.
pandora::StatusCode ReadSettings(const pandora::TiXmlHandle xmlHandle)
Read the algorithm settings.
std::string m_mcParticleListName
The MC particle list for creating training examples.
void GetBestVertex(const pandora::VertexVector &vertexVector, const pandora::Vertex *&pBestVertex, float &bestVertexDr) const
Use the MC information to get the best vertex from a list.
Vertex class.
Definition Vertex.h:26
StatusCode
The StatusCode enum.
std::vector< const Vertex * > VertexVector