|
ATLAS Offline Software
|
Go to the documentation of this file.
39 Tile::MAX_ROS - 1, Tile::MAX_DRAWER);
42 Tile::MAX_ROS - 1, Tile::MAX_DRAWER);
46 Tile::MAX_ROS - 1, Tile::MAX_DRAWER);
61 return StatusCode::SUCCESS;
88 std::vector<int> dmus;
98 int nBadConsecutiveModules = isTileErrorState ?
MAX_DMU : ((tileEventInfoFlag >>
MAX_DMU) & 0xF);
102 if (isTileErrorState) {
106 fill(
"TileConsecutiveBadModules", monitoredConsecutiveBad);
107 fill(
"TileConsecutiveBadModulesLB", monitoredConsecutiveBad,
lumiBlock);
116 bool physicRun = (l1TriggerType == 0) || (((l1TriggerType >> Trig_b7) & 1) == 1);
125 ATH_MSG_WARNING(
"Tile raw channel units are not ADC counts => will not check neagative amplitudes!" );
130 int fragId = rawChannelCollection->identify();
131 int drawer = (fragId & 0x3F);
132 int ros = fragId >> 8;
144 float pedestal = rawChannel->pedestal();
145 float quality = std::abs(rawChannel->quality());
146 float amplitude = rawChannel->amplitude();
147 float time = rawChannel->uncorrTime();
187 int channelDividedBy2 =
channel >> 1;
190 && (channelDividedBy2 == 0 || channelDividedBy2 == 6 || channelDividedBy2 == 9))
200 if (pedestal > 100000. && digitsContainer) {
205 if (digitsCollection) {
207 for (
const TileDigits* tile_digits : *digitsCollection) {
213 <<
" " << Tile::getDrawerString(
ros,
drawer)
214 << std::setfill(
' ') << std::setw(3) <<
channel
215 << ((
gain) ?
" HG" :
" LG") <<
" negative amplitude: "
216 << std::setprecision(2) << std::fixed << std::setw(7)
217 << amplitude <<
" Samples: " << std::setprecision(0);
219 std::vector<float> samples = tile_digits->samples();
220 for (
float sample : samples) {
241 if (digitsContainer) {
246 int fragId = digitsCollection->identify();
247 int drawer = (fragId & 0x3F);
248 int ros = fragId >> 8;
253 if (l1TriggerType != digitsCollection->getLvl1Type()) {
254 fill(
"TileMismatchedL1TriggerType", monitoredModule, monitoredROS);
257 if (l1TriggerType == 0
x82) {
259 unsigned int nBadOrDisconnectedChannels(0);
264 ++nBadOrDisconnectedChannels;
268 unsigned int nRequiredChannels(Tile::MAX_CHAN - nBadOrDisconnectedChannels);
269 if (digitsCollection->size() < nRequiredChannels) {
270 fill(
"TileNoAllDigits", monitoredModule, monitoredROS);
271 ATH_MSG_VERBOSE(
"No All channels with digits (Trigger Type: 0x82) in module "
273 <<
", present channels: " << digitsCollection->size()
274 <<
", required channels: " << nRequiredChannels);
283 for (
const TileDigits* tile_digits : *digitsCollection) {
302 <<
" " << Tile::getDrawerString(
ros,
drawer)
303 << std::setfill(
' ') << std::setw(3) <<
channel
304 << ((
gain) ?
" HG" :
" LG")
307 std::vector<float> samples = tile_digits->samples();
308 for (
float sample : samples) {
326 bool fillCorruptedData(
false);
328 if (corruptedData[
error] > 0
u) {
329 fillCorruptedData =
true;
330 for (
unsigned int dmu = 0
u; dmu < 16
u; ++dmu) {
331 if (corruptedData[
error] & (1
u << dmu)) {
338 if (fillCorruptedData) {
345 std::vector<int> rosWithGloblaCRC;
346 std::vector<int> drawerWithGlobalCRC;
349 for (
unsigned int ros = 1;
ros < Tile::MAX_ROS; ++
ros) {
353 bool isGoodModuleDCS(
true);
357 fractionOfBadDMUs = -1.0;
358 isGoodModuleDCS =
false;
364 if (
status & (TileFragStatus::ALL_FF | TileFragStatus::ALL_00)) {
366 }
else if (
status & (TileFragStatus::NO_FRAG | TileFragStatus::NO_ROB)) {
370 float nBadNotMaskedDMUs = 0;
372 for (
int dmu = 0; dmu <
MAX_DMU; ++dmu) {
389 if ((channelStatus0.isBad() && channelStatus1.
isBad() && channelStatus2.
isBad())
395 || ((
ros < 3 &&
channel == 42) && channelStatus0.isBad() && channelStatus2.
isBad())
400 || ((specialEB &&
channel == 3) && channelStatus1.
isBad() && channelStatus2.
isBad())) {
406 if (isGoodModuleDCS) {
424 || (
ros > 2 && (dmu == 8 || dmu == 9 || dmu == 14 || dmu == 15))
425 || (specialEB && dmu == 0))) {
473 if (isGoodModuleDCS) {
474 fractionOfBadDMUs = nBadNotMaskedDMUs /
MAX_DMU;
488 rosWithGloblaCRC.push_back(
ros);
489 drawerWithGlobalCRC.push_back(
drawer);
494 if (!rosWithGloblaCRC.empty()) {
497 fill(
"TileBadGlobalCRC", monModule, monROS);
502 return StatusCode::SUCCESS;
507 int dmu,
int error)
const {
def retrieve(aClass, aKey=None)
static int CorruptedData(int ros, int drawer, int channel, int gain, const std::vector< float > &digits, float &dmin, float &dmax, float ADCmaxMinusEps, float ADCmaskValueMinusEps)
Gaudi::Property< bool > m_skipMasked
float m_ADCmaskValueMinusEps
indicates channels which were masked in background dataset
int checkBCIDErr(int partition, int drawer, int dmu, int gain) const
returns 1 if DMU has BCID mismatch between DMU and ROD Since BCID errors in the DQ fragment are det...
Gaudi::Property< float > m_negativeAmplitudeCutHG
Gaudi::Property< bool > m_skipGapCells
uint64_t eventNumber() const
The current event's event number.
void setDigiError(std::vector< int > &dmus, std::vector< int > &errors, int dmu, int error) const
bool isChanDQgood(int partition, int drawer, int ch) const
returns status of single channel (if bigain, returns AND of ADCs' status
Gaudi::Property< float > m_timeMinThresh
Class holding bad channel problems.
int sample(const Identifier &id) const
std::vector< int > m_badChannelNegNotMaskGroups
bool msgLvl(const MSG::Level lvl) const
Identifier h2s_cell_id_index(const HWIdentifier &id, int &index, int &pmt) const
virtual StatusCode initialize() override
initialize
#define ATH_MSG_VERBOSE(x)
bool empty() const
Test if the key is blank.
bool isStatusBad(unsigned int ros, unsigned int drawer) const
Return true if given Tile drawer considered as bad by summary drawer states per LVPS otherwise return...
@ u
Enums for curvilinear frames.
Gaudi::Property< float > m_timeMaxThresh
SG::ReadHandleKey< TileDigitsContainer > m_digitsContainerKey
int channel(const HWIdentifier &id) const
extract channel field from HW identifier
def timer(name, disabled=False)
int checkGlobalCRCErr(int partition, int drawer, int gain) const
returns 1 if adc channel has global CRC error
const ServiceHandle< StoreGateSvc > & detStore() const
The standard StoreGateSvc/DetectorStore Returns (kind of) a pointer to the StoreGateSvc.
ValuesCollection< T > Collection(std::string name, const T &collection)
Declare a monitored (double-convertible) collection.
int checkROD_CRCErr(int partition, int drawer, int dmu, int gain) const
returns 1 if DMU has CRC error originating in ROD
@ Error
The sub-detector issued an error.
Gaudi::Property< float > m_negativeAmplitudeCutLG
int ADCmaskValue() const
Returns the overlay magic number that indicates channels which were masked in background dataset.
SG::ReadCondHandle< T > makeHandle(const SG::ReadCondHandleKey< T > &key, const EventContext &ctx=Gaudi::Hive::currentContext())
const TileHWID * m_tileHWID
float calibrateChannel(unsigned int drawerIdx, unsigned int channel, unsigned int adc, float amplitude, TileRawChannelUnit::UNIT rawDataUnitIn, TileRawChannelUnit::UNIT rawDataUnitOut) const
Calibrate a Tile channel.
SG::ReadCondHandleKey< TileBadChannels > m_badChannelsKey
Name of TileBadChannels in condition store.
Class that holds Data Quality fragment information and provides functions to extract the data quality...
int adc(const HWIdentifier &id) const
extract adc field from HW identifier
void clearDigiError(std::vector< int > &dmus, std::vector< int > &errors) const
const TileCablingService * m_cabling
::StatusCode StatusCode
StatusCode definition for legacy code.
std::vector< int > m_badPulseQualityGroups
int checkHeaderFormatErr(int partition, int drawer, int dmu, int gain) const
returns 1 if DMU has header word format error
SG::ReadHandleKey< TileDQstatus > m_DQstatusKey
void fill(const ToolHandle< GenericMonitoringTool > &groupHandle, std::vector< std::reference_wrapper< Monitored::IMonitoredVariable >> &&variables) const
Fills a vector of variables to a group by reference.
StatusCode initialize(bool used=true)
If this object is used as a property, then this should be called during the initialize phase.
Gaudi::Property< bool > m_ignoreNoRecoFragError
std::vector< int > m_badChannelNegGroups
SG::ReadHandle< xAOD::EventInfo > GetEventInfo(const EventContext &) const
Return a ReadHandle for an EventInfo object (get run/event numbers, etc.)
uint32_t lumiBlock() const
The current event's luminosity block number.
std::vector< std::vector< int > > m_errorsGroups
const TileBchStatus & getChannelStatus(const HWIdentifier channel_id) const
Return Tile channel status.
SG::ReadCondHandleKey< TileEMScale > m_emScaleKey
Name of TileEMScale in condition store.
int checkGlobalErr(int partition, int drawer, int gain) const
returns 1 if adc channel has any global error
ToolHandleArray< GenericMonitoringTool > m_tools
Array of Generic Monitoring Tools.
int checkSampleParityErr(int partition, int drawer, int dmu, int gain) const
returns 1 if DMU has data word parity error
Gaudi::Property< float > m_minChannelEnergy
HWIdentifier channel_id(int ros, int drawer, int channel) const
channel HWIdentifer
int checkHeaderParityErr(int partition, int drawer, int dmu, int gain) const
returns 1 if DMU has header word parity error
StatusCode initialize(bool used=true)
int checkSampleFormatErr(int partition, int drawer, int dmu, int gain) const
returns 1 if DMU has data word format error
static const char * BadPatternName(float ped)
SG::ReadHandleKey< TileRawChannelContainer > m_rawChannelContainerKey
static const int MAX_CORRUPTED_ERROR
SG::ReadDecorHandleKey< xAOD::EventInfo > m_eventInfoTileStatusKey
Class describing the basic event information.
const TileBchStatus & getAdcStatus(const HWIdentifier adc_id) const
Return Tile ADC status.
virtual StatusCode initialize() override
initialize
uint32_t eventFlags(EventFlagSubDet subDet) const
Get the event flags for a particular sub-detector.
virtual StatusCode fillHistograms(const EventContext &ctx) const override
adds event to the monitoring histograms
@ Tile
The Tile calorimeter.
Gaudi::Property< float > m_qualityCut
bool contains(const Prb &prb) const
bool isDisconnected(int ros, int drawer, int channel) const
#define ATH_MSG_WARNING(x)
std::vector< int > m_badChannelJumpGroups
std::vector< std::vector< int > > m_errorsInLBGroups
SG::ReadCondHandleKey< TileDCSState > m_DCSStateKey
Name of TileDCSState object in condition store.
uint16_t level1TriggerType() const
The Level-1 trigger type.
EventFlagErrorState errorState(EventFlagSubDet subDet) const
Get the error state for a particular sub-detector.
Condition object to keep Tile DCS status from DB.
ServiceHandle< TileCablingSvc > m_cablingSvc
Name of Tile cabling service.
std::vector< std::vector< int > > m_errorsVsLBGroups
static unsigned int getDrawerIdx(unsigned int ros, unsigned int drawer)
Returns a drawer hash.
int checkSingleStrobeErr(int partition, int drawer, int dmu, int gain) const
returns 1 if DMU has single strobe error
Declare a monitored scalar variable.
std::vector< int > m_negativeEnergyGroups
Handle class for reading from StoreGate.
Gaudi::Property< bool > m_fillDigiErrorsInLB
This is a "hash" representation of an Identifier. This encodes a 32 bit index which can be used to lo...
std::vector< int > m_badChannelJumpNotMaskGroups
int checkDoubleStrobeErr(int partition, int drawer, int dmu, int gain) const
returns 1 if DMU has double strobe error
int checkMemoryParityErr(int partition, int drawer, int dmu, int gain) const
returns 1 if DMU has memory parity error
int checkFE_CRCErr(int partition, int drawer, int dmu, int gain) const
returns 1 if DMU has CRC error originating in FE electronics
Gaudi::Property< bool > m_checkDCS
int ADCmax() const
Returns the maximum ADC output (10 bits --> 1023)
Gaudi::Property< float > m_minGapEnergy
const_pointer_type cptr()
const TileInfo * m_tileInfo