Skip to content

Commit

Permalink
Changed y-axis label. Cented x-axis BX label at BX=0. Changed to 24 b…
Browse files Browse the repository at this point in the history
…ins instead of 48 for gemVFATBXPerChamber. Indexed gemChamberVFATBX into different plots by BX#.

Changed y-axis label. Cented x-axis BX label at BX=0. Changed to 24 bins instead of 48.

Changed y-axis label. Cented x-axis BX label at BX=0. Changed to 24 bins instead of 48.
  • Loading branch information
nickh2000 committed Jul 21, 2022
1 parent b60cd8c commit 57a5282
Show file tree
Hide file tree
Showing 2 changed files with 44 additions and 15 deletions.
6 changes: 3 additions & 3 deletions DQM/L1TMonitor/interface/L1TStage2EMTF.h
Expand Up @@ -106,9 +106,9 @@ class L1TStage2EMTF : public DQMOneEDAnalyzer<> {
MonitorElement* gemHitVScscLCTTheta[2];
MonitorElement* gemHitVScscLCTBX[2];

// GEM plots added June 01 2022
MonitorElement* gemBXVFATPerChamber[36][2][2];
MonitorElement* gemChamberVFATBX[2];
// GEM plots added July 21 2022
MonitorElement* gemVFATBXPerChamber[36][2][2];
MonitorElement* gemChamberVFATBX[2][7];
};

#endif
53 changes: 41 additions & 12 deletions DQM/L1TMonitor/src/L1TStage2EMTF.cc
Expand Up @@ -365,20 +365,49 @@ void L1TStage2EMTF::bookHistograms(DQMStore::IBooker& ibooker, const edm::Run&,
gemChamberPad[hist]->setBinLabel(bin, std::to_string(bin), 1);
gemChamberPartition[hist]->setBinLabel(bin, std::to_string(bin), 1);
}
//Added 06-01-22 **
//Added 07-21-22 **
for (int ch = 0; ch < 36; ch++){
for (int lyr = 0; lyr < 2; lyr++){
gemBXVFATPerChamber[ch][hist][lyr] = ibooker.book2D("gemBXVFATPerChamber_" + std::to_string(ch) + "_" + std::to_string(hist) + "_" + std::to_string(lyr + 1), "GEM BX vs VFAT in Chamber " + std::to_string(ch+1) + " " + label + " Layer " + std::to_string(lyr + 1), 7, -3, 4, 48, 0, 48);
gemBXVFATPerChamber[ch][hist][lyr]->setAxisTitle("BX", 1);
gemBXVFATPerChamber[ch][hist][lyr]->setAxisTitle("8*phi + eta, " + label, 2);
gemVFATBXPerChamber[ch][hist][lyr] = ibooker.book2D("gemVFATBXPerChamber_" + std::to_string(ch) + "_" + std::to_string(hist) + "_" + std::to_string(lyr + 1), "GEM BX vs VFAT in Chamber " + std::to_string(ch+1) + " " + label + " Layer " + std::to_string(lyr + 1), 7, -3, 4, 24, 0, 24);
gemVFATBXPerChamber[ch][hist][lyr]->setAxisTitle("BX", 1);
gemVFATBXPerChamber[ch][hist][lyr]->setAxisTitle("VFAT #", 2);

for (int bin = 1; bin <= 48; ++bin) {
gemBXVFATPerChamber[ch][hist][lyr]->setBinLabel(bin, std::to_string(bin-1), 2);
for (int bin = 1; bin <= 24; ++bin) {
gemVFATBXPerChamber[ch][hist][lyr]->setBinLabel(bin, std::to_string(bin-1), 2);
}
for (int bx = 1; bx <= 7; ++bx) {
gemVFATBXPerChamber[ch][hist][lyr]->setBinLabel(bx, std::to_string(bx - 4), 1);
}
}
}
gemChamberVFATBX[hist] = ibooker.book2D("gemChamberVFATBX" + name, "GEM Chamber vs VFAT * BX" + label, 42, 1, 43, 210, 0, 210); // 8* (0-2) phi part + (0-7) eta part
gemChamberVFATBX[hist]->setAxisTitle("Chamber, " + label, 1);


//changed gemChamberVFATBX to be indexed by BX 07-21-2022
string bx_string;
for (int bx = 1; bx <= 7; ++bx) {

//Assign (m)inus or (p)us to plot name
if (bx < 4) bx_string = "Neg" + std::to_string(-1*(bx - 4));
else if (bx > 4) bx_string = "Pos" + std::to_string(bx - 4);
else bx_string = "0";

gemChamberVFATBX[hist][bx - 1] = ibooker.book2D("gemChamberVFATBX" + bx_string + name, "GEM Chamber vs VFAT at BX = " + std::to_string(bx - 4) + ", " + label, 42, 1, 43, 24, 0, 24); // 8* (0-2) phi part + (0-7) eta part
gemChamberVFATBX[hist][bx - 1]->setAxisTitle("Chamber, " + label, 1);
gemChamberVFATBX[hist][bx - 1]->setAxisTitle("VFAT #", 2);

for (int bin = 1; bin <= 24; bin ++) gemChamberVFATBX[hist][bx - 1]->setBinLabel(bin, std::to_string(bin - 1), 2);

int count = 0;
for (int bin = 1; bin <= 42; ++bin) {
gemChamberVFATBX[hist][bx - 1]->setBinLabel(bin, std::to_string(bin - count), 1);
if (bin == 2 || bin == 9 || bin == 16 || bin == 23 || bin == 30 || bin == 37) {
++bin;
++count;
gemChamberVFATBX[hist][bx - 1]->setBinLabel(bin, "N", 1);
}
}
}

}
// CSC LCT and RPC Hit Timing
ibooker.setCurrentFolder(monitorDir + "/Timing");
Expand Down Expand Up @@ -917,10 +946,10 @@ void L1TStage2EMTF::analyze(const edm::Event& e, const edm::EventSetup& c) {
gemChamberPad[hist_index]->Fill(chamber, Hit->Pad());
gemChamberPartition[hist_index]->Fill(chamber, Hit->Partition());
gemHitOccupancy->Fill(chamber_bin(1, 1, chamber), (endcap > 0) ? 1.5 : 0.5); // follow CSC convention
//Added plots 06-01-22 ***
gemBXVFATPerChamber[chamber-1][hist_index][layer]->Fill(Hit->BX(), vfat);
//changed from thisv2_chamber_bin
gemChamberVFATBX[hist_index]->Fill( chamber_bin(1, 1, chamber), (Hit->BX() + 3) * 30 + vfat);
//Added plots 07-21-22 ***
gemVFATBXPerChamber[chamber-1][hist_index][layer]->Fill(Hit->BX(), vfat);
//indexed plots by BX 07-21-22
gemChamberVFATBX[hist_index][Hit->BX() + 3]->Fill( chamber_bin(1, 1, chamber), vfat);
}
//Added plots 06-07-22

Expand Down

0 comments on commit 57a5282

Please sign in to comment.