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::jFEXSysSim Class Reference

The jFEXSysSim class defines the structure of the jFEX system Its purpose is: More...

#include <jFEXSysSim.h>

Inheritance diagram for LVL1::jFEXSysSim:
Collaboration diagram for LVL1::jFEXSysSim:

Public Member Functions

 jFEXSysSim (const std::string &type, const std::string &name, const IInterface *parent)
 Constructors. More...
 
jFEXSysSim && operator= (const jFEXSysSim &)=delete
 Destructor. More...
 
virtual StatusCode initialize () override
 standard Athena-Algorithm method More...
 
virtual StatusCode finalize () override
 standard Athena-Algorithm method More...
 
virtual StatusCode execute (jFEXOutputCollection *inputOutputCollection) override
 
virtual void init () const override
 
virtual void cleanup () override
 
virtual int calcTowerID (int eta, int phi, int mod) const 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, V, H > &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

StatusCode fillSRJetEDM (const std::unique_ptr< jFEXTOB > &internalTob, char istob, float_t eta, float_t phi, SG::WriteHandle< xAOD::jFexSRJetRoIContainer > &jContainer) const
 
StatusCode fillLRJetEDM (const std::unique_ptr< jFEXTOB > &internalTob, char istob, float_t eta, float_t phi, SG::WriteHandle< xAOD::jFexLRJetRoIContainer > &jContainer) const
 
StatusCode fillTauEDM (const std::unique_ptr< jFEXTOB > &internalTob, char istob, float_t eta, float_t phi, SG::WriteHandle< xAOD::jFexTauRoIContainer > &jContainer) const
 
StatusCode fillFwdElEDM (uint8_t jFexNum, uint8_t fpgaNumber, uint32_t tobWord, char istob, int resolution, float_t eta, float_t phi, SG::WriteHandle< xAOD::jFexFwdElRoIContainer > &jContainer) const
 
StatusCode fillSumEtEDM (const std::unique_ptr< jFEXTOB > &internalTob, SG::WriteHandle< xAOD::jFexSumETRoIContainer > &jContainer) const
 
StatusCode fillMetEDM (const std::unique_ptr< jFEXTOB > &internalTob, SG::WriteHandle< xAOD::jFexMETRoIContainer > &jContainer) const
 
Gaudi::Details::PropertyBase & declareGaudiProperty (Gaudi::Property< T, V, H > &hndl, const SG::VarHandleKeyType &)
 specialization for handling Gaudi::Property<SG::VarHandleKey> More...
 
Gaudi::Details::PropertyBase & declareGaudiProperty (Gaudi::Property< T, V, H > &hndl, const SG::VarHandleKeyArrayType &)
 specialization for handling Gaudi::Property<SG::VarHandleKeyArray> More...
 
Gaudi::Details::PropertyBase & declareGaudiProperty (Gaudi::Property< T, V, H > &hndl, const SG::VarHandleType &)
 specialization for handling Gaudi::Property<SG::VarHandleBase> More...
 
Gaudi::Details::PropertyBase & declareGaudiProperty (Gaudi::Property< T, V, H > &t, const SG::NotHandleType &)
 specialization for handling everything that's not a Gaudi::Property<SG::VarHandleKey> or a <SG::VarHandleKeyArray> More...
 

Private Attributes

std::vector< jFEXSim * > m_jFEXCollection
 Internal data. More...
 
SG::ReadCondHandleKey< jFEXDBCondDatam_DBToolKey {this, "DBToolKey", "jFEXDBParams", "DB tool key"}
 
ToolHandle< IjFEXSimm_jFEXSimTool {this, "jFEXSimTool", "LVL1::jFEXSim", "Tool that creates the jFEX Simulation"}
 
SG::ReadHandleKey< LVL1::jTowerContainerm_jTowerContainerSGKey {this, "MyETowers", "jTowerContainer", "Input container for jTowers"}
 
SG::ReadHandleKey< TrigConf::L1Menum_l1MenuKey {this, "L1TriggerMenu", "DetectorStore+L1TriggerMenu","Name of the L1Menu object to read configuration from"}
 
SG::WriteHandleKey< xAOD::jFexSRJetRoIContainerm_TobOutKey_jJ {this,"Key_jFexSRJetOutputContainer","L1_jFexSRJetRoI","Output jFexEDM jets container"}
 
SG::WriteHandleKey< xAOD::jFexLRJetRoIContainerm_TobOutKey_jLJ {this,"Key_jFexLRJetOutputContainer","L1_jFexLRJetRoI","Output jFexEDM Ljets container"}
 
SG::WriteHandleKey< xAOD::jFexTauRoIContainerm_TobOutKey_jTau {this,"Key_jFexTauOutputContainer" ,"L1_jFexTauRoI" ,"Output jFexEDM tau container"}
 
SG::WriteHandleKey< xAOD::jFexFwdElRoIContainerm_TobOutKey_jEM {this,"Key_jFexFwdElOutputContainer","L1_jFexFwdElRoI","Output jFexEDM fwdEl container"}
 
SG::WriteHandleKey< xAOD::jFexSumETRoIContainerm_TobOutKey_jTE {this,"Key_jFexSumETOutputContainer","L1_jFexSumETRoI","Output jFexEDM SumET container"}
 
SG::WriteHandleKey< xAOD::jFexMETRoIContainerm_TobOutKey_jXE {this,"Key_jFexMETOutputContainer" ,"L1_jFexMETRoI" ,"Output jFexEDM Met container"}
 
SG::WriteHandleKey< xAOD::jFexSRJetRoIContainerm_xTobOutKey_jJ {this,"Key_xTobOutKey_jJ" ,"L1_jFexSRJetxRoI","Output jFexEDM xTOBs jets container"}
 
SG::WriteHandleKey< xAOD::jFexLRJetRoIContainerm_xTobOutKey_jLJ {this,"Key_xTobOutKey_jLJ" ,"L1_jFexLRJetxRoI","Output jFexEDM xTOBs Ljets container"}
 
SG::WriteHandleKey< xAOD::jFexTauRoIContainerm_xTobOutKey_jTau {this,"Key_xTobOutKey_jTau" ,"L1_jFexTauxRoI" ,"Output jFexEDM xTOBs tau container"}
 
SG::WriteHandleKey< xAOD::jFexFwdElRoIContainerm_xTobOutKey_jEM {this,"Key_xTobOutKey_jEM" ,"L1_jFexFwdElxRoI","Output jFexEDM xTOBs fwdEl container"}
 
SG::WriteDecorHandleKey< xAOD::jFexSRJetRoIContainerm_TobDecorKey_jJ_seedET { this, "Key_tobDecor_jJ_seedET" , m_TobOutKey_jJ , "seedETMeV" , "jJet seed ET value in MeV" }
 
SG::WriteDecorHandleKey< xAOD::jFexSRJetRoIContainerm_xTobDecorKey_jJ_seedET { this, "Key_xTobDecor_jJ_seedET" , m_xTobOutKey_jJ , "seedETMeV" , "jJet seed ET value in MeV" }
 
std::unordered_map< int, jTowerm_jTowersColl
 
std::unordered_map< uint8_t, std::vector< std::vector< std::vector< uint32_t > > > > m_allfwdElTobs
 
std::unordered_map< uint8_t, std::vector< std::vector< std::unique_ptr< jFEXTOB > > > > m_alltauTobs
 
std::unordered_map< uint8_t, std::vector< std::vector< std::unique_ptr< jFEXTOB > > > > m_allSmallRJetTobs
 
std::unordered_map< uint8_t, std::vector< std::vector< std::unique_ptr< jFEXTOB > > > > m_allLargeRJetTobs
 
std::unordered_map< uint8_t, std::vector< std::unique_ptr< jFEXTOB > > > m_allsumEtTobs
 
std::unordered_map< uint8_t, std::vector< std::unique_ptr< jFEXTOB > > > m_allMetTobs
 
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 jFEXSysSim class defines the structure of the jFEX system Its purpose is:

Definition at line 47 of file jFEXSysSim.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

◆ jFEXSysSim()

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

Constructors.

Definition at line 36 of file jFEXSysSim.cxx.

36  :
38  {
39  declareInterface<IjFEXSysSim>(this);
40 
41  }

Member Function Documentation

◆ calcTowerID()

int LVL1::jFEXSysSim::calcTowerID ( int  eta,
int  phi,
int  mod 
) const
overridevirtual

Implements LVL1::IjFEXSysSim.

Definition at line 102 of file jFEXSysSim.cxx.

102  {
103 
104  return ((64*eta) + phi + mod);
105  }

◆ cleanup()

void LVL1::jFEXSysSim::cleanup ( )
overridevirtual

Implements LVL1::IjFEXSysSim.

Definition at line 94 of file jFEXSysSim.cxx.

94  {
95 
96  m_jFEXCollection.clear();
97  m_jTowersColl.clear();
98 
99  }

◆ declareGaudiProperty() [1/4]

Gaudi::Details::PropertyBase& AthCommonDataStore< AthCommonMsg< AlgTool > >::declareGaudiProperty ( Gaudi::Property< T, V, H > &  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, V, H > &  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, V, H > &  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, V, H > &  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, V, H > &  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::jFEXSysSim::execute ( jFEXOutputCollection inputOutputCollection)
overridevirtual

Implements LVL1::IjFEXSysSim.

Definition at line 107 of file jFEXSysSim.cxx.

107  {
108 
110  if(!this_jTowerContainer.isValid()){
111  ATH_MSG_ERROR("Could not retrieve jTowerContainer " << m_jTowerContainerSGKey.key());
112  return StatusCode::FAILURE;
113  }
114 
115  m_allSmallRJetTobs.clear();
116  m_allLargeRJetTobs.clear();
117  m_alltauTobs.clear();
118  m_allfwdElTobs.clear();
119  m_allMetTobs.clear();
120  m_allsumEtTobs.clear();
121  // We need to split the towers into 6 blocks in eta and 4 blocks in phi.
122 
123  // boundaries in eta: -2.5, -1.6, -0.8, 0.0, 0.8, 1.6, 2.5
124  // Written explicitly:
125  // -2.5 -> -0.8 (in reality this will be -4.9 to -0.8 , but we're ignoring the forward region for the time being...) [core is -4.9 to -1.6]
126  // -2.4 -> -0.0 [core is -1.6 to -0.8]
127  // -1.6 -> 0.8 [core is -0.8 to -0.0]
128  // -0.8 -> 1.6 [core is [0.0 to 0.8]
129  // 0.0 -> 2.4 [core is 0.8 to 1.6]
130  // 0.8 -> 2.5 (in reality this will be 0.8 to 4.9 , but we're ignoring the forward region for the time being...) [core is 1.6 to 4.9]
131 
132  //----------------------------------------------WRONG! THE FPGAs SPLIT IN PHI, NOT THE FEXs------------------------------------------------
133  // XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX
134  // boundaries in phi: 0.0, 1.6, 3.2, 4.8, 6.4
135  // Written explicitly:
136  // 5.6 -> 2.4 [core is 0.0 to 1.6]
137  // 0.8 -> 4.0 [core is 1.6 to 3.2]
138  // 2.4 -> 5.6 [core is 3.2 to 4.8]
139  // 4.0 -> 0.8 [core is 4.8 to 6.4]
140  // XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX
141  //----------------------------------------------WRONG! THE FPGAs SPLIT IN PHI, NOT THE FEXs------------------------------------------------
142 
143  //--------------------------------------------------------------------------------------------------------------------------------------------------------------------
144  // C-SIDE NEGATIVE JFEX
145  // LEFT-MOST
146  // -4.9 to -0.8 [core is -4.9 to -1.6]
147  // DO THE LEFT-MOST (NEGATIVE ETA) JFEX FIRST
148  //id_modifier + phi + (64 * eta)
149  int fcal2Eta = 3; int fcal2Phi = 0; int fcal2Mod = 1100000;
150  int initialFCAL2 = calcTowerID(fcal2Eta,fcal2Phi,fcal2Mod); //1100192
151  int fcal1Eta = 7; int fcal1Phi = 0; int fcal1Mod = 900000;
152  int initialFCAL1 = calcTowerID(fcal1Eta,fcal1Phi,fcal1Mod); //900448
153  int fcal0Eta = 11; int fcal0Phi = 0; int fcal0Mod = 700000;
154  int initialFCAL0 = calcTowerID(fcal0Eta,fcal0Phi,fcal0Mod); //700704
155  int emecEta = 28; int emecPhi = 0; int emecMod = 500000;
156  int initialEMEC = calcTowerID(emecEta,emecPhi,emecMod); //501792
157  int transEta = 14; int transPhi = 0; int transMod = 300000;
158  int initialTRANS = calcTowerID(transEta,transPhi,transMod); //300896;
159  int embEta = 13; int embPhi = 0; int embMod = 100000;
160  int initialEMB = calcTowerID(embEta,embPhi,embMod); //100832
161 
163  if (!myDBTool.isValid()){
164  ATH_MSG_ERROR("Not able to read " << m_DBToolKey );
165  return StatusCode::FAILURE;
166  }
167 
168  unsigned int evtTimeStamp = Gaudi::Hive::currentContext().eventID().time_stamp();
169 
170  uint8_t thisJFEX = 0;
171  // jFEX 0
172  thisJFEX = 0;
173 
174  // let's work fully out to in (sort of)
175  // Let's go with FCAL2 first
176  // decide which subset of towers (and therefore supercells) should go to the jFEX
177  std::unordered_map<int,jTower> tmp_jTowersColl_subset_ENDCAP_AND_EMB_AND_FCAL;
178  tmp_jTowersColl_subset_ENDCAP_AND_EMB_AND_FCAL.reserve(1600);
179 
180  // let's try doing this with an array initially just containing tower IDs.
181  int tmp_jTowersIDs_subset_ENDCAP_AND_EMB_AND_FCAL [2*FEXAlgoSpaceDefs::jFEX_algoSpace_height][FEXAlgoSpaceDefs::jFEX_wide_algoSpace_width];
182 
183  // zero the matrix out
184  for (int i = 0; i<2*FEXAlgoSpaceDefs::jFEX_algoSpace_height; i++){
185  for (int j = 0; j<FEXAlgoSpaceDefs::jFEX_wide_algoSpace_width; j++){
186  tmp_jTowersIDs_subset_ENDCAP_AND_EMB_AND_FCAL[i][j] = 0;
187  }
188  }
189 
190  int rows = sizeof tmp_jTowersIDs_subset_ENDCAP_AND_EMB_AND_FCAL / sizeof tmp_jTowersIDs_subset_ENDCAP_AND_EMB_AND_FCAL[0];
191  int cols = sizeof tmp_jTowersIDs_subset_ENDCAP_AND_EMB_AND_FCAL[0] / sizeof tmp_jTowersIDs_subset_ENDCAP_AND_EMB_AND_FCAL[0][0];
192 
193  // set the FCAL2 part
194  for(int thisCol=0; thisCol<4; thisCol++){
195  for(int thisRow=0; thisRow<rows/4; thisRow++){
196 
197  int towerid = initialFCAL2 - (thisCol * 64) + thisRow;
198 
199  tmp_jTowersIDs_subset_ENDCAP_AND_EMB_AND_FCAL[thisRow][thisCol] = towerid;
200  tmp_jTowersColl_subset_ENDCAP_AND_EMB_AND_FCAL.insert( std::unordered_map<int, jTower>::value_type(towerid, *(this_jTowerContainer->findTower(towerid))));
201 
202  }
203  }
204  //---
205  // Let's go with FCAL1
206  // set the FCAL1 part
207  for(int thisCol=4; thisCol<12; thisCol++){
208  for(int thisRow=0; thisRow<rows/4; thisRow++){
209 
210  int towerid = initialFCAL1 - ((thisCol-4) * 64) + thisRow;
211 
212  tmp_jTowersIDs_subset_ENDCAP_AND_EMB_AND_FCAL[thisRow][thisCol] = towerid;
213  tmp_jTowersColl_subset_ENDCAP_AND_EMB_AND_FCAL.insert( std::unordered_map<int, jTower>::value_type(towerid, *(this_jTowerContainer->findTower(towerid))));
214 
215  }
216  }
217  //---
218  // Let's go with FCAL0
219  // set the FCAL0 part
220  for(int thisCol=12; thisCol<24; thisCol++){
221  for(int thisRow=0; thisRow<rows/4; thisRow++){
222 
223  int towerid = initialFCAL0 - ((thisCol-12) * 64) + thisRow;
224 
225  tmp_jTowersIDs_subset_ENDCAP_AND_EMB_AND_FCAL[thisRow][thisCol] = towerid;
226  tmp_jTowersColl_subset_ENDCAP_AND_EMB_AND_FCAL.insert( std::unordered_map<int, jTower>::value_type(towerid, *(this_jTowerContainer->findTower(towerid))));
227 
228  }
229  }
230  //---
231  // decide which subset of towers (and therefore supercells) should go to the jFEX
232  // set the next EMEC part
233  for(int thisCol=24; thisCol<28; thisCol++){
234  for(int thisRow=0; thisRow<rows/2; thisRow++){
235 
236  int towerid = initialEMEC - ((thisCol-24) * 64) + thisRow;
237 
238  tmp_jTowersIDs_subset_ENDCAP_AND_EMB_AND_FCAL[thisRow][thisCol] = towerid;
239  tmp_jTowersColl_subset_ENDCAP_AND_EMB_AND_FCAL.insert( std::unordered_map<int, jTower>::value_type(towerid, *(this_jTowerContainer->findTower(towerid))));
240 
241  }
242  }
243  // set the EMEC part
244  for(int thisCol=28; thisCol<38; thisCol++){
245  for(int thisRow=0; thisRow<rows; thisRow++){
246 
247  int towerid = initialEMEC - ((thisCol-24) * 64) + thisRow; //note special case -24 rather than -28, this *is* deliberate
248 
249  tmp_jTowersIDs_subset_ENDCAP_AND_EMB_AND_FCAL[thisRow][thisCol] = towerid;
250  tmp_jTowersColl_subset_ENDCAP_AND_EMB_AND_FCAL.insert( std::unordered_map<int, jTower>::value_type(towerid, *(this_jTowerContainer->findTower(towerid))));
251 
252  }
253  }
254  // set the TRANS part
255  for(int thisRow = 0; thisRow < rows; thisRow++){
256 
257  int towerid = initialTRANS + thisRow;
258 
259  tmp_jTowersIDs_subset_ENDCAP_AND_EMB_AND_FCAL[thisRow][38] = towerid;
260  tmp_jTowersColl_subset_ENDCAP_AND_EMB_AND_FCAL.insert( std::unordered_map<int, jTower>::value_type(towerid, *(this_jTowerContainer->findTower(towerid))));
261 
262  }
263  // set the EMB part
264  for(int thisCol = 39; thisCol < 45; thisCol++){
265  for(int thisRow=0; thisRow<rows; thisRow++){
266 
267  int towerid = initialEMB - ( (thisCol-39) * 64) + thisRow;
268 
269  tmp_jTowersIDs_subset_ENDCAP_AND_EMB_AND_FCAL[thisRow][thisCol] = towerid;
270  tmp_jTowersColl_subset_ENDCAP_AND_EMB_AND_FCAL.insert( std::unordered_map<int, jTower>::value_type(towerid, *(this_jTowerContainer->findTower(towerid))));
271 
272  }
273  }
274 
275  if (msgLvl(MSG::DEBUG)) {
276  ATH_MSG_DEBUG("CONTENTS OF jFEX " << thisJFEX << " :");
277  for (int thisRow=rows-1; thisRow>=0; thisRow--) {
278  for (int thisCol=0; thisCol<cols; thisCol++) {
279  int tmptowerid = tmp_jTowersIDs_subset_ENDCAP_AND_EMB_AND_FCAL[thisRow][thisCol];
280  if(tmptowerid == 0 ) continue;
281  const LVL1::jTower* tmptower = this_jTowerContainer->findTower(tmptowerid);
282  const float tmptowereta = tmptower->iEta();
283  const float tmptowerphi = tmptower->iPhi();
284  if(thisCol != cols-1) {
285  ATH_MSG_DEBUG("| " << tmptowerid << "([" << tmptowerphi << "][" << tmptowereta << "]) ");
286  }
287  else {
288  ATH_MSG_DEBUG("| " << tmptowerid << "([" << tmptowereta << "][" << tmptowerphi << "]) |");
289  }
290  }
291  }
292  }
293  m_jFEXSimTool->init(thisJFEX);
294  ATH_CHECK(m_jFEXSimTool->ExecuteForwardASide(tmp_jTowersIDs_subset_ENDCAP_AND_EMB_AND_FCAL, inputOutputCollection, { evtTimeStamp, myDBTool->get_jJCalibParams(thisJFEX) } ));
295 
296  m_allSmallRJetTobs.insert(std::unordered_map<uint8_t, std::vector< std::vector<std::unique_ptr<jFEXTOB>> > >::value_type(thisJFEX,(m_jFEXSimTool->getSmallRJetTOBs() ) ));
297  m_allLargeRJetTobs.insert(std::unordered_map<uint8_t, std::vector< std::vector<std::unique_ptr<jFEXTOB>> > >::value_type(thisJFEX,(m_jFEXSimTool->getLargeRJetTOBs() ) ));
298  m_alltauTobs.insert( std::unordered_map<uint8_t, std::vector< std::vector<std::unique_ptr<jFEXTOB>> > >::value_type(thisJFEX,(m_jFEXSimTool->getTauTOBs() ) ));
299  m_allfwdElTobs.insert( std::unordered_map<uint8_t, std::vector<std::vector<std::vector<uint32_t>>> >::value_type(thisJFEX,(m_jFEXSimTool->getFwdElTOBs() ) ));
300 
301  m_allsumEtTobs.insert(std::unordered_map<uint8_t, std::vector<std::unique_ptr<jFEXTOB>> >::value_type(thisJFEX,(m_jFEXSimTool->getSumEtTOBs() ) ));
302  m_allMetTobs.insert(std::unordered_map<uint8_t, std::vector<std::unique_ptr<jFEXTOB>> >::value_type(thisJFEX,(m_jFEXSimTool->getMetTOBs() ) ));
303  m_jFEXSimTool->reset();
304 
305  //--------------------------------------------------------------------------------------------------------------------------------------------------------------------
306 
307  //--------------------------------------------------------------------------------------------------------------------------------------------------------------------
308  // C-SIDE NEGATIVE JFEX
309  // INNER-LEFT
310  // -2.4 -> -0.0 [core is -1.6 to -0.8]
311  // DO THE INNER-LEFT (NEGATIVE ETA) JFEX SECOND
312  //id_modifier + phi + (64 * eta)
313  emecEta = 23; emecPhi = 0; emecMod = 500000;
314  initialEMEC = calcTowerID(emecEta,emecPhi,emecMod); //500472;
315  transEta = 14; transPhi = 0; transMod = 300000;
316  initialTRANS = calcTowerID(transEta,transPhi,transMod); //300896;
317  embEta = 13; embPhi = 0; embMod = 100000;
318  initialEMB = calcTowerID(embEta,embPhi,embMod); //100832
319 
320  // jFEX 1
321  thisJFEX = 1;
322 
323  // decide which subset of towers (and therefore supercells) should go to the jFEX
324  std::unordered_map<int,jTower> tmp_jTowersColl_subset_1;
325 
326  // let's try doing this with an array initially just containing tower IDs.
328 
329  // zero the matrix out
330  for (int i = 0; i<2*FEXAlgoSpaceDefs::jFEX_algoSpace_height; i++){
331  for (int j = 0; j<FEXAlgoSpaceDefs::jFEX_thin_algoSpace_width; j++){
332  tmp_jTowersIDs_subset_1[i][j] = 0;
333  }
334  }
335 
336  rows = sizeof tmp_jTowersIDs_subset_1 / sizeof tmp_jTowersIDs_subset_1[0];
337  cols = sizeof tmp_jTowersIDs_subset_1[0] / sizeof tmp_jTowersIDs_subset_1[0][0];
338 
339  // set the EMEC part
340  for(int thisCol = 0; thisCol < 9; thisCol++){
341  for(int thisRow=0; thisRow<rows; thisRow++){
342 
343  int towerid = initialEMEC - (thisCol * 64) + thisRow;
344 
345  tmp_jTowersIDs_subset_1[thisRow][thisCol] = towerid;
346  tmp_jTowersColl_subset_1.insert( std::unordered_map<int, jTower>::value_type(towerid, *(this_jTowerContainer->findTower(towerid))));
347 
348  }
349  }
350 
351  // set the TRANS part
352  for(int thisRow = 0; thisRow < rows; thisRow++) {
353 
354  int towerid = initialTRANS + thisRow;
355 
356  tmp_jTowersIDs_subset_1[thisRow][9] = towerid;
357  tmp_jTowersColl_subset_1.insert( std::unordered_map<int, jTower>::value_type(towerid, *(this_jTowerContainer->findTower(towerid))));
358 
359  }
360 
361  // set the EMB part
362  for(int thisCol = 10; thisCol < cols; thisCol++) {
363  for(int thisRow=0; thisRow<rows; thisRow++) {
364 
365  int towerid = initialEMB - ( (thisCol-10) * 64) + thisRow ;
366 
367  tmp_jTowersIDs_subset_1[thisRow][thisCol] = towerid;
368  tmp_jTowersColl_subset_1.insert( std::unordered_map<int, jTower>::value_type(towerid, *(this_jTowerContainer->findTower(towerid))));
369 
370  }
371  }
372 
373  if (msgLvl(MSG::DEBUG)) {
374  ATH_MSG_DEBUG("CONTENTS OF jFEX " << thisJFEX << " :");
375  for (int thisRow=rows-1; thisRow>=0; thisRow--) {
376  for (int thisCol=0; thisCol<cols; thisCol++) {
377  int tmptowerid = tmp_jTowersIDs_subset_1[thisRow][thisCol];
378  if(tmptowerid == 0) continue;
379  const LVL1::jTower* tmptower = this_jTowerContainer->findTower(tmptowerid);
380  const float tmptowereta = tmptower->iEta();
381  const float tmptowerphi = tmptower->iPhi();
382  if(thisCol != cols-1) {
383  ATH_MSG_DEBUG("| " << tmptowerid << "([" << tmptowerphi << "][" << tmptowereta << "]) ");
384  }
385  else {
386  ATH_MSG_DEBUG("| " << tmptowerid << "([" << tmptowereta << "][" << tmptowerphi << "]) |");
387  }
388  }
389  }
390  }
391  m_jFEXSimTool->init(thisJFEX);
392  ATH_CHECK(m_jFEXSimTool->ExecuteBarrel(tmp_jTowersIDs_subset_1, inputOutputCollection, { evtTimeStamp, myDBTool->get_jJCalibParams(thisJFEX) } ));
393 
394  m_allSmallRJetTobs.insert(std::unordered_map<uint8_t, std::vector< std::vector<std::unique_ptr<jFEXTOB>> > >::value_type(thisJFEX,(m_jFEXSimTool->getSmallRJetTOBs() ) ));
395  m_allLargeRJetTobs.insert(std::unordered_map<uint8_t, std::vector< std::vector<std::unique_ptr<jFEXTOB>> > >::value_type(thisJFEX,(m_jFEXSimTool->getLargeRJetTOBs() ) ));
396  m_alltauTobs.insert( std::unordered_map<uint8_t, std::vector< std::vector<std::unique_ptr<jFEXTOB>> > >::value_type(thisJFEX,(m_jFEXSimTool->getTauTOBs() ) ));
397 
398  m_allsumEtTobs.insert(std::unordered_map<uint8_t, std::vector<std::unique_ptr<jFEXTOB>> >::value_type(thisJFEX,(m_jFEXSimTool->getSumEtTOBs() ) ));
399  m_allMetTobs.insert(std::unordered_map<uint8_t, std::vector<std::unique_ptr<jFEXTOB>> >::value_type(thisJFEX,(m_jFEXSimTool->getMetTOBs() ) ));
400  m_jFEXSimTool->reset();
401 
402  //--------------------------------------------------------------------------------------------------------------------------------------------------------------------
403 
404  //--------------------------------------------------------------------------------------------------------------------------------------------------------------------
405  // C-SIDE NEGATIVE JFEXs
406  // CENTRAL-LEFT
407  // -1.6 -> 0.8 [core is -0.8 to -0.0]
408  // DO THE CENTRAL-LEFT JFEXs (NEGATIVE ETA) THIRD
409  //id_modifier + phi + (64 * eta)
410  emecEta = 15; emecPhi = 0; emecMod = 500000;
411  initialEMEC = calcTowerID(emecEta,emecPhi,emecMod); //500960;
412  transEta = 14; transPhi = 0; transMod = 300000;
413  initialTRANS = calcTowerID(transEta,transPhi,transMod); //300896;
414  embEta = 13; embPhi = 0; embMod = 100000;
415  initialEMB = calcTowerID(embEta,embPhi,embMod); //100832
416 
417  // jFEX 2
418  thisJFEX = 2;
419 
420  // decide which subset of towers (and therefore supercells) should go to the jFEX
421  std::unordered_map<int,jTower> tmp_jTowersColl_subset_2;
422 
423  // doing this with an array initially just containing tower IDs.
425 
426  // zero the matrix out
427  for (int i = 0; i<2*FEXAlgoSpaceDefs::jFEX_algoSpace_height; i++) {
428  for (int j = 0; j<FEXAlgoSpaceDefs::jFEX_thin_algoSpace_width; j++) {
429  tmp_jTowersIDs_subset_2[i][j] = 0;
430  }
431  }
432 
433 
434  rows = sizeof tmp_jTowersIDs_subset_2 / sizeof tmp_jTowersIDs_subset_2[0];
435  cols = sizeof tmp_jTowersIDs_subset_2[0] / sizeof tmp_jTowersIDs_subset_2[0][0];
436 
437  // set the EMEC part
438  for(int thisRow=0; thisRow<rows; thisRow++) {
439 
440  int towerid = initialEMEC /*- (thisCol * 64)*/ + thisRow;
441 
442  tmp_jTowersIDs_subset_2[thisRow][0] = towerid;
443  tmp_jTowersColl_subset_2.insert( std::unordered_map<int, jTower>::value_type(towerid, *(this_jTowerContainer->findTower(towerid))));
444 
445  }
446 
447  // set the TRANS part
448  for(int thisRow = 0; thisRow < rows; thisRow++) {
449 
450  int towerid = initialTRANS + thisRow;
451 
452  tmp_jTowersIDs_subset_2[thisRow][1] = towerid;
453  tmp_jTowersColl_subset_2.insert( std::unordered_map<int, jTower>::value_type(towerid, *(this_jTowerContainer->findTower(towerid))));
454 
455  }
456 
457  // set the negative EMB part
458  for(int thisCol = 2; thisCol < cols-8; thisCol++) {
459  for(int thisRow=0; thisRow<rows; thisRow++) {
460  int towerid = -1;
461 
462  int tmp_initEMB = initialEMB;
463 
464  towerid = tmp_initEMB - ( (thisCol-2) * 64) + thisRow;
465  tmp_jTowersIDs_subset_2[thisRow][thisCol] = towerid;
466 
467  tmp_jTowersColl_subset_2.insert( std::unordered_map<int, jTower>::value_type(towerid, *(this_jTowerContainer->findTower(towerid))));
468 
469  }
470  }
471 
472  embEta = 0; embPhi = 0; embMod = 200000;
473  initialEMB = calcTowerID(embEta,embPhi,embMod); //200000
474 
475  // set the positive EMB part
476  for(int thisCol = 16; thisCol < cols; thisCol++) {
477  for(int thisRow=0; thisRow<rows; thisRow++) {
478  int towerid = -1;
479 
480  int tmp_initEMB = initialEMB;
481 
482  towerid = tmp_initEMB + ( (thisCol-16) * 64) + thisRow;
483  tmp_jTowersIDs_subset_2[thisRow][thisCol] = towerid;
484 
485  tmp_jTowersColl_subset_2.insert( std::unordered_map<int, jTower>::value_type(towerid, *(this_jTowerContainer->findTower(towerid))));
486 
487  }
488  }
489 
490  if (msgLvl(MSG::DEBUG)) {
491  ATH_MSG_DEBUG("CONTENTS OF jFEX " << thisJFEX << " :");
492  for (int thisRow=rows-1; thisRow>=0; thisRow--) {
493  for (int thisCol=0; thisCol<cols; thisCol++) {
494  int tmptowerid = tmp_jTowersIDs_subset_2[thisRow][thisCol];
495  if(tmptowerid == 0) continue;
496  const LVL1::jTower* tmptower = this_jTowerContainer->findTower(tmptowerid);
497  const float tmptowereta = tmptower->iEta();
498  const float tmptowerphi = tmptower->iPhi();
499  if(thisCol != cols-1) {
500  ATH_MSG_DEBUG("| " << tmptowerid << "([" << tmptowereta << "][" << tmptowerphi << "]) ");
501  }
502  else {
503  ATH_MSG_DEBUG("| " << tmptowerid << "([" << tmptowereta << "][" << tmptowerphi << "]) |");
504  }
505  }
506  }
507  }
508 
509  //tool use instead
510  m_jFEXSimTool->init(thisJFEX);
511  ATH_CHECK(m_jFEXSimTool->ExecuteBarrel(tmp_jTowersIDs_subset_2, inputOutputCollection, { evtTimeStamp, myDBTool->get_jJCalibParams(thisJFEX) } ));
512 
513  m_allSmallRJetTobs.insert(std::unordered_map<uint8_t, std::vector< std::vector<std::unique_ptr<jFEXTOB>> > >::value_type(thisJFEX,(m_jFEXSimTool->getSmallRJetTOBs() ) ));
514  m_allLargeRJetTobs.insert(std::unordered_map<uint8_t, std::vector< std::vector<std::unique_ptr<jFEXTOB>> > >::value_type(thisJFEX,(m_jFEXSimTool->getLargeRJetTOBs() ) ));
515  m_alltauTobs.insert( std::unordered_map<uint8_t, std::vector< std::vector<std::unique_ptr<jFEXTOB>> > >::value_type(thisJFEX,(m_jFEXSimTool->getTauTOBs() ) ));
516 
517  m_allsumEtTobs.insert(std::unordered_map<uint8_t, std::vector<std::unique_ptr<jFEXTOB>> >::value_type(thisJFEX,(m_jFEXSimTool->getSumEtTOBs() ) ));
518  m_allMetTobs.insert(std::unordered_map<uint8_t, std::vector<std::unique_ptr<jFEXTOB>> >::value_type(thisJFEX,(m_jFEXSimTool->getMetTOBs() ) ));
519  m_jFEXSimTool->reset();
520 
521  //--------------------------------------------------------------------------------------------------------------------------------------------------------------------
522 
523  //--------------------------------------------------------------------------------------------------------------------------------------------------------------------
524  // A-SIDE POSITIVE JFEXs
525  // CENTRAL-RIGHT JFEXs
526  // -0.8 -> 1.6 [core is [0.0 to 0.8]
527  // DO THE CENTRAL-RIGHT JFEXs (POSITIVE ETA) FOURTH
528  //id_modifier + phi + (64 * eta)
529  emecEta = 15; emecPhi = 0; emecMod = 600000;
530  initialEMEC = calcTowerID(emecEta,emecPhi,emecMod); //600960;
531  transEta = 14; transPhi = 0; transMod = 400000;
532  initialTRANS = calcTowerID(transEta,transPhi,transMod); //400896;
533  embEta = 7; embPhi = 0; embMod = 100000;
534  initialEMB = calcTowerID(embEta,embPhi,embMod); //100448
535 
536  // jFEX 3
537  thisJFEX = 3;
538 
539  // decide which subset of towers (and therefore supercells) should go to the jFEX
540  std::unordered_map<int,jTower> tmp_jTowersColl_subset_3;
541 
542  // doing this with an array initially just containing tower IDs.
544 
545  // zero the matrix out
546  for (int i = 0; i<2*FEXAlgoSpaceDefs::jFEX_algoSpace_height; i++){
547  for (int j = 0; j<FEXAlgoSpaceDefs::jFEX_thin_algoSpace_width; j++){
548  tmp_jTowersIDs_subset_3[i][j] = 0;
549  }
550  }
551 
552 
553  rows = sizeof tmp_jTowersIDs_subset_3 / sizeof tmp_jTowersIDs_subset_3[0];
554  cols = sizeof tmp_jTowersIDs_subset_3[0] / sizeof tmp_jTowersIDs_subset_3[0][0];
555 
556  // set the negative EMB part
557  for(int thisCol = 0; thisCol < 8; thisCol++){
558  for(int thisRow=0; thisRow<rows; thisRow++){
559  int towerid = -1;
560 
561  int tmp_initEMB = initialEMB;
562 
563  towerid = tmp_initEMB - ( (thisCol) * 64) + thisRow;
564 
565  tmp_jTowersIDs_subset_3[thisRow][thisCol] = towerid;
566 
567  tmp_jTowersColl_subset_3.insert( std::unordered_map<int, jTower>::value_type(towerid, *(this_jTowerContainer->findTower(towerid))));
568 
569  }
570  }
571 
572  embEta = 0; embPhi = 0; embMod = 200000;
573  initialEMB = calcTowerID(embEta,embPhi,embMod); //200000
574  // set the positive EMB part
575  for(int thisCol = 8; thisCol < 22; thisCol++){
576  for(int thisRow=0; thisRow<rows; thisRow++){
577  int towerid = -1;
578 
579  int tmp_initEMB = initialEMB;
580 
581  towerid = tmp_initEMB + ( (thisCol-8) * 64) + thisRow;
582 
583  tmp_jTowersIDs_subset_3[thisRow][thisCol] = towerid;
584 
585  tmp_jTowersColl_subset_3.insert( std::unordered_map<int, jTower>::value_type(towerid, *(this_jTowerContainer->findTower(towerid))));
586 
587  }
588  }
589 
590  // set the TRANS part
591  for(int thisRow = 0; thisRow < rows; thisRow++){
592  int towerid = initialTRANS + thisRow;
593 
594  tmp_jTowersIDs_subset_3[thisRow][22] = towerid;
595  tmp_jTowersColl_subset_3.insert( std::unordered_map<int, jTower>::value_type(towerid, *(this_jTowerContainer->findTower(towerid))));
596 
597  }
598 
599  // set the EMEC part
600  for(int thisRow=0; thisRow<rows; thisRow++){
601  int towerid = initialEMEC + /*( (thisCol-8) * 64)*/ + thisRow;
602 
603  tmp_jTowersIDs_subset_3[thisRow][23] = towerid;
604  tmp_jTowersColl_subset_3.insert( std::unordered_map<int, jTower>::value_type(towerid, *(this_jTowerContainer->findTower(towerid))));
605 
606  }
607 
608  if (msgLvl(MSG::DEBUG)) {
609  ATH_MSG_DEBUG("CONTENTS OF jFEX " << thisJFEX << " :");
610  for (int thisRow=rows-1; thisRow>=0; thisRow--) {
611  for (int thisCol=0; thisCol<cols; thisCol++) {
612  int tmptowerid = tmp_jTowersIDs_subset_3[thisRow][thisCol];
613  if(tmptowerid == 0) continue;
614  const LVL1::jTower* tmptower = this_jTowerContainer->findTower(tmptowerid);
615  const float tmptowereta = tmptower->iEta();
616  const float tmptowerphi = tmptower->iPhi();
617  if(thisCol != cols-1) {
618  ATH_MSG_DEBUG("| " << tmptowerid << "([" << tmptowereta << "][" << tmptowerphi << "]) ");
619  }
620  else {
621  ATH_MSG_DEBUG("| " << tmptowerid << "([" << tmptowereta << "][" << tmptowerphi << "]) |");
622  }
623  }
624  }
625  }
626 
627  //tool use instead
628  m_jFEXSimTool->init(thisJFEX);
629  ATH_CHECK(m_jFEXSimTool->ExecuteBarrel(tmp_jTowersIDs_subset_3, inputOutputCollection, { evtTimeStamp, myDBTool->get_jJCalibParams(thisJFEX) } ));
630 
631  m_allSmallRJetTobs.insert(std::unordered_map<uint8_t, std::vector< std::vector<std::unique_ptr<jFEXTOB>> > >::value_type(thisJFEX,(m_jFEXSimTool->getSmallRJetTOBs() ) ));
632  m_allLargeRJetTobs.insert(std::unordered_map<uint8_t, std::vector< std::vector<std::unique_ptr<jFEXTOB>> > >::value_type(thisJFEX,(m_jFEXSimTool->getLargeRJetTOBs() ) ));
633  m_alltauTobs.insert( std::unordered_map<uint8_t, std::vector< std::vector<std::unique_ptr<jFEXTOB>> > >::value_type(thisJFEX,(m_jFEXSimTool->getTauTOBs() ) ));
634 
635  m_allsumEtTobs.insert(std::unordered_map<uint8_t, std::vector<std::unique_ptr<jFEXTOB>> >::value_type(thisJFEX,(m_jFEXSimTool->getSumEtTOBs() ) ));
636  m_allMetTobs.insert(std::unordered_map<uint8_t, std::vector<std::unique_ptr<jFEXTOB>> >::value_type(thisJFEX,(m_jFEXSimTool->getMetTOBs() ) ));
637  m_jFEXSimTool->reset();
638 
639  //--------------------------------------------------------------------------------------------------------------------------------------------------------------------
640 
641  //--------------------------------------------------------------------------------------------------------------------------------------------------------------------
642  // A-SIDE POSITIVE JFEXs
643  // INNER-RIGHT JFEXs
644  // 0.0 -> 2.4 [core is 0.8 to 1.6]
645  // DO THE INNER-RIGHT JFEXs (POSITIVE ETA) FIFTH
646  emecEta = 15; emecPhi = 0; emecMod = 600000;
647  initialEMEC = calcTowerID(emecEta,emecPhi,emecMod); //600960;
648  transEta = 14; transPhi = 0; transMod = 400000;
649  initialTRANS = calcTowerID(transEta,transPhi,transMod); //400896;
650  embEta = 0; embPhi = 0; embMod = 200000;
651  initialEMB = calcTowerID(embEta,embPhi,embMod); //200000;
652 
653  // jFEX 4
654  thisJFEX = 4;
655 
656  // decide which subset of towers (and therefore supercells) should go to the jFEX
657  std::unordered_map<int,jTower> tmp_jTowersColl_subset_4;
658 
659  // doing this with an array initially just containing tower IDs.
661 
662  // zero the matrix out
663  for (int i = 0; i<2*FEXAlgoSpaceDefs::jFEX_algoSpace_height; i++){
664  for (int j = 0; j<FEXAlgoSpaceDefs::jFEX_thin_algoSpace_width; j++){
665  tmp_jTowersIDs_subset_4[i][j] = 0;
666  }
667  }
668 
669  rows = sizeof tmp_jTowersIDs_subset_4 / sizeof tmp_jTowersIDs_subset_4[0];
670  cols = sizeof tmp_jTowersIDs_subset_4[0] / sizeof tmp_jTowersIDs_subset_4[0][0];
671 
672  // set the EMB part
673  for(int thisCol = 0; thisCol < 14; thisCol++){
674  for(int thisRow=0; thisRow<rows; thisRow++){
675  int towerid = initialEMB + ( (thisCol) * 64) + thisRow;
676 
677  tmp_jTowersIDs_subset_4[thisRow][thisCol] = towerid;
678  tmp_jTowersColl_subset_4.insert( std::unordered_map<int, jTower>::value_type(towerid, *(this_jTowerContainer->findTower(towerid))));
679 
680  }
681  }
682  // set the TRANS part
683  for(int thisRow = 0; thisRow < rows; thisRow++){
684  int towerid = initialTRANS + thisRow;
685 
686  tmp_jTowersIDs_subset_4[thisRow][14] = towerid;
687  tmp_jTowersColl_subset_4.insert( std::unordered_map<int, jTower>::value_type(towerid, *(this_jTowerContainer->findTower(towerid))));
688 
689  }
690  // set the EMEC part
691  for(int thisCol = 15; thisCol < cols; thisCol++){
692  for(int thisRow=0; thisRow<rows; thisRow++){
693  int towerid = initialEMEC + ( (thisCol-15) * 64) + thisRow;
694 
695  tmp_jTowersIDs_subset_4[thisRow][thisCol] = towerid;
696  tmp_jTowersColl_subset_4.insert( std::unordered_map<int, jTower>::value_type(towerid, *(this_jTowerContainer->findTower(towerid))));
697 
698  }
699  }
700 
701  if (msgLvl(MSG::DEBUG)) {
702  ATH_MSG_DEBUG("CONTENTS OF jFEX " << thisJFEX << " :");
703  for (int thisRow=rows-1; thisRow>=0; thisRow--) {
704  for (int thisCol=0; thisCol<cols; thisCol++) {
705  int tmptowerid = tmp_jTowersIDs_subset_4[thisRow][thisCol];
706  if(tmptowerid == 0) continue;
707  const LVL1::jTower* tmptower = this_jTowerContainer->findTower(tmptowerid);
708  const float tmptowereta = tmptower->iEta();
709  const float tmptowerphi = tmptower->iPhi();
710  if(thisCol != cols-1) {
711  ATH_MSG_DEBUG("| " << tmptowerid << "([" << tmptowereta << "][" << tmptowerphi << "]) ");
712  }
713  else {
714  ATH_MSG_DEBUG("| " << tmptowerid << "([" << tmptowereta << "][" << tmptowerphi << "]) |");
715  }
716  }
717  }
718  }
719 
720  //tool use instead
721  m_jFEXSimTool->init(thisJFEX);
722  ATH_CHECK(m_jFEXSimTool->ExecuteBarrel(tmp_jTowersIDs_subset_4, inputOutputCollection, { evtTimeStamp, myDBTool->get_jJCalibParams(thisJFEX) } ));
723 
724  m_allSmallRJetTobs.insert(std::unordered_map<uint8_t, std::vector< std::vector<std::unique_ptr<jFEXTOB>> > >::value_type(thisJFEX,(m_jFEXSimTool->getSmallRJetTOBs() ) ));
725  m_allLargeRJetTobs.insert(std::unordered_map<uint8_t, std::vector< std::vector<std::unique_ptr<jFEXTOB>> > >::value_type(thisJFEX,(m_jFEXSimTool->getLargeRJetTOBs() ) ));
726  m_alltauTobs.insert( std::unordered_map<uint8_t, std::vector< std::vector<std::unique_ptr<jFEXTOB>> > >::value_type(thisJFEX,(m_jFEXSimTool->getTauTOBs() ) ));
727 
728  m_allsumEtTobs.insert(std::unordered_map<uint8_t, std::vector<std::unique_ptr<jFEXTOB>> >::value_type(thisJFEX,(m_jFEXSimTool->getSumEtTOBs() ) ));
729  m_allMetTobs.insert(std::unordered_map<uint8_t, std::vector<std::unique_ptr<jFEXTOB>> >::value_type(thisJFEX,(m_jFEXSimTool->getMetTOBs() ) ));
730  m_jFEXSimTool->reset();
731  //--------------------------------------------------------------------------------------------------------------------------------------------------------------------
732 
733  //--------------------------------------------------------------------------------------------------------------------------------------------------------------------
734  // A-SIDE POSITIVE JFEXs
735  // RIGHT-MOST
736  // 0.8 -> 2.5 (in reality this will be 0.8 to 4.9 , but we're ignoring the forward region for the time being...) [core is 1.6 to 4.9]
737  // DO THE RIGHT-MOST (POSITIVE ETA) JFEXs SIXTH
738  //id_modifier + phi + (64 * eta)
739  fcal2Eta = 0; fcal2Phi = 0; fcal2Mod = 1200000;
740  initialFCAL2 = calcTowerID(fcal2Eta,fcal2Phi,fcal2Mod); //1200000
741  fcal1Eta = 0; fcal1Phi = 0; fcal1Mod = 1000000;
742  initialFCAL1 = calcTowerID(fcal1Eta,fcal1Phi,fcal1Mod); //1000000
743  fcal0Eta = 0; fcal0Phi = 0; fcal0Mod = 800000;
744  initialFCAL0 = calcTowerID(fcal0Eta,fcal0Phi,fcal0Mod); //800000
745  emecEta = 15; emecPhi = 0; emecMod = 600000;
746  initialEMEC = calcTowerID(emecEta,emecPhi,emecMod); //600960;
747  transEta = 14; transPhi = 0; transMod = 400000;
748  initialTRANS = calcTowerID(transEta,transPhi,transMod); //400896;
749  embEta = 8; embPhi = 0; embMod = 200000;
750  initialEMB = calcTowerID(embEta,embPhi,embMod); //200512;
751 
752  // jFEX 5
753  thisJFEX = 5;
754 
755  // decide which subset of towers (and therefore supercells) should go to the jFEX
756  std::unordered_map<int,jTower> tmp_jTowersColl_subset_ENDCAP_AND_EMB_AND_FCAL_2;
757 
758  // let's try doing this with an array initially just containing tower IDs.
759  int tmp_jTowersIDs_subset_ENDCAP_AND_EMB_AND_FCAL_2 [2*FEXAlgoSpaceDefs::jFEX_algoSpace_height][FEXAlgoSpaceDefs::jFEX_wide_algoSpace_width];
760 
761  // zero the matrix out
762  for (int i = 0; i<2*FEXAlgoSpaceDefs::jFEX_algoSpace_height; i++){
763  for (int j = 0; j<FEXAlgoSpaceDefs::jFEX_wide_algoSpace_width; j++){
764  tmp_jTowersIDs_subset_ENDCAP_AND_EMB_AND_FCAL_2[i][j] = 0;
765  }
766  }
767 
768  rows = sizeof tmp_jTowersIDs_subset_ENDCAP_AND_EMB_AND_FCAL_2 / sizeof tmp_jTowersIDs_subset_ENDCAP_AND_EMB_AND_FCAL_2[0];
769  cols = sizeof tmp_jTowersIDs_subset_ENDCAP_AND_EMB_AND_FCAL_2[0] / sizeof tmp_jTowersIDs_subset_ENDCAP_AND_EMB_AND_FCAL_2[0][0];
770 
771  // set the EMB part
772  for(int thisCol = 0; thisCol < 6; thisCol++){
773  for(int thisRow=0; thisRow<rows; thisRow++){
774  int towerid = initialEMB + ( (thisCol) * 64) + thisRow;
775 
776  tmp_jTowersIDs_subset_ENDCAP_AND_EMB_AND_FCAL_2[thisRow][thisCol] = towerid;
777  tmp_jTowersColl_subset_ENDCAP_AND_EMB_AND_FCAL_2.insert( std::unordered_map<int, jTower>::value_type(towerid, *(this_jTowerContainer->findTower(towerid))));
778 
779  }
780  }
781 
782  // set the TRANS part
783  for(int thisRow = 0; thisRow < rows; thisRow++){
784  int towerid = initialTRANS + thisRow;
785 
786  tmp_jTowersIDs_subset_ENDCAP_AND_EMB_AND_FCAL_2[thisRow][6] = towerid;
787  tmp_jTowersColl_subset_ENDCAP_AND_EMB_AND_FCAL_2.insert( std::unordered_map<int, jTower>::value_type(towerid, *(this_jTowerContainer->findTower(towerid))));
788 
789  }
790 
791  // set the EMEC part
792  for(int thisCol=7; thisCol<17; thisCol++){
793  for(int thisRow=0; thisRow<rows; thisRow++){
794 
795  int towerid = initialEMEC + ((thisCol-7) * 64) + thisRow;
796 
797  tmp_jTowersIDs_subset_ENDCAP_AND_EMB_AND_FCAL_2[thisRow][thisCol] = towerid;
798  tmp_jTowersColl_subset_ENDCAP_AND_EMB_AND_FCAL_2.insert( std::unordered_map<int, jTower>::value_type(towerid, *(this_jTowerContainer->findTower(towerid))));
799 
800  }
801  }
802 
803  // set the next EMEC part
804  for(int thisCol=17; thisCol<21; thisCol++){
805  for(int thisRow=0; thisRow<rows/2; thisRow++){
806 
807  int towerid = initialEMEC + ((thisCol-7) * 64) + thisRow; //note special case -7 rather than -17, this *is* deliberate
808 
809  tmp_jTowersIDs_subset_ENDCAP_AND_EMB_AND_FCAL_2[thisRow][thisCol] = towerid;
810  tmp_jTowersColl_subset_ENDCAP_AND_EMB_AND_FCAL_2.insert( std::unordered_map<int, jTower>::value_type(towerid, *(this_jTowerContainer->findTower(towerid))));
811 
812  }
813  }
814 
815  //-----
816  // Let's go with FCAL0
817  // set the FCAL0 part
818  for(int thisCol=21; thisCol<33; thisCol++){
819  for(int thisRow=0; thisRow<rows/4; thisRow++){
820 
821  int towerid = initialFCAL0 + ((thisCol-21) * 64) + thisRow;
822 
823  tmp_jTowersIDs_subset_ENDCAP_AND_EMB_AND_FCAL_2[thisRow][thisCol] = towerid;
824  tmp_jTowersColl_subset_ENDCAP_AND_EMB_AND_FCAL_2.insert( std::unordered_map<int, jTower>::value_type(towerid, *(this_jTowerContainer->findTower(towerid))));
825 
826  }
827  }
828 
829  //---
830  // Let's go with FCAL1
831  // set the FCAL1 part
832  for(int thisCol=33; thisCol<41; thisCol++){
833  for(int thisRow=0; thisRow<rows/4; thisRow++){
834 
835  int towerid = initialFCAL1 + ((thisCol-33) * 64) + thisRow;
836 
837  tmp_jTowersIDs_subset_ENDCAP_AND_EMB_AND_FCAL_2[thisRow][thisCol] = towerid;
838  tmp_jTowersColl_subset_ENDCAP_AND_EMB_AND_FCAL_2.insert( std::unordered_map<int, jTower>::value_type(towerid, *(this_jTowerContainer->findTower(towerid))));
839 
840  }
841  }
842 
843  //---
844  // Let's go with FCAL2
845  // set the FCAL2 part
846  for(int thisCol=41; thisCol<45; thisCol++){
847  for(int thisRow=0; thisRow<rows/4; thisRow++){
848 
849  int towerid = initialFCAL2 + ((thisCol-41) * 64) + thisRow;
850 
851  tmp_jTowersIDs_subset_ENDCAP_AND_EMB_AND_FCAL_2[thisRow][thisCol] = towerid;
852  tmp_jTowersColl_subset_ENDCAP_AND_EMB_AND_FCAL_2.insert( std::unordered_map<int, jTower>::value_type(towerid, *(this_jTowerContainer->findTower(towerid))));
853 
854  }
855  }
856  //---
857 
858  if (msgLvl(MSG::DEBUG)) {
859  ATH_MSG_DEBUG("CONTENTS OF jFEX " << thisJFEX << " :");
860  for (int thisRow=rows-1; thisRow>=0; thisRow--) {
861  for (int thisCol=0; thisCol<cols; thisCol++) {
862  int tmptowerid = tmp_jTowersIDs_subset_ENDCAP_AND_EMB_AND_FCAL_2[thisRow][thisCol];
863  if(tmptowerid == 0) continue;
864  const LVL1::jTower* tmptower = this_jTowerContainer->findTower(tmptowerid);
865  const float tmptowereta = tmptower->iEta();
866  const float tmptowerphi = tmptower->iPhi();
867  if(thisCol != cols-1) {
868  ATH_MSG_DEBUG("| " << tmptowerid << "([" << tmptowerphi << "][" << tmptowereta << "]) ");
869  }
870  else {
871  ATH_MSG_DEBUG("| " << tmptowerid << "([" << tmptowereta << "][" << tmptowerphi << "]) |");
872  }
873  }
874  }
875  }
876 
877  m_jFEXSimTool->init(thisJFEX);
878  ATH_CHECK(m_jFEXSimTool->ExecuteForwardCSide(tmp_jTowersIDs_subset_ENDCAP_AND_EMB_AND_FCAL_2, inputOutputCollection, { evtTimeStamp, myDBTool->get_jJCalibParams(thisJFEX) } ));
879 
880  m_allSmallRJetTobs.insert(std::unordered_map<uint8_t, std::vector< std::vector<std::unique_ptr<jFEXTOB>> > >::value_type(thisJFEX,(m_jFEXSimTool->getSmallRJetTOBs() ) ));
881  m_allLargeRJetTobs.insert(std::unordered_map<uint8_t, std::vector< std::vector<std::unique_ptr<jFEXTOB>> > >::value_type(thisJFEX,(m_jFEXSimTool->getLargeRJetTOBs() ) ));
882  m_alltauTobs.insert( std::unordered_map<uint8_t, std::vector< std::vector<std::unique_ptr<jFEXTOB>> > >::value_type(thisJFEX,(m_jFEXSimTool->getTauTOBs() ) ));
883  m_allfwdElTobs.insert( std::unordered_map<uint8_t, std::vector<std::vector<std::vector<uint32_t>>> >::value_type(thisJFEX,(m_jFEXSimTool->getFwdElTOBs() ) ));
884 
885  m_allsumEtTobs.insert(std::unordered_map<uint8_t, std::vector<std::unique_ptr<jFEXTOB>> >::value_type(thisJFEX,(m_jFEXSimTool->getSumEtTOBs() ) ));
886  m_allMetTobs.insert(std::unordered_map<uint8_t, std::vector<std::unique_ptr<jFEXTOB>> >::value_type(thisJFEX,(m_jFEXSimTool->getMetTOBs() ) ));
887  m_jFEXSimTool->reset();
888 
889 
890  //-----------------------------------------------------FILLING EDMs--------------------------------------------------------------------------------
891 
892  //Reading the Trigger menu to send the jFEX Resolution to the EDMs
893 
895 
896  const int jFwdElResolution = l1Menu->thrExtraInfo().jEM().resolutionMeV();
897 
898  //---SRJet EDM
899  auto tobContainer_jJ = std::make_unique<xAOD::jFexSRJetRoIContainer> ();
900  std::unique_ptr< xAOD::jFexSRJetRoIAuxContainer > tobAuxContainer_jJ = std::make_unique<xAOD::jFexSRJetRoIAuxContainer> ();
901  tobContainer_jJ->setStore(tobAuxContainer_jJ.get());
902 
904 
905  auto xtobContainer_jJ = std::make_unique<xAOD::jFexSRJetRoIContainer> ();
906  std::unique_ptr< xAOD::jFexSRJetRoIAuxContainer > xtobAuxContainer_jJ = std::make_unique<xAOD::jFexSRJetRoIAuxContainer> ();
907  xtobContainer_jJ->setStore(xtobAuxContainer_jJ.get());
908 
910 
911 
913  ATH_MSG_DEBUG(" write: " << output_Tob_jJ.key() << " = " << "..." );
914  ATH_CHECK(output_Tob_jJ.record(std::move(tobContainer_jJ),std::move(tobAuxContainer_jJ)));
915 
917  ATH_MSG_DEBUG(" write: " << output_xTob_jJ.key() << " = " << "..." );
918  ATH_CHECK(output_xTob_jJ.record(std::move(xtobContainer_jJ),std::move(xtobAuxContainer_jJ)));
919 
920  // iterate over all SRJEt Tobs and fill EDM with them m_allSmallRJetTobs
921  for( auto const& [jfex, fpga] : m_allSmallRJetTobs ) {
922  for(auto const & tobs: fpga) {
923  for(size_t it = 0; it<tobs.size();it++) {
924  float_t eta = -99;
925  float_t phi = -99;
926  char istob = 0;
927  if(tobs.at(it)->getWord() != 0) {
928  eta = (this_jTowerContainer->findTower( tobs.at(it)->getTTID() ))->centreEta();
929  phi = (this_jTowerContainer->findTower( tobs.at(it)->getTTID() ))->centrephi_toPI();
930  }
931 
932  // Just sending 7 SRjets to L1Topo and HLT chain
933  if(it<7){
934  istob = 1;
935  ATH_CHECK(fillSRJetEDM(tobs.at(it), istob, eta, phi, output_Tob_jJ));
936  tobDec_jJ_seedET( *(output_Tob_jJ->back()) ) = tobs.at(it)->getSeedEt();
937  }
938  ATH_CHECK(fillSRJetEDM(tobs.at(it), istob, eta, phi, output_xTob_jJ));
939  xtobDec_jJ_seedET( *(output_xTob_jJ->back()) ) = tobs.at(it)->getSeedEt();
940  }
941  }
942  }
943 
944  //---LRJet EDM
945  auto tobContainer_jLJ = std::make_unique<xAOD::jFexLRJetRoIContainer> ();
946  std::unique_ptr< xAOD::jFexLRJetRoIAuxContainer > tobAuxContainer_jLJ = std::make_unique<xAOD::jFexLRJetRoIAuxContainer> ();
947  tobContainer_jLJ->setStore(tobAuxContainer_jLJ.get());
948 
949  auto xtobContainer_jLJ = std::make_unique<xAOD::jFexLRJetRoIContainer> ();
950  std::unique_ptr< xAOD::jFexLRJetRoIAuxContainer > xtobAuxContainer_jLJ = std::make_unique<xAOD::jFexLRJetRoIAuxContainer> ();
951  xtobContainer_jLJ->setStore(xtobAuxContainer_jLJ.get());
952 
953 
955  ATH_MSG_DEBUG(" write: " << output_Tob_jLJ.key() << " = " << "..." );
956  ATH_CHECK(output_Tob_jLJ.record(std::move(tobContainer_jLJ),std::move(tobAuxContainer_jLJ)));
957 
959  ATH_MSG_DEBUG(" write: " << output_xTob_jLJ.key() << " = " << "..." );
960  ATH_CHECK(output_xTob_jLJ.record(std::move(xtobContainer_jLJ),std::move(xtobAuxContainer_jLJ)));
961 
962  m_allLargeRJetTobs.clear(); // Aug2025: no longer filling the jLJ container, but will still produce the container to avoid EDM changes
963 
964  // iterate over all LRJEt Tobs and fill EDM with them
965  for(auto const& [jfex, fpga] : m_allLargeRJetTobs ) {
966  for(auto const& tobs: fpga) {
967  for(size_t it = 0; it<tobs.size();it++) {
968  float_t eta = -99;
969  float_t phi = -99;
970  char istob = 0;
971  if(tobs.at(it)->getWord() != 0) {
972  eta = (this_jTowerContainer->findTower( tobs.at(it)->getTTID() ))->centreEta();
973  phi = (this_jTowerContainer->findTower( tobs.at(it)->getTTID() ))->centrephi_toPI();
974  }
975 
976  // Just sending 1 LRjets to L1Topo and HLT chain
977  if(it<1){
978  istob=1;
979  ATH_CHECK(fillLRJetEDM(tobs.at(it), istob, eta, phi, output_Tob_jLJ));
980  }
981  ATH_CHECK(fillLRJetEDM(tobs.at(it), istob, eta, phi, output_xTob_jLJ));
982  }
983  }
984  }
985  //---Tau EDM
986  auto tobContainer_jTau = std::make_unique<xAOD::jFexTauRoIContainer> ();
987  std::unique_ptr< xAOD::jFexTauRoIAuxContainer > tobAuxContainer_jTau = std::make_unique<xAOD::jFexTauRoIAuxContainer> ();
988  tobContainer_jTau->setStore(tobAuxContainer_jTau.get());
989 
990  auto xtobContainer_jTau = std::make_unique<xAOD::jFexTauRoIContainer> ();
991  std::unique_ptr< xAOD::jFexTauRoIAuxContainer > xtobAuxContainer_jTau = std::make_unique<xAOD::jFexTauRoIAuxContainer> ();
992  xtobContainer_jTau->setStore(xtobAuxContainer_jTau.get());
993 
995  ATH_MSG_DEBUG(" write: " << output_Tob_jTau.key() << " = " << "..." );
996  ATH_CHECK(output_Tob_jTau.record(std::move(tobContainer_jTau),std::move(tobAuxContainer_jTau)));
997 
999  ATH_MSG_DEBUG(" write: " << output_xTob_jTau.key() << " = " << "..." );
1000  ATH_CHECK(output_xTob_jTau.record(std::move(xtobContainer_jTau),std::move(xtobAuxContainer_jTau)));
1001 
1002  //iterate over all Tau Tobs and fill EDM with
1003  for( auto const& [jfex, fpga] : m_alltauTobs ) {
1004  for(auto const& tobs : fpga){
1005  for(size_t it = 0; it<tobs.size();it++) {
1006  float_t eta = -99;
1007  float_t phi = -99;
1008  char istob = 0;
1009  if(tobs.at(it)->getWord() != 0){
1010  eta = (this_jTowerContainer->findTower( tobs.at(it)->getTTID() ))->centreEta();
1011  phi = (this_jTowerContainer->findTower( tobs.at(it)->getTTID() ))->centrephi_toPI();
1012  }
1013 
1014  // Just sending 6 Taus to L1Topo and HLT chain
1015  if(it<6){
1016  istob=1;
1017  ATH_CHECK(fillTauEDM(tobs.at(it), istob, eta, phi, output_Tob_jTau));
1018  }
1019  ATH_CHECK(fillTauEDM(tobs.at(it), istob, eta, phi, output_xTob_jTau));
1020  }
1021  }
1022 
1023  }
1024 
1025  //---Forward Elec EDM
1026  auto tobContainer_jEM = std::make_unique<xAOD::jFexFwdElRoIContainer> ();
1027  std::unique_ptr< xAOD::jFexFwdElRoIAuxContainer > tobAuxContainer_jEM = std::make_unique<xAOD::jFexFwdElRoIAuxContainer> ();
1028  tobContainer_jEM->setStore(tobAuxContainer_jEM.get());
1029 
1030  auto xtobContainer_jEM = std::make_unique<xAOD::jFexFwdElRoIContainer> ();
1031  std::unique_ptr< xAOD::jFexFwdElRoIAuxContainer > xtobAuxContainer_jEM = std::make_unique<xAOD::jFexFwdElRoIAuxContainer> ();
1032  xtobContainer_jEM->setStore(xtobAuxContainer_jEM.get());
1033 
1035  ATH_MSG_DEBUG(" write: " << output_Tob_jEM.key() << " = " << "..." );
1036  ATH_CHECK(output_Tob_jEM.record(std::move(tobContainer_jEM),std::move(tobAuxContainer_jEM)));
1037 
1039  ATH_MSG_DEBUG(" write: " << output_xTob_jEM.key() << " = " << "..." );
1040  ATH_CHECK(output_xTob_jEM.record(std::move(xtobContainer_jEM),std::move(xtobAuxContainer_jEM)));
1041 
1042  //iterate over all Forward Elec Tobs and fill EDM
1043  for( auto const& [jfex, MODULE_tobs] : m_allfwdElTobs ) {
1044  const int fpga_map[4]={0,1,3,2}; // No FPGA info available in FWD EL TOB
1045  uint8_t fpgaNum =0;
1046  for(auto &FPGA_tob : MODULE_tobs) {
1047  if (fpgaNum>3) {
1048  ATH_MSG_ERROR("FPGA larger than 4 in Forward electron EDM!");
1049  continue;
1050  }
1051  for(size_t it = 0; it<FPGA_tob.size();it++) {
1052  float_t eta = -99;
1053  float_t phi = -99;
1054  char istob = 0;
1055  if(FPGA_tob.at(it).at(1) != 0) {
1056  eta = (this_jTowerContainer->findTower(FPGA_tob.at(it).at(1)))->centreEta();
1057  phi = (this_jTowerContainer->findTower(FPGA_tob.at(it).at(1)))->centrephi_toPI();
1058  }
1059 
1060  if(it<5){
1061  istob=1;
1062  ATH_CHECK(fillFwdElEDM(jfex,fpga_map[fpgaNum], FPGA_tob.at(it).at(0),istob, jFwdElResolution, eta, phi, output_Tob_jEM));
1063  }
1064  ATH_CHECK(fillFwdElEDM(jfex,fpga_map[fpgaNum], FPGA_tob.at(it).at(0),istob, jFwdElResolution, eta, phi, output_xTob_jEM));
1065  }
1066  fpgaNum++;
1067  }
1068 
1069  }
1070 
1071  //---SumET EDM
1072  auto tobContainer_jTE = std::make_unique<xAOD::jFexSumETRoIContainer> ();
1073  std::unique_ptr< xAOD::jFexSumETRoIAuxContainer > tobAuxContainer_jTE = std::make_unique<xAOD::jFexSumETRoIAuxContainer> ();
1074  tobContainer_jTE->setStore(tobAuxContainer_jTE.get());
1075 
1077  ATH_MSG_DEBUG(" write: " << output_Tob_jTE.key() << " = " << "..." );
1078  ATH_CHECK(output_Tob_jTE.record(std::move(tobContainer_jTE),std::move(tobAuxContainer_jTE)));
1079 
1080  for( auto const& [jfex, tobs] : m_allsumEtTobs ) {
1081 
1082  for(auto const& t : tobs) {
1083  ATH_CHECK(fillSumEtEDM(t, output_Tob_jTE));
1084  }
1085  }
1086 
1087  //---MET EDM
1088  auto tobContainer_jXE = std::make_unique<xAOD::jFexMETRoIContainer> ();
1089  std::unique_ptr< xAOD::jFexMETRoIAuxContainer > tobAuxContainer_jXE = std::make_unique<xAOD::jFexMETRoIAuxContainer> ();
1090  tobContainer_jXE->setStore(tobAuxContainer_jXE.get());
1091 
1093  ATH_MSG_DEBUG(" write: " << output_Tob_jXE.key() << " = " << "..." );
1094  ATH_CHECK(output_Tob_jXE.record(std::move(tobContainer_jXE),std::move(tobAuxContainer_jXE)));
1095 
1096  for( auto const& [jfex, tobs] : m_allMetTobs ) {
1097 
1098  for(auto const& t : tobs) {
1099  ATH_CHECK(fillMetEDM(t, output_Tob_jXE));
1100  }
1101  }
1102 
1103 
1104 
1105  //Send TOBs to bytestream?
1106  // ToDo
1107  // To implement
1108  // {--Implement--}
1109 
1110  return StatusCode::SUCCESS;
1111 
1112  }

◆ 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

◆ fillFwdElEDM()

StatusCode LVL1::jFEXSysSim::fillFwdElEDM ( uint8_t  jFexNum,
uint8_t  fpgaNumber,
uint32_t  tobWord,
char  istob,
int  resolution,
float_t  eta,
float_t  phi,
SG::WriteHandle< xAOD::jFexFwdElRoIContainer > &  jContainer 
) const
private

Definition at line 1140 of file jFEXSysSim.cxx.

1140  {
1141 
1142  xAOD::jFexFwdElRoI* my_EDM = new xAOD::jFexFwdElRoI();
1143  jContainer->push_back( my_EDM );
1144 
1145  my_EDM->initialize(jFexNum, fpgaNumber, tobWord ,istob , resolution, eta, phi);
1146 
1147  ATH_MSG_DEBUG(" setting Forward Elec jFEX Number: " << +my_EDM->jFexNumber() << " et: " << my_EDM->et() << " eta: " << my_EDM->eta() <<" / "<< eta << " phi: " << my_EDM->phi()<<" / "<< phi );
1148 
1149  return StatusCode::SUCCESS;
1150  }

◆ fillLRJetEDM()

StatusCode LVL1::jFEXSysSim::fillLRJetEDM ( const std::unique_ptr< jFEXTOB > &  internalTob,
char  istob,
float_t  eta,
float_t  phi,
SG::WriteHandle< xAOD::jFexLRJetRoIContainer > &  jContainer 
) const
private

Definition at line 1152 of file jFEXSysSim.cxx.

1152  {
1153 
1154  xAOD::jFexLRJetRoI* my_EDM = new xAOD::jFexLRJetRoI();
1155  jContainer->push_back( my_EDM );
1156 
1157  my_EDM->initialize(internalTob->getjFex(), internalTob->getFpga(), internalTob->getWord(), istob, internalTob->getRes(), eta, phi);
1158 
1159  ATH_MSG_DEBUG(" setting LRJet jFEX Number: " << +my_EDM->jFexNumber() << " et: " << my_EDM->et() << " eta: " << my_EDM->eta() <<" / "<< eta << " phi: " << my_EDM->phi()<<" / "<< phi );
1160 
1161  return StatusCode::SUCCESS;
1162  }

◆ fillMetEDM()

StatusCode LVL1::jFEXSysSim::fillMetEDM ( const std::unique_ptr< jFEXTOB > &  internalTob,
SG::WriteHandle< xAOD::jFexMETRoIContainer > &  jContainer 
) const
private

Definition at line 1176 of file jFEXSysSim.cxx.

1176  {
1177 
1178  xAOD::jFexMETRoI* my_EDM = new xAOD::jFexMETRoI();
1179  jContainer->push_back( my_EDM );
1180 
1181  my_EDM->initialize(internalTob->getjFex(), internalTob->getFpga(), internalTob->getWord(), internalTob->getRes());
1182 
1183  ATH_MSG_DEBUG(" setting MET jFEX Number: " << +my_EDM->jFexNumber() << " Et_x: " << my_EDM->tobEx() << " Et_y: " << my_EDM->tobEy() << " sat: " << my_EDM->tobSat()<< " res: " << my_EDM->tobRes() );
1184 
1185  return StatusCode::SUCCESS;
1186  }

◆ fillSRJetEDM()

StatusCode LVL1::jFEXSysSim::fillSRJetEDM ( const std::unique_ptr< jFEXTOB > &  internalTob,
char  istob,
float_t  eta,
float_t  phi,
SG::WriteHandle< xAOD::jFexSRJetRoIContainer > &  jContainer 
) const
private

Definition at line 1115 of file jFEXSysSim.cxx.

1115  {
1116 
1117  xAOD::jFexSRJetRoI* my_EDM = new xAOD::jFexSRJetRoI();
1118  jContainer->push_back( my_EDM );
1119 
1120  my_EDM->initialize(internalTob->getjFex(), internalTob->getFpga(), internalTob->getWord(), istob, internalTob->getRes(), eta, phi);
1121 
1122  ATH_MSG_DEBUG(" setting SRJet jFEX Number: " << +my_EDM->jFexNumber() << " et: " << my_EDM->et() << " eta: " << my_EDM->eta() <<" / "<< eta << " phi: " << my_EDM->phi()<<" / "<< phi );
1123 
1124  return StatusCode::SUCCESS;
1125  }

◆ fillSumEtEDM()

StatusCode LVL1::jFEXSysSim::fillSumEtEDM ( const std::unique_ptr< jFEXTOB > &  internalTob,
SG::WriteHandle< xAOD::jFexSumETRoIContainer > &  jContainer 
) const
private

Definition at line 1164 of file jFEXSysSim.cxx.

1164  {
1165 
1166  xAOD::jFexSumETRoI* my_EDM = new xAOD::jFexSumETRoI();
1167  jContainer->push_back( my_EDM );
1168 
1169  my_EDM->initialize(internalTob->getjFex(), internalTob->getFpga(), internalTob->getWord(), internalTob->getRes());
1170 
1171  ATH_MSG_DEBUG(" setting SumET jFEX Number: " << +my_EDM->jFexNumber() << " Et_up: " << my_EDM->tobEt_upper() << " Et_down: " << my_EDM->tobEt_lower() << " sat_up: " << my_EDM->tobSat_upper()<< " sat_low: " << my_EDM->tobSat_lower());
1172 
1173  return StatusCode::SUCCESS;
1174  }

◆ fillTauEDM()

StatusCode LVL1::jFEXSysSim::fillTauEDM ( const std::unique_ptr< jFEXTOB > &  internalTob,
char  istob,
float_t  eta,
float_t  phi,
SG::WriteHandle< xAOD::jFexTauRoIContainer > &  jContainer 
) const
private

Definition at line 1128 of file jFEXSysSim.cxx.

1128  {
1129 
1130  xAOD::jFexTauRoI* my_EDM = new xAOD::jFexTauRoI();
1131  jContainer->push_back( my_EDM );
1132 
1133  my_EDM->initialize(internalTob->getjFex(), internalTob->getFpga(), internalTob->getWord(), istob, internalTob->getRes(), eta, phi);
1134 
1135  ATH_MSG_DEBUG(" setting tau jFEX Number: " << +my_EDM->jFexNumber() << " et: " << my_EDM->et() << " eta: " << my_EDM->eta() <<" / "<< eta << " phi: " << my_EDM->phi()<<" / "<< phi );
1136 
1137  return StatusCode::SUCCESS;
1138  }

◆ finalize()

StatusCode LVL1::jFEXSysSim::finalize ( )
overridevirtual

standard Athena-Algorithm method

Definition at line 84 of file jFEXSysSim.cxx.

85  {
86  return StatusCode::SUCCESS;
87  }

◆ init()

void LVL1::jFEXSysSim::init ( ) const
overridevirtual

Implements LVL1::IjFEXSysSim.

Definition at line 90 of file jFEXSysSim.cxx.

90  {
91 
92  }

◆ initialize()

StatusCode LVL1::jFEXSysSim::initialize ( )
overridevirtual

standard Athena-Algorithm method

Destructor.

Definition at line 51 of file jFEXSysSim.cxx.

52  {
53 
55 
56  ATH_CHECK( m_DBToolKey.initialize() );
57  ATH_CHECK(m_jFEXSimTool.retrieve() );
58 
59  // TOBs Key
60  ATH_CHECK(m_TobOutKey_jJ.initialize());
61  ATH_CHECK(m_TobOutKey_jLJ.initialize());
62  ATH_CHECK(m_TobOutKey_jTau.initialize());
63  ATH_CHECK(m_TobOutKey_jEM.initialize());
64  ATH_CHECK(m_TobOutKey_jTE.initialize());
65  ATH_CHECK(m_TobOutKey_jXE.initialize());
66 
67  // xTOBs Key
68  ATH_CHECK(m_xTobOutKey_jJ.initialize());
69  ATH_CHECK(m_xTobOutKey_jLJ.initialize());
70  ATH_CHECK(m_xTobOutKey_jTau.initialize());
71  ATH_CHECK(m_xTobOutKey_jEM.initialize());
72 
73  // Decorations
74  ATH_CHECK(m_TobDecorKey_jJ_seedET.initialize());
75  ATH_CHECK(m_xTobDecorKey_jJ_seedET.initialize());
76 
78 
79  return StatusCode::SUCCESS;
80  }

◆ 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::IjFEXSysSim::interfaceID ( )
inlinestaticinherited

Definition at line 58 of file IjFEXSysSim.h.

59  {
60  return IID_IjFEXSysSim;
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  }

◆ operator=()

jFEXSysSim&& LVL1::jFEXSysSim::operator= ( const jFEXSysSim )
delete

Destructor.

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

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

std::unordered_map<uint8_t, std::vector<std::vector<std::vector<uint32_t> > > > LVL1::jFEXSysSim::m_allfwdElTobs
private

Definition at line 105 of file jFEXSysSim.h.

◆ m_allLargeRJetTobs

std::unordered_map<uint8_t, std::vector<std::vector<std::unique_ptr<jFEXTOB> > > > LVL1::jFEXSysSim::m_allLargeRJetTobs
private

Definition at line 109 of file jFEXSysSim.h.

◆ m_allMetTobs

std::unordered_map<uint8_t, std::vector<std::unique_ptr<jFEXTOB> > > LVL1::jFEXSysSim::m_allMetTobs
private

Definition at line 111 of file jFEXSysSim.h.

◆ m_allSmallRJetTobs

std::unordered_map<uint8_t, std::vector<std::vector<std::unique_ptr<jFEXTOB> > > > LVL1::jFEXSysSim::m_allSmallRJetTobs
private

Definition at line 108 of file jFEXSysSim.h.

◆ m_allsumEtTobs

std::unordered_map<uint8_t, std::vector<std::unique_ptr<jFEXTOB> > > LVL1::jFEXSysSim::m_allsumEtTobs
private

Definition at line 110 of file jFEXSysSim.h.

◆ m_alltauTobs

std::unordered_map<uint8_t, std::vector<std::vector<std::unique_ptr<jFEXTOB> > > > LVL1::jFEXSysSim::m_alltauTobs
private

Definition at line 107 of file jFEXSysSim.h.

◆ m_DBToolKey

SG::ReadCondHandleKey<jFEXDBCondData> LVL1::jFEXSysSim::m_DBToolKey {this, "DBToolKey", "jFEXDBParams", "DB tool key"}
private

Definition at line 76 of file jFEXSysSim.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_jFEXCollection

std::vector<jFEXSim*> LVL1::jFEXSysSim::m_jFEXCollection
private

Internal data.

Definition at line 74 of file jFEXSysSim.h.

◆ m_jFEXSimTool

ToolHandle<IjFEXSim> LVL1::jFEXSysSim::m_jFEXSimTool {this, "jFEXSimTool", "LVL1::jFEXSim", "Tool that creates the jFEX Simulation"}
private

Definition at line 78 of file jFEXSysSim.h.

◆ m_jTowerContainerSGKey

SG::ReadHandleKey<LVL1::jTowerContainer> LVL1::jFEXSysSim::m_jTowerContainerSGKey {this, "MyETowers", "jTowerContainer", "Input container for jTowers"}
private

Definition at line 80 of file jFEXSysSim.h.

◆ m_jTowersColl

std::unordered_map<int,jTower> LVL1::jFEXSysSim::m_jTowersColl
private

Definition at line 103 of file jFEXSysSim.h.

◆ m_l1MenuKey

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

Definition at line 82 of file jFEXSysSim.h.

◆ m_TobDecorKey_jJ_seedET

SG::WriteDecorHandleKey<xAOD::jFexSRJetRoIContainer> LVL1::jFEXSysSim::m_TobDecorKey_jJ_seedET { this, "Key_tobDecor_jJ_seedET" , m_TobOutKey_jJ , "seedETMeV" , "jJet seed ET value in MeV" }
private

Definition at line 99 of file jFEXSysSim.h.

◆ m_TobOutKey_jEM

SG::WriteHandleKey< xAOD::jFexFwdElRoIContainer> LVL1::jFEXSysSim::m_TobOutKey_jEM {this,"Key_jFexFwdElOutputContainer","L1_jFexFwdElRoI","Output jFexEDM fwdEl container"}
private

Definition at line 88 of file jFEXSysSim.h.

◆ m_TobOutKey_jJ

SG::WriteHandleKey< xAOD::jFexSRJetRoIContainer> LVL1::jFEXSysSim::m_TobOutKey_jJ {this,"Key_jFexSRJetOutputContainer","L1_jFexSRJetRoI","Output jFexEDM jets container"}
private

Definition at line 85 of file jFEXSysSim.h.

◆ m_TobOutKey_jLJ

SG::WriteHandleKey< xAOD::jFexLRJetRoIContainer> LVL1::jFEXSysSim::m_TobOutKey_jLJ {this,"Key_jFexLRJetOutputContainer","L1_jFexLRJetRoI","Output jFexEDM Ljets container"}
private

Definition at line 86 of file jFEXSysSim.h.

◆ m_TobOutKey_jTau

SG::WriteHandleKey< xAOD::jFexTauRoIContainer> LVL1::jFEXSysSim::m_TobOutKey_jTau {this,"Key_jFexTauOutputContainer" ,"L1_jFexTauRoI" ,"Output jFexEDM tau container"}
private

Definition at line 87 of file jFEXSysSim.h.

◆ m_TobOutKey_jTE

SG::WriteHandleKey< xAOD::jFexSumETRoIContainer> LVL1::jFEXSysSim::m_TobOutKey_jTE {this,"Key_jFexSumETOutputContainer","L1_jFexSumETRoI","Output jFexEDM SumET container"}
private

Definition at line 89 of file jFEXSysSim.h.

◆ m_TobOutKey_jXE

SG::WriteHandleKey< xAOD::jFexMETRoIContainer> LVL1::jFEXSysSim::m_TobOutKey_jXE {this,"Key_jFexMETOutputContainer" ,"L1_jFexMETRoI" ,"Output jFexEDM Met container"}
private

Definition at line 90 of file jFEXSysSim.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.

◆ m_xTobDecorKey_jJ_seedET

SG::WriteDecorHandleKey<xAOD::jFexSRJetRoIContainer> LVL1::jFEXSysSim::m_xTobDecorKey_jJ_seedET { this, "Key_xTobDecor_jJ_seedET" , m_xTobOutKey_jJ , "seedETMeV" , "jJet seed ET value in MeV" }
private

Definition at line 100 of file jFEXSysSim.h.

◆ m_xTobOutKey_jEM

SG::WriteHandleKey< xAOD::jFexFwdElRoIContainer> LVL1::jFEXSysSim::m_xTobOutKey_jEM {this,"Key_xTobOutKey_jEM" ,"L1_jFexFwdElxRoI","Output jFexEDM xTOBs fwdEl container"}
private

Definition at line 96 of file jFEXSysSim.h.

◆ m_xTobOutKey_jJ

SG::WriteHandleKey< xAOD::jFexSRJetRoIContainer> LVL1::jFEXSysSim::m_xTobOutKey_jJ {this,"Key_xTobOutKey_jJ" ,"L1_jFexSRJetxRoI","Output jFexEDM xTOBs jets container"}
private

Definition at line 93 of file jFEXSysSim.h.

◆ m_xTobOutKey_jLJ

SG::WriteHandleKey< xAOD::jFexLRJetRoIContainer> LVL1::jFEXSysSim::m_xTobOutKey_jLJ {this,"Key_xTobOutKey_jLJ" ,"L1_jFexLRJetxRoI","Output jFexEDM xTOBs Ljets container"}
private

Definition at line 94 of file jFEXSysSim.h.

◆ m_xTobOutKey_jTau

SG::WriteHandleKey< xAOD::jFexTauRoIContainer> LVL1::jFEXSysSim::m_xTobOutKey_jTau {this,"Key_xTobOutKey_jTau" ,"L1_jFexTauxRoI" ,"Output jFexEDM xTOBs tau container"}
private

Definition at line 95 of file jFEXSysSim.h.


The documentation for this class was generated from the following files:
LVL1::jFEXSysSim::fillLRJetEDM
StatusCode fillLRJetEDM(const std::unique_ptr< jFEXTOB > &internalTob, char istob, float_t eta, float_t phi, SG::WriteHandle< xAOD::jFexLRJetRoIContainer > &jContainer) const
Definition: jFEXSysSim.cxx:1152
xAOD::jFexTauRoI_v1
Class describing properties of a LVL1 jFEX global Trigger Object (TOB) in the xAOD format.
Definition: jFexTauRoI_v1.h:23
LVL1::jFEXSysSim::m_TobOutKey_jJ
SG::WriteHandleKey< xAOD::jFexSRJetRoIContainer > m_TobOutKey_jJ
Definition: jFEXSysSim.h:85
xAOD::jFexSRJetRoI_v1
Class describing properties of a LVL1 jFEX global Trigger Object (TOB) in the xAOD format.
Definition: jFexSRJetRoI_v1.h:23
LVL1::jFEXSysSim::m_allLargeRJetTobs
std::unordered_map< uint8_t, std::vector< std::vector< std::unique_ptr< jFEXTOB > > > > m_allLargeRJetTobs
Definition: jFEXSysSim.h:109
LVL1::jFEXSysSim::fillMetEDM
StatusCode fillMetEDM(const std::unique_ptr< jFEXTOB > &internalTob, SG::WriteHandle< xAOD::jFexMETRoIContainer > &jContainer) const
Definition: jFEXSysSim.cxx:1176
xAOD::jFexTauRoI_v1::eta
float eta() const
phi
Scalar phi() const
phi method
Definition: AmgMatrixBasePlugin.h:67
xAOD::jFexTauRoI_v1::jFexNumber
uint8_t jFexNumber() const
SG::ReadCondHandle
Definition: ReadCondHandle.h:44
LVL1::jTower::iEta
int iEta() const
Get coordinates of tower.
Definition: jTower.cxx:166
xAOD::uint8_t
uint8_t
Definition: Muon_v1.cxx:558
xAOD::jFexLRJetRoI_v1::eta
float eta() const
LVL1::FEXAlgoSpaceDefs::jFEX_thin_algoSpace_width
constexpr static int jFEX_thin_algoSpace_width
Definition: FEXAlgoSpaceDefs.h:28
xAOD::jFexLRJetRoI
jFexLRJetRoI_v1 jFexLRJetRoI
Define the latest version of the jFexLRJetRoI class
Definition: jFexLRJetRoI.h:13
eta
Scalar eta() const
pseudorapidity method
Definition: AmgMatrixBasePlugin.h:83
SG::ReadHandle< LVL1::jTowerContainer >
xAOD::jFexFwdElRoI_v1::eta
float eta() const
LVL1::jFEXSysSim::m_allSmallRJetTobs
std::unordered_map< uint8_t, std::vector< std::vector< std::unique_ptr< jFEXTOB > > > > m_allSmallRJetTobs
Definition: jFEXSysSim.h:108
LVL1::jFEXSysSim::m_jFEXSimTool
ToolHandle< IjFEXSim > m_jFEXSimTool
Definition: jFEXSysSim.h:78
LVL1::jFEXSysSim::m_alltauTobs
std::unordered_map< uint8_t, std::vector< std::vector< std::unique_ptr< jFEXTOB > > > > m_alltauTobs
Definition: jFEXSysSim.h:107
xAOD::jFexFwdElRoI_v1::jFexNumber
uint8_t jFexNumber() const
Additional info (initialization)
skel.it
it
Definition: skel.GENtoEVGEN.py:407
xAOD::jFexFwdElRoI_v1::phi
float phi() const
SG::ReadCondHandle::isValid
bool isValid()
Definition: ReadCondHandle.h:210
AthCommonDataStore< AthCommonMsg< AlgTool > >::m_evtStore
StoreGateSvc_t m_evtStore
Pointer to StoreGate (event store by default)
Definition: AthCommonDataStore.h:390
AthCommonDataStore< AthCommonMsg< AlgTool > >::m_vhka
std::vector< SG::VarHandleKeyArray * > m_vhka
Definition: AthCommonDataStore.h:398
xAOD::jFexLRJetRoI_v1::jFexNumber
uint8_t jFexNumber() const
AthCommonMsg< AlgTool >::msgLvl
bool msgLvl(const MSG::Level lvl) const
Definition: AthCommonMsg.h:30
xAOD::jFexLRJetRoI_v1::et
unsigned int et() const
Methods that require combining results or applying scales.
Definition: jFexLRJetRoI_v1.cxx:139
xAOD::jFexSRJetRoI_v1::eta
float eta() const
xAOD::jFexSRJetRoI_v1::phi
float phi() const
LVL1::FEXAlgoSpaceDefs::jFEX_algoSpace_height
constexpr static int jFEX_algoSpace_height
Definition: FEXAlgoSpaceDefs.h:29
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
xAOD::jFexMETRoI_v1::initialize
void initialize(uint8_t jFexNumber, uint8_t fpgaNumber, uint32_t tobWord, int resolution)
In future initialze the xTOB as well, word1.
Definition: jFexMETRoI_v1.cxx:20
xAOD::jFexTauRoI_v1::et
unsigned int et() const
Methods that require combining results or applying scales.
Definition: jFexTauRoI_v1.cxx:114
LVL1::jFEXSysSim::m_l1MenuKey
SG::ReadHandleKey< TrigConf::L1Menu > m_l1MenuKey
Definition: jFEXSysSim.h:82
Dedxcorrection::resolution
double resolution[nGasTypes][nParametersResolution]
Definition: TRT_ToT_Corrections.h:46
python.CaloAddPedShiftConfig.type
type
Definition: CaloAddPedShiftConfig.py:42
LVL1::jFEXSysSim::m_xTobDecorKey_jJ_seedET
SG::WriteDecorHandleKey< xAOD::jFexSRJetRoIContainer > m_xTobDecorKey_jJ_seedET
Definition: jFEXSysSim.h:100
xAOD::jFexMETRoI_v1::jFexNumber
uint8_t jFexNumber() const
SG::VarHandleKeyArray::setOwner
virtual void setOwner(IDataHandleHolder *o)=0
xAOD::jFexMETRoI_v1
Class describing properties of a LVL1 jFEX global Trigger Object (TOB) in the xAOD format.
Definition: jFexMETRoI_v1.h:22
IDTPMcnv.htype
htype
Definition: IDTPMcnv.py:29
LVL1::jFEXSysSim::m_TobOutKey_jEM
SG::WriteHandleKey< xAOD::jFexFwdElRoIContainer > m_TobOutKey_jEM
Definition: jFEXSysSim.h:88
LVL1::jFEXSysSim::calcTowerID
virtual int calcTowerID(int eta, int phi, int mod) const override
Definition: jFEXSysSim.cxx:102
AthCommonDataStore::declareGaudiProperty
Gaudi::Details::PropertyBase & declareGaudiProperty(Gaudi::Property< T, V, H > &hndl, const SG::VarHandleKeyType &)
specialization for handling Gaudi::Property<SG::VarHandleKey>
Definition: AthCommonDataStore.h:156
LVL1::jFEXSysSim::m_jTowersColl
std::unordered_map< int, jTower > m_jTowersColl
Definition: jFEXSysSim.h:103
xAOD::jFexMETRoI_v1::tobSat
uint8_t tobSat() const
xAOD::jFexTauRoI_v1::initialize
void initialize(uint8_t jFexNumber, uint8_t fpgaNumber, uint32_t tobWord, char istob, int resolution, float_t eta, float_t phi)
In future initialze the EDM.
Definition: jFexTauRoI_v1.cxx:21
beamspotnt.cols
list cols
Definition: bin/beamspotnt.py:1113
LVL1::jFEXSysSim::m_jTowerContainerSGKey
SG::ReadHandleKey< LVL1::jTowerContainer > m_jTowerContainerSGKey
Definition: jFEXSysSim.h:80
xAOD::jFexLRJetRoI_v1
Class describing properties of a LVL1 jFEX global Trigger Object (TOB) in the xAOD format.
Definition: jFexLRJetRoI_v1.h:23
python.utils.AtlRunQueryDQUtils.p
p
Definition: AtlRunQueryDQUtils.py:209
AthCommonDataStore
Definition: AthCommonDataStore.h:52
ATH_MSG_ERROR
#define ATH_MSG_ERROR(x)
Definition: AthMsgStreamMacros.h:33
xAOD::jFexSumETRoI_v1::initialize
void initialize(uint8_t jFexNumber, uint8_t fpgaNumber, uint32_t tobWord, int resolution)
In future initialze the xTOB as well, word1.
Definition: jFexSumETRoI_v1.cxx:20
maskDeadModules.mod
mod
Definition: maskDeadModules.py:36
xAOD::jFexLRJetRoI_v1::initialize
void initialize(uint8_t jFexNumber, uint8_t fpgaNumber, uint32_t tobWord, char istob, int resolution, float_t eta, float_t phi)
In future initialze the EDM.
Definition: jFexLRJetRoI_v1.cxx:40
lumiFormat.i
int i
Definition: lumiFormat.py:85
xAOD::jFexMETRoI_v1::tobEy
int tobEy() const
LVL1::jFEXSysSim::m_xTobOutKey_jEM
SG::WriteHandleKey< xAOD::jFexFwdElRoIContainer > m_xTobOutKey_jEM
Definition: jFEXSysSim.h:96
ATH_MSG_DEBUG
#define ATH_MSG_DEBUG(x)
Definition: AthMsgStreamMacros.h:29
AthCommonDataStore::declareProperty
Gaudi::Details::PropertyBase & declareProperty(Gaudi::Property< T, V, H > &t)
Definition: AthCommonDataStore.h:145
xAOD::jFexMETRoI_v1::tobRes
uint8_t tobRes() const
SG::WriteDecorHandle
Handle class for adding a decoration to an object.
Definition: StoreGate/StoreGate/WriteDecorHandle.h:100
LVL1::jFEXSysSim::fillSRJetEDM
StatusCode fillSRJetEDM(const std::unique_ptr< jFEXTOB > &internalTob, char istob, float_t eta, float_t phi, SG::WriteHandle< xAOD::jFexSRJetRoIContainer > &jContainer) const
Definition: jFEXSysSim.cxx:1115
LVL1::FEXAlgoSpaceDefs::jFEX_wide_algoSpace_width
constexpr static int jFEX_wide_algoSpace_width
Definition: FEXAlgoSpaceDefs.h:27
xAOD::jFexMETRoI_v1::tobEx
int tobEx() const
test_pyathena.parent
parent
Definition: test_pyathena.py:15
ATH_CHECK
#define ATH_CHECK
Definition: AthCheckMacros.h:40
xAOD::jFexSRJetRoI
jFexSRJetRoI_v1 jFexSRJetRoI
Define the latest version of the jFexSRJetRoI class
Definition: jFexSRJetRoI.h:14
LVL1::jTower::iPhi
int iPhi() const
Return global phi index.
Definition: jTower.cxx:171
xAOD::jFexTauRoI_v1::phi
float phi() const
LVL1::jFEXSysSim::m_allMetTobs
std::unordered_map< uint8_t, std::vector< std::unique_ptr< jFEXTOB > > > m_allMetTobs
Definition: jFEXSysSim.h:111
beamspotnt.rows
list rows
Definition: bin/beamspotnt.py:1111
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
xAOD::jFexSumETRoI_v1::tobSat_lower
uint8_t tobSat_lower() const
AthAlgTool::AthAlgTool
AthAlgTool()
Default constructor:
LVL1::jFEXSysSim::m_xTobOutKey_jJ
SG::WriteHandleKey< xAOD::jFexSRJetRoIContainer > m_xTobOutKey_jJ
Definition: jFEXSysSim.h:93
LVL1::jFEXSysSim::m_TobOutKey_jTE
SG::WriteHandleKey< xAOD::jFexSumETRoIContainer > m_TobOutKey_jTE
Definition: jFEXSysSim.h:89
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::jFEXSysSim::fillTauEDM
StatusCode fillTauEDM(const std::unique_ptr< jFEXTOB > &internalTob, char istob, float_t eta, float_t phi, SG::WriteHandle< xAOD::jFexTauRoIContainer > &jContainer) const
Definition: jFEXSysSim.cxx:1128
merge_scale_histograms.doc
string doc
Definition: merge_scale_histograms.py:9
LVL1::jFEXSysSim::m_xTobOutKey_jLJ
SG::WriteHandleKey< xAOD::jFexLRJetRoIContainer > m_xTobOutKey_jLJ
Definition: jFEXSysSim.h:94
name
std::string name
Definition: Control/AthContainers/Root/debug.cxx:240
xAOD::jFexFwdElRoI_v1::initialize
void initialize(uint8_t jFexNumber, uint8_t fpgaNumber, uint32_t tobWord, char istob, int resolution, float_t eta, float_t phi)
initialze the EDM
Definition: jFexFwdElRoI_v1.cxx:30
DataVector::push_back
value_type push_back(value_type pElem)
Add an element to the end of the collection.
xAOD::jFexSumETRoI_v1
Class describing properties of a LVL1 jFEX global Trigger Object (TOB) in the xAOD format.
Definition: jFexSumETRoI_v1.h:22
LVL1::jFEXSysSim::fillSumEtEDM
StatusCode fillSumEtEDM(const std::unique_ptr< jFEXTOB > &internalTob, SG::WriteHandle< xAOD::jFexSumETRoIContainer > &jContainer) const
Definition: jFEXSysSim.cxx:1164
xAOD::jFexFwdElRoI
jFexFwdElRoI_v1 jFexFwdElRoI
Define the latest version of the jFexFwdElJetRoI class
Definition: jFexFwdElRoI.h:13
xAOD::jFexFwdElRoI_v1::et
unsigned int et() const
Methods that require combining results or applying scales.
Definition: jFexFwdElRoI_v1.cxx:151
LVL1::jFEXSysSim::m_jFEXCollection
std::vector< jFEXSim * > m_jFEXCollection
Internal data.
Definition: jFEXSysSim.h:74
xAOD::jFexSRJetRoI_v1::initialize
void initialize(uint8_t jFexNumber, uint8_t fpgaNumber, uint32_t tobWord, char istob, int resolution, float_t eta, float_t phi)
In future initialze the EDM.
Definition: jFexSRJetRoI_v1.cxx:38
xAOD::jFexSumETRoI_v1::jFexNumber
uint8_t jFexNumber() const
xAOD::jFexSumETRoI_v1::tobEt_upper
uint16_t tobEt_upper() const
LVL1::jFEXSysSim::m_TobOutKey_jXE
SG::WriteHandleKey< xAOD::jFexMETRoIContainer > m_TobOutKey_jXE
Definition: jFEXSysSim.h:90
LVL1::jFEXSysSim::m_TobOutKey_jLJ
SG::WriteHandleKey< xAOD::jFexLRJetRoIContainer > m_TobOutKey_jLJ
Definition: jFEXSysSim.h:86
SG::WriteHandle
Definition: StoreGate/StoreGate/WriteHandle.h:73
a
TList * a
Definition: liststreamerinfos.cxx:10
h
LVL1::jFEXSysSim::m_TobDecorKey_jJ_seedET
SG::WriteDecorHandleKey< xAOD::jFexSRJetRoIContainer > m_TobDecorKey_jJ_seedET
Definition: jFEXSysSim.h:99
LVL1::jFEXSysSim::m_allfwdElTobs
std::unordered_map< uint8_t, std::vector< std::vector< std::vector< uint32_t > > > > m_allfwdElTobs
Definition: jFEXSysSim.h:105
xAOD::jFexLRJetRoI_v1::phi
float phi() const
xAOD::jFexMETRoI
jFexMETRoI_v1 jFexMETRoI
Define the latest version of the jFexMETRoI class
Definition: jFexMETRoI.h:13
DEBUG
#define DEBUG
Definition: page_access.h:11
LVL1::jFEXSysSim::m_DBToolKey
SG::ReadCondHandleKey< jFEXDBCondData > m_DBToolKey
Definition: jFEXSysSim.h:76
SG::VarHandleBase::vhKey
SG::VarHandleKey & vhKey()
Return a non-const reference to the HandleKey.
Definition: StoreGate/src/VarHandleBase.cxx:629
LVL1::jTower
The jTower class is an interface object for jFEX trigger algorithms The purposes are twofold:
Definition: jTower.h:36
xAOD::jFexTauRoI
jFexTauRoI_v1 jFexTauRoI
Define the latest version of the jFexSRJetRoI class
Definition: jFexTauRoI.h:13
python.Bindings.keys
keys
Definition: Control/AthenaPython/python/Bindings.py:801
xAOD::jFexSumETRoI
jFexSumETRoI_v1 jFexSumETRoI
Define the latest version of the jFexSumETJetRoI class
Definition: jFexSumETRoI.h:13
xAOD::jFexSRJetRoI_v1::jFexNumber
uint8_t jFexNumber() const
LVL1::jFEXSysSim::fillFwdElEDM
StatusCode fillFwdElEDM(uint8_t jFexNum, uint8_t fpgaNumber, uint32_t tobWord, char istob, int resolution, float_t eta, float_t phi, SG::WriteHandle< xAOD::jFexFwdElRoIContainer > &jContainer) const
Definition: jFEXSysSim.cxx:1140
LVL1::jFEXSysSim::m_xTobOutKey_jTau
SG::WriteHandleKey< xAOD::jFexTauRoIContainer > m_xTobOutKey_jTau
Definition: jFEXSysSim.h:95
xAOD::jFexSumETRoI_v1::tobSat_upper
uint8_t tobSat_upper() const
LVL1::jFEXSysSim::m_allsumEtTobs
std::unordered_map< uint8_t, std::vector< std::unique_ptr< jFEXTOB > > > m_allsumEtTobs
Definition: jFEXSysSim.h:110
value_type
Definition: EDM_MasterSearch.h:11
xAOD::jFexSumETRoI_v1::tobEt_lower
uint16_t tobEt_lower() const
LVL1::jFEXSysSim::m_TobOutKey_jTau
SG::WriteHandleKey< xAOD::jFexTauRoIContainer > m_TobOutKey_jTau
Definition: jFEXSysSim.h:87
xAOD::jFexFwdElRoI_v1
Class describing properties of a LVL1 jFEX global Trigger Object (TOB) in the xAOD format.
Definition: jFexFwdElRoI_v1.h:23
fitman.k
k
Definition: fitman.py:528
xAOD::jFexSRJetRoI_v1::et
unsigned int et() const
Methods that require combining results or applying scales.
Definition: jFexSRJetRoI_v1.cxx:138