code: def tokenize_transformer(
      x: Union[list, np.ndarray],
      tokenizer: Callable,
      max_len: int,
      backend: str,
  ) -> dict:
      """
      Batch tokenizer for transformer models.
  
      Parameters
      ----------
      x
          Batch of instances.
      tokenizer
          Tokenizer for model.
      max_len
          Max token length.
      backend
          PyTorch ('pt') or TensorFlow ('tf') backend.
  
      Returns
      -------
      Tokenized instances.
      """
      return tokenizer(
          list(x),
          padding=True,
          truncation=True,
          max_length=max_len,
          return_tensors=backend,
      )
  
label_desc: Use image node_id 1 for calling a global function with example usage: tokenize_transformer(x, tokenizer, max_len, backend) and returns: tokenizer