Help protect the Great Barrier Reef with TensorFlow on Kaggle

# tensorflow:: ops:: MaxPoolWithArgmax

``` #include <nn_ops.h> ```

Performs max pooling on the input and outputs both max values and indices.

## Summary

The indices in ``` argmax ``` are flattened, so that a maximum value at position ``` [b, y, x, c] ``` becomes flattened index: ``` (y * width + x) * channels + c ``` if ``` include_batch_in_index ``` is False; ``` ((b * height + y) * width + x) * channels + c ``` if ``` include_batch_in_index ``` is True.

The indices returned are always in ``` [0, height) x [0, width) ``` before flattening, even if padding is involved and the mathematically correct answer is outside (either negative or too large). This is a bug, but fixing it is difficult to do in a safe backwards compatible way, especially due to flattening.

Args:

• scope: A Scope object
• input: 4-D with shape ``` [batch, height, width, channels] ``` . Input to pool over.
• ksize: The size of the window for each dimension of the input tensor.
• strides: The stride of the sliding window for each dimension of the input tensor.

Optional attributes (see ``` Attrs ``` ):

• include_batch_in_index: Whether to include batch dimension in flattened index of ``` argmax ``` .

Returns:

• ``` Output ``` output: The max pooled output tensor.
• ``` Output ``` argmax: 4-D. The flattened indices of the max values chosen for each output.

### Constructors and Destructors

``` MaxPoolWithArgmax (const :: tensorflow::Scope & scope, :: tensorflow::Input input, const gtl::ArraySlice< int > & ksize, const gtl::ArraySlice< int > & strides, StringPiece padding) ```
``` MaxPoolWithArgmax (const :: tensorflow::Scope & scope, :: tensorflow::Input input, const gtl::ArraySlice< int > & ksize, const gtl::ArraySlice< int > & strides, StringPiece padding, const MaxPoolWithArgmax::Attrs & attrs) ```

### Public attributes

``` argmax ```
``` :: tensorflow::Output ```
``` operation ```
``` Operation ```
``` output ```
``` :: tensorflow::Output ```

### Public static functions

``` IncludeBatchInIndex (bool x) ```
``` Attrs ```
``` Targmax (DataType x) ```
``` Attrs ```

### Structs

tensorflow:: ops:: MaxPoolWithArgmax:: Attrs

Optional attribute setters for MaxPoolWithArgmax .

## Public attributes

### argmax

`::tensorflow::Output argmax`

### operation

`Operation operation`

### output

`::tensorflow::Output output`

## Public functions

### MaxPoolWithArgmax

``` MaxPoolWithArgmax(
const ::tensorflow::Scope & scope,
::tensorflow::Input input,
const gtl::ArraySlice< int > & ksize,
const gtl::ArraySlice< int > & strides,
)```

### MaxPoolWithArgmax

``` MaxPoolWithArgmax(
const ::tensorflow::Scope & scope,
::tensorflow::Input input,
const gtl::ArraySlice< int > & ksize,
const gtl::ArraySlice< int > & strides,
const MaxPoolWithArgmax::Attrs & attrs
)```

## Public static functions

### IncludeBatchInIndex

```Attrs IncludeBatchInIndex(
bool x
)```

### Targmax

```Attrs Targmax(
DataType x
)```
[{ "type": "thumb-down", "id": "missingTheInformationINeed", "label":"Missing the information I need" },{ "type": "thumb-down", "id": "tooComplicatedTooManySteps", "label":"Too complicated / too many steps" },{ "type": "thumb-down", "id": "outOfDate", "label":"Out of date" },{ "type": "thumb-down", "id": "samplesCodeIssue", "label":"Samples / code issue" },{ "type": "thumb-down", "id": "otherDown", "label":"Other" }]
[{ "type": "thumb-up", "id": "easyToUnderstand", "label":"Easy to understand" },{ "type": "thumb-up", "id": "solvedMyProblem", "label":"Solved my problem" },{ "type": "thumb-up", "id": "otherUp", "label":"Other" }]