8#include <tracking/ckf/svd/filters/results/SVDResultFilterFactory.h>
10#include <tracking/trackFindingCDC/filters/base/FilterFactory.icc.h>
11#include <tracking/trackFindingCDC/filters/base/AllFilter.icc.h>
12#include <tracking/trackFindingCDC/filters/base/NoneFilter.icc.h>
13#include <tracking/trackFindingCDC/filters/base/ChoosableFromVarSetFilter.icc.h>
14#include <tracking/trackFindingCDC/filters/base/RecordingFilter.icc.h>
15#include <tracking/trackFindingCDC/filters/base/MVAFilter.icc.h>
17#include <tracking/trackFindingCDC/varsets/VariadicUnionVarSet.h>
19#include <tracking/ckf/svd/filters/results/SVDResultVarSet.h>
20#include <tracking/ckf/svd/filters/results/RelationSVDResultVarSet.h>
21#include <tracking/ckf/svd/filters/results/SVDResultTruthVarSet.h>
22#include <tracking/ckf/svd/filters/results/SizeSVDResultFilter.h>
23#include <tracking/ckf/svd/filters/results/WeightSVDResultFilter.h>
26using namespace TrackFindingCDC;
33 using RecordingSVDResultFilter =
37 using RecordingSVDSeededResultFilter =
49 :
Super(defaultFilterName)
62 return "Reject SVD CKF results. ";
68 {
"none",
"no combination is valid"},
69 {
"all",
"all combination are valid"},
70 {
"recording",
"record variables to a TTree"},
71 {
"recording_with_relations",
"record variables to a TTree"},
72 {
"mva",
"filter based on the trained MVA method"},
73 {
"mva_with_relations",
"filter based on the trained MVA method"},
74 {
"size",
"ordering according to size"},
75 {
"weight",
"ordering according to weight"},
76 {
"truth",
"monte carlo truth"},
77 {
"truth_svd_cdc_relation",
"monte carlo truth on the related CDC and SVD tracks"},
81std::unique_ptr<BaseSVDResultFilter>
84 if (filterName ==
"none") {
85 return std::make_unique<TrackFindingCDC::NoneFilter<BaseSVDResultFilter>>();
87 }
else if (filterName ==
"all") {
88 return std::make_unique<TrackFindingCDC::AllFilter<BaseSVDResultFilter>>();
90 }
else if (filterName ==
"recording") {
91 return std::make_unique<RecordingSVDResultFilter>();
93 }
else if (filterName ==
"recording_with_relations") {
94 return std::make_unique<RecordingSVDSeededResultFilter>();
96 }
else if (filterName ==
"mva") {
97 return std::make_unique<MVASVDResultFilter>(
"ckf_CDCToSVDResult");
99 }
else if (filterName ==
"mva_with_relations") {
100 return std::make_unique<MVASVDSeededResultFilter>(
"ckf_SeededCDCToSVDResult");
102 }
else if (filterName ==
"truth") {
103 return std::make_unique<ChooseableTruthSVDResultFilter>(
"truth");
105 }
else if (filterName ==
"truth_svd_cdc_relation") {
106 return std::make_unique<ChooseableTruthSVDResultFilter>(
"truth_svd_cdc_relation");
108 }
else if (filterName ==
"size") {
109 return std::make_unique<SizeSVDResultFilter>();
111 }
else if (filterName ==
"weight") {
112 return std::make_unique<WeightSVDResultFilter>();
SVDResultFilterFactory(const std::string &defaultFilterName="all")
Constructor forwarding the default filter name.
std::map< std::string, std::string > getValidFilterNamesAndDescriptions() const override
Getter for valid filter names and a description for each.
std::string getIdentifier() const override
Getter for a short identifier for the factory.
~SVDResultFilterFactory()
Default destructor.
std::string getFilterPurpose() const override
Getter for a descriptive purpose of the constructed filters.
std::unique_ptr< BaseSVDResultFilter > create(const std::string &filterName) const override
Create a filter with the given name.
Convince template to create a filter returning on variable from a set of variables.
virtual std::unique_ptr< BaseSVDResultFilter > create(const std::string &filterName) const
Create a filter with the given name, does not set filter specific parameters.
Convenience template to create a mva filter for a set of variables.
Convenience template to create a recording filter for a set of variables.
Abstract base class for different kinds of events.