ATLAS Offline Software
LArPedestalValidationAlg.h
Go to the documentation of this file.
1 //Dear emacs, this is -*- c++ -*-
2 
3 /*
4  Copyright (C) 2002-2023 CERN for the benefit of the ATLAS collaboration
5 */
6 
7 
18 #ifndef LARPEDESTALVALIDATIONALG_H
19 #define LARPEDESTALVALIDATIONALG_H
20 
21 #include <vector>
22 #include <string>
23 
27 
28 
30 
31 
41 
42  public:
46  LArPedestalValidationAlg (const std::string& name, ISvcLocator* pSvcLocator);
47 
48  private:
51  bool validateChannel(const LArCondObj& ref, const LArCondObj& val, const HWIdentifier chid, const int gain, const LArOnOffIdMapping *cabling,const LArBadChannelCont *bcCont) override final;
52 
53  virtual LArCondObj getRefObj(const HWIdentifier chid, const int gain) const override final;
54 
56  virtual StatusCode summary(const LArOnOffIdMapping *cabling, const LArBadChannelCont *bcCont) override;
57 
59  virtual StatusCode preLoop() override;
60 
61 
63  //float m_pedTolerance;
65  //float m_rmsTolerance;
66 
68  //Expectes three numbers (one per gain)
69  std::vector<std::string> m_pedToleranceInit;
71 
72 
74  //Expectes three numbers (one per gain)
75  std::vector<std::string> m_rmsToleranceInit;
77 
78 
80  //float m_pedToleranceFEB;
81  std::vector<std::string> m_pedToleranceFEBInit;
83 
85  //float m_rmsToleranceFEB;
86  std::vector<std::string> m_rmsToleranceFEBInit;
88 
89  //The following is for keeping track of entire FEBs
91  bool febSummary(const LArOnOffIdMapping *cabling, const LArBadChannelCont *bcCont);
92 
93 
94  class DataPerFEB {
95  public:
96  DataPerFEB () : chid(0), febid(0), gain(0),
97  pedVal(0.),rmsVal(0.),pedRef(0.),rmsRef(0.), nEntries(0) {}
98  DataPerFEB (const HWIdentifier cid, const HWIdentifier fid, int g) : chid(cid), febid(fid), gain(g),
99  pedVal(0.),rmsVal(0.),pedRef(0.),rmsRef(0.),nEntries(0) {}
100  HWIdentifier chid; //We need to remember the first connected channel for the offline id conversion
102  int gain;
103  double pedVal;
104  double rmsVal;
105  double pedRef;
106  double rmsRef;
107  unsigned nEntries;
108  };
109 
110  std::vector<DataPerFEB> m_vDataPerFEB;
111 
112  //The following is for keeping track of the global average
116 };
117 
118 
119 #endif
120 
LArPedestalValidationAlg::m_rmsGlobalRef
double m_rmsGlobalRef
Definition: LArPedestalValidationAlg.h:114
LArPedestalValidationAlg::DataPerFEB::nEntries
unsigned nEntries
Definition: LArPedestalValidationAlg.h:107
LArPedestalValidationAlg::m_pedTolerance
CaloCellGroupList m_pedTolerance
Definition: LArPedestalValidationAlg.h:70
LArPedestalValidationAlg::m_rmsToleranceFEBInit
std::vector< std::string > m_rmsToleranceFEBInit
Tolerance fro the average pedestal RMS (noise) of one FEB (in ADC counts) (job-Property)
Definition: LArPedestalValidationAlg.h:86
LArPedestalValidationAlg::DataPerFEB::rmsVal
double rmsVal
Definition: LArPedestalValidationAlg.h:104
LArPedestalValidationAlg::DataPerFEB::DataPerFEB
DataPerFEB()
Definition: LArPedestalValidationAlg.h:96
LArPedestalValidationAlg::preLoop
virtual StatusCode preLoop() override
Executed before the loop over all channels to reset global sums.
Definition: LArPedestalValidationAlg.cxx:28
LArBadXCont
Conditions-Data class holding LAr Bad Channel or Bad Feb information.
Definition: LArBadChannelCont.h:28
LArPedestalValidationAlg::m_pedGlobalVal
double m_pedGlobalVal
Definition: LArPedestalValidationAlg.h:113
CaloCondBlobAlgs_fillNoiseFromASCII.gain
gain
Definition: CaloCondBlobAlgs_fillNoiseFromASCII.py:110
ReadCellNoiseFromCool.cabling
cabling
Definition: ReadCellNoiseFromCool.py:154
LArPedestalValidationAlg::m_pedToleranceInit
std::vector< std::string > m_pedToleranceInit
Pedestal tolerance (in ADC counts) (job-Property)
Definition: LArPedestalValidationAlg.h:69
LArPedestalValidationAlg::m_vDataPerFEB
std::vector< DataPerFEB > m_vDataPerFEB
Definition: LArPedestalValidationAlg.h:110
CaloCellGroupList
Definition: CaloCellGroup.h:59
HWIdentifier
Definition: HWIdentifier.h:13
LArPedestalValidationAlg::m_rmsGlobalVal
double m_rmsGlobalVal
Definition: LArPedestalValidationAlg.h:113
LArPedestalValidationAlg::m_nEntriesGlobal
unsigned m_nEntriesGlobal
Definition: LArPedestalValidationAlg.h:115
LArPedestalValidationAlg::DataPerFEB::gain
int gain
Definition: LArPedestalValidationAlg.h:102
python.CaloCondTools.g
g
Definition: CaloCondTools.py:15
EL::StatusCode
::StatusCode StatusCode
StatusCode definition for legacy code.
Definition: PhysicsAnalysis/D3PDTools/EventLoop/EventLoop/StatusCode.h:22
LArPedestalValidationAlg::m_rmsToleranceFEB
CaloCellGroupList m_rmsToleranceFEB
Definition: LArPedestalValidationAlg.h:87
LArPedestalValidationAlg::m_pedToleranceFEBInit
std::vector< std::string > m_pedToleranceFEBInit
Tolerance fro the average pedestal of one FEB (in ADC counts) (job-Property)
Definition: LArPedestalValidationAlg.h:81
LArPedestalValidationAlg::m_rmsToleranceInit
std::vector< std::string > m_rmsToleranceInit
Pedestal RMS tolerances as CaloCellGroupList (job-Properties)
Definition: LArPedestalValidationAlg.h:75
LArCalibValidationAlg::LArCondObj
CONDITIONSCONTAINER::LArCondObj LArCondObj
Definition: LArCalibValidationAlg.h:80
LArPedestalValidationAlg::LArPedestalValidationAlg
LArPedestalValidationAlg(const std::string &name, ISvcLocator *pSvcLocator)
Regular algorithm constructor.
Definition: LArPedestalValidationAlg.cxx:8
LArPedestalValidationAlg::DataPerFEB::pedVal
double pedVal
Definition: LArPedestalValidationAlg.h:103
LArPedestalValidationAlg::validateChannel
bool validateChannel(const LArCondObj &ref, const LArCondObj &val, const HWIdentifier chid, const int gain, const LArOnOffIdMapping *cabling, const LArBadChannelCont *bcCont) override final
Method to validate the pedestal single readout channels.
Definition: LArPedestalValidationAlg.cxx:95
LArPedestalValidationAlg::DataPerFEB::DataPerFEB
DataPerFEB(const HWIdentifier cid, const HWIdentifier fid, int g)
Definition: LArPedestalValidationAlg.h:98
LArPedestalValidationAlg::summary
virtual StatusCode summary(const LArOnOffIdMapping *cabling, const LArBadChannelCont *bcCont) override
Summary method executed after the loop over all channels.
Definition: LArPedestalValidationAlg.cxx:196
LArPedestalValidationAlg::DataPerFEB::rmsRef
double rmsRef
Definition: LArPedestalValidationAlg.h:106
name
std::string name
Definition: Control/AthContainers/Root/debug.cxx:221
LArPedestalValidationBase
LArCalibValidationAlg< LArPedestalComplete, ILArPedestal > LArPedestalValidationBase
Definition: LArPedestalValidationAlg.h:29
LArPedestalValidationAlg::DataPerFEB::febid
HWIdentifier febid
Definition: LArPedestalValidationAlg.h:101
LArPedestalValidationAlg::DataPerFEB::chid
HWIdentifier chid
Definition: LArPedestalValidationAlg.h:100
CaloCellGroup.h
LArPedestalValidationAlg
Definition: LArPedestalValidationAlg.h:40
LArPedestalValidationAlg::m_pedGlobalRef
double m_pedGlobalRef
Definition: LArPedestalValidationAlg.h:114
ref
const boost::regex ref(r_ef)
Pythia8_RapidityOrderMPI.val
val
Definition: Pythia8_RapidityOrderMPI.py:14
LArPedestalComplete.h
LArCalibValidationAlg
Algorithm to validate LAr Autocorr;.
Definition: LArCalibValidationAlg.h:47
LArPedestalValidationAlg::m_rmsTolerance
CaloCellGroupList m_rmsTolerance
Definition: LArPedestalValidationAlg.h:76
LArPedestalValidationAlg::febSummary
bool febSummary(const LArOnOffIdMapping *cabling, const LArBadChannelCont *bcCont)
Method to compare FEB averages.
Definition: LArPedestalValidationAlg.cxx:157
LArCalibValidationAlg.h
LArPedestalValidationAlg::getRefObj
virtual LArCondObj getRefObj(const HWIdentifier chid, const int gain) const override final
Method implmented in derived class to get the reference object from ref-container.
Definition: LArPedestalValidationAlg.cxx:223
LArPedestalValidationAlg::DataPerFEB::pedRef
double pedRef
Definition: LArPedestalValidationAlg.h:105
LArPedestalValidationAlg::DataPerFEB
Definition: LArPedestalValidationAlg.h:94
LArPedestalValidationAlg::m_pedToleranceFEB
CaloCellGroupList m_pedToleranceFEB
Definition: LArPedestalValidationAlg.h:82
LArOnOffIdMapping
Definition: LArOnOffIdMapping.h:20