Skip to content

Commit

Permalink
mGMT_dqm_v3
Browse files Browse the repository at this point in the history
  • Loading branch information
EsmaeelEskandari committed Jan 24, 2016
1 parent d3ec73f commit 1903f8d
Show file tree
Hide file tree
Showing 7 changed files with 62 additions and 91 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -76,6 +76,9 @@
#process.RawToDigi.remove("siStripDigis")
#process.RawToDigi.remove("scalersRawToDigi")
#process.RawToDigi.remove("castorDigis")
#process.L1TMuonEmulation.remove("emptyCaloCollsProducer")
#process.emptyCaloCollsProducer.InputLabel = cms.InputTag("rawDataCollector")

# for GCT, unpack all five samples
#process.gctDigis.numberOfGctSamplesToUnpack = cms.uint32(5)

Expand Down Expand Up @@ -129,6 +132,8 @@
# remove module(s) or system sequence from l1tMonitorPath
# quality test disabled also
#
#process.l1tMonitorOnline.remove(process.bxTiming)

#process.l1tMonitorOnline.remove(process.bxTiming)
#process.l1tMonitorOnline.remove(process.l1tBPTX)

Expand Down Expand Up @@ -202,7 +207,7 @@
process.siStripDigis.ProductLabel = cms.InputTag("rawDataRepacker")
process.bxTiming.FedSource = cms.untracked.InputTag("rawDataRepacker")
process.l1s.fedRawData = cms.InputTag("rawDataRepacker")

# process.gmtStage2Digis.inputLabel = cms.InputTag("rawDataRepacker")
### process customizations included here
from DQM.Integration.config.online_customizations_cfi import *
process = customise(process)
4 changes: 2 additions & 2 deletions DQM/Integration/python/config/fileinputsource_cfi.py
Original file line number Diff line number Diff line change
Expand Up @@ -2,8 +2,8 @@

source = cms.Source("PoolSource",
fileNames = cms.untracked.vstring(
"file:/afs/cern.ch/user/e/esmaeel/CMSSW_8_0_0_pre4/src/DQM/Integration/python/config/L1T_EDM.root",
# "file:/afs/cern.ch/user/e/esmaeel/CMSSW_8_0_0_pre4/src/DQM/Integration/python/config/l1tMuon_263400.root",
# "file:/afs/cern.ch/user/e/esmaeel/CMSSW_8_0_0_pre4/src/DQM/Integration/python/config/L1T_EDM.root",
"file:/afs/cern.ch/user/e/esmaeel/CMSSW_8_0_0_pre4/src/DQM/Integration/python/config/l1tMuon_263400.root",
# "file:/afs/cern.ch/cms/CAF/CMSCOMM/COMM_DQM/DQMTest/MinimumBias__RAW__v1__165633__1CC420EE-B686-E011-A788-0030487CD6E8.root",
# "/store/data/Commissioning2014/Cosmics/RAW//v3/000/224/380/00000/E05943D1-1227-E411-BB8E-02163E00F0C4.root"
# "/store/data/Commissioning2014/Cosmics/RAW/v3/000/224/380/00000/68FDADE5-1227-E411-8AA6-02163E00A10C.root"
Expand Down
1 change: 0 additions & 1 deletion DQM/L1TMonitor/interface/L1TStage2BMTF.h
Original file line number Diff line number Diff line change
Expand Up @@ -46,7 +46,6 @@ class L1TStage2BMTF: public DQMEDAnalyzer {

// class constructor
L1TStage2BMTF(const edm::ParameterSet & ps);

// class destructor
virtual ~L1TStage2BMTF();

Expand Down
84 changes: 18 additions & 66 deletions DQM/L1TMonitor/interface/L1TStage2mGMT.h
Original file line number Diff line number Diff line change
Expand Up @@ -30,16 +30,17 @@
// stage2 requirements
#include "DataFormats/L1Trigger/interface/BXVector.h"
#include "DataFormats/L1Trigger/interface/Muon.h"
#include "DataFormats/L1TMuon/interface/RegionalMuonCand.h"
//#include "DataFormats/L1TMuon/interface/RegionalMuonCandFwd.h"

// dqm requirements
#include "DQMServices/Core/interface/DQMStore.h"
#include "DQMServices/Core/interface/MonitorElement.h"
#include "DQMServices/Core/interface/DQMEDAnalyzer.h"


// class decleration

class L1TStage2mGMT: public DQMEDAnalyzer {
class L1TStage2mGMT: public DQMEDAnalyzer {

public:

Expand All @@ -58,84 +59,35 @@ virtual ~L1TStage2mGMT();

// data members
private:
// enum ensubs {BMTF, OMTF, EMTF, mGMT};

std::string monitorDir;
edm::InputTag stage2mgmtSource ;
bool verbose ;
edm::EDGetToken stage2mgmtToken ;



MonitorElement* eta_mgmt;
MonitorElement* phi_mgmt;
MonitorElement* pt_mgmt;
MonitorElement* charge_mgmt;
MonitorElement* chargeVal_mgmt;
MonitorElement* qual_mgmt;
MonitorElement* iso_mgmt;

MonitorElement* bx_mgmt;
MonitorElement* etaVSphi_mgmt;
MonitorElement* phiVSpt_mgmt;
MonitorElement* etaVSpt_mgmt;

MonitorElement* etaVSbx_mgmt;
MonitorElement* phiVSbx_mgmt;
MonitorElement* ptVSbx_mgmt;
MonitorElement* chargeVSbx_mgmt;
MonitorElement* chargeValVSbx_mgmt;
MonitorElement* qualVSbx_mgmt;
MonitorElement* isoVSbx_mgmt;

MonitorElement* etaVSphi_mgmt;
MonitorElement* phiVSpt_mgmt;
MonitorElement* etaVSpt_mgmt;


// eta & phi
// MonitorElement* subs_eta[4];
// MonitorElement* subs_phi[4];
// MonitorElement* subs_etaphi[4];
// MonitorElement* subs_etaqty[4];

// MonitorElement* eta_bmtf_omtf_emtf;
// MonitorElement* eta_bmtf;
// MonitorElement* eta_omtf;
// MonitorElement* eta_emtf;
// MonitorElement* phi_bmtf_omtf_emtf;
// MonitorElement* phi_bmtf;
// MonitorElement* phi_omtf;
// MonitorElement* phi_emtf;
// MonitorElement* etaphi_bmtf_omtf_emtf;
/* MonitorElement* etaphi_bmtf; */
/* MonitorElement* etaphi_omtf; */
/* MonitorElement* etaphi_emtf; */
/* MonitorElement* phi_bmtf_omtf; */
/* MonitorElement* phi_bmtf_emtf; */
/* MonitorElement* phi_omtf_emtf; */
/* MonitorElement* eta_bmtf_omtf; */
/* MonitorElement* eta_bmtf_emtf; */
/* MonitorElement* eta_omtf_emtf; */

// MonitorElement* pt_bmtf;
// MonitorElement* pt_omtf;
// MonitorElement* pt_emtf;
// bunch-crossing
// MonitorElement* subs_nbx[4];
// MonitorElement* subs_dbx[3];
// MonitorElement* bx_number;
// MonitorElement* dbx_chip;
// MonitorElement* bx_bmtf_omtf;
// MonitorElement* bx_bmtf_emtf;
// MonitorElement* bx_omtf_emtfc;


// MonitorElement* subs_pt[4];
// MonitorElement* subs_qty[4];
// MonitorElement* subs_bits[4];

// MonitorElement* regional_triggers;

// MonitorElement* n_bmtf_vs_omtf ;
// MonitorElement* n_bmtf_vs_emtf;
// MonitorElement* n_omtf_vs_emtf;


// const edm::EDGetTokenT<MuonBxCollection> mgmtSource_ ;

/* int bxnum_old_; // bx of previous event */
/* int obnum_old_; // orbit of previous event */
/* int trsrc_old_; // code of trigger source ( bits: 0 DT, 1 bRPC, 2 CSC, 3 fRPC ) */

/* static const double piconv_; */
/* double phiconv_(float phi); */
/* void book_(const edm::EventSetup& c); */


};
Expand Down
1 change: 1 addition & 0 deletions DQM/L1TMonitor/python/L1TStage2_cff-esmaeel.py
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,7 @@
from EventFilter.L1TRawToDigi.gmtStage2Digis_cfi import *

l1tStage2online = cms.Sequence(
# l1tStage2OMTF,
# l1tStage2BMTF,
l1tStage2mGMT

Expand Down
54 changes: 33 additions & 21 deletions DQM/L1TMonitor/src/L1TStage2mGMT.cc
Original file line number Diff line number Diff line change
Expand Up @@ -29,20 +29,27 @@ void L1TStage2mGMT::beginLuminosityBlock(const edm::LuminosityBlock& iLumi, cons
void L1TStage2mGMT::bookHistograms(DQMStore::IBooker &ibooker, const edm::Run& iRun, const edm::EventSetup& eveSetup)
{
ibooker.setCurrentFolder(monitorDir);
// eta ,phi, pt
eta_mgmt = ibooker.book1D("eta_mgmt", "#eta of MGMT", 229, -114.5, 114.5);
phi_mgmt = ibooker.book1D("phi_mgmt", "#phi of MGMT", 144, -0.5, 143.5);
pt_mgmt = ibooker.book1D("pt_mgmt", "p_{T} of MGMT", 300, 0, 300);
bx_mgmt = ibooker.book1D("pt_mgmt", "BX", 2048, -0.5, 2047.5);
etaVSphi_mgmt = ibooker.book2D("etaVSphi_mgmt", "#eta VS #phi of MGMT", 229, -114.5, 114.5, 144, -0.5, 143.5);
phiVSpt_mgmt = ibooker.book2D("phiVSpt_mgmt", "#phi VS p_{T}of MGMT", 144, -0.5, 143.5, 300, 0, 300);
etaVSpt_mgmt = ibooker.book2D("etaVSpt_mgmt", "#eta VS p_{T} of MGMT", 229, -114.5, 114.5,300, 0, 300);
etaVSbx_mgmt = ibooker.book2D("etaVSbx_mgmt", "#eta of MGMT VS bx", 229, -114.5, 114.5, 2048, -0.5, 2047.5);
phiVSbx_mgmt = ibooker.book2D("phiVSbx_mgmt", "#phi of MGMT VS bx", 144, -0.5, 143.5, 2048, -0.5, 2047.5);
ptVSbx_mgmt = ibooker.book2D("ptVSbx_mgmt", "#p_{T} of MGMT VS bx", 300, 0, 300 , 2048, -0.5, 2047.5);



eta_mgmt = ibooker.book1D("eta_mgmt", "#eta of mGMT Muon", 462, -230, 232);
phi_mgmt = ibooker.book1D("phi_mgmt", "#phi of mGMT Muon", 580, 0, 580);
pt_mgmt = ibooker.book1D("pt_mgmt", "p_{T} of mGMT Muon", 300, 0, 300);
charge_mgmt = ibooker.book1D("charge_mgmt", "charge of mGMT Muon", 3, -1, 2);
chargeVal_mgmt = ibooker.book1D("chargeValid_mgmt", "chargeValid of mGMT Muon", 2, 0, 2);
qual_mgmt = ibooker.book1D("quality_mgmt", "quality of mGMT Muon", 16, 0, 16);
iso_mgmt = ibooker.book1D("iso_mgmt", "iso of mGMT Muon", 4, 0, 4);

bx_mgmt = ibooker.book1D("bx", "BX", 15, -7, 8);

etaVSphi_mgmt = ibooker.book2D("etaVSphi_mgmt" , "#eta VS #phi of mGMT Muon" , 229, -114.5, 114.5, 144, -0.5, 143.5);
phiVSpt_mgmt = ibooker.book2D("phiVSpt_mgmt" , "#phi VS p_{T}of mGMT Muon" , 144, -0.5, 143.5, 300, 0, 300);
etaVSpt_mgmt = ibooker.book2D("etaVSpt_mgmt" , "#eta VS p_{T} of mGMT Muon" , 229, -114.5, 114.5, 300, 0, 300);
etaVSbx_mgmt = ibooker.book2D("etaVSbx_mgmt" , "#eta of mGMT Muon VS bx" , 229, -114.5, 114.5, 15, -7, 8);
phiVSbx_mgmt = ibooker.book2D("phiVSbx_mgmt" , "#phi of mGMT Muon VS bx" , 144, -0.5, 143.5, 15, -7, 8);
ptVSbx_mgmt = ibooker.book2D("ptVSbx_mgmt" , "#p_{T} of mGMT Muon VS bx" , 150, 0, 300, 15, -7, 8);
chargeVSbx_mgmt = ibooker.book2D("chargeVSbx_mgmt" , "charge of mGMT Muon VS bx" , 3 , -1, 2, 15, -7, 8);
chargeValVSbx_mgmt = ibooker.book2D("chargeValidVSbx_mgmt", "chargeValid of mGMT Muon VS bx", 2 , 0, 2, 15, -7, 8);
qualVSbx_mgmt = ibooker.book2D("qualVSbx_mgmt" , "quality of mGMT Muon VS bx" , 16 , 0, 16, 15, -7, 8);
isoVSbx_mgmt = ibooker.book2D("isoVSbx_mgmt" , "iso of mGMT MuonVS bx" , 4 , 0, 4, 15, -7, 8);

}

Expand All @@ -60,27 +67,32 @@ void L1TStage2mGMT::analyze(const edm::Event & eve, const edm::EventSetup & eveS
for(int itBX=Muon->getFirstBX(); itBX<=Muon->getLastBX(); ++itBX)
{
for(l1t::MuonBxCollection::const_iterator itMuon = Muon->begin(itBX); itMuon != Muon->end(itBX); ++itMuon)
// for(l1t::MuonBxCollection::const_iterator itMuon = Muon->begin(); itMuon != Muon->end(); ++itMuon)
{

eta_mgmt->Fill(itMuon->hwEta());
phi_mgmt->Fill(itMuon->hwPhi());
pt_mgmt->Fill(itMuon->hwPt());
charge_mgmt->Fill(itMuon->hwCharge());
chargeVal_mgmt->Fill(itMuon->hwChargeValid());
qual_mgmt->Fill(itMuon->hwQual());
iso_mgmt->Fill(itMuon->hwIso());
bx_mgmt->Fill(itBX);

etaVSphi_mgmt->Fill(itMuon->hwEta(),itMuon->hwPhi());
phiVSpt_mgmt->Fill(itMuon->hwPhi(),itMuon->hwPt());
etaVSpt_mgmt->Fill(itMuon->hwEta(),itMuon->hwPt());

etaVSbx_mgmt->Fill(itMuon->hwEta(),itBX);
phiVSbx_mgmt->Fill(itMuon->hwPhi(),itBX);
ptVSbx_mgmt->Fill(itMuon->hwPt() ,itBX);
chargeVSbx_mgmt->Fill(itMuon->hwCharge(), itBX);
chargeValVSbx_mgmt->Fill(itMuon->hwChargeValid(), itBX);
qualVSbx_mgmt->Fill(itMuon->hwQual(), itBX);
isoVSbx_mgmt->Fill(itMuon->hwIso(), itBX);

etaVSphi_mgmt->Fill(itMuon->hwEta(),itMuon->hwPhi());
phiVSpt_mgmt->Fill(itMuon->hwPhi(),itMuon->hwPt());
etaVSpt_mgmt->Fill(itMuon->hwEta(),itMuon->hwPt());


}
}
}





2 changes: 2 additions & 0 deletions DQM/L1TMonitor/src/SealModule.cc
Original file line number Diff line number Diff line change
Expand Up @@ -33,6 +33,8 @@ DEFINE_FWK_MODULE(L1TStage2mGMT);
#include <DQM/L1TMonitor/interface/L1TStage2BMTF.h>
DEFINE_FWK_MODULE(L1TStage2BMTF);

//#include <DQM/L1TMonitor/interface/L1TStage2OMTF.h>
//DEFINE_FWK_MODULE(L1TStage2OMTF);

#include <DQM/L1TMonitor/interface/L1TGCT.h>
DEFINE_FWK_MODULE(L1TGCT);
Expand Down

0 comments on commit 1903f8d

Please sign in to comment.