19#include <unordered_map>
58 virtual StatusCode
init(
const std::string&);
75 virtual int getET(
int FPGAid,
int eta,
int phi,
int layer,
int cell)
const;
97 StatusCode
changeFPGAET(
int tmp_eTowersIDs_subset[][6],
int FPGAnumber,
int eFEXnumber);
132 std::vector<int>*
loadBlock(
const std::string&,
int)
const;
137 ToolHandle<eFEXFPGATowerIdProvider>
m_eFEXFPGATowerIdProviderTool {
this,
"eFEXFPGATowerIdProviderTool",
"LVL1::eFEXFPGATowerIdProvider",
"Tool that provides tower-FPGA mapping"};
146 std::unordered_map<int, std::unordered_map<int, unsigned int>*>
m_alltowers;
149 std::unordered_map<int, std::vector<int>*>
m_dict;
Scalar eta() const
pseudorapidity method
Scalar phi() const
phi method
std::string m_inputfile
path to the input directory
ToolHandle< eFEXFPGATowerIdProvider > m_eFEXFPGATowerIdProviderTool
tool needed for tower-FPGA mapping
std::unordered_map< int, std::unordered_map< int, unsigned int > * > m_alltowers
map of all supercell ETs of FPGAs m_alltowers[FPGAid] = (supercell id,ET) supercell id = eta * 1000 +...
virtual StatusCode loadnext()
Load the test vector of the next event.
StatusCode changeFPGAET(int tmp_eTowersIDs_subset[][6], int FPGAnumber, int eFEXnumber)
Replace the Et in an FOGA by the ones in the test vector.
StatusCode changeTowerET(LVL1::eTower *inputtower, int eta, int phi, int FPGAid) const
Replace the Et in a tower by the ones in the test vector.
virtual StatusCode seteTowers(eTowerContainer *)
Define the eTowerContainer object for which the Et will be replaced.
eTowerContainer * m_eTowerContainer
StatusCode loaddic(int)
load index of Et
std::unordered_map< int, std::vector< int > * > m_dict
map for mapping infomation. m_dict[FPGAid] = [ list of supercell id in order ]
static const InterfaceID & interfaceID()
eFakeTower(const std::string &type, const std::string &name, const IInterface *parent)
Constructor.
int getFPGAnumber(int iefex, int ifpga) const
determine the index of an FPGA
std::vector< int > * loadBlock(const std::string &, int) const
Load the Et or index in a block.
virtual StatusCode init(const std::string &)
initiate with the path to the test vector directory
int m_numberofevents
number of events
StatusCode loadFPGA(int)
load the Et in an FPGA
virtual StatusCode execute()
replace the Tower Et with the ones stored in the test vector.
virtual int getET(int FPGAid, int eta, int phi, int layer, int cell) const
obtain the Et of a tower slot
The eTower class is an interface object for eFEX trigger algorithms The purposes are twofold:
Provide tower-FPGA mapping.
eFexTowerBuilder creates xAOD::eFexTowerContainer from supercells (LATOME) and triggerTowers (TREX) i...
static const InterfaceID IID_IeFakeTower("LVL1::eFakeTower", 1, 0)