proc maxpool2d[T](input: Tensor[T]; kernel: Size2D; padding: Size2D = (0, 0); stride: Size2D = (1, 1)): tuple[max_indices: Tensor[int], maxpooled: Tensor[T]] {.noinit.}
proc maxpool2d_backward[T](cached_input_shape: openArray[int] | Metadata; cached_max_indices: Tensor[int]; gradOutput: Tensor[T]): Tensor[T] {.noinit.}