code: def dali_pipe_batch_N(shapes, types, batch):
      class TestPipeline(pipeline.Pipeline):
          def __init__(self, **kwargs):
              super(TestPipeline, self).__init__(**kwargs)
              self.reader = ops.readers.File(
                  file_root=data_path, file_list=file_list_path
              )
              self.decoder = ops.decoders.Image(device="mixed")
              self.resize = ops.Resize(
                  device="gpu", resize_x=200, resize_y=200
              )
  
          def define_graph(self):
              data, _ = self.reader()
              image = self.decoder(data)
              resized = self.resize(image)
              return resized
  
      pipe = TestPipeline(batch_size=batch, seed=0)
      ds = dali_tf.DALIDataset(
          pipe,
          batch_size=batch,
          output_dtypes=types,
          output_shapes=shapes,
      )
      ds_iter = iter(ds)
      for _ in range(10):
          (image,) = ds_iter.next()
          if shapes is None or len(shapes) == 4:
              assert_equals(image.shape, (batch, 200, 200, 3))
          else:
              assert_equals(image.shape, (200, 200, 3))
  
imports: import tensorflow
  import nvidia.dali.ops
  import nvidia.dali.pipeline
  import nvidia.dali.plugin.tf
  import nvidia.dali.types
  from test_utils_tensorflow import skip_for_incompatible_tf
  import os
  from nose.tools import assert_equals
  from nose_utils import raises
  import itertools
  import warnings
label_desc: Use image node_id 6 for calling a global function with example usage: dali_pipe_batch_N(shapes, types, batch) and returns: resized