code: def __init__(
      self,
      device,
      batch_size,
      output_type,
      input_type,
      use_input,
      num_threads=3,
      device_id=0,
      num_gpus=1,
      inv_map=False,
  ):
      super(WarpPipeline, self).__init__(
          batch_size,
          num_threads,
          device_id,
          seed=7865,
          exec_async=False,
          exec_pipelined=False,
      )
      self.use_input = use_input
      self.use_dynamic_size = use_input  # avoid Cartesian product
      self.name = device
      self.input = ops.readers.Caffe(
          path=caffe_db_folder, shard_id=device_id, num_shards=num_gpus
      )
      self.decode = ops.decoders.Image(
          device="cpu", output_type=types.RGB
      )
      if input_type != types.UINT8:
          self.cast = ops.Cast(device=device, dtype=input_type)
      else:
          self.cast = None
  
      static_size = None if self.use_dynamic_size else (240, 320)
  
      fill = 12.5 if output_type == types.FLOAT else 42
      output_type_arg = (
          output_type if output_type != input_type else None
      )
  
      if use_input:
          self.transform_source = ops.ExternalSource(
              lambda: gen_transforms(self.max_batch_size, 10)
          )
          self.warp = ops.WarpAffine(
              device=device,
              size=static_size,
              fill_value=fill,
              dtype=output_type_arg,
              inverse_map=inv_map,
          )
      else:
          warp_matrix = (0.1, 0.9, 10, 0.8, -0.2, -20)
          self.warp = ops.WarpAffine(
              device=device,
              size=static_size,
              matrix=warp_matrix,
              fill_value=fill,
              dtype=output_type_arg,
              inverse_map=inv_map,
          )
  
      self.iter = 0
  
imports: import nose_utils
  from nvidia.dali.pipeline import Pipeline
  import nvidia.dali.ops
  import nvidia.dali.fn
  import nvidia.dali.types
  import numpy
  import math
  import os
  import cv2
  from sequences_test_utils import video_suite_helper, SampleDesc, ArgCb
  from test_utils import compare_pipelines
  import random
label_desc: Use image node_id 1 to create a new WarpPipeline object from inherited base classes: Pipeline with example: obj = WarpPipeline(device, batch_size, output_type, input_type, use_input, num_threads, device_id, num_gpus, inv_map)