code: def _create_and_compare_simple_pipelines(
      cb,
      py_callback_pickler,
      batch_size,
      py_num_workers=2,
      py_start_method="spawn",
  ):
      parallel_pipeline = create_simple_pipeline(
          cb,
          py_callback_pickler,
          batch_size=batch_size,
          py_num_workers=py_num_workers,
          py_start_method=py_start_method,
          parallel=True,
      )
      serial_pipeline = create_simple_pipeline(
          cb, None, batch_size=batch_size, parallel=False
      )
      parallel_pipeline.build()
      serial_pipeline.build()
      for _ in range(3):
          _run_and_compare_outputs(
              batch_size, parallel_pipeline, serial_pipeline
          )
  
imports: import copyreg
  import numpy
  import nvidia.dali.fn
  import nvidia.dali.pickling
  import os
  from nvidia.dali import pipeline_def
  from pickle import PicklingError
  from nose_utils import raises
  from test_utils import get_dali_extra_path, restrict_python_version
label_desc: Use image node_id 22 for calling a global function with example usage: _create_and_compare_simple_pipelines(cb, py_callback_pickler, batch_size, py_num_workers, py_start_method) without return types