code: def __init__(self, output_size=None, **kwargs):
      super().__init__()
      if output_size is None:
          raise TypeError("Parameter 'output_size' is required")
      assert isinstance(output_size, (int, tuple))
      self.output_size = output_size
  
imports: import collections
  import importlib
  import logging
  import random
  import mmf.datasets.processors.functional
  import torch
  from mmf.common.registry import registry
  from mmf.datasets.processors import BaseProcessor
  from omegaconf import OmegaConf
  from torchvision import transforms
label_desc: Use image node_id 1 to create a new TruncateOrPad object from inherited base classes: BaseProcessor with example: obj = TruncateOrPad(output_size)