class_docstr: NYU Depth V2 Dataset.
docstr: Yields examples.
docstr_tok: ["Yields","examples","."]
code: def _generate_examples(self, root_dir):
      """Yields examples."""
      h5py = tfds.core.lazy_imports.h5py
      for directory in tf.io.gfile.listdir(root_dir):
          for file_name in tf.io.gfile.listdir(
              os.path.join(root_dir, directory)
          ):
              with h5py.File(
                  os.path.join(root_dir, directory, file_name), "r"
              ) as f:
                  yield directory + "_" + file_name, {
                      "image": np.transpose(f["rgb"], (1, 2, 0)),
                      "depth": f["depth"][:].astype("float16"),
                  }
  
file_path: datasets/tensorflow_datasets/datasets/nyu_depth_v2/nyu_depth_v2_dataset_builder.py
imports: import os
  import numpy
  from tensorflow_datasets.core.utils.lazy_imports_utils import tensorflow
  import tensorflow_datasets.public_api
label_desc: Use image node_id 3 for calling the Builder obj's underlying member method code with example usage: obj._generate_examples(root_dir) without return types