Input Layer */
| 46 | { |
| 47 | /** Input Layer */ |
| 48 | class InputLayer final : public ILayer |
| 49 | { |
| 50 | public: |
| 51 | /** Construct an input layer. |
| 52 | * |
| 53 | * @param[in] desc Description of input tensor. |
| 54 | * @param[in] accessor Accessor to get input tensor data from. |
| 55 | */ |
| 56 | InputLayer(TensorDescriptor desc, ITensorAccessorUPtr accessor) : _desc(desc), _accessor(std::move(accessor)) |
| 57 | { |
| 58 | } |
| 59 | |
| 60 | NodeID create_layer(IStream &s) override |
| 61 | { |
| 62 | NodeParams common_params = {name(), s.hints().target_hint}; |
| 63 | return GraphBuilder::add_input_node(s.graph(), common_params, _desc, std::move(_accessor)); |
| 64 | } |
| 65 | |
| 66 | private: |
| 67 | TensorDescriptor _desc; |
| 68 | ITensorAccessorUPtr _accessor; |
| 69 | }; |
| 70 | |
| 71 | /** Constant Layer */ |
| 72 | class ConstantLayer final : public ILayer |
no outgoing calls
no test coverage detected