telsoa01 | 4fcda01 | 2018-03-09 14:13:49 +0000 | [diff] [blame] | 1 | // |
| 2 | // Copyright © 2017 Arm Ltd. All rights reserved. |
David Beck | ecb56cd | 2018-09-05 12:52:57 +0100 | [diff] [blame] | 3 | // SPDX-License-Identifier: MIT |
telsoa01 | 4fcda01 | 2018-03-09 14:13:49 +0000 | [diff] [blame] | 4 | // |
| 5 | |
| 6 | #include "NeonLayerSupport.hpp" |
David Beck | 3e9e115 | 2018-10-17 14:17:50 +0100 | [diff] [blame] | 7 | #include "NeonBackendId.hpp" |
telsoa01 | 4fcda01 | 2018-03-09 14:13:49 +0000 | [diff] [blame] | 8 | |
telsoa01 | 4fcda01 | 2018-03-09 14:13:49 +0000 | [diff] [blame] | 9 | #include <armnn/Descriptors.hpp> |
Aron Virginas-Tar | c9cc804 | 2018-11-01 16:15:57 +0000 | [diff] [blame] | 10 | #include <InternalTypes.hpp> |
| 11 | #include <LayerSupportCommon.hpp> |
telsoa01 | 4fcda01 | 2018-03-09 14:13:49 +0000 | [diff] [blame] | 12 | #include <armnn/Tensor.hpp> |
Aron Virginas-Tar | fc82431 | 2018-10-15 15:00:13 +0100 | [diff] [blame] | 13 | #include <armnn/Types.hpp> |
telsoa01 | 4fcda01 | 2018-03-09 14:13:49 +0000 | [diff] [blame] | 14 | |
David Beck | 111b5d9 | 2018-11-12 14:59:37 +0000 | [diff] [blame] | 15 | #include <backendsCommon/BackendRegistry.hpp> |
David Beck | 3e9e115 | 2018-10-17 14:17:50 +0100 | [diff] [blame] | 16 | |
telsoa01 | 4fcda01 | 2018-03-09 14:13:49 +0000 | [diff] [blame] | 17 | #include <boost/core/ignore_unused.hpp> |
| 18 | |
Matteo Martincigh | d95e906 | 2019-01-31 15:35:59 +0000 | [diff] [blame] | 19 | #if defined(ARMCOMPUTENEON_ENABLED) |
Narumol Prangnawarat | 15eb583 | 2019-05-20 15:31:05 +0100 | [diff] [blame] | 20 | #include <aclCommon/ArmComputeUtils.hpp> |
Aron Virginas-Tar | 914e4db | 2019-09-09 13:36:45 +0100 | [diff] [blame] | 21 | #include "workloads/NeonAbsWorkload.hpp" |
Matthew Bentham | 955258d | 2018-12-10 10:48:52 +0000 | [diff] [blame] | 22 | #include "workloads/NeonAdditionWorkload.hpp" |
Nattapat Chaimanowong | d4b7059 | 2018-10-12 11:21:49 +0100 | [diff] [blame] | 23 | #include "workloads/NeonActivationWorkload.hpp" |
Matthew Bentham | c48ac8c | 2018-12-12 16:15:59 +0000 | [diff] [blame] | 24 | #include "workloads/NeonBatchNormalizationWorkload.hpp" |
Nattapat Chaimanowong | 974b65f | 2018-10-15 15:07:34 +0100 | [diff] [blame] | 25 | #include "workloads/NeonConvolution2dWorkload.hpp" |
Nattapat Chaimanowong | 7714088 | 2018-10-17 11:12:19 +0100 | [diff] [blame] | 26 | #include "workloads/NeonDepthwiseConvolutionWorkload.hpp" |
Narumol Prangnawarat | 01961a7 | 2019-05-30 16:47:12 +0100 | [diff] [blame] | 27 | #include "workloads/NeonDequantizeWorkload.hpp" |
kevmay01 | eed8592 | 2019-01-28 08:37:25 +0000 | [diff] [blame] | 28 | #include "workloads/NeonGreaterWorkload.hpp" |
David Beck | 0dbe0ee | 2018-09-24 15:59:27 +0100 | [diff] [blame] | 29 | #include "workloads/NeonL2NormalizationFloatWorkload.hpp" |
Jan Eilers | ad5293a | 2019-07-08 09:57:55 +0100 | [diff] [blame] | 30 | #include "workloads/NeonLstmFloatWorkload.hpp" |
Nattapat Chaimanowong | 4e6597a | 2018-12-20 14:14:06 +0000 | [diff] [blame] | 31 | #include "workloads/NeonMaximumWorkload.hpp" |
Matthew Bentham | fd89996 | 2018-12-31 15:49:42 +0000 | [diff] [blame] | 32 | #include "workloads/NeonMeanWorkload.hpp" |
Jim Flynn | 39d487d | 2019-05-17 15:44:36 +0100 | [diff] [blame] | 33 | #include "workloads/NeonConcatWorkload.hpp" |
Conor Kennedy | 54b2169 | 2019-01-09 07:57:38 +0000 | [diff] [blame] | 34 | #include "workloads/NeonMinimumWorkload.hpp" |
Conor Kennedy | b99480b | 2019-03-08 08:24:41 +0000 | [diff] [blame] | 35 | #include "workloads/NeonMultiplicationWorkload.hpp" |
David Beck | 0dbe0ee | 2018-09-24 15:59:27 +0100 | [diff] [blame] | 36 | #include "workloads/NeonNormalizationFloatWorkload.hpp" |
| 37 | #include "workloads/NeonFullyConnectedWorkload.hpp" |
Éanna Ó Catháin | 1205574 | 2019-01-25 10:01:40 +0000 | [diff] [blame] | 38 | #include "workloads/NeonPadWorkload.hpp" |
David Beck | 0dbe0ee | 2018-09-24 15:59:27 +0100 | [diff] [blame] | 39 | #include "workloads/NeonPermuteWorkload.hpp" |
Nattapat Chaimanowong | 5d2e700 | 2018-10-12 16:03:56 +0100 | [diff] [blame] | 40 | #include "workloads/NeonPooling2dWorkload.hpp" |
Nikhil Raj | 9b46148 | 2019-07-03 15:58:31 +0100 | [diff] [blame] | 41 | #include "workloads/NeonPreluWorkload.hpp" |
Sadik Armagan | fabc289 | 2019-05-31 09:05:11 +0100 | [diff] [blame] | 42 | #include "workloads/NeonQuantizeWorkload.hpp" |
Francis Murtagh | 4fc3c48 | 2019-08-02 13:20:54 +0100 | [diff] [blame] | 43 | #include "workloads/NeonQuantizedLstmWorkload.hpp" |
Ellen Norris-Thompson | 37e6868 | 2019-07-15 14:23:30 +0100 | [diff] [blame] | 44 | #include "workloads/NeonResizeWorkload.hpp" |
Aron Virginas-Tar | 0dd3b43 | 2019-09-10 13:55:09 +0100 | [diff] [blame^] | 45 | #include "workloads/NeonRsqrtWorkload.hpp" |
David Beck | 0dbe0ee | 2018-09-24 15:59:27 +0100 | [diff] [blame] | 46 | #include "workloads/NeonSoftmaxBaseWorkload.hpp" |
Ellen Norris-Thompson | 2979457 | 2019-06-26 16:40:36 +0100 | [diff] [blame] | 47 | #include "workloads/NeonSpaceToDepthWorkload.hpp" |
Narumol Prangnawarat | 15eb583 | 2019-05-20 15:31:05 +0100 | [diff] [blame] | 48 | #include "workloads/NeonSplitterWorkload.hpp" |
Matthew Jackson | 87f65ea | 2019-08-01 10:01:34 +0100 | [diff] [blame] | 49 | #include "workloads/NeonStackWorkload.hpp" |
FinnWilliamsArm | 1fa1919 | 2019-08-02 17:26:31 +0100 | [diff] [blame] | 50 | #include "workloads/NeonStridedSliceWorkload.hpp" |
Conor Kennedy | b99480b | 2019-03-08 08:24:41 +0000 | [diff] [blame] | 51 | #include "workloads/NeonSubtractionWorkload.hpp" |
Sadik Armagan | 581742d | 2019-08-12 14:11:37 +0100 | [diff] [blame] | 52 | #include "workloads/NeonTransposeConvolution2dWorkload.hpp" |
telsoa01 | 4fcda01 | 2018-03-09 14:13:49 +0000 | [diff] [blame] | 53 | #endif |
| 54 | |
| 55 | using namespace boost; |
| 56 | |
| 57 | namespace armnn |
| 58 | { |
telsoa01 | 4fcda01 | 2018-03-09 14:13:49 +0000 | [diff] [blame] | 59 | |
Aron Virginas-Tar | fc82431 | 2018-10-15 15:00:13 +0100 | [diff] [blame] | 60 | namespace |
arovir01 | 7ff76c5 | 2018-10-09 09:40:58 +0100 | [diff] [blame] | 61 | { |
telsoa01 | 4fcda01 | 2018-03-09 14:13:49 +0000 | [diff] [blame] | 62 | |
arovir01 | 085f0a4 | 2018-10-08 14:48:19 +0100 | [diff] [blame] | 63 | bool IsNeonBackendSupported(Optional<std::string&> reasonIfUnsupported) |
telsoa01 | 4fcda01 | 2018-03-09 14:13:49 +0000 | [diff] [blame] | 64 | { |
Matteo Martincigh | d95e906 | 2019-01-31 15:35:59 +0000 | [diff] [blame] | 65 | #if defined(ARMCOMPUTENEON_ENABLED) |
telsoa01 | 4fcda01 | 2018-03-09 14:13:49 +0000 | [diff] [blame] | 66 | return true; |
| 67 | #else |
Derek Lamberti | 0790dce | 2019-04-15 18:37:35 +0100 | [diff] [blame] | 68 | SetValueChecked(reasonIfUnsupported, "The armnn library has been built without NEON support"); |
telsoa01 | 4fcda01 | 2018-03-09 14:13:49 +0000 | [diff] [blame] | 69 | return false; |
| 70 | #endif |
| 71 | } |
| 72 | |
telsoa01 | c577f2c | 2018-08-31 09:22:23 +0100 | [diff] [blame] | 73 | template<typename FloatFunc, typename Uint8Func, typename ... Params> |
arovir01 | 085f0a4 | 2018-10-08 14:48:19 +0100 | [diff] [blame] | 74 | bool IsSupportedForDataTypeNeon(Optional<std::string&> reasonIfUnsupported, |
telsoa01 | 4fcda01 | 2018-03-09 14:13:49 +0000 | [diff] [blame] | 75 | DataType dataType, |
telsoa01 | c577f2c | 2018-08-31 09:22:23 +0100 | [diff] [blame] | 76 | FloatFunc floatFuncPtr, |
telsoa01 | 4fcda01 | 2018-03-09 14:13:49 +0000 | [diff] [blame] | 77 | Uint8Func uint8FuncPtr, |
| 78 | Params&&... params) |
| 79 | { |
| 80 | return IsNeonBackendSupported(reasonIfUnsupported) && |
| 81 | IsSupportedForDataTypeGeneric(reasonIfUnsupported, |
| 82 | dataType, |
| 83 | floatFuncPtr, |
telsoa01 | c577f2c | 2018-08-31 09:22:23 +0100 | [diff] [blame] | 84 | floatFuncPtr, |
telsoa01 | 4fcda01 | 2018-03-09 14:13:49 +0000 | [diff] [blame] | 85 | uint8FuncPtr, |
narpra01 | db2b160 | 2019-01-23 15:23:11 +0000 | [diff] [blame] | 86 | &FalseFunc<>, |
kevmay01 | 2b4d88e | 2019-01-24 14:05:09 +0000 | [diff] [blame] | 87 | &FalseFunc<>, |
telsoa01 | 4fcda01 | 2018-03-09 14:13:49 +0000 | [diff] [blame] | 88 | std::forward<Params>(params)...); |
| 89 | } |
| 90 | |
Matteo Martincigh | d95e906 | 2019-01-31 15:35:59 +0000 | [diff] [blame] | 91 | #if defined(ARMCOMPUTENEON_ENABLED) |
telsoa01 | 4fcda01 | 2018-03-09 14:13:49 +0000 | [diff] [blame] | 92 | template<class FuncType, class... Args> |
arovir01 | 085f0a4 | 2018-10-08 14:48:19 +0100 | [diff] [blame] | 93 | inline bool IsWorkloadSupported(FuncType& func, Optional<std::string&> reasonIfUnsupported, Args&&... args) |
telsoa01 | 4fcda01 | 2018-03-09 14:13:49 +0000 | [diff] [blame] | 94 | { |
| 95 | arm_compute::Status aclStatus = func(std::forward<Args>(args)...); |
| 96 | const bool supported = (aclStatus.error_code() == arm_compute::ErrorCode::OK); |
| 97 | if (!supported && reasonIfUnsupported) |
| 98 | { |
arovir01 | 085f0a4 | 2018-10-08 14:48:19 +0100 | [diff] [blame] | 99 | reasonIfUnsupported.value() = aclStatus.error_description(); |
telsoa01 | 4fcda01 | 2018-03-09 14:13:49 +0000 | [diff] [blame] | 100 | } |
| 101 | return supported; |
| 102 | } |
| 103 | |
| 104 | #define FORWARD_WORKLOAD_VALIDATE_FUNC(func, reasonIfUnsupported, ...) \ |
| 105 | return IsWorkloadSupported(func, reasonIfUnsupported, __VA_ARGS__); |
| 106 | #else |
| 107 | #define FORWARD_WORKLOAD_VALIDATE_FUNC(func, reasonIfUnsupported, ...) \ |
| 108 | return IsNeonBackendSupported(reasonIfUnsupported); |
| 109 | #endif |
| 110 | |
Aron Virginas-Tar | fc82431 | 2018-10-15 15:00:13 +0100 | [diff] [blame] | 111 | } // anonymous namespace |
| 112 | |
Aron Virginas-Tar | 914e4db | 2019-09-09 13:36:45 +0100 | [diff] [blame] | 113 | bool NeonLayerSupport::IsAbsSupported(const TensorInfo& input, |
| 114 | const TensorInfo& output, |
| 115 | Optional<std::string&> reasonIfUnsupported) const |
| 116 | { |
| 117 | FORWARD_WORKLOAD_VALIDATE_FUNC(NeonAbsWorkloadValidate, |
| 118 | reasonIfUnsupported, |
| 119 | input, |
| 120 | output); |
| 121 | } |
| 122 | |
Aron Virginas-Tar | fc82431 | 2018-10-15 15:00:13 +0100 | [diff] [blame] | 123 | bool NeonLayerSupport::IsActivationSupported(const TensorInfo& input, |
| 124 | const TensorInfo& output, |
| 125 | const ActivationDescriptor& descriptor, |
| 126 | Optional<std::string&> reasonIfUnsupported) const |
telsoa01 | 4fcda01 | 2018-03-09 14:13:49 +0000 | [diff] [blame] | 127 | { |
| 128 | ignore_unused(descriptor); |
telsoa01 | c577f2c | 2018-08-31 09:22:23 +0100 | [diff] [blame] | 129 | FORWARD_WORKLOAD_VALIDATE_FUNC(NeonActivationWorkloadValidate, |
| 130 | reasonIfUnsupported, |
| 131 | input, |
| 132 | output, |
| 133 | descriptor); |
telsoa01 | 4fcda01 | 2018-03-09 14:13:49 +0000 | [diff] [blame] | 134 | } |
| 135 | |
Aron Virginas-Tar | fc82431 | 2018-10-15 15:00:13 +0100 | [diff] [blame] | 136 | bool NeonLayerSupport::IsAdditionSupported(const TensorInfo& input0, |
| 137 | const TensorInfo& input1, |
| 138 | const TensorInfo& output, |
| 139 | Optional<std::string&> reasonIfUnsupported) const |
telsoa01 | 4fcda01 | 2018-03-09 14:13:49 +0000 | [diff] [blame] | 140 | { |
telsoa01 | c577f2c | 2018-08-31 09:22:23 +0100 | [diff] [blame] | 141 | FORWARD_WORKLOAD_VALIDATE_FUNC(NeonAdditionWorkloadValidate, |
| 142 | reasonIfUnsupported, |
| 143 | input0, |
| 144 | input1, |
| 145 | output); |
telsoa01 | 4fcda01 | 2018-03-09 14:13:49 +0000 | [diff] [blame] | 146 | } |
| 147 | |
Aron Virginas-Tar | fc82431 | 2018-10-15 15:00:13 +0100 | [diff] [blame] | 148 | bool NeonLayerSupport::IsBatchNormalizationSupported(const TensorInfo& input, |
| 149 | const TensorInfo& output, |
| 150 | const TensorInfo& mean, |
| 151 | const TensorInfo& var, |
| 152 | const TensorInfo& beta, |
| 153 | const TensorInfo& gamma, |
| 154 | const BatchNormalizationDescriptor& descriptor, |
| 155 | Optional<std::string&> reasonIfUnsupported) const |
telsoa01 | 4fcda01 | 2018-03-09 14:13:49 +0000 | [diff] [blame] | 156 | { |
telsoa01 | c577f2c | 2018-08-31 09:22:23 +0100 | [diff] [blame] | 157 | FORWARD_WORKLOAD_VALIDATE_FUNC(NeonBatchNormalizationValidate, |
| 158 | reasonIfUnsupported, |
| 159 | input, |
| 160 | output, |
| 161 | mean, |
| 162 | var, |
| 163 | beta, |
| 164 | gamma, |
| 165 | descriptor); |
telsoa01 | 4fcda01 | 2018-03-09 14:13:49 +0000 | [diff] [blame] | 166 | } |
| 167 | |
Jim Flynn | 906f946 | 2019-05-10 13:55:21 +0100 | [diff] [blame] | 168 | bool NeonLayerSupport::IsConcatSupported(const std::vector<const TensorInfo*> inputs, |
| 169 | const TensorInfo& output, |
Jim Flynn | e242f2d | 2019-05-22 14:24:13 +0100 | [diff] [blame] | 170 | const ConcatDescriptor& descriptor, |
Jim Flynn | 906f946 | 2019-05-10 13:55:21 +0100 | [diff] [blame] | 171 | Optional<std::string&> reasonIfUnsupported) const |
| 172 | { |
Jim Flynn | e242f2d | 2019-05-22 14:24:13 +0100 | [diff] [blame] | 173 | if (descriptor.GetNumDimensions() <= descriptor.GetConcatAxis()) |
| 174 | { |
| 175 | SetValueChecked(reasonIfUnsupported, "Neon Concat: Concat axis > Number of dimensions."); |
| 176 | return false; |
| 177 | } |
| 178 | |
| 179 | unsigned int concatInnerAxis = (descriptor.GetNumDimensions() - descriptor.GetConcatAxis()) - 1; |
| 180 | if(concatInnerAxis < 3) // Width, height, or channels |
| 181 | { |
| 182 | FORWARD_WORKLOAD_VALIDATE_FUNC(NeonConcatWorkloadValidate, |
| 183 | reasonIfUnsupported, |
| 184 | inputs, |
| 185 | output, |
| 186 | descriptor); |
| 187 | } |
| 188 | else if (concatInnerAxis == 3) |
| 189 | { |
| 190 | for (auto& input : inputs) |
| 191 | { |
| 192 | if (input && !output.IsTypeSpaceMatch(*input)) // Cannot use sub-tensors if the types are not same space |
| 193 | { |
| 194 | SetValueChecked(reasonIfUnsupported, "Neon Concat: Types and quantization parameters must match."); |
| 195 | return false; |
| 196 | } |
| 197 | } |
| 198 | return true; // Sub-tensors support concat along batch |
| 199 | } |
| 200 | else // > 4 dimensions not supported. |
| 201 | { |
| 202 | SetValueChecked(reasonIfUnsupported, "Neon Concat: Maximum of 4 dimensions supported."); |
| 203 | return false; |
| 204 | } |
Jim Flynn | 906f946 | 2019-05-10 13:55:21 +0100 | [diff] [blame] | 205 | } |
| 206 | |
Aron Virginas-Tar | fc82431 | 2018-10-15 15:00:13 +0100 | [diff] [blame] | 207 | bool NeonLayerSupport::IsConstantSupported(const TensorInfo& output, |
| 208 | Optional<std::string&> reasonIfUnsupported) const |
telsoa01 | 4fcda01 | 2018-03-09 14:13:49 +0000 | [diff] [blame] | 209 | { |
| 210 | return IsSupportedForDataTypeNeon(reasonIfUnsupported, |
| 211 | output.GetDataType(), |
| 212 | &TrueFunc<>, |
| 213 | &TrueFunc<>); |
| 214 | } |
| 215 | |
Aron Virginas-Tar | fc82431 | 2018-10-15 15:00:13 +0100 | [diff] [blame] | 216 | bool NeonLayerSupport::IsConvertFp16ToFp32Supported(const TensorInfo& input, |
| 217 | const TensorInfo& output, |
| 218 | Optional<std::string&> reasonIfUnsupported) const |
| 219 | { |
| 220 | ignore_unused(input); |
| 221 | ignore_unused(output); |
| 222 | ignore_unused(reasonIfUnsupported); |
| 223 | return true; |
| 224 | } |
| 225 | |
| 226 | bool NeonLayerSupport::IsConvertFp32ToFp16Supported(const TensorInfo& input, |
| 227 | const TensorInfo& output, |
| 228 | Optional<std::string&> reasonIfUnsupported) const |
| 229 | { |
| 230 | ignore_unused(input); |
| 231 | ignore_unused(output); |
| 232 | ignore_unused(reasonIfUnsupported); |
| 233 | return true; |
| 234 | } |
| 235 | |
| 236 | bool NeonLayerSupport::IsConvolution2dSupported(const TensorInfo& input, |
| 237 | const TensorInfo& output, |
| 238 | const Convolution2dDescriptor& descriptor, |
| 239 | const TensorInfo& weights, |
| 240 | const Optional<TensorInfo>& biases, |
| 241 | Optional<std::string&> reasonIfUnsupported) const |
telsoa01 | 4fcda01 | 2018-03-09 14:13:49 +0000 | [diff] [blame] | 242 | { |
surmeh01 | 3537c2c | 2018-05-18 16:31:43 +0100 | [diff] [blame] | 243 | FORWARD_WORKLOAD_VALIDATE_FUNC(NeonConvolution2dWorkloadValidate, |
| 244 | reasonIfUnsupported, |
| 245 | input, |
| 246 | output, |
| 247 | descriptor, |
| 248 | weights, |
| 249 | biases); |
telsoa01 | 4fcda01 | 2018-03-09 14:13:49 +0000 | [diff] [blame] | 250 | } |
| 251 | |
Aron Virginas-Tar | fc82431 | 2018-10-15 15:00:13 +0100 | [diff] [blame] | 252 | bool NeonLayerSupport::IsDepthwiseConvolutionSupported(const TensorInfo& input, |
| 253 | const TensorInfo& output, |
| 254 | const DepthwiseConvolution2dDescriptor& descriptor, |
| 255 | const TensorInfo& weights, |
| 256 | const Optional<TensorInfo>& biases, |
| 257 | Optional<std::string&> reasonIfUnsupported) const |
telsoa01 | 4fcda01 | 2018-03-09 14:13:49 +0000 | [diff] [blame] | 258 | { |
telsoa01 | c577f2c | 2018-08-31 09:22:23 +0100 | [diff] [blame] | 259 | FORWARD_WORKLOAD_VALIDATE_FUNC(NeonDepthwiseConvolutionWorkloadValidate, |
| 260 | reasonIfUnsupported, |
| 261 | input, |
| 262 | output, |
| 263 | descriptor, |
| 264 | weights, |
| 265 | biases); |
telsoa01 | 4fcda01 | 2018-03-09 14:13:49 +0000 | [diff] [blame] | 266 | } |
| 267 | |
Narumol Prangnawarat | 01961a7 | 2019-05-30 16:47:12 +0100 | [diff] [blame] | 268 | bool NeonLayerSupport::IsDequantizeSupported(const TensorInfo& input, |
| 269 | const TensorInfo& output, |
| 270 | Optional<std::string&> reasonIfUnsupported) const |
| 271 | { |
| 272 | FORWARD_WORKLOAD_VALIDATE_FUNC(NeonDequantizeWorkloadValidate, |
| 273 | reasonIfUnsupported, |
| 274 | input, |
| 275 | output); |
| 276 | } |
| 277 | |
Pablo Tello | f0bd683 | 2019-04-26 17:58:13 +0100 | [diff] [blame] | 278 | bool NeonLayerSupport::IsDilatedDepthwiseConvolutionSupported(const TensorInfo& input, |
| 279 | const TensorInfo& output, |
| 280 | const DepthwiseConvolution2dDescriptor& descriptor, |
| 281 | const TensorInfo& weights, |
| 282 | const Optional<TensorInfo>& biases, |
| 283 | Optional<std::string&> reasonIfUnsupported) const |
| 284 | { |
| 285 | FORWARD_WORKLOAD_VALIDATE_FUNC(NeonDepthwiseConvolutionWorkloadValidate, |
| 286 | reasonIfUnsupported, |
| 287 | input, |
| 288 | output, |
| 289 | descriptor, |
| 290 | weights, |
| 291 | biases); |
| 292 | } |
| 293 | |
Aron Virginas-Tar | fc82431 | 2018-10-15 15:00:13 +0100 | [diff] [blame] | 294 | bool NeonLayerSupport::IsFloorSupported(const TensorInfo& input, |
| 295 | const TensorInfo& output, |
| 296 | Optional<std::string&> reasonIfUnsupported) const |
| 297 | { |
| 298 | ignore_unused(output); |
| 299 | return IsNeonBackendSupported(reasonIfUnsupported) && |
| 300 | IsSupportedForDataTypeGeneric(reasonIfUnsupported, |
| 301 | input.GetDataType(), |
| 302 | &FalseFuncF16<>, |
| 303 | &TrueFunc<>, |
narpra01 | db2b160 | 2019-01-23 15:23:11 +0000 | [diff] [blame] | 304 | &FalseFuncU8<>, |
kevmay01 | 2b4d88e | 2019-01-24 14:05:09 +0000 | [diff] [blame] | 305 | &FalseFuncI32<>, |
| 306 | &FalseFuncU8<>); |
Aron Virginas-Tar | fc82431 | 2018-10-15 15:00:13 +0100 | [diff] [blame] | 307 | } |
| 308 | |
| 309 | bool NeonLayerSupport::IsFullyConnectedSupported(const TensorInfo& input, |
| 310 | const TensorInfo& output, |
| 311 | const TensorInfo& weights, |
| 312 | const TensorInfo& biases, |
| 313 | const FullyConnectedDescriptor& descriptor, |
| 314 | Optional<std::string&> reasonIfUnsupported) const |
telsoa01 | 4fcda01 | 2018-03-09 14:13:49 +0000 | [diff] [blame] | 315 | { |
telsoa01 | c577f2c | 2018-08-31 09:22:23 +0100 | [diff] [blame] | 316 | FORWARD_WORKLOAD_VALIDATE_FUNC(NeonFullyConnectedWorkloadValidate, |
| 317 | reasonIfUnsupported, |
| 318 | input, |
| 319 | output, |
| 320 | weights, |
| 321 | biases, |
| 322 | descriptor); |
telsoa01 | 4fcda01 | 2018-03-09 14:13:49 +0000 | [diff] [blame] | 323 | } |
| 324 | |
kevmay01 | eed8592 | 2019-01-28 08:37:25 +0000 | [diff] [blame] | 325 | bool NeonLayerSupport::IsGreaterSupported(const armnn::TensorInfo& input0, |
| 326 | const armnn::TensorInfo& input1, |
| 327 | const armnn::TensorInfo& output, |
| 328 | armnn::Optional<std::string&> reasonIfUnsupported) const |
| 329 | { |
| 330 | FORWARD_WORKLOAD_VALIDATE_FUNC(NeonGreaterWorkloadValidate, |
| 331 | reasonIfUnsupported, |
| 332 | input0, |
| 333 | input1, |
| 334 | output); |
| 335 | } |
| 336 | |
Aron Virginas-Tar | fc82431 | 2018-10-15 15:00:13 +0100 | [diff] [blame] | 337 | bool NeonLayerSupport::IsInputSupported(const TensorInfo& input, |
| 338 | Optional<std::string&> reasonIfUnsupported) const |
telsoa01 | 4fcda01 | 2018-03-09 14:13:49 +0000 | [diff] [blame] | 339 | { |
Francis Murtagh | b3fc252 | 2019-08-09 13:20:50 +0100 | [diff] [blame] | 340 | return IsNeonBackendSupported(reasonIfUnsupported); |
telsoa01 | 4fcda01 | 2018-03-09 14:13:49 +0000 | [diff] [blame] | 341 | } |
| 342 | |
Aron Virginas-Tar | fc82431 | 2018-10-15 15:00:13 +0100 | [diff] [blame] | 343 | bool NeonLayerSupport::IsL2NormalizationSupported(const TensorInfo& input, |
| 344 | const TensorInfo& output, |
| 345 | const L2NormalizationDescriptor& descriptor, |
| 346 | Optional<std::string&> reasonIfUnsupported) const |
telsoa01 | 4fcda01 | 2018-03-09 14:13:49 +0000 | [diff] [blame] | 347 | { |
Matteo Martincigh | bcd3c85 | 2018-09-28 14:14:12 +0100 | [diff] [blame] | 348 | FORWARD_WORKLOAD_VALIDATE_FUNC(NeonL2NormalizationWorkloadValidate, reasonIfUnsupported, input, output, descriptor); |
telsoa01 | 4fcda01 | 2018-03-09 14:13:49 +0000 | [diff] [blame] | 349 | } |
| 350 | |
Jan Eilers | ad5293a | 2019-07-08 09:57:55 +0100 | [diff] [blame] | 351 | bool NeonLayerSupport::IsLstmSupported(const TensorInfo& input, |
| 352 | const TensorInfo& outputStateIn, |
| 353 | const TensorInfo& cellStateIn, |
| 354 | const TensorInfo& scratchBuffer, |
| 355 | const TensorInfo& outputStateOut, |
| 356 | const TensorInfo& cellStateOut, |
| 357 | const TensorInfo& output, |
| 358 | const LstmDescriptor& descriptor, |
| 359 | const LstmInputParamsInfo& paramsInfo, |
| 360 | Optional<std::string&> reasonIfUnsupported) const |
| 361 | { |
| 362 | FORWARD_WORKLOAD_VALIDATE_FUNC(NeonLstmFloatWorkloadValidate, |
| 363 | reasonIfUnsupported, |
| 364 | input, |
| 365 | outputStateIn, |
| 366 | cellStateIn, |
| 367 | scratchBuffer, |
| 368 | outputStateOut, |
| 369 | cellStateOut, |
| 370 | output, |
| 371 | descriptor, |
| 372 | paramsInfo); |
| 373 | } |
| 374 | |
Nattapat Chaimanowong | 4e6597a | 2018-12-20 14:14:06 +0000 | [diff] [blame] | 375 | bool NeonLayerSupport::IsMaximumSupported(const TensorInfo& input0, |
| 376 | const TensorInfo& input1, |
| 377 | const TensorInfo& output, |
| 378 | Optional<std::string&> reasonIfUnsupported) const |
| 379 | { |
| 380 | FORWARD_WORKLOAD_VALIDATE_FUNC(NeonMaximumWorkloadValidate, |
| 381 | reasonIfUnsupported, |
| 382 | input0, |
| 383 | input1, |
| 384 | output); |
| 385 | } |
| 386 | |
Aron Virginas-Tar | fc82431 | 2018-10-15 15:00:13 +0100 | [diff] [blame] | 387 | bool NeonLayerSupport::IsMeanSupported(const TensorInfo& input, |
| 388 | const TensorInfo& output, |
| 389 | const MeanDescriptor& descriptor, |
| 390 | Optional<std::string&> reasonIfUnsupported) const |
narpra01 | 32b9046 | 2018-09-13 11:07:48 +0100 | [diff] [blame] | 391 | { |
Matthew Bentham | fd89996 | 2018-12-31 15:49:42 +0000 | [diff] [blame] | 392 | FORWARD_WORKLOAD_VALIDATE_FUNC(NeonMeanWorkloadValidate, |
| 393 | reasonIfUnsupported, |
| 394 | input, |
| 395 | output, |
| 396 | descriptor); |
narpra01 | 32b9046 | 2018-09-13 11:07:48 +0100 | [diff] [blame] | 397 | } |
| 398 | |
Aron Virginas-Tar | fc82431 | 2018-10-15 15:00:13 +0100 | [diff] [blame] | 399 | bool NeonLayerSupport::IsMergerSupported(const std::vector<const TensorInfo*> inputs, |
Nikhil Raj | 8599a41 | 2018-11-19 14:51:07 +0000 | [diff] [blame] | 400 | const TensorInfo& output, |
Jim Flynn | e242f2d | 2019-05-22 14:24:13 +0100 | [diff] [blame] | 401 | const MergerDescriptor& descriptor, |
Aron Virginas-Tar | fc82431 | 2018-10-15 15:00:13 +0100 | [diff] [blame] | 402 | Optional<std::string&> reasonIfUnsupported) const |
| 403 | { |
Jim Flynn | e242f2d | 2019-05-22 14:24:13 +0100 | [diff] [blame] | 404 | return IsConcatSupported(inputs, output, descriptor, reasonIfUnsupported); |
Aron Virginas-Tar | fc82431 | 2018-10-15 15:00:13 +0100 | [diff] [blame] | 405 | } |
| 406 | |
Conor Kennedy | 54b2169 | 2019-01-09 07:57:38 +0000 | [diff] [blame] | 407 | bool NeonLayerSupport::IsMinimumSupported(const TensorInfo& input0, |
| 408 | const TensorInfo& input1, |
| 409 | const TensorInfo& output, |
| 410 | Optional<std::string&> reasonIfUnsupported) const |
| 411 | { |
| 412 | FORWARD_WORKLOAD_VALIDATE_FUNC(NeonMinimumWorkloadValidate, |
| 413 | reasonIfUnsupported, |
| 414 | input0, |
| 415 | input1, |
| 416 | output); |
| 417 | } |
| 418 | |
Aron Virginas-Tar | fc82431 | 2018-10-15 15:00:13 +0100 | [diff] [blame] | 419 | bool NeonLayerSupport::IsMultiplicationSupported(const TensorInfo& input0, |
| 420 | const TensorInfo& input1, |
| 421 | const TensorInfo& output, |
| 422 | Optional<std::string&> reasonIfUnsupported) const |
| 423 | { |
| 424 | FORWARD_WORKLOAD_VALIDATE_FUNC(NeonMultiplicationWorkloadValidate, |
| 425 | reasonIfUnsupported, |
| 426 | input0, |
| 427 | input1, |
| 428 | output); |
| 429 | } |
| 430 | |
| 431 | bool NeonLayerSupport::IsNormalizationSupported(const TensorInfo& input, |
| 432 | const TensorInfo& output, |
| 433 | const NormalizationDescriptor& descriptor, |
| 434 | Optional<std::string&> reasonIfUnsupported) const |
| 435 | { |
| 436 | FORWARD_WORKLOAD_VALIDATE_FUNC(NeonNormalizationWorkloadValidate, |
| 437 | reasonIfUnsupported, |
| 438 | input, |
| 439 | output, |
| 440 | descriptor); |
| 441 | } |
| 442 | |
| 443 | bool NeonLayerSupport::IsOutputSupported(const TensorInfo& output, |
| 444 | Optional<std::string&> reasonIfUnsupported) const |
| 445 | { |
Francis Murtagh | b3fc252 | 2019-08-09 13:20:50 +0100 | [diff] [blame] | 446 | return IsNeonBackendSupported(reasonIfUnsupported); |
Aron Virginas-Tar | fc82431 | 2018-10-15 15:00:13 +0100 | [diff] [blame] | 447 | } |
| 448 | |
Éanna Ó Catháin | 1205574 | 2019-01-25 10:01:40 +0000 | [diff] [blame] | 449 | bool NeonLayerSupport::IsPadSupported(const TensorInfo& input, |
| 450 | const TensorInfo& output, |
| 451 | const PadDescriptor& descriptor, |
| 452 | Optional<std::string&> reasonIfUnsupported) const |
| 453 | { |
| 454 | FORWARD_WORKLOAD_VALIDATE_FUNC(NeonPadWorkloadValidate, |
| 455 | reasonIfUnsupported, |
| 456 | input, |
| 457 | output, |
| 458 | descriptor); |
| 459 | } |
| 460 | |
Aron Virginas-Tar | fc82431 | 2018-10-15 15:00:13 +0100 | [diff] [blame] | 461 | bool NeonLayerSupport::IsPermuteSupported(const TensorInfo& input, |
| 462 | const TensorInfo& output, |
| 463 | const PermuteDescriptor& descriptor, |
| 464 | Optional<std::string&> reasonIfUnsupported) const |
| 465 | { |
| 466 | FORWARD_WORKLOAD_VALIDATE_FUNC(NeonPermuteWorkloadValidate, reasonIfUnsupported, input, output, descriptor); |
telsoa01 | 4fcda01 | 2018-03-09 14:13:49 +0000 | [diff] [blame] | 467 | } |
Aron Virginas-Tar | fc82431 | 2018-10-15 15:00:13 +0100 | [diff] [blame] | 468 | |
| 469 | bool NeonLayerSupport::IsPooling2dSupported(const TensorInfo& input, |
| 470 | const TensorInfo& output, |
| 471 | const Pooling2dDescriptor& descriptor, |
| 472 | Optional<std::string&> reasonIfUnsupported) const |
| 473 | { |
| 474 | FORWARD_WORKLOAD_VALIDATE_FUNC(NeonPooling2dWorkloadValidate, reasonIfUnsupported, input, output, descriptor); |
| 475 | } |
| 476 | |
Nikhil Raj | 9b46148 | 2019-07-03 15:58:31 +0100 | [diff] [blame] | 477 | bool NeonLayerSupport::IsPreluSupported(const armnn::TensorInfo &input, |
| 478 | const armnn::TensorInfo &alpha, |
| 479 | const armnn::TensorInfo &output, |
| 480 | armnn::Optional<std::string &> reasonIfUnsupported) const |
| 481 | { |
| 482 | FORWARD_WORKLOAD_VALIDATE_FUNC(NeonPreluWorkloadValidate, reasonIfUnsupported, input, alpha, output); |
| 483 | } |
| 484 | |
Sadik Armagan | fabc289 | 2019-05-31 09:05:11 +0100 | [diff] [blame] | 485 | bool NeonLayerSupport::IsQuantizeSupported(const TensorInfo& input, |
| 486 | const TensorInfo& output, |
| 487 | Optional<std::string&> reasonIfUnsupported) const |
| 488 | { |
| 489 | FORWARD_WORKLOAD_VALIDATE_FUNC(NeonQuantizeWorkloadValidate, |
| 490 | reasonIfUnsupported, |
| 491 | input, |
| 492 | output); |
| 493 | } |
| 494 | |
Francis Murtagh | 4fc3c48 | 2019-08-02 13:20:54 +0100 | [diff] [blame] | 495 | bool NeonLayerSupport::IsQuantizedLstmSupported(const TensorInfo& input, |
| 496 | const TensorInfo& cellStateIn, |
| 497 | const TensorInfo& outputStateIn, |
| 498 | const TensorInfo& cellStateOut, |
| 499 | const TensorInfo& outputStateOut, |
| 500 | const QuantizedLstmInputParamsInfo& paramsInfo, |
| 501 | Optional<std::string&> reasonIfUnsupported) const |
| 502 | { |
| 503 | FORWARD_WORKLOAD_VALIDATE_FUNC(NeonQuantizedLstmWorkloadValidate, |
| 504 | reasonIfUnsupported, |
| 505 | input, |
| 506 | cellStateIn, |
| 507 | outputStateIn, |
| 508 | cellStateOut, |
| 509 | outputStateOut, |
| 510 | paramsInfo); |
| 511 | } |
| 512 | |
Aron Virginas-Tar | fc82431 | 2018-10-15 15:00:13 +0100 | [diff] [blame] | 513 | bool NeonLayerSupport::IsReshapeSupported(const TensorInfo& input, |
Matteo Martincigh | 992d6dc | 2019-01-10 17:34:20 +0000 | [diff] [blame] | 514 | const ReshapeDescriptor& descriptor, |
Aron Virginas-Tar | fc82431 | 2018-10-15 15:00:13 +0100 | [diff] [blame] | 515 | Optional<std::string&> reasonIfUnsupported) const |
| 516 | { |
Matteo Martincigh | 992d6dc | 2019-01-10 17:34:20 +0000 | [diff] [blame] | 517 | ignore_unused(descriptor); |
Aron Virginas-Tar | fc82431 | 2018-10-15 15:00:13 +0100 | [diff] [blame] | 518 | return IsSupportedForDataTypeNeon(reasonIfUnsupported, |
| 519 | input.GetDataType(), |
| 520 | &TrueFunc<>, |
| 521 | &TrueFunc<>); |
| 522 | } |
| 523 | |
Aron Virginas-Tar | 169d2f1 | 2019-07-01 19:01:44 +0100 | [diff] [blame] | 524 | bool NeonLayerSupport::IsResizeSupported(const TensorInfo& input, |
| 525 | const TensorInfo& output, |
| 526 | const ResizeDescriptor& descriptor, |
| 527 | Optional<std::string&> reasonIfUnsupported) const |
| 528 | { |
Ellen Norris-Thompson | 37e6868 | 2019-07-15 14:23:30 +0100 | [diff] [blame] | 529 | FORWARD_WORKLOAD_VALIDATE_FUNC(NeonResizeWorkloadValidate, |
| 530 | reasonIfUnsupported, |
| 531 | input, |
| 532 | output, |
| 533 | descriptor); |
Aron Virginas-Tar | 169d2f1 | 2019-07-01 19:01:44 +0100 | [diff] [blame] | 534 | } |
| 535 | |
Sadik Armagan | c625f00 | 2018-12-17 11:32:16 +0000 | [diff] [blame] | 536 | bool NeonLayerSupport::IsResizeBilinearSupported(const TensorInfo& input, |
| 537 | const TensorInfo& output, |
| 538 | Optional<std::string&> reasonIfUnsupported) const |
| 539 | { |
Ellen Norris-Thompson | 37e6868 | 2019-07-15 14:23:30 +0100 | [diff] [blame] | 540 | ResizeDescriptor descriptor; |
| 541 | descriptor.m_Method = ResizeMethod::Bilinear; |
| 542 | descriptor.m_DataLayout = DataLayout::NCHW; |
| 543 | |
| 544 | const TensorShape& outputShape = output.GetShape(); |
| 545 | descriptor.m_TargetHeight = outputShape[2]; |
| 546 | descriptor.m_TargetWidth = outputShape[3]; |
| 547 | |
| 548 | return IsResizeSupported(input, output, descriptor, reasonIfUnsupported); |
Sadik Armagan | c625f00 | 2018-12-17 11:32:16 +0000 | [diff] [blame] | 549 | } |
| 550 | |
Aron Virginas-Tar | 0dd3b43 | 2019-09-10 13:55:09 +0100 | [diff] [blame^] | 551 | bool NeonLayerSupport::IsRsqrtSupported(const TensorInfo& input, |
| 552 | const TensorInfo& output, |
| 553 | Optional<std::string&> reasonIfUnsupported) const |
| 554 | { |
| 555 | FORWARD_WORKLOAD_VALIDATE_FUNC(NeonRsqrtWorkloadValidate, reasonIfUnsupported, input, output); |
| 556 | } |
| 557 | |
Aron Virginas-Tar | fc82431 | 2018-10-15 15:00:13 +0100 | [diff] [blame] | 558 | bool NeonLayerSupport::IsSoftmaxSupported(const TensorInfo& input, |
| 559 | const TensorInfo& output, |
| 560 | const SoftmaxDescriptor& descriptor, |
| 561 | Optional<std::string&> reasonIfUnsupported) const |
| 562 | { |
| 563 | FORWARD_WORKLOAD_VALIDATE_FUNC(NeonSoftmaxWorkloadValidate, reasonIfUnsupported, input, output, descriptor); |
| 564 | } |
| 565 | |
Ellen Norris-Thompson | 2979457 | 2019-06-26 16:40:36 +0100 | [diff] [blame] | 566 | bool NeonLayerSupport::IsSpaceToDepthSupported(const TensorInfo& input, |
| 567 | const TensorInfo& output, |
| 568 | const SpaceToDepthDescriptor& descriptor, |
| 569 | Optional<std::string&> reasonIfUnsupported) const |
| 570 | { |
| 571 | FORWARD_WORKLOAD_VALIDATE_FUNC(NeonSpaceToDepthWorkloadValidate, |
| 572 | reasonIfUnsupported, |
| 573 | input, |
| 574 | output, |
| 575 | descriptor); |
| 576 | } |
| 577 | |
Aron Virginas-Tar | fc82431 | 2018-10-15 15:00:13 +0100 | [diff] [blame] | 578 | bool NeonLayerSupport::IsSplitterSupported(const TensorInfo& input, |
| 579 | const ViewsDescriptor& descriptor, |
| 580 | Optional<std::string&> reasonIfUnsupported) const |
| 581 | { |
| 582 | ignore_unused(descriptor); |
| 583 | return IsSupportedForDataTypeNeon(reasonIfUnsupported, |
| 584 | input.GetDataType(), |
| 585 | &TrueFunc<>, |
| 586 | &TrueFunc<>); |
| 587 | } |
| 588 | |
Narumol Prangnawarat | 15eb583 | 2019-05-20 15:31:05 +0100 | [diff] [blame] | 589 | bool NeonLayerSupport::IsSplitterSupported(const TensorInfo& input, |
| 590 | const std::vector<std::reference_wrapper<TensorInfo>>& outputs, |
| 591 | const ViewsDescriptor& descriptor, |
| 592 | Optional<std::string&> reasonIfUnsupported) const |
| 593 | { |
| 594 | #if defined(ARMCOMPUTENEON_ENABLED) |
| 595 | // Split along the last dimension, cannot use sub-tensors |
| 596 | // as width and height of the sub-tensors do not match |
| 597 | // the width and height of the parent tensor |
| 598 | // in case of input with more than 2D. |
| 599 | std::set<unsigned int> splitAxis = ComputeSplitAxis(descriptor, input.GetShape()); |
| 600 | if (descriptor.GetNumDimensions() > 2 && splitAxis.size() == 1 && |
| 601 | *splitAxis.begin() == descriptor.GetNumDimensions() - 1 ) |
| 602 | { |
| 603 | FORWARD_WORKLOAD_VALIDATE_FUNC(NeonSplitterWorkloadValidate, |
| 604 | reasonIfUnsupported, |
| 605 | input, |
| 606 | outputs, |
| 607 | *splitAxis.begin()); |
| 608 | } |
| 609 | #endif |
| 610 | for (auto output : outputs) |
| 611 | { |
| 612 | if (!input.IsTypeSpaceMatch(output)) // Cannot use sub-tensors if the types are not same space |
| 613 | { |
| 614 | SetValueChecked(reasonIfUnsupported, "Neon Splitter: Types and quantization parameters must match."); |
| 615 | return false; |
| 616 | } |
| 617 | } |
| 618 | return true; |
| 619 | } |
| 620 | |
Matthew Jackson | 87f65ea | 2019-08-01 10:01:34 +0100 | [diff] [blame] | 621 | bool NeonLayerSupport::IsStackSupported(const std::vector<const TensorInfo*>& inputs, |
| 622 | const TensorInfo& output, |
| 623 | const StackDescriptor& descriptor, |
| 624 | Optional<std::string&> reasonIfUnsupported) const |
| 625 | { |
| 626 | FORWARD_WORKLOAD_VALIDATE_FUNC(NeonStackWorkloadValidate, |
| 627 | reasonIfUnsupported, |
| 628 | inputs, |
| 629 | output, |
| 630 | descriptor); |
| 631 | } |
| 632 | |
FinnWilliamsArm | 1fa1919 | 2019-08-02 17:26:31 +0100 | [diff] [blame] | 633 | bool NeonLayerSupport::IsStridedSliceSupported(const TensorInfo& input, |
| 634 | const TensorInfo& output, |
| 635 | const StridedSliceDescriptor& descriptor, |
| 636 | Optional<std::string&> reasonIfUnsupported) const |
| 637 | { |
| 638 | FORWARD_WORKLOAD_VALIDATE_FUNC(NeonStridedSliceWorkloadValidate, |
| 639 | reasonIfUnsupported, |
| 640 | input, |
| 641 | output, |
| 642 | descriptor); |
| 643 | } |
| 644 | |
Aron Virginas-Tar | fc82431 | 2018-10-15 15:00:13 +0100 | [diff] [blame] | 645 | bool NeonLayerSupport::IsSubtractionSupported(const TensorInfo& input0, |
| 646 | const TensorInfo& input1, |
| 647 | const TensorInfo& output, |
| 648 | Optional<std::string&> reasonIfUnsupported) const |
| 649 | { |
| 650 | FORWARD_WORKLOAD_VALIDATE_FUNC(NeonSubtractionWorkloadValidate, |
| 651 | reasonIfUnsupported, |
| 652 | input0, |
| 653 | input1, |
| 654 | output); |
| 655 | } |
| 656 | |
Sadik Armagan | 581742d | 2019-08-12 14:11:37 +0100 | [diff] [blame] | 657 | bool NeonLayerSupport::IsTransposeConvolution2dSupported(const TensorInfo& input, |
| 658 | const TensorInfo& output, |
| 659 | const TransposeConvolution2dDescriptor& descriptor, |
| 660 | const TensorInfo& weights, |
| 661 | const Optional<TensorInfo>& biases, |
| 662 | Optional<std::string&> reasonIfUnsupported) const |
| 663 | { |
| 664 | FORWARD_WORKLOAD_VALIDATE_FUNC(NeonTransposeConvolution2dWorkloadValidate, |
| 665 | reasonIfUnsupported, |
| 666 | input, |
| 667 | output, |
| 668 | descriptor, |
| 669 | weights, |
| 670 | biases); |
| 671 | } |
| 672 | |
Aron Virginas-Tar | fc82431 | 2018-10-15 15:00:13 +0100 | [diff] [blame] | 673 | } // namespace armnn |