summaryrefslogtreecommitdiff
path: root/runtimes/pure_arm_compute/src/compilation.h
diff options
context:
space:
mode:
Diffstat (limited to 'runtimes/pure_arm_compute/src/compilation.h')
-rw-r--r--runtimes/pure_arm_compute/src/compilation.h30
1 files changed, 30 insertions, 0 deletions
diff --git a/runtimes/pure_arm_compute/src/compilation.h b/runtimes/pure_arm_compute/src/compilation.h
index dd3613b2d..1a06d06b9 100644
--- a/runtimes/pure_arm_compute/src/compilation.h
+++ b/runtimes/pure_arm_compute/src/compilation.h
@@ -14,15 +14,28 @@
* limitations under the License.
*/
+/**
+ * @file compilation.h
+ * @brief This file defines ANeuralNetworksCompilation class for handling Compilation NNAPI
+ * @ingroup COM_AI_RUNTIME
+ */
+
#ifndef __COMPILATION_H__
#define __COMPILATION_H__
#include "internal/Model.h"
#include "internal/arm_compute.h"
+/**
+ * @brief struct to define Compilation of NNAPI
+ */
struct ANeuralNetworksCompilation
{
public:
+ /**
+ * @brief Construct with params
+ * @param [in] model Pointer of internal::tflite::Model to set internal::arm_compute::Plan
+ */
ANeuralNetworksCompilation(const std::shared_ptr<const internal::tflite::Model> &model)
: _plan{new internal::arm_compute::Plan{model}}
{
@@ -30,11 +43,28 @@ public:
}
public:
+ /**
+ * @brief Get reference of internal::arm_compute::Plan
+ * @return Reference of internal::arm_compute::Plan
+ */
internal::arm_compute::Plan &plan(void) { return *_plan; }
public:
+ /**
+ * @brief Publish internal Plan to param
+ * @param [out] plan Pointer of internal::arm_compute::Plan to be set
+ * @return N/A
+ */
void publish(std::shared_ptr<const internal::arm_compute::Plan> &plan) { plan = _plan; }
+ /**
+ * @brief Get @c true if ANeuralNetworksCompilation_finish has been called, otherwise @c false
+ * @return @c true if ANeuralNetworksCompilation_finish has been called, otherwise @c false
+ */
bool isFinished(void) { return _isFinished; }
+ /**
+ * @brief Mark compilation process finished
+ * @return N/A
+ */
void markAsFinished() { _isFinished = true; }
private: