diff options
author | telsoa01 <telmo.soares@arm.com> | 2018-08-31 09:22:23 +0100 |
---|---|---|
committer | telsoa01 <telmo.soares@arm.com> | 2018-08-31 09:22:23 +0100 |
commit | c577f2c6a3b4ddb6ba87a882723c53a248afbeba (patch) | |
tree | bd7d4c148df27f8be6649d313efb24f536b7cf34 /tests/CaffeResNet-Armnn | |
parent | 4c7098bfeab1ffe1cdc77f6c15548d3e73274746 (diff) | |
download | armnn-c577f2c6a3b4ddb6ba87a882723c53a248afbeba.tar.gz |
Release 18.08
Diffstat (limited to 'tests/CaffeResNet-Armnn')
-rw-r--r-- | tests/CaffeResNet-Armnn/CaffeResNet-Armnn.cpp | 14 |
1 files changed, 10 insertions, 4 deletions
diff --git a/tests/CaffeResNet-Armnn/CaffeResNet-Armnn.cpp b/tests/CaffeResNet-Armnn/CaffeResNet-Armnn.cpp index 7cccb215a1..3b1a2945a5 100644 --- a/tests/CaffeResNet-Armnn/CaffeResNet-Armnn.cpp +++ b/tests/CaffeResNet-Armnn/CaffeResNet-Armnn.cpp @@ -3,7 +3,7 @@ // See LICENSE file in the project root for full license information. // #include "../InferenceTest.hpp" -#include "../ImageNetDatabase.hpp" +#include "../CaffePreprocessor.hpp" #include "armnnCaffeParser/ICaffeParser.hpp" int main(int argc, char* argv[]) @@ -20,12 +20,18 @@ int main(int argc, char* argv[]) armnn::TensorShape inputTensorShape({ 1, 3, 224, 224 }); + using DataType = float; + using DatabaseType = CaffePreprocessor; + using ParserType = armnnCaffeParser::ICaffeParser; + using ModelType = InferenceModel<ParserType, DataType>; + // Coverity fix: ClassifierInferenceTestMain() may throw uncaught exceptions. - retVal = armnn::test::ClassifierInferenceTestMain<ImageNetDatabase, armnnCaffeParser::ICaffeParser>( + retVal = armnn::test::ClassifierInferenceTestMain<DatabaseType, ParserType>( argc, argv, "ResNet_50_ilsvrc15_model.caffemodel", true, "data", "prob", { 0, 1 }, - [&imageSet](const char* dataDir) { return ImageNetDatabase(dataDir, 224, 224, imageSet); }, - &inputTensorShape); + [&imageSet](const char* dataDir, const ModelType&) { + return DatabaseType(dataDir, 224, 224, imageSet); + }, &inputTensorShape); } catch (const std::exception& e) { |