CMS 3D CMS Logo

EcalMipGraphs.h
Go to the documentation of this file.
1 // -*- C++ -*-
2 //
3 // Package: EcalMipGraphs
4 // Class: EcalMipGraphs
5 //
13 //
14 // Original Author: Seth COOPER
15 // Created: Th Nov 22 5:46:22 CEST 2007
16 //
17 //
18 
19 // system include files
20 #include <memory>
21 #include <vector>
22 #include <map>
23 #include <set>
24 #include <string>
25 
26 // user include files
36 
43 
47 
49 
50 #include "TFile.h"
51 #include "TH1F.h"
52 #include "TGraph.h"
53 #include "TTree.h"
54 
55 //
56 // class declaration
57 //
58 
59 class EcalMipGraphs : public edm::one::EDAnalyzer<edm::one::WatchRuns> {
60 public:
61  explicit EcalMipGraphs(const edm::ParameterSet&);
62  ~EcalMipGraphs() override;
63 
64 private:
65  void beginRun(edm::Run const&, edm::EventSetup const&) override;
66  void endRun(edm::Run const&, edm::EventSetup const&) override;
67  void analyze(edm::Event const&, edm::EventSetup const&) override;
68  void endJob() override;
71  void writeGraphs();
72  void initHists(int);
74  TGraph* selectDigi(DetId det, int ievt);
75  int getEEIndex(EcalElectronicsId elecId);
76 
77  // ----------member data ---------------------------
78 
84 
87 
93 
96 
97  int runNum_;
98  const int side_;
99  const double threshold_;
100  const double minTimingAmp_;
101 
102  std::set<EBDetId> listEBChannels;
103  std::set<EEDetId> listEEChannels;
104 
105  int abscissa[10];
106  int ordinate[10];
107 
108  static float gainRatio[3];
110 
111  std::vector<std::string>* names;
112  std::vector<int> maskedChannels_;
113  std::vector<int> maskedFEDs_;
114  std::vector<int> seedCrys_;
115  std::vector<std::string> maskedEBs_;
116  std::map<int, TH1F*> FEDsAndTimingHists_;
117  std::map<int, float> crysAndAmplitudesMap_;
118  std::map<int, EcalDCCHeaderBlock> FEDsAndDCCHeaders_;
119  std::map<std::string, int> seedFrequencyMap_;
120 
122 
123  TFile* file_;
124  TTree* canvasNames_;
128 
130 };
const edm::InputTag EEDigis_
Definition: EcalMipGraphs.h:82
void analyze(edm::Event const &, edm::EventSetup const &) override
std::string floatToString(float num)
std::vector< int > maskedFEDs_
int getEEIndex(EcalElectronicsId elecId)
void initHists(int)
const edm::EDGetTokenT< EEDigiCollection > eeDigiToken_
Definition: EcalMipGraphs.h:92
EcalFedMap * fedMap_
Ecal readout channel identification [32:20] Unused (so far) [19:13] DCC id [12:6] tower [5:3] strip [...
void selectHits(edm::Handle< EcalRecHitCollection > hits, int ievt)
std::string intToString(int num)
std::vector< std::string > maskedEBs_
TTree * canvasNames_
const EcalElectronicsMapping * ecalElectronicsMap_
static edm::Service< TFileService > fileService
int abscissa[10]
std::map< std::string, int > seedFrequencyMap_
void endRun(edm::Run const &, edm::EventSetup const &) override
std::set< EEDetId > listEEChannels
std::map< int, EcalDCCHeaderBlock > FEDsAndDCCHeaders_
const edm::EDGetTokenT< EcalRawDataCollection > rawDataToken_
Definition: EcalMipGraphs.h:88
EcalMipGraphs(const edm::ParameterSet &)
std::set< EBDetId > listEBChannels
const int side_
Definition: EcalMipGraphs.h:98
std::map< int, float > crysAndAmplitudesMap_
const edm::InputTag EBRecHitCollection_
Definition: EcalMipGraphs.h:79
int ordinate[10]
const edm::ESGetToken< EcalElectronicsMapping, EcalMappingRcd > ecalMappingToken_
Definition: EcalMipGraphs.h:94
void writeGraphs()
void endJob() override
const edm::InputTag EERecHitCollection_
Definition: EcalMipGraphs.h:80
TGraph * selectDigi(DetId det, int ievt)
const double threshold_
Definition: EcalMipGraphs.h:99
const CaloTopology * caloTopo_
Definition: DetId.h:17
std::vector< int > seedCrys_
const edm::EDGetTokenT< EcalRecHitCollection > ebRecHitToken_
Definition: EcalMipGraphs.h:89
std::vector< int > maskedChannels_
const edm::InputTag EBDigis_
Definition: EcalMipGraphs.h:81
edm::Handle< EEDigiCollection > EEdigisHandle
Definition: EcalMipGraphs.h:86
std::vector< std::string > * names
const edm::EDGetTokenT< EBDigiCollection > ebDigiToken_
Definition: EcalMipGraphs.h:91
void beginRun(edm::Run const &, edm::EventSetup const &) override
const edm::ESGetToken< CaloTopology, CaloTopologyRecord > topologyToken_
Definition: EcalMipGraphs.h:95
const edm::EDGetTokenT< EcalRecHitCollection > eeRecHitToken_
Definition: EcalMipGraphs.h:90
std::map< int, TH1F * > FEDsAndTimingHists_
const edm::InputTag headerProducer_
Definition: EcalMipGraphs.h:83
~EcalMipGraphs() override
static float gainRatio[3]
const double minTimingAmp_
TH1F * allFedsTimingHist_
edm::Handle< EBDigiCollection > EBdigisHandle
Definition: EcalMipGraphs.h:85
Definition: Run.h:45