CMS 3D CMS Logo

PFCandidateBenchmarkAnalyzer.cc
Go to the documentation of this file.
2 
7 
10 
13 
14 using namespace reco;
15 using namespace edm;
16 using namespace std;
17 
19  : BenchmarkAnalyzer(parameterSet), PFCandidateBenchmark((Benchmark::Mode)parameterSet.getParameter<int>("mode")) {
20  setRange(parameterSet.getParameter<double>("ptMin"),
21  parameterSet.getParameter<double>("ptMax"),
22  parameterSet.getParameter<double>("etaMin"),
23  parameterSet.getParameter<double>("etaMax"),
24  parameterSet.getParameter<double>("phiMin"),
25  parameterSet.getParameter<double>("phiMax"));
26 
27  myColl_ = consumes<PFCandidateCollection>(inputLabel_);
28 }
29 
31  edm::Run const &iRun,
32  edm::EventSetup const &iSetup) {
33  BenchmarkAnalyzer::bookHistograms(ibooker, iRun, iSetup);
34  setup(ibooker);
35 }
36 
39  iEvent.getByToken(myColl_, collection);
40 
41  fill(*collection);
42 }
T getParameter(std::string const &) const
void fill(const reco::PFCandidateCollection &pfCands)
bool getByToken(EDGetToken token, Handle< PROD > &result) const
Definition: Event.h:525
void bookHistograms(DQMStore::IBooker &, edm::Run const &, edm::EventSetup const &) override
abstract base class
Definition: Benchmark.h:19
void bookHistograms(DQMStore::IBooker &, edm::Run const &, edm::EventSetup const &) override
edm::InputTag inputLabel_
input collection
int iEvent
Definition: GenABIO.cc:224
PFCandidateBenchmarkAnalyzer(const edm::ParameterSet &parameterSet)
edm::EDGetTokenT< reco::PFCandidateCollection > myColl_
void setRange(float ptMin, float ptMax, float etaMin, float etaMax, float phiMin, float phiMax)
Definition: Benchmark.h:41
void setup(DQMStore::IBooker &b)
book histograms
fixed size matrix
HLT enums.
abtract base class for benchmark analyzers
ParameterSet const & parameterSet(Provenance const &provenance)
Definition: Provenance.cc:11
void analyze(const edm::Event &, const edm::EventSetup &) override
Definition: Run.h:45