18 MEP me_rollEfficiencyBarrel_eff =
19 booker.
book1D(
"RollEfficiencyBarrel_eff",
"Roll efficiency in Barrel;Efficiency [%]", 50 + 2, -2, 100 + 2);
20 MEP me_rollEfficiencyEndcap_eff =
21 booker.
book1D(
"RollEfficiencyEndcap_eff",
"Roll efficiency in Endcap;Efficiency [%]", 50 + 2, -2, 100 + 2);
22 MEP me_rollEfficiencyStatCutOffBarrel_eff =
23 booker.
book1D(
"RollEfficiencyCutOffBarrel_eff",
24 "Roll efficiency in Barrel without low stat chamber;Efficiency [%]",
28 MEP me_rollEfficiencyStatCutOffEndcap_eff =
29 booker.
book1D(
"RollEfficiencyCutOffEndcap_eff",
30 "Roll efficiency in Endcap without low stat chamber;Efficiency [%]",
35 const double maxNoise = 1
e-7;
36 MEP me_rollNoiseBarrel_noise = booker.
book1D(
"RollNoiseBarrel_noise",
37 "Roll noise in Barrel;Noise level [Event^{-1}cm^{-2}]",
40 maxNoise + maxNoise / 25);
41 MEP me_rollNoiseEndcap_noise = booker.
book1D(
"RollNoiseEndcap_noise",
42 "Roll noise in Endcap;Noise level [Event^{-1}cm^{-2}]",
45 maxNoise + maxNoise / 25);
47 MEP me_matchOccupancyBarrel_detId = getter.
get(subDir_ +
"/Occupancy/MatchOccupancyBarrel_detId");
48 MEP me_matchOccupancyEndcap_detId = getter.
get(subDir_ +
"/Occupancy/MatchOccupancyEndcap_detId");
49 MEP me_refOccupancyBarrel_detId = getter.
get(subDir_ +
"/Occupancy/RefOccupancyBarrel_detId");
50 MEP me_refOccupancyEndcap_detId = getter.
get(subDir_ +
"/Occupancy/RefOccupancyEndcap_detId");
52 if (me_matchOccupancyBarrel_detId and me_refOccupancyBarrel_detId) {
53 TH1 *h_matchOccupancyBarrel_detId = me_matchOccupancyBarrel_detId->
getTH1();
54 TH1 *h_refOccupancyBarrel_detId = me_refOccupancyBarrel_detId->getTH1();
56 for (
int bin = 1, nBin = h_matchOccupancyBarrel_detId->GetNbinsX();
bin <= nBin; ++
bin) {
57 const double nRec = h_matchOccupancyBarrel_detId->GetBinContent(
bin);
58 const double nRef = h_refOccupancyBarrel_detId->GetBinContent(
bin);
60 const double eff = nRef ? nRec / nRef * 100 : -1;
62 me_rollEfficiencyBarrel_eff->
Fill(eff);
64 me_rollEfficiencyStatCutOffBarrel_eff->
Fill(eff);
68 if (me_matchOccupancyEndcap_detId and me_refOccupancyEndcap_detId) {
69 TH1 *h_matchOccupancyEndcap_detId = me_matchOccupancyEndcap_detId->
getTH1();
70 TH1 *h_refOccupancyEndcap_detId = me_refOccupancyEndcap_detId->getTH1();
72 for (
int bin = 1, nBin = h_matchOccupancyEndcap_detId->GetNbinsX();
bin <= nBin; ++
bin) {
73 const double nRec = h_matchOccupancyEndcap_detId->GetBinContent(
bin);
74 const double nRef = h_refOccupancyEndcap_detId->GetBinContent(
bin);
76 const double eff = nRef ? nRec / nRef * 100 : -1;
78 me_rollEfficiencyEndcap_eff->
Fill(eff);
80 me_rollEfficiencyStatCutOffEndcap_eff->
Fill(eff);
84 MEP me_eventCount = getter.
get(subDir_ +
"/Occupancy/EventCount");
85 const double nEvent = me_eventCount ? me_eventCount->
getTH1()->GetBinContent(1) : 1;
86 MEP me_noiseOccupancyBarrel_detId = getter.
get(subDir_ +
"/Occupancy/NoiseOccupancyBarrel_detId");
87 MEP me_rollAreaBarrel_detId = getter.
get(subDir_ +
"/Occupancy/RollAreaBarrel_detId");
88 if (me_noiseOccupancyBarrel_detId and me_rollAreaBarrel_detId) {
89 TH1 *h_noiseOccupancyBarrel_detId = me_noiseOccupancyBarrel_detId->
getTH1();
90 TH1 *h_rollAreaBarrel_detId = me_rollAreaBarrel_detId->getTH1();
92 for (
int bin = 1, nBin = h_noiseOccupancyBarrel_detId->GetNbinsX();
bin <= nBin; ++
bin) {
93 const double noiseCount = h_noiseOccupancyBarrel_detId->GetBinContent(
bin);
94 const double area = h_rollAreaBarrel_detId->GetBinContent(
bin);
95 const double noiseLevel = area > 0 ? noiseCount / area / nEvent : 0;
97 me_rollNoiseBarrel_noise->
Fill(-maxNoise / 50);
99 me_rollNoiseBarrel_noise->
Fill(
std::min(noiseLevel, maxNoise));
103 MEP me_noiseOccupancyEndcap_detId = getter.
get(subDir_ +
"/Occupancy/NoiseOccupancyEndcap_detId");
104 MEP me_rollAreaEndcap_detId = getter.
get(subDir_ +
"/Occupancy/RollAreaEndcap_detId");
105 if (me_noiseOccupancyEndcap_detId and me_rollAreaEndcap_detId) {
106 TH1 *h_noiseOccupancyEndcap_detId = me_noiseOccupancyEndcap_detId->
getTH1();
107 TH1 *h_rollAreaEndcap_detId = me_rollAreaEndcap_detId->getTH1();
109 for (
int bin = 1, nBin = h_noiseOccupancyEndcap_detId->GetNbinsX();
bin <= nBin; ++
bin) {
110 const double noiseCount = h_noiseOccupancyEndcap_detId->GetBinContent(
bin);
111 const double area = h_rollAreaEndcap_detId->GetBinContent(
bin);
112 const double noiseLevel = area > 0 ? noiseCount / area / nEvent : 0;
114 me_rollNoiseEndcap_noise->
Fill(-maxNoise / 50);
116 me_rollNoiseEndcap_noise->
Fill(
std::min(noiseLevel, maxNoise));
T getParameter(std::string const &) const
#define DEFINE_FWK_MODULE(type)
void setCurrentFolder(std::string const &fullpath)
MonitorElement * book1D(Args &&...args)
MonitorElement * get(std::string const &path)
bin
set the eta bin as selection string.
RPCRecHitValidClient(const edm::ParameterSet &pset)
void dqmEndJob(DQMStore::IBooker &booker, DQMStore::IGetter &getter) override