8 theCaloTowerCollectionLabel(conf.getUntrackedParameter<edm::InputTag>(
"CaloTowerCollectionLabel"))
25 if(hcalselector_ ==
"HB")
isub = 1;
26 if(hcalselector_ ==
"HE")
isub = 2;
27 if(hcalselector_ ==
"HF")
isub = 3;
32 edm::LogInfo(
"OutputInfo") <<
" Hcal RecHit Task histograms will NOT be saved";
50 sprintf (histo,
"Ntowers_per_event_vs_ieta" );
53 sprintf (histo,
"CaloTowersTask_map_Nentries" );
61 sprintf (histo,
"emean_vs_ieta_E" );
63 sprintf (histo,
"emean_vs_ieta_H" );
65 sprintf (histo,
"emean_vs_ieta_EH" );
69 sprintf (histo,
"emean_vs_ieta_E1" );
71 sprintf (histo,
"emean_vs_ieta_H1" );
73 sprintf (histo,
"emean_vs_ieta_EH1" );
79 sprintf (histo,
"CaloTowersTask_map_energy_E" );
81 sprintf (histo,
"CaloTowersTask_map_energy_H");
83 sprintf (histo,
"CaloTowersTask_map_energy_EH" );
89 sprintf (histo,
"number_of_bad_cells_Ecal_EB");
91 sprintf (histo,
"number_of_bad_cells_Ecal_EE");
93 sprintf (histo,
"number_of_recovered_cells_Ecal_EB");
95 sprintf (histo,
"number_of_recovered_cells_Ecal_EE");
97 sprintf (histo,
"number_of_problematic_cells_Ecal_EB");
99 sprintf (histo,
"number_of_problematic_cells_Ecal_EE");
103 sprintf (histo,
"CaloTowersTask_map_occupancy" );
106 sprintf (histo,
"CaloTowersTask_occupancy_vs_ieta" );
111 sprintf (histo,
"number_of_bad_cells_Hcal_HB");
113 sprintf (histo,
"number_of_recovered_cells_Hcal_HB");
115 sprintf (histo,
"number_of_problematic_cells_Hcal_HB");
120 sprintf (histo,
"CaloTowersTask_energy_HCAL_HB" ) ;
123 sprintf (histo,
"CaloTowersTask_energy_ECAL_HB" ) ;
126 sprintf (histo,
"CaloTowersTask_number_of_fired_towers_HB" ) ;
129 sprintf (histo,
"CaloTowersTask_MET_HB" ) ;
132 sprintf (histo,
"CaloTowersTask_SET_HB" ) ;
138 sprintf (histo,
"CaloTowersTask_EM_Timing_HB" ) ;
141 sprintf (histo,
"CaloTowersTask_HAD_Timing_HB" ) ;
146 sprintf (histo,
"CaloTowersTask_EM_Energy_Timing_Low_HB" ) ;
149 sprintf (histo,
"CaloTowersTask_EM_Energy_Timing_HB" ) ;
152 sprintf (histo,
"CaloTowersTask_EM_Energy_Timing_High_HB" ) ;
155 sprintf (histo,
"CaloTowersTask_EM_Energy_Timing_profile_Low_HB" ) ;
158 sprintf (histo,
"CaloTowersTask_EM_Energy_Timing_profile_HB" ) ;
161 sprintf (histo,
"CaloTowersTask_EM_Energy_Timing_profile_High_HB" ) ;
165 sprintf (histo,
"CaloTowersTask_HAD_Energy_Timing_Low_HB" ) ;
168 sprintf (histo,
"CaloTowersTask_HAD_Energy_Timing_HB" ) ;
171 sprintf (histo,
"CaloTowersTask_HAD_Energy_Timing_High_HB" ) ;
174 sprintf (histo,
"CaloTowersTask_HAD_Energy_Timing_profile_Low_HB" ) ;
177 sprintf (histo,
"CaloTowersTask_HAD_Energy_Timing_profile_HB" ) ;
180 sprintf (histo,
"CaloTowersTask_HAD_Energy_Timing_profile_High_HB" ) ;
186 sprintf (histo,
"CaloTowersTask_sum_of_energy_HCAL_vs_ECAL_HB") ;
189 sprintf (histo,
"CaloTowersTask_energy_OUTER_HB" ) ;
192 sprintf (histo,
"CaloTowersTask_energy_of_ECAL_component_of_tower_HB" ) ;
195 sprintf (histo,
"CaloTowersTask_energy_of_HCAL_component_of_tower_HB" ) ;
198 sprintf (histo,
"CaloTowersTask_energy_HcalPlusEcalPlusHO_HB" ) ;
201 sprintf (histo,
"CaloTowersTask_map_energy_HB" );
203 sprintf (histo,
"CaloTowersTask_map_energy_HCAL_HB");
205 sprintf (histo,
"CaloTowersTask_map_energy_ECAL_HB" );
208 sprintf (histo,
"CaloTowersTask_phi_MET_HB" ) ;
215 sprintf (histo,
"number_of_bad_cells_Hcal_HE");
217 sprintf (histo,
"number_of_recovered_cells_Hcal_HE");
219 sprintf (histo,
"number_of_problematic_cells_Hcal_HE");
224 sprintf (histo,
"CaloTowersTask_energy_HCAL_HE" ) ;
227 sprintf (histo,
"CaloTowersTask_energy_ECAL_HE" ) ;
230 sprintf (histo,
"CaloTowersTask_number_of_fired_towers_HE" ) ;
233 sprintf (histo,
"CaloTowersTask_MET_HE" ) ;
236 sprintf (histo,
"CaloTowersTask_SET_HE" ) ;
242 sprintf (histo,
"CaloTowersTask_EM_Timing_HE" ) ;
245 sprintf (histo,
"CaloTowersTask_HAD_Timing_HE" ) ;
250 sprintf (histo,
"CaloTowersTask_EM_Energy_Timing_Low_HE" ) ;
253 sprintf (histo,
"CaloTowersTask_EM_Energy_Timing_HE" ) ;
256 sprintf (histo,
"CaloTowersTask_EM_Energy_Timing_profile_Low_HE" ) ;
259 sprintf (histo,
"CaloTowersTask_EM_Energy_Timing_profile_HE" ) ;
263 sprintf (histo,
"CaloTowersTask_HAD_Energy_Timing_Low_HE" ) ;
266 sprintf (histo,
"CaloTowersTask_HAD_Energy_Timing_HE" ) ;
269 sprintf (histo,
"CaloTowersTask_HAD_Energy_Timing_profile_Low_HE" ) ;
272 sprintf (histo,
"CaloTowersTask_HAD_Energy_Timing_profile_HE" ) ;
278 sprintf (histo,
"CaloTowersTask_sum_of_energy_HCAL_vs_ECAL_HE") ;
281 sprintf (histo,
"CaloTowersTask_energy_OUTER_HE" ) ;
284 sprintf (histo,
"CaloTowersTask_energy_of_ECAL_component_of_tower_HE" ) ;
287 sprintf (histo,
"CaloTowersTask_energy_of_HCAL_component_of_tower_HE" ) ;
290 sprintf (histo,
"CaloTowersTask_energy_HcalPlusEcalPlusHO_HE" ) ;
293 sprintf (histo,
"CaloTowersTask_map_energy_HE" );
295 sprintf (histo,
"CaloTowersTask_map_energy_HCAL_HE");
297 sprintf (histo,
"CaloTowersTask_map_energy_ECAL_HE" );
300 sprintf (histo,
"CaloTowersTask_phi_MET_HE" ) ;
308 sprintf (histo,
"number_of_bad_cells_Hcal_HF");
310 sprintf (histo,
"number_of_recovered_cells_Hcal_HF");
312 sprintf (histo,
"number_of_problematic_cells_Hcal_HF");
317 sprintf (histo,
"CaloTowersTask_energy_HCAL_HF" ) ;
320 sprintf (histo,
"CaloTowersTask_energy_ECAL_HF" ) ;
323 sprintf (histo,
"CaloTowersTask_number_of_fired_towers_HF" ) ;
326 sprintf (histo,
"CaloTowersTask_MET_HF" ) ;
329 sprintf (histo,
"CaloTowersTask_SET_HF" ) ;
335 sprintf (histo,
"CaloTowersTask_EM_Timing_HF" ) ;
338 sprintf (histo,
"CaloTowersTask_HAD_Timing_HF" ) ;
342 sprintf (histo,
"CaloTowersTask_EM_Energy_Timing_HF" ) ;
345 sprintf (histo,
"CaloTowersTask_EM_Energy_Timing_profile_HF" ) ;
349 sprintf (histo,
"CaloTowersTask_HAD_Energy_Timing_Low_HF" ) ;
352 sprintf (histo,
"CaloTowersTask_HAD_Energy_Timing_HF" ) ;
355 sprintf (histo,
"CaloTowersTask_HAD_Energy_Timing_profile_Low_HF" ) ;
358 sprintf (histo,
"CaloTowersTask_HAD_Energy_Timing_profile_HF" ) ;
364 sprintf (histo,
"CaloTowersTask_sum_of_energy_HCAL_vs_ECAL_HF") ;
367 sprintf (histo,
"CaloTowersTask_energy_OUTER_HF" ) ;
370 sprintf (histo,
"CaloTowersTask_energy_of_ECAL_component_of_tower_HF" ) ;
373 sprintf (histo,
"CaloTowersTask_energy_of_HCAL_component_of_tower_HF" ) ;
376 sprintf (histo,
"CaloTowersTask_energy_HcalPlusEcalPlusHO_HF" ) ;
379 sprintf (histo,
"CaloTowersTask_map_energy_HF" );
381 sprintf (histo,
"CaloTowersTask_map_energy_HCAL_HF");
383 sprintf (histo,
"CaloTowersTask_map_energy_ECAL_HF" );
386 sprintf (histo,
"CaloTowersTask_phi_MET_HF" ) ;
428 double sumEnergyHcal_HB = 0.;
429 double sumEnergyEcal_HB = 0.;
430 double sumEnergyHO_HB = 0.;
431 Int_t numFiredTowers_HB = 0;
437 double sumEnergyHcal_HE = 0.;
438 double sumEnergyEcal_HE = 0.;
439 double sumEnergyHO_HE = 0.;
440 Int_t numFiredTowers_HE = 0;
446 double sumEnergyHcal_HF = 0.;
447 double sumEnergyEcal_HF = 0.;
448 double sumEnergyHO_HF = 0.;
449 Int_t numFiredTowers_HF = 0;
455 for ( cal = towers->begin(); cal != towers->end(); ++cal ) {
457 double eE = cal->emEnergy();
458 double eH = cal->hadEnergy();
459 double eHO = cal->outerEnergy();
460 double etaT = cal->eta();
462 double en = cal->energy();
463 double etT = cal->et();
464 double had_tm = cal->hcalTime();
465 double em_tm = cal->ecalTime();
467 int numBadEcalCells = cal->numBadEcalCells();
468 int numRcvEcalCells = cal->numRecoveredEcalCells();
469 int numPrbEcalCells = cal->numProblematicEcalCells();
471 int numBadHcalCells = cal->numBadHcalCells();
472 int numRcvHcalCells = cal->numRecoveredHcalCells();
473 int numPrbHcalCells = cal->numProblematicHcalCells();
480 int ieta = idT.
ieta();
481 if(ieta > 0) ieta -= 1;
482 int iphi = idT.iphi();
486 std::vector<int> inEcals(2), inHcals(3);
487 unsigned int constitSize = cal->constituentsSize();
488 for(
unsigned int ic=0; ic<constitSize; ic++){
489 DetId detId = cal->constituent(ic);
518 && (fabs(etaT) <
etaMax[0] && fabs(etaT) >=
etaMin[0] )) {
534 sumEnergyHcal_HB += eH;
535 sumEnergyEcal_HB += eE;
536 sumEnergyHO_HB += eHO;
572 && (fabs(etaT) <
etaMax[1] && fabs(etaT) >=
etaMin[1] )) {
588 sumEnergyHcal_HE += eH;
589 sumEnergyEcal_HE += eE;
590 sumEnergyHO_HE += eHO;
621 && (fabs(etaT) <
etaMax[2] && fabs(etaT) >=
etaMin[2] )) {
637 sumEnergyHcal_HF += eH;
638 sumEnergyEcal_HF += eE;
639 sumEnergyHO_HF += eHO;
673 met =
sqrt(metx_HB*metx_HB + mety_HB*mety_HB);
674 Vector metv(metx_HB,mety_HB,metz_HB);
695 met =
sqrt(metx_HE*metx_HE + mety_HE*mety_HE);
696 Vector metv(metx_HE,mety_HE,metz_HE);
716 met =
sqrt(metx_HF*metx_HF + mety_HF*mety_HF);
717 Vector metv(metx_HF,mety_HF,metz_HF);
739 double PI = 3.1415926535898;
740 double deltaphi= phi1 - phi2;
741 if( phi2 > phi1 ) { deltaphi= phi2 - phi1;}
742 if(deltaphi > PI) { deltaphi = 2.*PI - deltaphi;}
743 double deltaeta = eta2 - eta1;
744 double tmp =
sqrt(deltaeta* deltaeta + deltaphi*deltaphi);
MonitorElement * emean_vs_ieta_EH1
MonitorElement * mapEnergyEcal_HF
edm::InputTag theCaloTowerCollectionLabel
T getUntrackedParameter(std::string const &, T const &) const
MonitorElement * meNumFiredTowers_HF
MonitorElement * hadEnergyTiming_profile_High_HB
MonitorElement * hadEnergyTiming_HF
MonitorElement * meEnergyHcalTower_HF
MonitorElement * meEnergyHcalvsEcal_HE
HcalSubdetector subdet() const
get the subdetector
MonitorElement * hadEnergyTiming_Low_HE
MonitorElement * meEnergyHcalTower_HE
MonitorElement * numRcvCellsHcal_HF
MonitorElement * book1D(const char *name, const char *title, int nchX, double lowX, double highX)
Book 1D histogram.
MonitorElement * phiMET_HF
MonitorElement * emEnergyTiming_profile_Low_HB
MonitorElement * phiMET_HE
MonitorElement * meEnergyEcalTower_HF
MonitorElement * hadEnergyTiming_profile_Low_HE
CaloTowersAnalyzer(edm::ParameterSet const &conf)
#define DEFINE_FWK_MODULE(type)
MonitorElement * emEnergyTiming_Low_HB
MonitorElement * emTiming_HE
void save(const std::string &filename, const std::string &path="", const std::string &pattern="", const std::string &rewrite="", SaveReferenceTag ref=SaveWithReference, int minStatus=dqm::qstatus::STATUS_OK, const std::string &fileupdate="RECREATE")
MonitorElement * meEnergyEcalTower_HE
MonitorElement * numRcvCellsEcal_EB
std::vector< CaloTower >::const_iterator const_iterator
MonitorElement * meEnergyHcalTower_HB
MonitorElement * emEnergyTiming_profile_Low_HE
MonitorElement * numRcvCellsEcal_EE
MonitorElement * meEnergyHcal_HF
MonitorElement * meEnergyHcal_HB
MonitorElement * meEnergyHO_HB
MonitorElement * emTiming_HB
MonitorElement * occupancy_map
std::string hcalselector_
MonitorElement * emEnergyTiming_HE
MonitorElement * hadEnergyTiming_Low_HB
MonitorElement * hadEnergyTiming_profile_Low_HB
MonitorElement * emean_vs_ieta_H
RhoEtaPhiVectorD RhoEtaPhiVector
spatial vector with cylindrical internal representation using pseudorapidity
MonitorElement * hadTiming_HE
MonitorElement * mapEnergyEcal_HB
MonitorElement * meEnergyHO_HF
MonitorElement * occupancy_vs_ieta
MonitorElement * mapEnergy_EH
MonitorElement * phiMET_HB
virtual void analyze(edm::Event const &e, edm::EventSetup const &c)
MonitorElement * meEnergyEcal_HE
MonitorElement * hadEnergyTiming_profile_HB
MonitorElement * meEnergyEcal_HB
MonitorElement * numBadCellsHcal_HE
MonitorElement * meTotEnergy_HE
void Fill(HcalDetId &id, double val, std::vector< TH2F > &depth)
MonitorElement * mapEnergy_E
MonitorElement * hadEnergyTiming_Low_HF
MonitorElement * numRcvCellsHcal_HB
MonitorElement * meNumFiredTowers_HB
MonitorElement * numPrbCellsHcal_HB
MonitorElement * mapEnergyHcal_HF
MonitorElement * meEnergyHcal_HE
MonitorElement * hadTiming_HB
MonitorElement * numBadCellsEcal_EE
MonitorElement * numPrbCellsEcal_EE
MonitorElement * mapEnergy_HE
MonitorElement * mapEnergy_HF
MonitorElement * mapEnergy_HB
MonitorElement * bookProfile(const char *name, const char *title, int nchX, double lowX, double highX, int nchY, double lowY, double highY, const char *option="s")
MonitorElement * meEnergyEcalTower_HB
MonitorElement * emean_vs_ieta_H1
MonitorElement * emEnergyTiming_High_HB
How EventSelector::AcceptEvent() decides whether to accept an event for output otherwise it is excluding the probing of A single or multiple positive and the trigger will pass if any such matching triggers are PASS or EXCEPTION[A criterion thatmatches no triggers at all is detected and causes a throw.] A single negative with an expectation of appropriate bit checking in the decision and the trigger will pass if any such matching triggers are FAIL or EXCEPTION A wildcarded negative criterion that matches more than one trigger in the trigger but the state exists so we define the behavior If all triggers are the negative crieriion will lead to accepting the event(this again matches the behavior of"!*"before the partial wildcard feature was incorporated).The per-event"cost"of each negative criterion with multiple relevant triggers is about the same as!*was in the past
int subdetId() const
get the contents of the subdetector field (not cast into any detector's numbering enum) ...
math::RhoEtaPhiVector Vector
MonitorElement * numRcvCellsHcal_HE
MonitorElement * emEnergyTiming_profile_HF
MonitorElement * hadEnergyTiming_HE
MonitorElement * numPrbCellsHcal_HE
MonitorElement * emEnergyTiming_profile_High_HB
MonitorElement * meTotEnergy_HB
MonitorElement * meTotEnergy_HF
MonitorElement * hadEnergyTiming_High_HB
MonitorElement * mapEnergyHcal_HE
MonitorElement * hadEnergyTiming_HB
MonitorElement * numPrbCellsHcal_HF
MonitorElement * hadEnergyTiming_profile_HF
MonitorElement * numBadCellsHcal_HB
MonitorElement * Ntowers_vs_ieta
MonitorElement * emEnergyTiming_HB
MonitorElement * meEnergyHO_HE
MonitorElement * hadEnergyTiming_profile_HE
MonitorElement * emEnergyTiming_Low_HE
MonitorElement * emean_vs_ieta_E
MonitorElement * numPrbCellsEcal_EB
MonitorElement * emean_vs_ieta_EH
std::vector< std::vector< double > > tmp
MonitorElement * numBadCellsHcal_HF
double dR(double eta1, double phi1, double eta2, double phi2)
MonitorElement * hadTiming_HF
MonitorElement * numBadCellsEcal_EB
MonitorElement * mapEnergyEcal_HE
MonitorElement * emTiming_HF
MonitorElement * emEnergyTiming_profile_HE
MonitorElement * mapEnergy_N
int ieta() const
get the tower ieta
MonitorElement * meEnergyHcalvsEcal_HB
MonitorElement * book2D(const char *name, const char *title, int nchX, double lowX, double highX, int nchY, double lowY, double highY)
Book 2D histogram.
Detector det() const
get the detector field from this detid
MonitorElement * mapEnergyHcal_HB
MonitorElement * emEnergyTiming_profile_HB
MonitorElement * meEnergyHcalvsEcal_HF
MonitorElement * emean_vs_ieta_E1
MonitorElement * meNumFiredTowers_HE
void setCurrentFolder(const std::string &fullpath)
MonitorElement * emEnergyTiming_HF
MonitorElement * hadEnergyTiming_profile_Low_HF
MonitorElement * mapEnergy_H
MonitorElement * meEnergyEcal_HF