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

#include <TileRawChannelBuilderFlatFilter.h>

Inheritance diagram for TileRawChannelBuilderFlatFilter:
Collaboration diagram for TileRawChannelBuilderFlatFilter:

Public Member Functions

 TileRawChannelBuilderFlatFilter (const std::string &type, const std::string &name, const IInterface *parent)
 Constructor.
 ~TileRawChannelBuilderFlatFilter ()
 Destructor.
virtual StatusCode initialize ()
 Initializer.
virtual StatusCode finalize ()
virtual TileRawChannelrawChannel (const TileDigits *digits, const EventContext &ctx)
 Builder virtual method to be implemented by subclasses.
void flatFilter (const std::vector< uint32_t > &digits, const int gain, double &amplitude, double &time) const
 Filter given digits using FlatFilter method.
void flatFilter (const std::vector< float > &digits, const int gain, double &amplitude, double &time) const
 Filter given digits using FlatFilter method.
virtual StatusCode createContainer (const EventContext &ctx)
 Create container in SG with name given by parameter (m_rawChannelContainerKey)
virtual StatusCode commitContainer (const EventContext &ctx)
 Commit RawChannelContiner in SG and make const.
void initLog (const EventContext &ctx)
void endLog ()
StatusCode build (const TileDigitsCollection *collection, const EventContext &ctx)
void resetDrawer ()
void resetOverflows (void)
Overflows_tgetOverflowedChannels (void)
std::string getTileRawChannelContainerID (void)
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 sysInitialize () override
 Perform system initialization for an algorithm.
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

Static Public Member Functions

static const InterfaceID & interfaceID ()
 AlgTool InterfaceID.
static double correctAmp (double phase, bool of2=true)
 Amplitude correction factor according to the time when using weights for tau=0 without iterations.
static double correctTime (double phase, bool of2=true)
 Time correction factor.
static int CorruptedData (int ros, int drawer, int channel, int gain, const std::vector< float > &digits, float &dmin, float &dmax, float ADCmaxMinusEps, float ADCmaskValueMinusEps)
static const char * BadPatternName (float ped)

Protected Member Functions

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.

Protected Attributes

SG::ReadHandleKey< TileDQstatusm_DQstatusKey
SG::ReadHandleKey< TileRawChannelContainerm_DSPContainerKey {this, "DSPContainer", "", "DSP Container key"}
SG::WriteHandleKey< TileRawChannelContainerm_rawChannelContainerKey
std::unique_ptr< TileMutableRawChannelContainerm_rawChannelCnt
TileFragHash::TYPE m_rChType
TileRawChannelUnit::UNIT m_rChUnit
unsigned int m_bsflags
int m_firstSample
bool m_calibrateEnergy
bool m_correctTime
bool m_useDSP
float m_ampMinThresh
 correct amplitude if it's above amplitude threshold (in ADC counts)
float m_timeMinThresh
 correct amplitude is time is above time min threshold
float m_timeMaxThresh
 correct amplitude is time is below time max threshold
int m_runType
const TileIDm_tileID
const TileHWIDm_tileHWID
ToolHandleArray< ITileRawChannelToolm_noiseFilterTools
ToolHandle< TileCondToolEmscalem_tileToolEmscale
ToolHandle< TileCondToolTimingm_tileToolTiming
ToolHandle< TileCondIdTransformsm_tileIdTransforms
ServiceHandle< TileCablingSvcm_cablingSvc
 Name of Tile cabling service.
const TileCablingServicem_cabling
 TileCabling instance.
Gaudi::Property< std::vector< int > > m_demoFragIDs
int m_trigType
bool m_idophys
bool m_idolas
bool m_idoped
bool m_idocis
int m_cischan
double m_capdaq
unsigned int m_evtCounter
unsigned int m_chCounter
int m_nChL
int m_nChH
double m_RChSumL
double m_RChSumH
Overflows_t m_overflows
int m_dataPoollSize
int m_error [MAX_CHANNELS]
int m_lastDrawer = -1
bool m_badDrawer = false
bool m_notUpgradeCabling
std::string m_infoName
const TileInfom_tileInfo
int m_i_ADCmax
float m_f_ADCmax
int m_i_ADCmaxPlus1
float m_f_ADCmaxPlus1
float m_ADCmaxMinusEps
float m_ADCmaskValueMinusEps
 indicates channels which were masked in background dataset

Static Protected Attributes

static const int MAX_CHANNELS = 48
static const int MAX_DMUS = 16

Private Types

typedef ServiceHandle< StoreGateSvcStoreGateSvc_t

Private Member Functions

bool isSignalInFrame (const std::vector< float > &digits, double deltaCut, double rmsCut, int &frameMax, int &frameMin, double &frameMean, double &frameRMS) const
 Find min and max sample Calculate mean and RMS of all samples.
double getPedestal (const std::vector< float > &digits, int pedStart, int pedLgt) const
 Calculate pedestal as mean of <pedLgt> samples starting from <pedStart>
int getMaxAdder (const std::vector< float > &digits, int filterLength, int signalStart, int signalLength, int &tMax, int &tMaxFrame, int &adderFrame) const
 Get position of maximal adder (sum of <filterLength> samples) in whole frame and in signal window (<signalStart>-><signalStart>+<signalLength> Return position and value of maximal adder in frame.
int getMaxSample (const std::vector< float > &digits, int signalStart, int signalLength, int &tMax, int &tMaxFrame, int &sampleFrame) const
double calculatePeak (const std::vector< float > &digits, int peakPos, double ped, double &position) const
double calculateFlatFilter (const std::vector< float > &digits, int filterStart, int filterLength, double ped, double &position) const
 Calculate energy using flat filter Sum of <filterLength> samples starting at <filterStart> Requires pedestal value and returns position of peak.
double getTime (const std::vector< float > &digits, int signalStart, int signalLength, double ped) const
 Calculate the time of signal in window of <signalLength> starting at <signalStart> Result is sum of time for every sample weighted with amplitude and divided by sum of times.
void fill_drawer_errors (const EventContext &ctx, const TileDigitsCollection *collection)
Gaudi::Details::PropertyBase & declareGaudiProperty (Gaudi::Property< T, V, H > &hndl, const SG::VarHandleKeyType &)
 specialization for handling Gaudi::Property<SG::VarHandleKey>

Private Attributes

int m_pedStart
int m_pedLength
int m_pedOffset
int m_signalStart
int m_signalLength
int m_filterLength
int m_frameLength
double m_deltaCut [2]
double m_rmsCut [2]
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 39 of file TileRawChannelBuilderFlatFilter.h.

Member Typedef Documentation

◆ StoreGateSvc_t

typedef ServiceHandle<StoreGateSvc> AthCommonDataStore< AthCommonMsg< AlgTool > >::StoreGateSvc_t
privateinherited

Definition at line 388 of file AthCommonDataStore.h.

Constructor & Destructor Documentation

◆ TileRawChannelBuilderFlatFilter()

TileRawChannelBuilderFlatFilter::TileRawChannelBuilderFlatFilter ( const std::string & type,
const std::string & name,
const IInterface * parent )

Constructor.

Definition at line 41 of file TileRawChannelBuilderFlatFilter.cxx.

43 : TileRawChannelBuilder(type, name, parent)
44{
45 //declare interfaces
46 declareInterface< TileRawChannelBuilder >( this );
47 declareInterface< TileRawChannelBuilderFlatFilter >(this);
48
49 m_rawChannelContainerKey = "TileRawChannelFlat";
50
51 //declare properties
52 declareProperty("PedStart",m_pedStart = 0);
53 declareProperty("PedLength",m_pedLength = 1);
54 declareProperty("PedOffset",m_pedOffset = 0);
55 declareProperty("SignalStart",m_signalStart = 1);
56 declareProperty("SignalLength",m_signalLength = 8);
57 declareProperty("FilterLength",m_filterLength = 5);
58 declareProperty("FrameLength",m_frameLength = 9);
59 declareProperty("DeltaCutLo",m_deltaCut[0] = 4.5);
60 declareProperty("DeltaCutHi",m_deltaCut[1] = 8.5);
61 declareProperty("RMSCutLo",m_rmsCut[0] = 1.0);
62 declareProperty("RMSCutHi",m_rmsCut[1] = 2.5);
63}
Gaudi::Details::PropertyBase & declareProperty(Gaudi::Property< T, V, H > &t)
SG::WriteHandleKey< TileRawChannelContainer > m_rawChannelContainerKey
TileRawChannelBuilder(const std::string &type, const std::string &name, const IInterface *parent)
Constructor.

◆ ~TileRawChannelBuilderFlatFilter()

TileRawChannelBuilderFlatFilter::~TileRawChannelBuilderFlatFilter ( )

Destructor.

Definition at line 68 of file TileRawChannelBuilderFlatFilter.cxx.

68 {
69}

Member Function Documentation

◆ BadPatternName()

const char * TileRawChannelBuilder::BadPatternName ( float ped)
staticinherited

Definition at line 458 of file TileRawChannelBuilder.cxx.

458 {
459 static const char * const errname[26] = {
460 "-10 - good signal",
461 "-9 - underflow",
462 "-8 - overflow",
463 "-7 - underflow and overflow",
464 "-6 - constant signal",
465 "-5 - disconnected channel",
466 "-4 - half a drawer masked",
467 "-3 - bad DQ status",
468 "-2 - underflow in all samples",
469 "-1 - overflow in all samples",
470 "0 - unknown error",
471 "1 - jump from zero to saturation",
472 "2 - samples with zeros",
473 "3 - at least two saturated. others - close to pedestal",
474 "4 - two distinct levels with at least 2 samples each",
475 "5 - pedestal with jump up in one sample",
476 "6 - pedestal with jump down in one sample",
477 "7 - signal with jump up in one sample",
478 "8 - signal with jump down in one sample",
479 "9 - base line above threshold in low gain",
480 "10 - jump down in first sample in low gain",
481 "11 - jump down in last sample in low gain",
482 "12 - jump up in one sample above const",
483 "13 - jump down in one sample below const",
484 "14 - unrecoverable timing jump",
485 "15 - unknown error"
486 };
487
488 return errname[std::min(25, std::max(0, int((ped + 500) * 1e-4)))];
489}

◆ build()

StatusCode TileRawChannelBuilder::build ( const TileDigitsCollection * collection,
const EventContext & ctx )
inherited

Definition at line 492 of file TileRawChannelBuilder.cxx.

493{
494
495 int frag = coll->identify();
496
497 // make sure that error array is up-to-date
498 if (frag != m_lastDrawer && m_notUpgradeCabling) {
499 fill_drawer_errors(ctx, coll);
500 }
501
502 // Iterate over all digits in this collection
503 TileDigitsCollection::const_iterator digitItr = coll->begin();
504 TileDigitsCollection::const_iterator lastDigit = coll->end();
505
506 for (; digitItr != lastDigit; ++digitItr) {
507
508 TileRawChannel* rch = rawChannel((*digitItr), ctx);
509
511
512 int err = m_error[m_tileHWID->channel(rch->adc_HWID())];
513
514 if (err) {
515 if (err == -8 || err == -7) m_overflows.push_back(std::make_pair(rch, (*digitItr)));
516 float ped = rch->pedestal() + 100000 + 10000 * err;
517 rch->setPedestal(ped);
518 if (msgLvl(MSG::VERBOSE) && !m_badDrawer) {
519 if (err < -5) {
520 msg(MSG::VERBOSE) << "BadCh " << m_tileHWID->to_string(rch->adc_HWID())
521 << " warning = " << BadPatternName(ped) << endmsg;
522 } else {
523 msg(MSG::VERBOSE) << "BadCh " << m_tileHWID->to_string(rch->adc_HWID())
524 << " error = " << BadPatternName(ped) << endmsg;
525 }
526 }
527 }
528
529 }
530
531 ATH_CHECK( m_rawChannelCnt->push_back (rch) );
532 }
533
534 IdentifierHash hash = m_rawChannelCnt->hashFunc().hash(coll->identify());
535 TileRawChannelCollection* rawChannelCollection = m_rawChannelCnt->indexFindPtr(hash);
536 rawChannelCollection->setLvl1Id(coll->getLvl1Id());
537 rawChannelCollection->setLvl1Type(coll->getLvl1Type());
538 rawChannelCollection->setDetEvType(coll->getDetEvType());
539 rawChannelCollection->setRODBCID(coll->getRODBCID());
540
541 return StatusCode::SUCCESS;
542}
#define endmsg
#define ATH_CHECK
Evaluate an expression and check for errors.
bool msgLvl(const MSG::Level lvl) const
MsgStream & msg() const
DataModel_detail::const_iterator< DataVector > const_iterator
Standard const_iterator.
Definition DataVector.h:838
static const char * BadPatternName(float ped)
std::unique_ptr< TileMutableRawChannelContainer > m_rawChannelCnt
void fill_drawer_errors(const EventContext &ctx, const TileDigitsCollection *collection)
virtual TileRawChannel * rawChannel(const TileDigits *digits, const EventContext &ctx)
Builder virtual method to be implemented by subclasses.
float pedestal(void) const
void setPedestal(float ped)
void setLvl1Type(uint32_t lvl1Type)
Setter for level1 type from ROD header.
void setLvl1Id(uint32_t lvl1Id)
Setter for level1 id from ROD header.
void setRODBCID(uint32_t rodBCID)
Setter for BCID from ROD header.
void setDetEvType(uint32_t detEvType)
Setter for detector event type from ROD header.
HWIdentifier adc_HWID(void) const
Definition TileRawData.h:53

◆ calculateFlatFilter()

double TileRawChannelBuilderFlatFilter::calculateFlatFilter ( const std::vector< float > & digits,
int filterStart,
int filterLength,
double ped,
double & position ) const
private

Calculate energy using flat filter Sum of <filterLength> samples starting at <filterStart> Requires pedestal value and returns position of peak.

Parameters
digitsVector of didits(double>
filterStartStart position for filter
filterLengthNumber of samples
pedPedestal value
positionStorage place for position of peak
Returns
Energy

Definition at line 415 of file TileRawChannelBuilderFlatFilter.cxx.

416 {
417
418 int t, sum = 0;
419 double energy;
420
422 ATH_MSG_VERBOSE( "Calc flat filter Filter: " << filterStart
423 << "->" << (filterStart + filterLength)
424 << " pedestal=" << ped );
425 }
426
427 // calculate sum of filter_length samples
428 for (t = filterStart; t < filterStart+filterLength; ++t)
429 sum += (int)digits.at(t);
430
431 // subtract pedestal
432 energy = (double)sum - ped * filterLength;
433
434 // calculate center of the filter and convert to nanoseconds
435 position = (filterStart + (filterLength-1)/2.) * 25.;
436
438 ATH_MSG_VERBOSE( "Flat amplitude=" << energy
439 << " position=" << position );
440 }
441
442 return(energy);
443}
#define ATH_MSG_VERBOSE(x)
#define TILE_FLATFILTERBUILDERVERBOSE

◆ calculatePeak()

double TileRawChannelBuilderFlatFilter::calculatePeak ( const std::vector< float > & digits,
int peakPos,
double ped,
double & position ) const
private

Definition at line 359 of file TileRawChannelBuilderFlatFilter.cxx.

360 {
361
362 int y_1, y0, y1;
363 double peak, tmax, A, B, C;
364
366 ATH_MSG_VERBOSE( "Calculating peak, Pos " << peakPos
367 << " Pedestal " << ped );
368 }
369
370 if ((peakPos == 0) || (peakPos == m_frameLength - 1)) {
371 // peak at the boundary
372 tmax = peakPos;
373 peak = digits.at(peakPos);
374 } else {
375 // let's say that "peak_pos" is X=0 point
376 y_1 = (int) digits.at(peakPos - 1); // ordinate at X=-1
377 y0 = (int) digits.at(peakPos); // ordinate at X=0
378 y1 = (int) digits.at(peakPos + 1); // ordinate at X=1
379
380 // coefficients A,B,C of Y(x) = A*x^2 + B*x + C
381 C = y0;
382 B = (y1 - y_1) / 2.;
383 A = y1 - B - C;
384
385 if (A < 0.0) {
386 // amplitude at peak_pos is local maximim
387 tmax = peakPos - B / (A * 2.);
388 peak = C - B * B / (A * 4.);
389 }
390 else if ( y_1 == y0 && y0 == y1 ) {
391 // flat distribution, no peak at all
392 tmax = peakPos;
393 peak = y0;
394 }
395 else {
396 // there is no local maximim
397 // phase has negative sign to indicate that,
398 // peak is amplitude at peak_pos
399 tmax = -peakPos;
400 peak = y0;
401 }
402 }
403
404 // subtract pedestal
405 peak -= ped;
406 // convert to nanoseconds
407 position = tmax * 25.;
408
410 ATH_MSG_VERBOSE( "Found Peak " << peak << " at " << position );
411
412 return (peak);
413}
struct color C

◆ commitContainer()

StatusCode TileRawChannelBuilder::commitContainer ( const EventContext & ctx)
virtualinherited

Commit RawChannelContiner in SG and make const.

Definition at line 544 of file TileRawChannelBuilder.cxx.

545{
546
547 const TileDQstatus* DQstatus = SG::makeHandle (m_DQstatusKey, ctx).get();
548
549 ToolHandleArray<ITileRawChannelTool>::iterator itrTool = m_noiseFilterTools.begin();
550 ToolHandleArray<ITileRawChannelTool>::iterator endTool = m_noiseFilterTools.end();
551
552 if ( m_useDSP && !m_DSPContainerKey.key().empty() &&
553 (DQstatus->incompleteDigits() || m_chCounter<12288) && itrTool!=endTool )
554 {
555 const TileRawChannelContainer * dspCnt = SG::makeHandle (m_DSPContainerKey, ctx).get();
556 ATH_MSG_DEBUG( "Incomplete container - use noise filter corrections from DSP container" );
557
558 uint32_t bsFlags = dspCnt->get_bsflags();
559 std::vector<IdentifierHash> hashes = m_rawChannelCnt->GetAllCurrentHashes();
560 std::vector<IdentifierHash> dspHashes = dspCnt->GetAllCurrentHashes();
561 if (bsFlags == 0) {
562 ATH_MSG_WARNING("Problem in applying noise corrections: DSP container ("
563 << m_DSPContainerKey.key() << ") seems to be emtpy!");
564 } else if (hashes != dspHashes) {
565 ATH_MSG_ERROR( " Error in applying noise corrections; "
566 "hash vectors do not match.");
567 } else {
568 // Go through all TileRawChannelCollections
569 for (IdentifierHash hash : hashes) {
570 TileRawChannelCollection* coll = m_rawChannelCnt->indexFindPtr (hash);
571 const TileRawChannelCollection* dcoll = dspCnt->indexFindPtr (hash);
572
573 if (coll->identify() != dcoll->identify()) {
574
575 ATH_MSG_ERROR( " Error in applying noise corrections " << MSG::hex
576 << " collection IDs 0x" << coll->identify() << " and 0x" << dcoll->identify()
577 << " do not match " << MSG::dec );
578 break;
579 }
580
581 // iterate over all channels in a collection
584
585 for (TileRawChannel* rch : *coll) {
586 HWIdentifier adc_id = rch->adc_HWID();
587 while (dspItr != dspLast && adc_id != (*dspItr)->adc_HWID()) {
588 ++dspItr;
589 }
590 if (dspItr != dspLast) {
591 float corr = (*dspItr)->pedestal();
592 ATH_MSG_VERBOSE( "Ch "<<m_tileHWID->to_string(adc_id)
593 <<" amp " << rch->amplitude() << " ped " << rch->pedestal()
594 << " corr " << corr );
595 if (corr<10000.) {
596 rch->setAmplitude (rch->amplitude() - corr); // just baseline shift
597 rch->setPedestal (rch->pedestal() + corr); // just baseline shift
598 } else {
599 float ped = rch->pedestal();
600 if (corr > ped) {
601 rch->setPedestal (fmod(ped,10000.) + int(corr)/10000 * 10000); // changing error status
602 ATH_MSG_VERBOSE( "New error status in ped "<<rch->pedestal());
603 }
604 }
605 } else {
606 ATH_MSG_WARNING(" Problem in applying noise corrections "
607 << " can not find channel in DSP container with HWID "
608 << m_tileHWID->to_string(adc_id) );
609 dspItr = dcoll->begin();
610 }
611 }
612 }
613 }
614
615 } else {
616
617 for (ToolHandle<ITileRawChannelTool>& noiseFilterTool : m_noiseFilterTools) {
618 if (noiseFilterTool->process(*m_rawChannelCnt.get(), ctx).isFailure()) {
619 ATH_MSG_ERROR( " Error status returned from noise filter " );
620 } else {
621 ATH_MSG_DEBUG( "Noise filter applied to the container" );
622 }
623 }
624
625 }
626
627 ATH_MSG_DEBUG( " nCh=" << m_chCounter
628 << " nChH/L=" << m_nChH << "/" << m_nChL
629 << " RChSumH/L=" << m_RChSumH << "/" << m_RChSumL );
630
631 SG::WriteHandle<TileRawChannelContainer> rawChannelsContainer(m_rawChannelContainerKey, ctx);
632 ATH_CHECK( rawChannelsContainer.record(std::move(m_rawChannelCnt)) );
633
634 endLog();
635
636 return StatusCode::SUCCESS;
637}
#define ATH_MSG_ERROR(x)
#define ATH_MSG_WARNING(x)
#define ATH_MSG_DEBUG(x)
Athena::TPCnvVers::Old Athena::TPCnvVers::Old Athena::TPCnvVers::Current Athena::TPCnvVers::Old Athena::TPCnvVers::Current TileRawChannelContainer
const_iterator end() const noexcept
Return a const_iterator pointing past the end of the collection.
const_iterator begin() const noexcept
Return a const_iterator pointing at the beginning of the collection.
virtual std::vector< IdentifierHash > GetAllCurrentHashes() const override final
Returns a collection of all hashes availiable in this IDC.
virtual const T * indexFindPtr(IdentifierHash hashId) const override final
return pointer on the found entry or null if out of range using hashed index - fast version,...
bool incompleteDigits() const
A few extra items (from TileBeamInfoProvider).
SG::ReadHandleKey< TileDQstatus > m_DQstatusKey
SG::ReadHandleKey< TileRawChannelContainer > m_DSPContainerKey
ToolHandleArray< ITileRawChannelTool > m_noiseFilterTools
uint32_t get_bsflags() const
SG::ReadCondHandle< T > makeHandle(const SG::ReadCondHandleKey< T > &key, const EventContext &ctx=Gaudi::Hive::currentContext())
setEventNumber uint32_t

◆ correctAmp()

double TileRawChannelBuilder::correctAmp ( double phase,
bool of2 = true )
staticinherited

Amplitude correction factor according to the time when using weights for tau=0 without iterations.

Definition at line 646 of file TileRawChannelBuilder.cxx.

646 {
647
648 double corr = 1.0;
649 if (of2) {
650 // estimation from Belen for rel 14.0.0
651 /*double a,b,c;
652 if(fabs(phase)<5.){
653 a=0.137; b=0.0877; c=0.0865;
654 }else{
655 a=0.565; b=0.116; c=0.0751;
656 }
657 corr=(1+(a+b*phase+c*phase*phase)/100.);
658 */
659
660 // estimation from Vakhtang for rel 14.4.0
661 /*double k = (phase < 0.0 ? 0.0009400 : 0.0010160);
662 corr = (1.0 + k * phase * phase);
663 */
664
665 // Parabolic correction from Tigran
666 double a1,a2,b,c;
667 a1 = phase < 0.0 ? 0.000940774 : 0.00102111;
668 a2 = phase < 0.0 ? 0.000759051 : 0.000689625;
669 b = phase < 0.0 ? -2.0 * 7.0 * (a1 - a2) : 2.0 * 12.5 * (a1 - a2);
670 c = phase < 0.0 ? 1.0 - 7.0 * 7.0 * (a1-a2) : 1.0 - 12.5 * 12.5 * (a1-a2);
671 if (phase < 12.5 && phase > -7.0) corr = a1 * phase * phase + 1.0;
672 else corr = phase * ( a2 * phase + b) + c;
673
674
675 } else {
676 /*double a,b,c;
677 if(phase<0){
678 a=1.0002942; b=0.0003528; c=0.0005241;
679 }else{
680 a=1.0001841; b=-0.0004182; c=0.0006167;
681 }
682 corr = a + phase * ( b + c * phase);
683 */
684
685 /*double k = (phase < 0.0 ? 0.0005241 : 0.0006167);
686 corr = (1.0 + k * phase * phase);
687 */
688
689 // 4th degree polynomial correction from Tigran
690 double k1 = (phase < 0.0 ? -0.0000326707:0.000380336);
691 double k2 = (phase < 0.0 ? -0.000560962:-0.000670487);
692 double k3 = (phase < 0.0 ? -0.00000807869:0.00000501773);
693 double k4 = (phase < 0.0 ? -0.000000145008:0.0000000584647);
694
695 corr = 1.0 / (1.0 + (k1 + (k2 + (k3 + k4 *phase)*phase)*phase)*phase);
696
697
698 }
699
700 return corr;
701}

◆ correctTime()

double TileRawChannelBuilder::correctTime ( double phase,
bool of2 = true )
staticinherited

Time correction factor.

Definition at line 705 of file TileRawChannelBuilder.cxx.

705 {
706
707 double correction = 0.0;
708
709 if (of2) {
710 if(phase < 0) {
711 correction = (-0.00695743 + (0.0020673 - (0.0002976 + 0.00000361305 * phase) * phase) * phase) * phase;
712 } else {
713 correction = (0.0130013 + (0.00128769 + (-0.000550218 + 0.00000755344 * phase) * phase) * phase) * phase;
714 }
715 }
716 // OF1 does not need correction
717
718 return correction;
719}
correction(mu, runmode, campaign, run=None)
Definition zlumi_mc_cf.py:4

◆ CorruptedData()

int TileRawChannelBuilder::CorruptedData ( int ros,
int drawer,
int channel,
int gain,
const std::vector< float > & digits,
float & dmin,
float & dmax,
float ADCmaxMinusEps,
float ADCmaskValueMinusEps )
staticinherited

Definition at line 723 of file TileRawChannelBuilder.cxx.

724 {
725 bool eb = (ros > 2);
726 bool ebsp = ((ros == 3 && drawer == 14) || (ros == 4 && drawer == 17));
727 bool empty = ((eb && ((channel > 23 && channel < 30) || channel > 41)) || (ebsp && channel < 3));
728 bool not_gap = !(empty || (eb && (channel == 0 || channel == 1 || channel == 12 || channel == 13))
729 || (ebsp && (channel == 18 || channel == 19)));
730
731 const float epsilon = 4.1; // allow +/- 2 counts fluctuations around const value
732 const float delta[4] = { 29.9, 29.9, 49.9, 99.9 }; // jump levels between constLG, constHG, non-constLG, non-constHG
733 const float level1 = 99.9; // jump from this level to m_i_ADCmax is bad
734 const float level2 = 149.9; // base line at this level in low gain is bad
735 const float narrowLevel[2] = { 29.9, 49.9 }; // minimal amplitude for narrow pulses
736 const float delt = std::min(std::min(std::min(delta[0], delta[1]), std::min(delta[2], delta[3])),
737 std::min(narrowLevel[0], narrowLevel[1]));
738 const float secondMaxLevel = 0.3;
739
740 int error = 0;
741
742 unsigned int nSamp = digits.size();
743 if (nSamp) {
744 dmin = dmax = digits[0];
745 unsigned int pmin = 0;
746 unsigned int pmax = 0;
747 unsigned int nzero = (dmin < 0.01) ? 1 : 0;
748 unsigned int nover = (dmax > ADCmaxMinusEps) ? 1 : 0;
749
750 for (unsigned int i = 1; i < nSamp; ++i) {
751 float dig = digits[i];
752 if (dig > dmax) {
753 dmax = dig;
754 pmax = i;
755 } else if (dig < dmin) {
756 dmin = dig;
757 pmin = i;
758 }
759 if (dig < 0.01) ++nzero;
760 else if (dig > ADCmaxMinusEps) ++nover;
761 }
762
763 float dmaxmin = dmax - dmin;
764 //std::cout << " ros " << ros << " drawer " << drawer << " channel " << channel << " not_gap " << not_gap << " nzero " << nzero << " nover " << nover << std::endl;
765
766 if (dmin > ADCmaxMinusEps) { // overflow in all samples
767 error = (dmin > ADCmaskValueMinusEps) ? -3 : -1; // dmin=m_tileInfo->ADCmaskValue() - masking in overlay job (set in TileDigitsMaker)
768
769 } else if (dmax < 0.01) { // underflow in all samples
770 error = (empty) ? -5 : -2; // set different type of errors for exsiting and non-existing channels
771
772 } else if (dmaxmin < 0.01) { // constant value in all samples
773 error = -6;
774
775 } else if (nzero && nover) { // jump from zero to saturation
776 error = 1;
777
778 } else if ((nzero && (not_gap || empty)) || nzero > 1) { // one sample at zero in normal channel
779 error = 2; // or 2 samples at zero in gap/crack/MBTS
780
781 } else if (gain == 0 && dmin > level2) { // baseline above threshold in low gain is bad
782 error = 9;
783
784 } else if (dmaxmin > delt) { // check that max-min is above minimal allowed jump
785
786 float abovemin = dmax;
787 float belowmax = dmin;
788 unsigned int nmin = 0;
789 unsigned int nmax = 0;
790 for (unsigned int i = 0; i < nSamp; ++i) {
791 float smp = digits[i];
792 if (smp - dmin < epsilon) {
793 ++nmin;
794 }
795 if (dmax - smp < epsilon) {
796 ++nmax;
797 }
798 if (smp < abovemin && smp > dmin) {
799 abovemin = smp;
800 }
801 if (smp > belowmax && smp < dmax) {
802 belowmax = smp;
803 }
804 }
805 // more than two different values - shift index by 2, i.e. use thresholds for non-const levels
806 int gainInd = (abovemin != dmax || belowmax != dmin) ? gain + 2 : gain;
807 bool big_jump = (dmaxmin > delta[gainInd]);
808 bool max_in_middle = (pmax > 0 && pmax < nSamp - 1);
809 bool min_in_middle = (pmin > 0 && pmin < nSamp - 1);
810
811 if (nover > 1 && belowmax < level1) { // at least two saturated. others - close to pedestal
812 error = 3;
813 } else if (nmax + nmin == nSamp && big_jump) {
814 if (nmax > 1 && nmin > 1) { // at least 2 samples at two distinct levels
815 error = 4;
816 } else if (nmax == 1) {
817 if (max_in_middle) { // jump up in one sample, but not at the edge
818 error = 5;
819 }
820 } else if (nmin == 1) { // jump down in one sample
821 error = 6;
822 }
823 }
824 if (error == 0 && dmaxmin > narrowLevel[gain]) {
825 float secondMax = dmaxmin * secondMaxLevel;
826 float dminPlus = dmin + secondMax;
827 float dmaxMinus = dmax - secondMax;
828 if (not_gap) { // jumps above two (or one) neighbour samples
829 if (max_in_middle && std::max(digits[pmax - 1], digits[pmax + 1]) < dminPlus) {
830 error = 7; // jump up in one sample in the middle, which is much higher than two neighbours
831 } else if (min_in_middle && std::min(digits[pmin - 1], digits[pmin + 1]) > dmaxMinus) {
832 error = 8; // jump down in one sample, which is much lower than two neighbours
833 } else if (big_jump && gain == 0) { // check first and last sample only in low gain
834 if (pmin == 0 && digits[1] > dmax - secondMax) {
835 error = 10; // jump down in first sample. which is much lower than next one
836 } else if (pmin == nSamp - 1 && digits[pmin - 1] > dmax - secondMax) {
837 error = 11; // jump down in last sample. which is much lower than previous one
838 }
839 }
840 }
841 if (!error && big_jump) { // jumps above all samples
842 if ((max_in_middle || gain == 0) && nmax == 1 && belowmax < dminPlus) {
843 error = 12; // jump up in one sample in the middle, which is much higher than all others
844 } else if ((min_in_middle || gain == 0) && nmin == 1 && abovemin > dmaxMinus) {
845 error = 13; // jump down in one sample, which is much lower than all others (
846 }
847 }
848 }
849 }
850
851 } else {
852 dmin = dmax = 0.0;
853 }
854
855 return error;
856}
const int nmax(200)
bool empty(TH1 *h)

◆ createContainer()

StatusCode TileRawChannelBuilder::createContainer ( const EventContext & ctx)
virtualinherited

Create container in SG with name given by parameter (m_rawChannelContainerKey)

Definition at line 233 of file TileRawChannelBuilder.cxx.

233 {
234 initLog(ctx);
235
236 // create TRC container
237 m_rawChannelCnt = std::make_unique<TileMutableRawChannelContainer>(true, m_rChType, m_rChUnit, SG::VIEW_ELEMENTS);
238 ATH_CHECK( m_rawChannelCnt->status() );
239 m_rawChannelCnt->set_bsflags(m_bsflags);
240
241 ATH_MSG_DEBUG( "Created TileRawChannelContainer '" << m_rawChannelContainerKey.key() << "'" );
242
243 return StatusCode::SUCCESS;
244}
TileRawChannelUnit::UNIT m_rChUnit
void initLog(const EventContext &ctx)
@ VIEW_ELEMENTS
this data object is a view, it does not own its elmts

◆ declareGaudiProperty()

Gaudi::Details::PropertyBase & AthCommonDataStore< AthCommonMsg< AlgTool > >::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< AlgTool > >::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< AlgTool > >::detStore ( ) const
inlineinherited

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

Definition at line 95 of file AthCommonDataStore.h.

◆ endLog()

void TileRawChannelBuilder::endLog ( )
inherited

Definition at line 639 of file TileRawChannelBuilder.cxx.

639 {
640 m_chCounter = 0;
641 m_nChL = m_nChH = 0;
642 m_RChSumL = m_RChSumH = 0.0;
643
644}

◆ evtStore()

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

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

Definition at line 85 of file AthCommonDataStore.h.

◆ extraDeps_update_handler()

void AthCommonDataStore< AthCommonMsg< AlgTool > >::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

◆ fill_drawer_errors()

void TileRawChannelBuilder::fill_drawer_errors ( const EventContext & ctx,
const TileDigitsCollection * collection )
privateinherited

Definition at line 300 of file TileRawChannelBuilder.cxx.

302{
303 const TileDQstatus* DQstatus = SG::makeHandle (m_DQstatusKey, ctx).get();
304
305 int frag = coll->identify();
306 int ros = (frag >> 8);
307 int drawer = (frag & 0xff);
308
309 m_lastDrawer = frag;
310
311 memset(m_error, 0, sizeof(m_error));
312 int dmuerr[MAX_DMUS] = {0};
313 int nch = 0;
314 bool bigain = DQstatus->isBiGain();
315 if (!bigain) { // in bigain runs we don't have DQ status fragment
316 for (int ch = 0; ch < MAX_CHANNELS; ch += 3) {
317 if (!DQstatus->isAdcDQgood(ros, drawer, ch, 0)) {
318 m_error[ch + 2] = m_error[ch + 1] = m_error[ch] = -3;
319 dmuerr[ch / 3] = 3;
320 nch += 3;
321 }
322 }
323 }
324 if (nch == MAX_CHANNELS) { // all bad - nothing to do
325 m_badDrawer = true;
326 ATH_MSG_VERBOSE( "Drawer 0x" << MSG::hex << frag << MSG::dec
327 << " is bad - skipping bad patterns check " );
328 return;
329 } else {
330 m_badDrawer = false;
331 ATH_MSG_VERBOSE( "Drawer 0x" << MSG::hex << frag << MSG::dec
332 << " looking for bad patterns in digits" );
333 }
334
335 float mindig, maxdig;
336 int nchbad[2] = { 0, 0 };
337
338 // Iterate over all digits in this collection
339 TileDigitsCollection::const_iterator digitItr = coll->begin();
340 TileDigitsCollection::const_iterator lastDigit = coll->end();
341
342 for (; digitItr != lastDigit; ++digitItr) {
343 const TileDigits * pDigits = (*digitItr);
344 HWIdentifier adcId = pDigits->adc_HWID();
345 int channel = m_tileHWID->channel(adcId);
346 int gain = m_tileHWID->adc(adcId);
347
348 if (m_error[channel]) {
349 ATH_MSG_VERBOSE( "BadCh " << ros
350 << "/" << drawer
351 << "/" << channel
352 << "/" << gain << " BAD DQ STATUS ");
353
354 } else {
355
356 int err = CorruptedData(ros, drawer, channel, gain, pDigits->samples(), mindig, maxdig, m_ADCmaxMinusEps, m_ADCmaskValueMinusEps);
357
358 if (err) {
359
361 if (err > -5) {
362 ++dmuerr[channel / 3];
363 ++nchbad[channel / 24];
364 }
365
366 if (msgLvl(MSG::VERBOSE)) {
367
368 msg(MSG::VERBOSE) << "BadCh " << ros
369 << "/" << drawer
370 << "/" << channel
371 << "/" << gain;
372 if (err < -5) msg(MSG::VERBOSE) << " Warning " << err;
373 else msg(MSG::VERBOSE) << " Error " << err;
374 if (mindig > m_ADCmaskValueMinusEps) msg(MSG::VERBOSE) << " BADDQ";
375 if (maxdig > m_ADCmaxMinusEps) msg(MSG::VERBOSE) << " Overflow";
376 if (mindig < 0.1) msg(MSG::VERBOSE) << " Underflow";
377 if (err < 0) msg(MSG::VERBOSE) << " Const";
378
379 msg(MSG::VERBOSE) << " samp=";
380 std::vector<float> digits = pDigits->samples();
381 for (unsigned int i = 0; i < digits.size(); ++i) {
382 msg(MSG::VERBOSE) << " " << digits[i];
383 }
384 msg(MSG::VERBOSE) << endmsg;
385 }
386
387 } else {
388 if (mindig < 0.01) err += 1;
389 if (maxdig > m_ADCmaxMinusEps) err += 2;
390 if (err) m_error[channel] = err - 10;
391 }
392 }
393 }
394
395 // check if we want to mask half a drawer
396 // in this case set error = -4 for channels which were good before
397
398 int ndmubad[2] = { 0, 0 };
399 int dmu = 0;
400 for (; dmu < MAX_DMUS / 2; ++dmu) { // first half
401 if (dmuerr[dmu] > 1)
402 ++ndmubad[0]; // count DMUs with at least two bad channels
403 }
404 for (; dmu < MAX_DMUS; ++dmu) { // second half
405 if (dmuerr[dmu] > 1)
406 ++ndmubad[1]; // count DMUs with at least two bad channels
407 }
408
409 int ndmulimit[2] = { 3, 3 }; // max number of bad DMUs when half-drawer is not yet masked
410 // if 4 DMUs will be bad - mask whole half-drawer
411 if (frag > 0x2ff) { // if extended barrel
412 if (frag == 0x30e || frag == 0x411)
413 ndmulimit[0] = 4; // in EB special one DMU is always bad (missing)
414 ndmulimit[1] = 5; // in second half of EB 4 DMUs ara always bad (missing)
415 // only if 7 DMUs are bad, mask whole half-drawer
416 }
417
418 bool printall = true;
419 for (int p = 0; p < 2; ++p) {
420 if (ndmubad[p] > ndmulimit[p] && nchbad[p] > 0) {
421 if (msgLvl(MSG::VERBOSE)) {
422 msg(MSG::VERBOSE) << "Drawer 0x" << MSG::hex << frag << MSG::dec
423 << " masking whole " << ((p) ? "second" : "first")
424 << " half" << endmsg;
425 if (printall) {
426 msg(MSG::VERBOSE) << "nDMuErr ";
427 for (int d = 0; d < MAX_DMUS; ++d) {
428 msg(MSG::VERBOSE) << " " << dmuerr[d];
429 }
430 msg(MSG::VERBOSE) << " total " << ndmubad[p] << " errors" << endmsg;
431
432 msg(MSG::VERBOSE) << "ChErr ";
433 int ch = 0;
434 while (ch < MAX_CHANNELS-2) {
435 msg(MSG::VERBOSE) << " " << m_error[ch++];
436 msg(MSG::VERBOSE) << " " << m_error[ch++];
437 msg(MSG::VERBOSE) << " " << m_error[ch++];
438 msg(MSG::VERBOSE) << " ";
439 }
440
441 msg(MSG::VERBOSE) << " total " << nchbad[p]
442 << " bad patterns" << endmsg;
443 printall = false;
444 }
445 }
446 int ch = (p) ? MAX_CHANNELS / 2 : 0;
447 int chmax = (p) ? MAX_CHANNELS : MAX_CHANNELS / 2;
448 for (; ch < chmax; ++ch) {
449 if (m_error[ch] == 0 || m_error[ch] < -5) { // channel was good before
450 m_error[ch] = -4;
451 }
452 }
453 }
454 }
455
456}
bool isAdcDQgood(int partition, int drawer, int ch, int gain) const
returns status of single ADC returns False if there are any errors
bool isBiGain() const
returns gain mode of run
const std::vector< float > & samples() const
Definition TileDigits.h:58
float m_ADCmaskValueMinusEps
indicates channels which were masked in background dataset
static int CorruptedData(int ros, int drawer, int channel, int gain, const std::vector< float > &digits, float &dmin, float &dmax, float ADCmaxMinusEps, float ADCmaskValueMinusEps)

◆ finalize()

StatusCode TileRawChannelBuilderFlatFilter::finalize ( )
virtual

Reimplemented from TileRawChannelBuilder.

Definition at line 86 of file TileRawChannelBuilderFlatFilter.cxx.

86 {
87
88 ATH_MSG_DEBUG( "Finalizing" );
89 return StatusCode::SUCCESS;
90}

◆ flatFilter() [1/2]

void TileRawChannelBuilderFlatFilter::flatFilter ( const std::vector< float > & digits,
const int gain,
double & amplitude,
double & time ) const

Filter given digits using FlatFilter method.

Parameters
digitsas vector of double
amplitude
time

Definition at line 480 of file TileRawChannelBuilderFlatFilter.cxx.

481 {
482
483 int frameMax = 0;
484 int frameMin = 0;
485 double frameMean = 0.0;
486 double frameRMS = 0.0;
487 bool signal = false;
488 double pedestal = 0.0;
489
490 //int adderMax = 0; // maximum of adder
491 int tAdder = 0; // time for adder
492 int tAdderFrame = 0;
493 int adderMaxFrame = 0;
494
495 //int sampleMax = 0;
496 int tSample = 0;
497 int tSampleFrame = 0;
498 int sampleMaxFrame = 0;
499
500 //double peakAmplitude;
501 //double peakEnergy;
502 //double peakTime;
503 //double flatEnergy;
504
505 double flatFilter; // non calibrated energy from flat filter
506 double flatTime;
507
508 if (msgLvl(MSG::VERBOSE)) {
509 msg(MSG::VERBOSE) << "Digits." << samples.size() << " {";
510 for (unsigned i = 0; i < samples.size(); i++) {
511 msg(MSG::VERBOSE) << samples[i] << " ";
512 }
513 msg(MSG::VERBOSE) << "}" << endmsg;
514 }
515
516 // check if signal in frame
517 signal = isSignalInFrame(samples, m_deltaCut[gain % 2], m_rmsCut[gain % 2]
518 , frameMax, frameMin, frameMean, frameRMS);
519
520 if (signal && (m_pedOffset < 0)) {
521 // take pedestal before signal
522 // and if number of samples before signal is not enough -
523 // use samples at the end of the frame
524 pedestal = getPedestal(samples, tAdder + m_pedOffset, -m_pedLength);
525 } else {
526 // fixed position of pedestal window for channel without signal
527 pedestal = getPedestal(samples, m_pedStart, m_pedLength);
528 }
529
530 //------------------ Flat Filter ---------------
532 , tAdder , tAdderFrame, adderMaxFrame);
533
534 // look for max. sample inside maxAdder
535 /*sampleMax =*/getMaxSample(samples, tAdder, m_filterLength, tSample
536 , tSampleFrame, sampleMaxFrame);
537
538 // position of the peak is always in the signal window even if
539 // real maximum is outside signal window
540 //peakAmplitude = calculatePeak (samples, tSample, pedestal, peakTime);
541 //peakEnergy = calibrateCSL(calibratePeak(peakAmplitude, adcId), adcId);
542
543 // flat filter method
544 // position of the filter is always in the signal window even if
545 // real maximum is outside signal window
546 flatFilter = calculateFlatFilter(samples, tAdder, m_filterLength, pedestal, flatTime);
547
548 //ZZZ: No calibration at all!
549 //flatEnergy = calibrateCSL(calibrateFlatFilter(flatFilter,adcId),adcId);
550
551 // calculate time of the signal as weighted sum of all samples in signal window
552 time = getTime(samples, m_signalStart, m_signalLength, pedestal);
553 if (time <= 0.0) time = -flatTime;
554
555 amplitude = flatFilter;
556}
double calculateFlatFilter(const std::vector< float > &digits, int filterStart, int filterLength, double ped, double &position) const
Calculate energy using flat filter Sum of <filterLength> samples starting at <filterStart> Requires p...
double getTime(const std::vector< float > &digits, int signalStart, int signalLength, double ped) const
Calculate the time of signal in window of <signalLength> starting at <signalStart> Result is sum of t...
bool isSignalInFrame(const std::vector< float > &digits, double deltaCut, double rmsCut, int &frameMax, int &frameMin, double &frameMean, double &frameRMS) const
Find min and max sample Calculate mean and RMS of all samples.
int getMaxSample(const std::vector< float > &digits, int signalStart, int signalLength, int &tMax, int &tMaxFrame, int &sampleFrame) const
int getMaxAdder(const std::vector< float > &digits, int filterLength, int signalStart, int signalLength, int &tMax, int &tMaxFrame, int &adderFrame) const
Get position of maximal adder (sum of <filterLength> samples) in whole frame and in signal window (<s...
double getPedestal(const std::vector< float > &digits, int pedStart, int pedLgt) const
Calculate pedestal as mean of <pedLgt> samples starting from <pedStart>
void flatFilter(const std::vector< uint32_t > &digits, const int gain, double &amplitude, double &time) const
Filter given digits using FlatFilter method.
time(flags, cells_name, *args, **kw)
tSample
Definition master.py:51
MsgStream & msg
Definition testRead.cxx:32

◆ flatFilter() [2/2]

void TileRawChannelBuilderFlatFilter::flatFilter ( const std::vector< uint32_t > & digits,
const int gain,
double & amplitude,
double & time ) const

Filter given digits using FlatFilter method.

Parameters
digitsas vector of unsigned 32 bit integers
amplitude
time

Definition at line 558 of file TileRawChannelBuilderFlatFilter.cxx.

559 {
560
561 std::vector<float> dVec;
562
564 ATH_MSG_VERBOSE( "TileRawChannelBuilderFlatFilter - Invoked with vector<int>..");
565
566 dVec.reserve(digits.size());
567 for (uint32_t i = 0; i < digits.size(); i++) {
568 dVec.push_back((float) digits[i]);
569 }
570 return flatFilter(dVec, gain, amplitude, time);
571}

◆ getMaxAdder()

int TileRawChannelBuilderFlatFilter::getMaxAdder ( const std::vector< float > & digits,
int filterLength,
int signalStart,
int signalLength,
int & tMax,
int & tMaxFrame,
int & adderFrame ) const
private

Get position of maximal adder (sum of <filterLength> samples) in whole frame and in signal window (<signalStart>-><signalStart>+<signalLength> Return position and value of maximal adder in frame.

Parameters
digitsVector if digits(double)
filterLength
signalStartStart of signal window
signalLengthLength of signal window
returnPosition of max adder

Definition at line 217 of file TileRawChannelBuilderFlatFilter.cxx.

219 {
220 int i, t, minW, maxW, adder, adderWindow;
221 int tm=0, maxAdder=-1;
222
224 ATH_MSG_VERBOSE( "Getting adder flgt " << filterLength
225 << " Signal " << signalStart
226 << "->" << (signalStart + signalLength) );
227 }
228
229 // left and right limits for signal window
230 minW = signalStart;
231 maxW = signalStart + signalLength - filterLength + 1;
232
233 // max adder inside signal window
234 for (t = minW; t < maxW; ++t) {
235 adder = 0;
236 // sum of all samples in window
237 for (i = t; i < t+filterLength; ++i) adder += (int)digits.at(i);
238 // store maximum
239 if ( adder > maxAdder ) {
240 tm = t;
241 maxAdder = adder;
242 }
243 }
244
245 // return parameters for max adder in signal window
246 tMax = tm;
247
248 adderWindow = maxAdder;
249
250 // right limit for whole frame
251 maxW = m_frameLength - filterLength + 1;
252
253 // max adder after signal window
254 for ( ; t < maxW; ++t) {
255 adder = 0;
256 for (i = t; i < t+filterLength; ++i) adder += (int)digits.at(i);
257
258 if ( adder > maxAdder ) {
259 tm = t;
260 maxAdder = adder;
261 }
262 }
263
264 // max adder before signal window
265 for (t = 0; t < minW; ++t) {
266 adder = 0;
267 for (i = t; i < t+filterLength; ++i)
268 adder += (int)digits.at(i);
269
270 if ( adder > maxAdder ) {
271 tm = t;
272 maxAdder = adder;
273 }
274 }
275
276 // return parameters for max adder in whole frame
277 tMaxFrame = tm;
278 adderFrame = maxAdder;
279
281 ATH_MSG_VERBOSE( "Got max adder, tMax=" << tMax
282 << " tMaxFrame=" << tMaxFrame
283 << " maxAdder=" << maxAdder
284 << " adderWindow=" << adderWindow );
285 }
286
287 return adderWindow;
288}

◆ getMaxSample()

int TileRawChannelBuilderFlatFilter::getMaxSample ( const std::vector< float > & digits,
int signalStart,
int signalLength,
int & tMax,
int & tMaxFrame,
int & sampleFrame ) const
private

Definition at line 290 of file TileRawChannelBuilderFlatFilter.cxx.

291 {
292
293 int t, minW, maxW, sampleWindow;
294 int tm = 0, maxSample = -1;
295
297 ATH_MSG_VERBOSE( "Getting max sample, Signal " << signalStart
298 << "->" << (signalStart + signalLength) );
299 }
300
301 // left and right limits for signal window
302 minW = signalStart;
303 maxW = signalStart + signalLength;
304
305 // max sample inside signal window take leftmost maximum
306 for (t = minW; t < maxW; ++t) {
307 if ((int) digits.at(t) > maxSample) {
308 tm = t;
309 maxSample = (int) digits.at(t);
310 }
311 }
312
313 // let's check if we have more than one sample with the same amplitude
314 // in such a case take central sample and also
315 // avoid maximum at the boundary (tm=minW)
316 for (t = tm + 1; t < maxW; ++t)
317 if ((int) digits.at(t) != maxSample) break;
318
319 t -= tm; // number of identical samples
320 if (t == 2 && tm == minW) ++tm; // move from the boundary
321 else tm += (t - 1) / 2; // center of the window
322
323 // return parameters for max sample in signal window
324 tMax = tm;
325 sampleWindow = maxSample;
326
327 // right limit for whole frame
328 maxW = m_frameLength;
329
330 // max sample after signal window
331 for ( ; t < maxW; ++t) {
332 if ( (int)digits.at(t) > maxSample ) {
333 tm = t;
334 maxSample = (int)digits.at(t);
335 }
336 }
337
338 // max sample before signal window
339 for (t = 0; t < minW; ++t) {
340 if ( (int)digits.at(t) > maxSample ) {
341 tm = t;
342 maxSample = (int)digits.at(t);
343 }
344 }
345
346 // return parameters for max adder in whole frame
347 tMaxFrame = tm;
348 sampleFrame = maxSample;
349
351 ATH_MSG_VERBOSE( "Got max sample " << sampleFrame
352 << " tMaxFrame=" << tMaxFrame
353 << " tMax=" << tMax );
354 }
355
356 return sampleWindow;
357}

◆ getOverflowedChannels()

Overflows_t & TileRawChannelBuilder::getOverflowedChannels ( void )
inherited

Definition at line 38 of file TileRawChannelBuilder.cxx.

38 {
39 return m_overflows;
40}

◆ getPedestal()

double TileRawChannelBuilderFlatFilter::getPedestal ( const std::vector< float > & digits,
int pedStart,
int pedLgt ) const
private

Calculate pedestal as mean of <pedLgt> samples starting from <pedStart>

Parameters
digitsVector of digits(double)
pedStartStart of pedestal
pedLgtLength of pedestal
Returns
Pedestal value

Definition at line 174 of file TileRawChannelBuilderFlatFilter.cxx.

175 {
176 int i, t, sum = 0;
177 double ped;
178
180 ATH_MSG_VERBOSE( "Getting pedestal " << pedStart
181 << "->" << (pedStart + pedLgt) );
182 }
183
184 if (pedLgt == 0)
185 return 0.0;
186 else if (pedLgt < 0) {
187 // calculate sum of ped_length samples starting from ped_start
188 // and go to the left (negative direction)
189 // if number of samples is not enough, start from the end of the frame */
190 pedLgt *= -1;
191 t = pedStart;
192 for (i = 0; i < pedLgt; ++i) {
193 if (t < 0) t += m_frameLength;
194 sum += (int) digits.at(t--);
195 }
196 }
197 else {
198 // calculate sum of ped_length samples starting from ped_start
199 // and go to the right
200 // if number of samples is not enough, start from the begining of the frame */
201 t = pedStart;
202 for (i = 0; i < pedLgt; ++i) {
203 if (t == m_frameLength) t -= m_frameLength;
204 sum += (int) digits.at(t++);
205 }
206 }
207
208 // calculate mean ped
209 ped = (double) sum / (double) pedLgt;
210
211 if (TILE_FLATFILTERBUILDERVERBOSE) ATH_MSG_VERBOSE( "Got pedestal " << ped );
212
213 return (ped);
214}

◆ getTileRawChannelContainerID()

std::string TileRawChannelBuilder::getTileRawChannelContainerID ( void )
inherited

Definition at line 42 of file TileRawChannelBuilder.cxx.

42 {
43 return m_rawChannelContainerKey.key();
44}

◆ getTime()

double TileRawChannelBuilderFlatFilter::getTime ( const std::vector< float > & digits,
int signalStart,
int signalLength,
double ped ) const
private

Calculate the time of signal in window of <signalLength> starting at <signalStart> Result is sum of time for every sample weighted with amplitude and divided by sum of times.

Parameters
digitsVector of digits(double)
signalStartStart of signal
signalLengthLength of signal in samples
pedPedestal value
Returns
Time of signal

Definition at line 445 of file TileRawChannelBuilderFlatFilter.cxx.

446 {
447
448 int t, tmax = signalStart + signalLength;
449 double position, val, sig = 0.0, sum = 0.0;
450
452 ATH_MSG_VERBOSE( "Getting time Signal: " << signalStart
453 << "->" << (signalStart + signalLength)
454 << " pedestal=" << ped );
455 }
456
457 // calculate sum of samples and sum of samples weighted with time
458 for (t = signalStart; t < tmax; ++t) {
459 val = (int) (digits.at(t) - ped);
460 sig += val;
461 sum += val * t;
462 }
463
464 if (sig > 0.0 && sum > 0) {
465 position = sum / sig;
466 // convert to nanoseconds
467 if (position < tmax) position *= 25.0;
468 else position = 0.0;
469
470 } else {
471 position = 0.0;
472 }
473
475 ATH_MSG_VERBOSE( "Got time " << position );
476
477 return (position);
478}

◆ initialize()

StatusCode TileRawChannelBuilderFlatFilter::initialize ( )
virtual

Initializer.

Reimplemented from TileRawChannelBuilder.

Definition at line 74 of file TileRawChannelBuilderFlatFilter.cxx.

74 {
75
76 ATH_MSG_INFO( "TileRawChannelBuilderFlatFilter::initialize()" );
77
79
80 // init in superclass
82
83 return StatusCode::SUCCESS;
84}
#define ATH_MSG_INFO(x)
#define CHECK(...)
Evaluate an expression and check for errors.
virtual StatusCode initialize()
Initializer.

◆ initLog()

void TileRawChannelBuilder::initLog ( const EventContext & ctx)
inherited

Definition at line 246 of file TileRawChannelBuilder.cxx.

246 {
247
248 const TileDQstatus* DQstatus = SG::makeHandle (m_DQstatusKey, ctx).get();
249
250 // update only if there is new event
251 if (m_evtCounter != ctx.evt()) {
252
253 m_evtCounter = ctx.evt();
254 if (m_runType != 0) m_trigType = m_runType;
255 else m_trigType = DQstatus->trigType();
256
257 if (0 == m_trigType) {
258 m_idophys = (DQstatus->calibMode() == 0);
259 m_idolas = false;
260 m_idoped = false;
261 m_idocis = (DQstatus->calibMode() == 1);
262 } else {
263 m_idophys = (m_trigType <= 1);
264 m_idolas = ((m_trigType == 2) || (m_trigType == 3));
265 m_idoped = ((m_trigType == 4) || (m_trigType == 5));
266 m_idocis = ((m_trigType == 8) || (m_trigType == 9));
267 }
268
269 const unsigned int *cispar = DQstatus->cispar();
270 if (0 == cispar[7]) { // if capdaq not set, it can't be CIS event
271 if (m_idocis) { // cis flag was set incorrectly, change to ped
272 m_idoped = true;
273 m_idocis = false;
274 }
275 m_capdaq = 0.0;
276 } else {
277 m_capdaq = (cispar[7] < 10) ? 5.2 : 100.0;
278 }
279 m_cischan = cispar[8] - 1; // channel where CIS is fired (-1 = all channels)
280
281 ATH_MSG_DEBUG( "Trig type is " << m_trigType
282 << "; dophys is " << ((m_idophys) ? "true" : "false")
283 << "; dolas is " << ((m_idolas) ? "true" : "false")
284 << "; doped is " << ((m_idoped) ? "true" : "false")
285 << "; docis is " << ((m_idocis) ? "true" : "false")
286 << "; capacitor is " << m_capdaq
287 << "; cis chan is " << m_cischan );
288 }
289}
int trigType() const
Trigger type.
uint32_t calibMode() const
Calibration mode.
const uint32_t * cispar() const
CIS parameters.

◆ inputHandles()

virtual std::vector< Gaudi::DataHandle * > AthCommonDataStore< AthCommonMsg< AlgTool > >::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.

◆ interfaceID()

const InterfaceID & TileRawChannelBuilderFlatFilter::interfaceID ( )
static

AlgTool InterfaceID.

Definition at line 31 of file TileRawChannelBuilderFlatFilter.cxx.

31 {
32 return IID_ITileRawChannelBuilderFlatFilter;
33 //return TileRawChannelBuilder::interfaceID();
34}

◆ isSignalInFrame()

bool TileRawChannelBuilderFlatFilter::isSignalInFrame ( const std::vector< float > & digits,
double deltaCut,
double rmsCut,
int & frameMax,
int & frameMin,
double & frameMean,
double & frameRMS ) const
private

Find min and max sample Calculate mean and RMS of all samples.

Returns true i signal is found

Parameters
digitsVector of digits(double)
delatCutDelta cut value
rmsCutRMS cut value
frameMaxStorage for max sample
frameMinStorage for frame min
frameMeanStorage for frame mean
frameRMSStorage for frame RMS
Returns
If signal was found

Definition at line 143 of file TileRawChannelBuilderFlatFilter.cxx.

144 {
145
146 int t, val;
147 // First compute the values that will be used to decide
148 min = 65536;
149 max = 0;
150 mean = 0.0;
151 rms = 0.0;
152
154 ATH_MSG_VERBOSE( "Checking for signal in frame" );
155
156 for (t = 0; t < m_frameLength; ++t) {
157 val = (int)digits.at(t);
158 mean += val;
159 rms += val*val;
160 if ( val < min ) min = val;
161 if ( val > max ) max = val;
162 }
163
166 rms = sqrt(rms - mean*mean);
167 if ( ( (max-min) >= deltaCut ) &&
168 ( rms >= rmsCut ) ) {
169 return true;
170 }
171 else return false;
172}
#define min(a, b)
Definition cfImp.cxx:40
#define max(a, b)
Definition cfImp.cxx:41
void mean(std::vector< double > &bins, std::vector< double > &values, const std::vector< std::string > &files, const std::string &histname, const std::string &tplotname, const std::string &label="")

◆ msg()

MsgStream & AthCommonMsg< AlgTool >::msg ( ) const
inlineinherited

Definition at line 24 of file AthCommonMsg.h.

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

◆ msgLvl()

bool AthCommonMsg< AlgTool >::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< AlgTool > >::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.

◆ rawChannel()

TileRawChannel * TileRawChannelBuilderFlatFilter::rawChannel ( const TileDigits * digits,
const EventContext & ctx )
virtual

Builder virtual method to be implemented by subclasses.

Parameters
digitsPointer to TileDigitsContainer

Reimplemented from TileRawChannelBuilder.

Definition at line 92 of file TileRawChannelBuilderFlatFilter.cxx.

92 {
93
95
96 const HWIdentifier adcId = digits->adc_HWID();
97 int gain = m_tileHWID->adc(adcId);
98
99 ATH_MSG_VERBOSE( "Running FlatFilter for TileRawChannel with HWID "
100 << m_tileHWID->to_string(adcId) );
101
102 // tmp variables for filtering
103 double amplitude = 0.0;
104 double time = 0.0;
105
106 // use flat filter
107 flatFilter(digits->samples(), gain, amplitude, time);
108
109 unsigned int drawerIdx(0), channel(0), adc(0);
110 m_tileIdTransforms->getIndices(adcId, drawerIdx, channel, adc);
111
112 // flat filter calib
113 if (m_calibrateEnergy) {
114 amplitude = m_tileToolEmscale->doCalibCis(drawerIdx, channel, adc, amplitude);
115 }
116
117 ATH_MSG_VERBOSE( "Creating RawChannel a=" << amplitude << " t=" << time );
118
119 // return new TileRawChannel
120 // TileRawChannel *rawCh = new TileRawChannel(adcId,amplitude,time,0.0);
121
122 DataPool<TileRawChannel> tileRchPool(m_dataPoollSize);
123 TileRawChannel *rawCh = tileRchPool.nextElementPtr();
124 rawCh->assign (adcId, amplitude, time, 0, 0);
125
126 if (m_correctTime) {
127 time -= m_tileToolTiming->getSignalPhase(drawerIdx, channel, adc);
128 rawCh->insertTime(time);
129 ATH_MSG_VERBOSE( "Correcting time, new time=" << rawCh->time() );
130 }
131
132 if (TileID::HIGHGAIN == gain) {
133 ++m_nChH;
134 m_RChSumH += amplitude;
135 } else {
136 ++m_nChL;
137 m_RChSumL += amplitude;
138 }
139
140 return rawCh;
141}
ToolHandle< TileCondToolTiming > m_tileToolTiming
ToolHandle< TileCondIdTransforms > m_tileIdTransforms
ToolHandle< TileCondToolEmscale > m_tileToolEmscale
void assign(const HWIdentifier &id, float amplitude, float time, float quality, float ped=0.0)
void insertTime(float time)
float time(int ind=0) const

◆ 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< AlgTool > >::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< AlgTool > >::renounceArray ( SG::VarHandleKeyArray & handlesArray)
inlineprotectedinherited

remove all handles from I/O resolution

Definition at line 364 of file AthCommonDataStore.h.

364 {
366 }

◆ resetDrawer()

void TileRawChannelBuilder::resetDrawer ( )
inherited

Definition at line 29 of file TileRawChannelBuilder.cxx.

29 {
30 m_lastDrawer = -1;
31 m_badDrawer = false;
32}

◆ resetOverflows()

void TileRawChannelBuilder::resetOverflows ( void )
inherited

Definition at line 34 of file TileRawChannelBuilder.cxx.

34 {
35 m_overflows.clear();
36}

◆ sysInitialize()

virtual StatusCode AthCommonDataStore< AthCommonMsg< AlgTool > >::sysInitialize ( )
overridevirtualinherited

Perform system initialization for an algorithm.

We override this to declare all the elements of handle key arrays at the end of initialization. See comments on updateVHKA.

Reimplemented in asg::AsgMetadataTool, AthCheckedComponent< AthAlgTool >, AthCheckedComponent<::AthAlgTool >, and DerivationFramework::CfAthAlgTool.

◆ sysStart()

virtual StatusCode AthCommonDataStore< AthCommonMsg< AlgTool > >::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< AlgTool > >::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 }
std::vector< SG::VarHandleKeyArray * > m_vhka

Member Data Documentation

◆ m_ADCmaskValueMinusEps

float TileRawChannelBuilder::m_ADCmaskValueMinusEps
protectedinherited

indicates channels which were masked in background dataset

Definition at line 222 of file TileRawChannelBuilder.h.

◆ m_ADCmaxMinusEps

float TileRawChannelBuilder::m_ADCmaxMinusEps
protectedinherited

Definition at line 221 of file TileRawChannelBuilder.h.

◆ m_ampMinThresh

float TileRawChannelBuilder::m_ampMinThresh
protectedinherited

correct amplitude if it's above amplitude threshold (in ADC counts)

Definition at line 152 of file TileRawChannelBuilder.h.

◆ m_badDrawer

bool TileRawChannelBuilder::m_badDrawer = false
protectedinherited

Definition at line 210 of file TileRawChannelBuilder.h.

◆ m_bsflags

unsigned int TileRawChannelBuilder::m_bsflags
protectedinherited

Definition at line 138 of file TileRawChannelBuilder.h.

◆ m_cabling

const TileCablingService* TileRawChannelBuilder::m_cabling
protectedinherited

TileCabling instance.

Definition at line 182 of file TileRawChannelBuilder.h.

◆ m_cablingSvc

ServiceHandle<TileCablingSvc> TileRawChannelBuilder::m_cablingSvc
protectedinherited
Initial value:
{ this,
"TileCablingSvc", "TileCablingSvc", "The Tile cabling service"}

Name of Tile cabling service.

Definition at line 179 of file TileRawChannelBuilder.h.

179 { this,
180 "TileCablingSvc", "TileCablingSvc", "The Tile cabling service"};

◆ m_calibrateEnergy

bool TileRawChannelBuilder::m_calibrateEnergy
protectedinherited

Definition at line 142 of file TileRawChannelBuilder.h.

◆ m_capdaq

double TileRawChannelBuilder::m_capdaq
protectedinherited

Definition at line 193 of file TileRawChannelBuilder.h.

◆ m_chCounter

unsigned int TileRawChannelBuilder::m_chCounter
protectedinherited

Definition at line 196 of file TileRawChannelBuilder.h.

◆ m_cischan

int TileRawChannelBuilder::m_cischan
protectedinherited

Definition at line 192 of file TileRawChannelBuilder.h.

◆ m_correctTime

bool TileRawChannelBuilder::m_correctTime
protectedinherited

Definition at line 145 of file TileRawChannelBuilder.h.

◆ m_dataPoollSize

int TileRawChannelBuilder::m_dataPoollSize
protectedinherited

Definition at line 204 of file TileRawChannelBuilder.h.

◆ m_deltaCut

double TileRawChannelBuilderFlatFilter::m_deltaCut[2]
private

Definition at line 161 of file TileRawChannelBuilderFlatFilter.h.

◆ m_demoFragIDs

Gaudi::Property<std::vector<int> > TileRawChannelBuilder::m_demoFragIDs
protectedinherited
Initial value:
{this,
"DemoFragIDs", {}, "List of Tile frag IDs with new electronics (demonstrator)"}

Definition at line 184 of file TileRawChannelBuilder.h.

184 {this,
185 "DemoFragIDs", {}, "List of Tile frag IDs with new electronics (demonstrator)"};

◆ m_detStore

StoreGateSvc_t AthCommonDataStore< AthCommonMsg< AlgTool > >::m_detStore
privateinherited

Pointer to StoreGate (detector store by default)

Definition at line 393 of file AthCommonDataStore.h.

◆ m_DQstatusKey

SG::ReadHandleKey<TileDQstatus> TileRawChannelBuilder::m_DQstatusKey
protectedinherited
Initial value:
{this, "TileDQstatus",
"TileDQstatus",
"TileDQstatus key"}

Definition at line 120 of file TileRawChannelBuilder.h.

120 {this, "TileDQstatus",
121 "TileDQstatus",
122 "TileDQstatus key"};

◆ m_DSPContainerKey

SG::ReadHandleKey<TileRawChannelContainer> TileRawChannelBuilder::m_DSPContainerKey {this, "DSPContainer", "", "DSP Container key"}
protectedinherited

Definition at line 125 of file TileRawChannelBuilder.h.

126{this, "DSPContainer", "", "DSP Container key"};

◆ m_error

int TileRawChannelBuilder::m_error[MAX_CHANNELS]
protectedinherited

Definition at line 208 of file TileRawChannelBuilder.h.

◆ m_evtCounter

unsigned int TileRawChannelBuilder::m_evtCounter
protectedinherited

Definition at line 195 of file TileRawChannelBuilder.h.

◆ m_evtStore

StoreGateSvc_t AthCommonDataStore< AthCommonMsg< AlgTool > >::m_evtStore
privateinherited

Pointer to StoreGate (event store by default)

Definition at line 390 of file AthCommonDataStore.h.

◆ m_f_ADCmax

float TileRawChannelBuilder::m_f_ADCmax
protectedinherited

Definition at line 218 of file TileRawChannelBuilder.h.

◆ m_f_ADCmaxPlus1

float TileRawChannelBuilder::m_f_ADCmaxPlus1
protectedinherited

Definition at line 220 of file TileRawChannelBuilder.h.

◆ m_filterLength

int TileRawChannelBuilderFlatFilter::m_filterLength
private

Definition at line 158 of file TileRawChannelBuilderFlatFilter.h.

◆ m_firstSample

int TileRawChannelBuilder::m_firstSample
protectedinherited

Definition at line 140 of file TileRawChannelBuilder.h.

◆ m_frameLength

int TileRawChannelBuilderFlatFilter::m_frameLength
private

Definition at line 159 of file TileRawChannelBuilderFlatFilter.h.

◆ m_i_ADCmax

int TileRawChannelBuilder::m_i_ADCmax
protectedinherited

Definition at line 217 of file TileRawChannelBuilder.h.

◆ m_i_ADCmaxPlus1

int TileRawChannelBuilder::m_i_ADCmaxPlus1
protectedinherited

Definition at line 219 of file TileRawChannelBuilder.h.

◆ m_idocis

bool TileRawChannelBuilder::m_idocis
protectedinherited

Definition at line 191 of file TileRawChannelBuilder.h.

◆ m_idolas

bool TileRawChannelBuilder::m_idolas
protectedinherited

Definition at line 189 of file TileRawChannelBuilder.h.

◆ m_idoped

bool TileRawChannelBuilder::m_idoped
protectedinherited

Definition at line 190 of file TileRawChannelBuilder.h.

◆ m_idophys

bool TileRawChannelBuilder::m_idophys
protectedinherited

Definition at line 188 of file TileRawChannelBuilder.h.

◆ m_infoName

std::string TileRawChannelBuilder::m_infoName
protectedinherited

Definition at line 215 of file TileRawChannelBuilder.h.

◆ m_lastDrawer

int TileRawChannelBuilder::m_lastDrawer = -1
protectedinherited

Definition at line 209 of file TileRawChannelBuilder.h.

◆ m_nChH

int TileRawChannelBuilder::m_nChH
protectedinherited

Definition at line 199 of file TileRawChannelBuilder.h.

◆ m_nChL

int TileRawChannelBuilder::m_nChL
protectedinherited

Definition at line 198 of file TileRawChannelBuilder.h.

◆ m_noiseFilterTools

ToolHandleArray<ITileRawChannelTool> TileRawChannelBuilder::m_noiseFilterTools
protectedinherited
Initial value:
{this,
"NoiseFilterTools", {}, "Tile noise filter tools"}

Definition at line 163 of file TileRawChannelBuilder.h.

163 {this,
164 "NoiseFilterTools", {}, "Tile noise filter tools"};

◆ m_notUpgradeCabling

bool TileRawChannelBuilder::m_notUpgradeCabling
protectedinherited

Definition at line 212 of file TileRawChannelBuilder.h.

◆ m_overflows

Overflows_t TileRawChannelBuilder::m_overflows
protectedinherited

Definition at line 203 of file TileRawChannelBuilder.h.

◆ m_pedLength

int TileRawChannelBuilderFlatFilter::m_pedLength
private

Definition at line 154 of file TileRawChannelBuilderFlatFilter.h.

◆ m_pedOffset

int TileRawChannelBuilderFlatFilter::m_pedOffset
private

Definition at line 155 of file TileRawChannelBuilderFlatFilter.h.

◆ m_pedStart

int TileRawChannelBuilderFlatFilter::m_pedStart
private

Definition at line 153 of file TileRawChannelBuilderFlatFilter.h.

◆ m_rawChannelCnt

std::unique_ptr<TileMutableRawChannelContainer> TileRawChannelBuilder::m_rawChannelCnt
protectedinherited

Definition at line 133 of file TileRawChannelBuilder.h.

◆ m_rawChannelContainerKey

SG::WriteHandleKey<TileRawChannelContainer> TileRawChannelBuilder::m_rawChannelContainerKey
protectedinherited
Initial value:
{this,"TileRawChannelContainer","TileRawChannelFiltered",
"Output Tile raw channels container key"}

Definition at line 129 of file TileRawChannelBuilder.h.

129 {this,"TileRawChannelContainer","TileRawChannelFiltered",
130 "Output Tile raw channels container key"};

◆ m_RChSumH

double TileRawChannelBuilder::m_RChSumH
protectedinherited

Definition at line 201 of file TileRawChannelBuilder.h.

◆ m_RChSumL

double TileRawChannelBuilder::m_RChSumL
protectedinherited

Definition at line 200 of file TileRawChannelBuilder.h.

◆ m_rChType

TileFragHash::TYPE TileRawChannelBuilder::m_rChType
protectedinherited

Definition at line 136 of file TileRawChannelBuilder.h.

◆ m_rChUnit

TileRawChannelUnit::UNIT TileRawChannelBuilder::m_rChUnit
protectedinherited

Definition at line 137 of file TileRawChannelBuilder.h.

◆ m_rmsCut

double TileRawChannelBuilderFlatFilter::m_rmsCut[2]
private

Definition at line 162 of file TileRawChannelBuilderFlatFilter.h.

◆ m_runType

int TileRawChannelBuilder::m_runType
protectedinherited

Definition at line 157 of file TileRawChannelBuilder.h.

◆ m_signalLength

int TileRawChannelBuilderFlatFilter::m_signalLength
private

Definition at line 157 of file TileRawChannelBuilderFlatFilter.h.

◆ m_signalStart

int TileRawChannelBuilderFlatFilter::m_signalStart
private

Definition at line 156 of file TileRawChannelBuilderFlatFilter.h.

◆ m_tileHWID

const TileHWID* TileRawChannelBuilder::m_tileHWID
protectedinherited

Definition at line 161 of file TileRawChannelBuilder.h.

◆ m_tileID

const TileID* TileRawChannelBuilder::m_tileID
protectedinherited

Definition at line 160 of file TileRawChannelBuilder.h.

◆ m_tileIdTransforms

ToolHandle<TileCondIdTransforms> TileRawChannelBuilder::m_tileIdTransforms
protectedinherited
Initial value:
{this,
"TileCondIdTransforms", "TileCondIdTransforms",
"Tile tool to tranlate hardware identifier to the drawerIdx, channel, and adc"}

Definition at line 172 of file TileRawChannelBuilder.h.

172 {this,
173 "TileCondIdTransforms", "TileCondIdTransforms",
174 "Tile tool to tranlate hardware identifier to the drawerIdx, channel, and adc"};

◆ m_tileInfo

const TileInfo* TileRawChannelBuilder::m_tileInfo
protectedinherited

Definition at line 216 of file TileRawChannelBuilder.h.

◆ m_tileToolEmscale

ToolHandle<TileCondToolEmscale> TileRawChannelBuilder::m_tileToolEmscale
protectedinherited
Initial value:
{this,
"TileCondToolEmscale", "TileCondToolEmscale", "Tile EM scale calibration tool"}

Definition at line 166 of file TileRawChannelBuilder.h.

166 {this,
167 "TileCondToolEmscale", "TileCondToolEmscale", "Tile EM scale calibration tool"};

◆ m_tileToolTiming

ToolHandle<TileCondToolTiming> TileRawChannelBuilder::m_tileToolTiming
protectedinherited
Initial value:
{this,
"TileCondToolTiming", "TileCondToolTiming", "Tile timing tool"}

Definition at line 169 of file TileRawChannelBuilder.h.

169 {this,
170 "TileCondToolTiming", "TileCondToolTiming", "Tile timing tool"};

◆ m_timeMaxThresh

float TileRawChannelBuilder::m_timeMaxThresh
protectedinherited

correct amplitude is time is below time max threshold

Definition at line 154 of file TileRawChannelBuilder.h.

◆ m_timeMinThresh

float TileRawChannelBuilder::m_timeMinThresh
protectedinherited

correct amplitude is time is above time min threshold

Definition at line 153 of file TileRawChannelBuilder.h.

◆ m_trigType

int TileRawChannelBuilder::m_trigType
protectedinherited

Definition at line 187 of file TileRawChannelBuilder.h.

◆ m_useDSP

bool TileRawChannelBuilder::m_useDSP
protectedinherited

Definition at line 149 of file TileRawChannelBuilder.h.

◆ m_varHandleArraysDeclared

bool AthCommonDataStore< AthCommonMsg< AlgTool > >::m_varHandleArraysDeclared
privateinherited

Definition at line 399 of file AthCommonDataStore.h.

◆ m_vhka

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

Definition at line 398 of file AthCommonDataStore.h.

◆ MAX_CHANNELS

const int TileRawChannelBuilder::MAX_CHANNELS = 48
staticprotectedinherited

Definition at line 206 of file TileRawChannelBuilder.h.

◆ MAX_DMUS

const int TileRawChannelBuilder::MAX_DMUS = 16
staticprotectedinherited

Definition at line 207 of file TileRawChannelBuilder.h.


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