ATLAS Offline Software
CaloBaselineMonAlg.h
Go to the documentation of this file.
1 /*
2  Copyright (C) 2002-2021 CERN for the benefit of the ATLAS collaboration
3 */
4 
5 // ********************************************************************
6 // NAME: CaloBaselineMonAlg.h
7 //
8 // Based on code from Benjamin Trocme (LPSC Grenoble) 01/2018
9 //
10 // ********************************************************************
11 
12 #ifndef CALOBASELINEMONALG_H
13 #define CALOBASELINEMONALG_H
14 
15 #include "CaloMonAlgBase.h"
16 
17 #include "GaudiKernel/ToolHandle.h"
18 #include "Identifier/Identifier.h"
23 
25  public:
26 
27  CaloBaselineMonAlg(const std::string& name, ISvcLocator* pSvcLocator);
28  virtual ~CaloBaselineMonAlg(){};
29 
30  virtual StatusCode initialize() override final;
31  virtual StatusCode fillHistograms(const EventContext& ctx) const override final;
32 
33  private:
34 
36 
37  // CaloCellContainer name
38  SG::ReadHandleKey<CaloCellContainer> m_cellContainerKey{this,"CellContainer","AllCalo","Input CaloCellContainer key"};
39 
40  SG::ReadCondHandleKey<BunchCrossingCondData> m_bcDataKey {this, "BunchCrossingCondDataKey", "BunchCrossingData" ,"SG Key of BunchCrossing CDO"};
41 
42  Gaudi::Property<std::string> m_MonGroupName {this, "MonGroupName", "CaloBaselineGroup"};
43  // LHC BCID caracteristics. Do not change it
44  const float m_BCID0_min = 0.;
45  const float m_BCID0_max = 3563.;
46  const int m_BCID0_nbins = 3563;
47  // Minimal BCID distance away from a bunch train to compute pedestal baseline
48  // If equal to negative, do not compute pedestal baseline in inter train
49  Gaudi::Property<int> m_pedestalMon_BCIDmin{this, "pedestalMon_BCIDmin", 25};
50  // Maximal BCID distance away from the start of bunch train to monitor CaloLumiBCIDTool
51  // If equal to negative, do not monitor CaloLumiBCIDTool
52  Gaudi::Property<int> m_bcidtoolMon_BCIDmax{this, "bcidtoolMon_BCIDmax", 144};
53  // Definition of eta range as a function of partitions
54  Gaudi::Property<std::vector<float> > m_etaMax{this, "maximumEta", {}};
55  Gaudi::Property<std::vector<float> > m_etaMin{this, "minimumEta", {}};
56  Gaudi::Property<std::vector<uint> > m_nbOfEtaBins{this, "nbOfEtaBins", {}};
57  // List of partitions given in job options;
58  // Can be : EM, HEC, FCal, HEC+FCal
59  Gaudi::Property<std::vector<std::string> > m_partNames{this, "partionList", {}};
60 
61  std::vector<float> m_etaBinWidth;
62  std::vector<float> m_inv_etaBinWidth;
63 
64  // Boolean to switch off/on monitoring - Derived from the two above properties
67 
68  /* Histogram grouping (part)(ieta) */
69  std::vector<std::vector<int> >m_histoGroups;
70 
71  // Control plots of BCID filled for each type
72  //TH1I_LW* m_h1_BCID_bcidtoolMon;
73  //TH1I_LW* m_h1_BCID_pedestalMon;
74 
75  /*
76  struct partitionHistos
77  {
78  TProfile_LW* hProf_bcidtoolMon_vs_Eta=nullptr;
79  TProfile_LW* hProf_bcidtoolMon_vs_LB=nullptr;
80  std::vector<TProfile_LW*> hProf_bcidtoolMon_vs_EtaBCID;
81 
82  TProfile_LW* hProf_pedestalMon_vs_Eta=nullptr;
83  TProfile_LW* hProf_pedestalMon_vs_LB=nullptr;
84  std::vector<TProfile_LW*> hProf_pedestalMon_vs_EtaBCID;
85  };
86  */
87 
88  // Map between the 4 partition and the m_partNames
89  // Filled at initialize
90  std::vector<int> m_partMap;
91 
92  // std::vector<partitionHistos> m_partHistos;
93 
94 };
95 
96 #endif // CaloBaselineMonAlg_H
ReadHandleKey.h
Property holding a SG store/key/clid from which a ReadHandle is made.
SG
Forward declaration.
Definition: CaloCellPacker_400_500.h:32
CaloBaselineMonAlg::m_histoGroups
std::vector< std::vector< int > > m_histoGroups
Definition: CaloBaselineMonAlg.h:69
CaloBaselineMonAlg::m_bcDataKey
SG::ReadCondHandleKey< BunchCrossingCondData > m_bcDataKey
Definition: CaloBaselineMonAlg.h:40
CaloBaselineMonAlg::m_etaMax
Gaudi::Property< std::vector< float > > m_etaMax
Definition: CaloBaselineMonAlg.h:54
const
bool const RAWDATA *ch2 const
Definition: LArRodBlockPhysicsV0.cxx:560
CaloBaselineMonAlg::m_inv_etaBinWidth
std::vector< float > m_inv_etaBinWidth
Definition: CaloBaselineMonAlg.h:62
CaloBaselineMonAlg::fillHistograms
virtual StatusCode fillHistograms(const EventContext &ctx) const override final
adds event to the monitoring histograms
Definition: CaloBaselineMonAlg.cxx:74
CaloMonAlgBase.h
CaloBaselineMonAlg::m_BCID0_nbins
const int m_BCID0_nbins
Definition: CaloBaselineMonAlg.h:46
CaloBaselineMonAlg::m_nbOfEtaBins
Gaudi::Property< std::vector< uint > > m_nbOfEtaBins
Definition: CaloBaselineMonAlg.h:56
CaloBaselineMonAlg::m_BCID0_max
const float m_BCID0_max
Definition: CaloBaselineMonAlg.h:45
CaloBaselineMonAlg::m_bcidtoolMon_BCIDmax
Gaudi::Property< int > m_bcidtoolMon_BCIDmax
Definition: CaloBaselineMonAlg.h:52
EL::StatusCode
::StatusCode StatusCode
StatusCode definition for legacy code.
Definition: PhysicsAnalysis/D3PDTools/EventLoop/EventLoop/StatusCode.h:22
CaloBaselineMonAlg::m_BCID0_min
const float m_BCID0_min
Definition: CaloBaselineMonAlg.h:44
CaloBaselineMonAlg::m_partNames
Gaudi::Property< std::vector< std::string > > m_partNames
Definition: CaloBaselineMonAlg.h:59
CaloBaselineMonAlg
Definition: CaloBaselineMonAlg.py:1
ReadCondHandleKey.h
CaloBaselineMonAlg::~CaloBaselineMonAlg
virtual ~CaloBaselineMonAlg()
Definition: CaloBaselineMonAlg.h:28
private
#define private
Definition: DetDescrConditionsDict_dict_fixes.cxx:13
name
std::string name
Definition: Control/AthContainers/Root/debug.cxx:221
CaloBaselineMonAlg::m_etaBinWidth
std::vector< float > m_etaBinWidth
Definition: CaloBaselineMonAlg.h:61
CaloCellContainer
Container class for CaloCell.
Definition: CaloCellContainer.h:55
CaloBaselineMonAlg::m_bool_pedestalMon
bool m_bool_pedestalMon
Definition: CaloBaselineMonAlg.h:65
CaloBaselineMonAlg::initialize
virtual StatusCode initialize() override final
initialize
Definition: CaloBaselineMonAlg.cxx:27
SG::ReadCondHandleKey< BunchCrossingCondData >
CaloBaselineMonAlg::m_cellContainerKey
SG::ReadHandleKey< CaloCellContainer > m_cellContainerKey
Definition: CaloBaselineMonAlg.h:38
CaloBaselineMonAlg::m_MonGroupName
Gaudi::Property< std::string > m_MonGroupName
Definition: CaloBaselineMonAlg.h:42
CaloBaselineMonAlg::retrieveTools
StatusCode retrieveTools()
CaloBaselineMonAlg::m_partMap
std::vector< int > m_partMap
Definition: CaloBaselineMonAlg.h:90
CaloIdManager.h
BunchCrossingCondData.h
Replaces the BunchCrossing AlgTool used in run1/2.
CaloBaselineMonAlg::CaloBaselineMonAlg
CaloBaselineMonAlg(const std::string &name, ISvcLocator *pSvcLocator)
Definition: CaloBaselineMonAlg.cxx:18
CaloBaselineMonAlg::m_pedestalMon_BCIDmin
Gaudi::Property< int > m_pedestalMon_BCIDmin
Definition: CaloBaselineMonAlg.h:49
CaloMonAlgBase
Definition: CaloMonAlgBase.py:1
CaloBaselineMonAlg::m_etaMin
Gaudi::Property< std::vector< float > > m_etaMin
Definition: CaloBaselineMonAlg.h:55
CaloBaselineMonAlg::m_bool_bcidtoolMon
bool m_bool_bcidtoolMon
Definition: CaloBaselineMonAlg.h:66