aboutsummaryrefslogtreecommitdiff
path: root/src/backends/backendsCommon/test/layerTests/Pooling2dTestImpl.cpp
diff options
context:
space:
mode:
authorMatthew Sloyan <matthew.sloyan@arm.com>2020-09-09 09:07:37 +0100
committerJan Eilers <jan.eilers@arm.com>2020-09-17 08:31:09 +0000
commit171214c8ff275c90cd4f7fc23a34ec2c83b5ea39 (patch)
tree23fd3ee288d631c8c94bede71f89f0f1e12da862 /src/backends/backendsCommon/test/layerTests/Pooling2dTestImpl.cpp
parenta25886e0966a6b9433cd23595688fadb88a161b2 (diff)
downloadarmnn-171214c8ff275c90cd4f7fc23a34ec2c83b5ea39.tar.gz
IVGCVSW-5300 Remove some boost::numeric_cast from armnn/backends
* Replaced with armnn/utility/NumericCast.hpp * Some exclusions in reference backend * Excluded as requires float implementation in NumericCast.hpp Signed-off-by: Matthew Sloyan <matthew.sloyan@arm.com> Change-Id: I9e4e9cd502c865452128fa04415fd6f250baa855
Diffstat (limited to 'src/backends/backendsCommon/test/layerTests/Pooling2dTestImpl.cpp')
-rw-r--r--src/backends/backendsCommon/test/layerTests/Pooling2dTestImpl.cpp17
1 files changed, 9 insertions, 8 deletions
diff --git a/src/backends/backendsCommon/test/layerTests/Pooling2dTestImpl.cpp b/src/backends/backendsCommon/test/layerTests/Pooling2dTestImpl.cpp
index a4f87ff3ed..70e2e61475 100644
--- a/src/backends/backendsCommon/test/layerTests/Pooling2dTestImpl.cpp
+++ b/src/backends/backendsCommon/test/layerTests/Pooling2dTestImpl.cpp
@@ -15,6 +15,7 @@
#include <armnnUtils/Permute.hpp>
#include <armnn/utility/IgnoreUnused.hpp>
+#include <armnn/utility/NumericCast.hpp>
#include <backendsCommon/WorkloadInfo.hpp>
@@ -48,15 +49,15 @@ LayerTestResult<T, 4> SimplePooling2dTestImpl(
auto widthIndex = dimensionIndices.GetWidthIndex();
auto channelsIndex = dimensionIndices.GetChannelsIndex();
- unsigned int inputHeight = boost::numeric_cast<unsigned int>(input.shape()[heightIndex]);
- unsigned int inputWidth = boost::numeric_cast<unsigned int>(input.shape()[widthIndex]);
- unsigned int inputChannels = boost::numeric_cast<unsigned int>(input.shape()[channelsIndex]);
- unsigned int inputBatchSize = boost::numeric_cast<unsigned int>(input.shape()[0]);
+ unsigned int inputHeight = armnn::numeric_cast<unsigned int>(input.shape()[heightIndex]);
+ unsigned int inputWidth = armnn::numeric_cast<unsigned int>(input.shape()[widthIndex]);
+ unsigned int inputChannels = armnn::numeric_cast<unsigned int>(input.shape()[channelsIndex]);
+ unsigned int inputBatchSize = armnn::numeric_cast<unsigned int>(input.shape()[0]);
- unsigned int outputHeight = boost::numeric_cast<unsigned int>(outputExpected.shape()[heightIndex]);
- unsigned int outputWidth = boost::numeric_cast<unsigned int>(outputExpected.shape()[widthIndex]);
- unsigned int outputChannels = boost::numeric_cast<unsigned int>(outputExpected.shape()[channelsIndex]);
- unsigned int outputBatchSize = boost::numeric_cast<unsigned int>(outputExpected.shape()[0]);
+ unsigned int outputHeight = armnn::numeric_cast<unsigned int>(outputExpected.shape()[heightIndex]);
+ unsigned int outputWidth = armnn::numeric_cast<unsigned int>(outputExpected.shape()[widthIndex]);
+ unsigned int outputChannels = armnn::numeric_cast<unsigned int>(outputExpected.shape()[channelsIndex]);
+ unsigned int outputBatchSize = armnn::numeric_cast<unsigned int>(outputExpected.shape()[0]);
armnn::TensorInfo inputTensorInfo = armnnUtils::GetTensorInfo(
inputBatchSize, inputChannels, inputHeight, inputWidth, dataLayout, ArmnnType);