Back to home page

Project CMSSW displayed by LXR

 
 

    


File indexing completed on 2024-04-06 12:27:34

0001 #ifndef RECOPARTICLEFLOW_PFISOREADER_H
0002 #define RECOPARTICLEFLOW_PFISOREADER_H
0003 #include "FWCore/Framework/interface/one/EDAnalyzer.h"
0004 #include "FWCore/Framework/interface/Frameworkfwd.h"
0005 #include "DataFormats/Common/interface/ValueMap.h"
0006 #include "DataFormats/EgammaCandidates/interface/Photon.h"
0007 #include "DataFormats/ParticleFlowCandidate/interface/PFCandidateFwd.h"
0008 #include "DataFormats/ParticleFlowCandidate/interface/PFCandidate.h"
0009 #include "DataFormats/RecoCandidate/interface/IsoDeposit.h"
0010 #include <iostream>
0011 #include <string>
0012 #include <map>
0013 
0014 class PFIsoReader : public edm::one::EDAnalyzer<> {
0015 public:
0016   explicit PFIsoReader(const edm::ParameterSet&);
0017   ~PFIsoReader() override = default;
0018 
0019   void analyze(const edm::Event& iEvent, const edm::EventSetup& c) override;
0020 
0021 private:
0022   typedef std::vector<edm::Handle<edm::ValueMap<reco::IsoDeposit> > > IsoDepositMaps;
0023   void printIsoDeposits(const IsoDepositMaps& depmap, const reco::PFCandidatePtr& ptr) const;
0024 
0025   const edm::InputTag inputTagGsfElectrons_;
0026   const edm::InputTag inputTagPhotons_;
0027   const edm::InputTag inputTagPFCandidates_;
0028   const edm::InputTag inputTagValueMapPhotons_;
0029   const edm::InputTag inputTagValueMapElectrons_;
0030   const edm::InputTag inputTagValueMapMerged_;
0031   const std::vector<edm::InputTag> inputTagElectronIsoDeposits_;
0032   const std::vector<edm::InputTag> inputTagPhotonIsoDeposits_;
0033   const bool useValueMaps_;
0034 
0035   const edm::EDGetTokenT<reco::PFCandidateCollection> pfCandToken_;
0036   const edm::EDGetTokenT<reco::GsfElectronCollection> elecToken_;
0037   const edm::EDGetTokenT<reco::PhotonCollection> photonToken_;
0038   const edm::EDGetTokenT<edm::ValueMap<reco::PFCandidatePtr> > elecMapToken_;
0039   const edm::EDGetTokenT<edm::ValueMap<reco::PFCandidatePtr> > photonMapToken_;
0040   const edm::EDGetTokenT<edm::ValueMap<reco::PFCandidatePtr> > mergeMapToken_;
0041   std::vector<edm::EDGetTokenT<edm::Handle<edm::ValueMap<reco::IsoDeposit> > > > isoElecToken_;
0042   std::vector<edm::EDGetTokenT<edm::Handle<edm::ValueMap<reco::IsoDeposit> > > > isoPhotToken_;
0043 };
0044 #endif