code: def testTransduction(self, p, transformation):
      data_dir = ""
      dataset_split = problem.DatasetSplit.TEST
      for sample in p.generate_samples(
          data_dir, self.test_dir, dataset_split
      ):
          input_tokens = sample["inputs"].split(" ")
          target_tokens = sample["targets"].split(" ")
          self.assertBetween(
              len(input_tokens),
              p.min_sequence_length(dataset_split),
              p.max_sequence_length(dataset_split),
          )
          self.assertBetween(
              len(target_tokens),
              p.min_sequence_length(dataset_split),
              p.max_sequence_length(dataset_split),
          )
  
          transformed_inputs = np.array(transformation(input_tokens))
  
          np.testing.assert_equal(transformed_inputs, target_tokens)
  
file_path: tensor2tensor/tensor2tensor/data_generators/transduction_problems_test.py
imports: from __future__ import absolute_import
  from __future__ import division
  from __future__ import print_function
  import shutil
  import tempfile
  from absl.testing import parameterized
  import numpy
  from tensor2tensor.data_generators import problem
  from tensor2tensor.data_generators import transduction_problems
  import tensorflow.compat.v1
label_desc: Use image node_id 3 for calling the TransductionProblem obj's underlying member method code with example usage: obj.testTransduction(p, transformation) without return types