code: def adaptive_max_pool2d(
      input: paddle.Tensor, output_size: Union[Sequence[int], int]
  ) -> paddle.Tensor:
      squeeze = input.ndim == 3
      x = paddle.unsqueeze(input, axis=0) if squeeze else input
      ret = paddle.nn.functional.adaptive_max_pool2d(x, output_size)
      return paddle.squeeze(ret, axis=0) if squeeze else ret
  
imports: from typing import Optional, Union, Tuple, List, Literal, Sequence, Callable
  import paddle
  from ivy.functional.ivy.layers import _handle_padding, _depth_max_pooling_helper, _validate_max_pool_params
  from ivy.utils.exceptions import IvyNotImplementedException, IvyValueError
  from ivy.func_wrapper import with_supported_device_and_dtypes, with_unsupported_dtypes, with_supported_dtypes
  from ..None import backend_version
  import ivy
label_desc: Use image node_id 16 for calling a global function with example usage: adaptive_max_pool2d(input, output_size) and returns: unknown