Go to the documentation of this file.00001 #ifndef DQM_BeamMonitor_AlcaBeamMonitor_h
00002 #define DQM_BeamMonitor_AlcaBeamMonitor_h
00003
00011
00012 #include <map>
00013 #include <vector>
00014 #include <string>
00015
00016 #include "FWCore/Framework/interface/Frameworkfwd.h"
00017 #include "FWCore/Framework/interface/EDAnalyzer.h"
00018 #include "FWCore/Framework/interface/Event.h"
00019 #include "FWCore/ParameterSet/interface/ParameterSet.h"
00020 #include "DQMServices/Core/interface/DQMStore.h"
00021 #include "DQMServices/Core/interface/MonitorElement.h"
00022 #include "DataFormats/Provenance/interface/LuminosityBlockID.h"
00023 #include "DataFormats/BeamSpot/interface/BeamSpot.h"
00024 #include "DataFormats/VertexReco/interface/Vertex.h"
00025 #include "DataFormats/VertexReco/interface/VertexFwd.h"
00026
00027 class BeamFitter;
00028 class PVFitter;
00029
00030 class AlcaBeamMonitor : public edm::EDAnalyzer {
00031 public:
00032 AlcaBeamMonitor( const edm::ParameterSet& );
00033 ~AlcaBeamMonitor();
00034
00035 protected:
00036
00037 void beginJob (void);
00038 void beginRun (const edm::Run& iRun, const edm::EventSetup& iSetup);
00039 void analyze (const edm::Event& iEvent, const edm::EventSetup& iSetup);
00040 void beginLuminosityBlock(const edm::LuminosityBlock& iLumi, const edm::EventSetup& iSetup);
00041 void endLuminosityBlock (const edm::LuminosityBlock& iLumi, const edm::EventSetup& iSetup);
00042 void endRun (const edm::Run& iRun, const edm::EventSetup& iSetup);
00043 void endJob (const edm::LuminosityBlock& iLumi, const edm::EventSetup& iSetup);
00044
00045 private:
00046
00047
00048 typedef std::map<std::string,reco::BeamSpot> BeamSpotContainer;
00049
00050 typedef std::map<std::string,std::map<std::string,std::map<std::string,MonitorElement*> > > HistosContainer;
00051
00052 typedef std::map<std::string,std::map<std::string,std::map<std::string,int> > > PositionContainer;
00053
00054
00055 edm::ParameterSet parameters_;
00056 std::string monitorName_;
00057 edm::InputTag primaryVertexLabel_;
00058 edm::InputTag beamSpotLabel_;
00059 edm::InputTag trackLabel_;
00060 edm::InputTag scalerLabel_;
00061
00062
00063 int numberOfValuesToSave_;
00064 DQMStore* dbe_;
00065 BeamFitter* theBeamFitter_;
00066 PVFitter* thePVFitter_;
00067
00068
00069 MonitorElement* hD0Phi0_;
00070 MonitorElement* hDxyBS_;
00071 MonitorElement* theValuesContainer_;
00072
00073
00074 BeamSpotContainer beamSpotsMap_;
00075 HistosContainer histosMap_;
00076 PositionContainer positionsMap_;
00077 std::vector<std::string> varNamesV_;
00078 std::multimap<std::string,std::string> histoByCategoryNames_;
00079 std::vector<reco::VertexCollection> vertices_;
00080
00081 };
00082
00083 #endif
00084