From 44cfd848c1913f87a77c0427450dba93ba47fb94 Mon Sep 17 00:00:00 2001 From: Aron Virginas-Tar Date: Fri, 14 Jun 2019 15:45:03 +0100 Subject: IVGCVSW-3283 Add test for converting CONV2D and DEPTHWISE_CONV2D operators with dilation params Signed-off-by: Aron Virginas-Tar Change-Id: I51a9c71d7a277ab530ac35faea2e8a069c134f45 --- test/1.1/Mean.cpp | 23 +++++++++++++++++------ 1 file changed, 17 insertions(+), 6 deletions(-) (limited to 'test/1.1/Mean.cpp') diff --git a/test/1.1/Mean.cpp b/test/1.1/Mean.cpp index cf9ddcb2..6e96d84b 100644 --- a/test/1.1/Mean.cpp +++ b/test/1.1/Mean.cpp @@ -6,6 +6,8 @@ #include "../DriverTestHelpers.hpp" #include "../TestTensor.hpp" +#include "../1.1/HalPolicy.hpp" + #include #include @@ -15,6 +17,8 @@ using namespace android::hardware; using namespace driverTestHelpers; using namespace armnn_driver; +using HalPolicy = hal_1_1::HalPolicy; + namespace { @@ -34,14 +38,21 @@ void MeanTestImpl(const TestTensor& input, { auto driver = std::make_unique(DriverOptions(computeDevice, fp16Enabled)); - V1_1::Model model = {}; - AddInputOperand (model, input.GetDimensions()); - AddTensorOperand(model, axisDimensions, const_cast(axisValues), V1_0::OperandType::TENSOR_INT32); - AddIntOperand (model, keepDims); - AddOutputOperand(model, expectedOutput.GetDimensions()); + HalPolicy::Model model = {}; + + AddInputOperand(model, input.GetDimensions()); + + AddTensorOperand(model, + axisDimensions, + const_cast(axisValues), + HalPolicy::OperandType::TENSOR_INT32); + + AddIntOperand(model, keepDims); + + AddOutputOperand(model, expectedOutput.GetDimensions()); model.operations.resize(1); - model.operations[0].type = V1_1::OperationType::MEAN; + model.operations[0].type = HalPolicy::OperationType::MEAN; model.operations[0].inputs = hidl_vec{ 0, 1, 2 }; model.operations[0].outputs = hidl_vec{ 3 }; model.relaxComputationFloat32toFloat16 = fp16Enabled; -- cgit v1.2.1