1 #ifndef _MA_MODEL_BASE_H_
2 #define _MA_MODEL_BASE_H_
8 #include "../engine/ma_engine.h"
9 #include "../ma_common.h"
17 std::function<void(
void*)> p_preprocess_done_;
18 std::function<void(
void*)> p_postprocess_done_;
19 std::function<void(
void*)> p_underlying_run_done_;
31 Model(
Engine* engine,
const char* name, uint16_t type);
34 const char* getName()
const;
41 void setPreprocessDone(std::function<
void(
void*)> func);
42 void setPostprocessDone(std::function<
void(
void*)> func);
43 void setRunDone(std::function<
void(
void*)> func);
44 void setUserCtx(
void* ctx);
Definition: ma_model_base.h:14
Engine * p_engine_
Definition: ma_model_base.h:24
virtual ma_err_t preprocess()=0
virtual ma_err_t postprocess()=0
const char * p_name_
Definition: ma_model_base.h:25
virtual ma_err_t setConfig(ma_model_cfg_opt_t opt,...)=0
virtual ma_err_t getConfig(ma_model_cfg_opt_t opt,...)=0
virtual const void * getInput()=0
Definition: ma_engine_base.h:17
ma_model_type_t
Definition: ma_types.h:274
ma_err_t
Definition: ma_types.h:21
ma_model_cfg_opt_t
Definition: ma_types.h:229
ma_output_type_t
Definition: ma_types.h:264
ma_input_type_t
Definition: ma_types.h:258
Definition: ma_engine_base.h:15
Definition: ma_types.h:138