ATLAS Offline Software
Loading...
Searching...
No Matches
PunchThroughClassifier.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#ifndef ISF_PUNCHTHROUGHTOOLS_SRC_PUNCHTHROUGHCLASSIFIER_H
6#define ISF_PUNCHTHROUGHTOOLS_SRC_PUNCHTHROUGHCLASSIFIER_H 1
7
8// ISF includes
10
12
14
16
17
18#include <map>
19
20//LWTNN
21#include "lwtnn/LightweightGraph.hh"
22
23
24namespace ISF {
25
26class PunchThroughClassifier : public extends<AthAlgTool, IPunchThroughClassifier> {
27public:
28
30 PunchThroughClassifier(const std::string&,const std::string&,const IInterface*);
31
33 virtual ~PunchThroughClassifier() = default;
34
36 virtual StatusCode initialize() override final;
37
39 StatusCode initializeScaler(const std::string & scalerConfigFile);
40
42 StatusCode initializeNetwork(const std::string & networkConfigFile);
43
45 StatusCode initializeCalibrator(const std::string & calibratorConfigFile);
46
48 virtual double computePunchThroughProbability(const ISF::ISFParticle &isfp, const TFCSSimulationState& simulstate) const override;
49
51 static std::map<std::string, std::map<std::string, double> > computeInputs(const ISF::ISFParticle &isfp, const TFCSSimulationState& simulstate) ;
52
54 std::map<std::string, std::map<std::string, double> > scaleInputs(std::map<std::string, std::map<std::string, double> >& inputs) const;
55
57 double calibrateOutput(double& networkOutput) const;
58
61 std::unique_ptr<lwt::LightweightGraph> m_graph{};
62
64 double m_scalerMin{};
65 double m_scalerMax{};
66 std::map<std::string, double> m_scalerMinMap;
67 std::map<std::string, double> m_scalerMaxMap;
68
73 std::map<double, double> m_calibrationMap;
74
75 //properties
79
80};
81}
82
83#endif //ISF_PUNCHTHROUGHTOOLS_SRC_PUNCHTHROUGHCLASSIFIER_H
The generic ISF particle definition,.
Definition ISFParticle.h:42
PunchThroughClassifier(const std::string &, const std::string &, const IInterface *)
Constructor.
std::map< std::string, std::map< std::string, double > > scaleInputs(std::map< std::string, std::map< std::string, double > > &inputs) const
scale NN inputs using MinMaxScaler
virtual double computePunchThroughProbability(const ISF::ISFParticle &isfp, const TFCSSimulationState &simulstate) const override
interface method to return probability prediction of punch through
StatusCode initializeScaler(const std::string &scalerConfigFile)
input variable MinMaxScaler initialize method
virtual ~PunchThroughClassifier()=default
Destructor.
std::map< std::string, double > m_scalerMinMap
double m_scalerMin
input variable MinMaxScaler members
std::map< double, double > m_calibrationMap
virtual StatusCode initialize() override final
AlgTool initialize method.
StatusCode initializeNetwork(const std::string &networkConfigFile)
neural network initialize method
double calibrateOutput(double &networkOutput) const
calibrate NN output using isotonic regressor
static std::map< std::string, std::map< std::string, double > > computeInputs(const ISF::ISFParticle &isfp, const TFCSSimulationState &simulstate)
calcalate NN inputs based on isfp and simulstate
std::map< std::string, double > m_scalerMaxMap
StatusCode initializeCalibrator(const std::string &calibratorConfigFile)
isotonic regressor calibrator initialize method
std::string m_calibratorConfigFile
isotonic regressor calibrator members
std::unique_ptr< lwt::LightweightGraph > m_graph
NN graph.
STL class.
STL class.
ISFParticleOrderedQueue.
STL namespace.
#define private