ATLAS Offline Software
Loading...
Searching...
No Matches
LVL1::L1CaloOfflineTriggerTowerTools Class Reference

#include <L1CaloOfflineTriggerTowerTools.h>

Inheritance diagram for LVL1::L1CaloOfflineTriggerTowerTools:
Collaboration diagram for LVL1::L1CaloOfflineTriggerTowerTools:

Public Types

typedef std::map< Identifier, const TileTTL1Cell * > IdTTL1CellMapType
typedef std::vector< constCaloCell * >::const_iterator Itr_vCaloCells
typedef std::vector< std::vector< constCaloCell * > >::const_iterator Itr_vvCaloCells

Public Member Functions

 L1CaloOfflineTriggerTowerTools (const std::string &name)
 Create a proper constructor for Athena.
virtual ~L1CaloOfflineTriggerTowerTools ()
 destructor
 L1CaloOfflineTriggerTowerTools ()=delete
 delete the big 4
 L1CaloOfflineTriggerTowerTools (const L1CaloOfflineTriggerTowerTools &rhs)=delete
 L1CaloOfflineTriggerTowerTools (L1CaloOfflineTriggerTowerTools &&rhs)=delete
L1CaloOfflineTriggerTowerToolsoperator= (const L1CaloOfflineTriggerTowerTools &rhs)=delete
virtual StatusCode initialize () override
 Dummy implementation of the initialisation function.
virtual StatusCode finalize () override
virtual int emPpmCrate (const TriggerTower *tt) const override
virtual int emPpmModule (const TriggerTower *tt) const override
virtual int emPpmSubmodule (const TriggerTower *tt) const override
virtual int emPpmChannel (const TriggerTower *tt) const override
virtual unsigned int emCoolChannelId (const TriggerTower *tt) const override
virtual std::vector< int > emLocation (const TriggerTower *tt) const override
virtual std::vector< unsigned int > emRxId (const TriggerTower *tt) const override
virtual int hadPpmCrate (const TriggerTower *tt) const override
virtual int hadPpmModule (const TriggerTower *tt) const override
virtual int hadPpmSubmodule (const TriggerTower *tt) const override
virtual int hadPpmChannel (const TriggerTower *tt) const override
virtual unsigned int hadCoolChannelId (const TriggerTower *tt) const override
virtual std::vector< int > hadLocation (const TriggerTower *tt) const override
virtual std::vector< unsigned int > hadRxId (const TriggerTower *tt) const override
virtual int hadIsTile (const TriggerTower *tt) const override
virtual std::vector< const CaloCell * > emCells (const TriggerTower *tt) const override
virtual int emNCells (const TriggerTower *tt) const override
virtual std::vector< int > emNCellsByLayer (const TriggerTower *tt) const override
virtual std::vector< int > emNCellsByReceiver (const TriggerTower *tt) const override
virtual std::vector< std::vector< int > > emNCellsByReceiverByLayer (const TriggerTower *tt) const override
virtual std::vector< int > emTTCellsLayerNames (const TriggerTower *tt) const override
virtual std::vector< std::vector< int > > emTTCellsLayerNamesByReceiver (const TriggerTower *tt) const override
virtual float emTTCellsEnergy (const TriggerTower *tt) const override
virtual std::vector< float > emTTCellsEnergyByLayer (const TriggerTower *tt) const override
virtual std::vector< float > emTTCellsEnergyByReceiver (const TriggerTower *tt, const int mode=0) const override
virtual float emTTCellsEt (const TriggerTower *tt) const override
virtual std::vector< float > emTTCellsEtByLayer (const TriggerTower *tt) const override
virtual std::vector< float > emTTCellsEtByReceiver (const TriggerTower *tt, const int mode=0) const override
virtual std::vector< const CaloCell * > hadCells (const TriggerTower *tt) const override
virtual int hadNCells (const TriggerTower *tt) const override
virtual std::vector< int > hadNCellsByLayer (const TriggerTower *tt) const override
virtual std::vector< int > hadNCellsByReceiver (const TriggerTower *tt) const override
virtual std::vector< std::vector< int > > hadNCellsByReceiverByLayer (const TriggerTower *tt) const override
virtual std::vector< int > hadTTCellsLayerNames (const TriggerTower *tt) const override
virtual std::vector< std::vector< int > > hadTTCellsLayerNamesByReceiver (const TriggerTower *tt) const override
virtual float hadTTCellsEnergy (const TriggerTower *tt) const override
virtual std::vector< float > hadTTCellsEnergyByLayer (const TriggerTower *tt) const override
virtual std::vector< float > hadTTCellsEnergyByReceiver (const TriggerTower *tt, const int mode=0) const override
virtual float hadTTCellsEt (const TriggerTower *tt) const override
virtual std::vector< float > hadTTCellsEtByLayer (const TriggerTower *tt) const override
virtual std::vector< float > hadTTCellsEtByReceiver (const TriggerTower *tt, const int mode=0) const override
virtual float tileCellEnergy (const TriggerTower *tt, IdTTL1CellMapType &map) const override
virtual float emCaloQuality (const TriggerTower *tt) const override
virtual float emNCellsNonNominal (const TriggerTower *tt) const override
virtual std::vector< float > emNCellsNonNominalByLayer (const TriggerTower *tt) const override
virtual std::vector< std::vector< float > > emNCellsNonNominalByReceiverByLayer (const TriggerTower *tt) const override
virtual float emNonNominalMeanScale (const TriggerTower *tt) const override
virtual std::vector< float > emNonNominalMeanScaleByLayer (const TriggerTower *tt) const override
virtual std::vector< float > emNonNominalMeanScaleByReceiver (const TriggerTower *tt) const override
virtual std::vector< std::vector< float > > emNonNominalMeanScaleByReceiverByLayer (const TriggerTower *tt) const override
virtual float hadCaloQuality (const TriggerTower *tt) const override
virtual float hadNCellsNonNominal (const TriggerTower *tt) const override
virtual std::vector< float > hadNCellsNonNominalByLayer (const TriggerTower *tt) const override
virtual std::vector< std::vector< float > > hadNCellsNonNominalByReceiverByLayer (const TriggerTower *tt) const override
virtual float hadNonNominalMeanScale (const TriggerTower *tt) const override
virtual std::vector< float > hadNonNominalMeanScaleByLayer (const TriggerTower *tt) const override
virtual std::vector< float > hadNonNominalMeanScaleByReceiver (const TriggerTower *tt) const override
virtual std::vector< std::vector< float > > hadNonNominalMeanScaleByReceiverByLayer (const TriggerTower *tt) const override
virtual const coral::AttributeList * emDbAttributes (const TriggerTower *tt, const CondAttrListCollection *dbAttrList) const override
virtual std::vector< const coral::AttributeList * > emDbRxGainsAttributes (const TriggerTower *tt, const CondAttrListCollection *dbAttrList) const override
virtual const coral::AttributeList * hadDbAttributes (const TriggerTower *tt, const CondAttrListCollection *dbAttrList) const override
virtual std::vector< const coral::AttributeList * > hadDbRxGainsAttributes (const TriggerTower *tt, const CondAttrListCollection *dbAttrList) const override
std::vector< int > emSuperCellIdentifiers (const TriggerTower *tt) const
std::vector< int > hadSuperCellIdentifiers (const TriggerTower *tt) const
virtual unsigned int ModuleId (const coral::AttributeList *attrList) const override
virtual unsigned int ErrorCode (const coral::AttributeList *attrList) const override
virtual unsigned long long PprDacScanResultsTimeStamp (const coral::AttributeList *attrList) const override
virtual unsigned long long PprPedestalRunResultsTimeStamp (const coral::AttributeList *attrList) const override
virtual unsigned long long PprNoiseRunResultsTimeStamp (const coral::AttributeList *attrList) const override
virtual unsigned long long PprTimingResultsTimeStamp (const coral::AttributeList *attrList) const override
virtual unsigned long long PprSatBcidResultsTimeStamp (const coral::AttributeList *attrList) const override
virtual unsigned long long PprFirFilterResultsTimeStamp (const coral::AttributeList *attrList) const override
virtual unsigned long long PprLutValuesResultsTimeStamp (const coral::AttributeList *attrList) const override
virtual double DacOffset (const coral::AttributeList *attrList) const override
virtual double DacSlope (const coral::AttributeList *attrList) const override
virtual double PedMean (const coral::AttributeList *attrList) const override
virtual unsigned int PedValue (const coral::AttributeList *attrList) const override
virtual unsigned int FullDelayData (const coral::AttributeList *attrList) const override
virtual unsigned short int SyncDelayBcid (const coral::AttributeList *attrList) const override
virtual unsigned short int InBcidNegedge (const coral::AttributeList *attrList) const override
virtual unsigned short int ExtBcidThreshold (const coral::AttributeList *attrList) const override
virtual unsigned short int SatBcidThreshLow (const coral::AttributeList *attrList) const override
virtual unsigned short int SatBcidThreshHigh (const coral::AttributeList *attrList) const override
virtual unsigned short int SatBcidLevel (const coral::AttributeList *attrList) const override
virtual unsigned short int BcidEnergyRangeLow (const coral::AttributeList *attrList) const override
virtual unsigned short int BcidEnergyRangeHigh (const coral::AttributeList *attrList) const override
virtual unsigned short int FirStartBit (const coral::AttributeList *attrList) const override
virtual short FirCoeff1 (const coral::AttributeList *attrList) const override
virtual short FirCoeff2 (const coral::AttributeList *attrList) const override
virtual short FirCoeff3 (const coral::AttributeList *attrList) const override
virtual short FirCoeff4 (const coral::AttributeList *attrList) const override
virtual short FirCoeff5 (const coral::AttributeList *attrList) const override
virtual unsigned short LutStrategy (const coral::AttributeList *attrList) const override
virtual unsigned short LutOffset (const coral::AttributeList *attrList) const override
virtual unsigned short LutNoiseCut (const coral::AttributeList *attrList) const override
virtual unsigned short LutSlope (const coral::AttributeList *attrList) const override
virtual unsigned int DeadChannel (const coral::AttributeList *attrList) const override
virtual unsigned int DisabledTower (const coral::AttributeList *attrList) const override
virtual float RxGain (const coral::AttributeList *attrList) const override
virtual unsigned int RxStatus (const coral::AttributeList *attrList) const override
virtual void LArHV (const SG::ReadCondHandleKey< ILArHVScaleCorr > &scaleCorrKey, const SG::ReadCondHandleKey< LArOnOffIdMapping > &cablingKey) override
virtual void caloCells (const CaloCellContainer *cells) override
Identifier ID (const double eta, const double phi, int layer) const
virtual Identifier emID (const double eta, const double phi) const override
virtual Identifier hadID (const double eta, const double phi) const override
virtual void print () const
 Print the state of the tool.
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
Additional helper functions, not directly mimicking Athena
template<class T>
const T * getProperty (const std::string &name) const
 Get one of the tool's properties.
const std::string & msg_level_name () const __attribute__((deprecated))
 A deprecated function for getting the message level's name.
const std::string & getName (const void *ptr) const
 Get the name of an object that is / should be in the event store.
SG::sgkey_t getKey (const void *ptr) const
 Get the (hashed) key of an object that is in the event store.

Protected Member Functions

virtual int pos_neg_z (const double eta) const override
virtual int region (const double eta) const override
virtual int ieta (const double eta) const override
virtual int iphi (const double eta, const double phi) const override
virtual std::vector< L1CaloRxCoolChannelIdemReceivers (const TriggerTower *tt) const override
virtual std::vector< L1CaloRxCoolChannelIdhadReceivers (const TriggerTower *tt) const override
virtual std::vector< std::vector< const CaloCell * > > sortFCAL23Cells (const std::vector< const CaloCell * > &cells, const double eta) const override
virtual std::vector< std::vector< const CaloCell * > > sortFCAL23Cells (const std::vector< const CaloCell * > &cells, const std::vector< unsigned int > &rxId) const override
virtual std::vector< std::vector< const CaloCell * > > sortEMCrackCells (const std::vector< const CaloCell * > &cells) const override
virtual float LArNonNominalHV (const std::vector< const CaloCell * > &cells) const override
virtual float LArNonNominalHV (const CaloCell *cell, const ILArHVScaleCorr *scaleCorr, const ILArHVScaleCorr *onlineScaleCorr, const LArOnOffIdMapping *cabling) const override
virtual float LArHVScale (const std::vector< const CaloCell * > &cells) const override
virtual float LArHVScale (const CaloCell *cell, const ILArHVScaleCorr *scaleCorr, const ILArHVScaleCorr *onlineScaleCorr, const LArOnOffIdMapping *cabling) const override
virtual float TileNonNominal (const std::vector< const CaloCell * > &cells) const override
virtual float TileNonNominal (const CaloCell *cell) const override
virtual float LArCaloQuality (const std::vector< const CaloCell * > &cells) const override
virtual float TileCaloQuality (const std::vector< const CaloCell * > &cells) const override
std::vector< int > SuperCellIdentifiers (const std::vector< const CaloCell * > &cells) const
void renounceArray (SG::VarHandleKeyArray &handlesArray)
 remove all handles from I/O resolution
std::enable_if_t< std::is_void_v< std::result_of_t< decltype(&T::renounce)(T)> > &&!std::is_base_of_v< SG::VarHandleKeyArray, T > &&std::is_base_of_v< Gaudi::DataHandle, T >, void > renounce (T &h)
void extraDeps_update_handler (Gaudi::Details::PropertyBase &ExtraDeps)
 Add StoreName to extra input/output deps as needed.

Private Types

typedef ServiceHandle< StoreGateSvcStoreGateSvc_t

Private Member Functions

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

Private Attributes

ToolHandle< LVL1::IL1CaloTTIdToolsm_l1CaloTTIdTools
ToolHandle< LVL1::IL1CaloCells2TriggerTowersm_cells2tt
const CaloIdManagerm_caloMgr
ToolHandle< CaloTriggerTowerServicem_ttSvc
const TTOnlineIDm_ttOnlineIdHelper
const CaloLVL1_IDm_lvl1Helper
const LArOnlineIDm_larOnlineID
ToolHandle< ICaloSuperCellIDToolm_scidtool
bool m_isLArHVCorrToolSet
double m_LArHVNonNomPara
SG::ReadCondHandleKey< ILArHVScaleCorrm_scaleCorrKey
SG::ReadCondHandleKey< LArOnOffIdMappingm_cablingKey
const TileHWIDm_tileHWID
ToolHandle< ITileBadChanToolm_tileBadChanTool
ToolHandle< LVL1::IL1CaloFcal23Cells2RxMappingToolm_rxMapTool
SG::ReadCondHandleKey< ILArHVScaleCorrm_onlineScaleCorrKey { this, "OnlineLArHVScaleCorr", "LArHVScaleCorr", "" }
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 68 of file L1CaloOfflineTriggerTowerTools.h.

Member Typedef Documentation

◆ IdTTL1CellMapType

◆ Itr_vCaloCells

Definition at line 85 of file L1CaloOfflineTriggerTowerTools.h.

◆ Itr_vvCaloCells

typedef std::vector<std::vector<constCaloCell*>>::const_iterator LVL1::L1CaloOfflineTriggerTowerTools::Itr_vvCaloCells

Definition at line 86 of file L1CaloOfflineTriggerTowerTools.h.

◆ StoreGateSvc_t

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

Definition at line 388 of file AthCommonDataStore.h.

Constructor & Destructor Documentation

◆ L1CaloOfflineTriggerTowerTools() [1/4]

LVL1::L1CaloOfflineTriggerTowerTools::L1CaloOfflineTriggerTowerTools ( const std::string & name)

Create a proper constructor for Athena.

constructor

Definition at line 16 of file L1CaloOfflineTriggerTowerTools.cxx.

16 :
17 asg::AsgTool( name ),
18 m_l1CaloTTIdTools("LVL1::L1CaloTTIdTools/L1CaloTTIdTools"),
19 m_cells2tt("LVL1::L1CaloCells2TriggerTowers/L1CaloCells2TriggerTowers", this),
20 m_ttSvc("CaloTriggerTowerService"),
21 m_scidtool ("CaloSuperCellIDTool"),
23 m_cablingKey(""),
24 m_tileBadChanTool("TileBadChanTool"),
25 m_rxMapTool("LVL1::L1CaloFcal23Cells2RxMappingTool/L1CaloFcal23Cells2RxMappingTool")
26 {
27 m_caloMgr = 0;
29 m_lvl1Helper = 0;
30 m_larOnlineID = 0;
32 m_tileHWID = 0;
33
34 declareProperty("LArHVNonNomPara",m_LArHVNonNomPara = 1.003);
35 declareProperty("TileBadChanTool", m_tileBadChanTool);
36 declareProperty("RxMappingTool",m_rxMapTool);
37 }
Gaudi::Details::PropertyBase & declareProperty(Gaudi::Property< T, V, H > &t)
ToolHandle< CaloTriggerTowerService > m_ttSvc
ToolHandle< ICaloSuperCellIDTool > m_scidtool
ToolHandle< LVL1::IL1CaloCells2TriggerTowers > m_cells2tt
ToolHandle< LVL1::IL1CaloTTIdTools > m_l1CaloTTIdTools
SG::ReadCondHandleKey< LArOnOffIdMapping > m_cablingKey
ToolHandle< LVL1::IL1CaloFcal23Cells2RxMappingTool > m_rxMapTool
SG::ReadCondHandleKey< ILArHVScaleCorr > m_scaleCorrKey

◆ ~L1CaloOfflineTriggerTowerTools()

virtual LVL1::L1CaloOfflineTriggerTowerTools::~L1CaloOfflineTriggerTowerTools ( )
inlinevirtual

destructor

Definition at line 77 of file L1CaloOfflineTriggerTowerTools.h.

77{}

◆ L1CaloOfflineTriggerTowerTools() [2/4]

LVL1::L1CaloOfflineTriggerTowerTools::L1CaloOfflineTriggerTowerTools ( )
delete

delete the big 4

◆ L1CaloOfflineTriggerTowerTools() [3/4]

LVL1::L1CaloOfflineTriggerTowerTools::L1CaloOfflineTriggerTowerTools ( const L1CaloOfflineTriggerTowerTools & rhs)
delete

◆ L1CaloOfflineTriggerTowerTools() [4/4]

LVL1::L1CaloOfflineTriggerTowerTools::L1CaloOfflineTriggerTowerTools ( L1CaloOfflineTriggerTowerTools && rhs)
delete

Member Function Documentation

◆ BcidEnergyRangeHigh()

unsigned short int LVL1::L1CaloOfflineTriggerTowerTools::BcidEnergyRangeHigh ( const coral::AttributeList * attrList) const
overridevirtual

Implements LVL1::IL1CaloOfflineTriggerTowerTools.

Definition at line 1518 of file L1CaloOfflineTriggerTowerTools.cxx.

1518 {
1519 unsigned short int value = 0;
1520 for(unsigned int attrNum=0;attrNum<attrList->size();attrNum++){
1521 if((*attrList)[attrNum].specification().name() == "BcidEnergyRangeHigh"){
1522 value = (unsigned short int) (*attrList)[attrNum].data<unsigned short int>();
1523 break;
1524 }
1525 }
1526 return value;
1527 }

◆ BcidEnergyRangeLow()

unsigned short int LVL1::L1CaloOfflineTriggerTowerTools::BcidEnergyRangeLow ( const coral::AttributeList * attrList) const
overridevirtual

Implements LVL1::IL1CaloOfflineTriggerTowerTools.

Definition at line 1507 of file L1CaloOfflineTriggerTowerTools.cxx.

1507 {
1508 unsigned short int value = 0;
1509 for(unsigned int attrNum=0;attrNum<attrList->size();attrNum++){
1510 if((*attrList)[attrNum].specification().name() == "BcidEnergyRangeLow"){
1511 value = (unsigned short int) (*attrList)[attrNum].data<unsigned short int>();
1512 break;
1513 }
1514 }
1515 return value;
1516 }

◆ caloCells()

void LVL1::L1CaloOfflineTriggerTowerTools::caloCells ( const CaloCellContainer * cells)
overridevirtual

Implements LVL1::IL1CaloOfflineTriggerTowerTools.

Definition at line 1740 of file L1CaloOfflineTriggerTowerTools.cxx.

1740 {
1741 m_cells2tt->initCaloCellsTriggerTowers(*cells);
1742 }

◆ DacOffset()

double LVL1::L1CaloOfflineTriggerTowerTools::DacOffset ( const coral::AttributeList * attrList) const
overridevirtual

Implements LVL1::IL1CaloOfflineTriggerTowerTools.

Definition at line 1384 of file L1CaloOfflineTriggerTowerTools.cxx.

1384 {
1385 double value = 0;
1386 for(unsigned int attrNum=0;attrNum<attrList->size();attrNum++){
1387 if((*attrList)[attrNum].specification().name() == "DacOffset"){
1388 value = (double) (*attrList)[attrNum].data<double>();
1389 break;
1390 }
1391 }
1392 return value;
1393 }

◆ DacSlope()

double LVL1::L1CaloOfflineTriggerTowerTools::DacSlope ( const coral::AttributeList * attrList) const
overridevirtual

Implements LVL1::IL1CaloOfflineTriggerTowerTools.

Definition at line 1395 of file L1CaloOfflineTriggerTowerTools.cxx.

1395 {
1396 double value = 0;
1397 for(unsigned int attrNum=0;attrNum<attrList->size();attrNum++){
1398 if((*attrList)[attrNum].specification().name() == "DacSlope"){
1399 value = (double) (*attrList)[attrNum].data<double>();
1400 break;
1401 }
1402 }
1403 return value;
1404 }

◆ DeadChannel()

unsigned int LVL1::L1CaloOfflineTriggerTowerTools::DeadChannel ( const coral::AttributeList * attrList) const
overridevirtual

Implements LVL1::IL1CaloOfflineTriggerTowerTools.

Definition at line 1654 of file L1CaloOfflineTriggerTowerTools.cxx.

1654 {
1655 unsigned int value = 0;
1656 for(unsigned int attrNum=0;attrNum<attrList->size();attrNum++){
1657 if((*attrList)[attrNum].specification().name() == "ErrorCode"){
1658 value = (unsigned int) (*attrList)[attrNum].data<unsigned int>();
1659 break;
1660 }
1661 }
1662 return value;
1663 }

◆ 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.

◆ DisabledTower()

unsigned int LVL1::L1CaloOfflineTriggerTowerTools::DisabledTower ( const coral::AttributeList * attrList) const
overridevirtual

Implements LVL1::IL1CaloOfflineTriggerTowerTools.

Definition at line 1641 of file L1CaloOfflineTriggerTowerTools.cxx.

1641 {
1642 unsigned int value = 0;
1643 for(unsigned int attrNum=0;attrNum<attrList->size();attrNum++){
1644 if((*attrList)[attrNum].specification().name() == "disabledBits"){
1645 value = (unsigned int) (*attrList)[attrNum].data<unsigned int>();
1646 break;
1647 }
1648 }
1649 return value;
1650 }

◆ emCaloQuality()

float LVL1::L1CaloOfflineTriggerTowerTools::emCaloQuality ( const TriggerTower * tt) const
overridevirtual

Implements LVL1::IL1CaloOfflineTriggerTowerTools.

Definition at line 879 of file L1CaloOfflineTriggerTowerTools.cxx.

879 {
880 Identifier Id = this->emID(tt->eta(),tt->phi());
881 std::vector<const CaloCell*> cells = m_cells2tt->caloCells(Id);
882 return this->LArCaloQuality(cells);
883 }
virtual float LArCaloQuality(const std::vector< const CaloCell * > &cells) const override
virtual Identifier emID(const double eta, const double phi) const override

◆ emCells()

std::vector< const CaloCell * > LVL1::L1CaloOfflineTriggerTowerTools::emCells ( const TriggerTower * tt) const
overridevirtual

Implements LVL1::IL1CaloOfflineTriggerTowerTools.

Definition at line 260 of file L1CaloOfflineTriggerTowerTools.cxx.

260 {
261 Identifier Id = this->emID(tt->eta(),tt->phi());
262 return m_cells2tt->caloCells(Id);
263 }

◆ emCoolChannelId()

unsigned int LVL1::L1CaloOfflineTriggerTowerTools::emCoolChannelId ( const TriggerTower * tt) const
overridevirtual

Implements LVL1::IL1CaloOfflineTriggerTowerTools.

Definition at line 71 of file L1CaloOfflineTriggerTowerTools.cxx.

71 {
72 Identifier Id = this->emID(tt->eta(),tt->phi());
73 HWIdentifier HWId = m_ttSvc->createTTChannelID(Id);
74 L1CaloCoolChannelId coolId = m_ttSvc->createL1CoolChannelId(HWId);
75 return coolId.id();
76 }
unsigned int id() const

◆ emDbAttributes()

const coral::AttributeList * LVL1::L1CaloOfflineTriggerTowerTools::emDbAttributes ( const TriggerTower * tt,
const CondAttrListCollection * dbAttrList ) const
overridevirtual

Implements LVL1::IL1CaloOfflineTriggerTowerTools.

Definition at line 1192 of file L1CaloOfflineTriggerTowerTools.cxx.

1192 {
1193 unsigned int coolId = this->emCoolChannelId(tt);
1195 const coral::AttributeList* attrList = 0;
1196 for(Itr_db i=dbAttrList->begin();i!=dbAttrList->end();++i){
1197 if(i->first == coolId){
1198 attrList = &(i->second);
1199 break;
1200 }
1201 }
1202 return attrList;
1203 }
const_iterator end() const
const_iterator begin() const
Access to Chan/AttributeList pairs via iterators.
ChanAttrListMap::const_iterator const_iterator
virtual unsigned int emCoolChannelId(const TriggerTower *tt) const override

◆ emDbRxGainsAttributes()

std::vector< const coral::AttributeList * > LVL1::L1CaloOfflineTriggerTowerTools::emDbRxGainsAttributes ( const TriggerTower * tt,
const CondAttrListCollection * dbAttrList ) const
overridevirtual

Implements LVL1::IL1CaloOfflineTriggerTowerTools.

Definition at line 1206 of file L1CaloOfflineTriggerTowerTools.cxx.

1206 {
1207
1208 std::vector<L1CaloRxCoolChannelId> rx = this->emReceivers(tt);
1209 std::vector<const coral::AttributeList*> v_attr;
1211 typedef std::vector<L1CaloRxCoolChannelId>::const_iterator Itr_Id;
1212
1213 for(Itr_Id a=rx.begin();a!=rx.end();++a){
1214 for(Itr_db i=dbAttrList->begin();i!=dbAttrList->end();++i){
1215 if(i->first == (*a).id()){
1216 v_attr.push_back( &(i->second) );
1217 }
1218 }
1219 }
1220 return v_attr;
1221 }
static Double_t a
virtual std::vector< L1CaloRxCoolChannelId > emReceivers(const TriggerTower *tt) const override

◆ emID()

Identifier LVL1::L1CaloOfflineTriggerTowerTools::emID ( const double eta,
const double phi ) const
overridevirtual

Implements LVL1::IL1CaloOfflineTriggerTowerTools.

Definition at line 1732 of file L1CaloOfflineTriggerTowerTools.cxx.

1732 {
1733 return m_lvl1Helper->tower_id(this->pos_neg_z(eta),0,this->region(eta),this->ieta(eta),this->iphi(eta,phi));
1734 }
Scalar eta() const
pseudorapidity method
Scalar phi() const
phi method
virtual int region(const double eta) const override
virtual int iphi(const double eta, const double phi) const override
virtual int pos_neg_z(const double eta) const override
virtual int ieta(const double eta) const override

◆ emLocation()

std::vector< int > LVL1::L1CaloOfflineTriggerTowerTools::emLocation ( const TriggerTower * tt) const
overridevirtual

Implements LVL1::IL1CaloOfflineTriggerTowerTools.

Definition at line 78 of file L1CaloOfflineTriggerTowerTools.cxx.

78 {
79 std::vector<int> location;
80 Identifier Id = this->emID(tt->eta(),tt->phi());
81 HWIdentifier HWId = m_ttSvc->createTTChannelID(Id);
82 location.push_back(m_ttOnlineIdHelper->crate(HWId));
83 location.push_back(m_ttOnlineIdHelper->module(HWId));
84 location.push_back(m_ttOnlineIdHelper->submodule(HWId));
85 location.push_back(m_ttOnlineIdHelper->channel(HWId));
86 L1CaloCoolChannelId coolId = m_ttSvc->createL1CoolChannelId(HWId);
87 location.push_back(coolId.id());
88 return location;
89 }

◆ emNCells()

int LVL1::L1CaloOfflineTriggerTowerTools::emNCells ( const TriggerTower * tt) const
overridevirtual

Implements LVL1::IL1CaloOfflineTriggerTowerTools.

Definition at line 265 of file L1CaloOfflineTriggerTowerTools.cxx.

265 {
266 Identifier Id = this->emID(tt->eta(),tt->phi());
267 std::vector<const CaloCell*> cells = m_cells2tt->caloCells(Id);
268 return cells.size();
269 }

◆ emNCellsByLayer()

std::vector< int > LVL1::L1CaloOfflineTriggerTowerTools::emNCellsByLayer ( const TriggerTower * tt) const
overridevirtual

Implements LVL1::IL1CaloOfflineTriggerTowerTools.

Definition at line 271 of file L1CaloOfflineTriggerTowerTools.cxx.

271 {
272 Identifier Id = this->emID(tt->eta(),tt->phi());
273 std::vector<int> v;
274 std::vector<std::vector<const CaloCell*> > cells = m_cells2tt->caloCellsByLayer(Id);
275 for(Itr_vvCaloCells i=cells.begin();i!=cells.end();++i){
276 v.push_back((*i).size());
277 }
278 return v;
279 }
std::vector< std::vector< constCaloCell * > >::const_iterator Itr_vvCaloCells

◆ emNCellsByReceiver()

std::vector< int > LVL1::L1CaloOfflineTriggerTowerTools::emNCellsByReceiver ( const TriggerTower * tt) const
overridevirtual

Implements LVL1::IL1CaloOfflineTriggerTowerTools.

Definition at line 281 of file L1CaloOfflineTriggerTowerTools.cxx.

281 {
282 Identifier Id = this->emID(tt->eta(),tt->phi());
283 std::vector<int> v;
284 std::vector<std::vector<const CaloCell*> > cells = this->sortEMCrackCells(m_cells2tt->caloCells(Id));
285 for(Itr_vvCaloCells i=cells.begin();i!=cells.end();++i){
286 v.push_back((*i).size());
287 }
288 return v;
289 }
virtual std::vector< std::vector< const CaloCell * > > sortEMCrackCells(const std::vector< const CaloCell * > &cells) const override

◆ emNCellsByReceiverByLayer()

std::vector< std::vector< int > > LVL1::L1CaloOfflineTriggerTowerTools::emNCellsByReceiverByLayer ( const TriggerTower * tt) const
overridevirtual

Implements LVL1::IL1CaloOfflineTriggerTowerTools.

Definition at line 291 of file L1CaloOfflineTriggerTowerTools.cxx.

291 {
292 Identifier Id = this->emID(tt->eta(),tt->phi());
293 std::vector<L1CaloRxCoolChannelId> rx = this->emReceivers(tt);
294 std::vector<int> v1;
295 std::vector<int> v2;
296 std::vector<std::vector<int> > v;
297 std::vector<std::vector<const CaloCell*> > cells = m_cells2tt->caloCellsByLayer(Id);
298 for(Itr_vvCaloCells i=cells.begin();i!=cells.end();++i){
299 if ((*i).empty()) continue;
300 if (rx.size() == 2) {
301 std::vector<std::vector<const CaloCell*> > cellsRx = this->sortEMCrackCells((*i));
302 for(Itr_vvCaloCells j=cellsRx.begin();j!=cellsRx.end();++j){
303 if ((*j).empty()) continue;
304 if (j == cellsRx.begin()) v1.push_back((*j).size());
305 else v2.push_back((*j).size());
306 }
307 } else if (rx.size() == 1) v1.push_back((*i).size());
308 }
309 v.push_back(std::move(v1));
310 if (rx.size() == 2) v.push_back(std::move(v2));
311 return v;
312 }

◆ emNCellsNonNominal()

float LVL1::L1CaloOfflineTriggerTowerTools::emNCellsNonNominal ( const TriggerTower * tt) const
overridevirtual

Implements LVL1::IL1CaloOfflineTriggerTowerTools.

Definition at line 885 of file L1CaloOfflineTriggerTowerTools.cxx.

885 {
886 if(m_isLArHVCorrToolSet == false){return -9.9;}
887 Identifier Id = this->emID(tt->eta(),tt->phi());
888 std::vector<const CaloCell*> cells = m_cells2tt->caloCells(Id);
889 return this->LArNonNominalHV( cells );
890 }
virtual float LArNonNominalHV(const std::vector< const CaloCell * > &cells) const override

◆ emNCellsNonNominalByLayer()

std::vector< float > LVL1::L1CaloOfflineTriggerTowerTools::emNCellsNonNominalByLayer ( const TriggerTower * tt) const
overridevirtual

Implements LVL1::IL1CaloOfflineTriggerTowerTools.

Definition at line 892 of file L1CaloOfflineTriggerTowerTools.cxx.

892 {
893 std::vector<float> nNonNomHV;
894 if(m_isLArHVCorrToolSet == false){return nNonNomHV;}
895
896 Identifier Id = this->emID(tt->eta(),tt->phi());
897 std::vector<std::vector<const CaloCell*> > cells = m_cells2tt->caloCellsByLayer(Id);
898 for(Itr_vvCaloCells i=cells.begin();i!=cells.end();++i){
899 nNonNomHV.push_back( this->LArNonNominalHV( (*i) ) );
900 }
901 return nNonNomHV;
902 }

◆ emNCellsNonNominalByReceiverByLayer()

std::vector< std::vector< float > > LVL1::L1CaloOfflineTriggerTowerTools::emNCellsNonNominalByReceiverByLayer ( const TriggerTower * tt) const
overridevirtual

Implements LVL1::IL1CaloOfflineTriggerTowerTools.

Definition at line 904 of file L1CaloOfflineTriggerTowerTools.cxx.

904 {
905 std::vector<std::vector<float> > nNonNomHV;
906 if(m_isLArHVCorrToolSet == false){return nNonNomHV;}
907 Identifier Id = this->emID(tt->eta(),tt->phi());
908 std::vector<L1CaloRxCoolChannelId> rx = this->emReceivers(tt);
909 std::vector<float> v1;
910 std::vector<float> v2;
911 std::vector<std::vector<const CaloCell*> > cells = m_cells2tt->caloCellsByLayer(Id);
912 for(Itr_vvCaloCells i=cells.begin();i!=cells.end();++i){
913 if ((*i).empty()) continue;
914 if (rx.size() == 2) {
915 std::vector<std::vector<const CaloCell*> > cellsRx = this->sortEMCrackCells((*i));
916 for(Itr_vvCaloCells j=cellsRx.begin();j!=cellsRx.end();++j){
917 if ((*j).empty()) continue;
918 if (j == cellsRx.begin()) v1.push_back(this->LArNonNominalHV((*j)));
919 else v2.push_back(this->LArNonNominalHV((*j)));
920 }
921 } else if (rx.size() == 1) v1.push_back(this->LArNonNominalHV((*i)));
922 }
923 nNonNomHV.push_back(std::move(v1));
924 if (rx.size() == 2) nNonNomHV.push_back(std::move(v2));
925 return nNonNomHV;
926 }

◆ emNonNominalMeanScale()

float LVL1::L1CaloOfflineTriggerTowerTools::emNonNominalMeanScale ( const TriggerTower * tt) const
overridevirtual

Implements LVL1::IL1CaloOfflineTriggerTowerTools.

Definition at line 928 of file L1CaloOfflineTriggerTowerTools.cxx.

928 {
929 if(m_isLArHVCorrToolSet == false){return -9.9;}
930 Identifier Id = this->emID(tt->eta(),tt->phi());
931 std::vector<const CaloCell*> cells = m_cells2tt->caloCells(Id);
932 return this->LArHVScale( cells );
933 }
virtual float LArHVScale(const std::vector< const CaloCell * > &cells) const override

◆ emNonNominalMeanScaleByLayer()

std::vector< float > LVL1::L1CaloOfflineTriggerTowerTools::emNonNominalMeanScaleByLayer ( const TriggerTower * tt) const
overridevirtual

Implements LVL1::IL1CaloOfflineTriggerTowerTools.

Definition at line 935 of file L1CaloOfflineTriggerTowerTools.cxx.

935 {
936 std::vector<float> NonNomHV;
937 if(m_isLArHVCorrToolSet == false){return NonNomHV;}
938 Identifier Id = this->emID(tt->eta(),tt->phi());
939 std::vector<std::vector<const CaloCell*> > cells = m_cells2tt->caloCellsByLayer(Id);
940 for(Itr_vvCaloCells i=cells.begin();i!=cells.end();++i){
941 NonNomHV.push_back( this->LArHVScale( (*i ) ) );
942 }
943 return NonNomHV;
944 }

◆ emNonNominalMeanScaleByReceiver()

std::vector< float > LVL1::L1CaloOfflineTriggerTowerTools::emNonNominalMeanScaleByReceiver ( const TriggerTower * tt) const
overridevirtual

Implements LVL1::IL1CaloOfflineTriggerTowerTools.

Definition at line 947 of file L1CaloOfflineTriggerTowerTools.cxx.

947 {
948
949 std::vector<float> output;
950 if(m_isLArHVCorrToolSet == false){return output;}
951 std::vector<L1CaloRxCoolChannelId> rx = this->emReceivers(tt);
952 Identifier Id = this->emID(tt->eta(),tt->phi());
953 std::vector<const CaloCell*> cells = m_cells2tt->caloCells(Id);
954
955 if(rx.size() == 2){
956 std::vector<std::vector<const CaloCell*> > vvcells = this->sortEMCrackCells(cells);
957 for(Itr_vvCaloCells i=vvcells.begin();i!=vvcells.end();++i){
958 output.push_back( this->LArHVScale( (*i) ) );
959 }
960 }
961
962 if(rx.size() == 1){
963 output.push_back( this->LArHVScale( cells ) );
964 }
965
966 return output;
967 }
output
Definition merge.py:16

◆ emNonNominalMeanScaleByReceiverByLayer()

std::vector< std::vector< float > > LVL1::L1CaloOfflineTriggerTowerTools::emNonNominalMeanScaleByReceiverByLayer ( const TriggerTower * tt) const
overridevirtual

Implements LVL1::IL1CaloOfflineTriggerTowerTools.

Definition at line 969 of file L1CaloOfflineTriggerTowerTools.cxx.

969 {
970 std::vector<std::vector<float> > output;
971 if(m_isLArHVCorrToolSet == false){return output;}
972 Identifier Id = this->emID(tt->eta(),tt->phi());
973 std::vector<L1CaloRxCoolChannelId> rx = this->emReceivers(tt);
974 std::vector<float> v1;
975 std::vector<float> v2;
976 std::vector<std::vector<const CaloCell*> > cells = m_cells2tt->caloCellsByLayer(Id);
977 for(Itr_vvCaloCells i=cells.begin();i!=cells.end();++i){
978 if ((*i).empty()) continue;
979 if (rx.size() == 2) {
980 std::vector<std::vector<const CaloCell*> > cellsRx = this->sortEMCrackCells((*i));
981 for(Itr_vvCaloCells j=cellsRx.begin();j!=cellsRx.end();++j){
982 if ((*j).empty()) continue;
983 if (j == cellsRx.begin()) v1.push_back(this->LArHVScale((*j)));
984 else v2.push_back(this->LArHVScale((*j)));
985 }
986 } else if (rx.size() == 1) v1.push_back(this->LArHVScale((*i)));
987 }
988 output.push_back(std::move(v1));
989 if (rx.size() == 2) output.push_back(std::move(v2));
990 return output;
991 }

◆ emPpmChannel()

int LVL1::L1CaloOfflineTriggerTowerTools::emPpmChannel ( const TriggerTower * tt) const
overridevirtual

Implements LVL1::IL1CaloOfflineTriggerTowerTools.

Definition at line 65 of file L1CaloOfflineTriggerTowerTools.cxx.

65 {
66 Identifier Id = this->emID(tt->eta(),tt->phi());
67 HWIdentifier HWId = m_ttSvc->createTTChannelID(Id);
68 return m_ttOnlineIdHelper->channel(HWId);
69 }

◆ emPpmCrate()

int LVL1::L1CaloOfflineTriggerTowerTools::emPpmCrate ( const TriggerTower * tt) const
overridevirtual

Implements LVL1::IL1CaloOfflineTriggerTowerTools.

Definition at line 47 of file L1CaloOfflineTriggerTowerTools.cxx.

47 {
48 Identifier Id = this->emID(tt->eta(),tt->phi());
49 HWIdentifier HWId = m_ttSvc->createTTChannelID(Id);
50 return m_ttOnlineIdHelper->crate(HWId);
51 }

◆ emPpmModule()

int LVL1::L1CaloOfflineTriggerTowerTools::emPpmModule ( const TriggerTower * tt) const
overridevirtual

Implements LVL1::IL1CaloOfflineTriggerTowerTools.

Definition at line 53 of file L1CaloOfflineTriggerTowerTools.cxx.

53 {
54 Identifier Id = this->emID(tt->eta(),tt->phi());
55 HWIdentifier HWId = m_ttSvc->createTTChannelID(Id);
56 return m_ttOnlineIdHelper->module(HWId);
57 }

◆ emPpmSubmodule()

int LVL1::L1CaloOfflineTriggerTowerTools::emPpmSubmodule ( const TriggerTower * tt) const
overridevirtual

Implements LVL1::IL1CaloOfflineTriggerTowerTools.

Definition at line 59 of file L1CaloOfflineTriggerTowerTools.cxx.

59 {
60 Identifier Id = this->emID(tt->eta(),tt->phi());
61 HWIdentifier HWId = m_ttSvc->createTTChannelID(Id);
62 return m_ttOnlineIdHelper->submodule(HWId);
63 }

◆ emReceivers()

std::vector< L1CaloRxCoolChannelId > LVL1::L1CaloOfflineTriggerTowerTools::emReceivers ( const TriggerTower * tt) const
overrideprotectedvirtual

Implements LVL1::IL1CaloOfflineTriggerTowerTools.

Definition at line 91 of file L1CaloOfflineTriggerTowerTools.cxx.

91 {
92 Identifier Id = this->emID(tt->eta(),tt->phi());
93 HWIdentifier HWId = m_ttSvc->createTTChannelID(Id);
94 L1CaloCoolChannelId coolId = m_ttSvc->createL1CoolChannelId(HWId);
95 std::vector<L1CaloRxCoolChannelId> rx = m_ttSvc->cnvCoolChannelIdToRxId(coolId);
96
97 std::vector<L1CaloRxCoolChannelId> output;
98
99 // Sort EM Crack recievers. End cap first, barrel second
100 if(rx.size() == 3){
101
102 // For the EM crack region, there are 3 recievers.
103 // 1 Rx have Crate 0 or 1 - correspond to the barrel before the Octopus cable magic - ignore
104 // 2 Rx have Crate 2 or 3 - correspond to the Rx we want:
105 // 1 Rx has inputConn() == 0 - EMEC receiver
106 // 1 Rx has inputConn() == 2 - Barrel receiver
107
108
109 typedef std::vector<L1CaloRxCoolChannelId>::const_iterator Itr_Id;
110 std::vector<L1CaloRxCoolChannelId> rx2;
111 for(Itr_Id a=rx.begin();a!=rx.end();++a){
112 if((*a).crate() == 2 || (*a).crate() == 3){ // Select only interesting recievers
113 rx2.push_back(*a);
114 }
115 }
116
117 if(rx2.size() == 2){
118
119 unsigned int inputA = rx2.at(0).inputConn();
120 unsigned int inputB = rx2.at(1).inputConn();
121
122 // End cap first, barrel second
123 if(inputA == 2 && inputB == 0){
124 output.push_back(rx2.at(1));
125 output.push_back(rx2.at(0));
126 }
127 if(inputA == 0 && inputB == 2){
128 output.push_back(rx2.at(0));
129 output.push_back(rx2.at(1));
130 }
131 }
132
133 }
134
135 if(rx.size() == 1){
136 output.push_back(rx.at(0));
137 }
138
139 return output;
140 }

◆ emRxId()

std::vector< unsigned int > LVL1::L1CaloOfflineTriggerTowerTools::emRxId ( const TriggerTower * tt) const
overridevirtual

Implements LVL1::IL1CaloOfflineTriggerTowerTools.

Definition at line 142 of file L1CaloOfflineTriggerTowerTools.cxx.

142 {
143 typedef std::vector<L1CaloRxCoolChannelId>::const_iterator Itr;
144 std::vector<L1CaloRxCoolChannelId> rx = this->emReceivers(tt);
145 std::vector<unsigned int> output;
146 for(Itr i=rx.begin();i!=rx.end();++i){
147 output.push_back( (*i).id() );
148 }
149 return output;
150 }

◆ emSuperCellIdentifiers()

std::vector< int > LVL1::L1CaloOfflineTriggerTowerTools::emSuperCellIdentifiers ( const TriggerTower * tt) const

Definition at line 1160 of file L1CaloOfflineTriggerTowerTools.cxx.

1160 {
1161 Identifier Id = this->emID(tt->eta(),tt->phi());
1162 std::vector<const CaloCell*> cells = m_cells2tt->caloCells(Id);
1163 return this->SuperCellIdentifiers( cells );
1164 }
std::vector< int > SuperCellIdentifiers(const std::vector< const CaloCell * > &cells) const

◆ emTTCellsEnergy()

float LVL1::L1CaloOfflineTriggerTowerTools::emTTCellsEnergy ( const TriggerTower * tt) const
overridevirtual

Implements LVL1::IL1CaloOfflineTriggerTowerTools.

Definition at line 342 of file L1CaloOfflineTriggerTowerTools.cxx.

342 {
343 Identifier Id = this->emID(tt->eta(),tt->phi());
344 return m_cells2tt->energy( m_cells2tt->caloCells(Id) );
345 }

◆ emTTCellsEnergyByLayer()

std::vector< float > LVL1::L1CaloOfflineTriggerTowerTools::emTTCellsEnergyByLayer ( const TriggerTower * tt) const
overridevirtual

Implements LVL1::IL1CaloOfflineTriggerTowerTools.

Definition at line 347 of file L1CaloOfflineTriggerTowerTools.cxx.

347 {
348 Identifier Id = this->emID(tt->eta(),tt->phi());
349 std::vector<std::vector<const CaloCell*> > cells = m_cells2tt->caloCellsByLayer(Id);
350 std::vector<float> eByLayer;
351 for(Itr_vvCaloCells i=cells.begin();i!=cells.end();++i){
352 eByLayer.push_back( m_cells2tt->energy( *i ) );
353 }
354 return eByLayer;
355 }

◆ emTTCellsEnergyByReceiver()

std::vector< float > LVL1::L1CaloOfflineTriggerTowerTools::emTTCellsEnergyByReceiver ( const TriggerTower * tt,
const int mode = 0 ) const
overridevirtual

Implements LVL1::IL1CaloOfflineTriggerTowerTools.

Definition at line 357 of file L1CaloOfflineTriggerTowerTools.cxx.

357 {
358 // Mode 0 : Return vector<float> even if it has 1 entry. Equivelent to emTTCellsEnergy
359 // Mode 1 : Return vecotr<float> only if size is > 2. D3PDs don't need this
360 std::vector<float> output;
361 std::vector<L1CaloRxCoolChannelId> rx = this->emReceivers(tt);
362 Identifier Id = this->emID(tt->eta(),tt->phi());
363 std::vector<const CaloCell*> cells = m_cells2tt->caloCells(Id);
364
365 if(rx.size() == 2){
366 std::vector<std::vector<const CaloCell*> > vvcells = this->sortEMCrackCells(cells);
367 for(Itr_vvCaloCells i=vvcells.begin();i!=vvcells.end();++i){
368 output.push_back( m_cells2tt->energy( (*i) ) );
369 }
370 }
371
372 if(rx.size() == 1 && mode == 0){
373 output.push_back( m_cells2tt->energy( cells ) );
374 }
375
376 return output;
377 }

◆ emTTCellsEt()

float LVL1::L1CaloOfflineTriggerTowerTools::emTTCellsEt ( const TriggerTower * tt) const
overridevirtual

Implements LVL1::IL1CaloOfflineTriggerTowerTools.

Definition at line 379 of file L1CaloOfflineTriggerTowerTools.cxx.

379 {
380 Identifier Id = this->emID(tt->eta(),tt->phi());
381 return m_cells2tt->et( m_cells2tt->caloCells(Id) );
382 }

◆ emTTCellsEtByLayer()

std::vector< float > LVL1::L1CaloOfflineTriggerTowerTools::emTTCellsEtByLayer ( const TriggerTower * tt) const
overridevirtual

Implements LVL1::IL1CaloOfflineTriggerTowerTools.

Definition at line 384 of file L1CaloOfflineTriggerTowerTools.cxx.

384 {
385 Identifier Id = this->emID(tt->eta(),tt->phi());
386 std::vector<std::vector<const CaloCell*> > cells = m_cells2tt->caloCellsByLayer(Id);
387 std::vector<float> eByLayer;
388 for(Itr_vvCaloCells i=cells.begin();i!=cells.end();++i){
389 eByLayer.push_back( m_cells2tt->et( *i ) );
390 }
391 return eByLayer;
392 }

◆ emTTCellsEtByReceiver()

std::vector< float > LVL1::L1CaloOfflineTriggerTowerTools::emTTCellsEtByReceiver ( const TriggerTower * tt,
const int mode = 0 ) const
overridevirtual

Implements LVL1::IL1CaloOfflineTriggerTowerTools.

Definition at line 394 of file L1CaloOfflineTriggerTowerTools.cxx.

394 {
395 // Mode 0 : Return vector<float> even if it has 1 entry. Equivelent to emTTCellsEt
396 // Mode 1 : Return vecotr<float> only if size is > 2. D3PDs don't need this
397 std::vector<float> output;
398 std::vector<L1CaloRxCoolChannelId> rx = this->emReceivers(tt);
399 Identifier Id = this->emID(tt->eta(),tt->phi());
400 std::vector<const CaloCell*> cells = m_cells2tt->caloCells(Id);
401
402 if(rx.size() == 2){
403 std::vector<std::vector<const CaloCell*> > vvcells = this->sortEMCrackCells(cells);
404 for(Itr_vvCaloCells i=vvcells.begin();i!=vvcells.end();++i){
405 output.push_back( m_cells2tt->et( (*i) ) );
406 }
407 }
408
409 if(rx.size() == 1 && mode == 0){
410 output.push_back( m_cells2tt->et( cells ) );
411 }
412
413 return output;
414 }

◆ emTTCellsLayerNames()

std::vector< int > LVL1::L1CaloOfflineTriggerTowerTools::emTTCellsLayerNames ( const TriggerTower * tt) const
overridevirtual

Implements LVL1::IL1CaloOfflineTriggerTowerTools.

Definition at line 314 of file L1CaloOfflineTriggerTowerTools.cxx.

314 {
315 Identifier Id = this->emID(tt->eta(),tt->phi());
316 return m_cells2tt->layerNames(Id);
317 }

◆ emTTCellsLayerNamesByReceiver()

std::vector< std::vector< int > > LVL1::L1CaloOfflineTriggerTowerTools::emTTCellsLayerNamesByReceiver ( const TriggerTower * tt) const
overridevirtual

Implements LVL1::IL1CaloOfflineTriggerTowerTools.

Definition at line 319 of file L1CaloOfflineTriggerTowerTools.cxx.

319 {
320 Identifier Id = this->emID(tt->eta(),tt->phi());
321 std::vector<L1CaloRxCoolChannelId> rx = this->emReceivers(tt);
322 std::vector<int> v1;
323 std::vector<int> v2;
324 std::vector<std::vector<int> > v;
325 std::vector<std::vector<const CaloCell*> > cells = m_cells2tt->caloCellsByLayer(Id);
326 for(Itr_vvCaloCells i=cells.begin();i!=cells.end();++i){
327 if ((*i).empty()) continue;
328 if (rx.size() == 2) {
329 std::vector<std::vector<const CaloCell*> > cellsRx = this->sortEMCrackCells((*i));
330 for(Itr_vvCaloCells j=cellsRx.begin();j!=cellsRx.end();++j){
331 if ((*j).empty()) continue;
332 if (j == cellsRx.begin()) v1.push_back(m_cells2tt->layerNames((*j)[0]));
333 else v2.push_back(m_cells2tt->layerNames((*j)[0]));
334 }
335 } else if (rx.size() == 1) v1.push_back(m_cells2tt->layerNames((*i)[0]));
336 }
337 v.push_back(std::move(v1));
338 if (rx.size() == 2) v.push_back(std::move(v2));
339 return v;
340 }

◆ ErrorCode()

unsigned int LVL1::L1CaloOfflineTriggerTowerTools::ErrorCode ( const coral::AttributeList * attrList) const
overridevirtual

Implements LVL1::IL1CaloOfflineTriggerTowerTools.

Definition at line 1296 of file L1CaloOfflineTriggerTowerTools.cxx.

1296 {
1297 unsigned int value = 0;
1298 for(unsigned int attrNum=0;attrNum<attrList->size();attrNum++){
1299 if((*attrList)[attrNum].specification().name() == "ErrorCode"){
1300 value = (unsigned int) (*attrList)[attrNum].data<unsigned int>();
1301 break;
1302 }
1303 }
1304 return value;
1305 }

◆ 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.

◆ ExtBcidThreshold()

unsigned short int LVL1::L1CaloOfflineTriggerTowerTools::ExtBcidThreshold ( const coral::AttributeList * attrList) const
overridevirtual

Implements LVL1::IL1CaloOfflineTriggerTowerTools.

Definition at line 1463 of file L1CaloOfflineTriggerTowerTools.cxx.

1463 {
1464 unsigned short int value = 0;
1465 for(unsigned int attrNum=0;attrNum<attrList->size();attrNum++){
1466 if((*attrList)[attrNum].specification().name() == "ExtBcidThreshold"){
1467 value = (unsigned short int) (*attrList)[attrNum].data<unsigned short int>();
1468 break;
1469 }
1470 }
1471 return value;
1472 }

◆ 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

◆ finalize()

StatusCode LVL1::L1CaloOfflineTriggerTowerTools::finalize ( )
overridevirtual

Definition at line 1700 of file L1CaloOfflineTriggerTowerTools.cxx.

1700 {
1701 return StatusCode::SUCCESS;
1702 }

◆ FirCoeff1()

short LVL1::L1CaloOfflineTriggerTowerTools::FirCoeff1 ( const coral::AttributeList * attrList) const
overridevirtual

Implements LVL1::IL1CaloOfflineTriggerTowerTools.

Definition at line 1540 of file L1CaloOfflineTriggerTowerTools.cxx.

1540 {
1541 short value = 0;
1542 for(unsigned int attrNum=0;attrNum<attrList->size();attrNum++){
1543 if((*attrList)[attrNum].specification().name() == "FirCoeff1"){
1544 value = (short) (*attrList)[attrNum].data<short>();
1545 break;
1546 }
1547 }
1548 return value;
1549 }

◆ FirCoeff2()

short LVL1::L1CaloOfflineTriggerTowerTools::FirCoeff2 ( const coral::AttributeList * attrList) const
overridevirtual

Implements LVL1::IL1CaloOfflineTriggerTowerTools.

Definition at line 1551 of file L1CaloOfflineTriggerTowerTools.cxx.

1551 {
1552 short value = 0;
1553 for(unsigned int attrNum=0;attrNum<attrList->size();attrNum++){
1554 if((*attrList)[attrNum].specification().name() == "FirCoeff2"){
1555 value = (short) (*attrList)[attrNum].data<short>();
1556 break;
1557 }
1558 }
1559 return value;
1560 }

◆ FirCoeff3()

short LVL1::L1CaloOfflineTriggerTowerTools::FirCoeff3 ( const coral::AttributeList * attrList) const
overridevirtual

Implements LVL1::IL1CaloOfflineTriggerTowerTools.

Definition at line 1562 of file L1CaloOfflineTriggerTowerTools.cxx.

1562 {
1563 short value = 0;
1564 for(unsigned int attrNum=0;attrNum<attrList->size();attrNum++){
1565 if((*attrList)[attrNum].specification().name() == "FirCoeff3"){
1566 value = (short) (*attrList)[attrNum].data<short>();
1567 break;
1568 }
1569 }
1570 return value;
1571 }

◆ FirCoeff4()

short LVL1::L1CaloOfflineTriggerTowerTools::FirCoeff4 ( const coral::AttributeList * attrList) const
overridevirtual

Implements LVL1::IL1CaloOfflineTriggerTowerTools.

Definition at line 1573 of file L1CaloOfflineTriggerTowerTools.cxx.

1573 {
1574 short value = 0;
1575 for(unsigned int attrNum=0;attrNum<attrList->size();attrNum++){
1576 if((*attrList)[attrNum].specification().name() == "FirCoeff4"){
1577 value = (short) (*attrList)[attrNum].data<short>();
1578 break;
1579 }
1580 }
1581 return value;
1582 }

◆ FirCoeff5()

short LVL1::L1CaloOfflineTriggerTowerTools::FirCoeff5 ( const coral::AttributeList * attrList) const
overridevirtual

Implements LVL1::IL1CaloOfflineTriggerTowerTools.

Definition at line 1584 of file L1CaloOfflineTriggerTowerTools.cxx.

1584 {
1585 short value = 0;
1586 for(unsigned int attrNum=0;attrNum<attrList->size();attrNum++){
1587 if((*attrList)[attrNum].specification().name() == "FirCoeff5"){
1588 value = (short) (*attrList)[attrNum].data<short>();
1589 break;
1590 }
1591 }
1592 return value;
1593 }

◆ FirStartBit()

unsigned short int LVL1::L1CaloOfflineTriggerTowerTools::FirStartBit ( const coral::AttributeList * attrList) const
overridevirtual

Implements LVL1::IL1CaloOfflineTriggerTowerTools.

Definition at line 1529 of file L1CaloOfflineTriggerTowerTools.cxx.

1529 {
1530 unsigned short int value = 0;
1531 for(unsigned int attrNum=0;attrNum<attrList->size();attrNum++){
1532 if((*attrList)[attrNum].specification().name() == "FirStartBit"){
1533 value = (unsigned short int) (*attrList)[attrNum].data<unsigned short int>();
1534 break;
1535 }
1536 }
1537 return value;
1538 }

◆ FullDelayData()

unsigned int LVL1::L1CaloOfflineTriggerTowerTools::FullDelayData ( const coral::AttributeList * attrList) const
overridevirtual

Implements LVL1::IL1CaloOfflineTriggerTowerTools.

Definition at line 1428 of file L1CaloOfflineTriggerTowerTools.cxx.

1428 {
1429 unsigned int value = 0;
1430 for(unsigned int attrNum=0;attrNum<attrList->size();attrNum++){
1431 if((*attrList)[attrNum].specification().name() == "FullDelayData"){
1432 value = (unsigned int) (*attrList)[attrNum].data<unsigned int>();
1433 break;
1434 }
1435 }
1436 return value;
1437 }

◆ getKey()

SG::sgkey_t asg::AsgTool::getKey ( const void * ptr) const
inherited

Get the (hashed) key of an object that is in the event store.

This is a bit of a special one. StoreGateSvc and xAOD::TEvent both provide ways for getting the SG::sgkey_t key for an object that is in the store, based on a bare pointer. But they provide different interfaces for doing so.

In order to allow tools to efficiently perform this operation, they can use this helper function.

See also
asg::AsgTool::getName
Parameters
ptrThe bare pointer to the object that the event store should know about
Returns
The hashed key of the object in the store. If not found, an invalid (zero) key.

Definition at line 119 of file AsgTool.cxx.

119 {
120
121#ifdef XAOD_STANDALONE
122 // In case we use @c xAOD::TEvent, we have a direct function call
123 // for this.
124 return evtStore()->event()->getKey( ptr );
125#else
126 const SG::DataProxy* proxy = evtStore()->proxy( ptr );
127 return ( proxy == nullptr ? 0 : proxy->sgkey() );
128#endif // XAOD_STANDALONE
129 }
ServiceHandle< StoreGateSvc > & evtStore()

◆ getName()

const std::string & asg::AsgTool::getName ( const void * ptr) const
inherited

Get the name of an object that is / should be in the event store.

This is a bit of a special one. StoreGateSvc and xAOD::TEvent both provide ways for getting the std::string name for an object that is in the store, based on a bare pointer. But they provide different interfaces for doing so.

In order to allow tools to efficiently perform this operation, they can use this helper function.

See also
asg::AsgTool::getKey
Parameters
ptrThe bare pointer to the object that the event store should know about
Returns
The string name of the object in the store. If not found, an empty string.

Definition at line 106 of file AsgTool.cxx.

106 {
107
108#ifdef XAOD_STANDALONE
109 // In case we use @c xAOD::TEvent, we have a direct function call
110 // for this.
111 return evtStore()->event()->getName( ptr );
112#else
113 const SG::DataProxy* proxy = evtStore()->proxy( ptr );
114 static const std::string dummy = "";
115 return ( proxy == nullptr ? dummy : proxy->name() );
116#endif // XAOD_STANDALONE
117 }

◆ getProperty()

template<class T>
const T * asg::AsgTool::getProperty ( const std::string & name) const
inherited

Get one of the tool's properties.

◆ hadCaloQuality()

float LVL1::L1CaloOfflineTriggerTowerTools::hadCaloQuality ( const TriggerTower * tt) const
overridevirtual

Implements LVL1::IL1CaloOfflineTriggerTowerTools.

Definition at line 996 of file L1CaloOfflineTriggerTowerTools.cxx.

996 {
997 Identifier Id = this->hadID(tt->eta(),tt->phi());
998 std::vector<const CaloCell*> cells = m_cells2tt->caloCells(Id);
999 bool isTile = m_lvl1Helper->is_tile(Id);
1000
1001 if(isTile == true){return this->TileCaloQuality(cells);}
1002 if(isTile == false){return this->LArCaloQuality(cells);}
1003 return -9.9;
1004 }
virtual Identifier hadID(const double eta, const double phi) const override
virtual float TileCaloQuality(const std::vector< const CaloCell * > &cells) const override

◆ hadCells()

std::vector< const CaloCell * > LVL1::L1CaloOfflineTriggerTowerTools::hadCells ( const TriggerTower * tt) const
overridevirtual

Implements LVL1::IL1CaloOfflineTriggerTowerTools.

Definition at line 442 of file L1CaloOfflineTriggerTowerTools.cxx.

442 {
443 Identifier Id = this->hadID(tt->eta(),tt->phi());
444 return m_cells2tt->caloCells(Id);
445 }

◆ hadCoolChannelId()

unsigned int LVL1::L1CaloOfflineTriggerTowerTools::hadCoolChannelId ( const TriggerTower * tt) const
overridevirtual

Implements LVL1::IL1CaloOfflineTriggerTowerTools.

Definition at line 178 of file L1CaloOfflineTriggerTowerTools.cxx.

178 {
179 Identifier Id = this->hadID(tt->eta(),tt->phi());
180 HWIdentifier HWId = m_ttSvc->createTTChannelID(Id);
181 L1CaloCoolChannelId coolId = m_ttSvc->createL1CoolChannelId(HWId);
182 return coolId.id();
183 }

◆ hadDbAttributes()

const coral::AttributeList * LVL1::L1CaloOfflineTriggerTowerTools::hadDbAttributes ( const TriggerTower * tt,
const CondAttrListCollection * dbAttrList ) const
overridevirtual

Implements LVL1::IL1CaloOfflineTriggerTowerTools.

Definition at line 1225 of file L1CaloOfflineTriggerTowerTools.cxx.

1225 {
1226 unsigned int coolId = this->hadCoolChannelId(tt);
1228 const coral::AttributeList* attrList = 0;
1229 for(Itr_db i=dbAttrList->begin();i!=dbAttrList->end();++i){
1230 if(i->first == coolId){
1231 attrList = &(i->second);
1232 break;
1233 }
1234 }
1235 return attrList;
1236 }
virtual unsigned int hadCoolChannelId(const TriggerTower *tt) const override

◆ hadDbRxGainsAttributes()

std::vector< const coral::AttributeList * > LVL1::L1CaloOfflineTriggerTowerTools::hadDbRxGainsAttributes ( const TriggerTower * tt,
const CondAttrListCollection * dbAttrList ) const
overridevirtual

Implements LVL1::IL1CaloOfflineTriggerTowerTools.

Definition at line 1238 of file L1CaloOfflineTriggerTowerTools.cxx.

1238 {
1239
1240 std::vector<L1CaloRxCoolChannelId> rx = this->hadReceivers(tt);
1241 std::vector<const coral::AttributeList*> v_attr;
1243 typedef std::vector<L1CaloRxCoolChannelId>::const_iterator Itr_Id;
1244
1245 for(Itr_Id a=rx.begin();a!=rx.end();++a){
1246 for(Itr_db i=dbAttrList->begin();i!=dbAttrList->end();++i){
1247 if(i->first == (*a).id()){
1248 v_attr.push_back( &(i->second) );
1249 }
1250 }
1251 }
1252 return v_attr;
1253 }
virtual std::vector< L1CaloRxCoolChannelId > hadReceivers(const TriggerTower *tt) const override

◆ hadID()

Identifier LVL1::L1CaloOfflineTriggerTowerTools::hadID ( const double eta,
const double phi ) const
overridevirtual

Implements LVL1::IL1CaloOfflineTriggerTowerTools.

Definition at line 1736 of file L1CaloOfflineTriggerTowerTools.cxx.

1736 {
1737 return m_lvl1Helper->tower_id(this->pos_neg_z(eta),1,this->region(eta),this->ieta(eta),this->iphi(eta,phi));
1738 }

◆ hadIsTile()

int LVL1::L1CaloOfflineTriggerTowerTools::hadIsTile ( const TriggerTower * tt) const
overridevirtual

Implements LVL1::IL1CaloOfflineTriggerTowerTools.

Definition at line 198 of file L1CaloOfflineTriggerTowerTools.cxx.

198 {
199 Identifier Id = this->hadID(tt->eta(),tt->phi());
200 if(m_lvl1Helper->is_tile(Id) == true){
201 return 1;
202 }
203 return 0;
204 }

◆ hadLocation()

std::vector< int > LVL1::L1CaloOfflineTriggerTowerTools::hadLocation ( const TriggerTower * tt) const
overridevirtual

Implements LVL1::IL1CaloOfflineTriggerTowerTools.

Definition at line 185 of file L1CaloOfflineTriggerTowerTools.cxx.

185 {
186 std::vector<int> location;
187 Identifier Id = this->hadID(tt->eta(),tt->phi());
188 HWIdentifier HWId = m_ttSvc->createTTChannelID(Id);
189 location.push_back(m_ttOnlineIdHelper->crate(HWId));
190 location.push_back(m_ttOnlineIdHelper->module(HWId));
191 location.push_back(m_ttOnlineIdHelper->submodule(HWId));
192 location.push_back(m_ttOnlineIdHelper->channel(HWId));
193 L1CaloCoolChannelId coolId = m_ttSvc->createL1CoolChannelId(HWId);
194 location.push_back(coolId.id());
195 return location;
196 }

◆ hadNCells()

int LVL1::L1CaloOfflineTriggerTowerTools::hadNCells ( const TriggerTower * tt) const
overridevirtual

Implements LVL1::IL1CaloOfflineTriggerTowerTools.

Definition at line 447 of file L1CaloOfflineTriggerTowerTools.cxx.

447 {
448 Identifier Id = this->hadID(tt->eta(),tt->phi());
449 std::vector<const CaloCell*> cells = m_cells2tt->caloCells(Id);
450 return cells.size();
451 }

◆ hadNCellsByLayer()

std::vector< int > LVL1::L1CaloOfflineTriggerTowerTools::hadNCellsByLayer ( const TriggerTower * tt) const
overridevirtual

Implements LVL1::IL1CaloOfflineTriggerTowerTools.

Definition at line 453 of file L1CaloOfflineTriggerTowerTools.cxx.

453 {
454 Identifier Id = this->hadID(tt->eta(),tt->phi());
455 std::vector<int> v;
456 std::vector<std::vector<const CaloCell*> > cells = m_cells2tt->caloCellsByLayer(Id);
457 for(Itr_vvCaloCells i=cells.begin();i!=cells.end();++i){
458 v.push_back((*i).size());
459 }
460 return v;
461 }

◆ hadNCellsByReceiver()

std::vector< int > LVL1::L1CaloOfflineTriggerTowerTools::hadNCellsByReceiver ( const TriggerTower * tt) const
overridevirtual

Implements LVL1::IL1CaloOfflineTriggerTowerTools.

Definition at line 463 of file L1CaloOfflineTriggerTowerTools.cxx.

463 {
464 std::vector<unsigned int> rx = this->hadRxId(tt);
465 Identifier Id = this->hadID(tt->eta(),tt->phi());
466
467 std::vector<int> v;
468 std::vector<std::vector<const CaloCell*> > cells = this->sortFCAL23Cells(m_cells2tt->caloCells(Id),rx);
469 for(Itr_vvCaloCells i=cells.begin();i!=cells.end();++i){
470 v.push_back((*i).size());
471 }
472 return v;
473 }
virtual std::vector< unsigned int > hadRxId(const TriggerTower *tt) const override
virtual std::vector< std::vector< const CaloCell * > > sortFCAL23Cells(const std::vector< const CaloCell * > &cells, const double eta) const override

◆ hadNCellsByReceiverByLayer()

std::vector< std::vector< int > > LVL1::L1CaloOfflineTriggerTowerTools::hadNCellsByReceiverByLayer ( const TriggerTower * tt) const
overridevirtual

Implements LVL1::IL1CaloOfflineTriggerTowerTools.

Definition at line 475 of file L1CaloOfflineTriggerTowerTools.cxx.

475 {
476 Identifier Id = this->hadID(tt->eta(),tt->phi());
477 std::vector<unsigned int> rx = this->hadRxId(tt);
478 std::vector<int> v1;
479 std::vector<int> v2;
480 std::vector<std::vector<int> > v;
481 std::vector<std::vector<const CaloCell*> > cells = m_cells2tt->caloCellsByLayer(Id);
482 for(Itr_vvCaloCells i=cells.begin();i!=cells.end();++i){
483 if ((*i).empty()) continue;
484 if (rx.size() == 2) {
485 std::vector<std::vector<const CaloCell*> > cellsRx = this->sortFCAL23Cells((*i),rx);
486 for(Itr_vvCaloCells j=cellsRx.begin();j!=cellsRx.end();++j){
487 if ((*j).empty()) continue;
488 if (j == cellsRx.begin()) v1.push_back((*j).size());
489 else v2.push_back((*j).size());
490 }
491 } else if (rx.size() == 1) v1.push_back((*i).size());
492 }
493 v.push_back(std::move(v1));
494 if (rx.size() == 2) v.push_back(std::move(v2));
495 return v;
496 }

◆ hadNCellsNonNominal()

float LVL1::L1CaloOfflineTriggerTowerTools::hadNCellsNonNominal ( const TriggerTower * tt) const
overridevirtual

Implements LVL1::IL1CaloOfflineTriggerTowerTools.

Definition at line 1007 of file L1CaloOfflineTriggerTowerTools.cxx.

1007 {
1008 Identifier Id = this->hadID(tt->eta(),tt->phi());
1009 bool isTile = m_lvl1Helper->is_tile(Id);
1010 std::vector<const CaloCell*> cells = m_cells2tt->caloCells(Id);
1011
1012 if(isTile == false && m_isLArHVCorrToolSet == false){return -9.9;}
1013
1014 if(isTile == false && m_isLArHVCorrToolSet == true){
1015 return this->LArNonNominalHV( cells );
1016 }
1017
1018 if(isTile == true){
1019 return this->TileNonNominal( cells );
1020 }
1021 return -9.9;
1022 }
virtual float TileNonNominal(const std::vector< const CaloCell * > &cells) const override

◆ hadNCellsNonNominalByLayer()

std::vector< float > LVL1::L1CaloOfflineTriggerTowerTools::hadNCellsNonNominalByLayer ( const TriggerTower * tt) const
overridevirtual

Implements LVL1::IL1CaloOfflineTriggerTowerTools.

Definition at line 1025 of file L1CaloOfflineTriggerTowerTools.cxx.

1025 {
1026 std::vector<float> nNonNomHV;
1027 Identifier Id = this->hadID(tt->eta(),tt->phi());
1028 bool isTile = m_lvl1Helper->is_tile(Id);
1029 std::vector<std::vector<const CaloCell*> > cells = m_cells2tt->caloCellsByLayer(Id);
1030 if(isTile == false && m_isLArHVCorrToolSet == false){return nNonNomHV;}
1031 if(isTile == false && m_isLArHVCorrToolSet == true){
1032 for(Itr_vvCaloCells i=cells.begin();i!=cells.end();++i){
1033 nNonNomHV.push_back( this->LArNonNominalHV( (*i) ) );
1034 }
1035 }
1036
1037 if(isTile == true){
1038 for(Itr_vvCaloCells i=cells.begin();i!=cells.end();++i){
1039 nNonNomHV.push_back( this->TileNonNominal( (*i) ) );
1040 }
1041 }
1042
1043 return nNonNomHV;
1044
1045 }

◆ hadNCellsNonNominalByReceiverByLayer()

std::vector< std::vector< float > > LVL1::L1CaloOfflineTriggerTowerTools::hadNCellsNonNominalByReceiverByLayer ( const TriggerTower * tt) const
overridevirtual

Implements LVL1::IL1CaloOfflineTriggerTowerTools.

Definition at line 1047 of file L1CaloOfflineTriggerTowerTools.cxx.

1047 {
1048 std::vector<std::vector<float> > nNonNomHV;
1049 Identifier Id = this->hadID(tt->eta(),tt->phi());
1050 bool isTile = m_lvl1Helper->is_tile(Id);
1051 if(isTile == false && m_isLArHVCorrToolSet == false){return nNonNomHV;}
1052 std::vector<unsigned int> rx = this->hadRxId(tt);
1053 std::vector<float> v1;
1054 std::vector<float> v2;
1055 std::vector<std::vector<const CaloCell*> > cells = m_cells2tt->caloCellsByLayer(Id);
1056 for(Itr_vvCaloCells i=cells.begin();i!=cells.end();++i){
1057 if ((*i).empty()) continue;
1058 if (rx.size() == 2) {
1059 std::vector<std::vector<const CaloCell*> > cellsRx = this->sortFCAL23Cells((*i),rx);
1060 for(Itr_vvCaloCells j=cellsRx.begin();j!=cellsRx.end();++j){
1061 if ((*j).empty()) continue;
1062 if (j == cellsRx.begin()) v1.push_back( (isTile == false) ? this->LArNonNominalHV((*j))
1063 : this->TileNonNominal((*j)));
1064 else v2.push_back( (isTile == false) ? this->LArNonNominalHV((*j))
1065 : this->TileNonNominal((*j)));
1066 }
1067 } else if (rx.size() == 1) v1.push_back( (isTile == false) ? this->LArNonNominalHV((*i))
1068 : this->TileNonNominal((*i)));
1069 }
1070 nNonNomHV.push_back(std::move(v1));
1071 if (rx.size() == 2) nNonNomHV.push_back(std::move(v2));
1072 return nNonNomHV;
1073 }

◆ hadNonNominalMeanScale()

float LVL1::L1CaloOfflineTriggerTowerTools::hadNonNominalMeanScale ( const TriggerTower * tt) const
overridevirtual

Implements LVL1::IL1CaloOfflineTriggerTowerTools.

Definition at line 1075 of file L1CaloOfflineTriggerTowerTools.cxx.

1075 {
1076
1077 Identifier Id = this->hadID(tt->eta(),tt->phi());
1078 bool isTile = m_lvl1Helper->is_tile(Id);
1079 if(isTile == true){return -9.9;}
1080
1081 if(m_isLArHVCorrToolSet == false){return -9.9;}
1082 std::vector<const CaloCell*> cells = m_cells2tt->caloCells(Id);
1083 return this->LArHVScale( cells );
1084
1085 }

◆ hadNonNominalMeanScaleByLayer()

std::vector< float > LVL1::L1CaloOfflineTriggerTowerTools::hadNonNominalMeanScaleByLayer ( const TriggerTower * tt) const
overridevirtual

Implements LVL1::IL1CaloOfflineTriggerTowerTools.

Definition at line 1087 of file L1CaloOfflineTriggerTowerTools.cxx.

1087 {
1088 std::vector<float> NonNomHV;
1089 Identifier Id = this->hadID(tt->eta(),tt->phi());
1090 bool isTile = m_lvl1Helper->is_tile(Id);
1091 if(isTile == true){return NonNomHV;}
1092
1093 if(m_isLArHVCorrToolSet == false){return NonNomHV;}
1094 std::vector<std::vector<const CaloCell*> > cells = m_cells2tt->caloCellsByLayer(Id);
1095
1096 for(Itr_vvCaloCells i=cells.begin();i!=cells.end();++i){
1097 NonNomHV.push_back( this->LArHVScale( (*i ) ) );
1098 }
1099 return NonNomHV;
1100 }

◆ hadNonNominalMeanScaleByReceiver()

std::vector< float > LVL1::L1CaloOfflineTriggerTowerTools::hadNonNominalMeanScaleByReceiver ( const TriggerTower * tt) const
overridevirtual

Implements LVL1::IL1CaloOfflineTriggerTowerTools.

Definition at line 1102 of file L1CaloOfflineTriggerTowerTools.cxx.

1102 {
1103
1104 std::vector<float> output;
1105 if(m_isLArHVCorrToolSet == false){return output;}
1106 std::vector<unsigned int> rx = this->hadRxId(tt);
1107 Identifier Id = this->hadID(tt->eta(),tt->phi());
1108
1109 bool isTile = m_lvl1Helper->is_tile(Id);
1110 if(isTile == true){return output;}
1111
1112 std::vector<const CaloCell*> cells = m_cells2tt->caloCells(Id);
1113
1114 if(rx.size() == 2){
1115 std::vector<std::vector<const CaloCell*> > vvcells = this->sortFCAL23Cells(cells,rx);
1116 for(Itr_vvCaloCells i=vvcells.begin();i!=vvcells.end();++i){
1117 output.push_back( this->LArHVScale( (*i) ) );
1118 }
1119 }
1120
1121 if(rx.size() == 1){
1122 output.push_back( this->LArHVScale( cells ) );
1123 }
1124
1125 return output;
1126
1127 }

◆ hadNonNominalMeanScaleByReceiverByLayer()

std::vector< std::vector< float > > LVL1::L1CaloOfflineTriggerTowerTools::hadNonNominalMeanScaleByReceiverByLayer ( const TriggerTower * tt) const
overridevirtual

Implements LVL1::IL1CaloOfflineTriggerTowerTools.

Definition at line 1129 of file L1CaloOfflineTriggerTowerTools.cxx.

1129 {
1130 std::vector<std::vector<float> > output;
1131 Identifier Id = this->hadID(tt->eta(),tt->phi());
1132 bool isTile = m_lvl1Helper->is_tile(Id);
1133 if(isTile == true || m_isLArHVCorrToolSet == false){return output;}
1134 std::vector<unsigned int> rx = this->hadRxId(tt);
1135 std::vector<float> v1;
1136 std::vector<float> v2;
1137 std::vector<std::vector<const CaloCell*> > cells = m_cells2tt->caloCellsByLayer(Id);
1138 for(Itr_vvCaloCells i=cells.begin();i!=cells.end();++i){
1139 if ((*i).empty()) continue;
1140 if (rx.size() == 2) {
1141 std::vector<std::vector<const CaloCell*> > cellsRx = this->sortFCAL23Cells((*i),rx);
1142 for(Itr_vvCaloCells j=cellsRx.begin();j!=cellsRx.end();++j){
1143 if ((*j).empty()) continue;
1144 if (j == cellsRx.begin()) v1.push_back(this->LArHVScale((*j)));
1145 else v2.push_back(this->LArHVScale((*j)));
1146 }
1147 } else if (rx.size() == 1) v1.push_back(this->LArHVScale((*i)));
1148 }
1149 output.push_back(std::move(v1));
1150 if (rx.size() == 2) output.push_back(std::move(v2));
1151 return output;
1152 }

◆ hadPpmChannel()

int LVL1::L1CaloOfflineTriggerTowerTools::hadPpmChannel ( const TriggerTower * tt) const
overridevirtual

Implements LVL1::IL1CaloOfflineTriggerTowerTools.

Definition at line 172 of file L1CaloOfflineTriggerTowerTools.cxx.

172 {
173 Identifier Id = this->hadID(tt->eta(),tt->phi());
174 HWIdentifier HWId = m_ttSvc->createTTChannelID(Id);
175 return m_ttOnlineIdHelper->channel(HWId);
176 }

◆ hadPpmCrate()

int LVL1::L1CaloOfflineTriggerTowerTools::hadPpmCrate ( const TriggerTower * tt) const
overridevirtual

Implements LVL1::IL1CaloOfflineTriggerTowerTools.

Definition at line 154 of file L1CaloOfflineTriggerTowerTools.cxx.

154 {
155 Identifier Id = this->hadID(tt->eta(),tt->phi());
156 HWIdentifier HWId = m_ttSvc->createTTChannelID(Id);
157 return m_ttOnlineIdHelper->crate(HWId);
158 }

◆ hadPpmModule()

int LVL1::L1CaloOfflineTriggerTowerTools::hadPpmModule ( const TriggerTower * tt) const
overridevirtual

Implements LVL1::IL1CaloOfflineTriggerTowerTools.

Definition at line 160 of file L1CaloOfflineTriggerTowerTools.cxx.

160 {
161 Identifier Id = this->hadID(tt->eta(),tt->phi());
162 HWIdentifier HWId = m_ttSvc->createTTChannelID(Id);
163 return m_ttOnlineIdHelper->module(HWId);
164 }

◆ hadPpmSubmodule()

int LVL1::L1CaloOfflineTriggerTowerTools::hadPpmSubmodule ( const TriggerTower * tt) const
overridevirtual

Implements LVL1::IL1CaloOfflineTriggerTowerTools.

Definition at line 166 of file L1CaloOfflineTriggerTowerTools.cxx.

166 {
167 Identifier Id = this->hadID(tt->eta(),tt->phi());
168 HWIdentifier HWId = m_ttSvc->createTTChannelID(Id);
169 return m_ttOnlineIdHelper->submodule(HWId);
170 }

◆ hadReceivers()

std::vector< L1CaloRxCoolChannelId > LVL1::L1CaloOfflineTriggerTowerTools::hadReceivers ( const TriggerTower * tt) const
overrideprotectedvirtual

Implements LVL1::IL1CaloOfflineTriggerTowerTools.

Definition at line 206 of file L1CaloOfflineTriggerTowerTools.cxx.

206 {
207 Identifier Id = this->hadID(tt->eta(),tt->phi());
208 HWIdentifier HWId = m_ttSvc->createTTChannelID(Id);
209 L1CaloCoolChannelId coolId = m_ttSvc->createL1CoolChannelId(HWId);
210 std::vector<L1CaloRxCoolChannelId> rx = m_ttSvc->cnvCoolChannelIdToRxId(coolId);
211
212 std::vector<L1CaloRxCoolChannelId> output;
213
214 // Sort FCAL 23 recievers. Always have -ve eta first and +ve eta second
215 if(rx.size() == 2){
216
217 // Odd receiver is lowest |eta|
218 unsigned int inputPairA = rx.at(0).inputPair();
219 unsigned int inputPairB = rx.at(1).inputPair();
220
221 bool oddA(false),oddB(false);
222 if(inputPairA % 2 != 0){oddA = true;}
223 if(inputPairB % 2 != 0){oddB = true;}
224
225 if(oddA == true && oddB == false){
226 output.push_back(rx.at(0));
227 output.push_back(rx.at(1));
228 }
229 if(oddA == false && oddB == true){
230 output.push_back(rx.at(1));
231 output.push_back(rx.at(0));
232 }
233
234 }
235 if(rx.size() == 1){
236 output.push_back(rx.at(0));
237 }
238
239 return output;
240 }

◆ hadRxId()

std::vector< unsigned int > LVL1::L1CaloOfflineTriggerTowerTools::hadRxId ( const TriggerTower * tt) const
overridevirtual

Implements LVL1::IL1CaloOfflineTriggerTowerTools.

Definition at line 243 of file L1CaloOfflineTriggerTowerTools.cxx.

243 {
244 typedef std::vector<L1CaloRxCoolChannelId>::const_iterator Itr;
245 std::vector<L1CaloRxCoolChannelId> rx = this->hadReceivers(tt);
246 std::vector<unsigned int> output;
247 for(Itr i=rx.begin();i!=rx.end();++i){
248 output.push_back( (*i).id() );
249 }
250 return output;
251 }

◆ hadSuperCellIdentifiers()

std::vector< int > LVL1::L1CaloOfflineTriggerTowerTools::hadSuperCellIdentifiers ( const TriggerTower * tt) const

Definition at line 1166 of file L1CaloOfflineTriggerTowerTools.cxx.

1166 {
1167 Identifier Id = this->hadID(tt->eta(),tt->phi());
1168 std::vector<const CaloCell*> cells = m_cells2tt->caloCells(Id);
1169 return this->SuperCellIdentifiers( cells );
1170 }

◆ hadTTCellsEnergy()

float LVL1::L1CaloOfflineTriggerTowerTools::hadTTCellsEnergy ( const TriggerTower * tt) const
overridevirtual

Implements LVL1::IL1CaloOfflineTriggerTowerTools.

Definition at line 526 of file L1CaloOfflineTriggerTowerTools.cxx.

526 {
527 Identifier Id = this->hadID(tt->eta(),tt->phi());
528 return m_cells2tt->energy( m_cells2tt->caloCells(Id) );
529 }

◆ hadTTCellsEnergyByLayer()

std::vector< float > LVL1::L1CaloOfflineTriggerTowerTools::hadTTCellsEnergyByLayer ( const TriggerTower * tt) const
overridevirtual

Implements LVL1::IL1CaloOfflineTriggerTowerTools.

Definition at line 531 of file L1CaloOfflineTriggerTowerTools.cxx.

531 {
532 Identifier Id = this->hadID(tt->eta(),tt->phi());
533 std::vector<std::vector<const CaloCell*> > cells = m_cells2tt->caloCellsByLayer(Id);
534 std::vector<float> eByLayer;
535 for(Itr_vvCaloCells i=cells.begin();i!=cells.end();++i){
536 eByLayer.push_back( m_cells2tt->energy( *i ) );
537 }
538 return eByLayer;
539 }

◆ hadTTCellsEnergyByReceiver()

std::vector< float > LVL1::L1CaloOfflineTriggerTowerTools::hadTTCellsEnergyByReceiver ( const TriggerTower * tt,
const int mode = 0 ) const
overridevirtual

Implements LVL1::IL1CaloOfflineTriggerTowerTools.

Definition at line 541 of file L1CaloOfflineTriggerTowerTools.cxx.

541 {
542 // Mode 0 : Return vector<float> even if it has 1 entry. Equivelent to hadTTCellsEnergy
543 // Mode 1 : Return vecotr<float> only if size is > 2. D3PDs don't need this
544 std::vector<float> output;
545 std::vector<unsigned int> rx = this->hadRxId(tt);
546 Identifier Id = this->hadID(tt->eta(),tt->phi());
547 std::vector<const CaloCell*> cells = m_cells2tt->caloCells(Id);
548
549 if(rx.size() == 2){
550 std::vector<std::vector<const CaloCell*> > vvcells = this->sortFCAL23Cells(cells,rx);
551 for(Itr_vvCaloCells i=vvcells.begin();i!=vvcells.end();++i){
552 output.push_back( m_cells2tt->energy( (*i) ) );
553 }
554 }
555
556 if(rx.size() == 1 && mode == 0){
557 output.push_back( m_cells2tt->energy( cells ) );
558 }
559
560 return output;
561 }

◆ hadTTCellsEt()

float LVL1::L1CaloOfflineTriggerTowerTools::hadTTCellsEt ( const TriggerTower * tt) const
overridevirtual

Implements LVL1::IL1CaloOfflineTriggerTowerTools.

Definition at line 563 of file L1CaloOfflineTriggerTowerTools.cxx.

563 {
564 Identifier Id = this->hadID(tt->eta(),tt->phi());
565 return m_cells2tt->et( m_cells2tt->caloCells(Id) );
566 }

◆ hadTTCellsEtByLayer()

std::vector< float > LVL1::L1CaloOfflineTriggerTowerTools::hadTTCellsEtByLayer ( const TriggerTower * tt) const
overridevirtual

Implements LVL1::IL1CaloOfflineTriggerTowerTools.

Definition at line 568 of file L1CaloOfflineTriggerTowerTools.cxx.

568 {
569 Identifier Id = this->hadID(tt->eta(),tt->phi());
570 std::vector<std::vector<const CaloCell*> > cells = m_cells2tt->caloCellsByLayer(Id);
571 std::vector<float> eByLayer;
572 for(Itr_vvCaloCells i=cells.begin();i!=cells.end();++i){
573 eByLayer.push_back( m_cells2tt->et( *i ) );
574 }
575 return eByLayer;
576 }

◆ hadTTCellsEtByReceiver()

std::vector< float > LVL1::L1CaloOfflineTriggerTowerTools::hadTTCellsEtByReceiver ( const TriggerTower * tt,
const int mode = 0 ) const
overridevirtual

Implements LVL1::IL1CaloOfflineTriggerTowerTools.

Definition at line 579 of file L1CaloOfflineTriggerTowerTools.cxx.

579 {
580 // Mode 0 : Return vector<float> even if it has 1 entry. Equivelent to hadTTCellsEt
581 // Mode 1 : Return vecotr<float> only if size is > 2. D3PDs don't need this
582 std::vector<float> output;
583 std::vector<unsigned int> rx = this->hadRxId(tt);
584 Identifier Id = this->hadID(tt->eta(),tt->phi());
585 std::vector<const CaloCell*> cells = m_cells2tt->caloCells(Id);
586
587 if(rx.size() == 2){
588 std::vector<std::vector<const CaloCell*> > vvcells = this->sortFCAL23Cells(cells,rx);
589 for(Itr_vvCaloCells i=vvcells.begin();i!=vvcells.end();++i){
590 output.push_back( m_cells2tt->et( (*i) ) );
591 }
592 }
593
594 if(rx.size() == 1 && mode == 0){
595 output.push_back( m_cells2tt->et( cells ) );
596 }
597
598 return output;
599 }

◆ hadTTCellsLayerNames()

std::vector< int > LVL1::L1CaloOfflineTriggerTowerTools::hadTTCellsLayerNames ( const TriggerTower * tt) const
overridevirtual

Implements LVL1::IL1CaloOfflineTriggerTowerTools.

Definition at line 498 of file L1CaloOfflineTriggerTowerTools.cxx.

498 {
499 Identifier Id = this->hadID(tt->eta(),tt->phi());
500 return m_cells2tt->layerNames(Id);
501 }

◆ hadTTCellsLayerNamesByReceiver()

std::vector< std::vector< int > > LVL1::L1CaloOfflineTriggerTowerTools::hadTTCellsLayerNamesByReceiver ( const TriggerTower * tt) const
overridevirtual

Implements LVL1::IL1CaloOfflineTriggerTowerTools.

Definition at line 503 of file L1CaloOfflineTriggerTowerTools.cxx.

503 {
504 Identifier Id = this->hadID(tt->eta(),tt->phi());
505 std::vector<unsigned int> rx = this->hadRxId(tt);
506 std::vector<int> v1;
507 std::vector<int> v2;
508 std::vector<std::vector<int> > v;
509 std::vector<std::vector<const CaloCell*> > cells = m_cells2tt->caloCellsByLayer(Id);
510 for(Itr_vvCaloCells i=cells.begin();i!=cells.end();++i){
511 if ((*i).empty()) continue;
512 if (rx.size() == 2) {
513 std::vector<std::vector<const CaloCell*> > cellsRx = this->sortFCAL23Cells((*i),rx);
514 for(Itr_vvCaloCells j=cellsRx.begin();j!=cellsRx.end();++j){
515 if ((*j).empty()) continue;
516 if (j == cellsRx.begin()) v1.push_back(m_cells2tt->layerNames((*j)[0]));
517 else v2.push_back(m_cells2tt->layerNames((*j)[0]));
518 }
519 } else if (rx.size() == 1) v1.push_back(m_cells2tt->layerNames((*i)[0]));
520 }
521 v.push_back(std::move(v1));
522 if (rx.size() == 2) v.push_back(std::move(v2));
523 return v;
524 }

◆ ID()

Identifier LVL1::L1CaloOfflineTriggerTowerTools::ID ( const double eta,
const double phi,
int layer ) const

Definition at line 1728 of file L1CaloOfflineTriggerTowerTools.cxx.

1728 {
1729 return m_lvl1Helper->tower_id(this->pos_neg_z(eta),layer,this->region(eta),this->ieta(eta),this->iphi(eta,phi));
1730 }

◆ ieta()

int LVL1::L1CaloOfflineTriggerTowerTools::ieta ( const double eta) const
overrideprotectedvirtual

Implements LVL1::IL1CaloOfflineTriggerTowerTools.

Definition at line 1720 of file L1CaloOfflineTriggerTowerTools.cxx.

1720 {
1721 return m_l1CaloTTIdTools->etaIndex(eta);
1722 }

◆ InBcidNegedge()

unsigned short int LVL1::L1CaloOfflineTriggerTowerTools::InBcidNegedge ( const coral::AttributeList * attrList) const
overridevirtual

Implements LVL1::IL1CaloOfflineTriggerTowerTools.

Definition at line 1451 of file L1CaloOfflineTriggerTowerTools.cxx.

1451 {
1452 unsigned short int value = 0;
1453 for(unsigned int attrNum=0;attrNum<attrList->size();attrNum++){
1454 if((*attrList)[attrNum].specification().name() == "InBcidNegedge"){
1455 value = (unsigned short int) (*attrList)[attrNum].data<unsigned short int>();
1456 break;
1457 }
1458 }
1459 return value;
1460 }

◆ initialize()

StatusCode LVL1::L1CaloOfflineTriggerTowerTools::initialize ( void )
overridevirtual

Dummy implementation of the initialisation function.

It's here to allow the dual-use tools to skip defining an initialisation function. Since many are doing so...

Reimplemented from asg::AsgTool.

Definition at line 1672 of file L1CaloOfflineTriggerTowerTools.cxx.

1672 {
1674
1675 m_ttOnlineIdHelper = m_caloMgr->getTTOnlineID();
1676 if(!m_ttOnlineIdHelper){ATH_MSG_ERROR("Could not access TTOnlineId helper");return StatusCode::FAILURE;}
1677
1678 m_lvl1Helper = m_caloMgr->getLVL1_ID();
1679 if(!m_lvl1Helper){ATH_MSG_ERROR("Could not access CaloLVL1_ID helper");return StatusCode::FAILURE;}
1680
1682 ATH_CHECK( m_tileBadChanTool.retrieve() );
1683 ATH_CHECK( m_rxMapTool.retrieve() );
1684 ATH_CHECK( detStore()->retrieve(m_larOnlineID,"LArOnlineID") );
1685 ATH_CHECK( m_l1CaloTTIdTools.retrieve() );
1686 ATH_CHECK( m_cells2tt.retrieve() );
1687
1688 ATH_CHECK( detStore()->retrieve (m_caloMgr, "CaloIdManager") );
1689 ATH_CHECK( m_scidtool.retrieve() );
1690
1691 //Retrieve cabling & tt services
1692 ATH_CHECK( m_ttSvc.retrieve() );
1693
1694 ATH_CHECK( m_onlineScaleCorrKey.initialize() );
1695
1696 ATH_MSG_INFO("L1Calo L1CaloOfflineTriggerTowerTools initialize() success!");
1697 return StatusCode::SUCCESS;
1698 }
#define ATH_CHECK
Evaluate an expression and check for errors.
#define ATH_MSG_ERROR(x)
#define ATH_MSG_INFO(x)
const ServiceHandle< StoreGateSvc > & detStore() const
SG::ReadCondHandleKey< ILArHVScaleCorr > m_onlineScaleCorrKey
retrieve(aClass, aKey=None)
Definition PyKernel.py:110

◆ 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.

◆ iphi()

int LVL1::L1CaloOfflineTriggerTowerTools::iphi ( const double eta,
const double phi ) const
overrideprotectedvirtual

Implements LVL1::IL1CaloOfflineTriggerTowerTools.

Definition at line 1724 of file L1CaloOfflineTriggerTowerTools.cxx.

1724 {
1725 return m_l1CaloTTIdTools->phiIndex(eta,phi);
1726 }

◆ LArCaloQuality()

float LVL1::L1CaloOfflineTriggerTowerTools::LArCaloQuality ( const std::vector< const CaloCell * > & cells) const
overrideprotectedvirtual

Implements LVL1::IL1CaloOfflineTriggerTowerTools.

Definition at line 763 of file L1CaloOfflineTriggerTowerTools.cxx.

763 {
764 float nom(0.), denom(0.);
765 for(Itr_vCaloCells i=cells.begin();i!=cells.end();++i){
766 if((*i)->provenance() & 0x2000) {
767 nom += ((*i)->e() * (*i)->quality());
768 denom += (*i)->e();
769 }
770 }
771
772 if(denom != 0.) {
773 nom /= denom;
774 }
775 else{
776 nom = -1e6; // error value
777 }
778 return nom;
779 }
std::vector< constCaloCell * >::const_iterator Itr_vCaloCells

◆ LArHV()

void LVL1::L1CaloOfflineTriggerTowerTools::LArHV ( const SG::ReadCondHandleKey< ILArHVScaleCorr > & scaleCorrKey,
const SG::ReadCondHandleKey< LArOnOffIdMapping > & cablingKey )
overridevirtual

Implements LVL1::IL1CaloOfflineTriggerTowerTools.

Definition at line 1704 of file L1CaloOfflineTriggerTowerTools.cxx.

1706 {
1707 m_scaleCorrKey = scaleCorrKey;
1708 m_cablingKey = cablingKey;
1709 m_isLArHVCorrToolSet = true;
1710 }

◆ LArHVScale() [1/2]

float LVL1::L1CaloOfflineTriggerTowerTools::LArHVScale ( const CaloCell * cell,
const ILArHVScaleCorr * scaleCorr,
const ILArHVScaleCorr * onlineScaleCorr,
const LArOnOffIdMapping * cabling ) const
overrideprotectedvirtual

Implements LVL1::IL1CaloOfflineTriggerTowerTools.

Definition at line 753 of file L1CaloOfflineTriggerTowerTools.cxx.

757 {
758 HWIdentifier hwid=cabling->createSignalChannelID(cell->ID());
759 return scaleCorr->HVScaleCorr( hwid ) * onlineScaleCorr->HVScaleCorr( hwid );
760 }
virtual const float & HVScaleCorr(const HWIdentifier &id) const =0

◆ LArHVScale() [2/2]

float LVL1::L1CaloOfflineTriggerTowerTools::LArHVScale ( const std::vector< const CaloCell * > & cells) const
overrideprotectedvirtual

Implements LVL1::IL1CaloOfflineTriggerTowerTools.

Definition at line 738 of file L1CaloOfflineTriggerTowerTools.cxx.

738 {
739 const EventContext& ctx = Gaudi::Hive::currentContext();
740 SG::ReadCondHandle<LArOnOffIdMapping> cabling (m_cablingKey, ctx);
741 SG::ReadCondHandle<ILArHVScaleCorr> scaleCorr (m_scaleCorrKey, ctx);
742 SG::ReadCondHandle<ILArHVScaleCorr> onlineScaleCorr (m_onlineScaleCorrKey, ctx);
743
744 float scale(0.0),count(0.0);
745 for(Itr_vCaloCells i=cells.begin();i!=cells.end();++i){
746 scale += this->LArHVScale( (*i), scaleCorr.cptr(), onlineScaleCorr.cptr(), cabling.cptr() );
747 count++;
748 }
749 if(count < 1.0){return 0.0;}
750 return scale / count;
751 }
int count(std::string s, const std::string &regx)
count how many occurances of a regx are in a string
Definition hcg.cxx:146

◆ LArNonNominalHV() [1/2]

float LVL1::L1CaloOfflineTriggerTowerTools::LArNonNominalHV ( const CaloCell * cell,
const ILArHVScaleCorr * scaleCorr,
const ILArHVScaleCorr * onlineScaleCorr,
const LArOnOffIdMapping * cabling ) const
overrideprotectedvirtual

Implements LVL1::IL1CaloOfflineTriggerTowerTools.

Definition at line 725 of file L1CaloOfflineTriggerTowerTools.cxx.

728 {
729 float nonNominal(0.0);
730 HWIdentifier hwid=cabling->createSignalChannelID(cell->ID());
731 float corr = scaleCorr->HVScaleCorr( hwid ) * onlineScaleCorr->HVScaleCorr( hwid );
732 if(corr > m_LArHVNonNomPara){
733 nonNominal = 1.0;
734 }
735 return nonNominal;
736 }

◆ LArNonNominalHV() [2/2]

float LVL1::L1CaloOfflineTriggerTowerTools::LArNonNominalHV ( const std::vector< const CaloCell * > & cells) const
overrideprotectedvirtual

Implements LVL1::IL1CaloOfflineTriggerTowerTools.

Definition at line 713 of file L1CaloOfflineTriggerTowerTools.cxx.

713 {
714 const EventContext& ctx = Gaudi::Hive::currentContext();
715 SG::ReadCondHandle<LArOnOffIdMapping> cabling (m_cablingKey, ctx);
716 SG::ReadCondHandle<ILArHVScaleCorr> scaleCorr (m_scaleCorrKey, ctx);
717 SG::ReadCondHandle<ILArHVScaleCorr> onlineScaleCorr (m_onlineScaleCorrKey, ctx);
718 float nonNominal(0.0);
719 for(Itr_vCaloCells i=cells.begin();i!=cells.end();++i){
720 nonNominal += this->LArNonNominalHV( (*i), scaleCorr.cptr(), onlineScaleCorr.cptr(), cabling.cptr() );
721 }
722 return nonNominal;
723 }

◆ LutNoiseCut()

unsigned short LVL1::L1CaloOfflineTriggerTowerTools::LutNoiseCut ( const coral::AttributeList * attrList) const
overridevirtual

Implements LVL1::IL1CaloOfflineTriggerTowerTools.

Definition at line 1628 of file L1CaloOfflineTriggerTowerTools.cxx.

1628 {
1629 unsigned short value = 0;
1630 for(unsigned int attrNum=0;attrNum<attrList->size();attrNum++){
1631 if((*attrList)[attrNum].specification().name() == "LutNoiseCut"){
1632 value = (unsigned short) (*attrList)[attrNum].data<unsigned short>();
1633 break;
1634 }
1635 }
1636 return value;
1637 }

◆ LutOffset()

unsigned short LVL1::L1CaloOfflineTriggerTowerTools::LutOffset ( const coral::AttributeList * attrList) const
overridevirtual

Implements LVL1::IL1CaloOfflineTriggerTowerTools.

Definition at line 1606 of file L1CaloOfflineTriggerTowerTools.cxx.

1606 {
1607 unsigned short value = 0;
1608 for(unsigned int attrNum=0;attrNum<attrList->size();attrNum++){
1609 if((*attrList)[attrNum].specification().name() == "LutOffset"){
1610 value = (unsigned short) (*attrList)[attrNum].data<unsigned short>();
1611 break;
1612 }
1613 }
1614 return value;
1615 }

◆ LutSlope()

unsigned short LVL1::L1CaloOfflineTriggerTowerTools::LutSlope ( const coral::AttributeList * attrList) const
overridevirtual

Implements LVL1::IL1CaloOfflineTriggerTowerTools.

Definition at line 1617 of file L1CaloOfflineTriggerTowerTools.cxx.

1617 {
1618 unsigned short value = 0;
1619 for(unsigned int attrNum=0;attrNum<attrList->size();attrNum++){
1620 if((*attrList)[attrNum].specification().name() == "LutSlope"){
1621 value = (unsigned short) (*attrList)[attrNum].data<unsigned short >();
1622 break;
1623 }
1624 }
1625 return value;
1626 }

◆ LutStrategy()

unsigned short LVL1::L1CaloOfflineTriggerTowerTools::LutStrategy ( const coral::AttributeList * attrList) const
overridevirtual

Implements LVL1::IL1CaloOfflineTriggerTowerTools.

Definition at line 1595 of file L1CaloOfflineTriggerTowerTools.cxx.

1595 {
1596 unsigned short value = 0;
1597 for(unsigned int attrNum=0;attrNum<attrList->size();attrNum++){
1598 if((*attrList)[attrNum].specification().name() == "LutStrategy"){
1599 value = (unsigned short) (*attrList)[attrNum].data<unsigned short>();
1600 break;
1601 }
1602 }
1603 return value;
1604 }

◆ ModuleId()

unsigned int LVL1::L1CaloOfflineTriggerTowerTools::ModuleId ( const coral::AttributeList * attrList) const
overridevirtual

Implements LVL1::IL1CaloOfflineTriggerTowerTools.

Definition at line 1285 of file L1CaloOfflineTriggerTowerTools.cxx.

1285 {
1286 unsigned int value = 0;
1287 for(unsigned int attrNum=0;attrNum<attrList->size();attrNum++){
1288 if((*attrList)[attrNum].specification().name() == "ModuleId"){
1289 value = (unsigned int) (*attrList)[attrNum].data<unsigned int>();
1290 break;
1291 }
1292 }
1293 return value;
1294 }

◆ msg()

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

Definition at line 24 of file AthCommonMsg.h.

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

◆ msg_level_name()

const std::string & asg::AsgTool::msg_level_name ( ) const
inherited

A deprecated function for getting the message level's name.

Instead of using this, weirdly named function, user code should get the string name of the current minimum message level (in case they really need it...), with:

MSG::name( msg().level() )

This function's name doesn't follow the ATLAS coding rules, and as such will be removed in the not too distant future.

Returns
The string name of the current minimum message level that's printed

Definition at line 101 of file AsgTool.cxx.

101 {
102
103 return MSG::name( msg().level() );
104 }
MsgStream & msg() const
const std::string & name(Level lvl)
Convenience function for translating message levels to strings.
Definition MsgLevel.cxx:19

◆ 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 }

◆ operator=()

L1CaloOfflineTriggerTowerTools & LVL1::L1CaloOfflineTriggerTowerTools::operator= ( const L1CaloOfflineTriggerTowerTools & rhs)
delete

◆ 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.

◆ PedMean()

double LVL1::L1CaloOfflineTriggerTowerTools::PedMean ( const coral::AttributeList * attrList) const
overridevirtual

Implements LVL1::IL1CaloOfflineTriggerTowerTools.

Definition at line 1406 of file L1CaloOfflineTriggerTowerTools.cxx.

1406 {
1407 double value = 0;
1408 for(unsigned int attrNum=0;attrNum<attrList->size();attrNum++){
1409 if((*attrList)[attrNum].specification().name() == "PedMean"){
1410 value = (double) (*attrList)[attrNum].data<double>();
1411 break;
1412 }
1413 }
1414 return value;
1415 }

◆ PedValue()

unsigned int LVL1::L1CaloOfflineTriggerTowerTools::PedValue ( const coral::AttributeList * attrList) const
overridevirtual

Implements LVL1::IL1CaloOfflineTriggerTowerTools.

Definition at line 1417 of file L1CaloOfflineTriggerTowerTools.cxx.

1417 {
1418 unsigned int value = 0;
1419 for(unsigned int attrNum=0;attrNum<attrList->size();attrNum++){
1420 if((*attrList)[attrNum].specification().name() == "PedValue"){
1421 value = (unsigned int) (*attrList)[attrNum].data<unsigned int>();
1422 break;
1423 }
1424 }
1425 return value;
1426 }

◆ pos_neg_z()

int LVL1::L1CaloOfflineTriggerTowerTools::pos_neg_z ( const double eta) const
overrideprotectedvirtual

Implements LVL1::IL1CaloOfflineTriggerTowerTools.

Definition at line 1712 of file L1CaloOfflineTriggerTowerTools.cxx.

1712 {
1713 return m_l1CaloTTIdTools->pos_neg_z(eta);
1714 }

◆ PprDacScanResultsTimeStamp()

unsigned long long LVL1::L1CaloOfflineTriggerTowerTools::PprDacScanResultsTimeStamp ( const coral::AttributeList * attrList) const
overridevirtual

Implements LVL1::IL1CaloOfflineTriggerTowerTools.

Definition at line 1307 of file L1CaloOfflineTriggerTowerTools.cxx.

1307 {
1308 unsigned long long value = 0;
1309 for(unsigned int attrNum=0;attrNum<attrList->size();attrNum++){
1310 if((*attrList)[attrNum].specification().name() == "PprDacScanResultsTimeStamp"){
1311 value = (unsigned long long) (*attrList)[attrNum].data<unsigned long long>();
1312 break;
1313 }
1314 }
1315 return value;
1316 }

◆ PprFirFilterResultsTimeStamp()

unsigned long long LVL1::L1CaloOfflineTriggerTowerTools::PprFirFilterResultsTimeStamp ( const coral::AttributeList * attrList) const
overridevirtual

Implements LVL1::IL1CaloOfflineTriggerTowerTools.

Definition at line 1362 of file L1CaloOfflineTriggerTowerTools.cxx.

1362 {
1363 unsigned long long value = 0;
1364 for(unsigned int attrNum=0;attrNum<attrList->size();attrNum++){
1365 if((*attrList)[attrNum].specification().name() == "PprFirFilterResultsTimeStamp"){
1366 value = (unsigned long long) (*attrList)[attrNum].data<unsigned long long>();
1367 break;
1368 }
1369 }
1370 return value;
1371 }

◆ PprLutValuesResultsTimeStamp()

unsigned long long LVL1::L1CaloOfflineTriggerTowerTools::PprLutValuesResultsTimeStamp ( const coral::AttributeList * attrList) const
overridevirtual

Implements LVL1::IL1CaloOfflineTriggerTowerTools.

Definition at line 1373 of file L1CaloOfflineTriggerTowerTools.cxx.

1373 {
1374 unsigned long long value = 0;
1375 for(unsigned int attrNum=0;attrNum<attrList->size();attrNum++){
1376 if((*attrList)[attrNum].specification().name() == "PprLutValuesResultsTimeStamp"){
1377 value = (unsigned long long) (*attrList)[attrNum].data<unsigned long long>();
1378 break;
1379 }
1380 }
1381 return value;
1382 }

◆ PprNoiseRunResultsTimeStamp()

unsigned long long LVL1::L1CaloOfflineTriggerTowerTools::PprNoiseRunResultsTimeStamp ( const coral::AttributeList * attrList) const
overridevirtual

Implements LVL1::IL1CaloOfflineTriggerTowerTools.

Definition at line 1329 of file L1CaloOfflineTriggerTowerTools.cxx.

1329 {
1330 unsigned long long value = 0;
1331 for(unsigned int attrNum=0;attrNum<attrList->size();attrNum++){
1332 if((*attrList)[attrNum].specification().name() == "PprNoiseRunResultsTimeStamp"){
1333 value = (unsigned long long) (*attrList)[attrNum].data<unsigned long long>();
1334 break;
1335 }
1336 }
1337 return value;
1338 }

◆ PprPedestalRunResultsTimeStamp()

unsigned long long LVL1::L1CaloOfflineTriggerTowerTools::PprPedestalRunResultsTimeStamp ( const coral::AttributeList * attrList) const
overridevirtual

Implements LVL1::IL1CaloOfflineTriggerTowerTools.

Definition at line 1318 of file L1CaloOfflineTriggerTowerTools.cxx.

1318 {
1319 unsigned long long value = 0;
1320 for(unsigned int attrNum=0;attrNum<attrList->size();attrNum++){
1321 if((*attrList)[attrNum].specification().name() == "PprPedestalRunResultsTimeStamp"){
1322 value = (unsigned long long) (*attrList)[attrNum].data<unsigned long long>();
1323 break;
1324 }
1325 }
1326 return value;
1327 }

◆ PprSatBcidResultsTimeStamp()

unsigned long long LVL1::L1CaloOfflineTriggerTowerTools::PprSatBcidResultsTimeStamp ( const coral::AttributeList * attrList) const
overridevirtual

Implements LVL1::IL1CaloOfflineTriggerTowerTools.

Definition at line 1351 of file L1CaloOfflineTriggerTowerTools.cxx.

1351 {
1352 unsigned long long value = 0;
1353 for(unsigned int attrNum=0;attrNum<attrList->size();attrNum++){
1354 if((*attrList)[attrNum].specification().name() == "PprSatBcidResultsTimeStamp"){
1355 value = (unsigned long long) (*attrList)[attrNum].data<unsigned long long>();
1356 break;
1357 }
1358 }
1359 return value;
1360 }

◆ PprTimingResultsTimeStamp()

unsigned long long LVL1::L1CaloOfflineTriggerTowerTools::PprTimingResultsTimeStamp ( const coral::AttributeList * attrList) const
overridevirtual

Implements LVL1::IL1CaloOfflineTriggerTowerTools.

Definition at line 1340 of file L1CaloOfflineTriggerTowerTools.cxx.

1340 {
1341 unsigned long long value = 0;
1342 for(unsigned int attrNum=0;attrNum<attrList->size();attrNum++){
1343 if((*attrList)[attrNum].specification().name() == "PprTimingResultsTimeStamp"){
1344 value = (unsigned long long) (*attrList)[attrNum].data<unsigned long long>();
1345 break;
1346 }
1347 }
1348 return value;
1349 }

◆ print()

◆ region()

int LVL1::L1CaloOfflineTriggerTowerTools::region ( const double eta) const
overrideprotectedvirtual

Implements LVL1::IL1CaloOfflineTriggerTowerTools.

Definition at line 1716 of file L1CaloOfflineTriggerTowerTools.cxx.

1716 {
1717 return m_l1CaloTTIdTools->regionIndex(eta);
1718 }

◆ 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 }

◆ RxGain()

float LVL1::L1CaloOfflineTriggerTowerTools::RxGain ( const coral::AttributeList * attrList) const
overridevirtual

Implements LVL1::IL1CaloOfflineTriggerTowerTools.

Definition at line 1262 of file L1CaloOfflineTriggerTowerTools.cxx.

1262 {
1263 float value = 0;
1264 for(unsigned int attrNum=0;attrNum<attrList->size();attrNum++){
1265 if((*attrList)[attrNum].specification().name() == "gain"){
1266 value = (float) (*attrList)[attrNum].data<float>();
1267 break;
1268 }
1269 }
1270 return value;
1271 }

◆ RxStatus()

unsigned int LVL1::L1CaloOfflineTriggerTowerTools::RxStatus ( const coral::AttributeList * attrList) const
overridevirtual

Implements LVL1::IL1CaloOfflineTriggerTowerTools.

Definition at line 1273 of file L1CaloOfflineTriggerTowerTools.cxx.

1273 {
1274 unsigned int value = 0;
1275 for(unsigned int attrNum=0;attrNum<attrList->size();attrNum++){
1276 if((*attrList)[attrNum].specification().name() == "status"){
1277 value = (unsigned int) (*attrList)[attrNum].data<unsigned int>();
1278 break;
1279 }
1280 }
1281 return value;
1282 }

◆ SatBcidLevel()

unsigned short int LVL1::L1CaloOfflineTriggerTowerTools::SatBcidLevel ( const coral::AttributeList * attrList) const
overridevirtual

Implements LVL1::IL1CaloOfflineTriggerTowerTools.

Definition at line 1496 of file L1CaloOfflineTriggerTowerTools.cxx.

1496 {
1497 unsigned short int value = 0;
1498 for(unsigned int attrNum=0;attrNum<attrList->size();attrNum++){
1499 if((*attrList)[attrNum].specification().name() == "SatBcidLevel"){
1500 value = (unsigned short int) (*attrList)[attrNum].data<unsigned short int>();
1501 break;
1502 }
1503 }
1504 return value;
1505 }

◆ SatBcidThreshHigh()

unsigned short int LVL1::L1CaloOfflineTriggerTowerTools::SatBcidThreshHigh ( const coral::AttributeList * attrList) const
overridevirtual

Implements LVL1::IL1CaloOfflineTriggerTowerTools.

Definition at line 1485 of file L1CaloOfflineTriggerTowerTools.cxx.

1485 {
1486 unsigned short int value = 0;
1487 for(unsigned int attrNum=0;attrNum<attrList->size();attrNum++){
1488 if((*attrList)[attrNum].specification().name() == "SatBcidThreshHigh"){
1489 value = (unsigned short int) (*attrList)[attrNum].data<unsigned short int>();
1490 break;
1491 }
1492 }
1493 return value;
1494 }

◆ SatBcidThreshLow()

unsigned short int LVL1::L1CaloOfflineTriggerTowerTools::SatBcidThreshLow ( const coral::AttributeList * attrList) const
overridevirtual

Implements LVL1::IL1CaloOfflineTriggerTowerTools.

Definition at line 1474 of file L1CaloOfflineTriggerTowerTools.cxx.

1474 {
1475 unsigned short int value = 0;
1476 for(unsigned int attrNum=0;attrNum<attrList->size();attrNum++){
1477 if((*attrList)[attrNum].specification().name() == "SatBcidThreshLow"){
1478 value = (unsigned short int) (*attrList)[attrNum].data<unsigned short int>();
1479 break;
1480 }
1481 }
1482 return value;
1483 }

◆ sortEMCrackCells()

std::vector< std::vector< const CaloCell * > > LVL1::L1CaloOfflineTriggerTowerTools::sortEMCrackCells ( const std::vector< const CaloCell * > & cells) const
overrideprotectedvirtual

Implements LVL1::IL1CaloOfflineTriggerTowerTools.

Definition at line 417 of file L1CaloOfflineTriggerTowerTools.cxx.

417 {
418 std::vector<std::vector<const CaloCell*> > output;
419 std::vector<const CaloCell*> emb;
420 std::vector<const CaloCell*> emec;
421
422 // End Cap first, Barrel second
423
424 for(Itr_vCaloCells i=cells.begin();i!=cells.end();++i){
425 int layer = m_cells2tt->layerNames(*i);
426
427 if( layer <= 3){
428 emb.push_back( (*i) );
429 }
430 if( layer >= 4){
431 emec.push_back( (*i) );
432 }
433 }
434
435 output.push_back(std::move(emec));
436 output.push_back(std::move(emb));
437 return output;
438 }
@ layer
Definition HitInfo.h:79

◆ sortFCAL23Cells() [1/2]

std::vector< std::vector< const CaloCell * > > LVL1::L1CaloOfflineTriggerTowerTools::sortFCAL23Cells ( const std::vector< const CaloCell * > & cells,
const double eta ) const
overrideprotectedvirtual

Implements LVL1::IL1CaloOfflineTriggerTowerTools.

Definition at line 614 of file L1CaloOfflineTriggerTowerTools.cxx.

615 {
616 std::vector<std::vector<const CaloCell*> > output;
617
618 std::vector<const CaloCell*> fcal2A;
619 std::vector<const CaloCell*> fcal2B;
620 std::vector<const CaloCell*> fcal3A;
621 std::vector<const CaloCell*> fcal3B;
622 double absEta = fabs(eta);
623
624 for(Itr_vCaloCells i=cells.begin();i!=cells.end();++i){
625 int layer = m_cells2tt->layerNames(*i);
626 const CaloDetDescrElement* caloDDE = (*i)->caloDDE();
627 // _raw is ideal position
628 double cellEta = fabs(caloDDE->eta_raw());
629 double x = fabs(caloDDE->x_raw());
630 double y = fabs(caloDDE->y_raw());
631
632 // FCAL 2
633 if (layer == 22) {
634 // TTs split the eta range equally, hence the apparent inconsistencies in next line
635 bool lowEta = (absEta < 4.05 && cellEta < 3.3) || (absEta > 4.05 && cellEta < 3.97);
636 // Exceptions, based on radial map
637 if ((x > 100. && x < 160. && y > 340. && y < 380.) ||
638 (x > 320. && x < 360. && y > 170. && y < 210.) ||
639 (x > 30. && x < 60. && y > 170. && y < 210.)) lowEta = true;
640 if ((x > 160. && x < 190. && y > 340. && y < 380.) ||
641 (x > 230. && x < 260. && y > 300. && y < 340.) ||
642 (x > 130. && x < 160. && y > 140. && y < 170.) ||
643 (x > 160. && x < 200. && y > 90. && y < 140.)) lowEta = false;
644 if (lowEta) fcal2A.push_back(*i);
645 else fcal2B.push_back(*i);
646 }
647 // FCAL 3
648 if (layer == 23) {
649 bool lowEta = (absEta < 4.05 && cellEta < 3.43) || (absEta > 4.05 && cellEta < 3.9);
650 // Exceptions
651 double xs = caloDDE->x_raw();
652 double ys = caloDDE->y_raw();
653 if ((x > 120. && x < 160. && y > 140. && y < 200.) ||
654 (x > 160. && x < 220. && y > 100. && y < 140.) ||
655 (xs > 120. && xs < 160. && ys > -140. && ys < -100.) ||
656 (xs > -160. && xs < -100. && ys > 100. && ys < 140.)) lowEta = true;
657 if ((x > 0. && x < 60. && y > 380. && y < 420.) ||
658 (xs > 320. && xs < 370. && ys > 140. && ys < 190.) ||
659 (xs > -360. && xs < -320. && ys > -180. && ys < -140.)) lowEta = false;
660 if (lowEta) fcal3A.push_back(*i);
661 else fcal3B.push_back(*i);
662 }
663 }
664
665 unsigned int size2A = fcal2A.size();
666 unsigned int size2B = fcal2B.size();
667 unsigned int size3A = fcal3A.size();
668 unsigned int size3B = fcal3B.size();
669
670 // Always have lowEta first
671 if(size2A > 0 && size2B > 0 && size3A == 0 && size3B == 0){ // FCAL 2
672 output.push_back(std::move(fcal2A));
673 output.push_back(std::move(fcal2B));
674 }
675 if(size2A == 0 && size2B == 0 && size3A > 0 && size3B > 0){ // FCAL 3
676 output.push_back(std::move(fcal3A));
677 output.push_back(std::move(fcal3B));
678 }
679
680 return output;
681 }
#define y
#define x
bool absEta(const xAOD::TauJet &tau, float &out)

◆ sortFCAL23Cells() [2/2]

std::vector< std::vector< const CaloCell * > > LVL1::L1CaloOfflineTriggerTowerTools::sortFCAL23Cells ( const std::vector< const CaloCell * > & cells,
const std::vector< unsigned int > & rxId ) const
overrideprotectedvirtual

Implements LVL1::IL1CaloOfflineTriggerTowerTools.

Definition at line 683 of file L1CaloOfflineTriggerTowerTools.cxx.

684 {
685
686 // vectors of calo cells for the different receivers
687 std::vector<const CaloCell*> cellsA;
688 std::vector<const CaloCell*> cellsB;
689 // output
690 std::vector<std::vector<const CaloCell*> > output;
691
692 // RxID of the different receivers
693 unsigned int rxidA = rxId.at(0);
694 unsigned int rxidB = rxId.at(1);
695
696 // Loop over calo cells and use mapping tool to assign cells to different receivers
697 for(Itr_vCaloCells i=cells.begin();i!=cells.end();++i){
698 unsigned int someRxId = m_rxMapTool->offlineCell2RxId( (*i)->ID().get_identifier32().get_compact() );
699 if(someRxId == rxidA){cellsA.push_back(*i);}
700 if(someRxId == rxidB){cellsB.push_back(*i);}
701 }
702 output.push_back(std::move(cellsA));
703 output.push_back(std::move(cellsB));
704 return output;
705 }

◆ SuperCellIdentifiers()

std::vector< int > LVL1::L1CaloOfflineTriggerTowerTools::SuperCellIdentifiers ( const std::vector< const CaloCell * > & cells) const
protected

Definition at line 1172 of file L1CaloOfflineTriggerTowerTools.cxx.

1172 {
1173 std::vector<int> output;
1174 std::map<int, std::vector<const CaloCell*> > sc_ids;
1175 for(Itr_vCaloCells i=cells.begin();i!=cells.end();++i){
1176 const CaloCell* cell = (*i);
1177 Identifier sCellID = m_scidtool->offlineToSuperCellID ( cell->ID() );
1178 sc_ids[sCellID.get_identifier32().get_compact()].push_back( cell );
1179 }
1180 for(std::map< int, std::vector<const CaloCell*> >::const_iterator i=sc_ids.begin();i!=sc_ids.end();++i){
1181 output.push_back( (*i).first );
1182 }
1183 return output;
1184 }
value_type get_compact() const
Get the compact id.
Identifier32 get_identifier32() const
Get the 32-bit version Identifier, will be invalid if >32 bits needed.

◆ SyncDelayBcid()

unsigned short int LVL1::L1CaloOfflineTriggerTowerTools::SyncDelayBcid ( const coral::AttributeList * attrList) const
overridevirtual

Implements LVL1::IL1CaloOfflineTriggerTowerTools.

Definition at line 1439 of file L1CaloOfflineTriggerTowerTools.cxx.

1439 {
1440 unsigned short int value = 0;
1441 for(unsigned int attrNum=0;attrNum<attrList->size();attrNum++){
1442 if((*attrList)[attrNum].specification().name() == "SyncDelayBcid"){
1443 value = (unsigned short int) (*attrList)[attrNum].data<unsigned short int>();
1444 break;
1445 }
1446 }
1447 return value;
1448 }

◆ 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.

◆ TileCaloQuality()

float LVL1::L1CaloOfflineTriggerTowerTools::TileCaloQuality ( const std::vector< const CaloCell * > & cells) const
overrideprotectedvirtual

Implements LVL1::IL1CaloOfflineTriggerTowerTools.

Definition at line 857 of file L1CaloOfflineTriggerTowerTools.cxx.

857 {
858 float nom(0.), denom(0.);
859 for(Itr_vCaloCells i=cells.begin();i!=cells.end();++i){
860 const TileCell *tileCell = dynamic_cast<const TileCell*>( (*i) );
861
862 if(tileCell && tileCell->provenance() & 0x8080) {
863 nom += tileCell->e() * std::max(tileCell->qual1(), tileCell->qual2());
864 denom += tileCell->e();
865 }
866 }
867
868 if(denom != 0.) {
869 nom /= denom;
870 }
871 else {
872 nom = -1e6; // error value
873 }
874 return nom;
875 }
virtual double e() const override final
get energy (data member) (synonym to method energy()
Definition CaloCell.h:333
uint16_t provenance() const
get provenance (data member)
Definition CaloCell.h:354
uint8_t qual1(void) const
get quality of first PMT (data member)
Definition TileCell.h:197
uint8_t qual2(void) const
get quality of second PMT (data member)
Definition TileCell.h:200

◆ tileCellEnergy()

float LVL1::L1CaloOfflineTriggerTowerTools::tileCellEnergy ( const TriggerTower * tt,
IdTTL1CellMapType & map ) const
overridevirtual

Implements LVL1::IL1CaloOfflineTriggerTowerTools.

Definition at line 601 of file L1CaloOfflineTriggerTowerTools.cxx.

601 {
602 Identifier Id = this->hadID(tt->eta(),tt->phi());
603 if(m_lvl1Helper->is_tile(Id) == false){return 0.0;}
604 else{
605 IdTTL1CellMapType::const_iterator ttL1Cell(map.find(Id));
606 IdTTL1CellMapType::const_iterator ttL1Cell_E(map.end());
607 if(ttL1Cell != ttL1Cell_E){
608 return ((ttL1Cell->second)->eneTower()) * 1e-3;
609 }
610 return 0.0;
611 }
612 }

◆ TileNonNominal() [1/2]

float LVL1::L1CaloOfflineTriggerTowerTools::TileNonNominal ( const CaloCell * cell) const
overrideprotectedvirtual

Implements LVL1::IL1CaloOfflineTriggerTowerTools.

Definition at line 791 of file L1CaloOfflineTriggerTowerTools.cxx.

791 {
792
793 // There are either 1 or 2 PMTs per Calo Cell
794 // A PMT may have Half Gain L1 or No Gain L1
795 //
796 // Assign a score as follows.
797 //
798 // Case (a) : 2 PMTs in the Cell
799 // Half gain counts as 0.25
800 // No gain counts as 0.5
801 // So if a cells has no gain in PMT1 and half gain in PMT2 it's score is 0.75
802 //
803 // Case (b) : 1 PMT in the Cell
804 // Half gain counts as 0.5
805 // No Gain counts as 1.0
806
807
808 // Cast the CaloCell as a TileCell
809 const TileCell *tileCell = dynamic_cast<const TileCell*>(cell);
810 if (!tileCell) return 0.0;
811
812 // Get IdentifierHash for both PMTs
813 const CaloDetDescrElement * caloDDE = tileCell->caloDDE();
814 IdentifierHash hash1 = caloDDE->onl1();
815 IdentifierHash hash2 = caloDDE->onl2();
816
817 // Values for PMT 1 and 2
818 int gain1(-9),gain2(-9);
819 float score(0.0),multiplier(1.0);
820 bool adc1_noGainL1(false),adc1_halfGainL1(false);
821 bool pmt2Valid(false),adc2_noGainL1(false),adc2_halfGainL1(false);
822
823 // PMT 1
824 gain1 = tileCell->gain1();
825 HWIdentifier adc_id1 = m_tileHWID->adc_id(hash1,(gain1<0)?1:gain1);
826 const TileBchStatus badChan1 = m_tileBadChanTool->getAdcStatus(adc_id1);
827 adc1_noGainL1 = badChan1.isNoGainL1();
828 adc1_halfGainL1 = badChan1.isHalfGainL1();
829
830 // gap/crack scintillators only have one PMT per cell
831 // PMT 2, if valid
832 if(hash2 != TileHWID::NOT_VALID_HASH){
833 pmt2Valid = true;
834 gain2 = tileCell->gain2();
835 HWIdentifier adc_id2 = m_tileHWID->adc_id(hash2,(gain2<0)?1:gain2);
836 const TileBchStatus badChan2 = m_tileBadChanTool->getAdcStatus(adc_id2);
837 adc2_noGainL1 = badChan2.isNoGainL1();
838 adc2_halfGainL1 = badChan2.isHalfGainL1();
839 }
840
841 // Calculate the TileCell score
842
843 // Check that a PMT can't contribute more than 0.5
844 // Should not be the case, but assumptions cause bugs.....
845 if(adc1_noGainL1 == true && adc1_halfGainL1 == true){adc1_halfGainL1 = false;}
846 if(adc2_noGainL1 == true && adc2_halfGainL1 == true){adc2_halfGainL1 = false;}
847
848 if(pmt2Valid == false){multiplier = 2.0;}
849 if(adc1_halfGainL1 == true){score += 0.25;}
850 if(adc1_noGainL1 == true){score += 0.5;}
851 if(adc2_halfGainL1 == true){score += 0.25;}
852 if(adc2_noGainL1 == true){score += 0.5;}
853
854 return score * multiplier;
855 }
const CaloDetDescrElement * caloDDE() const
get pointer to CaloDetDescrElement (data member)
Definition CaloCell.h:321
IdentifierHash onl2() const
cell online identifier 2
IdentifierHash onl1() const
cell online identifier 1
bool isNoGainL1() const
bool isHalfGainL1() const
int gain2(void) const
get gain of second PMT
Definition TileCell.cxx:175
int gain1(void) const
get gain of first PMT
Definition TileCell.cxx:168
@ NOT_VALID_HASH
Definition TileHWID.h:314

◆ TileNonNominal() [2/2]

float LVL1::L1CaloOfflineTriggerTowerTools::TileNonNominal ( const std::vector< const CaloCell * > & cells) const
overrideprotectedvirtual

Implements LVL1::IL1CaloOfflineTriggerTowerTools.

Definition at line 783 of file L1CaloOfflineTriggerTowerTools.cxx.

783 {
784 float nonNominal(0.0);
785 for(Itr_vCaloCells i=cells.begin();i!=cells.end();++i){
786 nonNominal += this->TileNonNominal( (*i) );
787 }
788 return nonNominal;
789 }

◆ 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_cablingKey

SG::ReadCondHandleKey<LArOnOffIdMapping> LVL1::L1CaloOfflineTriggerTowerTools::m_cablingKey
private

Definition at line 268 of file L1CaloOfflineTriggerTowerTools.h.

◆ m_caloMgr

const CaloIdManager* LVL1::L1CaloOfflineTriggerTowerTools::m_caloMgr
private

Definition at line 257 of file L1CaloOfflineTriggerTowerTools.h.

◆ m_cells2tt

ToolHandle<LVL1::IL1CaloCells2TriggerTowers> LVL1::L1CaloOfflineTriggerTowerTools::m_cells2tt
private

Definition at line 256 of file L1CaloOfflineTriggerTowerTools.h.

◆ 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_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_isLArHVCorrToolSet

bool LVL1::L1CaloOfflineTriggerTowerTools::m_isLArHVCorrToolSet
private

Definition at line 265 of file L1CaloOfflineTriggerTowerTools.h.

◆ m_l1CaloTTIdTools

ToolHandle<LVL1::IL1CaloTTIdTools> LVL1::L1CaloOfflineTriggerTowerTools::m_l1CaloTTIdTools
private

Definition at line 255 of file L1CaloOfflineTriggerTowerTools.h.

◆ m_LArHVNonNomPara

double LVL1::L1CaloOfflineTriggerTowerTools::m_LArHVNonNomPara
private

Definition at line 266 of file L1CaloOfflineTriggerTowerTools.h.

◆ m_larOnlineID

const LArOnlineID* LVL1::L1CaloOfflineTriggerTowerTools::m_larOnlineID
private

Definition at line 261 of file L1CaloOfflineTriggerTowerTools.h.

◆ m_lvl1Helper

const CaloLVL1_ID* LVL1::L1CaloOfflineTriggerTowerTools::m_lvl1Helper
private

Definition at line 260 of file L1CaloOfflineTriggerTowerTools.h.

◆ m_onlineScaleCorrKey

SG::ReadCondHandleKey<ILArHVScaleCorr> LVL1::L1CaloOfflineTriggerTowerTools::m_onlineScaleCorrKey { this, "OnlineLArHVScaleCorr", "LArHVScaleCorr", "" }
private

Definition at line 277 of file L1CaloOfflineTriggerTowerTools.h.

278{ this, "OnlineLArHVScaleCorr", "LArHVScaleCorr", "" };

◆ m_rxMapTool

ToolHandle<LVL1::IL1CaloFcal23Cells2RxMappingTool> LVL1::L1CaloOfflineTriggerTowerTools::m_rxMapTool
private

Definition at line 275 of file L1CaloOfflineTriggerTowerTools.h.

◆ m_scaleCorrKey

SG::ReadCondHandleKey<ILArHVScaleCorr> LVL1::L1CaloOfflineTriggerTowerTools::m_scaleCorrKey
private

Definition at line 267 of file L1CaloOfflineTriggerTowerTools.h.

◆ m_scidtool

ToolHandle<ICaloSuperCellIDTool> LVL1::L1CaloOfflineTriggerTowerTools::m_scidtool
private

Definition at line 262 of file L1CaloOfflineTriggerTowerTools.h.

◆ m_tileBadChanTool

ToolHandle<ITileBadChanTool> LVL1::L1CaloOfflineTriggerTowerTools::m_tileBadChanTool
private

Definition at line 272 of file L1CaloOfflineTriggerTowerTools.h.

◆ m_tileHWID

const TileHWID* LVL1::L1CaloOfflineTriggerTowerTools::m_tileHWID
private

Definition at line 271 of file L1CaloOfflineTriggerTowerTools.h.

◆ m_ttOnlineIdHelper

const TTOnlineID* LVL1::L1CaloOfflineTriggerTowerTools::m_ttOnlineIdHelper
private

Definition at line 259 of file L1CaloOfflineTriggerTowerTools.h.

◆ m_ttSvc

ToolHandle<CaloTriggerTowerService> LVL1::L1CaloOfflineTriggerTowerTools::m_ttSvc
private

Definition at line 258 of file L1CaloOfflineTriggerTowerTools.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.


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