Menoh
Classes | Namespaces | Macros | Enumerations | Functions
menoh.hpp File Reference
#include <memory>
#include <vector>
#include <menoh/menoh.h>

Go to the source code of this file.

Classes

class  menoh::error
 The error class thrown when any error occured. More...
 
class  menoh::model_data
 model data class More...
 
struct  menoh::variable_profile
 
class  menoh::variable_profile_table
 Key value store for variable_profile. More...
 
class  menoh::variable_profile_table_builder
 The builder class to build variable_profile_table. More...
 
struct  menoh::variable
 
class  menoh::model
 The main component to run inference. More...
 
class  menoh::model_builder
 The builder class to build model. More...
 

Namespaces

 menoh
 

Macros

#define MENOH_CPP_API_ERROR_CHECK(statement)
 

Enumerations

enum  menoh::error_code_t {
  menoh::error_code_t::success = menoh_error_code_success, menoh::error_code_t::std_error = menoh_error_code_std_error, menoh::error_code_t::unknown_error = menoh_error_code_unknown_error, menoh::error_code_t::invalid_filename = menoh_error_code_invalid_filename,
  menoh::error_code_t::unsupported_onnx_opset_version, menoh::error_code_t::onnx_parse_error = menoh_error_code_onnx_parse_error, menoh::error_code_t::invalid_dtype = menoh_error_code_invalid_dtype, menoh::error_code_t::invalid_attribute_type = menoh_error_code_invalid_attribute_type,
  menoh::error_code_t::unsupported_operator_attribute, menoh::error_code_t::dimension_mismatch = menoh_error_code_dimension_mismatch, menoh::error_code_t::variable_not_found = menoh_error_code_variable_not_found, menoh::error_code_t::index_out_of_range = menoh_error_code_index_out_of_range,
  menoh::error_code_t::json_parse_error = menoh_error_code_json_parse_error, menoh::error_code_t::invalid_backend_name = menoh_error_code_invalid_backend_name, menoh::error_code_t::unsupported_operator = menoh_error_code_unsupported_operator, menoh::error_code_t::failed_to_configure_operator,
  menoh::error_code_t::backend_error = menoh_error_code_backend_error, menoh::error_code_t::same_named_variable_already_exist, menoh::error_code_t::invalid_dims_size
}
 
enum  menoh::dtype_t { menoh::dtype_t::float_ = menoh_dtype_float }
 

Functions

model_data menoh::make_model_data_from_onnx (std::string const &onnx_filename)
 Load ONNX file and make model_data. More...
 
model_data menoh::make_model_data_from_onnx_data_on_memory (const uint8_t *onnx_data, uint32_t size)
 Make model_data from onnx binary data on memory. More...
 

Macro Definition Documentation

◆ MENOH_CPP_API_ERROR_CHECK

#define MENOH_CPP_API_ERROR_CHECK (   statement)
Value:
{ \
auto ec = statement; \
if(ec) { \
throw error(ec, menoh_get_last_error_message()); \
} \
}
MENOH_API const char * menoh_get_last_error_message()
Users can get detailed message about last error.