esimov / pigo

Fast face detection, pupil/eyes localization and facial landmark points detection library in pure Go.
MIT License
4.39k stars 310 forks source link

Can this be somehow used to smart-detect background image and replace it in realtime? #52

Closed s3rj1k closed 2 years ago

s3rj1k commented 2 years ago

Can this be somehow used to smart-detect background image and replace it in realtime?

esimov commented 2 years ago

You want something like what zoom or skype offer? I mean to retain the face unaltered but replace the background with a custom image? I suppose you tried the wasm version...

s3rj1k commented 2 years ago

@esimov yea, exactly, did not try anything yet, first thing that came to my mind when I saw this lib, was can I do smart background replacement with it :)

I know it can be done using python, but I like that this is golang lib :)

esimov commented 2 years ago

I somehow forgot about this ticket, but to answer your question, I created a few WASM demos using the Pigo library and one of them is tackling exactly the same situation, only I'm not replacing the background image but blurring it out. To replace the background image with a custom one is possible, but it's not quite appealing because of limited facial landmark points supported by the library.