CMS 3D CMS Logo

/data/refman/pasoursint/CMSSW_6_1_2_SLHC2/src/DQM/DTMonitorModule/src/DTTriggerEfficiencyTask.h

Go to the documentation of this file.
00001 #ifndef DTTriggerEfficiencyTask_H
00002 #define DTTriggerEfficiencyTask_H
00003 
00004 /*
00005  * \file DTTriggerEfficiencyTask.h
00006  *
00007  * $Date: 2011/10/21 18:10:23 $
00008  * $Revision: 1.4 $
00009  * \author C. Battilana - CIEMAT
00010  *
00011 */
00012 
00013 #include "FWCore/Framework/interface/Frameworkfwd.h"
00014 #include "FWCore/Framework/interface/EDAnalyzer.h"
00015 #include "DataFormats/Common/interface/Handle.h"
00016 #include "FWCore/Framework/interface/ESHandle.h"
00017 #include <FWCore/Framework/interface/LuminosityBlock.h>
00018 
00019 #include "FWCore/Framework/interface/Event.h"
00020 #include "FWCore/Framework/interface/MakerMacros.h"
00021 
00022 #include "FWCore/ParameterSet/interface/ParameterSet.h"
00023 
00024 #include "FWCore/Utilities/interface/InputTag.h"
00025 
00026 #include "DQMServices/Core/interface/DQMStore.h"
00027 #include "DQMServices/Core/interface/MonitorElement.h"
00028 #include "FWCore/ServiceRegistry/interface/Service.h"
00029 
00030 #include "DataFormats/DTDigi/interface/DTLocalTriggerCollection.h"
00031 #include "DataFormats/DTRecHit/interface/DTRecSegment4DCollection.h"
00032 #include "DataFormats/L1GlobalMuonTrigger/interface/L1MuRegionalCand.h"
00033 #include "DataFormats/L1GlobalMuonTrigger/interface/L1MuGMTReadoutCollection.h"
00034 
00035 #include <vector>
00036 #include <string>
00037 #include <map>
00038 
00039 class DTGeometry;
00040 class DTChamberId;
00041 class DTTrigGeomUtils;
00042 
00043 class DTTriggerEfficiencyTask: public edm::EDAnalyzer{
00044   
00045  public:
00046   
00048   DTTriggerEfficiencyTask(const edm::ParameterSet& ps );
00049   
00051   virtual ~DTTriggerEfficiencyTask();
00052   
00053  protected:
00054   
00055   // BeginJob
00056   void beginJob();
00057   
00059   void beginRun(const edm::Run& run, const edm::EventSetup& context);
00060 
00062   void bookChamberHistos(const DTChamberId& dtCh, std::string histoTag, std::string folder="");
00063 
00065   void bookWheelHistos(int wheel, std::string histoTag, std::string folder="");
00066 
00068   bool hasRPCTriggers(const edm::Event& e);
00069 
00071   std::string topFolder(std::string source) { return source=="DCC" ? "DT/03-LocalTrigger-DCC/" : "DT/04-LocalTrigger-DDU/"; }
00072 
00074   void analyze(const edm::Event& e, const edm::EventSetup& c);
00075 
00077   void beginLuminosityBlock(const edm::LuminosityBlock& lumiSeg, const edm::EventSetup& context) ;
00078   
00080   void endJob(void);
00081     
00082  private:
00083   
00084   int nevents;
00085 
00086   std::string SegmArbitration;
00087 
00088   bool processDCC, processDDU, detailedPlots;
00089   std::vector<std::string> processTags;
00090   int minBXDDU, maxBXDDU;
00091 
00092   float phiAccRange;
00093   int nMinHitsPhi;
00094 
00095   edm::InputTag inputTagMuons;
00096 
00097   edm::InputTag inputTagDCC;
00098   edm::InputTag inputTagDDU;
00099   edm::InputTag inputTagSEG;
00100 
00101   edm::InputTag inputTagGMT;
00102 
00103   DQMStore* dbe;
00104   edm::ParameterSet parameters;
00105   edm::ESHandle<DTGeometry> muonGeom;
00106   DTTrigGeomUtils* trigGeomUtils;
00107   std::map<uint32_t, std::map<std::string, MonitorElement*> > chamberHistos;
00108   std::map<int, std::map<std::string, MonitorElement*> > wheelHistos;
00109 
00110 };
00111 
00112 #endif