From 6940dd720ebb6b3d1df8ca203ab696daefe58189 Mon Sep 17 00:00:00 2001 From: Jim Flynn Date: Fri, 20 Mar 2020 12:25:56 +0000 Subject: renamed Documentation folder 20.02 and added .nojekyll file Signed-off-by: Jim Flynn --- 20.02/_insert_debug_layer_tests_8cpp_source.xhtml | 134 ++++++++++++++++++++++ 1 file changed, 134 insertions(+) create mode 100644 20.02/_insert_debug_layer_tests_8cpp_source.xhtml (limited to '20.02/_insert_debug_layer_tests_8cpp_source.xhtml') diff --git a/20.02/_insert_debug_layer_tests_8cpp_source.xhtml b/20.02/_insert_debug_layer_tests_8cpp_source.xhtml new file mode 100644 index 0000000000..9558efc7ab --- /dev/null +++ b/20.02/_insert_debug_layer_tests_8cpp_source.xhtml @@ -0,0 +1,134 @@ + + + + + + + + + + + + + +ArmNN: src/armnn/test/optimizations/InsertDebugLayerTests.cpp Source File + + + + + + + + + + + + + + + + +
+
+ + + + ArmNN + + + +
+
+  20.02 +
+
+
+ + + + + + + +
+
+ +
+
+
+ +
+ +
+
+ + +
+ +
+ +
+
+
InsertDebugLayerTests.cpp
+
+
+Go to the documentation of this file.
1 //
2 // Copyright © 2017 Arm Ltd. All rights reserved.
3 // SPDX-License-Identifier: MIT
4 //
5 
6 #include "../TestUtils.hpp"
7 
8 #include <Optimizer.hpp>
9 
10 #include <boost/test/unit_test.hpp>
11 
12 BOOST_AUTO_TEST_SUITE(Optimizer)
13 using namespace armnn::optimizations;
14 
15 BOOST_AUTO_TEST_CASE(InsertDebugOptimizationTest)
16 {
17  armnn::Graph graph;
18 
19  const armnn::TensorInfo info({ 2, 2, 1, 3 }, armnn::DataType::Float32);
20 
21  // Create the simple test network
22  auto input = graph.AddLayer<armnn::InputLayer>(0, "input");
23  input->GetOutputSlot().SetTensorInfo(info);
24 
25  auto floor = graph.AddLayer<armnn::FloorLayer>("floor");
26  floor->GetOutputSlot().SetTensorInfo(info);
27 
28  auto output = graph.AddLayer<armnn::OutputLayer>(1, "output");
29 
30  // Connect up the layers
31  input->GetOutputSlot().Connect(floor->GetInputSlot(0));
32  floor->GetOutputSlot().Connect(output->GetInputSlot(0));
33 
34  BOOST_TEST(CheckSequence(graph.cbegin(), graph.cend(), &IsLayerOfType<armnn::InputLayer>,
35  &IsLayerOfType<armnn::FloorLayer>, &IsLayerOfType<armnn::OutputLayer>));
36 
37  // Run the optimizer
39 
40  BOOST_TEST(CheckSequence(graph.cbegin(), graph.cend(), &IsLayerOfType<armnn::InputLayer>,
41  &IsLayerOfType<armnn::DebugLayer>, &IsLayerOfType<armnn::FloorLayer>,
42  &IsLayerOfType<armnn::DebugLayer>, &IsLayerOfType<armnn::OutputLayer>));
43 }
44 
BOOST_AUTO_TEST_SUITE(TensorflowLiteParser)
+
Optimizer::Optimizations MakeOptimizations(Args &&... args)
Definition: Optimizer.hpp:43
+ + +
LayerT * AddLayer(Args &&... args)
Adds a new layer, of type LayerType, to the graph constructed with the arguments passed.
Definition: Graph.hpp:397
+
ConstIterator cbegin() const
Returns const iterator pointing to the beginning of the list. Lowercase for range-based for loops...
Definition: Graph.hpp:168
+
int Connect(InputSlot &destination)
Definition: Layer.cpp:79
+
static void Pass(Graph &graph, const Optimizations &optimizations)
Definition: Optimizer.cpp:16
+
OptimizeForType< Layer, AddDebugImpl > InsertDebugLayer
Definition: AddDebug.hpp:34
+ +
A layer user-provided data can be bound to (e.g. inputs, outputs).
Definition: OutputLayer.hpp:13
+
BOOST_AUTO_TEST_CASE(CheckConvolution2dLayer)
+
This layer represents a floor operation.
Definition: FloorLayer.hpp:13
+ +
BOOST_AUTO_TEST_SUITE_END()
+
A layer user-provided data can be bound to (e.g. inputs, outputs).
Definition: InputLayer.hpp:13
+
bool CheckSequence(const armnn::Graph::ConstIterator first, const armnn::Graph::ConstIterator last)
Definition: TestUtils.hpp:20
+
void SetTensorInfo(const TensorInfo &tensorInfo) override
Definition: Layer.cpp:58
+
const OutputSlot & GetOutputSlot(unsigned int index=0) const override
Get the const output slot handle by slot index.
Definition: Layer.hpp:312
+ +
ConstIterator cend() const
Returns const iterator pointing to the end of the list. Lowercase for range-based for loops...
Definition: Graph.hpp:170
+
+
+ + + + -- cgit v1.2.1