1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
|
#ifndef EFFICIENCYANALYZER_H
#define EFFICIENCYANALYZER_H
/** Class EfficiencyAnalyzer
*
* DQM monitoring for dimuon mass
*
* Author: S.Folgueras, A. Calderon
*/
/* Base Class Headers */
#include <memory>
#include <fstream>
#include "FWCore/Framework/interface/Frameworkfwd.h"
#include "FWCore/Framework/interface/Event.h"
#include "FWCore/Framework/interface/MakerMacros.h"
#include "FWCore/ParameterSet/interface/ParameterSet.h"
#include "FWCore/Utilities/interface/InputTag.h"
#include "FWCore/ServiceRegistry/interface/Service.h"
#include "DQMServices/Core/interface/DQMStore.h"
#include "DQMServices/Core/interface/DQMEDAnalyzer.h"
#include "DataFormats/MuonReco/interface/Muon.h"
#include "DataFormats/MuonReco/interface/MuonFwd.h"
#include "DataFormats/BeamSpot/interface/BeamSpot.h"
#include "DataFormats/VertexReco/interface/Vertex.h"
#include "DataFormats/VertexReco/interface/VertexFwd.h"
#include "DataFormats/TrackReco/interface/Track.h"
#include "DataFormats/TrajectorySeed/interface/TrajectorySeedCollection.h"
class EfficiencyAnalyzer : public DQMEDAnalyzer {
public:
/* Constructor */
EfficiencyAnalyzer(const edm::ParameterSet& pset);
/* Destructor */
~EfficiencyAnalyzer() override;
/* Operations */
void analyze(const edm::Event& event, const edm::EventSetup& eventSetup) override;
void bookHistograms(DQMStore::IBooker&, edm::Run const&, edm::EventSetup const&) override;
private:
edm::ParameterSet parameters;
// Switch for verbosity
std::string metname;
//histo binning parameters
int etaBin_;
int phiBin_;
int ptBin_;
double ptMin_;
double ptMax_;
double etaMin_;
double etaMax_;
double phiMin_;
double phiMax_;
int vtxBin_;
double vtxMin_;
double vtxMax_;
std::string ID_;
MonitorElement* h_passProbes_ID_pt;
MonitorElement* h_passProbes_ID_inner_pt;
MonitorElement* h_passProbes_ID_inner_eta;
MonitorElement* h_passProbes_ID_inner_phi;
MonitorElement* h_passProbes_ID_EB_pt;
MonitorElement* h_passProbes_ID_EE_pt;
MonitorElement* h_passProbes_ID_eta;
MonitorElement* h_passProbes_ID_hp_eta;
MonitorElement* h_passProbes_ID_phi;
MonitorElement* h_passProbes_detIsoID_pt;
MonitorElement* h_passProbes_EB_detIsoID_pt;
MonitorElement* h_passProbes_EE_detIsoID_pt;
MonitorElement* h_passProbes_pfIsoID_pt;
MonitorElement* h_passProbes_EB_pfIsoID_pt;
MonitorElement* h_passProbes_EE_pfIsoID_pt;
MonitorElement* h_passProbes_detIsoID_nVtx;
MonitorElement* h_passProbes_pfIsoID_nVtx;
MonitorElement* h_passProbes_EB_detIsoID_nVtx;
MonitorElement* h_passProbes_EE_detIsoID_nVtx;
MonitorElement* h_passProbes_EB_pfIsoID_nVtx;
MonitorElement* h_passProbes_EE_pfIsoID_nVtx;
MonitorElement* h_failProbes_ID_pt;
MonitorElement* h_failProbes_ID_eta;
MonitorElement* h_failProbes_ID_phi;
MonitorElement* h_allProbes_pt;
MonitorElement* h_allProbes_EB_pt;
MonitorElement* h_allProbes_EE_pt;
MonitorElement* h_allProbes_eta;
MonitorElement* h_allProbes_hp_eta;
MonitorElement* h_allProbes_phi;
MonitorElement* h_allProbes_ID_pt;
MonitorElement* h_allProbes_inner_pt;
MonitorElement* h_allProbes_inner_eta;
MonitorElement* h_allProbes_inner_phi;
MonitorElement* h_allProbes_EB_ID_pt;
MonitorElement* h_allProbes_EE_ID_pt;
MonitorElement* h_allProbes_ID_nVtx;
MonitorElement* h_allProbes_EB_ID_nVtx;
MonitorElement* h_allProbes_EE_ID_nVtx;
// Apply deltaBeta PU corrections to the PF isolation eficiencies.
MonitorElement* h_passProbes_pfIsodBID_pt;
MonitorElement* h_passProbes_EB_pfIsodBID_pt;
MonitorElement* h_passProbes_EE_pfIsodBID_pt;
MonitorElement* h_passProbes_pfIsodBID_nVtx;
MonitorElement* h_passProbes_EB_pfIsodBID_nVtx;
MonitorElement* h_passProbes_EE_pfIsodBID_nVtx;
int _numPV;
// STA Label
edm::EDGetTokenT<edm::View<reco::Muon> > theMuonCollectionLabel_;
edm::EDGetTokenT<reco::TrackCollection> theTrackCollectionLabel_;
//Vertex requirements
bool doPVCheck_;
edm::EDGetTokenT<reco::VertexCollection> theVertexLabel_;
edm::EDGetTokenT<reco::BeamSpot> theBeamSpotLabel_;
std::string theFolder;
};
#endif
|