code: def process_record_dataset(
      dataset,
      is_training,
      batch_size,
      shuffle_buffer,
      parse_record_fn,
      dtype=None,
  ):
      if dtype is None:
          dtype = tf.float32
      dataset = dataset.prefetch(buffer_size=batch_size)
      if is_training:
          dataset = dataset.shuffle(buffer_size=shuffle_buffer)
  
      dataset = dataset.repeat()
      dataset = dataset.apply(
          tf.data.experimental.map_and_batch(
              lambda value: parse_record_fn(value, is_training, dtype),
              batch_size=batch_size,
              num_parallel_batches=1,
          )
      )
  
      dataset = dataset.prefetch(
          buffer_size=tf.data.experimental.AUTOTUNE
      )
  
      return dataset
  
imports: from zoo.orca import init_orca_context, stop_orca_context
  import os
  import argparse
  import tensorflow
label_desc: Use image node_id 11 for calling a global function with example usage: process_record_dataset(dataset, is_training, batch_size, shuffle_buffer, parse_record_fn, dtype) and returns: dataset