David Beck | e97c6e0 | 2018-10-03 13:09:28 +0100 | [diff] [blame] | 1 | // |
Teresa Charlin | 5266473 | 2020-06-29 16:27:03 +0100 | [diff] [blame] | 2 | // Copyright © 2017 Arm Ltd and Contributors. All rights reserved. |
David Beck | e97c6e0 | 2018-10-03 13:09:28 +0100 | [diff] [blame] | 3 | // SPDX-License-Identifier: MIT |
| 4 | // |
| 5 | #pragma once |
| 6 | |
Jim Flynn | 906f946 | 2019-05-10 13:55:21 +0100 | [diff] [blame] | 7 | #include <armnn/Deprecated.hpp> |
Cathal Corbett | 34b429c | 2021-12-24 12:24:40 +0000 | [diff] [blame] | 8 | #include <armnn/Descriptors.hpp> |
Jan Eilers | d01a83c | 2019-07-03 18:20:40 +0100 | [diff] [blame] | 9 | #include <armnn/LstmParams.hpp> |
James Conroy | ee18dc8 | 2019-07-17 11:27:46 +0100 | [diff] [blame] | 10 | #include <armnn/Optional.hpp> |
| 11 | #include <armnn/QuantizedLstmParams.hpp> |
Matthew Bentham | 313e1c8 | 2019-03-25 17:37:47 +0000 | [diff] [blame] | 12 | |
David Beck | 5eec11d | 2018-10-04 15:43:17 +0100 | [diff] [blame] | 13 | #include <cctype> |
Narumol Prangnawarat | 15eb583 | 2019-05-20 15:31:05 +0100 | [diff] [blame] | 14 | #include <functional> |
David Beck | 3e9e115 | 2018-10-17 14:17:50 +0100 | [diff] [blame] | 15 | #include <memory> |
Matthew Bentham | 313e1c8 | 2019-03-25 17:37:47 +0000 | [diff] [blame] | 16 | #include <vector> |
David Beck | e97c6e0 | 2018-10-03 13:09:28 +0100 | [diff] [blame] | 17 | |
| 18 | namespace armnn |
| 19 | { |
| 20 | |
| 21 | class TensorInfo; |
| 22 | |
| 23 | class ILayerSupport |
| 24 | { |
| 25 | protected: |
| 26 | ILayerSupport() {} |
| 27 | virtual ~ILayerSupport() {} |
| 28 | |
| 29 | public: |
Cathal Corbett | 34b429c | 2021-12-24 12:24:40 +0000 | [diff] [blame] | 30 | virtual bool IsLayerSupported(const LayerType& type, |
| 31 | const std::vector<TensorInfo>& infos, |
| 32 | const BaseDescriptor& descriptor, |
| 33 | const Optional<LstmInputParamsInfo>& lstmParamsInfo = EmptyOptional(), |
| 34 | const Optional<QuantizedLstmInputParamsInfo>& quantizedLstmParamsInfo = |
| 35 | EmptyOptional(), |
| 36 | Optional<std::string&> reasonIfUnsupported = EmptyOptional()) const; |
| 37 | |
David Beck | e97c6e0 | 2018-10-03 13:09:28 +0100 | [diff] [blame] | 38 | }; // class ILayerSupport |
| 39 | |
David Beck | 3e9e115 | 2018-10-17 14:17:50 +0100 | [diff] [blame] | 40 | using ILayerSupportSharedPtr = std::shared_ptr<ILayerSupport>; |
| 41 | |
David Beck | e97c6e0 | 2018-10-03 13:09:28 +0100 | [diff] [blame] | 42 | } // namespace armnn |