segment-anything-video icon indicating copy to clipboard operation
segment-anything-video copied to clipboard

SegAutoMaskPredictor producing random color

Open cnut1648 opened this issue 10 months ago • 1 comments

Hello, first of all, thank you for this awesome works!

I am following the instruction in the README for SegAutoMaskPredictor, specifically this one:

# For video
results = SegAutoMaskPredictor().video_predict(
    source="video.mp4",
    model_type="vit_l", # vit_l, vit_h, vit_b
    points_per_side=16,
    points_per_batch=64,
    min_area=1000,
    output_path="output.mp4",
)

on my private mp4 data. However I note that although the segment seems prefect, they often change color between frames. For example a chair was red in last frame but green in the next frame. I wonder is there any way to enforce color consistency between frames? Any pointer will be appreciated!

cnut1648 avatar Aug 14 '23 03:08 cnut1648