ie_mvn_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 
11 namespace InferenceEngine {
12 namespace Builder {
13 
14 /**
15  * @deprecated Use ngraph API instead.
16  * @brief The class represents a builder for MVN layer
17  */
18 IE_SUPPRESS_DEPRECATED_START
19 class INFERENCE_ENGINE_NN_BUILDER_API_CLASS(MVNLayer): public LayerDecorator {
20 public:
21  /**
22  * @brief The constructor creates a builder with the name
23  * @param name Layer name
24  */
25  explicit MVNLayer(const std::string& name = "");
26  /**
27  * @brief The constructor creates a builder from generic builder
28  * @param layer pointer to generic builder
29  */
30  explicit MVNLayer(const Layer::Ptr& layer);
31  /**
32  * @brief The constructor creates a builder from generic builder
33  * @param layer constant pointer to generic builder
34  */
35  explicit MVNLayer(const Layer::CPtr& layer);
36  /**
37  * @brief Sets the name for the layer
38  * @param name Layer name
39  * @return reference to layer builder
40  */
41  MVNLayer& setName(const std::string& name);
42 
43  /**
44  * @brief Returns port with shapes for the layer
45  * @return Port with shapes
46  */
47  const Port& getPort() const;
48  /**
49  * @brief Sets port shapes for the layer
50  * @param port Port with shapes
51  * @return reference to layer builder
52  */
53  MVNLayer& setPort(const Port& port);
54  /**
55  * @brief Returns across channels value
56  * @return true if mean values are shared across channels
57  */
58  bool getAcrossChannels() const;
59  /**
60  * @brief Sets across channels
61  * @param flag true if mean values are shared across channels
62  * @return reference to layer builder
63  */
64  MVNLayer& setAcrossChannels(bool flag);
65  /**
66  * @brief Returns normalize variance
67  * @return true if variance normalization is performed
68  */
69  bool getNormalize() const;
70  /**
71  * @brief Sets normalize variance
72  * @param flag true if variance normalization is performed
73  * @return reference to layer builder
74  */
75  MVNLayer& setNormalize(bool flag);
76  /**
77  * @brief Return epsilon
78  * @return Epsilon
79  */
80  float getEpsilon() const;
81  /**
82  * @brief Sets epsilon
83  * @param eps Epsilon
84  * @return reference to layer builder
85  */
86  MVNLayer& setEpsilon(float eps);
87 };
88 IE_SUPPRESS_DEPRECATED_END
89 
90 } // namespace Builder
91 } // namespace InferenceEngine
Inference Engine API.
Definition: ie_argmax_layer.hpp:11