ie_convolution_layer.hpp
1 // Copyright (C) 2018-2019 Intel Corporation
2 // SPDX-License-Identifier: Apache-2.0
3 //
4 
5 #pragma once
6 
7 #include <builders/ie_layer_decorator.hpp>
8 #include <ie_network.hpp>
9 #include <string>
10 #include <vector>
11 
12 namespace InferenceEngine {
13 namespace Builder {
14 
15 /**
16  * @deprecated Use ngraph API instead.
17  * @brief The class represents a builder for ArgMax layer
18  */
19 IE_SUPPRESS_DEPRECATED_START
20 class INFERENCE_ENGINE_NN_BUILDER_API_CLASS(ConvolutionLayer): public LayerDecorator {
21 public:
22  /**
23  * @brief The constructor creates a builder with the name
24  * @param name Layer name
25  */
26  explicit ConvolutionLayer(const std::string& name = "");
27  /**
28  * @brief The constructor creates a builder from generic builder
29  * @param layer pointer to generic builder
30  */
31  explicit ConvolutionLayer(const Layer::Ptr& layer);
32  /**
33  * @brief The constructor creates a builder from generic builder
34  * @param layer constant pointer to generic builder
35  */
36  explicit ConvolutionLayer(const Layer::CPtr& layer);
37  /**
38  * @brief Sets the name for the layer
39  * @param name Layer name
40  * @return reference to layer builder
41  */
42  ConvolutionLayer& setName(const std::string& name);
43 
44  /**
45  * @brief Returns input port
46  * @return Input port
47  */
48  const Port& getInputPort() const;
49  /**
50  * @brief Sets input port
51  * @param port Input port
52  * @return reference to layer builder
53  */
54  ConvolutionLayer& setInputPort(const Port& port);
55  /**
56  * @brief Returns output port
57  * @return Output port
58  */
59  const Port& getOutputPort() const;
60  /**
61  * @brief Sets output port
62  * @param port Output port
63  * @return reference to layer builder
64  */
65  ConvolutionLayer& setOutputPort(const Port& port);
66  /**
67  * @brief Returns kernel size
68  * @return Kernel size
69  */
70  const std::vector<size_t> getKernel() const;
71  /**
72  * @brief Sets kernel size
73  * @param kernel Kernel size
74  * @return reference to layer builder
75  */
76  ConvolutionLayer& setKernel(const std::vector<size_t>& kernel);
77  /**
78  * @brief Returns vector of strides
79  * @return vector of strides
80  */
81  const std::vector<size_t> getStrides() const;
82  /**
83  * @brief Sets strides
84  * @param strides vector of strides
85  * @return reference to layer builder
86  */
87  ConvolutionLayer& setStrides(const std::vector<size_t>& strides);
88  /**
89  * @brief Returns dilations
90  * @return vector of dilations
91  */
92  const std::vector<size_t> getDilation() const;
93  /**
94  * @brief Sets dilations
95  * @param dilation Vector of dilations
96  * @return reference to layer builder
97  */
98  ConvolutionLayer& setDilation(const std::vector<size_t>& dilation);
99  /**
100  * @brief Returns begin paddings
101  * @return vector of paddings
102  */
103  const std::vector<size_t> getPaddingsBegin() const;
104  /**
105  * @brief Sets begin paddings
106  * @param paddings Vector of paddings
107  * @return reference to layer builder
108  */
109  ConvolutionLayer& setPaddingsBegin(const std::vector<size_t>& paddings);
110  /**
111  * @brief Return end paddings
112  * @return Vector of paddings
113  */
114  const std::vector<size_t> getPaddingsEnd() const;
115  /**
116  * @brief Sets end paddings
117  * @param paddings Vector of paddings
118  * @return reference to layer builder
119  */
120  ConvolutionLayer& setPaddingsEnd(const std::vector<size_t>& paddings);
121  /**
122  * @brief Returns group
123  * @return Group
124  */
125  size_t getGroup() const;
126  /**
127  * @brief Sets group
128  * @param group Group
129  * @return reference to layer builder
130  */
131  ConvolutionLayer& setGroup(size_t group);
132  /**
133  * @brief Return output depth
134  * @return Output depth
135  */
136  size_t getOutDepth() const;
137  /**
138  * @brief Sets output depth
139  * @param outDepth Output depth
140  * @return reference to layer builder
141  */
142  ConvolutionLayer& setOutDepth(size_t outDepth);
143 };
144 IE_SUPPRESS_DEPRECATED_END
145 
146 } // namespace Builder
147 } // namespace InferenceEngine
Inference Engine API.
Definition: ie_argmax_layer.hpp:11