class_docstr: Bounding box of the annotation.
class_docstr_tok: ["Bounding","box","of","the","annotation","."]
docstr: Args:
      box: List[float]
          [minx, miny, maxx, maxy]
      shift_amount: List[int]
          To shift the box and mask predictions from sliced image
          to full sized image, should be in the form of [shift_x, shift_y]
docstr_tok: ["Args",":","box",":","List","[","float","]","[","minx",",","miny",",","maxx",",","maxy","]","shift_amount",":","List","[","int","]","To","shift","the","box","and","mask","predictions","from","sliced","image","to","full","sized","image",",","should","be","in","the","form","of","[","shift_x",",","shift_y","]"]
code: def __init__(
      self, box: List[float], shift_amount: List[int] = [0, 0]
  ):
      """
      Args:
          box: List[float]
              [minx, miny, maxx, maxy]
          shift_amount: List[int]
              To shift the box and mask predictions from sliced image
              to full sized image, should be in the form of [shift_x, shift_y]
      """
      if box[0] < 0 or box[1] < 0 or box[2] < 0 or box[3] < 0:
          raise Exception(
              "Box coords [minx, miny, maxx, maxy] cannot be negative"
          )
      self.minx = box[0]
      self.miny = box[1]
      self.maxx = box[2]
      self.maxy = box[3]
  
      self.shift_x = shift_amount[0]
      self.shift_y = shift_amount[1]
  
imports: import copy
  from typing import Dict, List, Optional
  import numpy
  from sahi.utils.coco import CocoAnnotation, CocoPrediction
  from sahi.utils.cv import get_bbox_from_bool_mask, get_bool_mask_from_coco_segmentation, get_coco_segmentation_from_bool_mask
  from sahi.utils.shapely import ShapelyAnnotation
label_desc: Use image node_id 1 to create a new BoundingBox object  with example: obj = BoundingBox(box, shift_amount)