code: def create_and_check_for_image_segmentation(
      self, config, pixel_values, labels
  ):
      config.num_labels = self.num_labels
      model = TFSegformerForSemanticSegmentation(config)
      result = model(pixel_values, training=False)
      self.parent.assertEqual(
          result.logits.shape,
          (
              self.batch_size,
              self.num_labels,
              self.image_size // 4,
              self.image_size // 4,
          ),
      )
      result = model(pixel_values, labels=labels, training=False)
      self.parent.assertEqual(
          result.logits.shape,
          (
              self.batch_size,
              self.num_labels,
              self.image_size // 4,
              self.image_size // 4,
          ),
      )
  
imports: import inspect
  import unittest
  from typing import List, Tuple
  from transformers import SegformerConfig
  from transformers.file_utils import is_tf_available, is_vision_available
  from transformers.testing_utils import require_tf, slow
  from ...test_configuration_common import ConfigTester
  from ...test_modeling_tf_common import TFModelTesterMixin, floats_tensor, ids_tensor
label_desc: Use image node_id 5 for calling the TFSegformerModelTester obj's underlying member method code with example usage: obj.create_and_check_for_image_segmentation(config, pixel_values, labels) without return types