GithubHelp home page GithubHelp logo

Comments (10)

MarekKowalski avatar MarekKowalski commented on August 15, 2024

Hi,

The current version is slow because the face alignment method (from the dlib library) requires face detection to run in every frame.
I have a version which uses Deep Alignment Network, a method published in one of my other repos for face alignment. I plan to include that version in this repo, but I don't have time to work on it right now.

For now you can download this faster version from Dropbox here:
https://www.dropbox.com/sh/yfq0hcu0we2hed0/AABXckFonehfgLfdzicjqqJYa?dl=0

Keep in mind that you need to install additional Python modules as detailed in the Deep Alignment Network repo. You will also need a gpu compatible with CUDA if you want it to work fast.

Let me know if that helps.

Marek

from faceswap.

seasonyang avatar seasonyang commented on August 15, 2024

@MarekKowalski
thank you for your help。
I have tried your idea,but when I run the new modle only using CPU,its speed is slowler than before.

from faceswap.

MarekKowalski avatar MarekKowalski commented on August 15, 2024

Yeah, it defienietly has to run on GPU to be fast.

from faceswap.

minhazur-piash avatar minhazur-piash commented on August 15, 2024

How can I run this program on GPU, please let me know.

from faceswap.

MarekKowalski avatar MarekKowalski commented on August 15, 2024

Hi,

If you mean the program I linked on Dropbox then please take a look at the installation requirements in this repo:
https://github.com/MarekKowalski/DeepAlignmentNetwork

Marek

from faceswap.

minhazur-piash avatar minhazur-piash commented on August 15, 2024

Hi,
Thanks for quick reply.
I don't have gpu compatible with CUDA,. Can I use openCL instead, if yes please let me know what changes I have to make.

Minhaz

from faceswap.

MarekKowalski avatar MarekKowalski commented on August 15, 2024

Hi,

No idea, look at the theano documentation and see there (theano is the library that uses the GPU).

Marek

from faceswap.

minhazur-piash avatar minhazur-piash commented on August 15, 2024

Hi,
Found out that utils.getFaceKeypoints(cameraImg, detector, predictor, prevShape2D) taking longer time and the reason behind dropping frames. Is there any workaround?
Thanks.
Minhaz.

from faceswap.

MarekKowalski avatar MarekKowalski commented on August 15, 2024

Hi,

Are you using the version that I supplied above in dropbox or the version in the repo?
If the one in Dropbox, I would suggest trying to enable gpu support.
If you are using the other version you might want to try to perform face detection on downscaled images.

Marek

from faceswap.

MarekKowalski avatar MarekKowalski commented on August 15, 2024

Hi,

The performance of the face alignment step (DAN) would definitely be lower than what you would get from a GPU equipped desktop computer. There would definitely be some room for performance improvements in other places, as there are some things that Python is very slow at. I am however not sure that it would be sufficiently fast.

One thing you might want to try to improve the DAN performance is to only use a single stage instead of two stages. You can specify that in the constructor parameters.

Best regards,

Marek

from faceswap.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.