Created
July 19, 2011 14:44
-
-
Save brynmathias/1092594 to your computer and use it in GitHub Desktop.
l1RecoJet.cc Snippet
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
void L1Analysis::L1AnalysisRecoJet::SetCaloJet(const edm::Event& event, | |
const edm::EventSetup& setup, | |
edm::Handle<reco::CaloJetCollection> caloJets, | |
edm::Handle<edm::ValueMap<reco::JetID> > jetsID, | |
const JetCorrector* caloJetCorrector, | |
unsigned maxJet) | |
{ | |
recoJet_.nJets=0; | |
for(reco::CaloJetCollection::const_iterator it=caloJets->begin(); | |
it!=caloJets->end() && recoJet_.nJets < maxJet; | |
++it) { | |
edm::RefToBase<reco::Jet> jetRef(edm::Ref<reco::CaloJetCollection>(caloJets,recoJet_.nJets)); | |
double scale = caloJetCorrector->correction(*it,jetRef,event,setup); | |
.......... | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment