ATLAS Offline Software
gFEXFPGA.h
Go to the documentation of this file.
1 /*
2  Copyright (C) 2002-2024 CERN for the benefit of the ATLAS collaboration
3 */
4 //***************************************************************************
5 // gFEXFPGA - Defines FPGA tools
6 // -------------------
7 // begin : 01 04 2021
8 // email : cecilia.tosciri@cern.ch
9 //***************************************************************************
10 
11 #ifndef gFEXFPGA_H
12 #define gFEXFPGA_H
13 
15 #include "AthenaKernel/CLASS_DEF.h"
20 #include <vector>
21 
22 namespace LVL1
23 {
24 
25  class gFEXFPGA : public AthAlgTool, virtual public IgFEXFPGA
26  {
27 
28  public:
30  gFEXFPGA(const std::string &type, const std::string &name, const IInterface *parent);
31 
33  virtual StatusCode initialize() override;
35  virtual ~gFEXFPGA();
36 
37  virtual StatusCode init(int id) override;
38  virtual void reset() override;
39  virtual int getID() const override { return m_fpgaId; }
40 
41  // virtual void SetTowersAndCells_SG(gTowersCentral) override ;
42  // virtual void SetTowersAndCells_SG(gTowersForward) override ;
43 
44  // virtual void GetEnergyMatrix(gTowersCentral &) const override ;
45  // virtual void GetEnergyMatrix(gTowersForward &) const override ;
46 
49 
51  private:
52  SG::ReadCondHandleKey<gFEXDBCondData> m_DBToolKey{this, "DBToolKey", "gFEXDBParams", "Database tool key"};
53 
54  int m_fpgaId = -1;
55 
59 
63 
67 
68  // gTowersCentral m_gTowersIDs_central;
69  // gTowersForward m_gTowersIDs_forward;
70 
71  void gtCalib(gTowersType &twrs, const gTowersType &offsets, const gTowersType &noiseCuts, const gTowersType &slopes) const;
72 
73  void calLookup(int *tower, const int offset, const int noiseCut, const int slope) const;
74 
75  void calExpand(gTowersType &offsets, gTowersType &noiseCuts, gTowersType &slopes, const int offset, const std::array<int, 12>& columnNoiseCuts, const std::array<int, 12>& columnSlopes) const;
76 
77  SG::ReadHandleKey<LVL1::gTowerContainer> m_gFEXFPGA_gTowerContainerKey{this, "MyGTowers", "gTowerContainer", "Input container for gTowers"};
78  SG::ReadHandleKey<LVL1::gTowerContainer> m_gFEXFPGA_gTower50ContainerKey{this, "MyGTowers50", "gTower50Container", "Input container for gTowers"};
79  };
80 
81 } // end of namespace
82 
83 #endif
LVL1::gFEXFPGA::gFEXFPGA
gFEXFPGA(const std::string &type, const std::string &name, const IInterface *parent)
Constructors.
Definition: gFEXFPGA.cxx:22
LVL1::gFEXFPGA::reset
virtual void reset() override
Definition: gFEXFPGA.cxx:51
LVL1::gFEXFPGA::m_slopesDefaultB
gTowersType m_slopesDefaultB
Definition: gFEXFPGA.h:62
LVL1::gFEXFPGA::getID
virtual int getID() const override
Definition: gFEXFPGA.h:39
LVL1::gFEXFPGA::m_slopesDefaultC
gTowersType m_slopesDefaultC
Definition: gFEXFPGA.h:66
LVL1::gFEXFPGA::~gFEXFPGA
virtual ~gFEXFPGA()
Destructor.
Definition: gFEXFPGA.cxx:28
gTowerContainer.h
LVL1::gFEXFPGA::m_fpgaId
int m_fpgaId
Definition: gFEXFPGA.h:54
gFEXOutputCollection.h
SG::ReadHandleKey< LVL1::gTowerContainer >
LVL1
eFexTowerBuilder creates xAOD::eFexTowerContainer from supercells (LATOME) and triggerTowers (TREX) i...
Definition: ICMMCPHitsCnvTool.h:18
LVL1::gFEXFPGA::FillgTowerEDMCentral
virtual void FillgTowerEDMCentral(SG::WriteHandle< xAOD::gFexTowerContainer > &, gTowersCentral &, gTowersType &, gTowersType &, gTowersType &) override
Definition: gFEXFPGA.cxx:57
IgFEXFPGA.h
LVL1::gFEXFPGA::m_noiseCutsDefaultB
gTowersType m_noiseCutsDefaultB
Definition: gFEXFPGA.h:61
LVL1::gFEXFPGA::gtCalib
void gtCalib(gTowersType &twrs, const gTowersType &offsets, const gTowersType &noiseCuts, const gTowersType &slopes) const
Definition: gFEXFPGA.cxx:266
LVL1::gFEXFPGA::calLookup
void calLookup(int *tower, const int offset, const int noiseCut, const int slope) const
Definition: gFEXFPGA.cxx:280
EL::StatusCode
::StatusCode StatusCode
StatusCode definition for legacy code.
Definition: PhysicsAnalysis/D3PDTools/EventLoop/EventLoop/StatusCode.h:22
LVL1::gFEXFPGA::m_offsetsDefaultC
gTowersType m_offsetsDefaultC
Definition: gFEXFPGA.h:64
AthAlgTool.h
LVL1::gFEXFPGA::m_gFEXFPGA_gTower50ContainerKey
SG::ReadHandleKey< LVL1::gTowerContainer > m_gFEXFPGA_gTower50ContainerKey
Definition: gFEXFPGA.h:78
test_pyathena.parent
parent
Definition: test_pyathena.py:15
LVL1::gFEXFPGA::m_DBToolKey
SG::ReadCondHandleKey< gFEXDBCondData > m_DBToolKey
Internal data.
Definition: gFEXFPGA.h:52
LVL1::gFEXFPGA::m_noiseCutsDefaultC
gTowersType m_noiseCutsDefaultC
Definition: gFEXFPGA.h:65
TrigConf::name
Definition: HLTChainList.h:35
LVL1::gTowersCentral
std::array< std::array< int, 12 >, 32 > gTowersCentral
Definition: IgFEXaltMetAlgo.h:19
LVL1::IgFEXFPGA
Definition: IgFEXFPGA.h:29
LVL1::gFEXFPGA::calExpand
void calExpand(gTowersType &offsets, gTowersType &noiseCuts, gTowersType &slopes, const int offset, const std::array< int, 12 > &columnNoiseCuts, const std::array< int, 12 > &columnSlopes) const
Definition: gFEXFPGA.cxx:309
LVL1::gFEXFPGA::m_offsetsDefaultA
gTowersType m_offsetsDefaultA
Definition: gFEXFPGA.h:56
LVL1::gFEXFPGA::initialize
virtual StatusCode initialize() override
standard Athena-Algorithm method
Definition: gFEXFPGA.cxx:34
gFEXDBCondData.h
LVL1::gFEXFPGA
Definition: gFEXFPGA.h:26
LVL1::gFEXFPGA::m_gFEXFPGA_gTowerContainerKey
SG::ReadHandleKey< LVL1::gTowerContainer > m_gFEXFPGA_gTowerContainerKey
Definition: gFEXFPGA.h:77
LVL1::gFEXFPGA::m_slopesDefaultA
gTowersType m_slopesDefaultA
Definition: gFEXFPGA.h:58
SG::ReadCondHandleKey
Definition: ReadCondHandleKey.h:20
SG::WriteHandle
Definition: StoreGate/StoreGate/WriteHandle.h:76
python.CaloScaleNoiseConfig.type
type
Definition: CaloScaleNoiseConfig.py:78
convertTimingResiduals.offset
offset
Definition: convertTimingResiduals.py:71
LVL1::gTowersForward
std::array< std::array< int, 8 >, 32 > gTowersForward
Definition: IgFEXaltMetAlgo.h:20
LVL1::gTowersType
std::array< std::array< int, 12 >, 32 > gTowersType
Definition: IgFEXFPGA.h:25
LVL1::gFEXFPGA::init
virtual StatusCode init(int id) override
Definition: gFEXFPGA.cxx:44
LVL1::gFEXFPGA::m_offsetsDefaultB
gTowersType m_offsetsDefaultB
Definition: gFEXFPGA.h:60
AthAlgTool
Definition: AthAlgTool.h:26
LVL1::gFEXFPGA::FillgTowerEDMForward
virtual void FillgTowerEDMForward(SG::WriteHandle< xAOD::gFexTowerContainer > &, gTowersForward &, gTowersForward &, gTowersType &, gTowersType &, gTowersType &) override
Definition: gFEXFPGA.cxx:151
LVL1::gFEXFPGA::m_noiseCutsDefaultA
gTowersType m_noiseCutsDefaultA
Definition: gFEXFPGA.h:57
CLASS_DEF.h
macros to associate a CLID to a type