diff options
author | Narumol Prangnawarat <narumol.prangnawarat@arm.com> | 2019-06-26 15:10:46 +0100 |
---|---|---|
committer | Narumol Prangnawarat <narumol.prangnawarat@arm.com> | 2019-06-26 17:22:57 +0000 |
commit | 610256fdfd9fc771b7213a9134c86c5988e77fdc (patch) | |
tree | 0f5568df7c5954cca9cd988e188b056adc8fd398 /tests/ExecuteNetwork/ExecuteNetwork.cpp | |
parent | b2b5a26e7b7250532df189cd7cf7cf1d4b528a28 (diff) | |
download | armnn-610256fdfd9fc771b7213a9134c86c5988e77fdc.tar.gz |
IVGCVSW-3193 Allow ExecuteNetwork to have qasymm8 input type
and add option to quantize float inputs to qasymm8
Signed-off-by: Narumol Prangnawarat <narumol.prangnawarat@arm.com>
Change-Id: I54b13b8b53c31c05658fe9c310ca5a66df759aa5
Diffstat (limited to 'tests/ExecuteNetwork/ExecuteNetwork.cpp')
-rw-r--r-- | tests/ExecuteNetwork/ExecuteNetwork.cpp | 7 |
1 files changed, 6 insertions, 1 deletions
diff --git a/tests/ExecuteNetwork/ExecuteNetwork.cpp b/tests/ExecuteNetwork/ExecuteNetwork.cpp index 60353dbf3f..a8f3b3d71d 100644 --- a/tests/ExecuteNetwork/ExecuteNetwork.cpp +++ b/tests/ExecuteNetwork/ExecuteNetwork.cpp @@ -66,6 +66,10 @@ int main(int argc, const char* argv[]) ("input-type,y",po::value(&inputTypes), "The type of the input tensors in the network separated by comma. " "If unset, defaults to \"float\" for all defined inputs. " "Accepted values (float, int or qasymm8)") + ("quantize-input,q",po::bool_switch()->default_value(false), + "If this option is enabled, all float inputs will be quantized to qasymm8. " + "If unset, default to not quantized. " + "Accepted values (true or false)") ("output-type,z",po::value(&outputTypes), "The type of the output tensors in the network separated by comma. " "If unset, defaults to \"float\" for all defined outputs. " @@ -119,6 +123,7 @@ int main(int argc, const char* argv[]) bool concurrent = vm["concurrent"].as<bool>(); bool enableProfiling = vm["event-based-profiling"].as<bool>(); bool enableFp16TurboMode = vm["fp16-turbo-mode"].as<bool>(); + bool quantizeInput = vm["quantize-input"].as<bool>(); // Check whether we have to load test cases from a file. if (CheckOption(vm, "test-cases")) @@ -220,7 +225,7 @@ int main(int argc, const char* argv[]) } return RunTest(modelFormat, inputTensorShapes, computeDevices, modelPath, inputNames, - inputTensorDataFilePaths, inputTypes, outputTypes, outputNames, + inputTensorDataFilePaths, inputTypes, quantizeInput, outputTypes, outputNames, enableProfiling, enableFp16TurboMode, thresholdTime, subgraphId); } } |