Belle II Software development
|
Algorithm to collect the x best TrackCandidates per family based on a VXD Quality estimator method output. More...
#include <SPTCSelectorXBestPerFamily.h>
Public Member Functions | |
SPTCSelectorXBestPerFamily (unsigned short xBest=5, const std::string &estimationMethod=std::string("tripletFit")) | |
Constructor for the selection of the x best candidates for each family based on the quality index. | |
~SPTCSelectorXBestPerFamily ()=default | |
Destructor. | |
void | prepareSelector (unsigned short nFamilies) |
Preparation of Best Candidate Selector by resetting the vectors. | |
void | testNewSPTC (SpacePointTrackCand &sptc) |
Test new SPTC if it is better than the least best of the current x best SPTCs of its respective family. | |
std::vector< SpacePointTrackCand > | returnSelection () const |
Return vector containing the best SPTCs; maximal m_xBest per family. | |
void | setMagneticFieldForQE (double bFieldZ) |
Setting magnetic field for the quality estimator. | |
Private Attributes | |
std::unique_ptr< QualityEstimatorBase > | m_estimator |
Pointer to the Quality Estimator used to evaluate the SPTCs to find the best. | |
std::vector< std::multiset< SpacePointTrackCand > > | m_bestPaths |
Vector containing one vector of the best SPTCs per family. | |
std::vector< short > | m_familyToIndex |
Map of family number to respective index for m_bestPaths. | |
unsigned short | m_currentIndex = 0 |
Counter for current index used for m_familyToIndex. | |
unsigned short | m_xBest |
Number of allowed best SPTCs per family. | |
Algorithm to collect the x best TrackCandidates per family based on a VXD Quality estimator method output.
Definition at line 29 of file SPTCSelectorXBestPerFamily.h.
|
inline |
Constructor for the selection of the x best candidates for each family based on the quality index.
xBest | Maximal number of best candidates to be stored per family. |
estimationMethod | Quality estimator to be used. |
Definition at line 38 of file SPTCSelectorXBestPerFamily.h.
|
inline |
Preparation of Best Candidate Selector by resetting the vectors.
To be executed at the beginning of a new event after the families are defined to reset the respective vectors and set them up under consideration of the number of families in the event.
nFamilies | Number of families in the event. |
Definition at line 61 of file SPTCSelectorXBestPerFamily.h.
|
inline |
Return vector containing the best SPTCs; maximal m_xBest per family.
Definition at line 103 of file SPTCSelectorXBestPerFamily.h.
|
inline |
Setting magnetic field for the quality estimator.
bFieldZ | Magnetic Field value to be used for the Quality Estimation. |
Definition at line 119 of file SPTCSelectorXBestPerFamily.h.
|
inline |
Test new SPTC if it is better than the least best of the current x best SPTCs of its respective family.
If so, the least best is thrown out, and the new is added to the sorted x best SPTC multiset of the family. If the maximal number of best SPTCs is not reached for the family, yet, the SPTC is just added at the right place.
sptc | SpacePointTrackCandidate to be evaluated for adding. |
Definition at line 76 of file SPTCSelectorXBestPerFamily.h.
|
private |
Vector containing one vector of the best SPTCs per family.
Definition at line 130 of file SPTCSelectorXBestPerFamily.h.
|
private |
Counter for current index used for m_familyToIndex.
The counter is increased each time a family is seen for the first time and thus a new entry for this family is added to m_familyToIndex.
Definition at line 137 of file SPTCSelectorXBestPerFamily.h.
|
private |
Pointer to the Quality Estimator used to evaluate the SPTCs to find the best.
Definition at line 127 of file SPTCSelectorXBestPerFamily.h.
|
private |
Map of family number to respective index for m_bestPaths.
Definition at line 133 of file SPTCSelectorXBestPerFamily.h.
|
private |
Number of allowed best SPTCs per family.
Definition at line 140 of file SPTCSelectorXBestPerFamily.h.