class_docstr: Build a tf.data.Dataset object out of Instruction instance(s).
  
  This class should not typically be exposed to the TFDS user.
class_docstr_tok: ["Build","a","tf.data.Dataset","object","out","of","Instruction","instance","(","s",")",".","This","class","should","not","typically","be","exposed","to","the","TFDS","user","."]
docstr: Returns single tf.data.Dataset instance for the set of file instructions.
  
  Args:
    file_instructions: The files information. The filenames contains the
      relative path, not absolute. skip/take indicates which example read in
      the shard: `ds.skip().take()`
    read_config: The input pipeline options
    shuffle_files: If True, input files are shuffled before being read.
    disable_shuffling: Specifies if the dataset being read has shuffling
      disabled.
    decode_fn: Eventual additional processing to apply to the example after
      deserialization.
  
  Returns:
     a tf.data.Dataset instance.
docstr_tok: ["Returns","single","tf.data.Dataset","instance","for","the","set","of","file","instructions",".","Args",":","file_instructions",":","The","files","information",".","The","filenames","contains","the","relative","path",",","not","absolute",".","skip\/take","indicates","which","example","read","in","the","shard",":","`","ds.skip","(",")",".take","(",")","`","read_config",":","The","input","pipeline","options","shuffle_files",":","If","True",",","input","files","are","shuffled","before","being","read",".","disable_shuffling",":","Specifies","if","the","dataset","being","read","has","shuffling","disabled",".","decode_fn",":","Eventual","additional","processing","to","apply","to","the","example","after","deserialization",".","Returns",":","a","tf.data.Dataset","instance","."]
code: def read_files(
      self,
      file_instructions: Sequence[shard_utils.FileInstruction],
      *,
      read_config: read_config_lib.ReadConfig,
      shuffle_files: bool,
      disable_shuffling: bool = False,
      decode_fn: Optional[DecodeFn] = None,
  ) -> tf.data.Dataset:
      """Returns single tf.data.Dataset instance for the set of file instructions.
  
      Args:
        file_instructions: The files information. The filenames contains the
          relative path, not absolute. skip/take indicates which example read in
          the shard: `ds.skip().take()`
        read_config: The input pipeline options
        shuffle_files: If True, input files are shuffled before being read.
        disable_shuffling: Specifies if the dataset being read has shuffling
          disabled.
        decode_fn: Eventual additional processing to apply to the example after
          deserialization.
  
      Returns:
         a tf.data.Dataset instance.
      """
      if not file_instructions:
          msg = (
              f"Instruction {file_instructions} corresponds to no data!"
          )
          raise ValueError(msg)
  
      # Read serialized example (eventually with `tfds_id`)
      ds = _read_files(
          file_instructions=file_instructions,
          read_config=read_config,
          shuffle_files=shuffle_files,
          disable_shuffling=disable_shuffling,
          file_format=self._file_format,
      )
  
      # Parse and decode
      def parse_and_decode(ex: Tensor) -> TreeDict[Tensor]:
          # TODO(pierrot): `parse_example` uses
          # `tf.io.parse_single_example`. It might be faster to use `parse_example`,
          # after batching.
          # https://www.tensorflow.org/api_docs/python/tf/io/parse_example
          ex = self._parser.parse_example(ex)
          if decode_fn:
              ex = decode_fn(ex)
          return ex
  
      # Eventually add the `tfds_id` after the decoding
      if read_config and read_config.add_tfds_id:
          parse_and_decode = functools.partial(
              _decode_with_id, decode_fn=parse_and_decode
          )
  
      ds = ds.map(
          parse_and_decode,
          num_parallel_calls=read_config.num_parallel_calls_for_decode,
      )
      return ds
  
imports: from __future__ import annotations
  import functools
  import os
  import re
  from typing import Any, Callable, List, NamedTuple, Optional, Sequence
  from absl import logging
  import numpy
  from tensorflow_datasets.core import example_parser
  from tensorflow_datasets.core import file_adapters
  from tensorflow_datasets.core import splits
  from tensorflow_datasets.core import tf_compat
  from tensorflow_datasets.core import utils
  from tensorflow_datasets.core.utils import file_utils
  from tensorflow_datasets.core.utils import read_config
  from tensorflow_datasets.core.utils import shard_utils
  from tensorflow_datasets.core.utils import tree_utils
  from tensorflow_datasets.core.utils.lazy_imports_utils import tensorflow
label_desc: Use image node_id 3 for calling the Reader obj's underlying member method code with example usage: obj.read_files(file_instructions) and returns: ds, ex