1 // Copyright (C) 2018-2019 Intel Corporation
2 // SPDX-License-Identifier: Apache-2.0
7 #include <builders/ie_layer_decorator.hpp>
8 #include <ie_network.hpp>
12 namespace InferenceEngine {
16 * @brief The class represents a builder for PSROIPooling layer
18 class INFERENCE_ENGINE_API_CLASS(PSROIPoolingLayer): public LayerDecorator {
21 * @brief The constructor creates a builder with the name
22 * @param name Layer name
24 explicit PSROIPoolingLayer(const std::string& name = "");
26 * @brief The constructor creates a builder from generic builder
27 * @param layer pointer to generic builder
29 explicit PSROIPoolingLayer(const Layer::Ptr& layer);
31 * @brief The constructor creates a builder from generic builder
32 * @param layer constant pointer to generic builder
34 explicit PSROIPoolingLayer(const Layer::CPtr& layer);
36 * @brief Sets the name for the layer
37 * @param name Layer name
38 * @return reference to layer builder
40 PSROIPoolingLayer& setName(const std::string& name);
43 * @brief Returns input ports
44 * @return Vector of input ports
46 const std::vector<Port>& getInputPorts() const;
48 * @brief Sets input ports
49 * @param ports Vector of input ports
50 * @return reference to layer builder
52 PSROIPoolingLayer& setInputPorts(const std::vector<Port>& ports);
54 * @brief Returns output ports
55 * @return Vector of output ports
57 const Port& getOutputPort() const;
59 * @brief Sets output ports
60 * @param port Vector of output ports
61 * @return reference to layer builder
63 PSROIPoolingLayer& setOutputPort(const Port& port);
65 * @brief Returns multiplicative spatial scale factor to translate ROI coordinates
66 * @return Spatial scale factor
68 float getSpatialScale() const;
70 * @brief Sets multiplicative spatial scale factor to translate ROI coordinates
71 * @param spatialScale Spatial scale factor
72 * @return reference to layer builder
74 PSROIPoolingLayer& setSpatialScale(float spatialScale);
76 * @brief Returns pooled output channel number
77 * @return Output channel number
79 size_t getOutputDim() const;
81 * @brief Sets pooled output channel number
82 * @param outDim Output channel number
83 * @return reference to layer builder
85 PSROIPoolingLayer& setOutputDim(size_t outDim);
87 * @brief Returns number of groups to encode position-sensitive score maps
88 * @return Number of groups
90 size_t getGroupSize() const;
92 * @brief Sets number of groups to encode position-sensitive score maps
93 * @param size Number of groups
94 * @return reference to layer builder
96 PSROIPoolingLayer& setGroupSize(size_t size);
99 } // namespace Builder
100 } // namespace InferenceEngine