diff options
author | narpra01 <narumol.prangnawarat@arm.com> | 2018-11-20 15:21:28 +0000 |
---|---|---|
committer | Aron Virginas-Tar <aron.virginas-tar@arm.com> | 2018-11-20 15:52:24 +0000 |
commit | b9546cf1ffde83f63436c4087711dcf098ea4196 (patch) | |
tree | 9e8bfe040effdc56e39f9cc9d920fb515352f52d /src/backends/backendsCommon/test/CommonTestUtils.hpp | |
parent | 97f71306bdfdadb7ff7a55043ebce40f6c280223 (diff) | |
download | armnn-b9546cf1ffde83f63436c4087711dcf098ea4196.tar.gz |
IVGCVSW-2173 - Add end to end layer test implementation and example usage
* Add CommonTestUtils
* Add end to end layer test implementation
* Add example usage for Merger layer on Ref, Cl, Neon
Change-Id: I8931136288cd68b80bcdad8f5ae087ae1a70a60a
Diffstat (limited to 'src/backends/backendsCommon/test/CommonTestUtils.hpp')
-rw-r--r-- | src/backends/backendsCommon/test/CommonTestUtils.hpp | 22 |
1 files changed, 22 insertions, 0 deletions
diff --git a/src/backends/backendsCommon/test/CommonTestUtils.hpp b/src/backends/backendsCommon/test/CommonTestUtils.hpp new file mode 100644 index 0000000000..68180fb289 --- /dev/null +++ b/src/backends/backendsCommon/test/CommonTestUtils.hpp @@ -0,0 +1,22 @@ +// +// Copyright © 2017 Arm Ltd. All rights reserved. +// SPDX-License-Identifier: MIT +// +#pragma once + +#include <Graph.hpp> + +using namespace armnn; + +namespace +{ + +// Connects two layers. +void Connect(IConnectableLayer* from, IConnectableLayer* to, const TensorInfo& tensorInfo, + unsigned int fromIndex = 0, unsigned int toIndex = 0) +{ + from->GetOutputSlot(fromIndex).Connect(to->GetInputSlot(toIndex)); + from->GetOutputSlot(fromIndex).SetTensorInfo(tensorInfo); +} + +} |