24.02
Main Page
Related Pages
Namespaces
Namespace List
Namespace Members
All
a
b
c
d
e
f
g
h
i
j
l
m
n
o
p
q
r
s
t
u
v
w
Functions
a
b
c
d
e
f
g
h
i
l
m
n
o
p
q
r
s
t
v
w
Variables
Typedefs
a
b
c
d
e
f
g
h
i
l
m
n
o
p
q
r
s
t
u
w
Enumerations
a
b
c
d
e
f
g
j
l
m
n
o
p
q
r
s
t
u
Classes
Class List
Class Index
Class Hierarchy
Class Members
All
a
b
c
d
e
f
g
h
i
j
k
l
m
n
o
p
q
r
s
t
u
v
w
~
Functions
a
b
c
d
e
f
g
h
i
j
l
m
n
o
p
q
r
s
t
u
v
w
~
Variables
c
d
e
f
i
j
l
m
o
p
r
s
v
w
Typedefs
a
b
c
d
e
f
g
h
i
k
l
m
n
o
p
r
s
t
v
w
Enumerations
Enumerator
Related Functions
Files
File List
File Members
All
a
b
c
d
e
f
g
h
i
l
m
o
r
s
t
u
v
x
z
Functions
a
b
c
g
i
m
r
s
t
v
z
Variables
Typedefs
Macros
a
c
d
e
f
h
i
l
o
s
t
u
v
x
Examples
•
All
Classes
Namespaces
Files
Functions
Variables
Typedefs
Enumerations
Enumerator
Friends
Macros
Pages
Observable.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 "
Observable.hpp
"
7
8
namespace
armnn
9
{
10
11
void
AddedLayerObservable::Update
(
Layer
* graphLayer)
12
{
13
m_ObservedObjects
.emplace_back(graphLayer);
14
}
15
16
void
ErasedLayerNamesObservable::Update
(
Layer
* graphLayer)
17
{
18
auto
& relatedLayerNames = graphLayer->
GetRelatedLayerNames
();
19
20
// If the erased layer has no related layers we take the erased layer's name
21
// Otherwise we need to preserve the related layer names,
22
// since we want to preserve the original graph's information
23
if
(relatedLayerNames.empty())
24
{
25
m_ObservedObjects
.emplace_back(graphLayer->
GetName
());
26
}
27
else
28
{
29
for
(
auto
& relatedLayerName : relatedLayerNames)
30
{
31
m_ObservedObjects
.emplace_back(relatedLayerName);
32
}
33
}
34
}
35
36
}
armnn::GraphObservable< Layer * >::m_ObservedObjects
std::list< Layer * > m_ObservedObjects
Definition:
Observable.hpp:43
armnn::AddedLayerObservable::Update
void Update(Layer *graphLayer) override
Definition:
Observable.cpp:11
armnn::Layer::GetName
const char * GetName() const override
Returns the name of the layer.
Definition:
Layer.hpp:332
Observable.hpp
armnn::Layer
Definition:
Layer.hpp:230
armnn::ErasedLayerNamesObservable::Update
void Update(Layer *graphLayer) override
Definition:
Observable.cpp:16
armnn::Layer::GetRelatedLayerNames
const std::list< std::string > & GetRelatedLayerNames()
Definition:
Layer.hpp:347
armnn
Copyright (c) 2021 ARM Limited and Contributors.
Definition:
01_00_quick_start.dox:6
src
armnn
Observable.cpp
Generated on Wed Feb 14 2024 16:36:14 for Arm NN by
1.8.17