From 3c432d45323314ae1e1c3e1260d6ddd6ee296b57 Mon Sep 17 00:00:00 2001 From: Liangliang He Date: Mon, 26 Feb 2018 15:10:23 +0800 Subject: [PATCH] Fix MaceEngine::Run compatibality issue --- mace/core/mace.cc | 7 +++++++ mace/core/public/mace.h | 5 ++++- 2 files changed, 11 insertions(+), 1 deletion(-) diff --git a/mace/core/mace.cc b/mace/core/mace.cc index 0d54c895..a533ff05 100644 --- a/mace/core/mace.cc +++ b/mace/core/mace.cc @@ -556,6 +556,13 @@ MaceEngine::~MaceEngine() { MACE_CHECK(hexagon_controller_->Finalize(), "hexagon finalize error"); } }; + +bool MaceEngine::Run(const float *input, + const std::vector &input_shape, + float *output) { + return Run(input, input_shape, output, nullptr); +} + bool MaceEngine::Run(const float *input, const std::vector &input_shape, float *output, diff --git a/mace/core/public/mace.h b/mace/core/public/mace.h index e7036ffe..23fe8004 100644 --- a/mace/core/public/mace.h +++ b/mace/core/public/mace.h @@ -360,10 +360,13 @@ class MaceEngine { explicit MaceEngine(const NetDef *net_def, DeviceType device_type); ~MaceEngine(); + bool Run(const float *input, + const std::vector &input_shape, + float *output); bool Run(const float *input, const std::vector &input_shape, float *output, - RunMetadata *run_metadata = nullptr); + RunMetadata *run_metadata); MaceEngine(const MaceEngine &) = delete; MaceEngine &operator=(const MaceEngine &) = delete; -- GitLab