CMS 3D CMS Logo

 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Pages
CandidateBenchmarkAnalyzer.cc
Go to the documentation of this file.
2 
7 
10 
12 
13 using namespace reco;
14 using namespace edm;
15 using namespace std;
16 
17 
19  BenchmarkAnalyzer(parameterSet),
20  CandidateBenchmark( (Benchmark::Mode) parameterSet.getParameter<int>("mode") )
21 {
22 
23  setRange( parameterSet.getParameter<double>("ptMin"),
24  parameterSet.getParameter<double>("ptMax"),
25  parameterSet.getParameter<double>("etaMin"),
26  parameterSet.getParameter<double>("etaMax"),
27  parameterSet.getParameter<double>("phiMin"),
28  parameterSet.getParameter<double>("phiMax") );
29 
30  myColl_ = consumes< View<Candidate> >(inputLabel_);
31 
32 }
33 
34 
36  edm::Run const & iRun,
37  edm::EventSetup const & iSetup )
38 {
39  BenchmarkAnalyzer::bookHistograms(ibooker, iRun, iSetup);
40  setup(ibooker);
41 }
42 
43 void
45  const edm::EventSetup& iSetup) {
46 
48  iEvent.getByToken(myColl_, collection);
49 
50  fill( *collection );
51 }
52 
T getParameter(std::string const &) const
edm::EDGetTokenT< edm::View< reco::Candidate > > myColl_
To plot Candidate quantities.
bool getByToken(EDGetToken token, Handle< PROD > &result) const
Definition: Event.h:446
abstract base class
Definition: Benchmark.h:22
void bookHistograms(DQMStore::IBooker &, edm::Run const &, edm::EventSetup const &) override
void fill(const C &candidates)
edm::InputTag inputLabel_
input collection
int iEvent
Definition: GenABIO.cc:230
void setRange(float ptMin, float ptMax, float etaMin, float etaMax, float phiMin, float phiMax)
Definition: Benchmark.h:51
CandidateBenchmarkAnalyzer(const edm::ParameterSet &parameterSet)
void bookHistograms(DQMStore::IBooker &, edm::Run const &, edm::EventSetup const &) override
abtract base class for benchmark analyzers
void analyze(const edm::Event &, const edm::EventSetup &)
void setup(DQMStore::IBooker &b)
book histograms
ParameterSet const & parameterSet(Provenance const &provenance)
Definition: Provenance.cc:11
Definition: Run.h:41