ATLAS Offline Software
TTrainedNetworkCondAlg.h
Go to the documentation of this file.
1 /*
2  Copyright (C) 2002-2022 CERN for the benefit of the ATLAS collaboration
3 */
4 
5 #ifndef _InDet_TTrainedNetworkCondAlg_H_
6 #define _InDet_TTrainedNetworkCondAlg_H_
7 
11 
12 #include "PoolSvc/IPoolSvc.h"
13 
15 
18 #include <string>
19 
20 #include "TFile.h"
21 
22 class IPoolSvc;
23 class TTrainedNetwork;
24 
25 namespace InDet {
26 
30 
31  public:
32 
33  TTrainedNetworkCondAlg (const std::string& name, ISvcLocator* pSvcLocator);
35 
36  StatusCode initialize() override final;
37  StatusCode execute(const EventContext& ctx) const override final;
38  StatusCode finalize() override final;
39  virtual bool isReEntrant() const override final { return false; }
40 
41  private:
42  TTrainedNetwork* retrieveNetwork(TFile &input_file, const std::string& folder) const;
43 
45  {this, "PoolSvc", "PoolSvc", "The service to retrieve files by GUID."};
46  ToolHandle<Trk::NeuralNetworkToHistoTool> m_networkToHistoTool
47  {this,"NetworkToHistoTool", "Trk::NeuralNetworkToHistoTool/NeuralNetworkToHistoTool", "Tool to create a neural network from a set of histograms." };
48 
50  {this, "ReadKey", "/PIXEL/PixelClustering/PixelClusNNCalib", "Cool folder name for the cluster NN input histogram file."};
51 
53  {this, "WriteKey", "PixelClusterNN", "The conditions statore key for the pixel cluster NNs"};
54 
55  Gaudi::Property< std::vector<std::string> > m_nnOrder
56  {this, "NetworkNames", {
57  "NumberParticles_NoTrack/",
58  "ImpactPoints1P_NoTrack/",
59  "ImpactPoints2P_NoTrack/",
60  "ImpactPoints3P_NoTrack/",
61  "ImpactPointErrorsX1_NoTrack/",
62  "ImpactPointErrorsX2_NoTrack/",
63  "ImpactPointErrorsX3_NoTrack/",
64  "ImpactPointErrorsY1_NoTrack/",
65  "ImpactPointErrorsY2_NoTrack/",
66  "ImpactPointErrorsY3_NoTrack/"},
67  "List of network names, which are created in this order"};
68 
69  Gaudi::Property<std::string> m_layerInfoHistogram
70  {this, "LayerInfoHistogram", "LayersInfo","Name about the layer info histogram."};
71 
72  Gaudi::Property<std::string> m_layerPrefix
73  {this, "LayerPrefix", "Layer", "Prefix of the pre layer weight and threshold histograms."};
74 
75  Gaudi::Property<std::string> m_weightIndicator
76  {this, "LayerWeightIndicator", "_weights", "Suffix of the weight histograms."};
77 
78  Gaudi::Property<std::string> m_thresholdIndicator
79  {this, "LayerThresholdIndicator", "_thresholds","Suffix of the threshold histograms."};
80 
81  Gaudi::Property<bool> m_getInputsInfo
82  {this, "GetInputsInfo", false,"Also read a histogram which contains information about the inputs (Run I)."};
83 };
84 }
85 #endif
InDet::TTrainedNetworkCondAlg::isReEntrant
virtual bool isReEntrant() const override final
Definition: TTrainedNetworkCondAlg.h:39
InDet::TTrainedNetworkCondAlg::m_weightIndicator
Gaudi::Property< std::string > m_weightIndicator
Definition: TTrainedNetworkCondAlg.h:76
IPoolSvc
This class provides the interface to the LCG POOL persistency software.
Definition: IPoolSvc.h:36
CondAttrListCollection.h
This file defines the class for a collection of AttributeLists where each one is associated with a ch...
InDet::TTrainedNetworkCondAlg::m_layerPrefix
Gaudi::Property< std::string > m_layerPrefix
Definition: TTrainedNetworkCondAlg.h:73
InDet::TTrainedNetworkCondAlg::TTrainedNetworkCondAlg
TTrainedNetworkCondAlg(const std::string &name, ISvcLocator *pSvcLocator)
Definition: TTrainedNetworkCondAlg.cxx:22
InDet::TTrainedNetworkCondAlg::retrieveNetwork
TTrainedNetwork * retrieveNetwork(TFile &input_file, const std::string &folder) const
Definition: TTrainedNetworkCondAlg.cxx:58
InDet
DUMMY Primary Vertex Finder.
Definition: VP1ErrorUtils.h:36
InDet::TTrainedNetworkCondAlg::m_poolsvc
ServiceHandle< IPoolSvc > m_poolsvc
Definition: TTrainedNetworkCondAlg.h:45
InDet::TTrainedNetworkCondAlg
Definition: TTrainedNetworkCondAlg.h:29
WriteCondHandleKey.h
NeuralNetworkToHistoTool.h
python.resample_meson.input_file
input_file
Definition: resample_meson.py:164
InDet::TTrainedNetworkCondAlg::m_networkToHistoTool
ToolHandle< Trk::NeuralNetworkToHistoTool > m_networkToHistoTool
Definition: TTrainedNetworkCondAlg.h:47
const
bool const RAWDATA *ch2 const
Definition: LArRodBlockPhysicsV0.cxx:562
AthReentrantAlgorithm
An algorithm that can be simultaneously executed in multiple threads.
Definition: AthReentrantAlgorithm.h:83
InDet::TTrainedNetworkCondAlg::m_writeKey
SG::WriteCondHandleKey< TTrainedNetworkCollection > m_writeKey
Definition: TTrainedNetworkCondAlg.h:53
InDet::TTrainedNetworkCondAlg::~TTrainedNetworkCondAlg
~TTrainedNetworkCondAlg()=default
InDet::TTrainedNetworkCondAlg::m_thresholdIndicator
Gaudi::Property< std::string > m_thresholdIndicator
Definition: TTrainedNetworkCondAlg.h:79
EL::StatusCode
::StatusCode StatusCode
StatusCode definition for legacy code.
Definition: PhysicsAnalysis/D3PDTools/EventLoop/EventLoop/StatusCode.h:22
TTrainedNetworkCollection.h
InDet::TTrainedNetworkCondAlg::initialize
StatusCode initialize() override final
Definition: TTrainedNetworkCondAlg.cxx:26
InDet::TTrainedNetworkCondAlg::m_getInputsInfo
Gaudi::Property< bool > m_getInputsInfo
Definition: TTrainedNetworkCondAlg.h:82
InDet::TTrainedNetworkCondAlg::m_readKey
SG::ReadCondHandleKey< CondAttrListCollection > m_readKey
Definition: TTrainedNetworkCondAlg.h:50
TTrainedNetwork
Definition: InnerDetector/InDetCalibAlgs/PixelCalibAlgs/NNClusteringCalibration_RunI/TTrainedNetwork.h:21
ReadCondHandleKey.h
AthReentrantAlgorithm.h
InDet::TTrainedNetworkCondAlg::finalize
StatusCode finalize() override final
Definition: TTrainedNetworkCondAlg.cxx:36
InDet::TTrainedNetworkCondAlg::m_layerInfoHistogram
Gaudi::Property< std::string > m_layerInfoHistogram
Definition: TTrainedNetworkCondAlg.h:70
name
std::string name
Definition: Control/AthContainers/Root/debug.cxx:192
InDet::TTrainedNetworkCondAlg::m_nnOrder
Gaudi::Property< std::vector< std::string > > m_nnOrder
Definition: TTrainedNetworkCondAlg.h:56
InDet::TTrainedNetworkCondAlg::execute
StatusCode execute(const EventContext &ctx) const override final
Definition: TTrainedNetworkCondAlg.cxx:104
IPoolSvc.h
This file contains the class definition for the IPoolSvc interface class.
SG::ReadCondHandleKey< CondAttrListCollection >
CaloCondBlobAlgs_fillNoiseFromASCII.folder
folder
Definition: CaloCondBlobAlgs_fillNoiseFromASCII.py:56
SG::WriteCondHandleKey< TTrainedNetworkCollection >
ServiceHandle< IPoolSvc >