33 virtual void endJob()
override ;
59 , eOverPMax_ (iConfig.getParameter<double>(
"eOverPMax") )
60 , debug_ ( iConfig.getParameter<bool>(
"debug") )
61 , taggingMode_ (iConfig.getParameter<bool>(
"taggingMode") )
64 produces<reco::PFCandidateCollection>(
"muons");
91 bool foundMuon =
false;
93 auto_ptr< reco::PFCandidateCollection >
108 double eOverP = totalCaloEnergy/cand.
p();
115 pOutputCandidateCollection->push_back( cand );
118 cout<<cand<<
" HCAL E="<<endl;
121 cout<<
"\t"<<
"E/p "<<eOverP<<endl;
125 iEvent.
put( pOutputCandidateCollection,
"muons" );
127 bool pass = !foundMuon;
129 iEvent.
put( std::auto_ptr<bool>(
new bool(pass)) );
static bool isIsolatedMuon(const reco::PFBlockElement &elt)
virtual double p() const
magnitude of momentum vector
double rawEcalEnergy() const
return corrected Ecal energy
bool getByToken(EDGetToken token, Handle< PROD > &result) const
#define DEFINE_FWK_MODULE(type)
std::vector< PFCandidatePtr > pfCandidates(const PFJet &jet, int particleId, bool sort=true)
~GreedyMuonPFCandidateFilter()
virtual void endJob() override
virtual void beginJob() override
const edm::EDGetTokenT< reco::PFCandidateCollection > tokenPFCandidates_
OrphanHandle< PROD > put(std::auto_ptr< PROD > product)
Put a new product.
virtual bool filter(edm::Event &, const edm::EventSetup &) override
reco::MuonRef muonRef() const
std::vector< reco::PFCandidate > PFCandidateCollection
collection of PFCandidates
GreedyMuonPFCandidateFilter(const edm::ParameterSet &)
Particle reconstructed by the particle flow algorithm.
virtual ParticleType particleId() const
double rawHcalEnergy() const
return raw Hcal energy