CMS 3D CMS Logo

/data/doxygen/doxygen-1.7.3/gen/CMSSW_4_2_8/src/PhysicsTools/PatAlgos/plugins/PATTauProducer.h

Go to the documentation of this file.
00001 //
00002 // $Id: PATTauProducer.h,v 1.22 2010/11/08 16:18:06 veelken Exp $
00003 //
00004 
00005 #ifndef PhysicsTools_PatAlgos_PATTauProducer_h
00006 #define PhysicsTools_PatAlgos_PATTauProducer_h
00007 
00020 #include "FWCore/Framework/interface/EDProducer.h"
00021 #include "FWCore/Framework/interface/Event.h"
00022 #include "FWCore/ParameterSet/interface/ParameterSet.h"
00023 #include "FWCore/Utilities/interface/InputTag.h"
00024 
00025 #include "DataFormats/Common/interface/Handle.h"
00026 
00027 #include "CommonTools/Utils/interface/PtComparator.h"
00028 
00029 #include "PhysicsTools/PatAlgos/interface/MultiIsolator.h"
00030 #include "PhysicsTools/PatAlgos/interface/EfficiencyLoader.h"
00031 #include "PhysicsTools/PatAlgos/interface/KinResolutionsLoader.h"
00032 
00033 #include "DataFormats/PatCandidates/interface/Tau.h"
00034 
00035 #include "DataFormats/PatCandidates/interface/UserData.h"
00036 #include "PhysicsTools/PatAlgos/interface/PATUserDataMerger.h"
00037 #include "PhysicsTools/PatAlgos/interface/PATUserDataHelper.h"
00038 
00039 #include "DataFormats/TauReco/interface/CaloTauDiscriminator.h"
00040 #include "DataFormats/TauReco/interface/PFTauDiscriminator.h"
00041 
00042 #include <string>
00043 
00044 
00045 namespace pat {
00046 
00047   class PATTauProducer : public edm::EDProducer {
00048 
00049     public:
00050 
00051       explicit PATTauProducer(const edm::ParameterSet & iConfig);
00052       ~PATTauProducer();
00053 
00054       virtual void produce(edm::Event & iEvent, const edm::EventSetup & iSetup);
00055 
00056       static void fillDescriptions(edm::ConfigurationDescriptions & descriptions);
00057 
00058     private:
00059 
00060       // configurables
00061       edm::InputTag tauSrc_;
00062       bool embedIsolationTracks_;
00063       bool embedLeadTrack_;
00064       bool embedSignalTracks_;
00065       bool embedLeadPFCand_; 
00066       bool embedLeadPFChargedHadrCand_; 
00067       bool embedLeadPFNeutralCand_; 
00068       bool embedSignalPFCands_; 
00069       bool embedSignalPFChargedHadrCands_; 
00070       bool embedSignalPFNeutralHadrCands_; 
00071       bool embedSignalPFGammaCands_; 
00072       bool embedIsolationPFCands_; 
00073       bool embedIsolationPFChargedHadrCands_; 
00074       bool embedIsolationPFNeutralHadrCands_; 
00075       bool embedIsolationPFGammaCands_; 
00076 
00077       bool          addGenMatch_;
00078       bool          embedGenMatch_;
00079       std::vector<edm::InputTag> genMatchSrc_;
00080 
00081       bool          addGenJetMatch_;
00082       bool          embedGenJetMatch_;
00083       edm::InputTag genJetMatchSrc_;
00084       bool          addTauID_;
00085       typedef std::pair<std::string, edm::InputTag> NameTag;
00086       std::vector<NameTag> tauIDSrcs_;
00087 
00088       // tools
00089       GreaterByPt<Tau>       pTTauComparator_;
00090 
00091       pat::helper::MultiIsolator isolator_; 
00092       pat::helper::MultiIsolator::IsolationValuePairs isolatorTmpStorage_; // better here than recreate at each event
00093       std::vector<std::pair<pat::IsolationKeys,edm::InputTag> > isoDepositLabels_;
00094 
00095       bool addEfficiencies_;
00096       pat::helper::EfficiencyLoader efficiencyLoader_;
00097       
00098       bool addResolutions_;
00099       pat::helper::KinResolutionsLoader resolutionLoader_;
00100 
00101       bool useUserData_;
00102       pat::PATUserDataHelper<pat::Tau>      userDataHelper_;
00103 
00104       template <typename TauCollectionType, typename TauDiscrType> float getTauIdDiscriminator(const edm::Handle<TauCollectionType>&, size_t, const edm::Handle<TauDiscrType>&);
00105   };
00106 
00107 }
00108 
00109 #endif