code: def _create_fake_file(folder, split_type, random_state):
      """Creates a fake data file."""
      path = os.path.join(folder, "{}.tar.gz".format(split_type))
      with tf.io.gfile.GFile(path, "w") as fout:
          with tarfile.open(fileobj=fout, mode="w:gz") as tar:
              for i in range(5):
                  for split in ["train", "test", "val"]:
                      # Write serialized numpy to buffer.
                      content = _random_content(random_state)
                      buf = six.BytesIO()
                      np.savez(buf, **content)
                      buf.seek(0)
                      # Create tarinfo for the file.
                      filename = "{split_type}/PGM_{split_type}_{split}_{id}.npz".format(
                          split_type=split_type, split=split, id=i
                      )
                      tarinfo = tarfile.TarInfo(filename)
                      tarinfo.size = len(buf.getvalue())
                      # Add the file to the archive.
                      tar.addfile(tarinfo=tarinfo, fileobj=buf)
  
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 2 for calling a global function with example usage: _create_fake_file(folder, split_type, random_state) without return types