aboutsummaryrefslogtreecommitdiff
path: root/1.1/HalPolicy.hpp
diff options
context:
space:
mode:
authorarovir01 <Aron.Virginas-Tar@arm.com>2018-09-05 17:03:25 +0100
committerMatthew Bentham <matthew.bentham@arm.com>2018-09-18 12:40:40 +0100
commitb0717b5241a15e3e4d37a1b51b6e5fd9a92a664f (patch)
tree84159d2eb142f12081c494483c07012e8ebee8cb /1.1/HalPolicy.hpp
parent93e48980920ddcc8c6390fa6cbfdfc9740786617 (diff)
downloadandroid-nn-driver-b0717b5241a15e3e4d37a1b51b6e5fd9a92a664f.tar.gz
IVGCVSW-1806: Refactor Android-NN-Driver ModelToINetworkConverter
* Moved conversion logic into new V1_0 and V1_1 HalPolicy classes * Extracted common helper functions into ConversionUtils class Change-Id: I1ab50edc266dd528c0cb22a5cd1aa65e103674d9
Diffstat (limited to '1.1/HalPolicy.hpp')
-rw-r--r--1.1/HalPolicy.hpp31
1 files changed, 31 insertions, 0 deletions
diff --git a/1.1/HalPolicy.hpp b/1.1/HalPolicy.hpp
new file mode 100644
index 00000000..3722d49d
--- /dev/null
+++ b/1.1/HalPolicy.hpp
@@ -0,0 +1,31 @@
+//
+// Copyright © 2017 Arm Ltd. All rights reserved.
+// SPDX-License-Identifier: MIT
+//
+
+#pragma once
+
+#include "ConversionUtils.hpp"
+
+#include <HalInterfaces.h>
+
+namespace armnn_driver
+{
+namespace hal_1_1
+{
+
+class HalPolicy
+{
+public:
+ using Model = V1_1::Model;
+ using Operation = V1_1::Operation;
+ using getSupportedOperations_cb = V1_1::IDevice::getSupportedOperations_1_1_cb;
+
+ static bool ConvertOperation(const Operation& operation, const Model& model, ConversionData& data);
+
+private:
+ static bool ConvertDiv(const Operation& operation, const Model& model, ConversionData& data);
+};
+
+} // namespace hal_1_1
+} // namespace armnn_driver