blob: 5490230ede34a6de08cf26bf50e2823ce365ba91 [file] [log] [blame]
Jan Eilers45274902020-10-15 18:34:43 +01001//
2// Copyright © 2020 Arm Ltd and Contributors. All rights reserved.
3// SPDX-License-Identifier: MIT
4//
5
6#pragma once
7
8#include <armnn/BackendId.hpp>
9#include <armnn/Tensor.hpp>
10
11/// Holds all parameters necessary to execute a network
12/// Check ExecuteNetworkProgramOptions.cpp for a description of each parameter
13struct ExecuteNetworkParams
14{
15 using TensorShapePtr = std::unique_ptr<armnn::TensorShape>;
16
17 std::vector<armnn::BackendId> m_ComputeDevices;
18 bool m_DequantizeOutput;
19 std::string m_DynamicBackendsPath;
20 bool m_EnableBf16TurboMode;
21 bool m_EnableFastMath = false;
22 bool m_EnableFp16TurboMode;
23 bool m_EnableLayerDetails = false;
24 bool m_EnableProfiling;
25 bool m_GenerateTensorData;
26 bool m_InferOutputShape = false;
27 std::vector<std::string> m_InputNames;
28 std::vector<std::string> m_InputTensorDataFilePaths;
29 std::vector<TensorShapePtr> m_InputTensorShapes;
30 std::vector<std::string> m_InputTypes;
31 bool m_IsModelBinary;
32 size_t m_Iterations;
33 std::string m_ModelFormat;
34 std::string m_ModelPath;
35 std::vector<std::string> m_OutputNames;
36 std::vector<std::string> m_OutputTensorFiles;
37 std::vector<std::string> m_OutputTypes;
38 bool m_ParseUnsupported = false;
39 bool m_PrintIntermediate;
40 bool m_QuantizeInput;
41 size_t m_SubgraphId;
42 double m_ThresholdTime;
43 int m_TuningLevel;
44 std::string m_TuningPath;
45
46 // Ensures that the parameters for ExecuteNetwork fit together
47 void ValidateParams();
48};