code: def test_vs_open_cv():
      batch_size = 10
      for device in ["cpu", "gpu"]:
          # they are independent parameters, it's just not to go overboard with test cases
          for normalize, grayscale in ((True, False), (False, True)):
              # For bigger windows and uint8 mode, cv2 seems to use some integral type that
              # saturates too early (in any case the resulting picture is mostly black and
              # different from the result of running cv2.laplacian with floats and then
              # clamping the results)
              for window_size in range(1, 13, 2):
                  yield (
                      _test_vs_open_cv,
                      device,
                      batch_size,
                      window_size,
                      types.UINT8,
                      None,
                      normalize,
                      grayscale,
                  )
  
imports: from nvidia.dali.pipeline import pipeline_def
  import nvidia.dali.types
  import nvidia.dali.fn
  import numpy
  import cv2
  from scipy.ndimage import convolve1d, filters
  import os
  from nose_utils import assert_raises
  from nose.plugins.attrib import attr
  from sequences_test_utils import video_suite_helper, ArgCb
  from test_utils import get_dali_extra_path, check_batch, RandomlyShapedDataIterator
label_desc: Use image node_id 8 for calling a global function with example usage: test_vs_open_cv() without return types