code: def non_uniform_tl():
      def get_samples():
          return [np.array([42, 42]), np.array([1, 2, 3])]
  
      @pipeline_def(batch_size=2, num_threads=4, device_id=0)
      def pipe():
          return fn.external_source(source=get_samples)
  
      p = pipe()
      p.build()
      return p.run()[0]
  
file_path: DALI/dali/test/python/test_external_source_impl_utils.py
imports: from nvidia.dali._utils import external_source_impl
  from nvidia.dali import tensors, pipeline_def
  import nvidia.dali.fn
  from nose.tools import assert_equals
  from nose_utils import raises
  from nose.plugins.attrib import attr
  import numpy
label_desc: Use image node_id 4 for calling a global function with example usage: non_uniform_tl() and returns: p, list, fn