class_docstr: Randomly crop
  
  Args:
  crop_size (tuple|list): The size you want to crop from image.
class_docstr_tok: ["Randomly","crop","Args",":","crop_size","(","tuple|list",")",":","The","size","you","want","to","crop","from","image","."]
code: def __call__(self, data):
      idex = np.random.randint(low=0, high=len(self.crop_size))
      crop_w, crop_h = self.crop_size[idex]
      img_h, img_w = data["img"].shape[0:2]
  
      start_h = 0
      start_w = 0
      if img_h > crop_h:
          start_h = np.random.randint(img_h - crop_h + 1)
      if img_w > crop_w:
          start_w = np.random.randint(img_w - crop_w + 1)
  
      end_h = min(img_h, start_h + crop_h)
      end_w = min(img_w, start_w + crop_w)
  
      data["img"] = data["img"][start_h:end_h, start_w:end_w]
      for key in data.get("gt_fields", []):
          data[key] = data[key][start_h:end_h, start_w:end_w]
  
      return data
  
imports: import os
  import random
  import string
  import cv2
  import numpy
  from paddleseg.transforms import functional
  from paddleseg.cvlibs import manager
  from paddleseg.utils import seg_env
  from PIL import Image
label_desc: Use image node_id 2 for calling the RandomCrop obj's underlying member method code with example usage: obj.__call__(data) and returns: data