Loading [MathJax]/extensions/tex2jax.js
ATLAS Offline Software
All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Modules Pages
LArSC2Ntuple.cxx
Go to the documentation of this file.
1 /*
2  Copyright (C) 2002-2024 CERN for the benefit of the ATLAS collaboration
3 */
4 
12 
13 #include <numeric>
14 
15 LArSC2Ntuple::LArSC2Ntuple(const std::string& name, ISvcLocator* pSvcLocator):
16  LArDigits2Ntuple(name, pSvcLocator), m_caloMgrSC(nullptr) {
17  m_ntTitle = "SCDigits";
18  m_ntpath = "/NTUPLES/FILE1/SCDIGITS";
19  }
20 
22 
23  ATH_MSG_DEBUG( "LArSC2Ntuple in initialize" );
24 
25  m_isSC = true;
26  if(m_fillTType && (! m_fillLB)) m_fillLB = true;
27  if(m_fillCaloTT && (! m_fillLB)) m_fillLB = true;
28 
30  ATH_CHECK( m_scidtool.retrieve() );
31 
34  ATH_CHECK( m_eventInfoDecorKey.initialize() );
35 
37 
39 
40  StatusCode sc=m_nt->addItem("latomeChannel",m_latomeChannel);
41  if (sc.isFailure()) {
42  ATH_MSG_ERROR( "addItem 'latomeChannel' failed" );
43  return sc;
44  }
45 
46  sc = m_nt->addItem("bcidVec",m_Nsamples, m_bcidVec);//here - > define length?
47  if (sc.isFailure()) {
48  ATH_MSG_ERROR( "addItem 'bcidVec' failed" );
49  return sc;
50  }
51  sc = m_nt->addItem("latomeSourceId",m_latomeSourceId);
52  if (sc.isFailure()) {
53  ATH_MSG_ERROR( "addItem 'latomeSourceId' failed" );
54  return sc;
55  }
56  sc = m_nt->addItem("Net",m_ntNet);
57  if (sc.isFailure()) {
58  ATH_MSG_ERROR( "addItem 'Net' failed" );
59  return sc;
60  }
61 
62  // Loop over container keys
63  for ( const std::string &ck : m_contKeys ){
64  if ( ck.find("SC") == std::string::npos){ // main readout only
65  if ( m_fillRawChan && ck == "LArRawChannels" ){
66  sc = m_nt->addItem("ROD_energy", 16, m_ROD_energy);
67  if (sc.isFailure()) {
68  ATH_MSG_ERROR( "addItem 'ROD_energy' failed" );
69  return sc;
70  }
71  sc = m_nt->addItem("ROD_time", 16, m_ROD_time);
72  if (sc.isFailure()) {
73  ATH_MSG_ERROR( "addItem 'ROD_time' failed" );
74  return sc;
75  }
76  sc = m_nt->addItem("ROD_id", 16, m_ROD_id);
77  if (sc.isFailure()) {
78  ATH_MSG_ERROR( "addItem 'ROD_id' failed" );
79  return sc;
80  }
81  }
82 
83  }else if ( ck == "SC_ADC_BAS" ){ // SC_ADC_BAS DigitContainer
84  sc = m_nt->addItem("samples_ADC_BAS",m_Nsamples,m_samples_ADC_BAS);
85  if (sc.isFailure()) {
86  ATH_MSG_ERROR( "addItem 'samples_ADC_BAS' failed" );
87  return sc;
88  }
89 
90  sc = m_nt->addItem("bcidVec_ADC_BAS",m_Nsamples, m_bcidVec_ADC_BAS);//here - > define length?
91  if (sc.isFailure()) {
92  ATH_MSG_ERROR( "addItem 'bcidVec_ADC_BAS' failed" );
93  return sc;
94  }
95 
96  }else if ( ck == "SC_ET" ){ // SC_ET RawSCContainer
97  sc = m_nt->addItem("energyVec_ET", m_Net, m_energyVec_ET);
98  if (sc.isFailure()) {
99  ATH_MSG_ERROR( "addItem 'energyVec_ET' failed" );
100  return sc;
101  }
102  sc = m_nt->addItem("bcidVec_ET", m_Net, m_bcidVec_ET);
103  if (sc.isFailure()) {
104  ATH_MSG_ERROR( "addItem 'bcidVec_ET' failed" );
105  return sc;
106  }
107  sc = m_nt->addItem("saturVec_ET", m_Net, m_saturVec_ET);
108  if (sc.isFailure()) {
109  ATH_MSG_ERROR( "addItem 'saturVec_ET' failed" );
110  return sc;
111  }
112 
113  }else if ( ck == "SC_ET_ID" ){ // SC_ET_ID RawSCContainer
114 
115  sc = m_nt->addItem("energyVec_ET_ID", m_Net, m_energyVec_ET_ID);
116  if (sc.isFailure()) {
117  ATH_MSG_ERROR( "addItem 'energyVec_ET_ID' failed" );
118  return sc;
119  }
120  sc = m_nt->addItem("bcidVec_ET_ID", m_Net, m_bcidVec_ET_ID);
121  if (sc.isFailure()) {
122  ATH_MSG_ERROR( "addItem 'bcidVec_ET_ID' failed" );
123  return sc;
124  }
125  sc = m_nt->addItem("saturVec_ET_ID", m_Net, m_saturVec_ET_ID);
126  if (sc.isFailure()) {
127  ATH_MSG_ERROR( "addItem 'saturVec_ET_ID' failed" );
128  return sc;
129  }
130  }
131 
132  }// end container key loop
133 
134  sc = m_nt->addItem("bcidLATOMEHEAD",m_bcidLATOMEHEAD);
135  if (sc.isFailure()) {
136  ATH_MSG_ERROR( "addItem 'bcidLATOMEHEAD' failed" );
137  return sc;
138  }
139 
140  if(m_fillTType) {
141  sc = m_evt_nt->addItem("TType", m_TType);
142  if (sc.isFailure()) {
143  ATH_MSG_ERROR( "addItem 'TType' failed" );
144  return sc;
145  }
146 
147  sc = m_evt_nt->addItem("LArEventBits", m_LArEventBits);
148  if (sc.isFailure()) {
149  ATH_MSG_ERROR( "addItem 'LArEventBits' failed" );
150  return sc;
151  }
152  sc = m_evt_nt->addItem("LArError", m_LArInError);
153  if (sc.isFailure()) {
154  ATH_MSG_ERROR( "addItem 'LArError' failed" );
155  return sc;
156  }
157  //Adding trigger decision bit branches
158  CHECK( m_trigDec.retrieve() );
159  for ( const std::string &tn : m_trigNames ){
160  sc = m_evt_nt->addItem(tn,m_trigNameMap[tn]);
161  if (sc.isFailure()) {
162  ATH_MSG_ERROR( "addItem '"+tn+"' failed" );
163  return sc;
164  }
165  }
166 
167  }//m_fillTType
168 
169  if(m_fillCaloTT) {
170  sc = m_evt_nt->addItem("NTT",m_ntNTT,0,20000);
171  if (sc.isFailure()) {
172  ATH_MSG_ERROR( "addItem 'Net' failed" );
173  return sc;
174  }
175  sc = m_evt_nt->addItem("TTeta", m_ntNTT, m_TTeta);
176  if (sc.isFailure()) {
177  ATH_MSG_ERROR( "addItem 'TTeta' failed" );
178  return sc;
179  }
180  sc = m_evt_nt->addItem("TTphi", m_ntNTT, m_TTphi);
181  if (sc.isFailure()) {
182  ATH_MSG_ERROR( "addItem 'TTphi' failed" );
183  return sc;
184  }
185  sc = m_evt_nt->addItem("TTEem", m_ntNTT, m_TTEem);
186  if (sc.isFailure()) {
187  ATH_MSG_ERROR( "addItem 'TTEem' failed" );
188  return sc;
189  }
190  sc = m_evt_nt->addItem("TTEhad", m_ntNTT, m_TTEhad);
191  if (sc.isFailure()) {
192  ATH_MSG_ERROR( "addItem 'TTEhad' failed" );
193  return sc;
194  }
195  } // end m_fillCaloTT
196 
197  return StatusCode::SUCCESS;
198 
199 }
200 
202 {
203 
204  StatusCode sc;
205 
206  const EventContext& ctx = Gaudi::Hive::currentContext();
207 
209  ATH_CHECK(evt.isValid());
210 
211  unsigned long long thisevent = evt->eventNumber();
212  unsigned short thislb = evt->lumiBlock();
213 
214  // This should be used for main readout later, once TDAQ fill event headers also in calib. runs properly
215  unsigned long thisbcid = evt->bcid();
216  unsigned long thisELVL1Id = 0;
217  unsigned long thisttype = evt->level1TriggerType();
218  //
220  bool hasDigitContainer=true;
221  const LArDigitContainer *DigitContainer = nullptr;
222  if(!m_contKey.key().empty()) {
224  if(!hdlDigit.isValid()) {
225  ATH_MSG_WARNING( "Unable to retrieve LArDigitContainer with key " << m_contKey << " from DetectorStore. " );
226  hasDigitContainer=false;
227  } else {
228  ATH_MSG_DEBUG( "Got LArDigitContainer with key " << m_contKey.key() );
229  DigitContainer = hdlDigit.cptr();
230  }
231  } else hasDigitContainer=false;
232 
233  bool hasAccCalibDigitContainer=true;
234  const LArAccumulatedCalibDigitContainer *AccCalibDigitContainer = nullptr;
235  if(!m_accCalibContKey.key().empty()) {
237  if(!hdlAccDigit.isValid()) {
238  ATH_MSG_WARNING( "Unable to retrieve LArAccumulatedCalibDigitContainer with key " << m_accCalibContKey << " from DetectorStore. " );
239  hasAccCalibDigitContainer=false;
240  } else {
241  ATH_MSG_DEBUG( "Got LArAccumulatedCalibDigitContainer with key " << m_accCalibContKey.key() );
242  AccCalibDigitContainer = hdlAccDigit.cptr();
243  }
244  } else hasAccCalibDigitContainer=false;
245 
246  bool hasAccDigitContainer=true;
247  const LArAccumulatedDigitContainer *AccDigitContainer = nullptr;
248  if(!m_accContKey.key().empty()) {
250  if(!hdlAccDigit.isValid()) {
251  ATH_MSG_WARNING( "Unable to retrieve LArAccumulatedDigitContainer with key " << m_accContKey << " from DetectorStore. " );
252  hasAccDigitContainer=false;
253  } else {
254  ATH_MSG_DEBUG( "Got LArAccumulatedDigitContainer with key " << m_accContKey.key() );
255  AccDigitContainer = hdlAccDigit.cptr();
256  }
257  } else hasAccDigitContainer=false;
258 
259  const LArDigitContainer* DigitContainer_next = nullptr;
260  const LArRawSCContainer* etcontainer = nullptr;
261  const LArRawSCContainer* etcontainer_next = nullptr;
262  const LArRawChannelContainer* RawChannelContainer = nullptr;
263  const LArLATOMEHeaderContainer*headcontainer = nullptr;
264  std::map<unsigned int, const LArLATOMEHeader*> LATOMEHeadMap;
265  rawChanMap_t rawChannelMap;
266 
267  if ((std::find(m_contKeys.begin(), m_contKeys.end(), "LArRawChannels") != m_contKeys.end()) ){
268  sc = evtStore()->retrieve(RawChannelContainer,"LArRawChannels");
269  if (sc.isFailure()) {
270  ATH_MSG_WARNING( "Unable to retrieve LArRawChannelContainer with key LArRawChannels from DetectorStore. " );
271  }
272  else
273  ATH_MSG_DEBUG( "Got LArRawChannelContainer with key LArRawChannels" );
274  }
275 
276  if(m_ETThreshMain > 0. && !RawChannelContainer) {
277  ATH_MSG_WARNING( "Asked for ETThresholdMain, but no LArRawChannelContainer, will not apply ! " );
278  m_ETThreshMain = -1.;
279  }
280 
281  if ((std::find(m_contKeys.begin(), m_contKeys.end(), "SC_ADC_BAS") != m_contKeys.end()) ){
282  sc = evtStore()->retrieve(DigitContainer_next,"SC_ADC_BAS");
283  if (sc.isFailure()) {
284  ATH_MSG_WARNING( "Unable to retrieve LArDigitContainer with key SC_ADC_BAS from DetectorStore. " );
285  }
286  else
287  ATH_MSG_DEBUG( "Got additional LArDigitContainer with key SC_ADC_BAS " );
288  }
289 
290  if ((std::find(m_contKeys.begin(), m_contKeys.end(), "SC_ET") != m_contKeys.end()) ){
291  sc = evtStore()->retrieve(etcontainer,"SC_ET");
292  if (sc.isFailure()) {
293  ATH_MSG_WARNING( "Unable to retrieve LArRawSCContainer with key SC_ET from DetectorStore. " );
294  }
295  else
296  ATH_MSG_DEBUG( "Got LArRawSCContainer with key SC_ET " );
297  }
298 
299  if ((std::find(m_contKeys.begin(), m_contKeys.end(), "SC_ET_ID") != m_contKeys.end()) ){
300  sc = evtStore()->retrieve(etcontainer_next,"SC_ET_ID");
301  if (sc.isFailure()) {
302  ATH_MSG_WARNING( "Unable to retrieve LArRawSCContainer with key SC_ET_ID from DetectorStore. " );
303  }
304  else
305  ATH_MSG_DEBUG( "Got LArRawSCContainer with key SC_ET_ID" );
306  }
307 
309  if (! hdrCont.isValid()) {
310  ATH_MSG_WARNING( "No LArLATOME container found in TDS" );
311  } else {
312  ATH_MSG_DEBUG( "LArLATOME container found");
313  headcontainer=&*hdrCont;
314  if(headcontainer != nullptr && *hdrCont->begin()) thisELVL1Id = (*hdrCont->begin())->L1Id();
315  ATH_MSG_DEBUG( " ELVL1I FROM LATOME HEADER " << thisELVL1Id );
316  }
317 
318  if (headcontainer){// loop through header container and fill map
319  for (const LArLATOMEHeader* hit : *headcontainer) {
320  LATOMEHeadMap.try_emplace ( hit->SourceId(), hit );
321  }
322  }
323  if(m_fillRawChan && RawChannelContainer){
324  for (const LArRawChannel& raw : *RawChannelContainer) {
325  rawChannelMap.try_emplace( raw.channelID(), &raw );
326  }
327  }
328  const LArOnOffIdMapping* cabling=nullptr;
329  const LArOnOffIdMapping* cablingROD=nullptr;
330  if(m_fillRawChan){
332  cabling=*cablingHdl;
333  if(!cabling) {
334  ATH_MSG_ERROR( "Do not have cabling for SC!" );
335  return StatusCode::FAILURE;
336  }
338  cablingROD=*cablingHdlROD;
339  if(!cablingROD) {
340  ATH_MSG_ERROR( "Do not have cabling for ROD!" );
341  return StatusCode::FAILURE;
342  }
343  }
344 
346  if( DigitContainer_next && DigitContainer_next->empty() ) DigitContainer_next = nullptr;
347 
348  if( etcontainer && etcontainer->empty() ) etcontainer = nullptr;
349 
350  if( etcontainer_next && etcontainer_next->empty() ) etcontainer_next = nullptr;
351 
352  int cellsno = 0;
353  if (hasDigitContainer) {
354  if( !DigitContainer->empty() ) cellsno = DigitContainer->size();
355  else {
356  ATH_MSG_WARNING("DigitContainer has zero size, but asked, will be not filled... ");
357  return StatusCode::SUCCESS;
358  }
359  }
360  ATH_MSG_DEBUG("DigitContainer has size: "<<cellsno<<" hasDigitContainer: "<<hasDigitContainer);
361 
362  if(m_ETThresh > 0. && !etcontainer && !etcontainer_next) {
363  ATH_MSG_WARNING( "Asked for ETThreshold, but no SC_ET* container, will not apply ! " );
364  m_ETThresh = -1.;
365  }
366 
367  if(m_ETThresh > 0. || m_ETThreshMain > 0.) {
369  ATH_CHECK(caloMgrHandle.isValid());
370  m_caloMgrSC = *caloMgrHandle;
371  }
372 
373  if(m_ADCThresh > 0. && ! DigitContainer&& !DigitContainer_next) {
374  ATH_MSG_WARNING( "Asked for ADCThreshold, but no digits container, will not apply ! " );
375  m_ADCThresh = -1.;
376  }
377 
378  if (hasAccCalibDigitContainer) {
379  if( !AccCalibDigitContainer->empty() ) {
380  cellsno = AccCalibDigitContainer->size();
381  ATH_MSG_DEBUG("AccCalibDigitContainer has size: "<<cellsno<<" hasAccCalibDigitContainer: "<<hasAccCalibDigitContainer);
382  } else {
383  ATH_MSG_WARNING("AccCalibDigitContainer has zero size, but asked, will be not filled... ");
384  return StatusCode::SUCCESS;
385  }
386  }
387  if (hasAccDigitContainer) {
388  if( !AccDigitContainer->empty() ) {
389  cellsno = AccDigitContainer->size();
390  ATH_MSG_DEBUG("AccDigitContainer has size: "<<cellsno<<" hasAccDigitContainer: "<<hasAccDigitContainer);
391  } else {
392  ATH_MSG_WARNING("AccDigitContainer has zero size, but asked, will be not filled... ");
393  return StatusCode::SUCCESS;
394  }
395  }
396 
397  if (DigitContainer_next){
398  if ( cellsno == 0 ){
399  cellsno = DigitContainer_next->size();
400  }else if(DigitContainer_next->size() != (unsigned)cellsno ){ ATH_MSG_ERROR(" NOOOOOOO! Different number of entries in DigitContainer_next"<< cellsno << " " << DigitContainer_next->size() );
401  }
402  }
403  if (etcontainer){
404  if ( cellsno == 0 ){
405  cellsno = etcontainer->size();
406  }else if(etcontainer->size() != (unsigned)cellsno ){ ATH_MSG_ERROR(" NOOOOOOO! Different number of entries in etcontainer"<< cellsno << " " << etcontainer->size() );
407  }
408  }
409  if (etcontainer_next){
410  if ( cellsno == 0 ){
411  cellsno = etcontainer_next->size();
412  }else if(etcontainer_next->size() != (unsigned)cellsno ){ ATH_MSG_ERROR(" NOOOOOOO! Different number of entries in etcontainer_next"<< cellsno << " " << etcontainer_next->size() );
413  }
414  }
415  unsigned cellCounter = 0;
416  ATH_MSG_DEBUG("cellsno size: "<<cellsno);
417 
418  for( int c = 0;c<cellsno;++c ){
419  if(m_fillBCID) m_bcid = thisbcid;
420 
421  m_ELVL1Id = thisELVL1Id;
422  m_IEvent = thisevent;
423  if(m_overwriteEventNumber) m_IEvent = ctx.evt();
424 
425  bool acceptETMain = true;
426 
427  if( hasAccDigitContainer ){
428 
429  const LArAccumulatedDigit* digi = AccDigitContainer->at(c);
430  // ======================
431 
432 
433  unsigned int trueMaxSample = digi->nsample();
434 
435  if(trueMaxSample>m_Nsamples){
436  if(!m_ipass){
437  ATH_MSG_DEBUG( "The number of samples in data is larger than the one specified by JO: " << trueMaxSample << " > " << m_Nsamples << " --> only " << m_Nsamples << " will be available in the ntuple " );
438  m_ipass = 1;
439  }
440  trueMaxSample = m_Nsamples;
441  }
442  m_ntNsamples = trueMaxSample;
443 
444  fillFromIdentifier(digi->hardwareID());
445 
446  float adcmax=-1.;
447  for(unsigned i = 0; i<trueMaxSample;++i) {
448  m_mean[i] = digi->mean(i);
449  m_RMS[i] = digi->RMS(i);
450  if(m_ADCThresh > 0 && m_mean[i]>adcmax) adcmax=m_mean[i];
451  }
452  if(m_ADCThresh > 0 && adcmax-m_mean[0] <= m_ADCThresh) continue;
453 
454  }//hasAccDigitContainer
455 
456  if( hasAccCalibDigitContainer ){
457 
458  const LArAccumulatedCalibDigit* digi = AccCalibDigitContainer->at(c);
459  // ======================
460 
461 
462  unsigned int trueMaxSample = digi->nsamples();
463 
464  if(trueMaxSample>m_Nsamples){
465  if(!m_ipass){
466  ATH_MSG_DEBUG( "The number of samples in data is larger than the one specified by JO: " << trueMaxSample << " > " << m_Nsamples << " --> only " << m_Nsamples << " will be available in the ntuple " );
467  m_ipass = 1;
468  }
469  trueMaxSample = m_Nsamples;
470  }
471  m_ntNsamples = trueMaxSample;
472 
473  fillFromIdentifier(digi->hardwareID());
474 
475  float adcmax=-1.;
476  for(unsigned i = 0; i<trueMaxSample;++i) {
477  m_mean[i] = digi->mean(i);
478  m_RMS[i] = digi->RMS(i);
479  if(m_ADCThresh > 0 && m_mean[i]>adcmax) adcmax=m_mean[i];
480  }
481  if(m_ADCThresh > 0 && adcmax-m_mean[0] <= m_ADCThresh) continue;
482  m_dac = digi->DAC();
483  m_delay = digi->delay();
484  m_pulsed = digi->getIsPulsedInt();
485 
486  }//hasAccCalibDigitContainer
487 
488  if( hasDigitContainer ){
489 
490  const LArDigit* digi = DigitContainer->at(c);
491  // ======================
492 
493  unsigned int trueMaxSample = digi->nsamples();
494 
495  if(trueMaxSample>m_Nsamples){
496  if(!m_ipass){
497  ATH_MSG_DEBUG( "The number of samples in data is larger than the one specified by JO: " << trueMaxSample << " > " << m_Nsamples << " --> only " << m_Nsamples << " will be available in the ntuple " );
498  m_ipass = 1;
499  }
500  trueMaxSample = m_Nsamples;
501  }
502  m_ntNsamples = trueMaxSample;
503 
504  fillFromIdentifier(digi->hardwareID());
505 
506  if(m_FTlist.size() > 0) { // should do a selection
507  if(std::find(std::begin(m_FTlist), std::end(m_FTlist), m_FT) == std::end(m_FTlist)) { // is our FT in list ?
508  continue;
509  }
510  }
511 
512  if( m_fillRawChan && RawChannelContainer ){
513  fillRODEnergy(digi->hardwareID(), rawChannelMap, cabling, cablingROD, acceptETMain);
514  if(!acceptETMain) continue; // do not pass the ETThreshMain cut
515  }
516 
517  short adcmax=0;
518  for(unsigned i = 0; i<trueMaxSample;++i) {
519  m_samples[i] = digi->samples().at(i);
520  if(m_ADCThresh > 0 && m_samples[i]>adcmax) adcmax=m_samples[i];
521  }
522  if(m_ADCThresh > 0 && adcmax-m_samples[0] <= m_ADCThresh) continue;
523 
524  const LArSCDigit* scdigi = dynamic_cast<const LArSCDigit*>(digi);
525  if(!scdigi){
526  ATH_MSG_DEBUG(" Can't cast digi to LArSCDigit*");
527  }else{
528  if (headcontainer){
529  ATH_MSG_DEBUG(" Accessing LATOME header ");
530  const LArLATOMEHeader*headmap = LATOMEHeadMap[scdigi->SourceId()];
531  if(headmap){
532  m_bcidLATOMEHEAD = headmap->BCId();
533  m_ELVL1Id = headmap->L1Id();
534  }
535  }
536  m_latomeChannel = scdigi->Channel();
537  unsigned int trueMaxBcid = trueMaxSample;
538  if(trueMaxBcid > scdigi->BCId().size()) trueMaxBcid=scdigi->BCId().size();
539  for( unsigned i = 0; i<trueMaxBcid; ++i){
540  m_bcidVec[i] = scdigi->BCId().at(i);
541  }
542  m_latomeSourceId = scdigi->SourceId();
543  }
544 
545 
546  }//hasDigitContainer
547  ATH_MSG_DEBUG("After hasDigitContainer ");
548 
549 
550  // DigitContainer 1 -> SC_ADC_BAS
551  if( DigitContainer_next ){
552 
553  const LArDigit* digi = DigitContainer_next->at(c);
554 
555  unsigned int trueMaxSample = digi->nsamples();
556 
557  if(trueMaxSample>m_Nsamples){
558  if(!m_ipass){
559  ATH_MSG_DEBUG( "The number of samples in data is larger than the one specified by JO: " << trueMaxSample << " > " << m_Nsamples << " --> only " << m_Nsamples << " will be available in the ntuple " );
560  m_ipass=1;
561  }
562  trueMaxSample = m_Nsamples;
563  }
564  m_ntNsamples = trueMaxSample;
565 
566  if( !hasDigitContainer){
568  if( m_fillRawChan && RawChannelContainer ){
569  fillRODEnergy(digi->hardwareID(), rawChannelMap, cabling, cablingROD, acceptETMain);
570  if(!acceptETMain) continue; // do not pass the ETThreshMain cut
571  }
572  }
573 
574  short adcmax=0;
575  for(unsigned i = 0; i<trueMaxSample;++i) {
576  m_samples_ADC_BAS[i] = digi->samples().at(i);
577  if(m_ADCThresh > 0 && m_samples_ADC_BAS[i]>adcmax) adcmax=m_samples_ADC_BAS[i];
578  }
579  if(m_ADCThresh > 0 && adcmax-m_samples_ADC_BAS[0] <= m_ADCThresh) continue;
580 
581  const LArSCDigit* scdigi = dynamic_cast<const LArSCDigit*>(digi);
582  if(!scdigi){ ATH_MSG_DEBUG(" Can't cast digi to LArSCDigit*");
583  }else{
584  if (headcontainer){
585  const LArLATOMEHeader*headmap = LATOMEHeadMap[scdigi->SourceId()];
586  if(headmap){
587  m_bcidLATOMEHEAD = headmap->BCId();
588  m_ELVL1Id = headmap->L1Id();
589  }
590  }
591  m_latomeChannel = scdigi->Channel();
592  for( unsigned i = 0; i<trueMaxSample;++i){
593  m_bcidVec[i] = scdigi->BCId().at(i);
594  }
595  m_latomeSourceId = scdigi->SourceId();
596  }
597 
598  }
599  ATH_MSG_DEBUG("After DigitContainer_next ");
600 
601 
602 
603  // etcontainer -> SC_ET
604  if( etcontainer ){
605  const LArRawSC*rawSC = etcontainer->at(c);
606 
607  if ( !hasDigitContainer && !DigitContainer_next ){
608  fillFromIdentifier(rawSC->hardwareID());
609  m_latomeChannel = rawSC->chan();
610  if (headcontainer){
611  const LArLATOMEHeader*headmap = LATOMEHeadMap[rawSC->SourceId()];
612  if(headmap){
613  m_bcidLATOMEHEAD = headmap->BCId();
614  m_ELVL1Id = headmap->L1Id();
615  }
616  }
617  if( m_fillRawChan && RawChannelContainer ){
618  fillRODEnergy(rawSC->hardwareID(), rawChannelMap, cabling, cablingROD, acceptETMain);
619  if(!acceptETMain) continue; // do not pass the ETThreshMain cut
620  }
621  }
622  unsigned int truenet = m_Net;
623  if(truenet > rawSC->bcids().size()) truenet=rawSC->bcids().size();
624  for( unsigned i=0; i<truenet;++i){ // just use the vector directly?
625  m_bcidVec_ET[i] = rawSC->bcids().at(i);
626  }
627  if(truenet > rawSC->energies().size()) truenet=rawSC->energies().size();
628  unsigned i;
629  for( i=0; i<truenet;++i){ // just use the vector directly?
630  m_energyVec_ET[i] = rawSC->energies().at(i);
631  if(rawSC->bcids().size()) {
632  if(m_ETThresh > 0. && m_bcidVec_ET[i] == thisbcid) { // our ET
633  if(m_energyVec_ET[i] < m_ETThresh) break;
634  }
635  } else {
636  if(m_ETThresh > 0. ) { // our ET
637  if(m_energyVec_ET[i] < m_ETThresh) break;
638  }
639  }
640  }
641  if(i<truenet) continue; // energy cut
642 
643  if(truenet > rawSC->satur().size()) truenet=rawSC->satur().size();
644  for( unsigned i = 0; i<truenet;++i){ // just use the vector directly?
645  m_saturVec_ET[i] = rawSC->satur().at(i);
646  }
647  m_Net=truenet;
648  m_ntNet=truenet;
649 
650  }
651  ATH_MSG_DEBUG("After etcontainer");
652  // etcontainer_next -> SC_ET_ID
653  if( etcontainer_next ){
654  const LArRawSC*rawSC = etcontainer_next->at(c);
655 
656  if ( !hasDigitContainer && !DigitContainer_next && !etcontainer ){
657  fillFromIdentifier(rawSC->hardwareID());
658  m_latomeChannel = rawSC->chan();
659  if (headcontainer){
660  const LArLATOMEHeader*headmap = LATOMEHeadMap[rawSC->SourceId()];
661  if(headmap){
662  m_bcidLATOMEHEAD = headmap->BCId();
663  m_ELVL1Id = headmap->L1Id();
664  }
665  }
666  if( m_fillRawChan && RawChannelContainer ){
667  fillRODEnergy(rawSC->hardwareID(), rawChannelMap, cabling, cablingROD, acceptETMain);
668  if(!acceptETMain) continue; // do not pass the ETThreshMain cut
669  }
670  }
671  ATH_MSG_DEBUG("Mid etcontainer_next "<<c);
672  for( unsigned i=0; i<rawSC->bcids().size();++i){ // just use the vector directly?
673  m_bcidVec_ET_ID[i] = rawSC->bcids()[i];
674  }
675  unsigned i;
676  for( i=0; i<rawSC->energies().size();++i){ // just use the vector directly?
677  m_energyVec_ET_ID[i] = rawSC->energies()[i];
678  if(rawSC->bcids().size()) {
679  if(m_ETThresh > 0. && m_bcidVec_ET_ID[i] == thisbcid) { // our ET
680  if(m_energyVec_ET_ID[i] < m_ETThresh) break;
681  }
682  } else {
683  if(m_ETThresh > 0.) { // our ET
684  if(m_energyVec_ET_ID[i] < m_ETThresh) break;
685  }
686  }
687  }
688  if(i<rawSC->energies().size()) {
689  continue; // energy cut
690  }
691 
692  for( unsigned i = 0; i<rawSC->satur().size();++i){ // just use the vector directly?
693  m_saturVec_ET_ID[i] = rawSC->satur()[i];
694  }
695  }
696  ATH_MSG_DEBUG("After etcontainer_next");
697 
698  sc = ntupleSvc()->writeRecord(m_nt);
699  if (sc != StatusCode::SUCCESS) {
700  ATH_MSG_ERROR( "writeRecord failed" );
701  return sc;
702  }
703  cellCounter++;
704  }// over cells
705 
706  if(m_fillTType) {
707  m_TType = thisttype;
708  m_IEventEvt = thisevent;
710  m_LB = thislb;
711 
712  for (auto const & x : m_trigNames) {
713  if( ! m_trigDec->getListOfTriggers(x).empty() ){
714  m_trigNameMap[x] = m_trigDec->isPassedBits( x );
715  }
716  }
717  m_LArEventBits = evt->eventFlags(xAOD::EventInfo::LAr);
718  m_LArInError = 0;
721 
722  }
723 
724  if(m_fillCaloTT){
725  const DataVector<LVL1::TriggerTower>* TTVector = nullptr;
726  if ( evtStore()->retrieve(TTVector,m_triggerTowerKey).isFailure() ) {
727  ATH_MSG_WARNING("Could not get the Calo TTs, will not fill...");
728  } else {
729  unsigned count=0;
730  ATH_MSG_INFO("Got TT vector of the sixe " << TTVector->size());
732  for ( x = TTVector->begin(); x < TTVector->end(); ++x ){
733  m_TTeta[count]=(*x)->eta();
734  m_TTphi[count]=(*x)->phi();
735  m_TTEem[count]=(*x)->emEnergy();
736  m_TTEhad[count]=(*x)->hadEnergy();
737  ++count;
738  if(count==20000) break;
739  }
740  m_ntNTT=count;
741  }
742  }
743 
744  if(m_fillTType || m_fillCaloTT){
745  sc = ntupleSvc()->writeRecord(m_evt_nt);
746  if (sc != StatusCode::SUCCESS) {
747  ATH_MSG_ERROR( "writeRecord failed" );
748  return sc;
749  }
750  }
751 
752  ATH_MSG_DEBUG( "LArSC2Ntuple has finished, filled " << cellCounter << " cells");
753  return StatusCode::SUCCESS;
754 }// end execute-method.
755 
756 void LArSC2Ntuple::fillRODEnergy(HWIdentifier SCId, rawChanMap_t &rawChanMap, const LArOnOffIdMapping* cabling, const LArOnOffIdMapping* cablingROD, bool &acceptETMain)
757 {
758  const Identifier offId = cabling->cnvToIdentifier(SCId);
759  const std::vector<Identifier> cellIds = m_scidtool->superCellToOfflineID(offId);
760  std::fill(m_ROD_energy.begin(), m_ROD_energy.end(), 0.);
761  std::fill(m_ROD_time.begin(), m_ROD_time.end(), 0.);
762  std::fill(m_ROD_id.begin(), m_ROD_id.end(), 0.);
763  for(unsigned i=0; i<cellIds.size(); ++i ) {
764  const HWIdentifier hwcell=cablingROD->createSignalChannelID(cellIds[i]);
765  if (hwcell.is_valid() && (rawChanMap.count(hwcell) != 0) ) {
766  m_ROD_energy[i] = rawChanMap[hwcell]->energy();
767  m_ROD_time[i] = rawChanMap[hwcell]->time();
768  m_ROD_id[i] = rawChanMap[hwcell]->hardwareID().get_identifier32().get_compact();
769  } else {
770  ATH_MSG_DEBUG(i<<"-th cell invalid Id");
771  }
772  }
773  if(acceptETMain && m_ETThreshMain > 0. && m_caloMgrSC) { // check if cell is above threshold
774  auto result = std::reduce(m_ROD_energy.begin(), m_ROD_energy.end());
775  auto dde = m_caloMgrSC->get_element(offId);
776  if(dde && result / cosh(dde->eta()) < m_ETThreshMain) acceptETMain = false;
777  }
778 }
LArDigits2Ntuple::m_evt_nt
NTuple::Tuple * m_evt_nt
Definition: LArDigits2Ntuple.h:56
python.PyKernel.retrieve
def retrieve(aClass, aKey=None)
Definition: PyKernel.py:110
LArRawSC
Liquid Argon SuperCell raw data.
Definition: LArRawSC.h:19
LArAccumulatedCalibDigit
Data class for calibration ADC samples preprocessed by the DSP.
Definition: LArAccumulatedCalibDigit.h:42
LArSC2Ntuple::m_ROD_time
NTuple::Array< float > m_ROD_time
Definition: LArSC2Ntuple.h:63
LArSC2Ntuple::m_TTphi
NTuple::Array< double > m_TTphi
Definition: LArSC2Ntuple.h:96
LArSC2Ntuple::m_cablingKeyAdditional
SG::ReadCondHandleKey< LArOnOffIdMapping > m_cablingKeyAdditional
Definition: LArSC2Ntuple.h:46
LArSC2Ntuple::m_trigNames
Gaudi::Property< std::vector< std::string > > m_trigNames
Definition: LArSC2Ntuple.h:40
LArDigits2Ntuple::m_dac
NTuple::Item< unsigned int > m_dac
Definition: LArDigits2Ntuple.h:50
get_generator_info.result
result
Definition: get_generator_info.py:21
LArRawSCContainer.h
LArSC2Ntuple::m_LArLatomeHeaderContainerKey
SG::ReadHandleKey< LArLATOMEHeaderContainer > m_LArLatomeHeaderContainerKey
Definition: LArSC2Ntuple.h:53
SG::ReadCondHandle
Definition: ReadCondHandle.h:44
LArDigits2Ntuple::m_IEventEvt
NTuple::Item< unsigned long long > m_IEventEvt
Definition: LArDigits2Ntuple.h:58
ATH_MSG_INFO
#define ATH_MSG_INFO(x)
Definition: AthMsgStreamMacros.h:31
LArAccumulatedDigitContainer
Container class for LArAccumulatedDigit.
Definition: LArAccumulatedDigitContainer.h:22
find
std::string find(const std::string &s)
return a remapped string
Definition: hcg.cxx:135
SG::ReadHandle::cptr
const_pointer_type cptr()
Dereference the pointer.
LArSC2Ntuple::m_samples_ADC_BAS
NTuple::Array< short > m_samples_ADC_BAS
Definition: LArSC2Ntuple.h:77
FeatureContainer.h
SG::ReadHandle
Definition: StoreGate/StoreGate/ReadHandle.h:67
LArDigits2Ntuple::m_Nsamples
Gaudi::Property< unsigned int > m_Nsamples
Definition: LArDigits2Ntuple.h:31
LArRawSC::SourceId
unsigned int SourceId() const
Definition: LArRawSC.h:95
LArSC2Ntuple::m_bcidLATOMEHEAD
NTuple::Item< uint16_t > m_bcidLATOMEHEAD
Definition: LArSC2Ntuple.h:70
LArDigits2Ntuple::m_fillBCID
Gaudi::Property< bool > m_fillBCID
Definition: LArDigits2Ntuple.h:38
LArRawSCContainer
Container class for LArRawSC.
Definition: LArRawSCContainer.h:17
LArRawSC::hardwareID
const HWIdentifier & hardwareID() const
Definition: LArRawSC.h:89
LArDigits2Ntuple::m_fillLB
Gaudi::Property< bool > m_fillLB
Definition: LArDigits2Ntuple.h:39
LArAccumulatedCalibDigit::nsamples
size_t nsamples() const
return number of samples
Definition: LArAccumulatedCalibDigit.h:120
CaloDetDescrManager_Base::get_element
const CaloDetDescrElement * get_element(const Identifier &cellId) const
get element by its identifier
Definition: CaloDetDescrManager.cxx:159
LArSC2Ntuple::m_caloMgrSC
const CaloSuperCellDetDescrManager * m_caloMgrSC
Definition: LArSC2Ntuple.h:58
ReadCellNoiseFromCool.cabling
cabling
Definition: ReadCellNoiseFromCool.py:154
LArLATOMEHeaderContainer.h
PlotCalibFromCool.begin
begin
Definition: PlotCalibFromCool.py:94
LArDigit::samples
const std::vector< short > & samples() const
Definition: LArDigit.h:78
LArDigit::hardwareID
const HWIdentifier & hardwareID() const
Definition: LArDigit.h:66
Feature.h
LArAccumulatedDigit::mean
float mean(int n_min=-1, int n_max=-1) const
Calculates and returns the Mean value of ADC samples.
Definition: LArAccumulatedDigit.cxx:41
LArSC2Ntuple::m_energyVec_ET_ID
NTuple::Array< int > m_energyVec_ET_ID
Definition: LArSC2Ntuple.h:84
LArDigits2Ntuple::m_IEvent
NTuple::Item< unsigned long long > m_IEvent
Definition: LArDigits2Ntuple.h:45
LArG4FSStartPointFilter.evt
evt
Definition: LArG4FSStartPointFilter.py:42
LArSC2Ntuple::m_bcidVec
NTuple::Array< unsigned short > m_bcidVec
Definition: LArSC2Ntuple.h:75
ChainGroup.h
LArLATOMEHeaderContainer
Container class for LArLATOMEHeader.
Definition: LArLATOMEHeaderContainer.h:19
SG::VarHandleKey::key
const std::string & key() const
Return the StoreGate ID for the referenced object.
Definition: AthToolSupport/AsgDataHandles/Root/VarHandleKey.cxx:141
LArSC2Ntuple::rawChanMap_t
std::map< HWIdentifier, const LArRawChannel * > rawChanMap_t
Definition: LArSC2Ntuple.h:28
HWIdentifier
Definition: HWIdentifier.h:13
LArSC2Ntuple::m_ntNet
NTuple::Item< uint32_t > m_ntNet
Definition: LArSC2Ntuple.h:72
LArSCDigit::SourceId
unsigned int SourceId() const
Definition: LArSCDigit.h:45
x
#define x
xAOD::EventInfo_v1::LAr
@ LAr
The LAr calorimeter.
Definition: EventInfo_v1.h:335
LArAccumulatedCalibDigit::getIsPulsedInt
uint16_t getIsPulsedInt() const
get the four bit int that tells which lines pulsed
Definition: LArAccumulatedCalibDigit.h:153
Identifier::is_valid
bool is_valid() const
Check if id is in a valid state.
LArDigits2Ntuple::m_ntNsamples
NTuple::Item< long > m_ntNsamples
Definition: LArDigits2Ntuple.h:41
LArDigits2Ntuple::m_ELVL1Id
NTuple::Item< unsigned long > m_ELVL1Id
Definition: LArDigits2Ntuple.h:44
LArRawSC::satur
const std::vector< bool > & satur() const
Definition: LArRawSC.h:107
LArCond2NtupleBase::cablingKey
const SG::ReadCondHandleKey< LArOnOffIdMapping > & cablingKey() const
Definition: LArCond2NtupleBase.cxx:449
XMLtoHeader.count
count
Definition: XMLtoHeader.py:85
reduce
void reduce(HepMC::GenEvent *ge, std::vector< HepMC::GenParticlePtr > toremove)
Remove unwanted particles from the event, collapsing the graph structure consistently.
Definition: FixHepMC.cxx:83
AthenaPoolTestRead.sc
sc
Definition: AthenaPoolTestRead.py:27
mergePhysValFiles.end
end
Definition: DataQuality/DataQualityUtils/scripts/mergePhysValFiles.py:93
xAOD::EventInfo_v1::Error
@ Error
The sub-detector issued an error.
Definition: EventInfo_v1.h:349
LArLATOMEHeader::L1Id
uint32_t L1Id() const
get the L1 Id
Definition: LArLATOMEHeader.h:44
LArAccumulatedDigit::hardwareID
const HWIdentifier & hardwareID() const
Return HWIdentifier.
Definition: LArAccumulatedDigit.h:70
LArSC2Ntuple::LArSC2Ntuple
LArSC2Ntuple(const std::string &name, ISvcLocator *pSvcLocator)
Definition: LArSC2Ntuple.cxx:15
LArSC2Ntuple::m_saturVec_ET
NTuple::Array< bool > m_saturVec_ET
Definition: LArSC2Ntuple.h:82
LArSC2Ntuple::m_eventInfoKey
SG::ReadHandleKey< xAOD::EventInfo > m_eventInfoKey
Definition: LArSC2Ntuple.h:50
LArDigits2Ntuple::m_event
long m_event
Definition: LArDigits2Ntuple.h:29
python.setupRTTAlg.size
int size
Definition: setupRTTAlg.py:39
LArSC2Ntuple::m_saturVec_ET_ID
NTuple::Array< bool > m_saturVec_ET_ID
Definition: LArSC2Ntuple.h:86
AthCommonDataStore< AthCommonMsg< Algorithm > >::evtStore
ServiceHandle< StoreGateSvc > & evtStore()
The standard StoreGateSvc (event store) Returns (kind of) a pointer to the StoreGateSvc.
Definition: AthCommonDataStore.h:85
LArDigits2Ntuple::m_FTlist
Gaudi::Property< std::vector< unsigned int > > m_FTlist
Definition: LArDigits2Ntuple.h:32
LArSC2Ntuple::m_ETThreshMain
Gaudi::Property< float > m_ETThreshMain
Definition: LArSC2Ntuple.h:43
LArSC2Ntuple::m_TTEhad
NTuple::Array< int > m_TTEhad
Definition: LArSC2Ntuple.h:94
LArDigits2Ntuple::m_bcid
NTuple::Item< short > m_bcid
Definition: LArDigits2Ntuple.h:43
LArAccumulatedDigit
Data class for ADC samples and autocorr preprocessed by the DSP.
Definition: LArAccumulatedDigit.h:32
LArSC2Ntuple::m_TTEem
NTuple::Array< int > m_TTEem
Definition: LArSC2Ntuple.h:93
LArDigits2Ntuple::m_RMS
NTuple::Array< float > m_RMS
Definition: LArDigits2Ntuple.h:49
ATH_MSG_ERROR
#define ATH_MSG_ERROR(x)
Definition: AthMsgStreamMacros.h:33
LArDigit::nsamples
int nsamples() const
Definition: LArDigit.h:75
LArDigits2Ntuple::m_pulsed
NTuple::Item< unsigned int > m_pulsed
Definition: LArDigits2Ntuple.h:52
LArSC2Ntuple::m_bcidVec_ET_ID
NTuple::Array< unsigned short > m_bcidVec_ET_ID
Definition: LArSC2Ntuple.h:85
LArDigit
Liquid Argon digit base class.
Definition: LArDigit.h:25
lumiFormat.i
int i
Definition: lumiFormat.py:85
LArSC2Ntuple::m_latomeSourceId
NTuple::Item< uint32_t > m_latomeSourceId
Definition: LArSC2Ntuple.h:76
LArRawChannel
Liquid Argon ROD output object base class.
Definition: LArRawChannel.h:40
LArAccumulatedDigit::nsample
int nsample() const
return number of samples
Definition: LArAccumulatedDigit.h:79
LArSC2Ntuple::m_LArEventBits
NTuple::Item< uint32_t > m_LArEventBits
Definition: LArSC2Ntuple.h:89
EL::StatusCode
::StatusCode StatusCode
StatusCode definition for legacy code.
Definition: PhysicsAnalysis/D3PDTools/EventLoop/EventLoop/StatusCode.h:22
LArAccumulatedCalibDigit::RMS
std::vector< float > RMS() const
Calculates and returns the RMS value of each ADC sample.
Definition: LArAccumulatedCalibDigit.cxx:50
ATH_MSG_DEBUG
#define ATH_MSG_DEBUG(x)
Definition: AthMsgStreamMacros.h:29
LArCond2NtupleBase::m_ntpath
std::string m_ntpath
Definition: LArCond2NtupleBase.h:65
LArSC2Ntuple::m_fillRawChan
Gaudi::Property< bool > m_fillRawChan
Definition: LArSC2Ntuple.h:38
LArSC2Ntuple::m_fillTType
Gaudi::Property< bool > m_fillTType
Definition: LArSC2Ntuple.h:39
LArCond2NtupleBase::m_nt
NTuple::Tuple * m_nt
Definition: LArCond2NtupleBase.h:68
LArRawSC::chan
short chan() const
Definition: LArRawSC.h:92
LArSCDigit.h
LArLATOMEHeader::BCId
uint16_t BCId() const
get the Bunch Crossing IDs
Definition: LArLATOMEHeader.h:41
LArSC2Ntuple::m_eventInfoDecorKey
SG::ReadDecorHandleKey< xAOD::EventInfo > m_eventInfoDecorKey
Definition: LArSC2Ntuple.h:51
ATH_CHECK
#define ATH_CHECK
Definition: AthCheckMacros.h:40
CHECK
#define CHECK(...)
Evaluate an expression and check for errors.
Definition: Control/AthenaKernel/AthenaKernel/errorcheck.h:422
LArSC2Ntuple::execute
virtual StatusCode execute() override
Definition: LArSC2Ntuple.cxx:201
LArDigits2Ntuple::m_accContKey
SG::ReadHandleKey< LArAccumulatedDigitContainer > m_accContKey
Definition: LArDigits2Ntuple.h:63
LArSC2Ntuple::m_trigDec
ToolHandle< Trig::TrigDecisionTool > m_trigDec
Definition: LArSC2Ntuple.h:48
SG::VarHandleKey::initialize
StatusCode initialize(bool used=true)
If this object is used as a property, then this should be called during the initialize phase.
Definition: AthToolSupport/AsgDataHandles/Root/VarHandleKey.cxx:103
LArSC2Ntuple::m_latomeChannel
NTuple::Item< short > m_latomeChannel
Definition: LArSC2Ntuple.h:60
LArSCDigit::Channel
short Channel() const
Definition: LArSCDigit.h:42
LArSC2Ntuple::m_energyVec_ET
NTuple::Array< int > m_energyVec_ET
Definition: LArSC2Ntuple.h:80
LArSC2Ntuple::m_overwriteEventNumber
Gaudi::Property< bool > m_overwriteEventNumber
Definition: LArSC2Ntuple.h:36
LArSC2Ntuple::m_TType
NTuple::Item< unsigned int > m_TType
Definition: LArSC2Ntuple.h:66
DataVector< LVL1::TriggerTower >
LArSC2Ntuple::m_bcidVec_ET
NTuple::Array< unsigned short > m_bcidVec_ET
Definition: LArSC2Ntuple.h:81
LArAccumulatedCalibDigit::hardwareID
const HWIdentifier & hardwareID() const
Return HWIdentifier.
Definition: LArAccumulatedCalibDigit.h:111
LArDigits2Ntuple::m_ipass
int m_ipass
Definition: LArDigits2Ntuple.h:28
LArOnOffIdMapping::createSignalChannelID
HWIdentifier createSignalChannelID(const Identifier &id) const
create a HWIdentifier from an Identifier (not inline)
Definition: LArOnOffIdMapping.h:126
LArSC2Ntuple::m_contKeys
Gaudi::Property< std::vector< std::string > > m_contKeys
Definition: LArSC2Ntuple.h:35
LArSCDigit
Base class for LArDigits taken by LATOME.
Definition: LArSCDigit.h:19
SG::ReadHandle::isValid
virtual bool isValid() override final
Can the handle be successfully dereferenced?
LArAccumulatedDigit::RMS
float RMS(int n_min=-1, int n_max=-1) const
Calculates and returns the RMS value of ADC samples
Definition: LArAccumulatedDigit.cxx:64
fill
void fill(H5::Group &out_file, size_t iterations)
Definition: test-hdf5-writer.cxx:95
LArSC2Ntuple::m_ROD_id
NTuple::Array< float > m_ROD_id
Definition: LArSC2Ntuple.h:64
LArSC2Ntuple::m_triggerTowerKey
Gaudi::Property< std::string > m_triggerTowerKey
Definition: LArSC2Ntuple.h:54
LArAccumulatedCalibDigit::mean
std::vector< float > mean() const
Calculates and returns the Mean value of each ADC sample.
Definition: LArAccumulatedCalibDigit.cxx:36
LArSC2Ntuple::m_ntNTT
NTuple::Item< uint32_t > m_ntNTT
Definition: LArSC2Ntuple.h:92
name
std::string name
Definition: Control/AthContainers/Root/debug.cxx:240
LArSC2Ntuple::fillRODEnergy
void fillRODEnergy(HWIdentifier SCId, rawChanMap_t &rawChanMap, const LArOnOffIdMapping *cabling, const LArOnOffIdMapping *cablingROD, bool &acceptMain)
Definition: LArSC2Ntuple.cxx:756
LArDigits2Ntuple
Definition: LArDigits2Ntuple.h:17
LArCond2NtupleBase::m_ntTitle
std::string m_ntTitle
Definition: LArCond2NtupleBase.h:65
LArDigits2Ntuple::m_contKey
SG::ReadHandleKey< LArDigitContainer > m_contKey
Definition: LArDigits2Ntuple.h:61
SG::CondHandleKey::initialize
StatusCode initialize(bool used=true)
LArSC2Ntuple::m_ROD_energy
NTuple::Array< float > m_ROD_energy
Definition: LArSC2Ntuple.h:62
LArSC2Ntuple::m_ADCThresh
Gaudi::Property< float > m_ADCThresh
Definition: LArSC2Ntuple.h:44
LArAccumulatedCalibDigit::delay
int delay() const
return the setting of the delay
Definition: LArAccumulatedCalibDigit.h:138
LArRawSC::bcids
const std::vector< unsigned short > & bcids() const
Definition: LArRawSC.h:104
LArSC2Ntuple::m_scidtool
ToolHandle< ICaloSuperCellIDTool > m_scidtool
Definition: LArSC2Ntuple.h:47
LArCond2NtupleBase::fillFromIdentifier
bool fillFromIdentifier(const HWIdentifier &id)
Definition: LArCond2NtupleBase.cxx:288
xAOD::EventInfo_v1::Warning
@ Warning
The sub-detector issued a warning.
Definition: EventInfo_v1.h:348
LArLATOMEHeader
Holds information from the LATOME Header.
Definition: LArLATOMEHeader.h:19
LArDigits2Ntuple::initialize
virtual StatusCode initialize()
Definition: LArDigits2Ntuple.cxx:23
ATH_MSG_WARNING
#define ATH_MSG_WARNING(x)
Definition: AthMsgStreamMacros.h:32
LArSC2Ntuple::m_ETThresh
Gaudi::Property< float > m_ETThresh
Definition: LArSC2Ntuple.h:42
LArDigits2Ntuple::m_delay
NTuple::Item< unsigned int > m_delay
Definition: LArDigits2Ntuple.h:51
LArCond2NtupleBase::m_isSC
Gaudi::Property< bool > m_isSC
Definition: LArCond2NtupleBase.h:55
LArDigits2Ntuple::m_mean
NTuple::Array< float > m_mean
Definition: LArDigits2Ntuple.h:48
LArDigits2Ntuple::m_samples
NTuple::Array< short > m_samples
Definition: LArDigits2Ntuple.h:46
LArDigitContainer
Container class for LArDigit.
Definition: LArDigitContainer.h:24
LArSC2Ntuple::initialize
virtual StatusCode initialize() override
Definition: LArSC2Ntuple.cxx:21
LArSC2Ntuple::m_Net
Gaudi::Property< unsigned int > m_Net
Definition: LArSC2Ntuple.h:37
LArSC2Ntuple::m_bcidVec_ADC_BAS
NTuple::Array< unsigned short > m_bcidVec_ADC_BAS
Definition: LArSC2Ntuple.h:78
DataVector::at
const T * at(size_type n) const
Access an element, as an rvalue.
LArDigits2Ntuple::m_accCalibContKey
SG::ReadHandleKey< LArAccumulatedCalibDigitContainer > m_accCalibContKey
Definition: LArDigits2Ntuple.h:62
ntupleSvc
INTupleSvc * ntupleSvc()
Definition: ServiceAccessor.h:14
LArAccumulatedCalibDigitContainer
Container class for LArAccumulatedCalibDigit.
Definition: LArAccumulatedCalibDigitContainer.h:25
python.compressB64.c
def c
Definition: compressB64.py:93
LArSCDigit::BCId
const std::vector< unsigned short > & BCId() const
Definition: LArSCDigit.h:48
DataVector::size
size_type size() const noexcept
Returns the number of elements in the collection.
LArSC2Ntuple::m_LArInError
NTuple::Item< short > m_LArInError
Definition: LArSC2Ntuple.h:90
LArCond2NtupleBase::m_FT
NTuple::Item< long > m_FT
Definition: LArCond2NtupleBase.h:72
LArDigits2Ntuple::m_LB
NTuple::Item< short > m_LB
Definition: LArDigits2Ntuple.h:59
LArSC2Ntuple::m_TTeta
NTuple::Array< double > m_TTeta
Definition: LArSC2Ntuple.h:95
DataVector::empty
bool empty() const noexcept
Returns true if the collection is empty.
LArSC2Ntuple::m_trigNameMap
std::map< std::string, NTuple::Item< unsigned int > > m_trigNameMap
Definition: LArSC2Ntuple.h:88
LArSC2Ntuple.h
LArSC2Ntuple::m_fillCaloTT
Gaudi::Property< bool > m_fillCaloTT
Definition: LArSC2Ntuple.h:41
DataVector::begin
const_iterator begin() const noexcept
Return a const_iterator pointing at the beginning of the collection.
LArSC2Ntuple::m_caloSCMgrKey
SG::ReadCondHandleKey< CaloSuperCellDetDescrManager > m_caloSCMgrKey
Definition: LArSC2Ntuple.h:56
LArRawChannelContainer
Container for LArRawChannel (IDC using LArRawChannelCollection)
Definition: LArRawChannelContainer.h:26
LArOnOffIdMapping
Definition: LArOnOffIdMapping.h:20
LArRawSC::energies
const std::vector< int > & energies() const
Definition: LArRawSC.h:101
LArAccumulatedCalibDigit::DAC
int DAC() const
return the number of samples
Definition: LArAccumulatedCalibDigit.h:135
Identifier
Definition: IdentifierFieldParser.cxx:14