alwaysbegrowing / pre-processing

0 stars 0 forks source link

Detect Streamer's Faces Automatically #104

Open chand1012 opened 2 years ago

chand1012 commented 2 years ago

I made a concept script for this exact thing that seems to work exceptionally well while using a simple HAAR Cascade-based OpenCV Python script.

image

The approximate location for the streamer's face would be based on the auto-generated thumbnails to decrease IO to Twitch. Most of those functions should be copy+pasted into a Lambda that will return the location of the streamer's face for when the auto-generate lambda runs and creates short-form mobile clips.

gatesyp commented 2 years ago

this looks like a good v1 to me

curious to see how it performs in production, there are some caching/efficiency opportunities i can think of

cool feature! :)

chand1012 commented 2 years ago

We could definitely cache it in the future, however it should be fast enough for an initial prototype. Using Python's async library I can process about 30 images a second on my system. It would be slower on lambda but it will be fast enough for the first prototype. In the future I can multithread it properly with step function maps.

chand1012 commented 2 years ago

Things to note:

chand1012 commented 2 years ago

Here is my quick-and-dirty chart of how the lambda would work. There would be one lambda process per thumbnail.

notes