Skip to content

Virtual Background - Add temporal smoothing to reduce segmentation flicker #17080

@solomon17705cs

Description

@solomon17705cs

What problem are you trying to solve?

The virtual background processes each video frame independently, without referencing previous frames. This lack of temporal consistency causes visible artifacts during motion:

  • Jitter: When raising a hand or moving quickly, the segmentation mask fluctuates frame-to-frame, creating a "ghostly" or "shimmering" effects
  • Flicker on Small Movements: Subtle movements cause the mask to alternately classify pixels as foreground/background, resulting in a strobing effect where the user and background appear to toggle rapidly.

The segmentation model outputs a per-frame alpha mask with no temporal smoothing. Small variations in inference (body movements, due to lighting, or model uncertainty) manifest as visible jitter when composited.

What solution would you like to see?

Implementation of lightweight temporal smoothing by blending the current frame's alpha mask with the previous frame's mask would reduce the flickering

Is there an alternative?

No response

Metadata

Metadata

Assignees

No one assigned

    Labels

    feature-requestIssue which suggest an idea, enhancement or feature to implement

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions