code: def test_repeat_last_queue():
      @pipeline_def
      def pipeline():
          cpu = fn.external_source(name="es_cpu", repeat_last=True)
          gpu = fn.external_source(
              name="es_gpu", repeat_last=True, device="gpu"
          )
          return cpu, gpu
  
      pipe = pipeline(
          batch_size=4,
          num_threads=4,
          device_id=0,
          prefetch_queue_depth=2,
      )
      pipe.build()
      data1 = [
          np.array([1], dtype=np.int32),
          np.array([3], dtype=np.int32),
          np.array([42], dtype=np.int32),
          np.array([666], dtype=np.int32),
      ]
      data2 = [
          np.array([11], dtype=np.int32),
          np.array([33], dtype=np.int32),
          np.array([422], dtype=np.int32),
          np.array([6666], dtype=np.int32),
      ]
      data3 = data1
  
      pipe.feed_input("es_cpu", data1)
      pipe.feed_input("es_gpu", data1)
      a, b = pipe.run()
      check_batch(a, data1)
      check_batch(b, data1)
      a, b = pipe.run()
      check_batch(a, data1)
      check_batch(b, data1)
  
      pipe.feed_input("es_cpu", data2)
      a, b = pipe.run()
      check_batch(a, data1)  # <- still the old value
      check_batch(b, data1)
  
      pipe.feed_input("es_gpu", data3)
      a, b = pipe.run()
      check_batch(a, data2)  # <- new value visible
      check_batch(b, data1)  # <- still old
  
      pipe.feed_input("es_cpu", data3)
      a, b = pipe.run()
      check_batch(
          a, data2
      )  # <- still 2, the most recent change not visible
      check_batch(b, data3)
  
imports: import random
  import nvidia.dali.fn
  import nvidia.dali.ops
  import nvidia.dali.types
  import numpy
  from nvidia.dali import Pipeline, pipeline_def
  from test_utils import check_batch
  from nose_utils import raises, assert_warns, assert_raises
  from nvidia.dali.types import DALIDataType
  from numpy.random import default_rng
label_desc: Use image node_id 34 for calling a global function with example usage: test_repeat_last_queue() and returns: cpu,  gpu