code: def deconvolution_2d(
      x, W, b=None, stride=1, pad=0, outsize=None, **kwargs
  ):
      """deconvolution_2d(x, W, b=None, stride=1, pad=0, outsize=None, *, \
  dilate=1, groups=1)
  
      Two dimensional deconvolution function.
  
      This is an implementation of two-dimensional deconvolution. In most of deep
      learning frameworks and papers, this function is called
      **transposed convolution**. But because of historical reasons (e.g. paper
      by Ziller `Deconvolutional Networks`_) and backward compatibility, this
      function is called **deconvolution** in Chainer.
  
      .. _Deconvolutional Networks: \
  http://www.matthewzeiler.com/pubs/cvpr2010/cvpr2010.pdf
  
      It takes three variables: input image ``x``,
      the filter weight ``W``, and the bias vector ``b``.
  
      Notation: here is a notation for dimensionalities.
  
      - :math:`n` is the batch size.
      - :math:`c_I` and :math:`c_O` are the number of the input and output
        channels, respectively.
      - :math:`h_I` and :math:`w_I` are the height and width of the input image,
        respectively.
      - :math:`h_K` and :math:`w_K` are the height and width of the filters,
        respectively.
      - :math:`h_P` and :math:`w_P` are the height and width of the spatial
        padding size, respectively.
  
      Let :math:`(s_Y, s_X)` be the stride of filter application. Then, the
      output size :math:`(h_O, w_O)` is estimated by the following equations:
  
      .. math::
  
         h_O &= s_Y (h_I - 1) + h_K - 2h_P,\\\\
         w_O &= s_X (w_I - 1) + w_K - 2w_P.
  
      The output of this function can be non-deterministic when it uses cuDNN.
      If ``chainer.configuration.config.deterministic`` is ``True`` and
      cuDNN version is >= v3, it forces cuDNN to use a deterministic algorithm.
  
      Deconvolution links can use a feature of cuDNN called autotuning, which
      selects the most efficient CNN algorithm for images of fixed-size,
      can provide a significant performance boost for fixed neural nets.
      To enable, set `chainer.using_config('autotune', True)`
  
      Args:
          x (:class:`~chainer.Variable` or :ref:`ndarray`):
              Input variable of shape :math:`(n, c_I, h_I, w_I)`.
          W (:class:`~chainer.Variable` or :ref:`ndarray`):
              Weight variable of shape :math:`(c_I, c_O, h_K, w_K)`.
          b (None or :class:`~chainer.Variable` or :ref:`ndarray`):
              Bias variable of length :math:`c_O` (optional).
          stride (:class:`int` or pair of :class:`int` s):
              Stride of filter applications. ``stride=s`` and ``stride=(s, s)``
              are equivalent.
          pad (:class:`int` or pair of :class:`int` s):
              Spatial padding width for input arrays.
              ``pad=p`` and ``pad=(p, p)`` are equivalent.
          outsize (None or :class:`tuple` of :class:`int` s):
              Expected output size of deconvolutional operation.
              It should be pair of height and width :math:`(h_O, w_O)`.
              Default value is ``None`` and the outsize is estimated by
              input size, stride and pad.
          dilate (:class:`int` or pair of :class:`int` s):
              Dilation factor of filter applications.
              ``dilate=d`` and ``dilate=(d, d)`` are equivalent.
          groups (:class:`int`):
              The number of groups to use grouped deconvolution.
              The default is one, where grouped deconvolution is not used.
  
      Returns:
          ~chainer.Variable:
              Output variable of shape :math:`(n, c_O, h_O, w_O)`.
  
      .. seealso::
  
          :class:`~chainer.links.Deconvolution2D` to manage the model parameters
          ``W`` and ``b``.
  
      .. admonition:: Example
  
          >>> n = 10
          >>> c_i, c_o = 1, 3
          >>> h_i, w_i = 5, 10
          >>> h_k, w_k = 10, 10
          >>> h_p, w_p = 5, 5
          >>> x = np.random.uniform(0, 1, (n, c_i, h_i, w_i)).astype(np.float32)
          >>> x.shape
          (10, 1, 5, 10)
          >>> W = np.random.uniform(0, 1, (c_i, c_o, h_k, w_k)).\
  astype(np.float32)
          >>> W.shape
          (1, 3, 10, 10)
          >>> b = np.random.uniform(0, 1, c_o).astype(np.float32)
          >>> b.shape
          (3,)
          >>> s_y, s_x = 5, 5
          >>> y = F.deconvolution_2d(x, W, b, stride=(s_y, s_x), pad=(h_p, w_p))
          >>> y.shape
          (10, 3, 20, 45)
          >>> h_o = s_y * (h_i - 1) + h_k - 2 * h_p
          >>> w_o = s_x * (w_i - 1) + w_k - 2 * w_p
          >>> y.shape == (n, c_o, h_o, w_o)
          True
  
  
      """
      argument.check_unexpected_kwargs(
          kwargs,
          deterministic="deterministic argument is not "
          "supported anymore. "
          "Use chainer.using_config('cudnn_deterministic', value) "
          "context where value is either `True` or `False`.",
      )
      dilate, groups = argument.parse_kwargs(
          kwargs, ("dilate", 1), ("groups", 1)
      )
  
      func = Deconvolution2DFunction(
          stride, pad, outsize, dilate=dilate, groups=groups
      )
      if b is None:
          args = x, W
      else:
          args = x, W, b
      (y,) = func.apply(args)
      return y
  
imports: import numpy
  import chainer
  from chainer.backends import cuda
  from chainer.backends import intel64
  from chainer import configuration
  from chainer import function_node
  import chainer.functions
  from chainer.functions.connection import convolution_2d
  from chainer import memory_layouts
  from chainer.utils import argument
  from chainer.utils import conv
  from chainer.utils import type_check
  import chainerx
label_desc: Use image node_id 2 for calling a global function with example usage: deconvolution_2d(x, W, b, stride, pad, outsize) and returns: y