CMS 3D CMS Logo

PATTauProducer.h
Go to the documentation of this file.
1 //
2 //
3 
4 #ifndef PhysicsTools_PatAlgos_PATTauProducer_h
5 #define PhysicsTools_PatAlgos_PATTauProducer_h
6 
22 
26 
28 
32 
34 
37 
42 
44 
45 #include <string>
46 
49 namespace pat {
50 
52  public:
53  explicit PATTauProducer(const edm::ParameterSet& iConfig);
54  ~PATTauProducer() override;
55 
56  void produce(edm::Event& iEvent, const edm::EventSetup& iSetup) override;
57 
58  static void fillDescriptions(edm::ConfigurationDescriptions& descriptions);
59 
60  private:
61  bool firstOccurence_; // used to print LogWarnings only at first occurnece in the event loop
62 
63  // configurables
82 
85  std::vector<edm::EDGetTokenT<edm::Association<reco::GenParticleCollection> > > genMatchTokens_;
86 
90 
92  std::vector<edm::EDGetTokenT<edm::ValueMap<TauJetCorrFactors> > > tauJetCorrFactorsTokens_;
93 
94  bool addTauID_;
95  typedef std::pair<std::string, edm::InputTag> NameTag;
96  typedef std::pair<std::string, std::string> WPCfg;
97  typedef std::pair<WPCfg, int> WPIdx;
98  typedef std::pair<std::string, WPIdx> NameWPIdx;
99  typedef std::pair<edm::InputTag, std::vector<NameWPIdx> >
100  IDContainerData; //to save input module tag and corresponding pairs <working point name for the output tree, WP index in the input ID container>
101  std::vector<NameTag> tauIDSrcs_;
102  std::vector<std::vector<NameWPIdx> > tauIDSrcContainers_;
103  std::vector<edm::EDGetTokenT<reco::PFTauDiscriminator> > pfTauIDTokens_;
104  std::vector<edm::EDGetTokenT<reco::TauDiscriminatorContainer> > pfTauIDContainerTokens_;
107  // tools
109 
111  pat::helper::MultiIsolator::IsolationValuePairs isolatorTmpStorage_; // better here than recreate at each event
112  std::vector<std::pair<pat::IsolationKeys, edm::InputTag> > isoDepositLabels_;
113  std::vector<edm::EDGetTokenT<edm::ValueMap<IsoDeposit> > > isoDepositTokens_;
114 
117 
120 
123 
124  template <typename TauCollectionType, typename TauDiscrType>
127  size_t,
129  int);
130 
132  };
133 
134 } // namespace pat
135 
136 #endif
pat::PATTauProducer::firstOccurence_
bool firstOccurence_
Definition: PATTauProducer.h:61
ProcessHistoryID.h
pat::PATTauProducer::pfTauToken_
edm::EDGetTokenT< reco::PFTauCollection > pfTauToken_
Definition: PATTauProducer.h:66
Handle.h
PATUserDataMerger.h
pat::PATUserDataHelper< pat::Tau >
GreaterByPt
Definition: PtComparator.h:24
pat::PATTauProducer::addGenJetMatch_
bool addGenJetMatch_
Definition: PATTauProducer.h:87
pat::PATTauProducer::PATTauProducer
PATTauProducer(const edm::ParameterSet &iConfig)
Definition: PATTauProducer.cc:30
PFTauDiscriminator.h
pat::PATTauProducer::tauIDSrcContainers_
std::vector< std::vector< NameWPIdx > > tauIDSrcContainers_
Definition: PATTauProducer.h:102
pat::helper::EfficiencyLoader
Definition: EfficiencyLoader.h:16
pat::PATTauProducer::WPIdx
std::pair< WPCfg, int > WPIdx
Definition: PATTauProducer.h:97
edm::EDGetTokenT
Definition: EDGetToken.h:33
pat::PATTauProducer
Produces pat::Tau's.
Definition: PATTauProducer.h:51
pat::PATTauProducer::embedIsolationPFNeutralHadrCands_
bool embedIsolationPFNeutralHadrCands_
Definition: PATTauProducer.h:80
pat::PATTauProducer::embedSignalTracks_
bool embedSignalTracks_
Definition: PATTauProducer.h:70
pat::PATTauProducer::embedIsolationTracks_
bool embedIsolationTracks_
Definition: PATTauProducer.h:68
pat::PATTauProducer::embedGenMatch_
bool embedGenMatch_
Definition: PATTauProducer.h:84
PFTauTIPAssociationByRef
edm::AssociationVector< reco::PFTauRefProd, std::vector< reco::PFTauTransverseImpactParameterRef > > PFTauTIPAssociationByRef
Definition: PATTauProducer.h:48
EDProducer.h
PtComparator.h
pat::PATTauProducer::embedLeadPFCand_
bool embedLeadPFCand_
Definition: PATTauProducer.h:71
pat::PATTauProducer::embedIsolationPFGammaCands_
bool embedIsolationPFGammaCands_
Definition: PATTauProducer.h:81
pat::PATTauProducer::embedLeadPFChargedHadrCand_
bool embedLeadPFChargedHadrCand_
Definition: PATTauProducer.h:72
pat::PATTauProducer::isolator_
pat::helper::MultiIsolator isolator_
Definition: PATTauProducer.h:110
pat::PATTauProducer::pfTauIDContainerTokens_
std::vector< edm::EDGetTokenT< reco::TauDiscriminatorContainer > > pfTauIDContainerTokens_
Definition: PATTauProducer.h:104
pat::PATTauProducer::addGenMatch_
bool addGenMatch_
Definition: PATTauProducer.h:83
edm::Handle
Definition: AssociativeIterator.h:50
Tau.h
pat::helper::MultiIsolator::IsolationValuePairs
std::vector< std::pair< pat::IsolationKeys, float > > IsolationValuePairs
Definition: MultiIsolator.h:17
MultiIsolator.h
EfficiencyLoader.h
pat::PATTauProducer::phID_
edm::ProcessHistoryID phID_
Definition: PATTauProducer.h:106
PositionAtECalEntranceComputer
Definition: PositionAtECalEntranceComputer.h:25
pat::PATTauProducer::addResolutions_
bool addResolutions_
Definition: PATTauProducer.h:118
pat::PATTauProducer::embedSignalPFGammaCands_
bool embedSignalPFGammaCands_
Definition: PATTauProducer.h:77
pat::PATTauProducer::posAtECalEntranceComputer_
PositionAtECalEntranceComputer posAtECalEntranceComputer_
Definition: PATTauProducer.h:131
pat::PATTauProducer::genMatchTokens_
std::vector< edm::EDGetTokenT< edm::Association< reco::GenParticleCollection > > > genMatchTokens_
Definition: PATTauProducer.h:85
pat::PATTauProducer::NameTag
std::pair< std::string, edm::InputTag > NameTag
Definition: PATTauProducer.h:95
pat::PATTauProducer::embedLeadTrack_
bool embedLeadTrack_
Definition: PATTauProducer.h:69
pat::PATTauProducer::isoDepositLabels_
std::vector< std::pair< pat::IsolationKeys, edm::InputTag > > isoDepositLabels_
Definition: PATTauProducer.h:112
pat::PATTauProducer::isolatorTmpStorage_
pat::helper::MultiIsolator::IsolationValuePairs isolatorTmpStorage_
Definition: PATTauProducer.h:111
ProductProvenance.h
pat::PATTauProducer::NameWPIdx
std::pair< std::string, WPIdx > NameWPIdx
Definition: PATTauProducer.h:98
pat::helper::KinResolutionsLoader
Definition: KinResolutionsLoader.h:18
KinResolutionsLoader.h
pat::PATTauProducer::~PATTauProducer
~PATTauProducer() override
Definition: PATTauProducer.cc:173
edm::Hash< ProcessHistoryType >
pat::PATTauProducer::tauIDSrcs_
std::vector< NameTag > tauIDSrcs_
Definition: PATTauProducer.h:101
pat::PATTauProducer::genJetMatchToken_
edm::EDGetTokenT< edm::Association< reco::GenJetCollection > > genJetMatchToken_
Definition: PATTauProducer.h:89
pat::PATTauProducer::addTauJetCorrFactors_
bool addTauJetCorrFactors_
Definition: PATTauProducer.h:91
PFTauTransverseImpactParameterFwd.h
edm::ConfigurationDescriptions
Definition: ConfigurationDescriptions.h:28
edm::AssociationVector
Definition: AssociationVector.h:67
pat::PATTauProducer::WPCfg
std::pair< std::string, std::string > WPCfg
Definition: PATTauProducer.h:96
edm::ParameterSet
Definition: ParameterSet.h:47
pat::PATTauProducer::embedSignalPFChargedHadrCands_
bool embedSignalPFChargedHadrCands_
Definition: PATTauProducer.h:75
Event.h
pat::PATTauProducer::efficiencyLoader_
pat::helper::EfficiencyLoader efficiencyLoader_
Definition: PATTauProducer.h:116
UserData.h
pat::PATTauProducer::pfTauIDTokens_
std::vector< edm::EDGetTokenT< reco::PFTauDiscriminator > > pfTauIDTokens_
Definition: PATTauProducer.h:103
pat::PATTauProducer::baseTauToken_
edm::EDGetTokenT< edm::View< reco::BaseTau > > baseTauToken_
Definition: PATTauProducer.h:64
pat::PATTauProducer::skipMissingTauID_
bool skipMissingTauID_
Definition: PATTauProducer.h:105
iEvent
int iEvent
Definition: GenABIO.cc:224
pat::PATTauProducer::isoDepositTokens_
std::vector< edm::EDGetTokenT< edm::ValueMap< IsoDeposit > > > isoDepositTokens_
Definition: PATTauProducer.h:113
pat::PATTauProducer::embedSignalPFNeutralHadrCands_
bool embedSignalPFNeutralHadrCands_
Definition: PATTauProducer.h:76
pat::PATTauProducer::embedIsolationPFCands_
bool embedIsolationPFCands_
Definition: PATTauProducer.h:78
edm::stream::EDProducer
Definition: EDProducer.h:38
TauDiscriminatorContainer.h
edm::EventSetup
Definition: EventSetup.h:58
pat
Definition: HeavyIon.h:7
pat::PATTauProducer::embedGenJetMatch_
bool embedGenJetMatch_
Definition: PATTauProducer.h:88
InputTag.h
pat::helper::MultiIsolator
Definition: MultiIsolator.h:15
pat::PATTauProducer::pTTauComparator_
GreaterByPt< Tau > pTTauComparator_
Definition: PATTauProducer.h:108
pat::PATTauProducer::userDataHelper_
pat::PATUserDataHelper< pat::Tau > userDataHelper_
Definition: PATTauProducer.h:122
pat::PATTauProducer::embedIsolationPFChargedHadrCands_
bool embedIsolationPFChargedHadrCands_
Definition: PATTauProducer.h:79
pat::PATTauProducer::addTauID_
bool addTauID_
Definition: PATTauProducer.h:94
pat::PATTauProducer::fillDescriptions
static void fillDescriptions(edm::ConfigurationDescriptions &descriptions)
Definition: PATTauProducer.cc:731
pat::PATTauProducer::embedLeadPFNeutralCand_
bool embedLeadPFNeutralCand_
Definition: PATTauProducer.h:73
pat::PATTauProducer::getTauIdDiscriminator
float getTauIdDiscriminator(const edm::Handle< TauCollectionType > &, size_t, const edm::Handle< TauDiscrType > &)
Definition: PATTauProducer.cc:705
Provenance.h
PATUserDataHelper.h
pat::PATTauProducer::getTauIdDiscriminatorFromContainer
float getTauIdDiscriminatorFromContainer(const edm::Handle< reco::PFTauCollection > &, size_t, const edm::Handle< reco::TauDiscriminatorContainer > &, int)
Definition: PATTauProducer.cc:711
pat::PATTauProducer::tauJetCorrFactorsTokens_
std::vector< edm::EDGetTokenT< edm::ValueMap< TauJetCorrFactors > > > tauJetCorrFactorsTokens_
Definition: PATTauProducer.h:92
pat::PATTauProducer::resolutionLoader_
pat::helper::KinResolutionsLoader resolutionLoader_
Definition: PATTauProducer.h:119
pat::PATTauProducer::tauTransverseImpactParameterToken_
edm::EDGetTokenT< PFTauTIPAssociationByRef > tauTransverseImpactParameterToken_
Definition: PATTauProducer.h:65
pat::PATTauProducer::embedSignalPFCands_
bool embedSignalPFCands_
Definition: PATTauProducer.h:74
pat::PATTauProducer::tauTransverseImpactParameterSrc_
edm::InputTag tauTransverseImpactParameterSrc_
Definition: PATTauProducer.h:67
ParameterSet.h
pat::PATTauProducer::useUserData_
bool useUserData_
Definition: PATTauProducer.h:121
pat::PATTauProducer::produce
void produce(edm::Event &iEvent, const edm::EventSetup &iSetup) override
Definition: PATTauProducer.cc:175
edm::Event
Definition: Event.h:73
pat::PATTauProducer::addEfficiencies_
bool addEfficiencies_
Definition: PATTauProducer.h:115
PositionAtECalEntranceComputer.h
edm::InputTag
Definition: InputTag.h:15
pat::PATTauProducer::IDContainerData
std::pair< edm::InputTag, std::vector< NameWPIdx > > IDContainerData
Definition: PATTauProducer.h:100