class_docstr: Base TFDS builder.
  
  The functions to overwrite are:
  
  * `_info`: Defines dataset features and metadata (see TFDS docs:
    https://www.tensorflow.org/datasets/add_dataset#_info_dataset_metadata)
  * `split_to_scene_configs`: Define the splits and scenes
  * `generate_scene`: Generate a single scene and returns the examples.
  
  Usage: See `HelloBeamWorker` for an example.
class_docstr_tok: ["Base","TFDS","builder",".","The","functions","to","overwrite","are",":","*","`","_info","`",":","Defines","dataset","features","and","metadata","(","see","TFDS","docs",":","https",":","\/\/www.tensorflow.org\/datasets\/add_dataset","#","_info_dataset_metadata",")","*","`","split_to_scene_configs","`",":","Define","the","splits","and","scenes","*","`","generate_scene","`",":","Generate","a","single","scene","and","returns","the","examples",".","Usage",":","See","`","HelloBeamWorker","`","for","an","example","."]
docstr: Generate a single scene.
docstr_tok: ["Generate","a","single","scene","."]
code: def _generate_single_scene(
      self,
      id_and_config: tuple[int, SceneConfig],
      *,
      split_to_scenes: SplitScenesMapping,
  ) -> tuple[int, SplitToSceneExs]:
      """Generate a single scene."""
      scene_id, scene_config = id_and_config
  
      with tempfile.TemporaryDirectory() as tmp_dir:
          scene_config = scene_config.replace(scratch_dir=tmp_dir)
  
          scene_output = self.generate_scene(scene_config)
          scene_output = self._normalize_scene_output(
              scene_output=scene_output,
              scene_id=scene_id,
              split_to_scenes=split_to_scenes,
          )
          return scene_id, scene_output
  
imports: from __future__ import annotations
  import abc
  import collections
  import dataclasses
  import itertools
  import tempfile
  from typing import Any, Dict, Iterator, List, Optional, TypeVar, Union
  import apache_beam
  from etils import edc
  from etils import epath
  import kubric
  import tensorflow_datasets
label_desc: Use image node_id 2 for calling the KubricBuilder obj's underlying member method code with example usage: obj._generate_single_scene(id_and_config) and returns: scene_id,  scene_output