3#include "onnx_proto3.pb.h"
6namespace Experimental {
9template <EBasicUnaryOperator Op>
14 std::string input_name = nodeproto.input(0);
19 std::runtime_error(
"TMVA::SOFIE ONNX Parser Unary op has input tensor " + input_name +
20 " but its type is not yet registered");
23 std::unique_ptr<ROperator> op;
24 std::string output_name = nodeproto.output(0);
31 throw std::runtime_error(
"TMVA::SOFIE - Unsupported - Binary Operator does not yet support input type " +
32 std::to_string(
static_cast<int>(input_type)));
45 return ParseBasicUnary<EBasicUnaryOperator::kSqrt>(parser, nodeproto);
50 return ParseBasicUnary<EBasicUnaryOperator::kReciprocal>(parser, nodeproto);
55 return ParseBasicUnary<EBasicUnaryOperator::kNeg>(parser, nodeproto);
60 return ParseBasicUnary<EBasicUnaryOperator::kExp>(parser, nodeproto);
bool IsRegisteredTensorType(const std::string &)
void RegisterTensorType(const std::string &, ETensorType)
ETensorType GetTensorType(const std::string &name)
ParserFuncSignature ParseSqrt
ParserFuncSignature ParseNeg
std::unique_ptr< ROperator > ParseBasicUnary(RModelParser_ONNX &parser, const onnx::NodeProto &nodeproto)
ParserFuncSignature ParseExp
std::function< std::unique_ptr< ROperator >(RModelParser_ONNX &, const onnx::NodeProto &)> ParserFuncSignature
ParserFuncSignature ParseReciprocal
create variable transformations