code: def test_center_crop_image(self):
      feature_extractor = ImageFeatureExtractionMixin()
      image = get_random_image(16, 32)
  
      # Test various crop sizes: bigger on all dimensions, on one of the dimensions only and on both dimensions.
      crop_sizes = [8, (8, 64), 20, (32, 64)]
      for size in crop_sizes:
          cropped_image = feature_extractor.center_crop(image, size)
          self.assertTrue(isinstance(cropped_image, PIL.Image.Image))
  
          # PIL Image.size is transposed compared to NumPy or PyTorch (width first instead of height first).
          expected_size = (
              (size, size)
              if isinstance(size, int)
              else (size[1], size[0])
          )
          self.assertEqual(cropped_image.size, expected_size)
  
imports: import os
  import tempfile
  import unittest
  import datasets
  import numpy
  import pytest
  from huggingface_hub.file_download import http_get
  from requests import ConnectTimeout, ReadTimeout
  from tests.pipelines.test_pipelines_document_question_answering import INVOICE_URL
  from transformers import is_torch_available, is_vision_available
  from transformers.image_utils import ChannelDimension, get_channel_dimension_axis, make_list_of_images
  from transformers.testing_utils import is_flaky, require_torch, require_vision
label_desc: Use image node_id 15 for calling the ImageFeatureExtractionTester obj's underlying member method code with example usage: obj.test_center_crop_image() without return types