code: def test_file_reader_relpath():
      batch_size = 3
      rel_root = os.path.relpath(g_root, os.getcwd())
      fnames = [os.path.join(rel_root, f) for f in g_files]
  
      pipe = Pipeline(batch_size, 1, 0)
      files, labels = fn.readers.file(files=fnames, random_shuffle=True)
      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")
              index = out_l.at(j)[0]
              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 7 for calling a global function with example usage: test_file_reader_relpath() without return types