code: def _test_reader_files_arg(use_root, use_labels, shuffle):
      root = g_root
      fnames = g_files
      if not use_root:
          fnames = [os.path.join(root, f) for f in fnames]
          root = None
  
      lbl = None
      if use_labels:
          lbl = [10000 + i for i in range(len(fnames))]
  
      batch_size = 3
      pipe = Pipeline(batch_size, 1, 0)
      files, labels = fn.readers.file(
          file_root=root,
          files=fnames,
          labels=lbl,
          random_shuffle=shuffle,
      )
      pipe.set_outputs(files, labels)
      pipe.build()
  
      num_iters = (len(fnames) + 2 * batch_size) // batch_size
      for i in range(num_iters):
          out_f, out_l = pipe.run()
          for j in range(batch_size):
              contents = bytes(out_f.at(j)).decode("utf-8")
              label = out_l.at(j)[0]
              index = label - 10000 if use_labels else label
              assert contents == ref_contents(fnames[index])
  
imports: import glob
  import numpy
  import nvidia.dali.fn
  import os
  import random
  import tempfile
  from nvidia.dali import Pipeline, pipeline_def
  from nose_utils import assert_raises
  from test_utils import compare_pipelines
label_desc: Use image node_id 5 for calling a global function with example usage: _test_reader_files_arg(use_root, use_labels, shuffle) without return types