|
|
|
@ -915,7 +915,7 @@ class MaxPool(_Pool):
|
|
|
|
|
Tensor, with shape :math:`(N, C_{out}, H_{out}, W_{out})`.
|
|
|
|
|
|
|
|
|
|
Examples:
|
|
|
|
|
>>> input_tensor = Tensor(np.arange(1*3*3*4).reshape((1,3,3,4)),mindspore.float32)
|
|
|
|
|
>>> input_tensor = Tensor(np.arange(1 * 3 * 3 * 4).reshape((1, 3, 3, 4)), mindspore.float32)
|
|
|
|
|
>>> maxpool_op = P.MaxPool(padding="VALID", ksize=2, strides=1)
|
|
|
|
|
>>> output_tensor = maxpool_op(input_tensor)
|
|
|
|
|
"""
|
|
|
|
@ -966,7 +966,7 @@ class MaxPoolWithArgmax(_Pool):
|
|
|
|
|
- **mask** (Tensor) - Max values' index represented by the mask.
|
|
|
|
|
|
|
|
|
|
Examples:
|
|
|
|
|
>>> input_tensor = Tensor(np.arange(1*3*3*4).reshape((1,3,3,4)),mindspore.float32)
|
|
|
|
|
>>> input_tensor = Tensor(np.arange(1 * 3 * 3 * 4).reshape((1, 3, 3, 4)), mindspore.float32)
|
|
|
|
|
>>> maxpool_arg_op = P.MaxPoolWithArgmax(padding="VALID", ksize=2, strides=1)
|
|
|
|
|
>>> output_tensor, argmax = maxpool_arg_op(input_tensor)
|
|
|
|
|
"""
|
|
|
|
|