class_docstr: Distort an image with random configurations.
  
  Args:
      brightness_range (float, optional): A range of brightness. Default: 0.5.
      brightness_prob (float, optional): A probability of adjusting brightness. Default: 0.5.
      contrast_range (float, optional): A range of contrast. Default: 0.5.
      contrast_prob (float, optional): A probability of adjusting contrast. Default: 0.5.
      saturation_range (float, optional): A range of saturation. Default: 0.5.
      saturation_prob (float, optional): A probability of adjusting saturation. Default: 0.5.
      hue_range (int, optional): A range of hue. Default: 18.
      hue_prob (float, optional): A probability of adjusting hue. Default: 0.5.
class_docstr_tok: ["Distort","an","image","with","random","configurations",".","Args",":","brightness_range","(","float",",","optional",")",":","A","range","of","brightness",".","Default",":","0.5.","brightness_prob","(","float",",","optional",")",":","A","probability","of","adjusting","brightness",".","Default",":","0.5.","contrast_range","(","float",",","optional",")",":","A","range","of","contrast",".","Default",":","0.5.","contrast_prob","(","float",",","optional",")",":","A","probability","of","adjusting","contrast",".","Default",":","0.5.","saturation_range","(","float",",","optional",")",":","A","range","of","saturation",".","Default",":","0.5.","saturation_prob","(","float",",","optional",")",":","A","probability","of","adjusting","saturation",".","Default",":","0.5.","hue_range","(","int",",","optional",")",":","A","range","of","hue",".","Default",":","18.","hue_prob","(","float",",","optional",")",":","A","probability","of","adjusting","hue",".","Default",":","0.5","."]
code: def __init__(
      self,
      brightness_range=0.5,
      brightness_prob=0.5,
      contrast_range=0.5,
      contrast_prob=0.5,
      saturation_range=0.5,
      saturation_prob=0.5,
      hue_range=18,
      hue_prob=0.5,
  ):
      self.brightness_range = brightness_range
      self.brightness_prob = brightness_prob
      self.contrast_range = contrast_range
      self.contrast_prob = contrast_prob
      self.saturation_range = saturation_range
      self.saturation_prob = saturation_prob
      self.hue_range = hue_range
      self.hue_prob = hue_prob
  
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 1 to create a new RandomDistort object  with example: obj = RandomDistort(brightness_range, brightness_prob, contrast_range, contrast_prob, saturation_range, saturation_prob, hue_range, hue_prob)