AveragePool - 1 vs 7

Files changed (1) hide show
  1. AveragePool1 → AveragePool7 +4 -1
AveragePool1 → AveragePool7 RENAMED
@@ -1 +1 @@
1
1
  AveragePool consumes an input tensor X and applies average pooling across
2
2
  the tensor according to kernel sizes, stride sizes, and pad lengths.
3
3
  average pooling consisting of computing the average on all values of a
4
4
  subset of the input tensor according to the kernel size and downsampling the
5
5
  data into the output tensor Y for further processing. The output spatial shape will be following:
6
6
  ::
7
7
  output_spatial_shape[i] = floor((input_spatial_shape[i] + pad_shape[i] - kernel_spatial_shape[i]) / strides_spatial_shape[i] + 1)
8
8
  * pad_shape[i] is sum of pads along axis i
9
9
  auto_pad is a DEPRECATED attribute. If you are using them currently, the output spatial shape will be following:
10
10
  ::
11
11
  VALID: output_spatial_shape[i] = ceil((input_spatial_shape[i] - kernel_spatial_shape[i] + 1) / strides_spatial_shape[i])
12
12
  SAME_UPPER or SAME_LOWER: output_spatial_shape[i] = ceil(input_spatial_shape[i] / strides_spatial_shape[i])
13
13
  And pad shape will be following if SAME_UPPER or SAME_LOWER:
14
14
  ::
15
15
  pad_shape[i] = (output_spatial_shape[i] - 1) * strides_spatial_shape[i] + kernel_spatial_shape[i] - input_spatial_shape[i]
16
- The output of each pooling window is divided by the number of elements exclude pad.
16
+ The output of each pooling window is divided by the number of elements (exclude pad when attribute count_include_pad is zero).
17
17
  **Attributes**
18
18
  * **auto_pad**:
19
19
  auto_pad must be either NOTSET, SAME_UPPER, SAME_LOWER or VALID.
20
20
  Where default value is NOTSET, which means explicit padding is used.
21
21
  SAME_UPPER or SAME_LOWER mean pad the input so that the output
22
22
  spatial size match the input.In case of odd number add the extra
23
23
  padding at the end for SAME_UPPER and at the beginning for
24
24
  SAME_LOWER. VALID mean no padding.
25
+ * **count_include_pad**:
26
+ Whether include pad pixels when calculating values for the edges.
27
+ Default is 0, doesn't count include pad.
25
28
  * **kernel_shape** (required):
26
29
  The size of the kernel along each axis.
27
30
  * **pads**:
28
31
  Padding for the beginning and ending along each spatial axis, it can
29
32
  take any value greater than or equal to 0. The value represent the
30
33
  number of pixels added to the beginning and end part of the
31
34
  corresponding axis. pads format should be as follow [x1_begin,
32
35
  x2_begin...x1_end, x2_end,...], where xi_begin the number of pixels
33
36
  added at the beginning of axis i and xi_end, the number of pixels
34
37
  added at the end of axis i. This attribute cannot be used
35
38
  simultaneously with auto_pad attribute. If not present, the padding
36
39
  defaults to 0 along start and end of each spatial axis.
37
40
  * **strides**:
38
41
  Stride along each spatial axis.
39
42
  **Inputs**
40
43
  * **X** (heterogeneous) - **T**:
41
44
  Input data tensor from the previous operator; dimensions for image
42
45
  case are (N x C x H x W), where N is the batch size, C is the number
43
46
  of channels, and H and W are the height and the width of the data.
44
47
  For non image case, the dimensions are in the form of (N x C x D1 x
45
48
  D2 ... Dn), where N is the batch size. Optionally, if dimension
46
49
  denotation is in effect, the operation expects the input data tensor
47
50
  to arrive with the dimension denotation of [DATA_BATCH,
48
51
  DATA_CHANNEL, DATA_FEATURE, DATA_FEATURE ...].
49
52
  **Outputs**
50
53
  * **Y** (heterogeneous) - **T**:
51
54
  Output data tensor from average or max pooling across the input
52
55
  tensor. Dimensions will vary based on various kernel, stride, and
53
56
  pad sizes. Floor value of the dimension is used
54
57
  **Type Constraints**
55
58
  * **T** in (
56
59
  tensor(double),
57
60
  tensor(float),
58
61
  tensor(float16)
59
62
  ):
60
63
  Constrain input and output types to float tensors.