ONE - On-device Neural Engine
|
Class to store information to run a model. Normally this info comes from users via CLI params or configuration file. More...
#include <ModelSignature.h>
Public Member Functions | |
void | add_input (const TensorName &input) |
void | add_input (const TensorName &&input) |
void | add_output (const TensorName &output) |
void | add_output (const TensorName &&output) |
const std::vector< TensorName > & | inputs () const |
const std::vector< TensorName > & | outputs () const |
void | add_customop (const std::string &op) |
Adds customop op type (not name of node) provided from user. | |
const std::vector< std::string > & | customops () const |
void | shape (const std::string &node_name, const angkor::TensorShape &shape) |
Adds node name and its shape provided from user. | |
const angkor::TensorShape * | shape (const std::string &node_name) const |
void | dtype (const std::string &node_name, loco::DataType dtype) |
Adds node name and its dtype provided from user. | |
loco::DataType | dtype (const std::string &node_name) const |
Class to store information to run a model. Normally this info comes from users via CLI params or configuration file.
Definition at line 35 of file ModelSignature.h.
void moco::ModelSignature::add_customop | ( | const std::string & | op | ) |
Adds customop op type (not name of node) provided from user.
Definition at line 24 of file ModelSignature.cpp.
|
inline |
Definition at line 39 of file ModelSignature.h.
|
inline |
Definition at line 38 of file ModelSignature.h.
Referenced by nnkit::support::moco::tf::Backend::Backend(), and main().
|
inline |
Definition at line 41 of file ModelSignature.h.
|
inline |
Definition at line 40 of file ModelSignature.h.
Referenced by nnkit::support::moco::tf::Backend::Backend(), and main().
|
inline |
Definition at line 50 of file ModelSignature.h.
loco::DataType moco::ModelSignature::dtype | ( | const std::string & | node_name | ) | const |
Definition at line 57 of file ModelSignature.cpp.
void moco::ModelSignature::dtype | ( | const std::string & | node_name, |
loco::DataType | dtype | ||
) |
Adds node name and its dtype provided from user.
Definition at line 49 of file ModelSignature.cpp.
References dtype().
Referenced by moco::tf::COpCallGraphBuilder::build(), and dtype().
|
inline |
Definition at line 43 of file ModelSignature.h.
Referenced by validate_onnx2circle.OnnxRunner::feed_random_inputs(), and package.infer.session::set_inputs().
|
inline |
Definition at line 44 of file ModelSignature.h.
Referenced by validate_onnx2circle.OnnxRunner::get_outputs(), package.infer.session::inference(), and package.infer.session::set_outputs().
const angkor::TensorShape * moco::ModelSignature::shape | ( | const std::string & | node_name | ) | const |
Definition at line 40 of file ModelSignature.cpp.
Referenced by RandomDataGenerator.RandomDataGenerator::_gen_float32(), RandomDataGenerator.RandomDataGenerator::_gen_int16(), and RandomDataGenerator.RandomDataGenerator::_gen_uint8().
void moco::ModelSignature::shape | ( | const std::string & | node_name, |
const angkor::TensorShape & | shape | ||
) |
Adds node name and its shape provided from user.
Definition at line 32 of file ModelSignature.cpp.
References shape().
Referenced by RandomDataGenerator.RandomDataGenerator::_gen_float32(), RandomDataGenerator.RandomDataGenerator::_gen_int16(), RandomDataGenerator.RandomDataGenerator::_gen_uint8(), nnkit::support::moco::tf::Backend::Backend(), moco::tf::COpCallGraphBuilder::build(), main(), and shape().