CMS 3D CMS Logo

EcalTPGAnalyzer.h
Go to the documentation of this file.
1 // -*- C++ -*-
2 //
3 // Class: EcalTPGAnalyzer
4 //
5 //
6 // Original Author: Pascal Paganini
7 //
15 #include <vector>
16 #include <string>
17 #include <TFile.h>
18 #include <TTree.h>
19 
21 
22 // Auxiliary class
23 class towerEner {
24 public:
25  float eRec_;
26  int tpgEmul_[5];
27  int tpgADC_;
29  towerEner() : eRec_(0), tpgADC_(0), iphi_(-999), ieta_(-999), nbXtal_(0) {
30  for (int i = 0; i < 5; i++)
31  tpgEmul_[i] = 0;
32  }
33 };
34 
36 public:
37  explicit EcalTPGAnalyzer(const edm::ParameterSet &);
38  ~EcalTPGAnalyzer() override;
39  void analyze(edm::Event const &, edm::EventSetup const &) override;
40  void beginRun(edm::Run const &, edm::EventSetup const &) override;
41 
42 private:
44  // event variables
45  unsigned int runNb;
46  unsigned int evtNb;
47  unsigned int bxNb;
48  unsigned int orbitNb;
49  unsigned int nbOfActiveTriggers;
50  int activeTriggers[128];
51 
52  // tower variables
53  unsigned int nbOfTowers; //max 4032 EB+EE
54  int ieta[4032];
55  int iphi[4032];
56  int nbOfXtals[4032];
57  int rawTPData[4032];
58  int rawTPEmul1[4032];
59  int rawTPEmul2[4032];
60  int rawTPEmul3[4032];
61  int rawTPEmul4[4032];
62  int rawTPEmul5[4032];
63  float eRec[4032];
64  };
65 
66 private:
67  TFile *file_;
68  TTree *tree_;
70 
76 
77  bool allowTP_;
78  bool useEE_;
79  bool print_;
80 
84 };
EcalTPGAnalyzer::tpEmulatorCollection_
edm::InputTag tpEmulatorCollection_
Definition: EcalTPGAnalyzer.h:72
mps_fire.i
i
Definition: mps_fire.py:428
EcalTPGAnalyzer::theBarrelGeometry_
const CaloSubdetectorGeometry * theBarrelGeometry_
Definition: EcalTPGAnalyzer.h:82
EcalTPGAnalyzer::EcalTPGVariables::rawTPEmul2
int rawTPEmul2[4032]
Definition: EcalTPGAnalyzer.h:59
towerEner::iphi_
int iphi_
Definition: EcalTPGAnalyzer.h:28
EcalTPGAnalyzer::EcalTPGVariables::rawTPData
int rawTPData[4032]
Definition: EcalTPGAnalyzer.h:57
ESHandle.h
edm::Run
Definition: Run.h:45
EcalTPGAnalyzer::file_
TFile * file_
Definition: EcalTPGAnalyzer.h:67
EcalTPGAnalyzer
Definition: EcalTPGAnalyzer.h:35
EcalTPGAnalyzer::EcalTPGVariables::nbOfTowers
unsigned int nbOfTowers
Definition: EcalTPGAnalyzer.h:53
EcalTPGAnalyzer::EcalTPGVariables::bxNb
unsigned int bxNb
Definition: EcalTPGAnalyzer.h:47
EDAnalyzer.h
EcalTPGAnalyzer::EcalTPGVariables::evtNb
unsigned int evtNb
Definition: EcalTPGAnalyzer.h:46
EcalTPGAnalyzer::theEndcapGeometry_
const CaloSubdetectorGeometry * theEndcapGeometry_
Definition: EcalTPGAnalyzer.h:81
EcalTPGAnalyzer::EcalTPGVariables
Definition: EcalTPGAnalyzer.h:43
edm::EDAnalyzer
Definition: EDAnalyzer.h:28
EcalTPGAnalyzer::EcalTPGVariables::orbitNb
unsigned int orbitNb
Definition: EcalTPGAnalyzer.h:48
towerEner::eRec_
float eRec_
Definition: EcalTPGAnalyzer.h:25
MakerMacros.h
EcalTPGAnalyzer::EcalTPGVariables::rawTPEmul1
int rawTPEmul1[4032]
Definition: EcalTPGAnalyzer.h:58
EcalTPGAnalyzer::EcalTPGVariables::rawTPEmul3
int rawTPEmul3[4032]
Definition: EcalTPGAnalyzer.h:60
towerEner::ieta_
int ieta_
Definition: EcalTPGAnalyzer.h:28
EcalTPGAnalyzer::~EcalTPGAnalyzer
~EcalTPGAnalyzer() override
Definition: EcalTPGAnalyzer.cc:88
edm::ESHandle< EcalTrigTowerConstituentsMap >
EcalTPGAnalyzer::EcalTPGVariables::activeTriggers
int activeTriggers[128]
Definition: EcalTPGAnalyzer.h:50
EcalTPGAnalyzer::beginRun
void beginRun(edm::Run const &, edm::EventSetup const &) override
Definition: EcalTPGAnalyzer.cc:94
AlCaHLTBitMon_QueryRunRegistry.string
string
Definition: AlCaHLTBitMon_QueryRunRegistry.py:256
CaloSubdetectorGeometry.h
EcalTPGAnalyzer::EcalTPGVariables::nbOfXtals
int nbOfXtals[4032]
Definition: EcalTPGAnalyzer.h:56
edm::ParameterSet
Definition: ParameterSet.h:47
Event.h
EcalTPGAnalyzer::tree_
TTree * tree_
Definition: EcalTPGAnalyzer.h:68
EcalTPGAnalyzer::EcalTPGVariables::ieta
int ieta[4032]
Definition: EcalTPGAnalyzer.h:54
towerEner::tpgEmul_
int tpgEmul_[5]
Definition: EcalTPGAnalyzer.h:26
EcalTPGAnalyzer::print_
bool print_
Definition: EcalTPGAnalyzer.h:79
EcalTPGAnalyzer::EcalTPGVariables::eRec
float eRec[4032]
Definition: EcalTPGAnalyzer.h:63
EcalTPGAnalyzer::EcalTPGAnalyzer
EcalTPGAnalyzer(const edm::ParameterSet &)
Definition: EcalTPGAnalyzer.cc:50
EcalTPGAnalyzer::analyze
void analyze(edm::Event const &, edm::EventSetup const &) override
Definition: EcalTPGAnalyzer.cc:108
EcalTPGAnalyzer::tpCollection_
edm::InputTag tpCollection_
Definition: EcalTPGAnalyzer.h:71
edm::EventSetup
Definition: EventSetup.h:57
towerEner::towerEner
towerEner()
Definition: EcalTPGAnalyzer.h:29
EcalTPGAnalyzer::EcalTPGVariables::nbOfActiveTriggers
unsigned int nbOfActiveTriggers
Definition: EcalTPGAnalyzer.h:49
EcalTPGAnalyzer::gtRecordCollectionTag_
std::string gtRecordCollectionTag_
Definition: EcalTPGAnalyzer.h:75
EcalTPGAnalyzer::useEE_
bool useEE_
Definition: EcalTPGAnalyzer.h:78
EcalTrigTowerConstituentsMap.h
towerEner::tpgADC_
int tpgADC_
Definition: EcalTPGAnalyzer.h:27
EcalTPGAnalyzer::digiCollectionEB_
edm::InputTag digiCollectionEB_
Definition: EcalTPGAnalyzer.h:73
EcalTPGAnalyzer::allowTP_
bool allowTP_
Definition: EcalTPGAnalyzer.h:77
EcalTPGAnalyzer::eTTmap_
edm::ESHandle< EcalTrigTowerConstituentsMap > eTTmap_
Definition: EcalTPGAnalyzer.h:83
EcalTPGAnalyzer::digiCollectionEE_
edm::InputTag digiCollectionEE_
Definition: EcalTPGAnalyzer.h:74
CaloSubdetectorGeometry
Definition: CaloSubdetectorGeometry.h:22
towerEner::nbXtal_
int nbXtal_
Definition: EcalTPGAnalyzer.h:28
ParameterSet.h
EcalTPGAnalyzer::EcalTPGVariables::rawTPEmul4
int rawTPEmul4[4032]
Definition: EcalTPGAnalyzer.h:61
edm::Event
Definition: Event.h:73
towerEner
Definition: EcalTPGAnalyzer.h:23
EcalTPGAnalyzer::EcalTPGVariables::rawTPEmul5
int rawTPEmul5[4032]
Definition: EcalTPGAnalyzer.h:62
EcalTPGAnalyzer::EcalTPGVariables::runNb
unsigned int runNb
Definition: EcalTPGAnalyzer.h:45
edm::InputTag
Definition: InputTag.h:15
EcalTPGAnalyzer::EcalTPGVariables::iphi
int iphi[4032]
Definition: EcalTPGAnalyzer.h:55
EcalTPGAnalyzer::treeVariables_
EcalTPGVariables treeVariables_
Definition: EcalTPGAnalyzer.h:69