summaryrefslogtreecommitdiff
path: root/nn/runtime/test/TestExecution.cpp
diff options
context:
space:
mode:
authorXusong Wang <xusongw@google.com>2018-11-07 15:03:29 -0800
committerMiao Wang <miaowang@google.com>2019-01-24 18:08:03 -0800
commite5be7ce52b1a9d95c1d05fa833829ad8a9249e30 (patch)
treea2e65a7b2d5d5ea60541f51a840d7c26412a7d92 /nn/runtime/test/TestExecution.cpp
parentd1e50b1930011296bf2da4e37218833b04223aa9 (diff)
downloadml-e5be7ce52b1a9d95c1d05fa833829ad8a9249e30.tar.gz
Implement dynamic output shape in CpuExecutor and Sample Driver.
Create interface for CpuExecutor to report output shapes after execution. Add a new ResultCode ANEURALNETWORKS_OUTPUT_INSUFFICIENT_SIZE for dynamic output shape support. Let Sample Driver notify output shape after computation. Bug: 73506513 Test: NeuralNetworksTest_static Test: VtsHalNeuralnetworksV1_xTargetTest with 1.2 sample driver Change-Id: I1ee906b7af101e447b479bea96050d8bde7fa6f4 Merged-In: I1ee906b7af101e447b479bea96050d8bde7fa6f4 (cherry picked from commit 1f2af28227899847999d8fa4a5761158121ca155)
Diffstat (limited to 'nn/runtime/test/TestExecution.cpp')
-rw-r--r--nn/runtime/test/TestExecution.cpp16
1 files changed, 6 insertions, 10 deletions
diff --git a/nn/runtime/test/TestExecution.cpp b/nn/runtime/test/TestExecution.cpp
index 7abef57bc..422af9144 100644
--- a/nn/runtime/test/TestExecution.cpp
+++ b/nn/runtime/test/TestExecution.cpp
@@ -386,16 +386,12 @@ template<class DriverClass> void ExecutionTestTemplate<DriverClass>::TestWait()
}
}
-auto kTestValues = ::testing::Values(std::make_tuple(ErrorStatus::NONE,
- Result::NO_ERROR),
- std::make_tuple(ErrorStatus::DEVICE_UNAVAILABLE,
- Result::OP_FAILED),
- std::make_tuple(ErrorStatus::GENERAL_FAILURE,
- Result::OP_FAILED),
- std::make_tuple(ErrorStatus::OUTPUT_INSUFFICIENT_SIZE,
- Result::OP_FAILED),
- std::make_tuple(ErrorStatus::INVALID_ARGUMENT,
- Result::BAD_DATA));
+auto kTestValues = ::testing::Values(
+ std::make_tuple(ErrorStatus::NONE, Result::NO_ERROR),
+ std::make_tuple(ErrorStatus::DEVICE_UNAVAILABLE, Result::OP_FAILED),
+ std::make_tuple(ErrorStatus::GENERAL_FAILURE, Result::OP_FAILED),
+ std::make_tuple(ErrorStatus::OUTPUT_INSUFFICIENT_SIZE, Result::OUTPUT_INSUFFICIENT_SIZE),
+ std::make_tuple(ErrorStatus::INVALID_ARGUMENT, Result::BAD_DATA));
class ExecutionTest12 : public ExecutionTestTemplate<TestDriver12> {};
TEST_P(ExecutionTest12, Wait) {