ATLAS Offline Software
TileFatherMonTool.h
Go to the documentation of this file.
1 /*
2  Copyright (C) 2002-2023 CERN for the benefit of the ATLAS collaboration
3 */
4 
5 // ********************************************************************
6 //
7 // NAME: TileFatherMonTool.h
8 // PACKAGE: TileMonitoring
9 //
10 // AUTHOR: Luca Fiorini (Luca.Fiorini@cern.ch)
11 //
12 // July 2006
13 // ********************************************************************
14 #ifndef TILEMONITORING_TILEFATHERMONTOOL_H
15 #define TILEMONITORING_TILEFATHERMONTOOL_H
16 
17 #include "TilePaterMonTool.h"
18 
20 
21 class CaloCell;
22 class TriggerInfo;
23 
24 namespace Trig {
25  class TrigDecisionTool;
26 }
27 
32 class ATLAS_NOT_THREAD_SAFE TileFatherMonTool: public TilePaterMonTool // deprecated: ATLASRECTS-7259
33 {
34 
35  public:
36 
37  TileFatherMonTool(const std::string & type, const std::string & name,
38  const IInterface* parent);
39 
40 
41  virtual ~TileFatherMonTool();
42 
43  virtual StatusCode initialize() override;
44 
45  int getPartition( const CaloCell* cell );
46 
47  void get_eventTrigs(uint32_t lvl1info);
48 
49  //method to set an histogram axis bin labels according to a vector of strings
50  template<class T>
51  void SetBinLabel(T* axis, const std::vector<std::string>& labels);
52 
53  //method to set an histogram axis bin labels according to an array of strings
54  template<class T>
55  void SetBinLabel(T* axis, const std::string* labels, int nLabels);
56 
57  // Method to move bins of TProfile histogra,
58  // Used for online to display only latest 100 LB
59  void ShiftTprofile(TProfile *, int);
60 
63  inline int vecIndx(unsigned int i) {
64  return m_activeTrigs[ m_eventTrigs[i] ];
65  }
66 
67 
71  inline uint32_t getL1info() { return m_lvl1info;};
72 
74  inline uint32_t getEvtNum() { return m_evtNum;};
75 
77  inline uint32_t getLumiBlock() { return m_lumiBlock;};
78 
80  inline uint32_t getEvtBCID() { return m_evtBCID;};
81 
83  inline uint32_t getRunNum() { return m_runNum;};
84 
86  std::string getRunNumStr();
87 
89  inline uint32_t gettileFlag() { return m_tileFlag;};
90 
92  inline uint32_t gettileError_error() { return m_tileError_error;};
93 
96  void fillEvtInfo();
97 
99  enum Sampling {
100  SampA =0,
101  SampB =1,
102  SampD =2,
103  SampE =3,
104  AllSamp =4,
105  TotalSamp =5
106  };
107 
109  enum Partitions {
110  PartEBA = 0,
111  PartLBA = 1,
112  PartLBC = 2,
113  PartEBC = 3,
114  NumPart = 4,
115  NPartHisto = 5
116  };
117 
119  enum L1Trig {
120  Trig_b0 = 0,
121  Trig_b1 = 1,
122  Trig_b2 = 2,
123  Trig_b3 = 3,
124  Trig_b4 = 4,
125  Trig_b5 = 5,
126  Trig_b6 = 6,
127  Trig_b7 = 7,
128  AnyTrig = 8,
129  NTrigHisto = 9
130  };
131 
132 
133  std::string m_SampStrNames[TotalSamp] ;
134  std::string m_PartNames[NPartHisto] ;
135  std::string m_GainNames[2] ;
136  std::string m_TrigNames[NTrigHisto] ;
137 
138  // conversion from ROS index to partition index
139  int m_ros2partition[NPartHisto];
140 
141  // conversion from partition index to ROS index
142  int m_partition2ros[NPartHisto];
143 
144  // conversion from partition index to ROS index
145 
152  int m_activeTrigs[9]={0};
153 
154  uint32_t m_lvl1info{};
155  uint32_t m_evtNum{};
156  uint32_t m_lumiBlock{};
157  uint32_t m_evtBCID{};
158  uint32_t m_runNum{};
159  uint32_t m_tileFlag{};
160  uint32_t m_tileError_error{};
161  ToolHandle<Trig::TrigDecisionTool> m_trigDec;
162 
164  std::vector<int> m_eventTrigs;
165 
166  static bool m_is_collision;
167  static unsigned int m_lastevent;
168  static float m_time_difference;
169 
170 protected:
171 
172 private:
173  void checkIsCollision(); //moved to private. Should not be called from the derived classes.
175  std::string m_cellsContainerID;
176  std::vector<unsigned int> m_fillHistogramsForL1Triggers;
177  std::vector<bool> m_allowedL1TriggerBits;
178 };
179 
180 #endif // TILEMONITORING_TILEFATHERMONTOOL_H
TileFatherMonTool::m_allowedL1TriggerBits
std::vector< bool > m_allowedL1TriggerBits
Definition: TileFatherMonTool.h:177
TileFatherMonTool::getEvtNum
uint32_t getEvtNum()
Method to get the event number:
Definition: TileFatherMonTool.h:74
TileFatherMonTool::m_fillHistogramsForL1Triggers
std::vector< unsigned int > m_fillHistogramsForL1Triggers
Definition: TileFatherMonTool.h:176
ReadCellNoiseFromCool.cell
cell
Definition: ReadCellNoiseFromCool.py:53
TileFatherMonTool::m_MBTSCellContainerID
std::string m_MBTSCellContainerID
Definition: TileFatherMonTool.h:174
TilePaterMonTool::initialize
virtual StatusCode initialize() override
Definition: TilePaterMonTool.cxx:101
Trig
The common trigger namespace for trigger analysis tools.
Definition: LArCellMonAlg.h:33
ATLAS_NOT_THREAD_SAFE
#define ATLAS_NOT_THREAD_SAFE
getNoisyStrip() Find noisy strips from hitmaps and write out into xml/db formats
Definition: checker_macros.h:212
xAOD::uint32_t
setEventNumber uint32_t
Definition: EventInfo_v1.cxx:127
yodamerge_tmp.axis
list axis
Definition: yodamerge_tmp.py:241
TilePaterMonTool
Base class for tilecal calibration monitoring tools.
Definition: TilePaterMonTool.h:50
TileFatherMonTool
Base class for TileCal online monitoring tools in physics runs.
Definition: TileFatherMonTool.h:33
TileFatherMonTool::m_time_difference
static float m_time_difference
Definition: TileFatherMonTool.h:168
TileFatherMonTool::m_cellsContainerID
std::string m_cellsContainerID
Definition: TileFatherMonTool.h:175
TilePaterMonTool.h
TileFatherMonTool::getLumiBlock
uint32_t getLumiBlock()
Method to get the lumi_block word:
Definition: TileFatherMonTool.h:77
beamspotnt.labels
list labels
Definition: bin/beamspotnt.py:1447
lumiFormat.i
int i
Definition: lumiFormat.py:85
python.TrigEgammaMonitorHelper.TProfile
def TProfile(*args, **kwargs)
Definition: TrigEgammaMonitorHelper.py:81
TileFatherMonTool::m_trigDec
ToolHandle< Trig::TrigDecisionTool > m_trigDec
Definition: TileFatherMonTool.h:161
EL::StatusCode
::StatusCode StatusCode
StatusCode definition for legacy code.
Definition: PhysicsAnalysis/D3PDTools/EventLoop/EventLoop/StatusCode.h:22
TileFatherMonTool::L1Trig
L1Trig
enum defining L1 trigger bits
Definition: TileFatherMonTool.h:119
TileFatherMonTool::getEvtBCID
uint32_t getEvtBCID()
Method to get the event BCID:
Definition: TileFatherMonTool.h:80
test_pyathena.parent
parent
Definition: test_pyathena.py:15
TileFatherMonTool::vecIndx
int vecIndx(unsigned int i)
Method that returns the histogram index corresponding to trigger 'i'.
Definition: TileFatherMonTool.h:63
TileFatherMonTool::m_lastevent
static unsigned int m_lastevent
Definition: TileFatherMonTool.h:167
TileFatherMonTool::m_is_collision
static bool m_is_collision
Definition: TileFatherMonTool.h:166
TriggerInfo
This class contains trigger related information.
Definition: TriggerInfo.h:77
name
std::string name
Definition: Control/AthContainers/Root/debug.cxx:221
TileFatherMonTool::gettileError_error
uint32_t gettileError_error()
Method to get the tile Error:
Definition: TileFatherMonTool.h:92
TileFatherMonTool::gettileFlag
uint32_t gettileFlag()
Method to get the tile Flag:
Definition: TileFatherMonTool.h:89
CaloCell
Data object for each calorimeter readout cell.
Definition: CaloCell.h:57
TileFatherMonTool::Sampling
Sampling
enum defining TileCal cell samples
Definition: TileFatherMonTool.h:99
python.CaloScaleNoiseConfig.type
type
Definition: CaloScaleNoiseConfig.py:78
TileFatherMonTool::Partitions
Partitions
enum defining TileCal partitions
Definition: TileFatherMonTool.h:109
LArSCvsRawChannelConfig.TrigDecisionTool
TrigDecisionTool
Definition: LArSCvsRawChannelConfig.py:83
TileFatherMonTool::getL1info
uint32_t getL1info()
Method to get the Level1 Trigger word: 32bit long, but only 8 bit are used If no trigger word or empt...
Definition: TileFatherMonTool.h:71
checker_macros.h
Define macros for attributes used to control the static checker.
TileFatherMonTool::getRunNum
uint32_t getRunNum()
Method to get the run Number:
Definition: TileFatherMonTool.h:83
TSU::T
unsigned long long T
Definition: L1TopoDataTypes.h:35
TileFatherMonTool::m_eventTrigs
std::vector< int > m_eventTrigs
Vector containing the list of triggers passed by the event.
Definition: TileFatherMonTool.h:164