CMS 3D CMS Logo

L1TGMTClient Class Reference

#include <DQM/L1TMonitorClient/interface/L1TGMTClient.h>

Inheritance diagram for L1TGMTClient:

edm::EDAnalyzer

List of all members.

Public Member Functions

 L1TGMTClient (const edm::ParameterSet &ps)
 Constructor.
virtual ~L1TGMTClient ()
 Destructor.

Protected Member Functions

void analyze (const edm::Event &e, const edm::EventSetup &c)
 Fake Analyze.
void beginJob (const edm::EventSetup &c)
 BeginJob.
void beginLuminosityBlock (const edm::LuminosityBlock &lumiSeg, const edm::EventSetup &context)
void beginRun (const edm::Run &r, const edm::EventSetup &c)
 BeginRun.
void endJob ()
 Endjob.
void endLuminosityBlock (const edm::LuminosityBlock &lumiSeg, const edm::EventSetup &c)
 DQM Client Diagnostic.
void endRun (const edm::Run &r, const edm::EventSetup &c)
 EndRun.

Private Member Functions

MonitorElementbookClone1D (std::string name, std::string title, std::string hrefName)
MonitorElementbookClone1DVB (std::string name, std::string title, std::string hrefName)
MonitorElementbookClone2D (std::string name, std::string title, std::string hrefName)
TH1F * get1DHisto (std::string meName, DQMStore *dbi)
TH2F * get2DHisto (std::string meName, DQMStore *dbi)
void initialize ()
void makeEfficiency1D (MonitorElement *meeff, std::string heName, std::string hiName)
void makeEfficiency2D (MonitorElement *meeff, std::string heName, std::string hiName)
void makeRatio1D (MonitorElement *mer, std::string h1Name, std::string h2Name)
void process ()

Private Attributes

int counterEvt_
 counter
int counterLS_
DQMStoredbe_
MonitorElementeff_eta_dtcsc
 prescale on number of events
MonitorElementeff_eta_rpc
MonitorElementeff_etaphi_dtcsc
MonitorElementeff_etaphi_rpc
MonitorElementeff_phi_dtcsc
MonitorElementeff_phi_rpc
std::string input_dir_
std::string monitorName_
std::string output_dir_
edm::ParameterSet parameters_
int prescaleEvt_
 units of lumi sections
int prescaleLS_
 counter
MonitorElementratio_csc_rpcf_lumi
MonitorElementratio_dt_rpcb_lumi


Detailed Description

Definition at line 10 of file L1TGMTClient.h.


Constructor & Destructor Documentation

L1TGMTClient::L1TGMTClient ( const edm::ParameterSet ps  ) 

Constructor.

Definition at line 14 of file L1TGMTClient.cc.

References initialize(), and parameters_.

00015 {
00016   parameters_=ps;
00017   initialize();
00018 }

L1TGMTClient::~L1TGMTClient (  )  [virtual]

Destructor.

Definition at line 20 of file L1TGMTClient.cc.

00020                            {
00021   LogInfo("TriggerDQM")<<"[TriggerDQM]: ending... ";
00022 }


Member Function Documentation

void L1TGMTClient::analyze ( const edm::Event e,
const edm::EventSetup c 
) [protected, virtual]

Fake Analyze.

Implements edm::EDAnalyzer.

Definition at line 114 of file L1TGMTClient.cc.

References counterEvt_, prescaleEvt_, and process().

00114                                                                    {
00115    counterEvt_++;
00116    if (prescaleEvt_<1) return;
00117    if (prescaleEvt_>0 && counterEvt_%prescaleEvt_ != 0) return;
00118    process();
00119 }

void L1TGMTClient::beginJob ( const edm::EventSetup c  )  [protected, virtual]

BeginJob.

Reimplemented from edm::EDAnalyzer.

Definition at line 51 of file L1TGMTClient.cc.

References bookClone1D(), bookClone1DVB(), bookClone2D(), dbe_, eff_eta_dtcsc, eff_eta_rpc, eff_etaphi_dtcsc, eff_etaphi_rpc, eff_phi_dtcsc, eff_phi_rpc, MonitorElement::getTH1F(), MonitorElement::getTH2F(), output_dir_, ratio_csc_rpcf_lumi, ratio_dt_rpcb_lumi, MonitorElement::setAxisTitle(), and DQMStore::setCurrentFolder().

00051                                                     {
00052 
00053   LogInfo("TriggerDQM")<<"[TriggerDQM]: Begin Job";
00054 
00055   // get backendinterface
00056   dbe_ = Service<DQMStore>().operator->();  
00057 
00058   dbe_->setCurrentFolder(output_dir_);
00059 
00060   // booking
00061   eff_eta_dtcsc = bookClone1DVB("eff_eta_dtcsc","efficiency DTCSC vs eta","eta_DTCSC_and_RPC");
00062   eff_eta_dtcsc->setAxisTitle("eta",1);
00063   eff_eta_dtcsc->getTH1F()->Sumw2();
00064   
00065   eff_eta_rpc   = bookClone1DVB("eff_eta_rpc","efficiency RPC vs eta","eta_DTCSC_and_RPC");
00066   eff_eta_rpc->setAxisTitle("eta",1);
00067   eff_eta_rpc->getTH1F()->Sumw2();
00068 
00069   
00070   eff_phi_dtcsc = bookClone1D("eff_phi_dtcsc","efficiency DTCSC vs phi","phi_DTCSC_and_RPC");
00071   eff_phi_dtcsc->setAxisTitle("phi (deg)",1);
00072   eff_phi_dtcsc->getTH1F()->Sumw2();
00073   
00074   eff_phi_rpc   = bookClone1D("eff_phi_rpc","efficiency RPC vs phi","phi_DTCSC_and_RPC");
00075   eff_phi_rpc->setAxisTitle("phi (deg)",1);
00076   eff_phi_rpc->getTH1F()->Sumw2();
00077   
00078   
00079   eff_etaphi_dtcsc = bookClone2D("eff_etaphi_dtcsc","efficiency DTCSC vs eta and phi","etaphi_DTCSC_and_RPC");
00080   eff_etaphi_dtcsc->setAxisTitle("eta",1);
00081   eff_etaphi_dtcsc->setAxisTitle("phi (deg)",2);
00082   eff_etaphi_dtcsc->getTH2F()->Sumw2();
00083   
00084   eff_etaphi_rpc   = bookClone2D("eff_etaphi_rpc","efficiency RPC vs eta and phi","etaphi_DTCSC_and_RPC");
00085   eff_etaphi_rpc->setAxisTitle("eta",1);
00086   eff_etaphi_rpc->setAxisTitle("phi (deg)",2);
00087   eff_etaphi_rpc->getTH2F()->Sumw2();
00088   
00089   ratio_dt_rpcb_lumi  = bookClone1D("ratio_dt_rpcb_lumi" ,"ratio candidates DT/RPCb per lumisegment","DTTF_candlumi");
00090   ratio_csc_rpcf_lumi = bookClone1D("ratio_csc_rpcf_lumi","ratio candidates CSC/RPCf per lumisegment","DTTF_candlumi");
00091 }

void L1TGMTClient::beginLuminosityBlock ( const edm::LuminosityBlock lumiSeg,
const edm::EventSetup context 
) [protected, virtual]

Reimplemented from edm::EDAnalyzer.

Definition at line 98 of file L1TGMTClient.cc.

00098                                                                                                  {
00099    // optionally reset histograms here
00100    // clientHisto->Reset();
00101 }

void L1TGMTClient::beginRun ( const edm::Run r,
const edm::EventSetup c 
) [protected, virtual]

BeginRun.

Reimplemented from edm::EDAnalyzer.

Definition at line 94 of file L1TGMTClient.cc.

00094                                                                    {
00095 }

MonitorElement* L1TGMTClient::bookClone1D ( std::string  name,
std::string  title,
std::string  hrefName 
) [private]

Referenced by beginJob().

MonitorElement* L1TGMTClient::bookClone1DVB ( std::string  name,
std::string  title,
std::string  hrefName 
) [private]

Referenced by beginJob().

MonitorElement* L1TGMTClient::bookClone2D ( std::string  name,
std::string  title,
std::string  hrefName 
) [private]

Referenced by beginJob().

void L1TGMTClient::endJob ( void   )  [protected, virtual]

Endjob.

Reimplemented from edm::EDAnalyzer.

Definition at line 145 of file L1TGMTClient.cc.

00145                          {
00146 }

void L1TGMTClient::endLuminosityBlock ( const edm::LuminosityBlock lumiSeg,
const edm::EventSetup c 
) [protected, virtual]

DQM Client Diagnostic.

Reimplemented from edm::EDAnalyzer.

Definition at line 104 of file L1TGMTClient.cc.

References counterLS_, prescaleLS_, and process().

00105                                                  {
00106   counterLS_++;
00107   if (prescaleLS_<1) return;
00108   if (prescaleLS_>0 && counterLS_%prescaleLS_ != 0) return;
00109 //  cout << "L1TGMTClient::endLumi" << endl;
00110 
00111   process();
00112 }             

void L1TGMTClient::endRun ( const edm::Run r,
const edm::EventSetup c 
) [protected, virtual]

EndRun.

Reimplemented from edm::EDAnalyzer.

Definition at line 140 of file L1TGMTClient.cc.

References process().

00140                                                                 {
00141   process();
00142 }

TH1F* L1TGMTClient::get1DHisto ( std::string  meName,
DQMStore dbi 
) [private]

TH2F* L1TGMTClient::get2DHisto ( std::string  meName,
DQMStore dbi 
) [private]

void L1TGMTClient::initialize (  )  [private]

Definition at line 25 of file L1TGMTClient.cc.

References counterEvt_, counterLS_, GenMuonPlsPt100GeV_cfg::cout, dbe_, lat::endl(), edm::ParameterSet::getUntrackedParameter(), input_dir_, monitorName_, output_dir_, parameters_, prescaleEvt_, and prescaleLS_.

Referenced by L1TGMTClient().

00025                              { 
00026 
00027   counterLS_=0; 
00028   counterEvt_=0; 
00029   
00030   // get back-end interface
00031   dbe_ = Service<DQMStore>().operator->();
00032   
00033   // base folder for the contents of this job
00034   monitorName_ = parameters_.getUntrackedParameter<string>("monitorName","");
00035   cout << "Monitor name = " << monitorName_ << endl;
00036   prescaleLS_ = parameters_.getUntrackedParameter<int>("prescaleLS", -1);
00037   cout << "DQM lumi section prescale = " << prescaleLS_ << " lumi section(s)"<< endl;
00038   prescaleEvt_ = parameters_.getUntrackedParameter<int>("prescaleEvt", -1);
00039   cout << "DQM event prescale = " << prescaleEvt_ << " events(s)"<< endl;
00040   output_dir_ = parameters_.getUntrackedParameter<string>("output_dir","");
00041   cout << "DQM output dir = " << output_dir_ << endl;
00042   input_dir_ = parameters_.getUntrackedParameter<string>("input_dir","");
00043   cout << "DQM input dir = " << input_dir_ << endl;
00044   
00045   LogInfo( "TriggerDQM");
00046 
00047       
00048 }

void L1TGMTClient::makeEfficiency1D ( MonitorElement meeff,
std::string  heName,
std::string  hiName 
) [private]

Referenced by process().

void L1TGMTClient::makeEfficiency2D ( MonitorElement meeff,
std::string  heName,
std::string  hiName 
) [private]

Referenced by process().

void L1TGMTClient::makeRatio1D ( MonitorElement mer,
std::string  h1Name,
std::string  h2Name 
) [private]

Referenced by process().

void L1TGMTClient::process (  )  [private]

Definition at line 122 of file L1TGMTClient.cc.

References eff_eta_dtcsc, eff_eta_rpc, eff_etaphi_dtcsc, eff_etaphi_rpc, eff_phi_dtcsc, eff_phi_rpc, makeEfficiency1D(), makeEfficiency2D(), makeRatio1D(), ratio_csc_rpcf_lumi, and ratio_dt_rpcb_lumi.

Referenced by analyze(), endLuminosityBlock(), and endRun().

00122                            {
00123   
00124 //  cout << "L1TGMTClient: processing..." << endl;
00125   
00126   makeEfficiency1D(eff_eta_dtcsc,"eta_DTCSC_and_RPC","eta_RPC_only");
00127   makeEfficiency1D(eff_eta_rpc  ,"eta_DTCSC_and_RPC","eta_DTCSC_only");
00128   
00129   makeEfficiency1D(eff_phi_dtcsc,"phi_DTCSC_and_RPC","phi_RPC_only");
00130   makeEfficiency1D(eff_phi_rpc  ,"phi_DTCSC_and_RPC","phi_DTCSC_only");
00131   
00132   makeEfficiency2D(eff_etaphi_dtcsc,"etaphi_DTCSC_and_RPC","etaphi_RPC_only");
00133   makeEfficiency2D(eff_etaphi_rpc  ,"etaphi_DTCSC_and_RPC","etaphi_DTCSC_only");
00134   
00135   makeRatio1D(ratio_dt_rpcb_lumi, "DTTF_candlumi", "RPCb_candlumi");
00136   makeRatio1D(ratio_csc_rpcf_lumi,"CSCTF_candlumi","RPCf_candlumi");  
00137   
00138 }


Member Data Documentation

int L1TGMTClient::counterEvt_ [private]

counter

Definition at line 63 of file L1TGMTClient.h.

Referenced by analyze(), and initialize().

int L1TGMTClient::counterLS_ [private]

Definition at line 62 of file L1TGMTClient.h.

Referenced by endLuminosityBlock(), and initialize().

DQMStore* L1TGMTClient::dbe_ [private]

Definition at line 58 of file L1TGMTClient.h.

Referenced by beginJob(), and initialize().

MonitorElement* L1TGMTClient::eff_eta_dtcsc [private]

prescale on number of events

Definition at line 68 of file L1TGMTClient.h.

Referenced by beginJob(), and process().

MonitorElement* L1TGMTClient::eff_eta_rpc [private]

Definition at line 69 of file L1TGMTClient.h.

Referenced by beginJob(), and process().

MonitorElement* L1TGMTClient::eff_etaphi_dtcsc [private]

Definition at line 72 of file L1TGMTClient.h.

Referenced by beginJob(), and process().

MonitorElement* L1TGMTClient::eff_etaphi_rpc [private]

Definition at line 73 of file L1TGMTClient.h.

Referenced by beginJob(), and process().

MonitorElement* L1TGMTClient::eff_phi_dtcsc [private]

Definition at line 70 of file L1TGMTClient.h.

Referenced by beginJob(), and process().

MonitorElement* L1TGMTClient::eff_phi_rpc [private]

Definition at line 71 of file L1TGMTClient.h.

Referenced by beginJob(), and process().

std::string L1TGMTClient::input_dir_ [private]

Definition at line 60 of file L1TGMTClient.h.

Referenced by initialize().

std::string L1TGMTClient::monitorName_ [private]

Definition at line 59 of file L1TGMTClient.h.

Referenced by initialize().

std::string L1TGMTClient::output_dir_ [private]

Definition at line 61 of file L1TGMTClient.h.

Referenced by beginJob(), and initialize().

edm::ParameterSet L1TGMTClient::parameters_ [private]

Definition at line 57 of file L1TGMTClient.h.

Referenced by initialize(), and L1TGMTClient().

int L1TGMTClient::prescaleEvt_ [private]

units of lumi sections

Definition at line 65 of file L1TGMTClient.h.

Referenced by analyze(), and initialize().

int L1TGMTClient::prescaleLS_ [private]

counter

Definition at line 64 of file L1TGMTClient.h.

Referenced by endLuminosityBlock(), and initialize().

MonitorElement* L1TGMTClient::ratio_csc_rpcf_lumi [private]

Definition at line 76 of file L1TGMTClient.h.

Referenced by beginJob(), and process().

MonitorElement* L1TGMTClient::ratio_dt_rpcb_lumi [private]

Definition at line 75 of file L1TGMTClient.h.

Referenced by beginJob(), and process().


The documentation for this class was generated from the following files:
Generated on Tue Jun 9 18:27:04 2009 for CMSSW by  doxygen 1.5.4