CMS 3D CMS Logo

List of all members | Public Member Functions | Static Public Member Functions | Private Attributes
PFTauDiscriminatorLogicalAndProducer Class Reference
Inheritance diagram for PFTauDiscriminatorLogicalAndProducer:
TauDiscriminationProducerBase< TauType, TauDiscriminator, TauDiscriminatorDataType, ConsumeType > edm::stream::EDProducer<>

Public Member Functions

double discriminate (const PFTauRef &pfTau) const override
 
 PFTauDiscriminatorLogicalAndProducer (const edm::ParameterSet &)
 
 ~PFTauDiscriminatorLogicalAndProducer () override
 
- Public Member Functions inherited from TauDiscriminationProducerBase< TauType, TauDiscriminator, TauDiscriminatorDataType, ConsumeType >
virtual void beginEvent (const edm::Event &, const edm::EventSetup &)
 
virtual TauDiscriminatorDataType discriminate (const TauRef &tau) const =0
 
virtual void endEvent (edm::Event &)
 
void produce (edm::Event &, const edm::EventSetup &) override
 
 TauDiscriminationProducerBase (const edm::ParameterSet &iConfig)
 
 TauDiscriminationProducerBase ()
 
 ~TauDiscriminationProducerBase () override
 
- Public Member Functions inherited from edm::stream::EDProducer<>
 EDProducer ()=default
 
 EDProducer (const EDProducer &)=delete
 
bool hasAbilityToProduceInBeginLumis () const final
 
bool hasAbilityToProduceInBeginProcessBlocks () const final
 
bool hasAbilityToProduceInBeginRuns () const final
 
bool hasAbilityToProduceInEndLumis () const final
 
bool hasAbilityToProduceInEndProcessBlocks () const final
 
bool hasAbilityToProduceInEndRuns () const final
 
const EDProduceroperator= (const EDProducer &)=delete
 

Static Public Member Functions

static void fillDescriptions (edm::ConfigurationDescriptions &descriptions)
 
- Static Public Member Functions inherited from TauDiscriminationProducerBase< TauType, TauDiscriminator, TauDiscriminatorDataType, ConsumeType >
static void fillProducerDescriptions (edm::ParameterSetDescription &desc)
 
static std::string getTauTypeString ()
 helper method to retrieve tau type name, e.g. to build correct cfi getter More...
 

Private Attributes

double passResult_
 

Additional Inherited Members

- Public Types inherited from TauDiscriminationProducerBase< TauType, TauDiscriminator, TauDiscriminatorDataType, ConsumeType >
typedef std::vector< TauType > TauCollection
 
typedef edm::Ref< TauCollectionTauRef
 
typedef edm::RefProd< TauCollectionTauRefProd
 
- Public Types inherited from edm::stream::EDProducer<>
using CacheTypes = CacheContexts< T... >
 
using GlobalCache = typename CacheTypes::GlobalCache
 
using HasAbility = AbilityChecker< T... >
 
using InputProcessBlockCache = typename CacheTypes::InputProcessBlockCache
 
using LuminosityBlockCache = typename CacheTypes::LuminosityBlockCache
 
using LuminosityBlockContext = LuminosityBlockContextT< LuminosityBlockCache, RunCache, GlobalCache >
 
using LuminosityBlockSummaryCache = typename CacheTypes::LuminosityBlockSummaryCache
 
using RunCache = typename CacheTypes::RunCache
 
using RunContext = RunContextT< RunCache, GlobalCache >
 
using RunSummaryCache = typename CacheTypes::RunSummaryCache
 
- Protected Attributes inherited from TauDiscriminationProducerBase< TauType, TauDiscriminator, TauDiscriminatorDataType, ConsumeType >
std::string moduleLabel_
 
double prediscriminantFailValue_
 
edm::EDGetTokenT< TauCollectionTau_token
 
size_t tauIndex_
 
edm::InputTag TauProducer_
 

Detailed Description

Definition at line 21 of file PFTauDiscriminatorLogicalAndProducer.cc.

Constructor & Destructor Documentation

◆ PFTauDiscriminatorLogicalAndProducer()

PFTauDiscriminatorLogicalAndProducer::PFTauDiscriminatorLogicalAndProducer ( const edm::ParameterSet iConfig)
explicit

Definition at line 32 of file PFTauDiscriminatorLogicalAndProducer.cc.

References edm::ParameterSet::getParameter(), passResult_, and TauDiscriminationProducerBase< TauType, TauDiscriminator, TauDiscriminatorDataType, ConsumeType >::prediscriminantFailValue_.

34  passResult_ = iConfig.getParameter<double>("PassValue");
35  prediscriminantFailValue_ = iConfig.getParameter<double>("FailValue"); //defined in base class
36 }
T getParameter(std::string const &) const
Definition: ParameterSet.h:303
TauDiscriminationProducerBase< reco::PFTau, reco::PFTauDiscriminator > PFTauDiscriminationProducerBase

◆ ~PFTauDiscriminatorLogicalAndProducer()

PFTauDiscriminatorLogicalAndProducer::~PFTauDiscriminatorLogicalAndProducer ( )
inlineoverride

Definition at line 24 of file PFTauDiscriminatorLogicalAndProducer.cc.

24 {};

Member Function Documentation

◆ discriminate()

double PFTauDiscriminatorLogicalAndProducer::discriminate ( const PFTauRef pfTau) const
override

Definition at line 38 of file PFTauDiscriminatorLogicalAndProducer.cc.

References passResult_.

38  {
39  // if this function is called on a tau, it is has passed (in the base class)
40  // the set of prediscriminants, using the prescribed boolean operation. thus
41  // we only need to return TRUE
42  return passResult_;
43 }

◆ fillDescriptions()

void PFTauDiscriminatorLogicalAndProducer::fillDescriptions ( edm::ConfigurationDescriptions descriptions)
static

Definition at line 45 of file PFTauDiscriminatorLogicalAndProducer.cc.

References edm::ConfigurationDescriptions::add(), edm::ParameterSetDescription::add(), submitPVResolutionJobs::desc, ProducerED_cfi::InputTag, and AlCaHLTBitMon_QueryRunRegistry::string.

45  {
46  // PFTauDiscriminatorLogicalAndProducer
48 
49  {
51  psd0.add<std::string>("BooleanOperator", "and");
52  {
54  psd1.add<double>("cut", 0.5);
55  psd1.add<edm::InputTag>("Producer", edm::InputTag("pfRecoTauDiscriminationAgainstElectron"));
56  psd0.add<edm::ParameterSetDescription>("discr2", psd1);
57  }
58  {
60  psd1.add<double>("cut", 0.5);
61  psd1.add<edm::InputTag>("Producer", edm::InputTag("pfRecoTauDiscriminationByIsolation"));
62  psd0.add<edm::ParameterSetDescription>("discr1", psd1);
63  }
64  desc.add<edm::ParameterSetDescription>("Prediscriminants", psd0);
65  }
66 
67  desc.add<double>("PassValue", 1.0);
68  desc.add<double>("FailValue", 0.0);
69  desc.add<edm::InputTag>("PFTauProducer", edm::InputTag("pfRecoTauProducer"));
70  descriptions.add("PFTauDiscriminatorLogicalAndProducer", desc);
71 }
ParameterDescriptionBase * add(U const &iLabel, T const &value)
void add(std::string const &label, ParameterSetDescription const &psetDescription)

Member Data Documentation

◆ passResult_

double PFTauDiscriminatorLogicalAndProducer::passResult_
private