1#ifndef TMVA_SOFIE_ROPERATOR_IDENTITY
2#define TMVA_SOFIE_ROPERATOR_IDENTITY
11namespace Experimental{
45 throw std::runtime_error(
"TMVA SOFIE Identity Op Input Tensor is not found in model");
69 std::stringstream out;
70 out <<
"\n//------ IDENTITY\n";
72 out <<
SP <<
SP <<
"tensor_" <<
fNY <<
" = tensor_" <<
fNX <<
";\n";
81 throw std::runtime_error(
"TMVA SOFIE Operator Identity called to Generate without being initialized first");
83 std::stringstream out;
84 out <<
"\n//------ IDENTITY\n";
86 out <<
SP <<
SP <<
"tensor_" <<
fNY <<
" = tensor_" <<
fNX <<
";\n";
ROOT::Detail::TRangeCast< T, true > TRangeDynCast
TRangeDynCast is an adapter class that allows the typed iteration through a TCollection.
Option_t Option_t TPoint TPoint const char GetTextMagnitude GetFillStyle GetLineColor GetLineWidth GetMarkerStyle GetTextAlign GetTextColor GetTextSize void input
const ETensorType & GetTensorType(std::string name)
void AddIntermediateTensor(std::string tensor_name, ETensorType type, std::vector< Dim > dim_shape)
bool CheckIfTensorAlreadyExist(std::string tensor_name)
void AddConstantTensor(std::string tensor_name, ETensorType type, std::vector< std::size_t > shape, std::shared_ptr< void > data)
bool IsInitializedTensor(const std::string &name) const
bool IsConstantTensor(const std::string &name) const
const std::vector< size_t > & GetTensorShape(std::string name)
std::shared_ptr< void > GetInitializedTensorData(std::string tensor_name)
std::string GenerateInitCode()
void Initialize(RModel &model)
std::vector< ETensorType > TypeInference(std::vector< ETensorType > input)
std::vector< std::vector< size_t > > ShapeInference(std::vector< std::vector< size_t > > input)
ROperator_Identity(std::string nameX, std::string nameY)
std::vector< size_t > fShape
std::string Generate(std::string OpName)
std::vector< std::string_view > fInputTensorNames
bool fIsOutputConstant
flag to identify if operator has a constant output (no need to generate code)
const std::string SP
space used to correctly indent the generated C++ code
std::vector< std::string_view > fOutputTensorNames
create variable transformations