code: def _test_resize(self, scale, epsilonscale):
      im = self._test_image()
  
      size_up = int(round(im.width * scale)), int(
          round(im.height * scale)
      )
      matrix_up = [1 / scale, 0, 0, 0, 1 / scale, 0, 0, 0]
      matrix_down = [scale, 0, 0, 0, scale, 0, 0, 0]
  
      for resample, epsilon in [
          (Image.NEAREST, 0),
          (Image.BILINEAR, 2),
          (Image.BICUBIC, 1),
      ]:
          transformed = im.transform(
              size_up, self.transform, matrix_up, resample
          )
          transformed = transformed.transform(
              im.size, self.transform, matrix_down, resample
          )
          assert_image_similar(transformed, im, epsilon * epsilonscale)
  
imports: import math
  import pytest
  from PIL import Image, ImageTransform
  from .helper import assert_image_equal, assert_image_similar, hopper
label_desc: Use image node_id 7 for calling the TestImageTransformAffine obj's underlying member method code with example usage: obj._test_resize(scale, epsilonscale) without return types