Belle II Software release-09-00-00
TOPReconstructorModule::PDFCollection Struct Reference

A collection of PDF's of charged stable particles for a given track. More...

Collaboration diagram for TOPReconstructorModule::PDFCollection:

Public Member Functions

 PDFCollection (const TOP::TOPTrack &trk, bool deltaRayModeling)
 Constructor.
 
void deletePDFs ()
 Release memory allocated in the constructor.
 
void setMostProbable ()
 Sets most probable hypothesis.
 
void appendPDFOther (const TOP::PDFConstructor *pdfOther)
 Append most probable PDF of other track in the same module.
 
void clearPDFOther ()
 Clear the containers of PDF's of other tracks.
 

Public Attributes

const TOP::TOPTracktopTrack = 0
 track
 
std::vector< TOP::PDFConstructor * > PDFs
 PDF's of charged stable particles.
 
const TOP::PDFConstructormostProbable = 0
 PDF of most probable particle hypothesis.
 
bool isValid = false
 true if all PDF's are provided
 

Detailed Description

A collection of PDF's of charged stable particles for a given track.

Definition at line 72 of file TOPReconstructorModule.h.

Constructor & Destructor Documentation

◆ PDFCollection()

PDFCollection ( const TOP::TOPTrack trk,
bool  deltaRayModeling 
)
inline

Constructor.

Parameters
trkgiven track
deltaRayModelinginclude or exclude delta-ray modeling in log likelihood calculation

Definition at line 84 of file TOPReconstructorModule.h.

85 {
86 topTrack = &trk;
87 for (const auto& chargedStable : Const::chargedStableSet) {
88 auto* pdf = new TOP::PDFConstructor(trk, chargedStable);
89 if (not pdf->isValid()) {
90 delete pdf;
91 for (auto PDF : PDFs) delete PDF;
92 PDFs.clear();
93 return;
94 }
95 pdf->switchDeltaRayPDF(deltaRayModeling);
96 PDFs.push_back(pdf);
97 }
98 isValid = true;
99 }
static const ParticleSet chargedStableSet
set of charged stable particles
Definition: Const.h:618
bool isValid
true if all PDF's are provided
std::vector< TOP::PDFConstructor * > PDFs
PDF's of charged stable particles.

Member Function Documentation

◆ appendPDFOther()

void appendPDFOther ( const TOP::PDFConstructor pdfOther)
inline

Append most probable PDF of other track in the same module.

Parameters
pdfOtherPDF of other track

Definition at line 131 of file TOPReconstructorModule.h.

132 {
133 if (not isValid) return;
134 for (const auto pdf : PDFs) pdf->appendPDFOther(pdfOther);
135 }

◆ clearPDFOther()

void clearPDFOther ( )
inline

Clear the containers of PDF's of other tracks.

Definition at line 140 of file TOPReconstructorModule.h.

141 {
142 if (not isValid) return;
143 for (const auto pdf : PDFs) pdf->clearPDFOther();
144 }

◆ deletePDFs()

void deletePDFs ( )
inline

Release memory allocated in the constructor.

Definition at line 104 of file TOPReconstructorModule.h.

105 {
106 for (auto pdf : PDFs) delete pdf;
107 PDFs.clear();
108 isValid = false;
109 }

◆ setMostProbable()

void setMostProbable ( )
inline

Sets most probable hypothesis.

Definition at line 114 of file TOPReconstructorModule.h.

115 {
116 if (not isValid) return;
117 double maxLogL = -std::numeric_limits<double>::infinity();
118 for (const auto pdf : PDFs) {
119 double logL = pdf->getLogL().logL;
120 if (logL > maxLogL) {
121 mostProbable = pdf;
122 maxLogL = logL;
123 }
124 }
125 }
const TOP::PDFConstructor * mostProbable
PDF of most probable particle hypothesis.

Member Data Documentation

◆ isValid

bool isValid = false

true if all PDF's are provided

Definition at line 77 of file TOPReconstructorModule.h.

◆ mostProbable

const TOP::PDFConstructor* mostProbable = 0

PDF of most probable particle hypothesis.

Definition at line 76 of file TOPReconstructorModule.h.

◆ PDFs

std::vector<TOP::PDFConstructor*> PDFs

PDF's of charged stable particles.

Definition at line 75 of file TOPReconstructorModule.h.

◆ topTrack

const TOP::TOPTrack* topTrack = 0

track

Definition at line 74 of file TOPReconstructorModule.h.


The documentation for this struct was generated from the following file: