ATLAS Offline Software
Loading...
Searching...
No Matches
LArCablingChecker Class Reference

#include <LArCablingChecker.h>

Inheritance diagram for LArCablingChecker:
Collaboration diagram for LArCablingChecker:

Public Member Functions

 LArCablingChecker (const std::string &name, ISvcLocator *pSvcLocator)
 ~LArCablingChecker ()
StatusCode initialize ()
StatusCode execute (const EventContext &ctx)
 Execute method.
StatusCode finalize ()
virtual StatusCode sysInitialize () override
 Override sysInitialize.
virtual const DataObjIDColl & extraOutputDeps () const override
 Return the list of extra output dependencies.
bool filterPassed (const EventContext &ctx) const
void setFilterPassed (bool state, const EventContext &ctx) const
ServiceHandle< StoreGateSvc > & evtStore ()
 The standard StoreGateSvc (event store) Returns (kind of) a pointer to the StoreGateSvc.
const ServiceHandle< StoreGateSvc > & detStore () const
 The standard StoreGateSvc/DetectorStore Returns (kind of) a pointer to the StoreGateSvc.
virtual StatusCode sysStart () override
 Handle START transition.
virtual std::vector< Gaudi::DataHandle * > inputHandles () const override
 Return this algorithm's input handles.
virtual std::vector< Gaudi::DataHandle * > outputHandles () const override
 Return this algorithm's output handles.
Gaudi::Details::PropertyBase & declareProperty (Gaudi::Property< T, V, H > &t)
void updateVHKA (Gaudi::Details::PropertyBase &)
MsgStream & msg () const
bool msgLvl (const MSG::Level lvl) const
const EventContext & getContext () const
 Deprecated methods (use the ones with EventContext).
bool filterPassed () const
void setFilterPassed (bool state) const

Protected Member Functions

virtual bool isReEntrant () const override final
 Legacy algorithms are not thread-safe.
void renounceArray (SG::VarHandleKeyArray &handlesArray)
 remove all handles from I/O resolution
std::enable_if_t< std::is_void_v< std::result_of_t< decltype(&T::renounce)(T)> > &&!std::is_base_of_v< SG::VarHandleKeyArray, T > &&std::is_base_of_v< Gaudi::DataHandle, T >, void > renounce (T &h)
void extraDeps_update_handler (Gaudi::Details::PropertyBase &ExtraDeps)
 Add StoreName to extra input/output deps as needed.

Private Types

typedef ServiceHandle< StoreGateSvcStoreGateSvc_t

Private Member Functions

Gaudi::Details::PropertyBase & declareGaudiProperty (Gaudi::Property< T, V, H > &hndl, const SG::VarHandleKeyType &)
 specialization for handling Gaudi::Property<SG::VarHandleKey>

Private Attributes

int m_count
SG::ReadCondHandleKey< LArOnOffIdMappingm_cablingKey {this,"CablingKey","LArOnOffIdMap","SG Key of LArOnOffIdMapping object"}
SG::ReadCondHandleKey< LArBadChannelContm_BCKey {this, "BadChanKey", "LArBadChannel", "SG bad channels key"}
SG::ReadCondHandleKey< LArCalibLineMappingm_CLKey {this, "CalibLineKey", "LArCalibLineMap", "SG calib line key"}
const LArOnlineIDm_onlineHelper
const LArEM_IDm_emId
std::ofstream m_outfile
std::string m_key
std::string m_outFileName
std::vector< bool > * m_errorcellsThisEvent
int m_errorCounterThisEvent
std::vector< bool > * m_errorcellsPreviousEvent
int m_errorCounterPreviousEvent
int m_numberOfEventsWithThisErrorState
LArOnlineID::size_type m_channelHashMax
bool m_PrintAllCellsAndEvents
bool m_PrintDisconnectedCells
int m_ADCThreshold
int m_DACHighGainThreshold
int m_DACMediumGainThreshold
int m_DACLowGainThreshold
bool m_printEventSummary
bool m_useBadChannelTool
DataObjIDColl m_extendedExtraObjects
StoreGateSvc_t m_evtStore
 Pointer to StoreGate (event store by default).
StoreGateSvc_t m_detStore
 Pointer to StoreGate (detector store by default).
std::vector< SG::VarHandleKeyArray * > m_vhka
bool m_varHandleArraysDeclared

Detailed Description

Definition at line 20 of file LArCablingChecker.h.

Member Typedef Documentation

◆ StoreGateSvc_t

typedef ServiceHandle<StoreGateSvc> AthCommonDataStore< AthCommonMsg< Gaudi::Algorithm > >::StoreGateSvc_t
privateinherited

Definition at line 388 of file AthCommonDataStore.h.

Constructor & Destructor Documentation

◆ LArCablingChecker()

LArCablingChecker::LArCablingChecker ( const std::string & name,
ISvcLocator * pSvcLocator )

Definition at line 14 of file LArCablingChecker.cxx.

15 : AthAlgorithm(name, pSvcLocator),
16 //m_chan(0),
18 m_emId(0),
25{
26 m_count = 0;
27 declareProperty("DigitKey", m_key = "");
28 declareProperty("FileName", m_outFileName = "CablingSummary.txt");
29 //declareProperty("Pattern", m_vPattern);
30 declareProperty("ADCThreshold", m_ADCThreshold = 1250);
31 declareProperty("DACHighGainThreshold", m_DACHighGainThreshold = 100);
32 declareProperty("DACMediumGainThreshold", m_DACMediumGainThreshold = 1000);
33 declareProperty("DACLowGainThreshold", m_DACLowGainThreshold = 10000);
34 declareProperty("PrintAllCellsAndEvents", m_PrintAllCellsAndEvents = false);
35 declareProperty("PrintDisconnectedCells", m_PrintDisconnectedCells = true);
36 declareProperty("PrintEventSummary", m_printEventSummary = false);
37 declareProperty("UseBadChannelTool", m_useBadChannelTool = true);
38}
AthAlgorithm(const std::string &name, ISvcLocator *pSvcLocator)
Constructor with parameters:
Gaudi::Details::PropertyBase & declareProperty(Gaudi::Property< T, V, H > &t)
std::string m_outFileName
const LArOnlineID * m_onlineHelper
const LArEM_ID * m_emId
std::vector< bool > * m_errorcellsThisEvent
std::vector< bool > * m_errorcellsPreviousEvent
LArOnlineID::size_type m_channelHashMax

◆ ~LArCablingChecker()

LArCablingChecker::~LArCablingChecker ( )

Definition at line 40 of file LArCablingChecker.cxx.

40 {
41 //empty
42}

Member Function Documentation

◆ declareGaudiProperty()

Gaudi::Details::PropertyBase & AthCommonDataStore< AthCommonMsg< Gaudi::Algorithm > >::declareGaudiProperty ( Gaudi::Property< T, V, H > & hndl,
const SG::VarHandleKeyType &  )
inlineprivateinherited

specialization for handling Gaudi::Property<SG::VarHandleKey>

Definition at line 156 of file AthCommonDataStore.h.

158 {
160 hndl.value(),
161 hndl.documentation());
162
163 }

◆ declareProperty()

Gaudi::Details::PropertyBase & AthCommonDataStore< AthCommonMsg< Gaudi::Algorithm > >::declareProperty ( Gaudi::Property< T, V, H > & t)
inlineinherited

Definition at line 145 of file AthCommonDataStore.h.

145 {
146 typedef typename SG::HandleClassifier<T>::type htype;
148 }
Gaudi::Details::PropertyBase & declareGaudiProperty(Gaudi::Property< T, V, H > &hndl, const SG::VarHandleKeyType &)
specialization for handling Gaudi::Property<SG::VarHandleKey>

◆ detStore()

const ServiceHandle< StoreGateSvc > & AthCommonDataStore< AthCommonMsg< Gaudi::Algorithm > >::detStore ( ) const
inlineinherited

The standard StoreGateSvc/DetectorStore Returns (kind of) a pointer to the StoreGateSvc.

Definition at line 95 of file AthCommonDataStore.h.

◆ evtStore()

ServiceHandle< StoreGateSvc > & AthCommonDataStore< AthCommonMsg< Gaudi::Algorithm > >::evtStore ( )
inlineinherited

The standard StoreGateSvc (event store) Returns (kind of) a pointer to the StoreGateSvc.

Definition at line 85 of file AthCommonDataStore.h.

◆ execute()

StatusCode LArCablingChecker::execute ( const EventContext & ctx)
virtual

Execute method.

Provides access to the EventContext if needed but is non-const as opposed to AthReentrantAlgorithm.

Implements AthAlgorithm.

Definition at line 76 of file LArCablingChecker.cxx.

76 {
77 unsigned eventNb = ctx.eventID().event_number();
78
79 ATH_MSG_INFO ( "======== executing event "<< eventNb << " ========" );
80 //m_outfile << "Checking Event " << eventNb << "..." << std::endl;
81
82 //log << MSG::INFO << "Retrieving LArDigitContainer. Key= " << m_key << std::endl;
83 const LArDigitContainer* larDigitCont = nullptr;
84 ATH_CHECK( evtStore()->retrieve(larDigitCont, m_key) );
85
86 //const LArCalibParams* calibParams;
87 const LArCalibParams* calibParams = nullptr;
88 ATH_CHECK( detStore()->retrieve(calibParams,"LArCalibParams") );
89
90 SG::ReadCondHandle<LArBadChannelCont> readHandle(m_BCKey, ctx);
91 const LArBadChannelCont *bcCont {*readHandle};
92 if(!bcCont) {
93 ATH_MSG_ERROR( "Do not have Bad chan container " << m_BCKey.key() );
94 return StatusCode::FAILURE;
95 }
96
97 SG::ReadCondHandle<LArOnOffIdMapping> cablingHdl(m_cablingKey, ctx);
98 const LArOnOffIdMapping* cabling=*cablingHdl;
99 if(!cabling) {
100 ATH_MSG_ERROR( "Do not have cabling object LArOnOffIdMapping" );
101 return StatusCode::FAILURE;
102 }
103
104 SG::ReadCondHandle<LArCalibLineMapping> clHdl(m_CLKey, ctx);
105 const LArCalibLineMapping *clCont {*clHdl};
106 if(!clCont) {
107 ATH_MSG_ERROR( "Do not have calib line mapping !!!" );
108 return StatusCode::FAILURE;
109 }
110
111
112 // Using vectors like this works because the hashes seem to be guaranteed to be collision-free.
113 delete m_errorcellsPreviousEvent; // OK to delete 0, Stroustrup 6.2.6
115 m_errorcellsThisEvent = new std::vector<bool>(m_channelHashMax); // All elements initialized to false, Stroustrup 16.3.4
116
119
120 int cellsCounter = 0;
121
122 int inconsistencyCounter = 0;
123 int disconnectedCounter = 0;
124 int badChannelCounter = 0;
125
126 bool signalPresent;
127 bool pulsed;
128 bool badChannel;
129 bool disconnected;
130
131 // Put errors in ErrorList, to print if needed.
132 std::ostringstream ErrorList;
133
134 // Loop on all cells (digits).
135 for (const LArDigit* digit : *larDigitCont) {
136 cellsCounter++;
137
138 ErrorList.clear();
139
140 // Get FEB info.
141 const HWIdentifier online_id = digit->hardwareID();
142 const HWIdentifier febid = m_onlineHelper->feb_Id(online_id);
143
144 int chNb = m_onlineHelper->channel(online_id);
145
146 // Check if channel is connected.
147 if (!cabling->isOnlineConnected(online_id)) {
148 disconnected = true;
149 disconnectedCounter++;
150 } else
151 disconnected = false;
152
153 Identifier offline_id;
154
155 // Get offline id.
156 bool noOffline_id = false;
157 try {
158 offline_id = cabling->cnvToIdentifier(online_id);
159 }
160 catch (const LArID_Exception&) {
161 noOffline_id = true;
162 }
163
164 // Find out if signal over theshold is present.
165 // Set signalPresent.
166 const int max = *max_element(digit->samples().begin(), digit->samples().end());
167 if (max >= m_ADCThreshold)
168 signalPresent = true;
169 else
170 signalPresent = false;
171
172 // Loop on calibchannels to see which, if any, that pulsed the cell.
173 // Set pulsed and DACvalue, and fill PulserList.
174 pulsed = false;
175 int DACvalue = -1;
176 std::ostringstream PulserList;
177 const std::vector<HWIdentifier>& calibChannelIDs=clCont->calibSlotLine(online_id);
178
179 for (HWIdentifier hwid : calibChannelIDs) {
180 //m_outfile << hwid.get_compact() << " ";
181 bool isPulsed=calibParams->isPulsed(eventNb, hwid);
182 if (isPulsed) {
183 int DACvalue_temp = calibParams->DAC(eventNb, hwid);
184 if (DACvalue_temp > DACvalue)
185 DACvalue = DACvalue_temp;
186 pulsed = true;
187 const int slot = m_onlineHelper->slot(hwid);
188 const int line = m_onlineHelper->channel(hwid);
189 PulserList << std::hex << hwid.get_compact() << std::dec << " " << slot << " " << line << " ";
190 }
191 }
192 //m_outfile << std::endl;
193
194 CaloGain::CaloGain gain = digit->gain();
195 bool DACOverThreshold;
196 switch (gain) {
198 DACOverThreshold = DACvalue >= m_DACLowGainThreshold;
199 break;
201 DACOverThreshold = DACvalue >= m_DACMediumGainThreshold;
202 break;
204 DACOverThreshold = DACvalue >= m_DACHighGainThreshold;
205 break;
206 default:
207 DACOverThreshold = DACvalue >= m_DACHighGainThreshold;
208 }
209
210 // Find out if we have a bad cell.
211 if (m_useBadChannelTool && !noOffline_id) {
212 if (bcCont->offlineStatus(offline_id).good()) {
213 badChannel = false;
214 } else {
215 badChannel = true;
216 badChannelCounter++;
217 }
218 } else {
219 badChannel = false;
220 }
221
222 // Analyze and report.
223
224 bool inconsistency = (signalPresent != pulsed) && DACOverThreshold;
225 if (inconsistency)
226 inconsistencyCounter++;
227
228 bool errorInCell = inconsistency || badChannel;
229 if (errorInCell)
231
232 std::ostringstream CellData;
233 CellData << "0x" << std::hex << std::setw(8) << febid.get_compact() << std::dec
234 << std::setw(5) << m_onlineHelper->feedthrough(febid)
235 << std::setw(5) << m_onlineHelper->slot(febid)
236 << std::setw(5) << chNb;
237
238 CellData << std::setw(5);
239 if (noOffline_id)
240 CellData << "-";
241 else
242 CellData << m_emId->sampling(offline_id);
243
244 CellData << std::setw(5);
245 if (noOffline_id)
246 CellData << "-";
247 else
248 CellData << m_emId->eta(offline_id);
249
250 CellData << std::setw(5);
251 if (noOffline_id)
252 CellData << "-";
253 else
254 CellData << m_emId->phi(offline_id);
255
256 CellData << std::setw(7) << max;
257 if (DACvalue >= 0) // Above have set DACvalue=-1 if got no DAC value.
258 CellData << std::setw(7) << DACvalue;
259 else
260 CellData << std::setw(7) << "-";
261
262 if (disconnected) {
264 ErrorList << " D ";
265 ErrorList << CellData.str() << std::endl;
266 }
267 }
268 else {
269 // Set relevant bit in m_errorcellsThisEvent if error in this cell.
270 if (errorInCell)
271 (*m_errorcellsThisEvent)[m_onlineHelper->channel_Hash(online_id)] = true;
272
273 if (errorInCell || m_PrintAllCellsAndEvents) {
274 if (inconsistency)
275 ErrorList << "I";
276 else
277 ErrorList << " ";
278 if (pulsed)
279 ErrorList << "P";
280 else
281 ErrorList << " ";
282 if (signalPresent)
283 ErrorList << "S";
284 else
285 ErrorList << " ";
286 if (badChannel)
287 ErrorList << "B ";
288 else
289 ErrorList << " ";
290
291 ErrorList << CellData.str();
292
293 if (pulsed)
294 ErrorList << " " << PulserList.str();
295
296 ErrorList << std::endl;
297 }
298 }
299 } //End looping on all cells
300
301 ErrorList << std::endl;
302
304 ErrorList << "Examined " << cellsCounter << " cells in event " << eventNb << ". Found:" << std::endl;
305 ErrorList << std::left << std::setw(25) << "Inconsistencies: "
306 << std::right << std::setw(4) << inconsistencyCounter << std::endl;
307 ErrorList << std::left << std::setw(25) << "Bad cells: "
308 << std::right << std::setw(4) << badChannelCounter << std::endl;
309 ErrorList << std::left << std::setw(25) << "Sum errors: "
310 << std::right << std::setw(4) << m_errorCounterThisEvent << std::endl;
311 ErrorList << std::left << std::setw(25) << "Disconnected cells: "
312 << std::right << std::setw(4) << disconnectedCounter << std::endl;
313 ErrorList << std::endl;
314 }
315
317 // Compare m_errorcellsThisEvent to m_errorcellsPreviousEvent
318 if (*m_errorcellsThisEvent == *m_errorcellsPreviousEvent) { // Pray to God this is optimized.
319 // Same status as previous event, increase counter and go to next event.
321 }
322 else {
323 // A new status for this event. Print number of repeats for the previous one and print new state, if an error.
325 m_outfile << "Last error occurred in "
326 << m_numberOfEventsWithThisErrorState << " events." << std::endl << std::endl;
327
328 if (m_errorCounterThisEvent != 0) {
329 m_outfile << "Error in event "<< std::setw(7) << eventNb
330 << " ==========================================================================" << std::endl;
331 m_outfile << "I=Inconsistency P=Pulsed S=Signal B=Bad D=Disconnected" << std::endl;
332 m_outfile << " "
333 << std::left << std::setw(10) << "FEB"
334 << std::right << std::setw(5) << "FT"
335 << std::setw(5) << "SL"
336 << std::setw(5) << "CH"
337 << std::setw(5) << "Smpl"
338 << std::setw(5) << "Eta"
339 << std::setw(5) << "Phi"
340 << std::setw(7) << "ADC"
341 << std::setw(7) << "DAC"
342 << " Pulsed by calibchannel slot line"
343 << std::endl;
344
345 m_outfile << ErrorList.str();
346 }
347
349 }
350 }
351 else { // m_PrintAllCellsAndEvents==true
352 m_outfile << "Status of event "<< std::setw(7) << eventNb
353 << " ==========================================================================" << std::endl;
354 m_outfile << "I=Inconsistency P=Pulsed S=Signal B=Bad D=Disconnected" << std::endl;
355 m_outfile << " "
356 << std::left << std::setw(10) << "FEB"
357 << std::right << std::setw(5) << "FT"
358 << std::setw(5) << "SL"
359 << std::setw(5) << "CH"
360 << std::setw(5) << "Smpl"
361 << std::setw(5) << "Eta"
362 << std::setw(5) << "Phi"
363 << std::setw(7) << "ADC"
364 << std::setw(7) << "DAC"
365 << " Pulsed by slot line"
366 << std::endl;
367
368 m_outfile << ErrorList.str();
369 }
370
371 return StatusCode::SUCCESS;
372}
#define ATH_CHECK
Evaluate an expression and check for errors.
#define ATH_MSG_ERROR(x)
#define ATH_MSG_INFO(x)
LArBadXCont< LArBadChannel > LArBadChannelCont
#define max(a, b)
Definition cfImp.cxx:41
const ServiceHandle< StoreGateSvc > & detStore() const
value_type get_compact() const
Get the compact id.
bool good() const
Returns true if no problems at all (all bits at zero).
LArBC_t offlineStatus(const Identifier id) const
Query the status of a particular channel by offline ID This is the main client access method.
SG::ReadCondHandleKey< LArCalibLineMapping > m_CLKey
std::ofstream m_outfile
SG::ReadCondHandleKey< LArBadChannelCont > m_BCKey
SG::ReadCondHandleKey< LArOnOffIdMapping > m_cablingKey
const std::vector< HWIdentifier > & calibSlotLine(const HWIdentifier id) const
bool isPulsed(const unsigned event, const HWIdentifier calibLineID) const
unsigned DAC(const unsigned event, const HWIdentifier calibLineID) const
@ LARMEDIUMGAIN
Definition CaloGain.h:18
@ LARLOWGAIN
Definition CaloGain.h:18
@ LARHIGHGAIN
Definition CaloGain.h:18

◆ extraDeps_update_handler()

void AthCommonDataStore< AthCommonMsg< Gaudi::Algorithm > >::extraDeps_update_handler ( Gaudi::Details::PropertyBase & ExtraDeps)
protectedinherited

Add StoreName to extra input/output deps as needed.

use the logic of the VarHandleKey to parse the DataObjID keys supplied via the ExtraInputs and ExtraOuputs Properties to add the StoreName if it's not explicitly given

◆ extraOutputDeps()

const DataObjIDColl & AthAlgorithm::extraOutputDeps ( ) const
overridevirtualinherited

Return the list of extra output dependencies.

This list is extended to include symlinks implied by inheritance relations.

Definition at line 50 of file AthAlgorithm.cxx.

51{
52 // If we didn't find any symlinks to add, just return the collection
53 // from the base class. Otherwise, return the extended collection.
54 if (!m_extendedExtraObjects.empty()) {
56 }
57 return Algorithm::extraOutputDeps();
58}
DataObjIDColl m_extendedExtraObjects

◆ filterPassed() [1/2]

bool AthAlgorithm::filterPassed ( ) const
inherited

Definition at line 94 of file AthAlgorithm.cxx.

94 {
95 return filterPassed( Gaudi::Hive::currentContext() );
96}
bool filterPassed() const

◆ filterPassed() [2/2]

bool AthAlgorithm::filterPassed ( const EventContext & ctx) const
inherited

Definition at line 98 of file AthAlgorithm.cxx.

98 {
99 return execState( ctx ).filterPassed();
100}

◆ finalize()

StatusCode LArCablingChecker::finalize ( )

Definition at line 374 of file LArCablingChecker.cxx.

374 {
376 m_outfile << "Last error occurred in " << m_numberOfEventsWithThisErrorState << " events." << std::endl << std::endl;
377
378 m_outfile.close();
379
382
383 return StatusCode::SUCCESS;
384}

◆ getContext()

const EventContext & AthAlgorithm::getContext ( ) const
inherited

Deprecated methods (use the ones with EventContext).

Definition at line 90 of file AthAlgorithm.cxx.

90 {
91 return Gaudi::Hive::currentContext();
92}

◆ initialize()

StatusCode LArCablingChecker::initialize ( )

Definition at line 44 of file LArCablingChecker.cxx.

44 {
45 ATH_CHECK( detStore()->retrieve(m_onlineHelper, "LArOnlineID") );
46 ATH_CHECK( m_cablingKey.initialize() );
47 ATH_CHECK( m_CLKey.initialize() );
48
50 ATH_CHECK( m_BCKey.initialize() );
51 }
52
53 m_outfile.open(m_outFileName.c_str(), std::ios::out);
54 if (!m_outfile.is_open()) {
55 ATH_MSG_ERROR ( "Unable to open output file with name " << m_outFileName );
56 return StatusCode::FAILURE;
57 }
58
59 const CaloCell_ID* idHelper = nullptr;
60 ATH_CHECK( detStore()->retrieve (idHelper, "CaloCell_ID") );
61 m_emId=idHelper->em_idHelper();
62
63 m_channelHashMax = m_onlineHelper->channelHashMax();
64
67 // Phony "previous" event so that the first event has something to compare to.
68 m_errorcellsThisEvent = new std::vector<bool>(m_channelHashMax);
71
72 ATH_MSG_DEBUG ( "======== LArCablingChecker initialize successfully ========" );
73 return StatusCode::SUCCESS;
74}
#define ATH_MSG_DEBUG(x)
const LArEM_ID * em_idHelper() const
access to EM idHelper
Definition CaloCell_ID.h:63

◆ inputHandles()

virtual std::vector< Gaudi::DataHandle * > AthCommonDataStore< AthCommonMsg< Gaudi::Algorithm > >::inputHandles ( ) const
overridevirtualinherited

Return this algorithm's input handles.

We override this to include handle instances from key arrays if they have not yet been declared. See comments on updateVHKA.

◆ isReEntrant()

virtual bool AthAlgorithm::isReEntrant ( ) const
inlinefinaloverrideprotectedvirtualinherited

Legacy algorithms are not thread-safe.

Definition at line 111 of file AthAlgorithm.h.

111{ return false; }

◆ msg()

MsgStream & AthCommonMsg< Gaudi::Algorithm >::msg ( ) const
inlineinherited

Definition at line 24 of file AthCommonMsg.h.

24 {
25 return this->msgStream();
26 }

◆ msgLvl()

bool AthCommonMsg< Gaudi::Algorithm >::msgLvl ( const MSG::Level lvl) const
inlineinherited

Definition at line 30 of file AthCommonMsg.h.

30 {
31 return this->msgLevel(lvl);
32 }

◆ outputHandles()

virtual std::vector< Gaudi::DataHandle * > AthCommonDataStore< AthCommonMsg< Gaudi::Algorithm > >::outputHandles ( ) const
overridevirtualinherited

Return this algorithm's output handles.

We override this to include handle instances from key arrays if they have not yet been declared. See comments on updateVHKA.

◆ renounce()

std::enable_if_t< std::is_void_v< std::result_of_t< decltype(&T::renounce)(T)> > &&!std::is_base_of_v< SG::VarHandleKeyArray, T > &&std::is_base_of_v< Gaudi::DataHandle, T >, void > AthCommonDataStore< AthCommonMsg< Gaudi::Algorithm > >::renounce ( T & h)
inlineprotectedinherited

Definition at line 380 of file AthCommonDataStore.h.

381 {
382 h.renounce();
384 }
std::enable_if_t< std::is_void_v< std::result_of_t< decltype(&T::renounce)(T)> > &&!std::is_base_of_v< SG::VarHandleKeyArray, T > &&std::is_base_of_v< Gaudi::DataHandle, T >, void > renounce(T &h)

◆ renounceArray()

void AthCommonDataStore< AthCommonMsg< Gaudi::Algorithm > >::renounceArray ( SG::VarHandleKeyArray & handlesArray)
inlineprotectedinherited

remove all handles from I/O resolution

Definition at line 364 of file AthCommonDataStore.h.

364 {
366 }

◆ setFilterPassed() [1/2]

void AthAlgorithm::setFilterPassed ( bool state) const
inherited

Definition at line 102 of file AthAlgorithm.cxx.

102 {
103 setFilterPassed( state, Gaudi::Hive::currentContext() );
104}
void setFilterPassed(bool state) const

◆ setFilterPassed() [2/2]

void AthAlgorithm::setFilterPassed ( bool state,
const EventContext & ctx ) const
inherited

Definition at line 106 of file AthAlgorithm.cxx.

106 {
107 execState( ctx ).setFilterPassed(state);
108}

◆ sysInitialize()

StatusCode AthAlgorithm::sysInitialize ( )
overridevirtualinherited

Override sysInitialize.

Override sysInitialize from the base class.

Loop through all output handles, and if they're WriteCondHandles, automatically register them and this Algorithm with the CondSvc.

Scan through all outputHandles, and if they're WriteCondHandles, register them with the CondSvc

Reimplemented from AthCommonDataStore< AthCommonMsg< Gaudi::Algorithm > >.

Reimplemented in AthAnalysisAlgorithm, AthFilterAlgorithm, AthHistogramAlgorithm, and PyAthena::Alg.

Definition at line 66 of file AthAlgorithm.cxx.

66 {
68
69 if (sc.isFailure()) {
70 return sc;
71 }
72 ServiceHandle<ICondSvc> cs("CondSvc",name());
73 for (auto h : outputHandles()) {
74 if (h->isCondition() && h->mode() == Gaudi::DataHandle::Writer) {
75 // do this inside the loop so we don't create the CondSvc until needed
76 if ( cs.retrieve().isFailure() ) {
77 ATH_MSG_WARNING("no CondSvc found: won't autoreg WriteCondHandles");
78 return StatusCode::SUCCESS;
79 }
80 if (cs->regHandle(this,*h).isFailure()) {
81 sc = StatusCode::FAILURE;
82 ATH_MSG_ERROR("unable to register WriteCondHandle " << h->fullKey()
83 << " with CondSvc");
84 }
85 }
86 }
87 return sc;
88}
#define ATH_MSG_WARNING(x)
static Double_t sc
virtual StatusCode sysInitialize() override
Override sysInitialize.
AthCommonDataStore(const std::string &name, T... args)
virtual std::vector< Gaudi::DataHandle * > outputHandles() const override
::StatusCode StatusCode
StatusCode definition for legacy code.

◆ sysStart()

virtual StatusCode AthCommonDataStore< AthCommonMsg< Gaudi::Algorithm > >::sysStart ( )
overridevirtualinherited

Handle START transition.

We override this in order to make sure that conditions handle keys can cache a pointer to the conditions container.

◆ updateVHKA()

void AthCommonDataStore< AthCommonMsg< Gaudi::Algorithm > >::updateVHKA ( Gaudi::Details::PropertyBase & )
inlineinherited

Definition at line 308 of file AthCommonDataStore.h.

308 {
309 // debug() << "updateVHKA for property " << p.name() << " " << p.toString()
310 // << " size: " << m_vhka.size() << endmsg;
311 for (auto &a : m_vhka) {
313 for (auto k : keys) {
314 k->setOwner(this);
315 }
316 }
317 }

Member Data Documentation

◆ m_ADCThreshold

int LArCablingChecker::m_ADCThreshold
private

Definition at line 57 of file LArCablingChecker.h.

◆ m_BCKey

SG::ReadCondHandleKey<LArBadChannelCont> LArCablingChecker::m_BCKey {this, "BadChanKey", "LArBadChannel", "SG bad channels key"}
private

Definition at line 36 of file LArCablingChecker.h.

36{this, "BadChanKey", "LArBadChannel", "SG bad channels key"};

◆ m_cablingKey

SG::ReadCondHandleKey<LArOnOffIdMapping> LArCablingChecker::m_cablingKey {this,"CablingKey","LArOnOffIdMap","SG Key of LArOnOffIdMapping object"}
private

Definition at line 35 of file LArCablingChecker.h.

35{this,"CablingKey","LArOnOffIdMap","SG Key of LArOnOffIdMapping object"};

◆ m_channelHashMax

LArOnlineID::size_type LArCablingChecker::m_channelHashMax
private

Definition at line 52 of file LArCablingChecker.h.

◆ m_CLKey

SG::ReadCondHandleKey<LArCalibLineMapping> LArCablingChecker::m_CLKey {this, "CalibLineKey", "LArCalibLineMap", "SG calib line key"}
private

Definition at line 37 of file LArCablingChecker.h.

37{this, "CalibLineKey", "LArCalibLineMap", "SG calib line key"};

◆ m_count

int LArCablingChecker::m_count
private

Definition at line 33 of file LArCablingChecker.h.

◆ m_DACHighGainThreshold

int LArCablingChecker::m_DACHighGainThreshold
private

Definition at line 58 of file LArCablingChecker.h.

◆ m_DACLowGainThreshold

int LArCablingChecker::m_DACLowGainThreshold
private

Definition at line 60 of file LArCablingChecker.h.

◆ m_DACMediumGainThreshold

int LArCablingChecker::m_DACMediumGainThreshold
private

Definition at line 59 of file LArCablingChecker.h.

◆ m_detStore

StoreGateSvc_t AthCommonDataStore< AthCommonMsg< Gaudi::Algorithm > >::m_detStore
privateinherited

Pointer to StoreGate (detector store by default).

Definition at line 393 of file AthCommonDataStore.h.

◆ m_emId

const LArEM_ID* LArCablingChecker::m_emId
private

Definition at line 40 of file LArCablingChecker.h.

◆ m_errorcellsPreviousEvent

std::vector<bool>* LArCablingChecker::m_errorcellsPreviousEvent
private

Definition at line 49 of file LArCablingChecker.h.

◆ m_errorcellsThisEvent

std::vector<bool>* LArCablingChecker::m_errorcellsThisEvent
private

Definition at line 47 of file LArCablingChecker.h.

◆ m_errorCounterPreviousEvent

int LArCablingChecker::m_errorCounterPreviousEvent
private

Definition at line 50 of file LArCablingChecker.h.

◆ m_errorCounterThisEvent

int LArCablingChecker::m_errorCounterThisEvent
private

Definition at line 48 of file LArCablingChecker.h.

◆ m_evtStore

StoreGateSvc_t AthCommonDataStore< AthCommonMsg< Gaudi::Algorithm > >::m_evtStore
privateinherited

Pointer to StoreGate (event store by default).

Definition at line 390 of file AthCommonDataStore.h.

◆ m_extendedExtraObjects

DataObjIDColl AthAlgorithm::m_extendedExtraObjects
privateinherited

Definition at line 114 of file AthAlgorithm.h.

◆ m_key

std::string LArCablingChecker::m_key
private

Definition at line 43 of file LArCablingChecker.h.

◆ m_numberOfEventsWithThisErrorState

int LArCablingChecker::m_numberOfEventsWithThisErrorState
private

Definition at line 51 of file LArCablingChecker.h.

◆ m_onlineHelper

const LArOnlineID* LArCablingChecker::m_onlineHelper
private

Definition at line 39 of file LArCablingChecker.h.

◆ m_outfile

std::ofstream LArCablingChecker::m_outfile
private

Definition at line 42 of file LArCablingChecker.h.

◆ m_outFileName

std::string LArCablingChecker::m_outFileName
private

Definition at line 44 of file LArCablingChecker.h.

◆ m_PrintAllCellsAndEvents

bool LArCablingChecker::m_PrintAllCellsAndEvents
private

Definition at line 55 of file LArCablingChecker.h.

◆ m_PrintDisconnectedCells

bool LArCablingChecker::m_PrintDisconnectedCells
private

Definition at line 56 of file LArCablingChecker.h.

◆ m_printEventSummary

bool LArCablingChecker::m_printEventSummary
private

Definition at line 61 of file LArCablingChecker.h.

◆ m_useBadChannelTool

bool LArCablingChecker::m_useBadChannelTool
private

Definition at line 62 of file LArCablingChecker.h.

◆ m_varHandleArraysDeclared

bool AthCommonDataStore< AthCommonMsg< Gaudi::Algorithm > >::m_varHandleArraysDeclared
privateinherited

Definition at line 399 of file AthCommonDataStore.h.

◆ m_vhka

std::vector<SG::VarHandleKeyArray*> AthCommonDataStore< AthCommonMsg< Gaudi::Algorithm > >::m_vhka
privateinherited

Definition at line 398 of file AthCommonDataStore.h.


The documentation for this class was generated from the following files: