ATLAS Offline Software
Loading...
Searching...
No Matches
TFCSGANLWTNNHandler.h
Go to the documentation of this file.
1
21
22// Hopefully documentation gets inherited from VNetworkBase
23
24#ifndef TFCSGANLWTNNHANDLER_H
25#define TFCSGANLWTNNHANDLER_H
26
28
29// Becuase we have a field of type LightweightGraph
30#include "lwtnn/LightweightGraph.hh"
31
32// For writing to a tree
33#include <vector>
34#include <memory>
35#include <string>
36
38public:
39 // Don't lose default constructors
41
52 explicit TFCSGANLWTNNHandler(const std::string &inputFile);
53
63
76 NetworkOutputs compute(NetworkInputs const &inputs) const override;
77
86 std::vector<std::string> getOutputLayers() const override;
87
88protected:
98 void setupNet() override;
99
100private:
101 // unique ptr deletes the object when it goes out of scope
105 std::unique_ptr<lwt::LightweightGraph> m_lwtnn_graph;
106
110 std::vector<std::string> m_outputLayers;
111
115 std::string *m_input = nullptr;
116
117 // Suppling a ClassDef for writing to file.
119};
120
121#endif // TFCSGANLWTNNHANDLER_H
ClassDefOverride(TFCSGANLWTNNHandler, 6)
void setupNet() override
Perform actions that prepare network for use.
std::string * m_input
Do not persistify.
NetworkOutputs compute(NetworkInputs const &inputs) const override
Function to pass values to the network.
TFCSGANLWTNNHandler(const std::string &inputFile)
TFCSGANLWTNNHandler constructor.
std::unique_ptr< lwt::LightweightGraph > m_lwtnn_graph
The network that we are wrapping here.
VNetworkLWTNN(const VNetworkLWTNN &copy_from)
VNetworkLWTNN copy constructor.
std::vector< std::string > getOutputLayers() const override
List the names of the outputs.
std::vector< std::string > m_outputLayers
Do not persistify.
std::map< std::string, std::map< std::string, double > > NetworkInputs
Format for network inputs.
std::map< std::string, double > NetworkOutputs
Format for network outputs.
VNetworkLWTNN(const VNetworkLWTNN &copy_from)
VNetworkLWTNN copy constructor.