class_docstr: Randomly change the brightness, contrast, saturation and hue of an image or video.
  
  If the input is a :class:`torch.Tensor`, it is expected
  to have [..., 1 or 3, H, W] shape, where ... means an arbitrary number of leading dimensions.
  If img is PIL Image, mode "1", "I", "F" and modes with transparency (alpha channel) are not supported.
  
  Args:
      brightness (float or tuple of float (min, max)): How much to jitter brightness.
          brightness_factor is chosen uniformly from [max(0, 1 - brightness), 1 + brightness]
          or the given [min, max]. Should be non negative numbers.
      contrast (float or tuple of float (min, max)): How much to jitter contrast.
          contrast_factor is chosen uniformly from [max(0, 1 - contrast), 1 + contrast]
          or the given [min, max]. Should be non-negative numbers.
      saturation (float or tuple of float (min, max)): How much to jitter saturation.
          saturation_factor is chosen uniformly from [max(0, 1 - saturation), 1 + saturation]
          or the given [min, max]. Should be non negative numbers.
      hue (float or tuple of float (min, max)): How much to jitter hue.
          hue_factor is chosen uniformly from [-hue, hue] or the given [min, max].
          Should have 0<= hue <= 0.5 or -0.5 <= min <= max <= 0.5.
          To jitter hue, the pixel values of the input image has to be non-negative for conversion to HSV space;
          thus it does not work if you normalize your image to an interval with negative values,
          or use an interpolation that generates negative values before using this function.
class_docstr_tok: ["Randomly","change","the","brightness",",","contrast",",","saturation","and","hue","of","an","image","or","video",".","If","the","input","is","a",":","class",":","`","torch.Tensor","`",",","it","is","expected","to","have","[","...",",","1","or","3",",","H",",","W","]","shape",",","where","...","means","an","arbitrary","number","of","leading","dimensions",".","If","img","is","PIL","Image",",","mode","``","1","''",",","``","I","''",",","``","F","''","and","modes","with","transparency","(","alpha","channel",")","are","not","supported",".","Args",":","brightness","(","float","or","tuple","of","float","(","min",",","max",")",")",":","How","much","to","jitter","brightness",".","brightness_factor","is","chosen","uniformly","from","[","max","(","0",",","1","-","brightness",")",",","1","+","brightness","]","or","the","given","[","min",",","max","]",".","Should","be","non","negative","numbers",".","contrast","(","float","or","tuple","of","float","(","min",",","max",")",")",":","How","much","to","jitter","contrast",".","contrast_factor","is","chosen","uniformly","from","[","max","(","0",",","1","-","contrast",")",",","1","+","contrast","]","or","the","given","[","min",",","max","]",".","Should","be","non-negative","numbers",".","saturation","(","float","or","tuple","of","float","(","min",",","max",")",")",":","How","much","to","jitter","saturation",".","saturation_factor","is","chosen","uniformly","from","[","max","(","0",",","1","-","saturation",")",",","1","+","saturation","]","or","the","given","[","min",",","max","]",".","Should","be","non","negative","numbers",".","hue","(","float","or","tuple","of","float","(","min",",","max",")",")",":","How","much","to","jitter","hue",".","hue_factor","is","chosen","uniformly","from","[","-hue",",","hue","]","or","the","given","[","min",",","max","]",".","Should","have","0","<","=","hue","<","=","0.5","or","-0.5","<","=","min","<","=","max","<","=","0.5",".","To","jitter","hue",",","the","pixel","values","of","the","input","image","has","to","be","non-negative","for","conversion","to","HSV","space",";","thus","it","does","not","work","if","you","normalize","your","image","to","an","interval","with","negative","values",",","or","use","an","interpolation","that","generates","negative","values","before","using","this","function","."]
code: def _transform(self, inpt: Any, params: Dict[str, Any]) -> Any:
      output = inpt
      brightness_factor = params["brightness_factor"]
      contrast_factor = params["contrast_factor"]
      saturation_factor = params["saturation_factor"]
      hue_factor = params["hue_factor"]
      for fn_id in params["fn_idx"]:
          if fn_id == 0 and brightness_factor is not None:
              output = self._call_kernel(
                  F.adjust_brightness,
                  output,
                  brightness_factor=brightness_factor,
              )
          elif fn_id == 1 and contrast_factor is not None:
              output = self._call_kernel(
                  F.adjust_contrast,
                  output,
                  contrast_factor=contrast_factor,
              )
          elif fn_id == 2 and saturation_factor is not None:
              output = self._call_kernel(
                  F.adjust_saturation,
                  output,
                  saturation_factor=saturation_factor,
              )
          elif fn_id == 3 and hue_factor is not None:
              output = self._call_kernel(
                  F.adjust_hue, output, hue_factor=hue_factor
              )
      return output
  
imports: import collections.abc
  from typing import Any, Dict, List, Optional, Sequence, Tuple, Union
  import torch
  from torchvision import transforms
  from torchvision.transforms.v2 import functional, Transform
  from ._transform import _RandomApplyTransform
  from ._utils import query_chw
label_desc: Use image node_id 6 for calling the ColorJitter obj's underlying member method code with example usage: obj._transform(inpt, params) and returns: output