diff options
author | David Beck <david.beck@arm.com> | 2018-10-23 13:35:58 +0100 |
---|---|---|
committer | Matthew Bentham <matthew.bentham@arm.com> | 2018-10-25 09:49:58 +0100 |
commit | 29c75de868ac3a86a70b25f8da0d0c7e47d40803 (patch) | |
tree | db8dd31d26622ca252f6e2d2c86c7e20a0829e9e /src/armnnUtils/GraphTopologicalSort.hpp | |
parent | 5cc8e56b4ca8d58dc11973c49c10a02a2f13580c (diff) | |
download | armnn-29c75de868ac3a86a70b25f8da0d0c7e47d40803.tar.gz |
IVGCVSW-2067 : dynamically create workload factories based on the backends in the network
Change-Id: Ide594db8c79ff67642721d8bad47624b88621fbd
Diffstat (limited to 'src/armnnUtils/GraphTopologicalSort.hpp')
-rw-r--r-- | src/armnnUtils/GraphTopologicalSort.hpp | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/src/armnnUtils/GraphTopologicalSort.hpp b/src/armnnUtils/GraphTopologicalSort.hpp index 81a37ac4e5..11314590a0 100644 --- a/src/armnnUtils/GraphTopologicalSort.hpp +++ b/src/armnnUtils/GraphTopologicalSort.hpp @@ -4,8 +4,8 @@ // #pragma once +#include <armnn/Optional.hpp> #include <boost/assert.hpp> -#include <boost/optional.hpp> #include <functional> #include <map> @@ -27,7 +27,7 @@ enum class NodeState template <typename TNodeId> -boost::optional<TNodeId> GetNextChild(TNodeId node, +armnn::Optional<TNodeId> GetNextChild(TNodeId node, std::function<std::vector<TNodeId>(TNodeId)> getIncomingEdges, std::map<TNodeId, NodeState>& nodeStates) { @@ -70,11 +70,11 @@ bool TopologicallySort( nodeStates[current] = NodeState::Visiting; - boost::optional<TNodeId> nextChildOfCurrent = GetNextChild(current, getIncomingEdges, nodeStates); + auto nextChildOfCurrent = GetNextChild(current, getIncomingEdges, nodeStates); if (nextChildOfCurrent) { - TNodeId nextChild = nextChildOfCurrent.get(); + TNodeId nextChild = nextChildOfCurrent.value(); // If the child has not been searched, add to the stack and iterate over this node if (nodeStates.find(nextChild) == nodeStates.end()) |