code: def single_file_dataset(input_file, name_to_features):
      """Creates a single-file dataset to be passed for BERT custom training."""
      # For training, we want a lot of parallel reading and shuffling.
      # For eval, we want no shuffling and parallel reading doesn't matter.
      d = tf.data.TFRecordDataset(input_file)
      d = d.map(lambda record: decode_record(record, name_to_features))
  
      # When `input_file` is a path to a single file or a list
      # containing a single path, disable auto sharding so that
      # same input file is sent to all workers.
      # if isinstance(input_file, str) or len(input_file) == 1:
      #   options = tf.data.Options()
      #   options.experimental_distribute.auto_shard_policy = (
      #       tf.data.experimental.AutoShardPolicy.OFF)
      #   d = d.with_options(options)
      return d
  
file_path: autodist/examples/benchmark/utils/input_pipeline.py
imports: from __future__ import absolute_import
  from __future__ import division
  from __future__ import print_function
  import tensorflow
label_desc: Use image node_id 2 for calling a global function with example usage: single_file_dataset(input_file, name_to_features) and returns: d