Detectron2 with rcnn for foreground detection Passing the bounding box to SAM model Segment mask through controlnet in stable diffusion inpaint to fill the space Used mixed precions training Replaced detectron with yolo