diff options
author | Derek Lamberti <derek.lamberti@arm.com> | 2019-04-09 10:25:02 +0100 |
---|---|---|
committer | Derek Lamberti <derek.lamberti@arm.com> | 2019-04-10 15:13:41 +0100 |
commit | f30f7d32b22020f80b21da7b008d8302cee9d395 (patch) | |
tree | 2e213da4704c46b40f20629223365d1ddbf8d8cd /src/backends/reference/workloads/ElementwiseFunction.hpp | |
parent | 82fbe7c0b82f7adadd5120ac4b4f779d0da7c0d5 (diff) | |
download | armnn-f30f7d32b22020f80b21da7b008d8302cee9d395.tar.gz |
IVGCVSW-2946 RefElementwiseWorkload configures prior to first execute
+ Added PostAllocationConfigure() method to workload interface
+ Elementwise function now deduces types based on Functor
- Replaced RefComparisonWorkload with RefElementwiseWorkload specialization
+ Fixed up unit tests and minor formatting
Change-Id: I33d08797767bba01cf4efb2904920ce0f950a4fe
Signed-off-by: Derek Lamberti <derek.lamberti@arm.com>
Diffstat (limited to 'src/backends/reference/workloads/ElementwiseFunction.hpp')
-rw-r--r-- | src/backends/reference/workloads/ElementwiseFunction.hpp | 11 |
1 files changed, 7 insertions, 4 deletions
diff --git a/src/backends/reference/workloads/ElementwiseFunction.hpp b/src/backends/reference/workloads/ElementwiseFunction.hpp index 9eb003d5f9..fd1fab0690 100644 --- a/src/backends/reference/workloads/ElementwiseFunction.hpp +++ b/src/backends/reference/workloads/ElementwiseFunction.hpp @@ -11,15 +11,18 @@ namespace armnn { -template <typename Functor, typename DecoderOp, typename EncoderOp> +template <typename Functor> struct ElementwiseFunction { + using OutType = typename Functor::result_type; + using InType = typename Functor::first_argument_type; + ElementwiseFunction(const TensorShape& inShape0, const TensorShape& inShape1, const TensorShape& outShape, - DecoderOp& inData0, - DecoderOp& inData1, - EncoderOp& outData); + armnn::Decoder<InType>& inData0, + armnn::Decoder<InType>& inData1, + armnn::Encoder<OutType>& outData); }; } //namespace armnn |