code: def test_batch_encode_plus_batch_sequence_length(self):
      # Tests that all encoded values have the correct size
      tokenizers = self.get_tokenizers(do_lower_case=False)
      for tokenizer in tokenizers:
          with self.subTest(f"{tokenizer.__class__.__name__}"):
              table = self.get_table(tokenizer, length=0)
              sequences = [
                  "Testing batch encode plus",
                  "Testing batch encode plus with different sequence lengths",
                  "Testing batch encode plus with different sequence lengths correctly pads",
              ]
  
              encoded_sequences = [
                  tokenizer.encode_plus(table, sequence)
                  for sequence in sequences
              ]
              encoded_sequences_batch = tokenizer.batch_encode_plus(
                  table, sequences, padding=False
              )
              self.assertListEqual(
                  encoded_sequences,
                  self.convert_batch_encode_plus_format_to_encode_plus(
                      encoded_sequences_batch
                  ),
              )
  
              maximum_length = len(
                  max(
                      [
                          encoded_sequence["input_ids"]
                          for encoded_sequence in encoded_sequences
                      ],
                      key=len,
                  )
              )
  
              # check correct behaviour if no pad_token_id exists and add it eventually
              self._check_no_pad_token_padding(tokenizer, sequences)
  
              encoded_sequences_padded = [
                  tokenizer.encode_plus(
                      table,
                      sequence,
                      max_length=maximum_length,
                      padding="max_length",
                  )
                  for sequence in sequences
              ]
  
              encoded_sequences_batch_padded = (
                  tokenizer.batch_encode_plus(
                      table, sequences, padding=True
                  )
              )
              self.assertListEqual(
                  encoded_sequences_padded,
                  self.convert_batch_encode_plus_format_to_encode_plus(
                      encoded_sequences_batch_padded
                  ),
              )
  
              # check 'longest' is unsensitive to a max length
              encoded_sequences_batch_padded_1 = (
                  tokenizer.batch_encode_plus(
                      table, sequences, padding=True
                  )
              )
              encoded_sequences_batch_padded_2 = (
                  tokenizer.batch_encode_plus(
                      table,
                      sequences,
                      max_length=maximum_length + 10,
                      padding="longest",
                  )
              )
              for key in encoded_sequences_batch_padded_1.keys():
                  self.assertListEqual(
                      encoded_sequences_batch_padded_1[key],
                      encoded_sequences_batch_padded_2[key],
                  )
  
              # check 'no_padding' is unsensitive to a max length
              encoded_sequences_batch_padded_1 = (
                  tokenizer.batch_encode_plus(
                      table, sequences, padding=False
                  )
              )
              encoded_sequences_batch_padded_2 = (
                  tokenizer.batch_encode_plus(
                      table,
                      sequences,
                      max_length=maximum_length + 10,
                      padding=False,
                  )
              )
              for key in encoded_sequences_batch_padded_1.keys():
                  self.assertListEqual(
                      encoded_sequences_batch_padded_1[key],
                      encoded_sequences_batch_padded_2[key],
                  )
  
imports: import json
  import os
  import shutil
  import tempfile
  import unittest
  from typing import List
  import pandas
  from transformers import AddedToken, TapexTokenizer
  from transformers.models.tapex.tokenization_tapex import VOCAB_FILES_NAMES
  from transformers.testing_utils import is_pt_tf_cross_test, require_pandas, slow
  from ...test_tokenization_common import TokenizerTesterMixin
label_desc: Use image node_id 30 for calling the TapexTokenizationTest obj's underlying member method code with example usage: obj.test_batch_encode_plus_batch_sequence_length() without return types