class_docstr: Dataset register based on generated `data_dir` paths.
  
  Usage:
  
  ```python
  register = DataDirRegister(namespace_to_data_dirs=
    {'my_namespace': [epath.Path('/path/to/namespaces.toml')]})
  
  # List all registered datasets: ['kaggle:ds0', 'kaggle:ds1',...]
  register.list_builders()
  
  # Load a specific dataset
  builder = register.builder('tensorflow_graphics:shapenet')
  ```
class_docstr_tok: ["Dataset","register","based","on","generated","`","data_dir","`","paths",".","Usage",":","``","`","python","register","=","DataDirRegister","(","namespace_to_data_dirs=","{","'my_namespace","'",":","[","epath.Path","(","'\/path\/to\/namespaces.toml","'",")","]","}",")","#","List","all","registered","datasets",":","[","'kaggle",":","ds0","'",",","'kaggle",":","ds1","'",",","...","]","register.list_builders","(",")","#","Load","a","specific","dataset","builder","=","register.builder","(","'tensorflow_graphics",":","shapenet","'",")","``","`"]
docstr: Contructor.
  
  Args:
    namespace_to_data_dirs: Mapping from namespace to list of paths where the
      datasets for that namespace are located.
docstr_tok: ["Contructor",".","Args",":","namespace_to_data_dirs",":","Mapping","from","namespace","to","list","of","paths","where","the","datasets","for","that","namespace","are","located","."]
code: def __init__(
      self, namespace_to_data_dirs: Dict[str, List[epath.Path]]
  ):
      """Contructor.
  
      Args:
        namespace_to_data_dirs: Mapping from namespace to list of paths where the
          datasets for that namespace are located.
      """
      self._ns2data_dir = namespace_to_data_dirs
  
imports: import concurrent.futures
  import difflib
  import functools
  import os
  from typing import Any, Dict, FrozenSet, Iterable, Iterator, List, Type
  from absl import flags
  from absl import logging
  from etils import epath
  from tensorflow_datasets.core import dataset_builder
  from tensorflow_datasets.core import naming
  from tensorflow_datasets.core import read_only_builder
  from tensorflow_datasets.core import registered
  from tensorflow_datasets.core.community import register_base
  from tensorflow_datasets.core.utils import file_utils
  from tensorflow_datasets.core.utils.lazy_imports_utils import tensorflow
label_desc: Use image node_id 1 to create a new DataDirRegister object from inherited base classes: register_base with example: obj = DataDirRegister(namespace_to_data_dirs)