code: def external_source_to_tf_dataset(
      pipe_desc, device_str
  ):  # -> tf.data.Dataset
      pipe, _, dtypes = pipe_desc
      with tf.device(device_str):
          dali_dataset = dali_tf.experimental.DALIDatasetWithInputs(
              input_datasets=None,
              pipeline=pipe,
              batch_size=pipe.max_batch_size,
              output_shapes=None,
              output_dtypes=dtypes,
              num_threads=pipe.num_threads,
              device_id=pipe.device_id,
          )
      return dali_dataset
  
imports: import copy
  import numpy
  import nvidia.dali.plugin.tf
  import tensorflow
  from nvidia.dali import Pipeline, fn
  from test_utils import RandomlyShapedDataIterator
label_desc: Use image node_id 8 for calling a global function with example usage: external_source_to_tf_dataset(pipe_desc, device_str) and returns: dali_dataset