28 const std::string&
name,
29 const IInterface*
parent) :
31 m_trigDec(
"Trig::TrigDecisionTool/TrigDecisionTool"),
35 m_isTrigDefined1(false),
36 m_isTrigDefined2(false),
37 m_isTrigDefined3(false),
38 m_isTrigEvent1(false),
39 m_isTrigEvent2(false),
40 m_isTrigEvent3(false),
46 m_twr_etaphi_Et_thresh(),
49 m_twr_e_phiall_thresh(),
50 m_twr_e_etaphi_thresh(),
51 m_twr_e_trans_phi_thresh(),
52 m_twr_e_trans_eta_thresh(),
53 m_twr_e_trans_phiall_thresh(),
54 m_twr_e_trans_etaphi_thresh(),
55 m_twr_e_total_phi_thresh(),
56 m_twr_e_total_eta_thresh(),
57 m_twr_e_total_phiall_thresh(),
58 m_twr_e_total_etaphi_thresh(),
59 m_twr_nCells_phi_thresh(),
60 m_twr_nCells_eta_thresh(),
61 m_twr_nCells_phiall_thresh(),
62 m_twr_nCells_etaphi_thresh(),
65 m_twr_phiall_thresh(),
68 declareInterface<IMonitorToolBase>(
this);
129 for (
int j=0; j<3;j++){
178 ATH_MSG_ERROR(
"Could not initialize ManagedMonitorToolBase");
213 if( !
sc.isSuccess() ) {
253 return StatusCode::SUCCESS;
274 return StatusCode::SUCCESS;
278 bool isNewTimeGran=isNewRun;
283 isNewTimeGran=isNewEventsBlock;
286 else if (
m_timeGran.compare(
"lumiblock") ==0) {
287 isNewTimeGran=isNewLumiBlock;
323 std::string TheTrigger;
327 std::string TheTowerDir(
"/CaloMonitoring/");
330 m_n_calos =
new TH1F(
"NCalos",
"Number of Calorimeters in Tower", 10, 0., 10.);
333 m_n_twrs =
new TH1F(
"NTwr",
"Number of Towers",150,0.,7500.);
334 m_n_twrs->GetXaxis()->SetTitle(
"Number");
335 m_n_twrs->GetYaxis()->SetTitle(
"Events");
340 std::string TheTrigger;
344 std::string TheTowerDir(
"/CaloMonitoring/");
352 m_etaphi_hotrat_tower =
new TH2F(
"etaphi_hotrat",
"Hit map of towers with E_Cell/E_tower > 0.9 and E_Tower>0.0 GeV",98,-4.9,4.9,64,-3.15,3.15);
365 std::string TheTrigger;
369 std::string TheTowerDir(
"/CaloMonitoring/");
375 m_twr_e =
new TH1F(
"EnergyOfTwr",
"Tower Energy Distribution", 100,-500.0,500.0);
376 m_twr_e->GetXaxis()->SetTitle(
"Energy");
377 m_twr_e->GetYaxis()->SetTitle(
"Events");
380 m_postwr_e_thresh =
new TH1F(
"EnergyOfPosTwr",
"Tower Energy distribution with E_Twr>0.0GeV", 100,0.,500.0);
385 m_negtwr_e_thresh =
new TH1F(
"EnergyOfNegTwr",
"Tower Energy distribution with E_Twr<0.0GeV", 100,-500.0,0.);
390 std::string title_FcalA0 =
"Tower in FcalA Et Distribution without trigger cut";
402 std::string title_FcalA2 =
"Tower in FcalA Et Distribution passing"+
m_TriggerNames3;
408 std::string title_FcalC0 =
"Tower in FcalC Et Distribution without trigger cut";
420 std::string title_FcalC2 =
"Tower in FcalC Et Distribution passing"+
m_TriggerNames3;
428 std::string TheTrigger;
432 std::string TheTowerDir(
"/CaloMonitoring/");
448 sprintf(bname,
"TwrOccupancyVsEtaPhithresh_Et_%d",
i);
449 sprintf(btitle,
"Tower Occupancy Vs #eta - #phi with Et_Twr> %4.1f GeV",
m_Ethresh[
i]);
456 for (
int j=0; j<3;j++){
469 sprintf(bname,
"AvgEnergyOfTwrVsPhithresh_%s_%d",
Region.c_str(),
i);
470 sprintf(btitle,
"AvgEnergy of Tower %s Vs #phi with E_Twr> %4.1f GeV",
Region.c_str(),
m_Ethresh[
i]);
478 sprintf(bname,
"TransEnergyOfTwrVsPhithresh_%s_%d",
Region.c_str(),
i);
479 sprintf(btitle,
"TransEnergy of Tower %s Vs #phi with E_Twr> %4.1f GeV",
Region.c_str(),
m_Ethresh[
i]);
488 sprintf(bname,
"TotalEnergyOfTwrVsPhithresh_%s_%d",
Region.c_str(),
i);
489 sprintf(btitle,
"TotalEnergy of Tower %s Vs #phi with E_Twr> %4.1f GeV",
Region.c_str(),
m_Ethresh[
i]);
497 sprintf(bname,
"TowersAvgnCellsVsPhithresh_%s_%d",
Region.c_str(),
i);
498 sprintf(btitle,
"AvgNumber of cells in each %s Tower Vs #phi with E_Twr>%4.1f GeV ",
Region.c_str(),
m_Ethresh[
i]);
505 sprintf(bname,
"TwrOccupancyVsPhithresh_%s_%d",
Region.c_str(),
i);
506 sprintf(btitle,
"Tower %s Occupancy Vs #phi with E_Twr> %4.1f GeV ",
Region.c_str(),
m_Ethresh[
i]);
514 sprintf(bname,
"AvgEnergyOfTwrVsEtathresh_%d",
i);
515 sprintf(btitle,
"AvgEnergy of Tower Vs #eta for E_Twr> %4.1f GeV",
m_Ethresh[
i]);
522 sprintf(bname,
"AvgEnergyOfTwrVsFullPhithresh_%d",
i);
523 sprintf(btitle,
"AvgEnergy of Tower Vs #phi E_Twr > %4.1f GeV",
m_Ethresh[
i]);
530 sprintf(bname,
"AvgEnergyOfTwrVsEtaPhithresh_%d",
i);
531 sprintf(btitle,
"AvgEnergy of Tower Vs #eta-#phi for E_Twr> %4.1f GeV",
m_Ethresh[
i]);
539 sprintf(bname,
"TransEnergyOfTwrVsEtathresh_%d",
i);
540 sprintf(btitle,
"TransEnergy of Tower Vs #eta for E_Twr> %4.1f GeV",
m_Ethresh[
i]);
546 sprintf(bname,
"TransEnergyOfTwrVsFullPhithresh_%d",
i);
547 sprintf(btitle,
"TransEnergy of Tower Vs #phi E_Twr > %4.1f GeV",
m_Ethresh[
i]);
554 sprintf(bname,
"TransEnergyOfTwrVsEtaPhithresh_%d",
i);
555 sprintf(btitle,
"TransEnergy of Tower Vs #eta-#phi for E_Twr> %4.1f GeV",
m_Ethresh[
i]);
563 sprintf(bname,
"TotalEnergyOfTwrVsEtathresh_%d",
i);
564 sprintf(btitle,
"TotalEnergy of Tower Vs #eta for E_Twr> %4.1f GeV",
m_Ethresh[
i]);
570 sprintf(bname,
"TotalEnergyOfTwrVsFullPhithresh_%d",
i);
571 sprintf(btitle,
"TotalEnergy of Tower Vs #phi E_Twr > %4.1f GeV",
m_Ethresh[
i]);
578 sprintf(bname,
"TotalEnergyOfTwrVsEtaPhithresh_%d",
i);
579 sprintf(btitle,
"TotalEnergy of Tower Vs #eta-#phi for E_Twr> %4.1f GeV",
m_Ethresh[
i]);
586 sprintf(bname,
"TowersAvgnCellsVsEtathresh_%d",
i);
587 sprintf(btitle,
"AvgNumber of cells in each Tower with E_Twr>%4.1f GeV Vs #eta ",
m_Ethresh[
i]);
594 sprintf(bname,
"TowersAvgnCellsVsFullPhithresh_%d",
i);
595 sprintf(btitle,
"AvgNumber of cells in each Tower with E_Twr>%4.1f GeV vs #phi ",
m_Ethresh[
i]);
602 sprintf(bname,
"TowersAvgnCellsVsEtaPhithresh_%d",
i);
603 sprintf(btitle,
"AvgNumber of cells in each Tower with E_Twr>%4.1f GeV Vs #eta-#Phi ",
m_Ethresh[
i]);
611 sprintf(bname,
"TwrOccupancyVsEtathresh_%d",
i);
612 sprintf(btitle,
"Tower Occupancy Vs Eta with E_Twr> %4.1f GeV",
m_Ethresh[
i]);
619 sprintf(bname,
"TwrOccupancyVsFullPhithresh_%d",
i);
620 sprintf(btitle,
"Tower Occupancy Vs #phi with E_Twr> %4.1f GeV",
m_Ethresh[
i]);
627 sprintf(bname,
"TwrOccupancyVsEtaPhithresh_%d",
i);
628 sprintf(btitle,
"Tower Occupancy Vs #eta - #phi with E_Twr> %4.1f GeV",
m_Ethresh[
i]);
640 std::string TheTrigger;
644 std::string TheTowerDir(
"/CaloMonitoring/");
650 std::string title_Fcal0 =
"sum of Towers in Fcal Et Distribution without trigger cut";
662 std::string title_Fcal2 =
"sum of Tower in Fcal Et Distribution passing"+
m_TriggerNames3;
668 m_twrMost_e =
new TH1F(
"TowerMostEnergy",
"Energy in Most Energetic Tower",100,0., 50000.);
669 m_twrMost_e->GetXaxis()->SetTitle(
"Most Energetic Tower Energy");
673 m_twrMost_nCells =
new TH1F(
"TowerMostnCells",
"Number of cells in Most Energetic Tower", 50, 0., 500.);
674 m_twrMost_nCells->GetXaxis()->SetTitle(
"Number of cells in Most Energetic Tower");
678 m_twrMost_etaphi =
new TH2F(
"TowerMostEnergyEtaPhi",
"EtaPhi of Most Energetic Tower", 98, -4.9, 4.9, 64, -3.15, 3.15);
691 if(
sc.isFailure() || !ifPass)
return StatusCode::SUCCESS;
699 if(
sc.isFailure() || !towerCont ) {
708 for ( ;
it!=it_e;++
it) {
730 if (
sc!=StatusCode::SUCCESS){
747 if(
sc!=StatusCode::SUCCESS){
751 return StatusCode::SUCCESS;
782 float ntwrs = towerCont->
size();
788 float etaTwr = twr->
eta();
789 float phiTwr = twr->
phi();
794 float maxCellEnergy=0.;
796 for ( ;cellIter !=cellIterEnd;cellIter++) {
799 float EnergyCell=
cell->energy()/
GeV;
800 if (cellcount == 1 || fabs(EnergyCell) > fabs(maxCellEnergy)) {
801 maxCellEnergy= EnergyCell;
806 if(eTwr > 0.)
ratio = maxCellEnergy/eTwr;
808 if(fabs(etaTwr) < 5.0) {
822 float etaTwr = twr->
eta();
823 float etTwr = twr->
et()/
GeV;
829 if(etaTwr>3.1 && etaTwr<5.0){
835 if(etaTwr<(-3.1) && etaTwr>(-5.0)){
844 float etTwr = twr->
et()/
GeV;
845 float etaTwr = twr->
eta();
846 float phiTwr = twr->
phi();
848 unsigned int reg_i=0;
849 if (fabs(etaTwr)<1.5) reg_i=0;
850 else if (etaTwr > 1.5) reg_i=1;
899 float etaTwr = twr->
eta();
900 float phiTwr = twr->
phi();
902 float etTwr = eTwr/cosh(etaTwr);
905 if(fabs(etaTwr)>3.1 && fabs(etaTwr)<5.0){
928 ATH_MSG_DEBUG(
"CaloTowerVecMon default procHistograms() is starting" );
929 return StatusCode::SUCCESS;