code: def test_init_mismatched_task_type():
      """Test the TextData object when the task type does not match the label format"""
  
      # Arrange
      label = [1, 2, 3]
      text = ["a", "b", "c"]
  
      # Act & Assert
      assert_that(
          calling(TextData).with_args(
              raw_text=text,
              label=label,
              task_type="token_classification",
          ),
          raises(
              DeepchecksValueError,
              r"tokenized_text must be provided for token_classification task type",
          ),
      )
  
      # Arrange
      label = [["PER", "ORG", "ORG", "GEO"], [], []]
  
      # Act & Assert
      assert_that(
          calling(TextData).with_args(
              raw_text=text,
              label=label,
              task_type="text_classification",
          ),
          raises(
              DeepchecksValueError,
              r"multilabel was identified. It must be a Sequence of Sequences of 0 or 1.",
          ),
      )
  
imports: import numpy
  import pandas
  from hamcrest import assert_that, calling, contains_exactly, equal_to, raises
  from deepchecks.core.errors import DeepchecksValueError
  from deepchecks.nlp.text_data import TextData
label_desc: Use image node_id 3 for calling a global function with example usage: test_init_mismatched_task_type() without return types