diff options
author | Aron Virginas-Tar <Aron.Virginas-Tar@arm.com> | 2019-02-25 14:12:46 +0000 |
---|---|---|
committer | Aron Virginas-Tar <aron.virginas-tar@arm.com> | 2019-02-25 14:58:32 +0000 |
commit | a1ecc49d1beb8d2cbb76c259b73b0f5a537aab2e (patch) | |
tree | fec863f816bd9155fc845db45af7b41190fbf888 /src | |
parent | 451d95bff7d8cd2d759fbb1b31bbeddd9c332360 (diff) | |
download | armnn-a1ecc49d1beb8d2cbb76c259b73b0f5a537aab2e.tar.gz |
IVGCVSW-2762 Fix missing layer name and output slot index in DebugLayer output
Change-Id: Idda9c8ba244c74d931105ced90c38a12d48df48a
Signed-off-by: Aron Virginas-Tar <Aron.Virginas-Tar@arm.com>
Diffstat (limited to 'src')
-rw-r--r-- | src/armnn/NetworkUtils.cpp | 13 |
1 files changed, 6 insertions, 7 deletions
diff --git a/src/armnn/NetworkUtils.cpp b/src/armnn/NetworkUtils.cpp index d0c36dd34f..a7f89ff222 100644 --- a/src/armnn/NetworkUtils.cpp +++ b/src/armnn/NetworkUtils.cpp @@ -85,17 +85,16 @@ std::vector<DebugLayer*> InsertDebugLayerAfter(Graph& graph, Layer& layer) std::vector<DebugLayer*> debugLayers; debugLayers.reserve(layer.GetNumOutputSlots()); - // Change outputs to DataType::Float16 + // Connect a DebugLayer to each output slot of the layer + unsigned int outputSlotIndex = 0u; for (auto&& outputSlot = layer.BeginOutputSlots(); outputSlot != layer.EndOutputSlots(); ++outputSlot) { - // Insert debug layer after the layer - const std::string name = - std::string("DebugLayerAfter") + layer.GetName(); - - const DebugDescriptor descriptor; + const std::string layerName(layer.GetName()); + const std::string debugName = std::string("DebugLayerAfter") + layerName; + const DebugDescriptor descriptor(layerName, outputSlotIndex++); DebugLayer* debugLayer = - graph.InsertNewLayer<DebugLayer>(*outputSlot, descriptor, name.c_str()); + graph.InsertNewLayer<DebugLayer>(*outputSlot, descriptor, debugName.c_str()); // Sets output tensor info for the debug layer. TensorInfo debugInfo = debugLayer->GetInputSlot(0).GetConnectedOutputSlot()->GetTensorInfo(); |