From 6b0b53d307f956c3d67429f2a93df91f2eb2f483 Mon Sep 17 00:00:00 2001 From: jimfly01 Date: Mon, 8 Oct 2018 14:43:01 +0100 Subject: IVGCVSW-1929: Fix for this defect (QASYM8 no scale) * Now hand in an optional vector of strings to Optimize function in which errors/warning messages are placed. * Optimize function changed to check outputs of each layer. If they are Quantized 8 bit but the scale has not been set an error message is added for each such output. * Unit test modelled on defect report added to exercise the fix. !android-nn-driver:152483 Change-Id: If9901f5324a516f1ab62858266b38f98dae16201 --- include/armnn/INetwork.hpp | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) (limited to 'include/armnn') diff --git a/include/armnn/INetwork.hpp b/include/armnn/INetwork.hpp index 2c83909c83..aaf49a3d47 100644 --- a/include/armnn/INetwork.hpp +++ b/include/armnn/INetwork.hpp @@ -7,6 +7,7 @@ #include "armnn/NetworkFwd.hpp" #include "armnn/DescriptorsFwd.hpp" #include "armnn/TensorFwd.hpp" +#include "armnn/Optional.hpp" #include "armnn/Types.hpp" @@ -332,6 +333,7 @@ struct OptimizerOptions /// @param network INetwork description of the network to be optimized. /// @param backendPreferences The choice of the backend ordered by user preferences. /// @param deviceSpec DeviceSpec object as queried from the runtime. See IRuntime::GetDeviceSpec() +/// @param errMessages if there are failures or warnings a string describing same will be added to the vector /// @param options OptimizerOptions object with optimizer configuration options /// @return An IOptimizedNetworkPtr interface to the optimized network, throws an exception derived from /// armnn::Exception if process fails. @@ -339,5 +341,6 @@ struct OptimizerOptions IOptimizedNetworkPtr Optimize(const INetwork& network, const std::vector& backendPreferences, const IDeviceSpec& deviceSpec, - const OptimizerOptions& options = OptimizerOptions()); + const OptimizerOptions& options = OptimizerOptions(), + Optional&> errMessages = EmptyOptional()); } //namespace armnn -- cgit v1.2.1