10#include <tracking/trackFindingCDC/filters/base/FilterOnVarSet.dcl.h>
11#include <tracking/trackFindingCDC/filters/base/Filter.fwd.h>
13#include <tracking/trackFindingCDC/varsets/BaseVarSet.h>
15#include <tracking/trackFindingCDC/numerics/Weight.h>
17#include <framework/database/DBObjPtr.h>
18#include <tracking/dbobjects/TrackingMVAFilterParameters.h>
29 class ModuleParamList;
31 namespace TrackFindingCDC {
35 template<
class AFilter>
44 using Object =
typename AFilter::Object;
52 explicit MVA(std::unique_ptr<AVarSet> varSet,
53 const std::string& identifier =
"",
54 double defaultCut = NAN,
55 const std::string& dbObjectName =
"");
77 std::vector<float>
predict(
const std::vector<Object*>& objs);
80 virtual std::vector<float>
operator()(
const std::vector <Object*>& objs)
override;
99 template<
class AVarSet>
111 explicit MVAFilter(
const std::string& defaultTrainingName =
"",
112 double defaultCut = NAN,
113 const std::string& defaultDBObjectName =
"");
The Module parameter list class.
Object Object
Object type from which variables shall be extracted.
Convenience template to create a mva filter for a set of variables.
typename AVarSet::Object Object
Type of the object to be analysed.
~MVAFilter()
Default destructor.
Filter based on a mva method.
virtual ~MVA()
Default destructor.
void initialize() override
Initialize the expert before event processing.
Weight operator()(const Object &obj) override
Function to object for its signalness.
std::unique_ptr< MVAExpert > m_mvaExpert
MVA Expert to examine the object.
std::string m_DBPayloadName
Name of the DB payload.
void beginRun() override
Signal to load new run parameters.
typename AFilter::Object Object
Type of the object to be analysed.
virtual double predict(const Object &obj)
Evaluate the mva method.
void exposeParameters(ModuleParamList *moduleParamList, const std::string &prefix) override
Expose the set of parameters of the filter to the module parameter list.
double m_cutValue
The cut on the MVA output.
std::vector< Named< Float_t * > > m_namedVariables
named variables, ordered as in the weightFile:
std::string m_identifier
Database identifier of the expert or weight file name.
Filter adapter to make a filter work on a set of variables.
Abstract base class for different kinds of events.