39 histfile_ =
new TFile(
"histos.root",
"RECREATE");
40 tree_ =
new TTree(
"TPGtree",
"TPGtree");
59 eTTmapToken_ = esConsumes<EcalTrigTowerConstituentsMap, IdealGeometryRecord>();
68 hTPvsTow_eta_ =
new TH2F(
"TP_vs_Tow_eta",
"TP vs Tow eta ; #eta(tow); #eta(tp)", 50, -2.5, 2.5, 50, -2.5, 2.5);
69 hAllTPperEvt_ =
new TH1F(
"AllTPperEvt",
"TP per Event; N_{TP}; ", 100, 0., 20000.);
70 hTPperEvt_ =
new TH1F(
"TPperEvt",
"N_{TP} per Event; N_{TP}; ", 100, 0., 500.);
71 hTP_iphiVsieta_ =
new TH2F(
"TP_iphiVsieta",
"TP i#phi vs i#eta ; i#eta(tp); i#phi(tp)", 10, 70, 80, 10, 340, 350);
73 new TH2F(
"TP_iphiVsieta_fullrange",
"TP i#phi vs i#eta ; i#eta(tp); i#phi(tp)", 200, -100, 100, 350, 0, 350);
77 new TH2F(
"TP_vs_Tow_ieta",
"TP vs Tow ieta ; i#eta(tow); i#eta(tp)", 200, -100, 100, 200, -100, 100);
79 hTPvsRechit_ =
new TH2F(
"TP_vs_RecHit",
"TP vs rechit Et;E_{T}(rh) (GeV);E_{T}(tp) (GeV)", 100, 0, 50, 100, 0, 50);
80 hDeltaEt_ =
new TH1F(
"DeltaEt",
"[Et(rh)-Et(TP)]/Et(rh); [E_{T}(rh)-E_{T}(tp)]/E_{T}(rh); Counts", 200, -1, 1);
81 hTPoverRechit_ =
new TH1F(
"TP_over_RecHit",
"Et(TP/rechit); E_{T}(tp)/E_{T}(rh); Counts", 200, 0, 2);
82 hRechitEt_ =
new TH1F(
"RecHitEt",
"E_{T};E_{T}(rh) (GeV);Counts", 100, 0, 50);
83 hTPEt_ =
new TH1F(
"TPEt",
"E_{T}{tp);E_{T}(rh) (GeV);Count", 100, 0, 50);
84 hRatioEt_ =
new TH1F(
"RatioTPoverRH",
"Et", 100, 0, 50);
87 hRH_iphiVsieta_ =
new TH2F(
"RH_iphiVsieta",
"RH i#phi vs i#eta ; i#eta(rh); i#phi(rh)", 10, 70, 80, 10, 340, 350);
89 new TH2F(
"RH_iphiVsieta_fullrange",
"RH i#phi vs i#eta ; i#eta(rh); i#phi(rh)", 200, -100, 100, 350, 0, 350);
127 for (
unsigned int i = 0;
i <
tp.product()->size();
i++) {
147 std::cout <<
" TP analyzer =================> Treating event " <<
iEvent.id() <<
" Number of TPs " 148 <<
tp.product()->size() << std::endl;
164 for (
unsigned int i = 0;
i <
tp.product()->size();
i++) {
175 float Et =
d.encodedEt() / 8.;
181 std::cout <<
" TP digi size " <<
d.size() << std::endl;
182 for (
int iBx = 0; iBx <
d.size(); iBx++) {
183 std::cout <<
" TP samples " <<
d.sample(iBx) << std::endl;
201 for (
unsigned int j = 0;
j < rechit_EB_col.
product()->
size();
j++) {
207 std::cout <<
" Analyzer same cristal " << myid1 <<
" " << TPid << std::endl;
228 std::cout <<
" TP compressed et " <<
d.encodedEt() <<
" Et in GeV " << Et <<
" RH Et " << rhEt
229 <<
" Et/rhEt " << Et / rhEt << std::endl;
248 for (
unsigned int j = 0;
j < rechit_EB_col.
product()->
size();
j++) {
T getParameter(std::string const &) const
int iphi() const
get the crystal iphi
Sin< T >::type sin(const T &t)
T const * product() const
edm::EDGetTokenT< EcalRecHitCollection > rechits_labelEB_
edm::ESGetToken< CaloSubdetectorGeometry, EcalBarrelGeometryRecord > barrelGeomToken_
int ieta() const
get the crystal ieta
EcalTPGScale::Tokens tokens_
T const * product() const
edm::EDGetTokenT< EBDigiCollection > tokenEBdigi_
TH2F * hTP_iphiVsieta_fullrange_
~EcalEBTrigPrimAnalyzer() override
ESHandle< T > getHandle(const ESGetToken< T, R > &iToken) const
virtual std::shared_ptr< const CaloCellGeometry > getGeometry(const DetId &id) const
Get the cell geometry of a given detector id. Should return false if not found.
EcalEBTrigPrimAnalyzer(const edm::ParameterSet &)
std::vector< edm::EDGetTokenT< int > > tokens_
edm::ESGetToken< EcalTrigTowerConstituentsMap, IdealGeometryRecord > eTTmapToken_
std::vector< std::string > ecal_parts_
edm::ESHandle< EcalTrigTowerConstituentsMap > eTTmap_
edm::EDGetTokenT< EcalEBTrigPrimDigiCollection > primToken_
void analyze(const edm::Event &, const edm::EventSetup &) override
void init(const edm::EventSetup &)
TH2F * hRH_iphiVsieta_fullrange_
Geom::Theta< T > theta() const