8#include <tracking/trackFindingCDC/findlets/combined/TrackQualityEstimator.h>
10#include <tracking/trackFindingCDC/eventdata/tracks/CDCTrack.h>
12#include <tracking/trackFindingCDC/filters/base/ChooseableFilter.icc.h>
14#include <tracking/trackFindingCDC/utilities/StringManipulation.h>
15#include <tracking/trackFindingCDC/utilities/Algorithms.h>
17#include <framework/core/ModuleParamList.templateDetails.h>
20using namespace TrackFindingCDC;
25 : m_trackQualityFilter(defaultFilterName)
40 return "Set the quality indicator for CDC tracks and, if desired, delete tracks with a too low quality value.";
48 moduleParamList->
addParameter(prefixed(prefix,
"deleteTracks"),
50 "Delete tracks below cut instead of just assigning quality indicator.",
53 moduleParamList->
addParameter(prefixed(prefix,
"resetTakenFlag"),
55 "Reset taken flag for deleted tracks so that hits can be used by subsequent TFs.",
65 track.setQualityIndicator(qualityIndicator);
69 auto reject = [
this](
const CDCTrack & track) {
70 const double qualityIndicator = track.getQualityIndicator();
72 track.forwardTakenFlag(
false);
74 return std::isnan(qualityIndicator);
76 erase_remove_if(tracks, reject);
The Module parameter list class.
void apply(std::vector< CDCTrack > &cdcTracks) final
Write give tracks into track store array.
Class representing a sequence of three dimensional reconstructed hits.
Convenvience wrapper to setup a Chooseable filter from a specific factory object.
void initialize() override
Receive and dispatch signal before the start of the event processing.
void addProcessingSignalListener(ProcessingSignalListener *psl)
Register a processing signal listener to be notified.
virtual void exposeParameters(ModuleParamList *moduleParamList, const std::string &prefix)
Forward prefixed parameters of this findlet to the module parameter list.
bool m_param_resetTakenFlag
Reset taken flag for deleted tracks so that hits can be used by subsequent TFs.
bool m_param_deleteTracks
Delete tracks below threshold instead of just assigning quality indicator.
void apply(std::vector< CDCTrack > &tracks) final
Main algorithm.
void initialize() override
Receive and dispatch signal before the start of the event processing.
bool m_needsTruthInformation
Store output of needsTruthInformation from filter in member variable.
ChooseableFilter< TrackQualityFilterFactory > m_trackQualityFilter
Reference to the filter to be used to filter.
std::string getDescription() final
Short description of the findlet.
void exposeParameters(ModuleParamList *moduleParamList, const std::string &prefix) final
Expose the parameters to a module.
CDCMCCloneLookUpFiller m_mcCloneLookUpFiller
Findlet to fill CDCTracks into lookup table (singleton) with clone information.
TrackQualityEstimator(const std::string &defaultFilterName="mva")
Constructor adding the filter as a subordinary processing signal listener.
void addParameter(const std::string &name, T ¶mVariable, const std::string &description, const T &defaultValue)
Adds a new parameter to the module list.
Abstract base class for different kinds of events.