My stuff

  • My Workflows

  • Liked Workflows

  • Following Workflows

Go to OpenArt main site
Upload workflow

Lock-On Stabilization using Florence2 and SAM2

5.0

0 reviews
3
760
141
0
Description

What's this?

Reproduces a Lock-On Stabilization effect centered on an arbitrary object.

Workflow

  • Extract the first frame from a video
  • 🟪 Use Florence-2 to detect the ball via object detection
  • 🟫 Since detecting only the ball also caused the arm to be included in the segmentation, detect the arm position with Florence-2 and pass it to SAM2 as a negative prompt
  • 🟩 Use the position information from Florence-2 to segment the target object with SAM2
  • 🟨 Use ComfyUI-Inpaint-CropAndStitch to create a cropped region with padding around the masked area, and turn it into a video
    • Increasing context_from_mask_extend_factor will add more padding
Discussion

(No comments yet)

Loading...

Author

32
59.1K
934
285.6K

No reviews yet

  • - latest (2 months ago)

Primitive Nodes (9)

DownloadAndLoadSAM2Model (1)

Florence2ModelLoader (1)

Florence2Run (2)

Florence2toCoordinates (2)

InpaintCropImproved (1)

Sam2VideoSegmentation (1)

Sam2VideoSegmentationAddPoints (1)

Custom Nodes (6)

ComfyUI

  • - ImageFromBatch (1)

  • - PreviewImage (2)

ComfyUI-VideoHelperSuite

  • - VHS_LoadVideo (1)

  • - VHS_VideoCombine (1)

  • - VHS_VideoInfo (1)

Checkpoints (0)

LoRAs (0)