class_docstr: Randomly resizes the image and its bounding boxes  within the specified scale range.
  The class implements the Scale Jitter augmentation as described in the paper
  `"Simple Copy-Paste is a Strong Data Augmentation Method for Instance Segmentation" <https://arxiv.org/abs/2012.07177>`_.
  
  Args:
      target_size (tuple of ints): The target size for the transform provided in (height, weight) format.
      scale_range (tuple of ints): scaling factor interval, e.g (a, b), then scale is randomly sampled from the
          range a <= scale <= b.
      interpolation (InterpolationMode): Desired interpolation enum defined by
          :class:`torchvision.transforms.InterpolationMode`. Default is ``InterpolationMode.BILINEAR``.
code: def forward(
      self, image: Tensor, target: Optional[Dict[str, Tensor]] = None
  ) -> Tuple[Tensor, Optional[Dict[str, Tensor]]]:
      if isinstance(image, torch.Tensor):
          if image.ndimension() not in {2, 3}:
              raise ValueError(
                  f"image should be 2/3 dimensional. Got {image.ndimension()} dimensions."
              )
          elif image.ndimension() == 2:
              image = image.unsqueeze(0)
  
      _, orig_height, orig_width = F.get_dimensions(image)
  
      scale = self.scale_range[0] + torch.rand(1) * (
          self.scale_range[1] - self.scale_range[0]
      )
      r = (
          min(
              self.target_size[1] / orig_height,
              self.target_size[0] / orig_width,
          )
          * scale
      )
      new_width = int(orig_width * r)
      new_height = int(orig_height * r)
  
      image = F.resize(
          image,
          [new_height, new_width],
          interpolation=self.interpolation,
          antialias=self.antialias,
      )
  
      if target is not None:
          target["boxes"][:, 0::2] *= new_width / orig_width
          target["boxes"][:, 1::2] *= new_height / orig_height
          if "masks" in target:
              target["masks"] = F.resize(
                  target["masks"],
                  [new_height, new_width],
                  interpolation=InterpolationMode.NEAREST,
                  antialias=self.antialias,
              )
  
      return image, target
  
imports: from typing import Dict, List, Optional, Tuple, Union
  import torch
  import torchvision
  from torch import nn, Tensor
  from torchvision import ops
  from torchvision.transforms import functional, InterpolationMode, transforms
label_desc: Use image node_id 2 for calling the ScaleJitter obj's underlying member method code with example usage: obj.forward(image, target) and returns: image,  target