code: def test_external_source_collection_cycling():
      pipe = Pipeline(1, 3, 0)
  
      batches = [
          [make_array([1.5, 2.5], dtype=datapy.float32)],
          [make_array([-1, 3.5, 4.5], dtype=datapy.float32)],
      ]
  
      pipe.set_outputs(fn.external_source(batches, cycle=True))
      pipe.build()
  
      # epochs are cycles over the source iterable
      for _ in range(3):
          for batch in batches:
              batch = asnumpy(batch)
              check_output(pipe.run(), batch)
  
imports: import functools
  import numpy
  import nvidia.dali.fn
  import nvidia.dali.ops
  from nvidia.dali import Pipeline
  from nose_utils import assert_raises
  from test_utils import check_output
label_desc: Use image node_id 19 for calling a global function with example usage: test_external_source_collection_cycling() without return types