Class AvgPoolFusion
Defined in File avg_pool_fusion.h
Inheritance Relationships
Base Type
public mindspore::ops::AvgPool
(Class AvgPool)
Class Documentation
-
class AvgPoolFusion : public mindspore::ops::AvgPool
AvgPoolFusion defined AvgPool operator prototype of lite.
Public Functions
-
inline AvgPoolFusion()
Constructor.
-
void Init(const std::vector<int64_t> &kernel_size = {1}, const std::vector<int64_t> &stride = {1}, const PadMode &pad_mode = VALID, const Format &format = NCHW, const std::vector<int64_t> &pad = {0, 0, 0, 0}, const RoundMode &round_mode = FLOOR, const bool global = false, const ActivationType activation_type = NO_ACTIVATION)
Method to init the op’s attributes.
- Parameters
kernel_size – [in] Define the size of the kernel.
stride – [in] Define the moving size of the kernel.
pad_mode – [in] Define the padding method.
format – [in] Define the format of input tensor.
pad – [in] Define the concrete padding value on each dimension
round_mode – [in] Define numerical operation mode of the output tensor.
global – [in] Define a boolean value to indicate whether to do global pooling. If true, kernel_size will be useless.
activation_type – [in] Define the activation type.
-
void set_global(const bool global)
Method to set global attribute.
- Parameters
global – [in] Define a boolean value to indicate whether to do global pooling. If true, kernel_size will be useless.
-
void set_activation_type(const ActivationType activation_type)
Method to set activation type.
- Parameters
activation_type – [in] Define the activation type.
-
bool get_global() const
Method to get global attribute.
- Returns
a boolean value to indicate whether to do global pooling. If true, kernel_size will be useless.
-
ActivationType get_activation_type() const
Method to get activation type.
- Returns
activation type.
-
inline AvgPoolFusion()