ATLAS Offline Software
Public Member Functions | Static Public Member Functions | Protected Member Functions | Private Types | Private Member Functions | Private Attributes | List of all members
LVL1::eFEXFPGA Class Reference

The eFEXFPGA class defines the structure of a single eFEX FPGA Its purpose is: More...

#include <eFEXFPGA.h>

Inheritance diagram for LVL1::eFEXFPGA:
Collaboration diagram for LVL1::eFEXFPGA:

Public Member Functions

 eFEXFPGA (const std::string &type, const std::string &name, const IInterface *parent)
 Constructors. More...
 
virtual StatusCode initialize () override
 standard Athena-Algorithm method More...
 
virtual ~eFEXFPGA ()
 Destructor. More...
 
virtual StatusCode init (int id, int efexid) override
 
virtual StatusCode execute (eFEXOutputCollection *inputOutputCollection) override
 
virtual void reset () override
 
virtual int getID () const override
 
virtual void SetTowersAndCells_SG (int[][6]) override
 
virtual void SetIsoWP (const std::vector< unsigned int > &, const std::vector< unsigned int > &, unsigned int &, unsigned int) const override
 
virtual std::vector< std::unique_ptr< eFEXegTOB > > getEmTOBs () override
 
virtual std::vector< std::unique_ptr< eFEXtauTOB > > getTauHeuristicTOBs () override
 
virtual std::vector< std::unique_ptr< eFEXtauTOB > > getTauBDTTOBs () override
 
ServiceHandle< StoreGateSvc > & evtStore ()
 The standard StoreGateSvc (event store) Returns (kind of) a pointer to the StoreGateSvc. More...
 
const ServiceHandle< StoreGateSvc > & evtStore () const
 The standard StoreGateSvc (event store) Returns (kind of) a pointer to the StoreGateSvc. More...
 
const ServiceHandle< StoreGateSvc > & detStore () const
 The standard StoreGateSvc/DetectorStore Returns (kind of) a pointer to the StoreGateSvc. More...
 
virtual StatusCode sysInitialize () override
 Perform system initialization for an algorithm. More...
 
virtual StatusCode sysStart () override
 Handle START transition. More...
 
virtual std::vector< Gaudi::DataHandle * > inputHandles () const override
 Return this algorithm's input handles. More...
 
virtual std::vector< Gaudi::DataHandle * > outputHandles () const override
 Return this algorithm's output handles. More...
 
Gaudi::Details::PropertyBase & declareProperty (Gaudi::Property< T > &t)
 
Gaudi::Details::PropertyBase * declareProperty (const std::string &name, SG::VarHandleKey &hndl, const std::string &doc, const SG::VarHandleKeyType &)
 Declare a new Gaudi property. More...
 
Gaudi::Details::PropertyBase * declareProperty (const std::string &name, SG::VarHandleBase &hndl, const std::string &doc, const SG::VarHandleType &)
 Declare a new Gaudi property. More...
 
Gaudi::Details::PropertyBase * declareProperty (const std::string &name, SG::VarHandleKeyArray &hndArr, const std::string &doc, const SG::VarHandleKeyArrayType &)
 
Gaudi::Details::PropertyBase * declareProperty (const std::string &name, T &property, const std::string &doc, const SG::NotHandleType &)
 Declare a new Gaudi property. More...
 
Gaudi::Details::PropertyBase * declareProperty (const std::string &name, T &property, const std::string &doc="none")
 Declare a new Gaudi property. More...
 
void updateVHKA (Gaudi::Details::PropertyBase &)
 
MsgStream & msg () const
 
MsgStream & msg (const MSG::Level lvl) const
 
bool msgLvl (const MSG::Level lvl) const
 

Static Public Member Functions

static const InterfaceID & interfaceID ()
 

Protected Member Functions

void renounceArray (SG::VarHandleKeyArray &handlesArray)
 remove all handles from I/O resolution More...
 
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. More...
 

Private Types

typedef ServiceHandle< StoreGateSvcStoreGateSvc_t
 

Private Member Functions

std::vector< std::unique_ptr< eFEXtauTOB > > getTauTOBs (std::vector< std::unique_ptr< eFEXtauTOB > > &tauTobObjects)
 
Gaudi::Details::PropertyBase & declareGaudiProperty (Gaudi::Property< T > &hndl, const SG::VarHandleKeyType &)
 specialization for handling Gaudi::Property<SG::VarHandleKey> More...
 
Gaudi::Details::PropertyBase & declareGaudiProperty (Gaudi::Property< T > &hndl, const SG::VarHandleKeyArrayType &)
 specialization for handling Gaudi::Property<SG::VarHandleKeyArray> More...
 
Gaudi::Details::PropertyBase & declareGaudiProperty (Gaudi::Property< T > &hndl, const SG::VarHandleType &)
 specialization for handling Gaudi::Property<SG::VarHandleBase> More...
 
Gaudi::Details::PropertyBase & declareGaudiProperty (Gaudi::Property< T > &t, const SG::NotHandleType &)
 specialization for handling everything that's not a Gaudi::Property<SG::VarHandleKey> or a <SG::VarHandleKeyArray> More...
 

Private Attributes

const unsigned int m_eFexStep = 25
 Internal data. More...
 
int m_id = 0
 
int m_efexid = 0
 
std::vector< std::unique_ptr< eFEXegTOB > > m_emTobObjects
 
std::vector< std::unique_ptr< eFEXtauTOB > > m_tauHeuristicTobObjects
 
std::vector< std::unique_ptr< eFEXtauTOB > > m_tauBDTTobObjects
 
int m_eTowersIDs [10][6] {}
 
SG::ReadHandleKey< TrigConf::L1Menum_l1MenuKey
 
SG::ReadHandleKey< LVL1::eTowerContainerm_eTowerContainerKey
 
ToolHandle< IeFEXtauAlgom_eFEXtauAlgoTool
 
ToolHandle< IeFEXtauAlgom_eFEXtauBDTAlgoTool
 
ToolHandle< IeFEXegAlgom_eFEXegAlgoTool
 
ToolHandle< IeFEXFormTOBsm_eFEXFormTOBsTool {this, "eFEXFormTOBs", "LVL1::eFEXFormTOBs", "Tool that creates eFEX TOB words"}
 
StoreGateSvc_t m_evtStore
 Pointer to StoreGate (event store by default) More...
 
StoreGateSvc_t m_detStore
 Pointer to StoreGate (detector store by default) More...
 
std::vector< SG::VarHandleKeyArray * > m_vhka
 
bool m_varHandleArraysDeclared
 

Detailed Description

The eFEXFPGA class defines the structure of a single eFEX FPGA Its purpose is:

Definition at line 39 of file eFEXFPGA.h.

Member Typedef Documentation

◆ StoreGateSvc_t

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

Definition at line 388 of file AthCommonDataStore.h.

Constructor & Destructor Documentation

◆ eFEXFPGA()

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

Constructors.

Definition at line 30 of file eFEXFPGA.cxx.

30  :
32 {
33  declareInterface<IeFEXFPGA>(this);
34 }

◆ ~eFEXFPGA()

LVL1::eFEXFPGA::~eFEXFPGA ( )
virtual

Destructor.

Definition at line 38 of file eFEXFPGA.cxx.

39  {
40  }

Member Function Documentation

◆ declareGaudiProperty() [1/4]

Gaudi::Details::PropertyBase& AthCommonDataStore< AthCommonMsg< AlgTool > >::declareGaudiProperty ( Gaudi::Property< T > &  hndl,
const SG::VarHandleKeyArrayType  
)
inlineprivateinherited

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

Definition at line 170 of file AthCommonDataStore.h.

172  {
173  return *AthCommonDataStore<PBASE>::declareProperty(hndl.name(),
174  hndl.value(),
175  hndl.documentation());
176 
177  }

◆ declareGaudiProperty() [2/4]

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

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

Definition at line 156 of file AthCommonDataStore.h.

158  {
159  return *AthCommonDataStore<PBASE>::declareProperty(hndl.name(),
160  hndl.value(),
161  hndl.documentation());
162 
163  }

◆ declareGaudiProperty() [3/4]

Gaudi::Details::PropertyBase& AthCommonDataStore< AthCommonMsg< AlgTool > >::declareGaudiProperty ( Gaudi::Property< T > &  hndl,
const SG::VarHandleType  
)
inlineprivateinherited

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

Definition at line 184 of file AthCommonDataStore.h.

186  {
187  return *AthCommonDataStore<PBASE>::declareProperty(hndl.name(),
188  hndl.value(),
189  hndl.documentation());
190  }

◆ declareGaudiProperty() [4/4]

Gaudi::Details::PropertyBase& AthCommonDataStore< AthCommonMsg< AlgTool > >::declareGaudiProperty ( Gaudi::Property< T > &  t,
const SG::NotHandleType  
)
inlineprivateinherited

specialization for handling everything that's not a Gaudi::Property<SG::VarHandleKey> or a <SG::VarHandleKeyArray>

Definition at line 199 of file AthCommonDataStore.h.

200  {
201  return PBASE::declareProperty(t);
202  }

◆ declareProperty() [1/6]

Gaudi::Details::PropertyBase* AthCommonDataStore< AthCommonMsg< AlgTool > >::declareProperty ( const std::string &  name,
SG::VarHandleBase hndl,
const std::string &  doc,
const SG::VarHandleType  
)
inlineinherited

Declare a new Gaudi property.

Parameters
nameName of the property.
hndlObject holding the property value.
docDocumentation string for the property.

This is the version for types that derive from SG::VarHandleBase. The property value object is put on the input and output lists as appropriate; then we forward to the base class.

Definition at line 245 of file AthCommonDataStore.h.

249  {
250  this->declare(hndl.vhKey());
251  hndl.vhKey().setOwner(this);
252 
253  return PBASE::declareProperty(name,hndl,doc);
254  }

◆ declareProperty() [2/6]

Gaudi::Details::PropertyBase* AthCommonDataStore< AthCommonMsg< AlgTool > >::declareProperty ( const std::string &  name,
SG::VarHandleKey hndl,
const std::string &  doc,
const SG::VarHandleKeyType  
)
inlineinherited

Declare a new Gaudi property.

Parameters
nameName of the property.
hndlObject holding the property value.
docDocumentation string for the property.

This is the version for types that derive from SG::VarHandleKey. The property value object is put on the input and output lists as appropriate; then we forward to the base class.

Definition at line 221 of file AthCommonDataStore.h.

225  {
226  this->declare(hndl);
227  hndl.setOwner(this);
228 
229  return PBASE::declareProperty(name,hndl,doc);
230  }

◆ declareProperty() [3/6]

Gaudi::Details::PropertyBase* AthCommonDataStore< AthCommonMsg< AlgTool > >::declareProperty ( const std::string &  name,
SG::VarHandleKeyArray hndArr,
const std::string &  doc,
const SG::VarHandleKeyArrayType  
)
inlineinherited

Definition at line 259 of file AthCommonDataStore.h.

263  {
264 
265  // std::ostringstream ost;
266  // ost << Algorithm::name() << " VHKA declareProp: " << name
267  // << " size: " << hndArr.keys().size()
268  // << " mode: " << hndArr.mode()
269  // << " vhka size: " << m_vhka.size()
270  // << "\n";
271  // debug() << ost.str() << endmsg;
272 
273  hndArr.setOwner(this);
274  m_vhka.push_back(&hndArr);
275 
276  Gaudi::Details::PropertyBase* p = PBASE::declareProperty(name, hndArr, doc);
277  if (p != 0) {
278  p->declareUpdateHandler(&AthCommonDataStore<PBASE>::updateVHKA, this);
279  } else {
280  ATH_MSG_ERROR("unable to call declareProperty on VarHandleKeyArray "
281  << name);
282  }
283 
284  return p;
285 
286  }

◆ declareProperty() [4/6]

Gaudi::Details::PropertyBase* AthCommonDataStore< AthCommonMsg< AlgTool > >::declareProperty ( const std::string &  name,
T &  property,
const std::string &  doc,
const SG::NotHandleType  
)
inlineinherited

Declare a new Gaudi property.

Parameters
nameName of the property.
propertyObject holding the property value.
docDocumentation string for the property.

This is the generic version, for types that do not derive from SG::VarHandleKey. It just forwards to the base class version of declareProperty.

Definition at line 333 of file AthCommonDataStore.h.

337  {
338  return PBASE::declareProperty(name, property, doc);
339  }

◆ declareProperty() [5/6]

Gaudi::Details::PropertyBase* AthCommonDataStore< AthCommonMsg< AlgTool > >::declareProperty ( const std::string &  name,
T &  property,
const std::string &  doc = "none" 
)
inlineinherited

Declare a new Gaudi property.

Parameters
nameName of the property.
propertyObject holding the property value.
docDocumentation string for the property.

This dispatches to either the generic declareProperty or the one for VarHandle/Key/KeyArray.

Definition at line 352 of file AthCommonDataStore.h.

355  {
356  typedef typename SG::HandleClassifier<T>::type htype;
357  return declareProperty (name, property, doc, htype());
358  }

◆ declareProperty() [6/6]

Gaudi::Details::PropertyBase& AthCommonDataStore< AthCommonMsg< AlgTool > >::declareProperty ( Gaudi::Property< T > &  t)
inlineinherited

Definition at line 145 of file AthCommonDataStore.h.

145  {
146  typedef typename SG::HandleClassifier<T>::type htype;
148  }

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

95 { return m_detStore; }

◆ evtStore() [1/2]

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.

85 { return m_evtStore; }

◆ evtStore() [2/2]

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

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

Definition at line 90 of file AthCommonDataStore.h.

90 { return m_evtStore; }

◆ execute()

StatusCode LVL1::eFEXFPGA::execute ( eFEXOutputCollection inputOutputCollection)
overridevirtual

Implements LVL1::IeFEXFPGA.

Definition at line 73 of file eFEXFPGA.cxx.

73  {
74  m_emTobObjects.clear();
76  m_tauBDTTobObjects.clear();
77 
79  if(!eTowerContainer.isValid()){
80  ATH_MSG_FATAL("Could not retrieve container " << m_eTowerContainerKey.key() );
81  return StatusCode::FAILURE;
82  }
83 
84  // Retrieve the L1 menu configuration
86  ATH_CHECK(l1Menu.isValid());
87 
88  auto & thr_eEM = l1Menu->thrExtraInfo().eEM();
89  auto & thr_eTAU = l1Menu->thrExtraInfo().eTAU();
90 
91  // Define eta range to consider extra towers in edge cases
92  int min_eta;
93  int overflow_eta;
94  if ((m_efexid%3 == 0) && (m_id == 0)) {
95  min_eta = 0;
96  } else {
97  min_eta = 1;
98  }
99  if ((m_efexid%3 == 2) && (m_id == 3)) {
100  overflow_eta = 6;
101  } else {
102  overflow_eta = 5;
103  }
104 
105  for(int ieta = min_eta; ieta < overflow_eta; ieta++) {
106  for(int iphi = 1; iphi < 9; iphi++) {
107 
108  int tobtable[3][3]={
109  {ieta > 0 ? m_eTowersIDs[iphi-1][ieta-1] : 0,
110  m_eTowersIDs[iphi-1][ieta],
111  ieta < 5 ? m_eTowersIDs[iphi-1][ieta+1] : 0},
112 
113  {ieta > 0 ? m_eTowersIDs[iphi][ieta-1] : 0,
114  m_eTowersIDs[iphi][ieta],
115  ieta < 5 ? m_eTowersIDs[iphi][ieta+1] : 0},
116 
117  {ieta > 0 ? m_eTowersIDs[iphi+1][ieta-1] : 0,
118  m_eTowersIDs[iphi+1][ieta],
119  ieta < 5 ? m_eTowersIDs[iphi+1][ieta+1] : 0},
120  };
121 
122 
123  ATH_CHECK( m_eFEXegAlgoTool->safetyTest() );
124  m_eFEXegAlgoTool->setup(tobtable, m_efexid, m_id, ieta);
125 
126  // ignore any tobs without a seed, move on to the next window
127  if (m_eFEXegAlgoTool->hasSeed() == false) continue;
128  unsigned int seed = m_eFEXegAlgoTool->getSeed();
129  unsigned int und = (m_eFEXegAlgoTool->getUnD() ? 1 : 0);
130 
131  // the minimum energy to send to topo (not eta dependent yet, but keep inside loop as it will be eventually?)
132  unsigned int ptMinToTopoCounts = thr_eEM.ptMinToTopoCounts();
133 
134  //returns a unsigned integer et value corresponding to the... eFEX EM cluster in 25 MeV internal calculation scale
135  unsigned int eEMTobEt = m_eFEXegAlgoTool->getET();
136 
137  // thresholds from Trigger menu
138  // the menu eta runs from -25 to 24
139  int menuEta = m_id*4 + (m_efexid%3)*16 + ieta - 25;
140  auto iso_loose = thr_eEM.isolation(TrigConf::Selection::WP::LOOSE, menuEta);
141  auto iso_medium = thr_eEM.isolation(TrigConf::Selection::WP::MEDIUM, menuEta);
142  auto iso_tight = thr_eEM.isolation(TrigConf::Selection::WP::TIGHT, menuEta);
143 
144  std::vector<unsigned int> threshReta;
145  threshReta.push_back(iso_loose.reta_fw());
146  threshReta.push_back(iso_medium.reta_fw());
147  threshReta.push_back(iso_tight.reta_fw());
148 
149  std::vector<unsigned int> threshRhad;
150  threshRhad.push_back(iso_loose.rhad_fw());
151  threshRhad.push_back(iso_medium.rhad_fw());
152  threshRhad.push_back(iso_tight.rhad_fw());
153 
154  std::vector<unsigned int> threshWstot;
155  threshWstot.push_back(iso_loose.wstot_fw());
156  threshWstot.push_back(iso_medium.wstot_fw());
157  threshWstot.push_back(iso_tight.wstot_fw());
158 
159  ATH_MSG_DEBUG("ieta=" << ieta << " loose => reta_fw=" << threshReta[0] << ", rhad_fw=" << threshRhad[0] << ", wstot_fw=" << threshWstot[0]);
160  ATH_MSG_DEBUG("ieta=" << ieta << " medium => reta_fw=" << threshReta[1] << ", rhad_fw=" << threshRhad[1] << ", wstot_fw=" << threshWstot[1]);
161  ATH_MSG_DEBUG("ieta=" << ieta << " tight => reta_fw=" << threshReta[2] << ", rhad_fw=" << threshRhad[2] << ", wstot_fw=" << threshWstot[2]);
162 
163  // Get Reta and Rhad outputs
164  std::vector<unsigned int> RetaCoreEnv;
165  m_eFEXegAlgoTool->getReta(RetaCoreEnv);
166  std::vector<unsigned int> RhadEMHad;
167  m_eFEXegAlgoTool->getRhad(RhadEMHad);
168  std::vector<unsigned int> WstotDenNum;
169  m_eFEXegAlgoTool->getWstot(WstotDenNum);
170 
171  // Set Reta, Rhad and Wstot WP
172  unsigned int RetaWP = 0;
173  unsigned int RhadWP = 0;
174  unsigned int WstotWP = 0;
175 
176  // bitshifts for the different iso vars
177  unsigned int RetaBitS = 3;
178  unsigned int RhadBitS = 3;
179  unsigned int WstotBitS = 5;
180 
181  unsigned int maxEtCountsEm = thr_eEM.maxEtCounts(m_eFexStep);
182  if (eEMTobEt >= maxEtCountsEm){
183  RetaWP = 3;
184  RhadWP = 3;
185  WstotWP = 3;
186  }
187  else{
188  SetIsoWP(RetaCoreEnv,threshReta,RetaWP,RetaBitS);
189  SetIsoWP(RhadEMHad,threshRhad,RhadWP,RhadBitS);
190  SetIsoWP(WstotDenNum,threshWstot,WstotWP,WstotBitS);
191  }
192  int eta_ind = ieta; // No need to offset eta index with new 0-5 convention
193  int phi_ind = iphi - 1;
194 
195  //form the egamma tob word and xTOB words
196  uint32_t tobword = m_eFEXFormTOBsTool->formEmTOBWord(m_id,eta_ind,phi_ind,RhadWP,WstotWP,RetaWP,seed,und,eEMTobEt,ptMinToTopoCounts);
197  std::vector<uint32_t> xtobwords = m_eFEXFormTOBsTool->formEmxTOBWords(m_efexid,m_id,eta_ind,phi_ind,RhadWP,WstotWP,RetaWP,seed,und,eEMTobEt,ptMinToTopoCounts);
198 
199  std::unique_ptr<eFEXegTOB> tmp_tob = m_eFEXegAlgoTool->geteFEXegTOB();
200 
201  tmp_tob->setFPGAID(m_id);
202  tmp_tob->seteFEXID(m_efexid);
203  tmp_tob->setEta(ieta);
204  tmp_tob->setPhi(iphi);
205  tmp_tob->setTobword(tobword);
206  tmp_tob->setxTobword0(xtobwords[0]);
207  tmp_tob->setxTobword1(xtobwords[1]);
208 
209  // for plotting
210  if (inputOutputCollection->getdooutput() && (tobword != 0) && (eEMTobEt != 0)) {
211  inputOutputCollection->addeFexNumber(m_efexid);
212  inputOutputCollection->addEMtob(tobword);
213  inputOutputCollection->addValue_eg("WstotNum", tmp_tob->getWstotNum());
214  inputOutputCollection->addValue_eg("WstotDen", tmp_tob->getWstotDen());
215  inputOutputCollection->addValue_eg("RetaNum", tmp_tob->getRetaCore());
216  inputOutputCollection->addValue_eg("RetaDen", tmp_tob->getRetaEnv());
217  inputOutputCollection->addValue_eg("RhadNum", tmp_tob->getRhadEM());
218  inputOutputCollection->addValue_eg("RhadDen", tmp_tob->getRhadHad());
219  inputOutputCollection->addValue_eg("haveSeed", m_eFEXegAlgoTool->hasSeed());
220  inputOutputCollection->addValue_eg("ET", m_eFEXegAlgoTool->getET());
221  float eta = 9999;
222  m_eFEXegAlgoTool->getRealEta(eta);
223  inputOutputCollection->addValue_eg("eta", eta);
224  float phi = 9999;
225  m_eFEXegAlgoTool->getRealPhi(phi);
226  inputOutputCollection->addValue_eg("phi", phi);
227  unsigned int em_et = 9999;
228  m_eFEXegAlgoTool->getCoreEMTowerET(em_et);
229  inputOutputCollection->addValue_eg("em", em_et);
230  unsigned int had_et = 9999;
231  m_eFEXegAlgoTool->getCoreHADTowerET(had_et);
232  inputOutputCollection->addValue_eg("had", had_et);
233  inputOutputCollection->fill_eg();
234  }
235 
236  // Now we've finished with that object we can move it into the class results store
237  if ( (tobword != 0) && (eEMTobEt != 0) ) m_emTobObjects.push_back(std::move(tmp_tob));
238 
239  }
240  }
241 
242  // --------------- TAU -------------
243  for(int ieta = min_eta; ieta < overflow_eta; ieta++)
244  {
245  for(int iphi = 1; iphi < 9; iphi++)
246  {
247  int tobtable[3][3]={
248  {ieta > 0 ? m_eTowersIDs[iphi-1][ieta-1] : 0,
249  m_eTowersIDs[iphi-1][ieta],
250  ieta < 5 ? m_eTowersIDs[iphi-1][ieta+1] : 0},
251 
252  {ieta > 0 ? m_eTowersIDs[iphi][ieta-1] : 0,
253  m_eTowersIDs[iphi][ieta],
254  ieta < 5 ? m_eTowersIDs[iphi][ieta+1] : 0},
255 
256  {ieta > 0 ? m_eTowersIDs[iphi+1][ieta-1] : 0,
257  m_eTowersIDs[iphi+1][ieta],
258  ieta < 5 ? m_eTowersIDs[iphi+1][ieta+1] : 0},
259  };
260 
261  ATH_CHECK( m_eFEXtauAlgoTool->safetyTest() );
262  ATH_CHECK( m_eFEXtauBDTAlgoTool->safetyTest() );
263  m_eFEXtauAlgoTool->setup(tobtable, m_efexid, m_id, ieta);
264  m_eFEXtauBDTAlgoTool->setup(tobtable, m_efexid, m_id, ieta);
265 
266  if ( m_eFEXtauAlgoTool->isCentralTowerSeed() != m_eFEXtauBDTAlgoTool->isCentralTowerSeed() )
267  {
268  ATH_MSG_FATAL("BDT tau algo and heuristic tau algo should agree on seeding for all TOBs");
269  return StatusCode::FAILURE;
270  }
271 
272  if (!m_eFEXtauAlgoTool->isCentralTowerSeed()){ continue; }
273 
274  // the minimum energy to send to topo (not eta dependent yet, but keep inside loop as it will be eventually?)
275  unsigned int ptTauMinToTopoCounts = thr_eTAU.ptMinToTopoCounts();
276 
277  unsigned int ptTauMinToTopoInEfexCounts = TrigConf::energyInCounts(thr_eTAU.ptMinToTopoMeV(), m_eFexStep);
278 
279  // Get Et of eFEX tau object in internal units (25 MeV)
280  unsigned int eTauTobEt = m_eFEXtauAlgoTool->getEt();
281  unsigned int eTauBDTTobEt = m_eFEXtauBDTAlgoTool->getEt();
282 
283  // thresholds from Trigger menu
284  // the menu eta runs from -25 to 24
285  int menuEta = m_id*4 + (m_efexid%3)*16 + ieta - 25;
286  auto iso_loose = thr_eTAU.isolation(TrigConf::Selection::WP::LOOSE, menuEta);
287  auto iso_medium = thr_eTAU.isolation(TrigConf::Selection::WP::MEDIUM, menuEta);
288  auto iso_tight = thr_eTAU.isolation(TrigConf::Selection::WP::TIGHT, menuEta);
289 
290  std::vector<unsigned int> threshRCore;
291  threshRCore.push_back(iso_loose.rCore_fw());
292  threshRCore.push_back(iso_medium.rCore_fw());
293  threshRCore.push_back(iso_tight.rCore_fw());
294 
295  std::vector<unsigned int> threshRHad;
296  threshRHad.push_back(iso_loose.rHad_fw());
297  threshRHad.push_back(iso_medium.rHad_fw());
298  threshRHad.push_back(iso_tight.rHad_fw());
299 
300  // Get isolation values
301  std::vector<unsigned int> rCoreVec;
302  m_eFEXtauAlgoTool->getRCore(rCoreVec);
303 
304  std::vector<unsigned int> rHadVec;
305  m_eFEXtauAlgoTool->getRHad(rHadVec);
306 
307  // BDT-based tau algorithm outputs (both 0 for heuristic algorithm)
308  unsigned int bdtScore = 0;
309  unsigned int bdtCondition = 0;
310  unsigned int bdtRHadWP = 0;
311 
312  // Set isolation WP
313  unsigned int rCoreWP = 0;
314  unsigned int rHadWP = 0;
315 
316  // Isolation bitshift value
317  unsigned int RcoreBitS = 3;
318  unsigned int RhadBitS = 3;
319 
320  unsigned int maxEtCountsTau = thr_eTAU.maxEtCounts(m_eFexStep);
321  unsigned int bdtMinEtCounts = thr_eTAU.minIsoEtCounts(m_eFexStep);
322  if (eTauTobEt >= maxEtCountsTau) {
323  rCoreWP = 3;
324  rHadWP = 3;
325  } else {
326  SetIsoWP(rCoreVec,threshRCore,rCoreWP,RcoreBitS);
327  SetIsoWP(rHadVec,threshRHad,rHadWP,RhadBitS);
328  }
329 
330  // Only one tau algorithm may be active and this is controlled by the L1 menu.
331  // When the BDT algorithm is active, the rCore field contains the BDT L/M/T thresholds.
332  std::vector<unsigned int> threshBDT;
333  threshBDT.push_back(iso_loose.rCore_fw());
334  threshBDT.push_back(iso_medium.rCore_fw());
335  threshBDT.push_back(iso_tight.rCore_fw());
336  m_eFEXtauBDTAlgoTool->setThresholds(threshRHad, threshBDT, ptTauMinToTopoInEfexCounts, maxEtCountsTau, bdtMinEtCounts);
337  // Re-compute after setting thresholds.
338  // Threshold bits in the BDT algorithm's implementation are computed inside the algorithm class
339  m_eFEXtauBDTAlgoTool->compute();
340  eTauBDTTobEt = m_eFEXtauBDTAlgoTool->getEt();
341  bdtScore = m_eFEXtauBDTAlgoTool->getBDTScore();
342  bdtCondition = m_eFEXtauBDTAlgoTool->getBDTCondition();
343  bdtRHadWP = m_eFEXtauBDTAlgoTool->getBDTHadFracCondition();
344 
345  unsigned int seed = m_eFEXtauAlgoTool->getSeed();
346  // Heuristic seed as returned is supercell value within 3x3 area, here want it within central cell
347  seed = seed - 4;
348 
349  unsigned int und = (m_eFEXtauAlgoTool->getUnD() ? 1 : 0);
350 
351  unsigned int bdtSeed = m_eFEXtauBDTAlgoTool->getSeed();
352 
353  int eta_ind = ieta; // No need to offset eta index with new 0-5 convention
354  int phi_ind = iphi - 1;
355 
356  // Form the tau TOB word and xTOB words
357  std::vector<uint32_t> xtobwords;
358  std::vector<uint32_t> xtobwordsBDT;
359 
360  ATH_MSG_DEBUG("m_id: " << m_id << ", eta_ind: " << eta_ind << ", phi_ind: "
361  << phi_ind << ", eTauBDTTobEt: " << eTauBDTTobEt
362  << ", eTauTobEt: " << eTauTobEt << ", ptTauMinToTopoCounts: "
363  << ptTauMinToTopoCounts << ", maxEtCountsTau: " << maxEtCountsTau
364  << ", bdtScore: " << bdtScore << " bdtMinEtCounts: " << bdtMinEtCounts << " bdtRHadWP " << bdtRHadWP);
365 
366  uint32_t tobwordBDT = m_eFEXFormTOBsTool->formTauBDTTOBWord(m_id, eta_ind, phi_ind, eTauBDTTobEt, bdtRHadWP, bdtCondition, bdtSeed, ptTauMinToTopoCounts);
367  xtobwordsBDT = m_eFEXFormTOBsTool->formTauBDTxTOBWords(m_efexid, m_id, eta_ind, phi_ind, eTauBDTTobEt, bdtRHadWP, bdtCondition, bdtSeed, ptTauMinToTopoCounts, bdtScore);
368  uint32_t tobword = m_eFEXFormTOBsTool->formTauTOBWord(m_id, eta_ind, phi_ind, eTauTobEt, rHadWP, rCoreWP, seed, und, ptTauMinToTopoCounts);
369  xtobwords = m_eFEXFormTOBsTool->formTauxTOBWords(m_efexid, m_id, eta_ind, phi_ind, eTauTobEt, rHadWP, rCoreWP, seed, und, ptTauMinToTopoCounts);
370 
371  std::unique_ptr<eFEXtauTOB> tmp_tau_tob = m_eFEXtauAlgoTool->getTauTOB();
372  tmp_tau_tob->setFPGAID(m_id);
373  tmp_tau_tob->seteFEXID(m_efexid);
374  tmp_tau_tob->setEta(ieta);
375  tmp_tau_tob->setPhi(iphi);
376  tmp_tau_tob->setTobword(tobword);
377  tmp_tau_tob->setxTobword0(xtobwords[0]);
378  tmp_tau_tob->setxTobword1(xtobwords[1]);
379 
380  std::unique_ptr<eFEXtauTOB> tmp_tau_tob_bdt = m_eFEXtauBDTAlgoTool->getTauTOB();
381  tmp_tau_tob_bdt->setFPGAID(m_id);
382  tmp_tau_tob_bdt->seteFEXID(m_efexid);
383  tmp_tau_tob_bdt->setEta(ieta);
384  tmp_tau_tob_bdt->setPhi(iphi);
385  tmp_tau_tob_bdt->setTobword(tobwordBDT);
386  tmp_tau_tob_bdt->setxTobword0(xtobwordsBDT[0]);
387  tmp_tau_tob_bdt->setxTobword1(xtobwordsBDT[1]);
388 
389  // for plotting
390  if ((inputOutputCollection->getdooutput()) && ( tobword != 0 )) {
391  inputOutputCollection->addValue_tau("isCentralTowerSeed", m_eFEXtauAlgoTool->isCentralTowerSeed());
392  inputOutputCollection->addValue_tau("Et", m_eFEXtauAlgoTool->getEt());
393  inputOutputCollection->addValue_tau("EtBDT", m_eFEXtauBDTAlgoTool->getEt());
394  inputOutputCollection->addValue_tau("Eta", ieta);
395  inputOutputCollection->addValue_tau("Phi", iphi);
396  const LVL1::eTower * centerTower = eTowerContainer->findTower(m_eTowersIDs[iphi][ieta]);
397  const LVL1::eTower * oneOffEtaTower = ieta < 5 ? eTowerContainer->findTower(m_eTowersIDs[iphi][ieta+1]) : nullptr;
398  const LVL1::eTower * oneBelowEtaTower = ieta > 0 ? eTowerContainer->findTower(m_eTowersIDs[iphi][ieta-1]) : nullptr;
399  inputOutputCollection->addValue_tau("CenterTowerEt", centerTower->getTotalET());
400  inputOutputCollection->addValue_tau("OneOffEtaTowerEt", oneOffEtaTower ? oneOffEtaTower->getTotalET() : 0);
401  inputOutputCollection->addValue_tau("OneBelowEtaTowerEt", oneBelowEtaTower ? oneBelowEtaTower->getTotalET() : 0);
402  inputOutputCollection->addValue_tau("FloatEta", centerTower->eta() * centerTower->getPosNeg());
403  inputOutputCollection->addValue_tau("FloatPhi", centerTower->phi());
404  inputOutputCollection->addValue_tau("RCoreCore", rCoreVec[0]);
405  inputOutputCollection->addValue_tau("RCoreEnv", rCoreVec[1]);
406  inputOutputCollection->addValue_tau("RealRCore", m_eFEXtauAlgoTool->getRealRCore());
407  inputOutputCollection->addValue_tau("RCoreWP", rCoreWP);
408  inputOutputCollection->addValue_tau("RHadCore", rHadVec[0]);
409  inputOutputCollection->addValue_tau("RHadEnv", rHadVec[1]);
410  inputOutputCollection->addValue_tau("RealRHad", m_eFEXtauAlgoTool->getRealRHad());
411  inputOutputCollection->addValue_tau("RealRHadBDT", m_eFEXtauBDTAlgoTool->getRealRHad());
412  inputOutputCollection->addValue_tau("RHadWP", rHadWP);
413  inputOutputCollection->addValue_tau("Seed", seed);
414  inputOutputCollection->addValue_tau("UnD", und);
415  inputOutputCollection->addValue_tau("BDTScore", bdtScore);
416  inputOutputCollection->addValue_tau("BDTCondition", bdtCondition);
417  inputOutputCollection->addValue_tau("eFEXID", m_efexid);
418  inputOutputCollection->addValue_tau("FPGAID", m_id);
419 
420 
421  inputOutputCollection->fill_tau();
422  }
423  // Now we've finished with that object we can move it into the class results store
424  if ( tobword != 0 ) m_tauHeuristicTobObjects.push_back(std::move(tmp_tau_tob));
425  if ( tobwordBDT != 0 ) m_tauBDTTobObjects.push_back(std::move(tmp_tau_tob_bdt));
426 
427  }
428  }
429 
430  return StatusCode::SUCCESS;
431 }

◆ 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

◆ getEmTOBs()

std::vector< std::unique_ptr< eFEXegTOB > > LVL1::eFEXFPGA::getEmTOBs ( )
overridevirtual

Implements LVL1::IeFEXFPGA.

Definition at line 435 of file eFEXFPGA.cxx.

436 {
437  // TOB sorting moved to eFEXSysSim to simplify xTOB production
438  // But leave this here in case more subtle requirement is uncovered in future
439  /*
440  auto tobsSort = m_emTobObjects;
441 
442  ATH_MSG_DEBUG("number of tobs: " <<tobsSort.size() << " in FPGA: " << m_id << " before truncation");
443 
444  // sort tobs by their et (last 12 bits of the 32 bit tob word)
445  std::sort (tobsSort.begin(), tobsSort.end(), TOBetSort<eFEXegTOB>);
446 
447  // return the top 6 highest ET TOBs from the FPGA
448  if (tobsSort.size() > 6) tobsSort.resize(6);
449  return tobsSort;
450  */
451 
452  /* Returning a vector of unique_pointers means this class will lose ownership.
453  This shouldn't be an issue since all this class does is create and return the
454  objects, but you should bear it in mind if you make changes */
455 
456  // This copy seems to be needed - it won't let me pass m_emTobOjects directly (to do with being a class member?)
457  std::vector<std::unique_ptr<eFEXegTOB>> tobsSort;
458  for(auto &j : m_emTobObjects){
459  tobsSort.push_back(std::move(j));
460  }
461 
462  return tobsSort;
463 }

◆ getID()

virtual int LVL1::eFEXFPGA::getID ( ) const
inlineoverridevirtual

Implements LVL1::IeFEXFPGA.

Definition at line 53 of file eFEXFPGA.h.

53 {return m_id;}

◆ getTauBDTTOBs()

std::vector< std::unique_ptr< eFEXtauTOB > > LVL1::eFEXFPGA::getTauBDTTOBs ( )
overridevirtual

Implements LVL1::IeFEXFPGA.

Definition at line 500 of file eFEXFPGA.cxx.

501 {
503 }

◆ getTauHeuristicTOBs()

std::vector< std::unique_ptr< eFEXtauTOB > > LVL1::eFEXFPGA::getTauHeuristicTOBs ( )
overridevirtual

Implements LVL1::IeFEXFPGA.

Definition at line 495 of file eFEXFPGA.cxx.

496 {
498 }

◆ getTauTOBs()

std::vector< std::unique_ptr< eFEXtauTOB > > LVL1::eFEXFPGA::getTauTOBs ( std::vector< std::unique_ptr< eFEXtauTOB > > &  tauTobObjects)
private

Definition at line 465 of file eFEXFPGA.cxx.

466 {
467  // TOB sorting moved to eFEXSysSim to simplify xTOB production
468  // But leave this here in case more subtle requirement is uncovered in future
469  /*
470  auto tobsSort = tauTobObjects;
471 
472  ATH_MSG_DEBUG("number of tobs: " <<tobsSort.size() << " in FPGA: " << m_id << " before truncation");
473 
474  // sort tobs by their et (last 12 bits of the 32 bit tob word)
475  std::sort (tobsSort.begin(), tobsSort.end(), TOBetSort<eFEXtauTOB>);
476 
477  // return the top 6 highest ET TOBs from the FPGA
478  if (tobsSort.size() > 6) tobsSort.resize(6);
479  return tobsSort;
480  */
481 
482  /* Returning a vector of unique_pointers means this class will lose ownership.
483  This shouldn't be an issue since all this class does is create and return the
484  objects, but you should bear it in mind if you make changes */
485 
486  // This copy seems to be needed - it won't let me pass m_tauTobOjects directly (to do with being a class member?)
487  std::vector<std::unique_ptr<eFEXtauTOB>> tobsSort;
488  for(auto &j : tauTobObjects){
489  tobsSort.push_back(std::move(j));
490  }
491 
492  return tobsSort;
493 }

◆ init()

StatusCode LVL1::eFEXFPGA::init ( int  id,
int  efexid 
)
overridevirtual

Implements LVL1::IeFEXFPGA.

Definition at line 59 of file eFEXFPGA.cxx.

60 {
61  m_id = id;
62  m_efexid = efexid;
63 
64  return StatusCode::SUCCESS;
65 }

◆ initialize()

StatusCode LVL1::eFEXFPGA::initialize ( )
overridevirtual

standard Athena-Algorithm method

Definition at line 44 of file eFEXFPGA.cxx.

45 {
46 
48  ATH_CHECK( m_eFEXegAlgoTool.retrieve() );
49  ATH_CHECK( m_eFEXtauAlgoTool.retrieve() );
50  ATH_CHECK( m_eFEXtauBDTAlgoTool.retrieve() );
51 
52 
54 
55  return StatusCode::SUCCESS;
56 }

◆ inputHandles()

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

Return this algorithm's input handles.

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

◆ interfaceID()

const InterfaceID & LVL1::IeFEXFPGA::interfaceID ( )
inlinestaticinherited

Definition at line 58 of file IeFEXFPGA.h.

59  {
60  return IID_IeFEXFPGA;
61  }

◆ msg() [1/2]

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

Definition at line 24 of file AthCommonMsg.h.

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

◆ msg() [2/2]

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

Definition at line 27 of file AthCommonMsg.h.

27  {
28  return this->msgStream(lvl);
29  }

◆ msgLvl()

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

Definition at line 30 of file AthCommonMsg.h.

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

◆ outputHandles()

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

Return this algorithm's output handles.

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

◆ 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();
383  PBASE::renounce (h);
384  }

◆ 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  {
365  handlesArray.renounce();
366  }

◆ reset()

void LVL1::eFEXFPGA::reset ( )
overridevirtual

Implements LVL1::IeFEXFPGA.

Definition at line 67 of file eFEXFPGA.cxx.

67  {
68 
69  m_id = -1;
70  m_efexid = -1;
71 }

◆ SetIsoWP()

void LVL1::eFEXFPGA::SetIsoWP ( const std::vector< unsigned int > &  CoreEnv,
const std::vector< unsigned int > &  thresholds,
unsigned int &  workingPoint,
unsigned int  bitshift 
) const
overridevirtual

Implements LVL1::IeFEXFPGA.

Definition at line 550 of file eFEXFPGA.cxx.

550  {
551  // Working point evaluted by Core * 2^bitshift > Threshold * Environment conditions
552  std::unordered_map<unsigned int, unsigned int> bsmap { {3, 8}, {5, 32}};
553 
554  // if core (denom) has overflowed, automatically pass all thresholds
555  if (CoreEnv[0] > 0xffff) {
556  workingPoint = 3;
557  return;
558  }
559 
560  unsigned int large = CoreEnv[0]*bsmap[bitshift]; // core
561  unsigned int small = CoreEnv[1]; // env
562 
563  // Word length conditions
564  if (large > 0xffff ) large = 0xffff;
565  if (small > 0xffff ) small = 0xffff;
566 
567  // Fail all if env sum overflows
568  if (small == 0xffff) {
569  workingPoint = 0;
570  return;
571  }
572 
573  // Otherwise test thresholds in firmware order
574  // i.e. check lowest threshold failed rather than highest passed
575  if ( large < small*thresholds[0] ) {
576  workingPoint = 0;
577  return;
578  }
579  if ( large < small*thresholds[1] ) {
580  workingPoint = 1;
581  return;
582  }
583  if ( large < small*thresholds[2] ) {
584  workingPoint = 2;
585  return;
586  }
587  workingPoint = 3;
588  return;
589 }

◆ SetTowersAndCells_SG()

void LVL1::eFEXFPGA::SetTowersAndCells_SG ( int  tmp_eTowersIDs_subset[][6])
overridevirtual

Implements LVL1::IeFEXFPGA.

Definition at line 505 of file eFEXFPGA.cxx.

505  {
506 
507  int rows = 10;
508  int cols = sizeof tmp_eTowersIDs_subset[0] / sizeof tmp_eTowersIDs_subset[0][0];
509 
510  std::copy(&tmp_eTowersIDs_subset[0][0], &tmp_eTowersIDs_subset[0][0]+(10*6),&m_eTowersIDs[0][0]);
511 
512  if(false){ //this prints out the eTower IDs that each FPGA is responsible for
513  ATH_MSG_DEBUG("\n---- eFEXFPGA --------- eFEX (" << m_efexid << " ----- FPGA (" << m_id << ") IS RESPONSIBLE FOR eTOWERS :");
514  for (int thisRow=rows-1; thisRow>=0; thisRow--){
515  for (int thisCol=0; thisCol<cols; thisCol++){
516  if(thisCol != cols-1){ ATH_MSG_DEBUG("| " << m_eTowersIDs[thisRow][thisCol] << " "); }
517  else { ATH_MSG_DEBUG("| " << m_eTowersIDs[thisRow][thisCol] << " |"); }
518  }
519  }
520  }
521 
522 
523  //-----------------------------------------------------------
524  // Set up a the second CSV file if necessary (should only need to be done if the mapping changes, which should never happen unless major changes to the simulation are required)
525  if(false){ // CSV CODE TO BE RE-INTRODUCED VERY SOON
527  if(!eTowerContainer.isValid()){
528  ATH_MSG_FATAL("Could not retrieve container " << m_eTowerContainerKey.key() );
529  }
530 
531  std::ofstream tower_fpga_efex_map;
532  tower_fpga_efex_map.open ("./tower_fpga_efex_map.csv", std::ios_base::app);
533 
534  for (int thisRow=rows-1; thisRow>=0; thisRow--){
535  for (int thisCol=0; thisCol<cols; thisCol++){
536 
537  const LVL1::eTower * tmpTower = eTowerContainer->findTower(m_eTowersIDs[thisRow][thisCol]);
538 
539  tower_fpga_efex_map << m_efexid << "," << m_id << "," << m_eTowersIDs[thisRow][thisCol] << "," << tmpTower->eta() << "," << tmpTower->phi() << "\n";
540 
541  }
542  }
543  }
544  //------------------------------------------------------------
545 
546 
547 }

◆ 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 DerivationFramework::CfAthAlgTool, AthCheckedComponent< AthAlgTool >, AthCheckedComponent<::AthAlgTool >, and asg::AsgMetadataTool.

◆ sysStart()

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

Handle START transition.

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

◆ updateVHKA()

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

Definition at line 308 of file AthCommonDataStore.h.

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

Member Data Documentation

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

ToolHandle<IeFEXegAlgo> LVL1::eFEXFPGA::m_eFEXegAlgoTool
private
Initial value:
{
this, "eFEXegAlgoTool", "LVL1::eFEXegAlgo",
"Tool that runs the eFEX e/gamma algorithm"}

Definition at line 92 of file eFEXFPGA.h.

◆ m_eFEXFormTOBsTool

ToolHandle<IeFEXFormTOBs> LVL1::eFEXFPGA::m_eFEXFormTOBsTool {this, "eFEXFormTOBs", "LVL1::eFEXFormTOBs", "Tool that creates eFEX TOB words"}
private

Definition at line 96 of file eFEXFPGA.h.

◆ m_efexid

int LVL1::eFEXFPGA::m_efexid = 0
private

Definition at line 70 of file eFEXFPGA.h.

◆ m_eFexStep

const unsigned int LVL1::eFEXFPGA::m_eFexStep = 25
private

Internal data.

Definition at line 67 of file eFEXFPGA.h.

◆ m_eFEXtauAlgoTool

ToolHandle<IeFEXtauAlgo> LVL1::eFEXFPGA::m_eFEXtauAlgoTool
private
Initial value:
{
this, "eFEXtauAlgoTool", "LVL1::eFEXtauAlgo",
"Tool that runs the eFEX tau algorithm"}

Definition at line 84 of file eFEXFPGA.h.

◆ m_eFEXtauBDTAlgoTool

ToolHandle<IeFEXtauAlgo> LVL1::eFEXFPGA::m_eFEXtauBDTAlgoTool
private
Initial value:
{
this, "eFEXtauBDTAlgoTool", "LVL1::eFEXtauBDTAlgo",
"Tool that runs the eFEX BDT tau algorithm"}

Definition at line 88 of file eFEXFPGA.h.

◆ m_emTobObjects

std::vector< std::unique_ptr<eFEXegTOB> > LVL1::eFEXFPGA::m_emTobObjects
private

Definition at line 71 of file eFEXFPGA.h.

◆ m_eTowerContainerKey

SG::ReadHandleKey<LVL1::eTowerContainer> LVL1::eFEXFPGA::m_eTowerContainerKey
private
Initial value:
{
this, "MyETowers", "eTowerContainer",
"Input container for eTowers"}

Definition at line 80 of file eFEXFPGA.h.

◆ m_eTowersIDs

int LVL1::eFEXFPGA::m_eTowersIDs[10][6] {}
private

Definition at line 74 of file eFEXFPGA.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_id

int LVL1::eFEXFPGA::m_id = 0
private

Definition at line 69 of file eFEXFPGA.h.

◆ m_l1MenuKey

SG::ReadHandleKey<TrigConf::L1Menu> LVL1::eFEXFPGA::m_l1MenuKey
private
Initial value:
{
this, "L1TriggerMenu", "DetectorStore+L1TriggerMenu",
"Name of the L1Menu object to read configuration from"}

Definition at line 76 of file eFEXFPGA.h.

◆ m_tauBDTTobObjects

std::vector< std::unique_ptr<eFEXtauTOB> > LVL1::eFEXFPGA::m_tauBDTTobObjects
private

Definition at line 73 of file eFEXFPGA.h.

◆ m_tauHeuristicTobObjects

std::vector< std::unique_ptr<eFEXtauTOB> > LVL1::eFEXFPGA::m_tauHeuristicTobObjects
private

Definition at line 72 of file eFEXFPGA.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:
eTowerContainer
Container class for eTower.
TrigConf::Selection::WP::LOOSE
@ LOOSE
test_pyathena.eta
eta
Definition: test_pyathena.py:10
ATH_MSG_FATAL
#define ATH_MSG_FATAL(x)
Definition: AthMsgStreamMacros.h:34
LVL1::eTower::getTotalET
int getTotalET() const
Get ET sum of all cells in the eTower in MeV.
Definition: eTower.cxx:194
LVL1::eTower
The eTower class is an interface object for eFEX trigger algorithms The purposes are twofold:
Definition: eTower.h:38
LVL1::eFEXFPGA::m_eFEXegAlgoTool
ToolHandle< IeFEXegAlgo > m_eFEXegAlgoTool
Definition: eFEXFPGA.h:92
xAOD::uint32_t
setEventNumber uint32_t
Definition: EventInfo_v1.cxx:127
LVL1::eFEXFPGA::getTauTOBs
std::vector< std::unique_ptr< eFEXtauTOB > > getTauTOBs(std::vector< std::unique_ptr< eFEXtauTOB > > &tauTobObjects)
Definition: eFEXFPGA.cxx:465
SG::ReadHandle
Definition: StoreGate/StoreGate/ReadHandle.h:70
AthCommonDataStore::declareProperty
Gaudi::Details::PropertyBase & declareProperty(Gaudi::Property< T > &t)
Definition: AthCommonDataStore.h:145
LVL1::eFEXFPGA::m_eFEXtauBDTAlgoTool
ToolHandle< IeFEXtauAlgo > m_eFEXtauBDTAlgoTool
Definition: eFEXFPGA.h:88
LVL1::eFEXFPGA::m_id
int m_id
Definition: eFEXFPGA.h:69
AthCommonDataStore< AthCommonMsg< AlgTool > >::m_evtStore
StoreGateSvc_t m_evtStore
Pointer to StoreGate (event store by default)
Definition: AthCommonDataStore.h:390
LVL1::eTower::getPosNeg
int getPosNeg() const
Definition: eTower.h:121
AthCommonDataStore< AthCommonMsg< AlgTool > >::m_vhka
std::vector< SG::VarHandleKeyArray * > m_vhka
Definition: AthCommonDataStore.h:398
LVL1::eFEXFPGA::m_tauBDTTobObjects
std::vector< std::unique_ptr< eFEXtauTOB > > m_tauBDTTobObjects
Definition: eFEXFPGA.h:73
read_hist_ntuple.t
t
Definition: read_hist_ntuple.py:5
SG::VarHandleKey::key
const std::string & key() const
Return the StoreGate ID for the referenced object.
Definition: AthToolSupport/AsgDataHandles/Root/VarHandleKey.cxx:141
LVL1::eFEXFPGA::m_l1MenuKey
SG::ReadHandleKey< TrigConf::L1Menu > m_l1MenuKey
Definition: eFEXFPGA.h:76
LVL1::eFEXFPGA::m_emTobObjects
std::vector< std::unique_ptr< eFEXegTOB > > m_emTobObjects
Definition: eFEXFPGA.h:71
LVL1::eFEXFPGA::m_eFEXtauAlgoTool
ToolHandle< IeFEXtauAlgo > m_eFEXtauAlgoTool
Definition: eFEXFPGA.h:84
SG::VarHandleKeyArray::setOwner
virtual void setOwner(IDataHandleHolder *o)=0
IDTPMcnv.htype
htype
Definition: IDTPMcnv.py:29
xAOD::phi
setEt phi
Definition: TrigEMCluster_v1.cxx:29
LVL1::eFEXFPGA::m_eFexStep
const unsigned int m_eFexStep
Internal data.
Definition: eFEXFPGA.h:67
beamspotnt.cols
list cols
Definition: bin/beamspotnt.py:1114
python.utils.AtlRunQueryDQUtils.p
p
Definition: AtlRunQueryDQUtils.py:210
AthCommonDataStore
Definition: AthCommonDataStore.h:52
Generate_dsid_ranseed.seed
seed
Definition: Generate_dsid_ranseed.py:10
ATH_MSG_ERROR
#define ATH_MSG_ERROR(x)
Definition: AthMsgStreamMacros.h:33
LVL1::eTower::phi
float phi() const
Definition: eTower.h:65
ATH_MSG_DEBUG
#define ATH_MSG_DEBUG(x)
Definition: AthMsgStreamMacros.h:29
LVL1::eFEXFPGA::m_eFEXFormTOBsTool
ToolHandle< IeFEXFormTOBs > m_eFEXFormTOBsTool
Definition: eFEXFPGA.h:96
test_pyathena.parent
parent
Definition: test_pyathena.py:15
ATH_CHECK
#define ATH_CHECK
Definition: AthCheckMacros.h:40
beamspotnt.rows
list rows
Definition: bin/beamspotnt.py:1112
AthCommonDataStore< AthCommonMsg< AlgTool > >::m_detStore
StoreGateSvc_t m_detStore
Pointer to StoreGate (detector store by default)
Definition: AthCommonDataStore.h:393
SG::VarHandleKey::initialize
StatusCode initialize(bool used=true)
If this object is used as a property, then this should be called during the initialize phase.
Definition: AthToolSupport/AsgDataHandles/Root/VarHandleKey.cxx:103
AthAlgTool::AthAlgTool
AthAlgTool()
Default constructor:
SG::VarHandleKeyArray::renounce
virtual void renounce()=0
SG::HandleClassifier::type
std::conditional< std::is_base_of< SG::VarHandleKeyArray, T >::value, VarHandleKeyArrayType, type2 >::type type
Definition: HandleClassifier.h:54
LVL1::eFEXFPGA::m_eTowersIDs
int m_eTowersIDs[10][6]
Definition: eFEXFPGA.h:74
TrigConf::energyInCounts
unsigned int energyInCounts(unsigned int energyMeV, unsigned int energyResolutionMeV)
helper funtion to translate energies into counts
Definition: L1ThresholdBase.cxx:18
merge_scale_histograms.doc
string doc
Definition: merge_scale_histograms.py:9
id
SG::auxid_t id
Definition: Control/AthContainers/Root/debug.cxx:227
name
std::string name
Definition: Control/AthContainers/Root/debug.cxx:228
LVL1::eFEXFPGA::m_eTowerContainerKey
SG::ReadHandleKey< LVL1::eTowerContainer > m_eTowerContainerKey
Definition: eFEXFPGA.h:80
TrigConf::Selection::WP::MEDIUM
@ MEDIUM
TrigConf::Selection::WP::TIGHT
@ TIGHT
a
TList * a
Definition: liststreamerinfos.cxx:10
h
LVL1::eFEXFPGA::m_efexid
int m_efexid
Definition: eFEXFPGA.h:70
python.CaloScaleNoiseConfig.type
type
Definition: CaloScaleNoiseConfig.py:78
LVL1::eFEXFPGA::SetIsoWP
virtual void SetIsoWP(const std::vector< unsigned int > &, const std::vector< unsigned int > &, unsigned int &, unsigned int) const override
Definition: eFEXFPGA.cxx:550
SG::VarHandleBase::vhKey
SG::VarHandleKey & vhKey()
Return a non-const reference to the HandleKey.
Definition: StoreGate/src/VarHandleBase.cxx:623
module_driven_slicing.min_eta
min_eta
Definition: module_driven_slicing.py:166
LVL1::eTower::eta
float eta() const
Definition: eTower.h:64
python.Bindings.keys
keys
Definition: Control/AthenaPython/python/Bindings.py:798
calibdata.copy
bool copy
Definition: calibdata.py:27
AthCommonDataStore::declareGaudiProperty
Gaudi::Details::PropertyBase & declareGaudiProperty(Gaudi::Property< T > &hndl, const SG::VarHandleKeyType &)
specialization for handling Gaudi::Property<SG::VarHandleKey>
Definition: AthCommonDataStore.h:156
fitman.k
k
Definition: fitman.py:528
LVL1::eFEXFPGA::m_tauHeuristicTobObjects
std::vector< std::unique_ptr< eFEXtauTOB > > m_tauHeuristicTobObjects
Definition: eFEXFPGA.h:72