ATLAS Offline Software
Loading...
Searching...
No Matches
DNNCaloSimSvc.h
Go to the documentation of this file.
1/*
2 Copyright (C) 2002-2022 CERN for the benefit of the ATLAS collaboration
3*/
4
6// DNNCaloSimSvc.h, (c) ATLAS Detector software
8
9#ifndef ISF_DNNCALOSIMSVC_H
10#define ISF_DNNCALOSIMSVC_H 1
11
12// ISF includes
14
15// Framework includes
16#include "GaudiKernel/IChronoStatSvc.h"
17
18// FastCaloSim includes
21
23
25
32
33#include "lwtnn/LightweightGraph.hh"
35#include "CLHEP/Units/PhysicalConstants.h"
36
38
39namespace CLHEP
40{
41 class HepRandomEngine;
42}
43
44//forward declarations
48
49
50namespace ISF {
55
57 {
58 public:
60 DNNCaloSimSvc(const std::string& name, ISvcLocator* pSvcLocator);
61
63 virtual ~DNNCaloSimSvc() final;
64
66 virtual StatusCode initialize() override final;
67 virtual StatusCode finalize() override final;
68
70 StatusCode initializeNetwork();
71
73 virtual StatusCode simulate(ISFParticle& isp, McEventCollection*) override final;
74 // type of input requested by lwtnn
75 typedef std::map<std::string, std::map<std::string, double> > NetworkInputs ;
76 typedef std::map<std::string, double> NetworkOutputs;
77 StatusCode fillNetworkInputs(const ISF::ISFParticle& isfp, NetworkInputs & inputs, double & trueEnergy);
78 StatusCode fillWindowCells(const double etaExtrap,const double phiExtrap,const CaloDetDescrElement* & impactCellDDE);
79
81 virtual StatusCode setupEvent() override final;
82
84 virtual StatusCode releaseEvent() override final;
85
88
89 std::unique_ptr<lwt::LightweightGraph> m_graph;
90
93
95 ToolHandle<Trk::ITimedExtrapolator> m_extrapolator;
96
98
100 CLHEP::HepRandomEngine* m_randomEngine;
102
103
108
109 // specific to architecture
110 // preprocessing of input
114 double m_riImpactEtaMean = 0.;
116 double m_riImpactPhiMean = 0.;
118
119 // building of the 266 cells cluster
127
128
130 };
131
132}
133
134#endif //> !ISF_DNNCALOSIMSVC_H
This class provides an interface to generate or decode an identifier for the upper levels of the dete...
Definition of CaloDetDescrManager.
#define pi
constexpr int pow(int base, int exp) noexcept
Define macros for attributes used to control the static checker.
#define ATLAS_NOT_THREAD_SAFE
getNoisyStrip() Find noisy strips from hitmaps and write out into xml/db formats
Container class for CaloCell.
Data object for each calorimeter readout cell.
Definition CaloCell.h:57
This class groups all DetDescr information related to a CaloCell.
This class provides the client interface for accessing the detector description information common to...
manage multiple CLHEP random engines as named streams
BaseSimulationSvc(const std::string &name, ISvcLocator *pSvcLocator)
ToolHandle< Trk::ITimedExtrapolator > m_extrapolator
const CaloDetDescrManager * m_caloDetDescrManager
std::vector< CaloCell * > m_windowCells
virtual StatusCode initialize() override final
Athena algorithm's interface methods.
const double m_middleCellWidthPhi
const double m_phiRawMiddleCut
virtual StatusCode simulate(ISFParticle &isp, McEventCollection *) override final
Simulation Call.
const int m_numberOfCellsForDNN
StatusCode fillWindowCells(const double etaExtrap, const double phiExtrap, const CaloDetDescrElement *&impactCellDDE)
std::string m_caloCellsOutputName
CaloCellContainer * m_theContainer
StatusCode fillNetworkInputs(const ISF::ISFParticle &isfp, NetworkInputs &inputs, double &trueEnergy)
std::string m_paramsInputArchitecture
DNNCaloSimSvc(const std::string &name, ISvcLocator *pSvcLocator)
Constructor with parameters.
std::string m_randomEngineName
const LArEM_ID * m_emID
virtual StatusCode finalize() override final
framework methods
ServiceHandle< IAtRndmGenSvc > m_rndGenSvc
StatusCode initializeNetwork()
helper for initialize
std::unique_ptr< lwt::LightweightGraph > m_graph
virtual StatusCode releaseEvent() override final
Release Event chain - in case of an end-of event action is needed.
const double m_phiRawStripCut
CLHEP::HepRandomEngine * m_randomEngine
ToolHandleArray< ICaloCellMakerTool > m_caloCellMakerToolsSetup
const double m_etaRawBackCut
ToolHandle< IFastCaloSimCaloExtrapolation > m_FastCaloSimCaloExtrapolation
std::unique_ptr< CaloGeometryFromCaloDDM > m_caloGeo
std::map< std::string, std::map< std::string, double > > NetworkInputs
ToolHandleArray< ICaloCellMakerTool > m_caloCellMakerToolsRelease
std::map< std::string, double > NetworkOutputs
const double m_middleCellWidthEta
virtual ~DNNCaloSimSvc() final
Destructor.
std::string m_paramsFilename
const double m_etaRawMiddleCut
virtual StatusCode setupEvent() override final
Setup Event chain - in case of a begin-of event action is needed.
The generic ISF particle definition,.
Definition ISFParticle.h:42
Helper class for LArEM offline identifiers.
Definition LArEM_ID.h:111
This defines the McEventCollection, which is really just an ObjectVector of McEvent objectsFile: Gene...
STL class.
STL class.
ISFParticleOrderedQueue.
Ensure that the ATLAS eigen extensions are properly loaded.
STL namespace.