---
title: "maxPool2dWithIndices"
sidebar_label: "maxPool2dWithIndices"
description: "Kotlin binding reference: maxPool2dWithIndices."
---

<!-- Generated by tools/api_reference/generate_api_docs.py. Do not edit. -->

//[clika-runtime](../../../index.md)/[io.clika.runtime](../index.md)/[Ops](index.md)/[maxPool2dWithIndices](maxPool2dWithIndices.md)

# maxPool2dWithIndices

[common]\
fun [maxPool2dWithIndices](maxPool2dWithIndices.md)(input: [Tensor](../Tensor/index.md), kernelSize: [LongArray](https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-long-array/index.html), stride: [LongArray](https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-long-array/index.html) = longArrayOf(), padding: [LongArray](https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-long-array/index.html) = longArrayOf(0, 0), dilation: [LongArray](https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-long-array/index.html) = longArrayOf(1, 1), ceilMode: [Boolean](https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-boolean/index.html) = false): [List](https://kotlinlang.org/api/core/kotlin-stdlib/kotlin.collections/-list/index.html)&lt;[Tensor](../Tensor/index.md)&gt;

`maxPool2dWithIndices(input: Tensor, kernelSize: LongArray, stride: LongArray = longArrayOf(), padding: LongArray = longArrayOf(0, 0), dilation: LongArray = longArrayOf(1, 1), ceilMode: Boolean = false)`: the `max_pool2d_with_indices` operator.