code: def check_forward(self, x_data):
      x = chainer.Variable(x_data)
      y = functions.unpooling_2d(
          x, self.ksize, outsize=self.outsize, pad=self.pad
      )
      self.assertEqual(y.data.dtype, self.dtype)
      y_data = cuda.to_cpu(y.data)
  
      self.assertEqual(self.gy.shape, y_data.shape)
      for i in six.moves.range(self.N):
          for c in six.moves.range(self.n_channels):
              outsize = self.outsize or self.expected_outsize
              assert y_data.shape[2:] == outsize
              if outsize == (4, 2):
                  expect = numpy.array(
                      [
                          [self.x[i, c, 0, 0], self.x[i, c, 0, 0]],
                          [self.x[i, c, 0, 0], self.x[i, c, 0, 0]],
                          [self.x[i, c, 1, 0], self.x[i, c, 1, 0]],
                          [self.x[i, c, 1, 0], self.x[i, c, 1, 0]],
                      ]
                  )
              elif outsize == (4, 6):
                  expect = numpy.array(
                      [
                          [
                              self.x[i, c, 1, 1],
                              self.x[i, c, 1, 1],
                              self.x[i, c, 1, 2],
                              self.x[i, c, 1, 2],
                              self.x[i, c, 1, 3],
                              self.x[i, c, 1, 3],
                          ],
                          [
                              self.x[i, c, 1, 1],
                              self.x[i, c, 1, 1],
                              self.x[i, c, 1, 2],
                              self.x[i, c, 1, 2],
                              self.x[i, c, 1, 3],
                              self.x[i, c, 1, 3],
                          ],
                          [
                              self.x[i, c, 2, 1],
                              self.x[i, c, 2, 1],
                              self.x[i, c, 2, 2],
                              self.x[i, c, 2, 2],
                              self.x[i, c, 2, 3],
                              self.x[i, c, 2, 3],
                          ],
                          [
                              self.x[i, c, 2, 1],
                              self.x[i, c, 2, 1],
                              self.x[i, c, 2, 2],
                              self.x[i, c, 2, 2],
                              self.x[i, c, 2, 3],
                              self.x[i, c, 2, 3],
                          ],
                      ]
                  )
              else:
                  raise ValueError(
                      "Unsupported outsize: {}".format(outsize)
                  )
              testing.assert_allclose(expect, y_data[i, c])
  
imports: import unittest
  import numpy
  import six
  import chainer
  from chainer.backends import cuda
  from chainer import functions
  from chainer import gradient_check
  from chainer import testing
  from chainer.testing import attr
  from chainer_tests.functions_tests.pooling_tests import pooling_nd_helper
label_desc: Use image node_id 2 for calling the TestIntegerScaleUnpooling2D obj's underlying member method code with example usage: obj.check_forward(x_data) without return types