code: def _save_images(jpg, imgpaths):
      """Save images with a proper hierarchy."""
      for imgpath in imgpaths:
          dirpath = os.path.dirname(imgpath)
          if not os.path.exists(dirpath):
              os.makedirs(dirpath)
          with tf.io.gfile.GFile(imgpath, "wb") as fimg:
              fimg.write(jpg)
  
file_path: datasets/tensorflow_datasets/testing/fake_data_generation/cassava.py
imports: import os
  from absl import app
  from absl import flags
  from tensorflow_datasets.core import utils
  from tensorflow_datasets.core.utils.lazy_imports_utils import tensorflow
  from tensorflow_datasets.testing import fake_data_utils
label_desc: Use image node_id 2 for calling a global function with example usage: _save_images(jpg, imgpaths) without return types