ArmNN
 21.05
LayerSupportBase.hpp
Go to the documentation of this file.
1 //
2 // Copyright © 2017 Arm Ltd and Contributors. All rights reserved.
3 // SPDX-License-Identifier: MIT
4 //
5 
6 #pragma once
7 
9 
10 namespace armnn
11 {
12 
14 {
15 public:
16  ARMNN_DEPRECATED_MSG("Use IsElementwiseUnarySupported instead")
17  bool IsAbsSupported(const TensorInfo& input,
18  const TensorInfo& output,
19  Optional<std::string&> reasonIfUnsupported = EmptyOptional()) const override;
20 
21  bool IsActivationSupported(const TensorInfo& input,
22  const TensorInfo& output,
23  const ActivationDescriptor& descriptor,
24  Optional<std::string&> reasonIfUnsupported = EmptyOptional()) const override;
25 
26  bool IsAdditionSupported(const TensorInfo& input0,
27  const TensorInfo& input1,
28  const TensorInfo& output,
29  Optional<std::string&> reasonIfUnsupported = EmptyOptional()) const override;
30 
31  bool IsArgMinMaxSupported(const TensorInfo& input,
32  const TensorInfo& output,
33  const ArgMinMaxDescriptor& descriptor,
34  Optional<std::string&> reasonIfUnsupported = EmptyOptional()) const override;
35 
36  bool IsBatchNormalizationSupported(const TensorInfo& input,
37  const TensorInfo& output,
38  const TensorInfo& mean,
39  const TensorInfo& var,
40  const TensorInfo& beta,
41  const TensorInfo& gamma,
42  const BatchNormalizationDescriptor& descriptor,
43  Optional<std::string&> reasonIfUnsupported = EmptyOptional()) const override;
44 
45  bool IsBatchToSpaceNdSupported(const TensorInfo& input,
46  const TensorInfo& output,
47  const BatchToSpaceNdDescriptor& descriptor,
48  Optional<std::string&> reasonIfUnsupported = EmptyOptional()) const override;
49 
50  bool IsCastSupported(const TensorInfo& input,
51  const TensorInfo& output,
52  Optional<std::string&> reasonIfUnsupported = EmptyOptional()) const override;
53 
54  bool IsComparisonSupported(const TensorInfo& input0,
55  const TensorInfo& input1,
56  const TensorInfo& output,
57  const ComparisonDescriptor& descriptor,
58  Optional<std::string&> reasonIfUnsupported = EmptyOptional()) const override;
59 
60  bool IsConcatSupported(const std::vector<const TensorInfo*> inputs,
61  const TensorInfo& output,
62  const OriginsDescriptor& descriptor,
63  Optional<std::string&> reasonIfUnsupported = EmptyOptional()) const override;
64 
65  bool IsConstantSupported(const TensorInfo& output,
66  Optional<std::string&> reasonIfUnsupported = EmptyOptional()) const override;
67 
68  bool IsConvertBf16ToFp32Supported(const TensorInfo& input,
69  const TensorInfo& output,
70  Optional<std::string&> reasonIfUnsupported = EmptyOptional()) const override;
71 
72  bool IsConvertFp16ToFp32Supported(const TensorInfo& input,
73  const TensorInfo& output,
74  Optional<std::string&> reasonIfUnsupported = EmptyOptional()) const override;
75 
76  bool IsConvertFp32ToBf16Supported(const TensorInfo& input,
77  const TensorInfo& output,
78  Optional<std::string&> reasonIfUnsupported = EmptyOptional()) const override;
79 
81  const TensorInfo& input,
82  const TensorInfo& output,
83  Optional<std::string&> reasonIfUnsupported = EmptyOptional()) const override;
84 
85  bool IsConvolution2dSupported(const TensorInfo& input,
86  const TensorInfo& output,
87  const Convolution2dDescriptor& descriptor,
88  const TensorInfo& weights,
89  const Optional<TensorInfo>& biases,
90  Optional<std::string&> reasonIfUnsupported = EmptyOptional()) const override;
91 
92  bool IsDebugSupported(const TensorInfo& input,
93  const TensorInfo& output,
94  Optional<std::string&> reasonIfUnsupported = EmptyOptional()) const override;
95 
96  bool IsDepthToSpaceSupported(const TensorInfo& input,
97  const TensorInfo& output,
98  const DepthToSpaceDescriptor& descriptor,
99  Optional<std::string&> reasonIfUnsupported = EmptyOptional()) const override;
100 
102  const TensorInfo& output,
103  const DepthwiseConvolution2dDescriptor& descriptor,
104  const TensorInfo& weights,
105  const Optional<TensorInfo>& biases,
106  Optional<std::string&> reasonIfUnsupported = EmptyOptional()) const override;
107 
108  bool IsDequantizeSupported(const TensorInfo& input,
109  const TensorInfo& output,
110  Optional<std::string&> reasonIfUnsupported = EmptyOptional()) const override;
111 
113  const TensorInfo& scores,
114  const TensorInfo& anchors,
115  const TensorInfo& detectionBoxes,
116  const TensorInfo& detectionClasses,
117  const TensorInfo& detectionScores,
118  const TensorInfo& numDetections,
119  const DetectionPostProcessDescriptor& descriptor,
120  Optional<std::string&> reasonIfUnsupported = EmptyOptional()) const override;
121 
123  const TensorInfo& output,
124  const DepthwiseConvolution2dDescriptor& descriptor,
125  const TensorInfo& weights,
126  const Optional<TensorInfo>& biases,
127  Optional<std::string&> reasonIfUnsupported =
128  EmptyOptional()) const override;
129 
130  bool IsDivisionSupported(const TensorInfo& input0,
131  const TensorInfo& input1,
132  const TensorInfo& output,
133  Optional<std::string&> reasonIfUnsupported = EmptyOptional()) const override;
134 
135  bool IsElementwiseUnarySupported(const TensorInfo& input,
136  const TensorInfo& output,
137  const ElementwiseUnaryDescriptor& descriptor,
138  Optional<std::string&> reasonIfUnsupported = EmptyOptional()) const override;
139 
140  ARMNN_DEPRECATED_MSG("Use IsComparisonSupported instead")
141  bool IsEqualSupported(const TensorInfo& input0,
142  const TensorInfo& input1,
143  const TensorInfo& output,
144  Optional<std::string&> reasonIfUnsupported = EmptyOptional()) const override;
145 
146  bool IsFakeQuantizationSupported(const TensorInfo& input,
147  const FakeQuantizationDescriptor& descriptor,
148  Optional<std::string&> reasonIfUnsupported = EmptyOptional()) const override;
149 
150  virtual bool IsFillSupported(const TensorInfo& input,
151  const TensorInfo& output,
152  const FillDescriptor& descriptor,
153  Optional<std::string&> reasonIfUnsupported = EmptyOptional()) const override;
154 
155  bool IsFloorSupported(const TensorInfo& input,
156  const TensorInfo& output,
157  Optional<std::string&> reasonIfUnsupported = EmptyOptional()) const override;
158 
159  bool IsFullyConnectedSupported(const TensorInfo& input,
160  const TensorInfo& output,
161  const TensorInfo& weights,
162  const TensorInfo& biases,
163  const FullyConnectedDescriptor& descriptor,
164  Optional<std::string&> reasonIfUnsupported = EmptyOptional()) const override;
165 
166  ARMNN_DEPRECATED_MSG("Use IsGatherSupported with descriptor instead")
167  bool IsGatherSupported(const TensorInfo& input0,
168  const TensorInfo& input1,
169  const TensorInfo& output,
170  Optional<std::string&> reasonIfUnsupported = EmptyOptional()) const override;
171 
172  bool IsGatherSupported(const TensorInfo& input0,
173  const TensorInfo& input1,
174  const TensorInfo& output,
175  const GatherDescriptor& descriptor,
176  Optional<std::string&> reasonIfUnsupported = EmptyOptional()) const override;
177 
178  ARMNN_DEPRECATED_MSG("Use IsComparisonSupported instead")
179  bool IsGreaterSupported(const TensorInfo& input0,
180  const TensorInfo& input1,
181  const TensorInfo& output,
182  Optional<std::string&> reasonIfUnsupported = EmptyOptional()) const override;
183 
184  bool IsInputSupported(const TensorInfo& input,
185  Optional<std::string&> reasonIfUnsupported = EmptyOptional()) const override;
186 
188  const TensorInfo& input,
189  const TensorInfo& output,
190  const InstanceNormalizationDescriptor& descriptor,
191  Optional<std::string&> reasonIfUnsupported = EmptyOptional()) const override;
192 
193  bool IsL2NormalizationSupported(const TensorInfo& input,
194  const TensorInfo& output,
195  const L2NormalizationDescriptor& descriptor,
196  Optional<std::string&> reasonIfUnsupported = EmptyOptional()) const override;
197 
198  bool IsLogicalBinarySupported(const TensorInfo& input0,
199  const TensorInfo& input1,
200  const TensorInfo& output,
201  const LogicalBinaryDescriptor& descriptor,
202  Optional<std::string&> reasonIfUnsupported = EmptyOptional()) const override;
203 
204  bool IsLogicalUnarySupported(const TensorInfo& input,
205  const TensorInfo& output,
206  const ElementwiseUnaryDescriptor& descriptor,
207  Optional<std::string&> reasonIfUnsupported = EmptyOptional()) const override;
208 
209  bool IsLogSoftmaxSupported(const TensorInfo& input,
210  const TensorInfo& output,
211  const LogSoftmaxDescriptor& descriptor,
212  Optional<std::string&> reasonIfUnsupported = EmptyOptional()) const override;
213 
214  bool IsLstmSupported(const TensorInfo& input,
215  const TensorInfo& outputStateIn,
216  const TensorInfo& cellStateIn,
217  const TensorInfo& scratchBuffer,
218  const TensorInfo& outputStateOut,
219  const TensorInfo& cellStateOut,
220  const TensorInfo& output,
221  const LstmDescriptor& descriptor,
222  const LstmInputParamsInfo& paramsInfo,
223  Optional<std::string&> reasonIfUnsupported = EmptyOptional()) const override;
224 
225  bool IsMaximumSupported(const TensorInfo& input0,
226  const TensorInfo& input1,
227  const TensorInfo& output,
228  Optional<std::string&> reasonIfUnsupported = EmptyOptional()) const override;
229 
230  bool IsMeanSupported(const TensorInfo& input,
231  const TensorInfo& output,
232  const MeanDescriptor& descriptor,
233  Optional<std::string&> reasonIfUnsupported = EmptyOptional()) const override;
234 
235  bool IsMemCopySupported(const TensorInfo& input,
236  const TensorInfo& output,
237  Optional<std::string&> reasonIfUnsupported = EmptyOptional()) const override;
238 
239  bool IsMemImportSupported(const TensorInfo& input,
240  const TensorInfo& output,
241  Optional<std::string&> reasonIfUnsupported = EmptyOptional()) const override;
242 
243  bool IsMergeSupported(const TensorInfo& input0,
244  const TensorInfo& input1,
245  const TensorInfo& output,
246  Optional<std::string&> reasonIfUnsupported = EmptyOptional()) const override;
247 
248  ARMNN_DEPRECATED_MSG("Use IsConcatSupported instead")
249  bool IsMergerSupported(const std::vector<const TensorInfo*> inputs,
250  const TensorInfo& output,
251  const OriginsDescriptor& descriptor,
252  Optional<std::string&> reasonIfUnsupported = EmptyOptional()) const override;
253 
254  bool IsMinimumSupported(const TensorInfo& input0,
255  const TensorInfo& input1,
256  const TensorInfo& output,
257  Optional<std::string&> reasonIfUnsupported = EmptyOptional()) const override;
258 
259  bool IsMultiplicationSupported(const TensorInfo& input0,
260  const TensorInfo& input1,
261  const TensorInfo& output,
262  Optional<std::string&> reasonIfUnsupported = EmptyOptional()) const override;
263 
264  bool IsNormalizationSupported(const TensorInfo& input,
265  const TensorInfo& output,
266  const NormalizationDescriptor& descriptor,
267  Optional<std::string&> reasonIfUnsupported = EmptyOptional()) const override;
268 
269  bool IsOutputSupported(const TensorInfo& output,
270  Optional<std::string&> reasonIfUnsupported = EmptyOptional()) const override;
271 
272  bool IsPadSupported(const TensorInfo& input,
273  const TensorInfo& output,
274  const PadDescriptor& descriptor,
275  Optional<std::string&> reasonIfUnsupported = EmptyOptional()) const override;
276 
277  bool IsPermuteSupported(const TensorInfo& input,
278  const TensorInfo& output,
279  const PermuteDescriptor& descriptor,
280  Optional<std::string&> reasonIfUnsupported = EmptyOptional()) const override;
281 
282  bool IsPooling2dSupported(const TensorInfo& input,
283  const TensorInfo& output,
284  const Pooling2dDescriptor& descriptor,
285  Optional<std::string&> reasonIfUnsupported = EmptyOptional()) const override;
286 
287  bool IsPreCompiledSupported(const TensorInfo& input,
288  const PreCompiledDescriptor& descriptor,
289  Optional<std::string&> reasonIfUnsupported = EmptyOptional()) const override;
290 
291  bool IsPreluSupported(const TensorInfo& input,
292  const TensorInfo& alpha,
293  const TensorInfo& output,
294  Optional<std::string &> reasonIfUnsupported) const override;
295 
296  bool IsQuantizeSupported(const TensorInfo& input,
297  const TensorInfo& output,
298  Optional<std::string&> reasonIfUnsupported = EmptyOptional()) const override;
299 
300  bool IsQLstmSupported(const TensorInfo& input,
301  const TensorInfo& previousOutputIn,
302  const TensorInfo& previousCellStateIn,
303  const TensorInfo& outputStateOut,
304  const TensorInfo& cellStateOut,
305  const TensorInfo& output,
306  const QLstmDescriptor& descriptor,
307  const LstmInputParamsInfo& paramsInfo,
308  Optional<std::string&> reasonIfUnsupported = EmptyOptional()) const override;
309 
310  bool IsQuantizedLstmSupported(const TensorInfo& input,
311  const TensorInfo& previousCellStateIn,
312  const TensorInfo& previousOutputIn,
313  const TensorInfo& cellStateOut,
314  const TensorInfo& output,
315  const QuantizedLstmInputParamsInfo& paramsInfo,
316  Optional<std::string&> reasonIfUnsupported = EmptyOptional()) const override;
317 
318  bool IsRankSupported(const TensorInfo& input,
319  const TensorInfo& output,
320  Optional<std::string&> reasonIfUnsupported) const override;
321 
322  bool IsReduceSupported(const TensorInfo& input,
323  const TensorInfo& output,
324  const ReduceDescriptor& descriptor,
325  Optional<std::string&> reasonIfUnsupported = EmptyOptional()) const override;
326 
327  bool IsReshapeSupported(const TensorInfo& input,
328  const TensorInfo& output,
329  const ReshapeDescriptor& descriptor,
330  Optional<std::string&> reasonIfUnsupported = EmptyOptional()) const override;
331 
332  bool IsResizeSupported(const TensorInfo& input,
333  const TensorInfo& output,
334  const ResizeDescriptor& descriptor,
335  Optional<std::string&> reasonIfUnsupported = EmptyOptional()) const override;
336 
337  ARMNN_DEPRECATED_MSG("Use IsResizeSupported instead")
338  bool IsResizeBilinearSupported(const TensorInfo& input,
339  const TensorInfo& output,
340  Optional<std::string&> reasonIfUnsupported = EmptyOptional()) const override;
341 
342  ARMNN_DEPRECATED_MSG("Use IsElementwiseUnarySupported instead")
343  bool IsRsqrtSupported(const TensorInfo& input,
344  const TensorInfo& output,
345  Optional<std::string&> reasonIfUnsupported = EmptyOptional()) const override;
346 
347  bool IsSliceSupported(const TensorInfo& input,
348  const TensorInfo& output,
349  const SliceDescriptor& descriptor,
350  Optional<std::string&> reasonIfUnsupported = EmptyOptional()) const override;
351 
352  bool IsSoftmaxSupported(const TensorInfo& input,
353  const TensorInfo& output,
354  const SoftmaxDescriptor& descriptor,
355  Optional<std::string&> reasonIfUnsupported = EmptyOptional()) const override;
356 
357  bool IsSpaceToBatchNdSupported(const TensorInfo& input,
358  const TensorInfo& output,
359  const SpaceToBatchNdDescriptor& descriptor,
360  Optional<std::string&> reasonIfUnsupported = EmptyOptional()) const override;
361 
362  bool IsSpaceToDepthSupported(const TensorInfo& input,
363  const TensorInfo& output,
364  const SpaceToDepthDescriptor& descriptor,
365  Optional<std::string&> reasonIfUnsupported = EmptyOptional()) const override;
366 
367  ARMNN_DEPRECATED_MSG("Use IsSplitterSupported with outputs instead")
368  bool IsSplitterSupported(const TensorInfo& input,
369  const ViewsDescriptor& descriptor,
370  Optional<std::string&> reasonIfUnsupported = EmptyOptional()) const override;
371 
372  bool IsSplitterSupported(const TensorInfo& input,
373  const std::vector<std::reference_wrapper<TensorInfo>>& outputs,
374  const ViewsDescriptor& descriptor,
375  Optional<std::string&> reasonIfUnsupported = EmptyOptional()) const override;
376 
377  bool IsStackSupported(const std::vector<const TensorInfo*>& inputs,
378  const TensorInfo& output,
379  const StackDescriptor& descriptor,
380  Optional<std::string&> reasonIfUnsupported = EmptyOptional()) const override;
381 
382  bool IsStandInSupported(const std::vector<const TensorInfo*>& inputs,
383  const std::vector<const TensorInfo*>& outputs,
384  const StandInDescriptor& descriptor,
385  Optional<std::string&> reasonIfUnsupported = EmptyOptional()) const override;
386 
387  bool IsStridedSliceSupported(const TensorInfo& input,
388  const TensorInfo& output,
389  const StridedSliceDescriptor& descriptor,
390  Optional<std::string&> reasonIfUnsupported = EmptyOptional()) const override;
391 
392  bool IsSubtractionSupported(const TensorInfo& input0,
393  const TensorInfo& input1,
394  const TensorInfo& output,
395  Optional<std::string&> reasonIfUnsupported = EmptyOptional()) const override;
396 
397  bool IsSwitchSupported(const TensorInfo& input0,
398  const TensorInfo& input1,
399  const TensorInfo& output0,
400  const TensorInfo& output1,
401  Optional<std::string&> reasonIfUnsupported = EmptyOptional()) const override;
402 
404  const TensorInfo& input,
405  const TensorInfo& output,
406  const TransposeConvolution2dDescriptor& descriptor,
407  const TensorInfo& weights,
408  const Optional<TensorInfo>& biases,
409  Optional<std::string&> reasonIfUnsupported = EmptyOptional()) const override;
410 
411  bool IsTransposeSupported(const TensorInfo& input,
412  const TensorInfo& output,
413  const TransposeDescriptor& descriptor,
414  Optional<std::string&> reasonIfUnsupported = EmptyOptional()) const override;
415 
416 };
417 
418 } // namespace armnn
bool IsEqualSupported(const TensorInfo &input0, const TensorInfo &input1, const TensorInfo &output, Optional< std::string &> reasonIfUnsupported=EmptyOptional()) const override
bool IsInputSupported(const TensorInfo &input, Optional< std::string &> reasonIfUnsupported=EmptyOptional()) const override
A ViewsDescriptor for the SplitterLayer.
bool IsQLstmSupported(const TensorInfo &input, const TensorInfo &previousOutputIn, const TensorInfo &previousCellStateIn, const TensorInfo &outputStateOut, const TensorInfo &cellStateOut, const TensorInfo &output, const QLstmDescriptor &descriptor, const LstmInputParamsInfo &paramsInfo, Optional< std::string &> reasonIfUnsupported=EmptyOptional()) const override
A TransposeConvolution2dDescriptor for the TransposeConvolution2dLayer.
bool IsPreluSupported(const TensorInfo &input, const TensorInfo &alpha, const TensorInfo &output, Optional< std::string &> reasonIfUnsupported) const override
A ReshapeDescriptor for the ReshapeLayer.
bool IsDetectionPostProcessSupported(const TensorInfo &boxEncodings, const TensorInfo &scores, const TensorInfo &anchors, const TensorInfo &detectionBoxes, const TensorInfo &detectionClasses, const TensorInfo &detectionScores, const TensorInfo &numDetections, const DetectionPostProcessDescriptor &descriptor, Optional< std::string &> reasonIfUnsupported=EmptyOptional()) const override
bool IsMemImportSupported(const TensorInfo &input, const TensorInfo &output, Optional< std::string &> reasonIfUnsupported=EmptyOptional()) const override
bool IsLogSoftmaxSupported(const TensorInfo &input, const TensorInfo &output, const LogSoftmaxDescriptor &descriptor, Optional< std::string &> reasonIfUnsupported=EmptyOptional()) const override
A ComparisonDescriptor for the ComparisonLayer.
Definition: Descriptors.hpp:78
bool IsTransposeSupported(const TensorInfo &input, const TensorInfo &output, const TransposeDescriptor &descriptor, Optional< std::string &> reasonIfUnsupported=EmptyOptional()) const override
bool IsCastSupported(const TensorInfo &input, const TensorInfo &output, Optional< std::string &> reasonIfUnsupported=EmptyOptional()) const override
bool IsQuantizeSupported(const TensorInfo &input, const TensorInfo &output, Optional< std::string &> reasonIfUnsupported=EmptyOptional()) const override
bool IsMultiplicationSupported(const TensorInfo &input0, const TensorInfo &input1, const TensorInfo &output, Optional< std::string &> reasonIfUnsupported=EmptyOptional()) const override
bool IsQuantizedLstmSupported(const TensorInfo &input, const TensorInfo &previousCellStateIn, const TensorInfo &previousOutputIn, const TensorInfo &cellStateOut, const TensorInfo &output, const QuantizedLstmInputParamsInfo &paramsInfo, Optional< std::string &> reasonIfUnsupported=EmptyOptional()) const override
bool IsLogicalBinarySupported(const TensorInfo &input0, const TensorInfo &input1, const TensorInfo &output, const LogicalBinaryDescriptor &descriptor, Optional< std::string &> reasonIfUnsupported=EmptyOptional()) const override
A Convolution2dDescriptor for the Convolution2dLayer.
bool IsAdditionSupported(const TensorInfo &input0, const TensorInfo &input1, const TensorInfo &output, Optional< std::string &> reasonIfUnsupported=EmptyOptional()) const override
bool IsDebugSupported(const TensorInfo &input, const TensorInfo &output, Optional< std::string &> reasonIfUnsupported=EmptyOptional()) const override
bool IsRsqrtSupported(const TensorInfo &input, const TensorInfo &output, Optional< std::string &> reasonIfUnsupported=EmptyOptional()) const override
bool IsActivationSupported(const TensorInfo &input, const TensorInfo &output, const ActivationDescriptor &descriptor, Optional< std::string &> reasonIfUnsupported=EmptyOptional()) const override
bool IsReduceSupported(const TensorInfo &input, const TensorInfo &output, const ReduceDescriptor &descriptor, Optional< std::string &> reasonIfUnsupported=EmptyOptional()) const override
bool IsMeanSupported(const TensorInfo &input, const TensorInfo &output, const MeanDescriptor &descriptor, Optional< std::string &> reasonIfUnsupported=EmptyOptional()) const override
bool IsArgMinMaxSupported(const TensorInfo &input, const TensorInfo &output, const ArgMinMaxDescriptor &descriptor, Optional< std::string &> reasonIfUnsupported=EmptyOptional()) const override
bool IsGatherSupported(const TensorInfo &input0, const TensorInfo &input1, const TensorInfo &output, Optional< std::string &> reasonIfUnsupported=EmptyOptional()) const override
A LogicalBinaryDescriptor for the LogicalBinaryLayer.
bool IsSpaceToBatchNdSupported(const TensorInfo &input, const TensorInfo &output, const SpaceToBatchNdDescriptor &descriptor, Optional< std::string &> reasonIfUnsupported=EmptyOptional()) const override
bool IsSoftmaxSupported(const TensorInfo &input, const TensorInfo &output, const SoftmaxDescriptor &descriptor, Optional< std::string &> reasonIfUnsupported=EmptyOptional()) const override
std::vector< float > boxEncodings({ 0.0f, 0.0f, 0.0f, 0.0f, 0.0f, 1.0f, 0.0f, 0.0f, 0.0f, -1.0f, 0.0f, 0.0f, 0.0f, 0.0f, 0.0f, 0.0f, 0.0f, 1.0f, 0.0f, 0.0f, 0.0f, 0.0f, 0.0f, 0.0f })
bool IsComparisonSupported(const TensorInfo &input0, const TensorInfo &input1, const TensorInfo &output, const ComparisonDescriptor &descriptor, Optional< std::string &> reasonIfUnsupported=EmptyOptional()) const override
Copyright (c) 2021 ARM Limited and Contributors.
bool IsStandInSupported(const std::vector< const TensorInfo *> &inputs, const std::vector< const TensorInfo *> &outputs, const StandInDescriptor &descriptor, Optional< std::string &> reasonIfUnsupported=EmptyOptional()) const override
bool IsDepthwiseConvolutionSupported(const TensorInfo &input, const TensorInfo &output, const DepthwiseConvolution2dDescriptor &descriptor, const TensorInfo &weights, const Optional< TensorInfo > &biases, Optional< std::string &> reasonIfUnsupported=EmptyOptional()) const override
bool IsL2NormalizationSupported(const TensorInfo &input, const TensorInfo &output, const L2NormalizationDescriptor &descriptor, Optional< std::string &> reasonIfUnsupported=EmptyOptional()) const override
A SpaceToDepthDescriptor for the SpaceToDepthLayer.
bool IsSliceSupported(const TensorInfo &input, const TensorInfo &output, const SliceDescriptor &descriptor, Optional< std::string &> reasonIfUnsupported=EmptyOptional()) const override
bool IsFakeQuantizationSupported(const TensorInfo &input, const FakeQuantizationDescriptor &descriptor, Optional< std::string &> reasonIfUnsupported=EmptyOptional()) const override
A BatchToSpaceNdDescriptor for the BatchToSpaceNdLayer.
virtual bool IsFillSupported(const TensorInfo &input, const TensorInfo &output, const FillDescriptor &descriptor, Optional< std::string &> reasonIfUnsupported=EmptyOptional()) const override
bool IsPreCompiledSupported(const TensorInfo &input, const PreCompiledDescriptor &descriptor, Optional< std::string &> reasonIfUnsupported=EmptyOptional()) const override
bool IsStridedSliceSupported(const TensorInfo &input, const TensorInfo &output, const StridedSliceDescriptor &descriptor, Optional< std::string &> reasonIfUnsupported=EmptyOptional()) const override
A ResizeDescriptor for the ResizeLayer.
A StackDescriptor for the StackLayer.
A PadDescriptor for the PadLayer.
bool IsSwitchSupported(const TensorInfo &input0, const TensorInfo &input1, const TensorInfo &output0, const TensorInfo &output1, Optional< std::string &> reasonIfUnsupported=EmptyOptional()) const override
bool IsMergerSupported(const std::vector< const TensorInfo *> inputs, const TensorInfo &output, const OriginsDescriptor &descriptor, Optional< std::string &> reasonIfUnsupported=EmptyOptional()) const override
bool IsAbsSupported(const TensorInfo &input, const TensorInfo &output, Optional< std::string &> reasonIfUnsupported=EmptyOptional()) const override
bool IsBatchToSpaceNdSupported(const TensorInfo &input, const TensorInfo &output, const BatchToSpaceNdDescriptor &descriptor, Optional< std::string &> reasonIfUnsupported=EmptyOptional()) const override
bool IsDivisionSupported(const TensorInfo &input0, const TensorInfo &input1, const TensorInfo &output, Optional< std::string &> reasonIfUnsupported=EmptyOptional()) const override
An LstmDescriptor for the LstmLayer.
A L2NormalizationDescriptor for the L2NormalizationLayer.
An ArgMinMaxDescriptor for ArgMinMaxLayer.
Definition: Descriptors.hpp:56
An OriginsDescriptor for the ConcatLayer.
A ReduceDescriptor for the REDUCE operators.
bool IsPermuteSupported(const TensorInfo &input, const TensorInfo &output, const PermuteDescriptor &descriptor, Optional< std::string &> reasonIfUnsupported=EmptyOptional()) const override
A FullyConnectedDescriptor for the FullyConnectedLayer.
bool IsLogicalUnarySupported(const TensorInfo &input, const TensorInfo &output, const ElementwiseUnaryDescriptor &descriptor, Optional< std::string &> reasonIfUnsupported=EmptyOptional()) const override
A FakeQuantizationDescriptor for the FakeQuantizationLayer.
bool IsConvertFp32ToFp16Supported(const TensorInfo &input, const TensorInfo &output, Optional< std::string &> reasonIfUnsupported=EmptyOptional()) const override
bool IsElementwiseUnarySupported(const TensorInfo &input, const TensorInfo &output, const ElementwiseUnaryDescriptor &descriptor, Optional< std::string &> reasonIfUnsupported=EmptyOptional()) const override
bool IsConvertFp16ToFp32Supported(const TensorInfo &input, const TensorInfo &output, Optional< std::string &> reasonIfUnsupported=EmptyOptional()) const override
A GatherDescriptor for the GatherLayer.
A StandInDescriptor for the StandIn layer.
bool IsReshapeSupported(const TensorInfo &input, const TensorInfo &output, const ReshapeDescriptor &descriptor, Optional< std::string &> reasonIfUnsupported=EmptyOptional()) const override
A QLstmDescriptor for the QLstmLayer.
bool IsMergeSupported(const TensorInfo &input0, const TensorInfo &input1, const TensorInfo &output, Optional< std::string &> reasonIfUnsupported=EmptyOptional()) const override
bool IsStackSupported(const std::vector< const TensorInfo *> &inputs, const TensorInfo &output, const StackDescriptor &descriptor, Optional< std::string &> reasonIfUnsupported=EmptyOptional()) const override
bool IsSpaceToDepthSupported(const TensorInfo &input, const TensorInfo &output, const SpaceToDepthDescriptor &descriptor, Optional< std::string &> reasonIfUnsupported=EmptyOptional()) const override
An ActivationDescriptor for the ActivationLayer.
Definition: Descriptors.hpp:25
bool IsMemCopySupported(const TensorInfo &input, const TensorInfo &output, Optional< std::string &> reasonIfUnsupported=EmptyOptional()) const override
bool IsInstanceNormalizationSupported(const TensorInfo &input, const TensorInfo &output, const InstanceNormalizationDescriptor &descriptor, Optional< std::string &> reasonIfUnsupported=EmptyOptional()) const override
A SliceDescriptor for the SliceLayer.
bool IsRankSupported(const TensorInfo &input, const TensorInfo &output, Optional< std::string &> reasonIfUnsupported) const override
bool IsTransposeConvolution2dSupported(const TensorInfo &input, const TensorInfo &output, const TransposeConvolution2dDescriptor &descriptor, const TensorInfo &weights, const Optional< TensorInfo > &biases, Optional< std::string &> reasonIfUnsupported=EmptyOptional()) const override
A SpaceToBatchNdDescriptor for the SpaceToBatchNdLayer.
bool IsPadSupported(const TensorInfo &input, const TensorInfo &output, const PadDescriptor &descriptor, Optional< std::string &> reasonIfUnsupported=EmptyOptional()) const override
bool IsMinimumSupported(const TensorInfo &input0, const TensorInfo &input1, const TensorInfo &output, Optional< std::string &> reasonIfUnsupported=EmptyOptional()) const override
bool IsConvertBf16ToFp32Supported(const TensorInfo &input, const TensorInfo &output, Optional< std::string &> reasonIfUnsupported=EmptyOptional()) const override
EmptyOptional is used to initialize the Optional class in case we want to have default value for an O...
Definition: Optional.hpp:32
bool IsSplitterSupported(const TensorInfo &input, const ViewsDescriptor &descriptor, Optional< std::string &> reasonIfUnsupported=EmptyOptional()) const override
A ElementwiseUnaryDescriptor for the ElementwiseUnaryLayer.
Definition: Descriptors.hpp:98
bool IsConvolution2dSupported(const TensorInfo &input, const TensorInfo &output, const Convolution2dDescriptor &descriptor, const TensorInfo &weights, const Optional< TensorInfo > &biases, Optional< std::string &> reasonIfUnsupported=EmptyOptional()) const override
std::vector< float > scores({ 0.0f, 0.9f, 0.8f, 0.0f, 0.75f, 0.72f, 0.0f, 0.6f, 0.5f, 0.0f, 0.93f, 0.95f, 0.0f, 0.5f, 0.4f, 0.0f, 0.3f, 0.2f })
bool IsSubtractionSupported(const TensorInfo &input0, const TensorInfo &input1, const TensorInfo &output, Optional< std::string &> reasonIfUnsupported=EmptyOptional()) const override
bool IsLstmSupported(const TensorInfo &input, const TensorInfo &outputStateIn, const TensorInfo &cellStateIn, const TensorInfo &scratchBuffer, const TensorInfo &outputStateOut, const TensorInfo &cellStateOut, const TensorInfo &output, const LstmDescriptor &descriptor, const LstmInputParamsInfo &paramsInfo, Optional< std::string &> reasonIfUnsupported=EmptyOptional()) const override
A MeanDescriptor for the MeanLayer.
bool IsFloorSupported(const TensorInfo &input, const TensorInfo &output, Optional< std::string &> reasonIfUnsupported=EmptyOptional()) const override
bool IsConstantSupported(const TensorInfo &output, Optional< std::string &> reasonIfUnsupported=EmptyOptional()) const override
bool IsNormalizationSupported(const TensorInfo &input, const TensorInfo &output, const NormalizationDescriptor &descriptor, Optional< std::string &> reasonIfUnsupported=EmptyOptional()) const override
A TransposeDescriptor for the TransposeLayer.
A StridedSliceDescriptor for the StridedSliceLayer.
bool IsFullyConnectedSupported(const TensorInfo &input, const TensorInfo &output, const TensorInfo &weights, const TensorInfo &biases, const FullyConnectedDescriptor &descriptor, Optional< std::string &> reasonIfUnsupported=EmptyOptional()) const override
bool IsOutputSupported(const TensorInfo &output, Optional< std::string &> reasonIfUnsupported=EmptyOptional()) const override
bool IsResizeSupported(const TensorInfo &input, const TensorInfo &output, const ResizeDescriptor &descriptor, Optional< std::string &> reasonIfUnsupported=EmptyOptional()) const override
bool IsPooling2dSupported(const TensorInfo &input, const TensorInfo &output, const Pooling2dDescriptor &descriptor, Optional< std::string &> reasonIfUnsupported=EmptyOptional()) const override
#define ARMNN_DEPRECATED_MSG(message)
Definition: Deprecated.hpp:43
A PreCompiledDescriptor for the PreCompiledLayer.
A Pooling2dDescriptor for the Pooling2dLayer.
A NormalizationDescriptor for the NormalizationLayer.
bool IsConvertFp32ToBf16Supported(const TensorInfo &input, const TensorInfo &output, Optional< std::string &> reasonIfUnsupported=EmptyOptional()) const override
bool IsMaximumSupported(const TensorInfo &input0, const TensorInfo &input1, const TensorInfo &output, Optional< std::string &> reasonIfUnsupported=EmptyOptional()) const override
An InstanceNormalizationDescriptor for InstanceNormalizationLayer.
bool IsDepthToSpaceSupported(const TensorInfo &input, const TensorInfo &output, const DepthToSpaceDescriptor &descriptor, Optional< std::string &> reasonIfUnsupported=EmptyOptional()) const override
A SoftmaxDescriptor for the SoftmaxLayer.
bool IsConcatSupported(const std::vector< const TensorInfo *> inputs, const TensorInfo &output, const OriginsDescriptor &descriptor, Optional< std::string &> reasonIfUnsupported=EmptyOptional()) const override
bool IsBatchNormalizationSupported(const TensorInfo &input, const TensorInfo &output, const TensorInfo &mean, const TensorInfo &var, const TensorInfo &beta, const TensorInfo &gamma, const BatchNormalizationDescriptor &descriptor, Optional< std::string &> reasonIfUnsupported=EmptyOptional()) const override
bool IsResizeBilinearSupported(const TensorInfo &input, const TensorInfo &output, Optional< std::string &> reasonIfUnsupported=EmptyOptional()) const override
bool IsGreaterSupported(const TensorInfo &input0, const TensorInfo &input1, const TensorInfo &output, Optional< std::string &> reasonIfUnsupported=EmptyOptional()) const override
A DepthwiseConvolution2dDescriptor for the DepthwiseConvolution2dLayer.
A FillDescriptor for the FillLayer.
A BatchNormalizationDescriptor for the BatchNormalizationLayer.
bool IsDequantizeSupported(const TensorInfo &input, const TensorInfo &output, Optional< std::string &> reasonIfUnsupported=EmptyOptional()) const override
A PermuteDescriptor for the PermuteLayer.
bool IsDilatedDepthwiseConvolutionSupported(const TensorInfo &input, const TensorInfo &output, const DepthwiseConvolution2dDescriptor &descriptor, const TensorInfo &weights, const Optional< TensorInfo > &biases, Optional< std::string &> reasonIfUnsupported=EmptyOptional()) const override
std::vector< float > anchors({ 0.5f, 0.5f, 1.0f, 1.0f, 0.5f, 0.5f, 1.0f, 1.0f, 0.5f, 0.5f, 1.0f, 1.0f, 0.5f, 10.5f, 1.0f, 1.0f, 0.5f, 10.5f, 1.0f, 1.0f, 0.5f, 100.5f, 1.0f, 1.0f })