|
ATLAS Offline Software
|
Go to the documentation of this file.
12 "Enable detection of Pulse timeShift");
14 "CaloCellGroup of allowed deviation of the amplitude (in permills)");
16 "CaloCellGroup of llowed deviation of the FWHM (in permills)");
18 "CaloCellGroup of llowed deviation of the amplitude (average over one FEB, in permills)");
20 "CaloCellGroup of allowed deviation of the FWHM (average over one FEB, in permills)");
34 ATH_MSG_INFO (
"Initialize Amplitude Tolerances (CaloCellGroup)" ) ;
37 ATH_MSG_ERROR (
"Failed to initialize CaloCellGroup of amplitude tolerances!" ) ;
38 return StatusCode::FAILURE;
41 ATH_MSG_ERROR (
"Configuration error: Expected three amplitude tolerance values (one per gain), got "
43 return StatusCode::FAILURE;
49 ATH_MSG_INFO (
"Initialize FWHM Tolerances (CaloCellGroup)" ) ;
52 ATH_MSG_ERROR (
"Failed to initialize CaloCellGroup of FWHM tolerances!" ) ;
53 return StatusCode::FAILURE;
56 ATH_MSG_ERROR (
"Configuration error: Expected three FWHM tolerance values (one per gain), got "
58 return StatusCode::FAILURE;
64 ATH_MSG_INFO (
"Initialize FEB Amplitude Tolerances (CaloCellGroup)" ) ;
67 ATH_MSG_ERROR (
"Failed to initialize CaloCellGroup of FEB amplitude tolerances!" ) ;
68 return StatusCode::FAILURE;
71 ATH_MSG_ERROR (
"Configuration error: Expected three FEB amplitude tolerance values (one per gain), got "
73 return StatusCode::FAILURE;
79 ATH_MSG_INFO (
"Initialize FEB FWHM Tolerances (CaloCellGroup)" ) ;
82 ATH_MSG_ERROR (
"Failed to initialize CaloCellGroup of FEB FWHM tolerances!" ) ;
83 return StatusCode::FAILURE;
86 ATH_MSG_ERROR (
"Configuration error: Expected three FEB FWHM tolerance values (one per gain), got "
88 return StatusCode::FAILURE;
92 return StatusCode::SUCCESS;
97 if (gain<0 || gain>2) {
119 if (
val.size()>0 &&
ref.size()>0){
136 if (!dataPerFEB || dataPerFEB->
febid!=febid) {
141 dataPerFEB->
ampVal+=ampVal;
142 dataPerFEB->
ampRef+=ampRef;
155 if (fabs(TmaxVal-TmaxRef)> TMaxshift &&
m_timeShift==
true) {
163 if (1000*fabs(ampVal-ampRef)/ampRef > ampTolerance || 1000*fabs(fwhmVal-fwhmRef)/fwhmRef > fwhmTolerance) {
167 msg().setf(std::ios::fixed,std::ios::floatfield);
169 <<
", " << 100.*(ampVal-ampRef)/ampRef <<
" %)"
170 <<
" FWHM: " << fwhmVal <<
" ( " << fwhmRef <<
", " << 100*(fwhmVal-fwhmRef)/fwhmVal <<
" %)" <<
endmsg;
171 ATH_MSG_DEBUG (
"Amplitude FEB tolerance: " << ampTolerance <<
", FWHM FEB tolerance: " << fwhmTolerance ) ;
186 msg().setf(std::ios::fixed,std::ios::floatfield);
189 dataPerFeb.ampVal/=dataPerFeb.nEntries;
190 dataPerFeb.ampRef/=dataPerFeb.nEntries;
191 dataPerFeb.fwhmVal/=dataPerFeb.nEntries;
192 dataPerFeb.fwhmRef/=dataPerFeb.nEntries;
198 if (fabs(dataPerFeb.ampVal-dataPerFeb.ampRef)/dataPerFeb.ampRef*1000>ampToleranceFEB ||
199 fabs(dataPerFeb.fwhmVal-dataPerFeb.fwhmRef)/dataPerFeb.fwhmRef*1000>fwhmToleranceFEB) {
200 msg() <<
m_myMsgLvl <<
"Deviating! " <<
channelDescription(dataPerFeb.febid,
cabling,bcCont,dataPerFeb.gain,
true)<<
"Average Amp: " << dataPerFeb.ampVal <<
" (" << dataPerFeb.ampRef <<
")"
201 <<
" FWHM: " << dataPerFeb.fwhmVal <<
" (" << dataPerFeb.fwhmRef <<
")" <<
endmsg;
203 ATH_MSG_DEBUG (
"Amplitude FEB tolerance: " << ampToleranceFEB <<
", FWHM FEB tolerance: " << fwhmToleranceFEB ) ;
220 sc=StatusCode::RECOVERABLE;
223 sc=StatusCode::RECOVERABLE;
CaloCellGroupList m_fwhmTolerance
CaloCellGroupList m_ampToleranceFEB
unsigned m_nEntriesGlobal
const LArOnlineID_Base * m_onlineHelper
std::vector< std::string > m_ampToleranceInit
Amplitude tolerance (in permills) (job-Property)
unsigned m_nFailedValidation
Number of channels for which vaildateChannel returned false.
double getWidth(const LArWave &theWave) const
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.
const double & getDt() const
delta time
bool msgLvl(const MSG::Level lvl) const
CaloCellGroupList m_ampTolerance
double getMaxAmp(const LArWave &theWave) const
unsigned int getMax(const LArWave &theWave) const
return index of maximum sample
bool febSummary(const LArOnOffIdMapping *cabling, const LArBadChannelCont *bcCont)
Method to compare FEB averages.
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.
::StatusCode StatusCode
StatusCode definition for legacy code.
CaloCellGroupList m_fwhmToleranceFEB
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_fwhmToleranceFEBInit
Tolerance for the average FWHM of one FEB (in permills) (job-Property)
CONDITIONSCONTAINER::LArCondObj LArCondObj
HWIdentifier feb_Id(int barrel_ec, int pos_neg, int feedthrough, int slot) const
Create feb_Id from fields.
virtual StatusCode preLoop() override
Executed before the loop over all channels to reset global sums.
MSG::Level m_myMsgLvl
Message level for reporting deviations.
std::vector< std::string > m_fwhmToleranceInit
FWHM tolerance (in permills) (job-Property)
LArWaveHelper m_waveHelper
virtual StatusCode summary(const LArOnOffIdMapping *cabling, const LArBadChannelCont *bcCont) override
Summary method executed after the loop over all channels.
const boost::regex ref(r_ef)
std::vector< DataPerFEB > m_vDataPerFEB
unsigned m_maxmessages
Limit for the number of messages about indiviual deviating channels (usd only by derived class)
LArCaliWaveValidationAlg(const std::string &name, ISvcLocator *pSvcLocator)
Regular algorithm constructor.
Algorithm to validate LAr Autocorr;.
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)
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)
std::vector< std::string > m_ampToleranceFEBInit
Tolerance for the average amplitude of one FEB (in permills) (job-Property)