diff options
author | Jan Eilers <jan.eilers@arm.com> | 2020-08-12 14:59:06 +0100 |
---|---|---|
committer | TeresaARM <teresa.charlinreyes@arm.com> | 2020-08-17 16:10:54 +0000 |
commit | 841aca155b35cc17ea9527599d2c364695e28166 (patch) | |
tree | 8861d6f275f5955495201f0e1b0677bb44604a17 /python/pyarmnn/src/pyarmnn/swig/armnn_tfliteparser.i | |
parent | 313c99f9a64c7fc51dc70757bffff3088c2e95cf (diff) | |
download | armnn-841aca155b35cc17ea9527599d2c364695e28166.tar.gz |
IVGCVSW-5200 Update pyarmnn
* Add HalfPixelCenters to Resize
* Update pyarmnn version to semantic versioning
* Add fill operator
* Add Bf16 optimization
* Add Gather operator
* Update TransposeConvolution2d descriptor
* Add Rank operator
* Add load dynamic tensor support of TfLiteParser
Signed-off-by: Jan Eilers <jan.eilers@arm.com>
Change-Id: I7e76ed286ab87bd97a65ff62868ba7db7967376f
Diffstat (limited to 'python/pyarmnn/src/pyarmnn/swig/armnn_tfliteparser.i')
-rw-r--r-- | python/pyarmnn/src/pyarmnn/swig/armnn_tfliteparser.i | 30 |
1 files changed, 27 insertions, 3 deletions
diff --git a/python/pyarmnn/src/pyarmnn/swig/armnn_tfliteparser.i b/python/pyarmnn/src/pyarmnn/swig/armnn_tfliteparser.i index 825b104a27..3ed5d6b8fd 100644 --- a/python/pyarmnn/src/pyarmnn/swig/armnn_tfliteparser.i +++ b/python/pyarmnn/src/pyarmnn/swig/armnn_tfliteparser.i @@ -87,14 +87,37 @@ public: list: A list of the output tensor names for the given model. ") GetSubgraphOutputTensorNames; std::vector<std::string> GetSubgraphOutputTensorNames(size_t subgraphId); + + %feature("flatnested"); + %feature("docstring", + " + Options for TfLiteParser. + + Contains: + m_StandInLayerForUnsupported (bool): Add StandInLayers as placeholders for unsupported operators. + Default: False + m_InferAndValidate (bool): Infer output shape of operations based on their input shape. Default: False + ")TfLiteParserOptions; + struct TfLiteParserOptions + { + TfLiteParserOptions(); + + bool m_StandInLayerForUnsupported; + bool m_InferAndValidate; + }; }; %extend ITfLiteParser { // This is not a substitution of the default constructor of the Armnn class. It tells swig to create custom __init__ // method for ITfLiteParser python object that will use static factory method to do the job. - ITfLiteParser() { - return armnnTfLiteParser::ITfLiteParser::CreateRaw(); + ITfLiteParser(const armnnTfLiteParser::ITfLiteParser::TfLiteParserOptions* options = nullptr) { + if (options) { + return armnnTfLiteParser::ITfLiteParser::CreateRaw( + armnn::Optional<armnnTfLiteParser::ITfLiteParser::TfLiteParserOptions>(*options)); + } else { + return armnnTfLiteParser::ITfLiteParser::CreateRaw(); + } } // The following does not replace a real destructor of the Armnn class. @@ -127,6 +150,7 @@ public: } -} +} // end of namespace armnnTfLiteParser + // Clear exception typemap. %exception; |