1#ifndef TMVA_SOFIE_RMODEL
2#define TMVA_SOFIE_RMODEL
5#include <unordered_set>
7#include <unordered_map>
20namespace Experimental{
30std::underlying_type_t<Options>
operator|(std::underlying_type_t<Options> opA,
Options opB);
44 std::string
fName=
"UnnamedModel";
52 const std::unordered_set<std::string>
fAllowedStdLib = {
"vector",
"algorithm",
"cmath"};
70 RModel(std::string
name, std::string parsedtime);
78 void AddOperator(std::unique_ptr<ROperator> op,
int order_execution = -1);
84 for (
auto &routine : routines) {
98 void UpdateOutputTensorList(std::vector<std::string> curr_output_tensor, std::vector<std::string> modify_output_tensor);
104 void Generate(std::underlying_type_t<Options> options,
int batchSize = 1);
106 Generate(
static_cast<std::underlying_type_t<Options>
>(options), batchSize);
#define ClassDef(name, id)
Option_t Option_t TPoint TPoint const char GetTextMagnitude GetFillStyle GetLineColor GetLineWidth GetMarkerStyle GetTextAlign GetTextColor GetTextSize void data
Option_t Option_t TPoint TPoint const char GetTextMagnitude GetFillStyle GetLineColor GetLineWidth GetMarkerStyle GetTextAlign GetTextColor GetTextSize void char Point_t Rectangle_t WindowAttributes_t Float_t Float_t Float_t Int_t Int_t UInt_t UInt_t Rectangle_t Int_t Int_t Window_t TString Int_t GCValues_t GetPrimarySelectionOwner GetDisplay GetScreen GetColormap GetNativeEvent const char const char dpyName wid window const char font_name cursor keysym reg const char only_if_exist regb h Point_t winding char text const char depth char const char Int_t count const char ColorStruct_t color const char filename
Option_t Option_t TPoint TPoint const char GetTextMagnitude GetFillStyle GetLineColor GetLineWidth GetMarkerStyle GetTextAlign GetTextColor GetTextSize void char Point_t Rectangle_t WindowAttributes_t Float_t Float_t Float_t Int_t Int_t UInt_t UInt_t Rectangle_t Int_t Int_t Window_t TString Int_t GCValues_t GetPrimarySelectionOwner GetDisplay GetScreen GetColormap GetNativeEvent const char const char dpyName wid window const char font_name cursor keysym reg const char only_if_exist regb h Point_t winding char text const char depth char const char Int_t count const char ColorStruct_t color const char Pixmap_t Pixmap_t PictureAttributes_t attr const char char ret_data h unsigned char height h Atom_t Int_t ULong_t ULong_t unsigned char prop_list Atom_t Atom_t Atom_t Time_t type
void AddOutputTensorNameList(std::vector< std::string > outputtensornames)
void ReadInitializedTensorsFromFile()
const ETensorType & GetTensorType(std::string name)
RModel(const RModel &other)=delete
void PrintIntermediateTensors()
void AddIntermediateTensor(std::string tensor_name, ETensorType type, std::vector< std::size_t > shape)
std::unordered_set< std::string > fNeededBlasRoutines
bool CheckIfTensorAlreadyExist(std::string tensor_name)
std::vector< std::unique_ptr< ROperator > > fOperators
void AddInputTensorInfo(std::string input_name, ETensorType type, std::vector< Dim > shape)
void Initialize(int batchSize=1)
std::unordered_map< std::string, TensorInfo > fIntermediateTensorInfos
std::unordered_map< std::string, TensorInfo > fReadyInputTensorInfos
void AddInitializedTensor(std::string tensor_name, ETensorType type, std::vector< std::size_t > shape, std::shared_ptr< void > data)
RModel & operator=(RModel &&other)
void AddBlasRoutines(std::vector< std::string > routines)
void AddInputTensorName(std::string name)
std::vector< std::string > fOutputTensorNames
void AddNeededStdLib(std::string libname)
bool IsInitializedTensor(const std::string &name) const
std::unordered_set< std::string > fNeededStdLib
void PrintInitializedTensors()
void AddOperator(std::unique_ptr< ROperator > op, int order_execution=-1)
void HeadInitializedTensors(std::string name, int n_print=50)
void OutputGenerated(std::string filename="")
const std::vector< size_t > & GetTensorShape(std::string name)
RModel & operator=(const RModel &other)=delete
void AddNeededCustomHeader(std::string filename)
std::unordered_map< std::string, InputTensorInfo > fInputTensorInfos
std::shared_ptr< void > GetInitializedTensorData(std::string tensor_name)
void Generate(std::underlying_type_t< Options > options, int batchSize=1)
const std::unordered_set< std::string > fAllowedStdLib
void WriteInitializedTensorsToFile(std::string filename="")
void Generate(Options options=Options::kDefault, int batchSize=1)
std::vector< std::string > fInputTensorNames
std::unordered_map< std::string, InitializedTensor > fInitializedTensors
void UpdateInitializedTensor(std::string tensor_name, ETensorType type, std::vector< std::size_t > shape, std::shared_ptr< void > data)
std::vector< std::string > GetOutputTensorNames()
void UpdateOutputTensorList(std::vector< std::string > curr_output_tensor, std::vector< std::string > modify_output_tensor)
std::unordered_set< std::string > fCustomOpHeaders
void PrintRequiredInputTensors()
Mother of all ROOT objects.
std::underlying_type_t< Options > operator|(Options opA, Options opB)
create variable transformations