code: def _random_content(random_state):
      """Returns a dictionary with a data sample with random content."""
      # Randomly sample the number of relations.
      num_relations = random_state.randint(1, 5)
      # Randomly sample the relations.
      relation_structure = []
      for _ in range(num_relations):
          relation_structure.append(
              (
                  random_state.choice(OBJECTS),
                  random_state.choice(ATTRIBUTES),
                  random_state.choice(RELATIONS),
              )
          )
      # Encode the relations.
      relation_structure_encoded = np.zeros((4, 12), dtype=np.int64)
      for i, relation in enumerate(relation_structure):
          for name in relation:
              relation_structure_encoded[i, ENCODING_MAP[name]] = 1
  
      # Create the meta target which is the max across the relations.
      meta_target = np.max(relation_structure_encoded, axis=0)
  
      # Create the final object.
      return {
          "relation_structure_encoded": relation_structure_encoded,
          "relation_structure": np.array(relation_structure),
          "target": random_state.randint(8, dtype=np.int64),
          "image": random_state.randint(
              8, size=(160, 160, 16), dtype=np.int64
          ),
          "meta_target": meta_target,
      }
  
file_path: datasets/tensorflow_datasets/testing/fake_data_generation/abstract_reasoning.py
imports: import os
  import tarfile
  from absl import app
  from absl import flags
  import numpy
  import six
  from tensorflow_datasets.core import utils
  from tensorflow_datasets.core.utils.lazy_imports_utils import tensorflow
  from tensorflow_datasets.testing import test_utils
label_desc: Use image node_id 1 for calling a global function with example usage: _random_content(random_state) and returns: dict