21.11
AddDebug.hpp
Go to the documentation of this file.
1
//
2
// Copyright © 2017 Arm Ltd. All rights reserved.
3
// SPDX-License-Identifier: MIT
4
//
5
#pragma once
6
7
#include "
Optimization.hpp
"
8
#include "
NetworkUtils.hpp
"
9
10
namespace
armnn
11
{
12
namespace
optimizations
13
{
14
15
class
AddDebugImpl
16
{
17
public
:
18
19
void
Run
(
Graph
& graph,
Layer
& layer)
const
20
{
21
if
(layer.
GetType
() !=
LayerType::Debug
&& layer.
GetType
() !=
LayerType::Output
)
22
{
23
// if the inputs/outputs of this layer do not have a debug layer
24
// insert the debug layer after them
25
InsertDebugLayerAfter
(graph, layer);
26
}
27
}
28
29
protected
:
30
AddDebugImpl
() =
default
;
31
~AddDebugImpl
() =
default
;
32
};
33
34
using
InsertDebugLayer
=
OptimizeForType<Layer, AddDebugImpl>
;
35
36
}
// namespace optimizations
37
}
// namespace armnn
armnn::LayerType::Output
armnn::OptimizeForType
Definition:
Optimization.hpp:67
armnn
Copyright (c) 2021 ARM Limited and Contributors.
Definition:
01_00_quick_start.dox:6
armnn::optimizations::AddDebugImpl::AddDebugImpl
AddDebugImpl()=default
armnn::optimizations::AddDebugImpl
Definition:
AddDebug.hpp:15
armnn::Layer::GetType
LayerType GetType() const override
Returns the armnn::LayerType of this layer.
Definition:
Layer.hpp:265
NetworkUtils.hpp
armnn::Graph
Definition:
Graph.hpp:30
armnn::optimizations::AddDebugImpl::~AddDebugImpl
~AddDebugImpl()=default
Optimization.hpp
armnn::InsertDebugLayerAfter
std::vector< DebugLayer * > InsertDebugLayerAfter(Graph &graph, Layer &layer)
Definition:
NetworkUtils.cpp:234
armnn::Layer
Definition:
Layer.hpp:210
armnn::LayerType::Debug
armnn::optimizations::AddDebugImpl::Run
void Run(Graph &graph, Layer &layer) const
Definition:
AddDebug.hpp:19
src
armnn
optimizations
AddDebug.hpp
Generated on Wed Nov 17 2021 12:59:00 for ArmNN by
1.8.13