CMS 3D CMS Logo

 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Groups Pages
RecoTauDiscriminantCleanerPlugin.cc
Go to the documentation of this file.
1 /*
2  * RecoTauDiscriminantCleanerPlugin
3  *
4  * Author: Evan K. Friis, UC Davis
5  *
6  * A reco tau cleaner plugin that given a PFTau returns the associated value
7  * stored in a PFTauDiscrimiantor.
8  */
9 
12 
13 namespace reco {
14  namespace tau {
15 
17  public:
20 
21  // Get discriminant value for a given tau Ref
22  double operator()(const reco::PFTauRef&) const override;
23  // Hook called from base class at the beginning of each event
24  void beginEvent() override;
25 
26  private:
30  };
31 
34  : RecoTauCleanerPlugin(pset, std::move(iC)) {
37  }
38 
40  // Load our handle to the discriminators from the event
42  }
43 
45  // Get the discriminator result for this tau. N.B. result is negated! lower
46  // = more "tau like"! This is opposite to the normal case.
47  double result = -(*discriminator_)[tau];
48  return result;
49  }
50 
51  } // namespace tau
52 } // namespace reco
53 
54 // Register our plugin
58  "RecoTauDiscriminantCleanerPlugin");
bool getByToken(EDGetToken token, Handle< PROD > &result) const
Definition: Event.h:539
edm::EDGetTokenT< PFTauDiscriminator > discriminator_token
tuple result
Definition: mps_fire.py:311
double operator()(const reco::PFTauRef &) const override
def move
Definition: eostools.py:511
T getParameter(std::string const &) const
Definition: ParameterSet.h:303
RecoTauDiscriminantCleanerPlugin(const edm::ParameterSet &pset, edm::ConsumesCollector &&iC)
#define DEFINE_EDM_PLUGIN(factory, type, name)