code: def test_dali_iterator_decorator_declarative_pipeline_fn_with_argument():
      # given
      @data_iterator(output_map=["data"], reader_name="reader")
      def iterator_function(num_shards):
          return iterator_function_def(num_shards=num_shards)
  
      iter = iterator_function(
          num_shards=2,
          num_threads=4,
          device_id=0,
          batch_size=batch_size,
      )
  
      # then
      run_and_assert_sequential_iterator(iter)
  
      # We want to assert that the argument was actually passed. It should affect the
      # number of samples in the iterator.
      # Dataset has 47 samples, with batch_size=3 and num_shards=2, we should get 24 samples.
      # That is because the last batch is extended with the first sample to match the batch_size.
      assert iter.size == 24
  
file_path: DALI/dali/test/python/jax_plugin/test_iterator_decorator.py
imports: from utils import iterator_function_def
  from nvidia.dali.plugin.jax import DALIGenericIterator, data_iterator
  from test_iterator import run_and_assert_sequential_iterator
  import inspect
label_desc: Use image node_id 4 for calling a global function with example usage: test_dali_iterator_decorator_declarative_pipeline_fn_with_argument() and returns: iterator_function_def