code: def pipe_shot_noise(factor, device="cpu"):
      encoded, _ = fn.readers.file(file_root=images_dir)
      in_data = fn.decoders.image(
          encoded, device="cpu", output_type=types.RGB
      )
      if device == "gpu":
          in_data = in_data.gpu()
      factor_arg = factor or fn.random.uniform(range=(0.1, 100.0))
      out_data = fn.noise.shot(in_data, factor=factor_arg)
      return in_data, out_data, factor_arg
  
file_path: DALI/dali/test/python/operator_1/test_noise_shot.py
imports: from nvidia.dali import pipeline_def
  import nvidia.dali.fn
  import nvidia.dali.types
  import random
  import numpy
  import os
  from test_utils import get_dali_extra_path
  from test_noise_utils import PSNR
label_desc: Use image node_id 2 for calling a global function with example usage: pipe_shot_noise(factor, device) and returns: in_data,  out_data,  factor_arg