|
ATLAS Offline Software
|
Go to the documentation of this file.
12 "CaloCellGroup of allowed deviation of the pedestal (in ADC counts)");
14 "CaloCellGroup of allowed deviation of the pedestal RMS (in ADC counts)");
17 "CaloCellGroup of allowed deviation of the pedestal (average over one FEB, in ADC counts)");
19 "CaloCellGroup Allowed deviation of the pedestal RMS (average over one FEB, in ADC counts)");
38 ATH_MSG_INFO (
"Initialize Pedestal Tolerances (CaloCellGroup)" ) ;
41 ATH_MSG_ERROR (
"Failed to initialize CaloCellGroup of pedestal tolerances!" ) ;
42 return StatusCode::FAILURE;
45 ATH_MSG_ERROR (
"Configuration error: Expected three pedestal tolerance values (one per gain), got "
47 return StatusCode::FAILURE;
52 ATH_MSG_INFO (
"Initialize Pedestal RMS Tolerances (CaloCellGroup)" ) ;
55 ATH_MSG_ERROR (
"Failed to initialize CaloCellGroup of rms tolerances!" ) ;
56 return StatusCode::FAILURE;
59 ATH_MSG_ERROR (
"Configuration error: Expected three rms tolerance values (one per gain), got "
61 return StatusCode::FAILURE;
66 ATH_MSG_INFO (
"Initialize FEB Pedestal Tolerances (CaloCellGroup)" ) ;
69 ATH_MSG_ERROR (
"Failed to initialize CaloCellGroup of pedestal tolerances!" ) ;
70 return StatusCode::FAILURE;
73 ATH_MSG_ERROR (
"Configuration error: Expected three pedestal tolerance values (one per gain), got "
75 return StatusCode::FAILURE;
79 ATH_MSG_INFO (
"Initialize FEB Pedestal RMS Tolerances (CaloCellGroup)" ) ;
82 ATH_MSG_ERROR (
"Failed to initialize CaloCellGroup of rms tolerances!" ) ;
83 return StatusCode::FAILURE;
86 ATH_MSG_ERROR (
"Configuration error: Expected three rms tolerance values (one per gain), got "
88 return StatusCode::FAILURE;
92 return StatusCode::SUCCESS;
97 if (gain<0 || gain>2) {
102 const float& pedVal=
val.m_Pedestal;
103 const float& pedRef=
ref.m_Pedestal;
105 const float& rmsVal=
val.m_PedestalRMS;
106 const float& rmsRef=
ref.m_PedestalRMS;
117 if (!dataPerFEB || dataPerFEB->
febid!=febid) {
122 dataPerFEB->
pedVal+=pedVal;
123 dataPerFEB->
pedRef+=pedRef;
124 dataPerFEB->
rmsVal+=rmsVal;
125 dataPerFEB->
rmsRef+=rmsRef;
136 if (fabs(pedVal-pedRef)> pedTolerance ||
137 fabs(rmsVal-rmsRef)> rmsTolerance){
140 msg().setf(std::ios::fixed,std::ios::floatfield);
142 <<
" (" <<
ref.m_Pedestal <<
", " <<
val.m_Pedestal-
ref.m_Pedestal <<
" ADC)"
143 <<
" RMS: " <<
val.m_PedestalRMS <<
" (" <<
ref.m_PedestalRMS <<
", "
144 << ((
val.m_PedestalRMS-
ref.m_PedestalRMS)/
ref.m_PedestalRMS)*100 <<
"%)" <<
endmsg;
146 ATH_MSG_DEBUG (
"Pedestal Tolerance: " << pedTolerance <<
" RMS Tolerance:" << rmsTolerance ) ;
162 msg().setf(std::ios::fixed,std::ios::floatfield);
166 dataPerFeb.pedVal/=dataPerFeb.nEntries;
167 dataPerFeb.pedRef/=dataPerFeb.nEntries;
168 dataPerFeb.rmsVal/=dataPerFeb.nEntries;
169 dataPerFeb.rmsRef/=dataPerFeb.nEntries;
176 if (fabs(dataPerFeb.pedVal-dataPerFeb.pedRef)>pedToleranceFEB ||
177 fabs(dataPerFeb.rmsVal-dataPerFeb.rmsRef)>rmsToleranceFEB) {
180 <<
"Average Ped: " << dataPerFeb.pedVal <<
" (" << dataPerFeb.pedRef <<
")"
181 <<
" RMS: " << dataPerFeb.rmsVal <<
" (" << dataPerFeb.rmsRef <<
")" <<
endmsg;
182 ATH_MSG_DEBUG (
"Pdestal FEB Tolerance: " << pedToleranceFEB <<
" RMS FEB Tolerance:" << rmsToleranceFEB ) ;
200 sc=StatusCode::RECOVERABLE;
204 sc=StatusCode::RECOVERABLE;
214 msg().setf(std::ios::fixed,std::ios::floatfield);
CaloCellGroupList m_pedTolerance
const LArOnlineID_Base * m_onlineHelper
unsigned m_nFailedValidation
Number of channels for which vaildateChannel returned false.
const REFCONTAINER * m_reference
Pointer to container with reference values.
std::vector< std::string > m_rmsToleranceFEBInit
Tolerance fro the average pedestal RMS (noise) of one FEB (in ADC counts) (job-Property)
virtual StatusCode preLoop() override
Executed before the loop over all channels to reset global sums.
Gaudi::Details::PropertyBase & declareProperty(Gaudi::Property< T > &t)
const std::vector< float > & getDefaults() const
Conditions-Data class holding LAr Bad Channel or Bad Feb information.
std::vector< std::string > m_pedToleranceInit
Pedestal tolerance (in ADC counts) (job-Property)
std::vector< DataPerFEB > m_vDataPerFEB
bool msgLvl(const MSG::Level lvl) const
unsigned m_nEntriesGlobal
::StatusCode StatusCode
StatusCode definition for legacy code.
CaloCellGroupList m_rmsToleranceFEB
std::vector< std::string > m_pedToleranceFEBInit
Tolerance fro the average pedestal of one FEB (in ADC counts) (job-Property)
virtual StatusCode summary(const LArOnOffIdMapping *cabling, const LArBadChannelCont *bcCont)
Method executed after the loop over all channels The implementation in the base class writes out only...
const CaloCell_Base_ID * m_caloId
std::vector< std::string > m_rmsToleranceInit
Pedestal RMS tolerances as CaloCellGroupList (job-Properties)
CONDITIONSCONTAINER::LArCondObj LArCondObj
LArPedestalValidationAlg(const std::string &name, ISvcLocator *pSvcLocator)
Regular algorithm constructor.
HWIdentifier feb_Id(int barrel_ec, int pos_neg, int feedthrough, int slot) const
Create feb_Id from fields.
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.
virtual StatusCode summary(const LArOnOffIdMapping *cabling, const LArBadChannelCont *bcCont) override
Summary method executed after the loop over all channels.
MSG::Level m_myMsgLvl
Message level for reporting deviations.
const boost::regex ref(r_ef)
unsigned m_maxmessages
Limit for the number of messages about indiviual deviating channels (usd only by derived class)
Algorithm to validate LAr Autocorr;.
CaloCellGroupList m_rmsTolerance
bool febSummary(const LArOnOffIdMapping *cabling, const LArBadChannelCont *bcCont)
Method to compare FEB averages.
const std::string channelDescription(const HWIdentifier &chid, const LArOnOffIdMapping *cabling, const LArBadChannelCont *bcCont, const unsigned gain=99, bool isFeb=false) const
Textual representation of gain and location of a certain cell or FEB.
const std::vector< float > & valuesForCell(const Identifier id)
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.
bool setDefinition(const CaloCell_Base_ID *caloCellId, const std::vector< std::string > &definitions, MsgStream &logStr)
bool m_doFebAverages
wether to compare feb-averages (used only by derived class)
CaloCellGroupList m_pedToleranceFEB