diff options
Diffstat (limited to 'include/armnn')
-rw-r--r-- | include/armnn/ILayerSupport.hpp | 4 | ||||
-rw-r--r-- | include/armnn/ILayerVisitor.hpp | 7 | ||||
-rw-r--r-- | include/armnn/INetwork.hpp | 4 | ||||
-rw-r--r-- | include/armnn/LayerSupport.hpp | 7 | ||||
-rw-r--r-- | include/armnn/LayerVisitorBase.hpp | 4 |
5 files changed, 25 insertions, 1 deletions
diff --git a/include/armnn/ILayerSupport.hpp b/include/armnn/ILayerSupport.hpp index 4794a219e7..fe440719b0 100644 --- a/include/armnn/ILayerSupport.hpp +++ b/include/armnn/ILayerSupport.hpp @@ -77,6 +77,10 @@ public: const Optional<TensorInfo>& biases, Optional<std::string&> reasonIfUnsupported = EmptyOptional()) const = 0; + virtual bool IsDequantizeSupported(const TensorInfo& input, + const TensorInfo& output, + Optional<std::string&> reasonIfUnsupported = EmptyOptional()) const = 0; + virtual bool IsDetectionPostProcessSupported( const TensorInfo& input0, const TensorInfo& input1, diff --git a/include/armnn/ILayerVisitor.hpp b/include/armnn/ILayerVisitor.hpp index a39cbd10b9..e23cf5e6dd 100644 --- a/include/armnn/ILayerVisitor.hpp +++ b/include/armnn/ILayerVisitor.hpp @@ -95,6 +95,13 @@ public: const Optional<ConstTensor>& biases, const char* name = nullptr) = 0; + /// Function that a Dequantize layer should call back to when its + /// Accept(ILayerVisitor&) function is invoked. + /// @param layer - pointer to the layer which is calling back to this visit function. + /// @param name - Optional name for the layer. + virtual void VisitDequantizeLayer(const IConnectableLayer* layer, + const char* name = nullptr) = 0; + /// Function that a Detection PostProcess layer should call back to when its /// Accept(ILayerVisitor&) function is invoked. /// @param layer - pointer to the layer which is calling back to this visit function. diff --git a/include/armnn/INetwork.hpp b/include/armnn/INetwork.hpp index 7c1fbdbd49..5a9d4f246e 100644 --- a/include/armnn/INetwork.hpp +++ b/include/armnn/INetwork.hpp @@ -147,6 +147,10 @@ public: const ConstTensor& biases, const char* name = nullptr) = 0; + /// Adds a Dequantize layer to the network. + /// @return - Interface for configuring the layer. + virtual IConnectableLayer* AddDequantizeLayer(const char* name = nullptr) = 0; + /// Adds a Detection PostProcess layer to the network. /// @param descriptor - Description of the Detection PostProcess layer. /// @param anchors - Tensor for anchors. diff --git a/include/armnn/LayerSupport.hpp b/include/armnn/LayerSupport.hpp index 7b9343b5d6..7c6bc1372a 100644 --- a/include/armnn/LayerSupport.hpp +++ b/include/armnn/LayerSupport.hpp @@ -96,6 +96,13 @@ bool IsDepthwiseConvolutionSupported(const BackendId& backend, size_t reasonIfUnsupportedMaxLength = 1024); /// Deprecated in favor of IBackend and ILayerSupport interfaces +bool IsDequantizeSupported(const BackendId& backend, + const TensorInfo& input, + const TensorInfo& output, + char* reasonIfUnsupported = nullptr, + size_t reasonIfUnsupportedMaxLength = 1024); + +/// Deprecated in favor of IBackend and ILayerSupport interfaces bool IsDivisionSupported(const BackendId& backend, const TensorInfo& input0, const TensorInfo& input1, diff --git a/include/armnn/LayerVisitorBase.hpp b/include/armnn/LayerVisitorBase.hpp index d30005f0ed..a5459e1a32 100644 --- a/include/armnn/LayerVisitorBase.hpp +++ b/include/armnn/LayerVisitorBase.hpp @@ -45,6 +45,9 @@ public: const Optional<ConstTensor>&, const char*) override { DefaultPolicy::Apply(); } + void VisitDequantizeLayer(const IConnectableLayer*, + const char*) override { DefaultPolicy::Apply(); } + void VisitDetectionPostProcessLayer(const IConnectableLayer*, const DetectionPostProcessDescriptor&, const ConstTensor&, @@ -175,4 +178,3 @@ public: }; } //namespace armnn - |