code: def build_and_run_pipeline(pipe, iters=None, *args):
      pipe.build()
      capture_processes(pipe._py_pool)
      if iters is None:
          while True:
              pipe.run()
      else:
          for _ in range(iters):
              pipe.run()
  
imports: import numpy
  import nvidia.dali
  from nose.tools import with_setup
  from test_pool_utils import capture_processes, teardown_function, setup_function
  from test_utils import compare_pipelines, check_batch, RandomDataIterator, RandomlyShapedDataIterator
label_desc: Use image node_id 2 for calling a global function with example usage: build_and_run_pipeline(pipe, iters) without return types