Skip to content

Suggestion: switch to new async interface for segmentation (>50% drop in CPU usage) #198

@stephematician

Description

@stephematician

I would recommend switching to the asynchronous MediaPipe interface. I've been working on a similar (but fundamentally different) effect and I found that CPU usage dropped dramatically when switching to MediaPipe's new segment_async.

As an example, here's htop output when running Linux-Fake-Background-Webcam script doing no composition whatsoever (just segmenting) 1280x720, 30FPS, MJPG colour:

image

And here's the htop result when I'm running my own effect that uses segment_async (same input/output):

image

Metadata

Metadata

Assignees

No one assigned

    Labels

    enhancementNew feature or request

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions