Comments (10)
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.
@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.
Yeah, it defienietly has to run on GPU to be fast.
from faceswap.
How can I run this program on GPU, please let me know.
from faceswap.
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.
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.
Hi,
No idea, look at the theano documentation and see there (theano is the library that uses the GPU).
Marek
from faceswap.
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.
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.
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)
- face moving while blinking HOT 1
- Overlay Transparency HOT 1
- Question mean3DShape HOT 1
- The principle about the algorithms in 'FaceSwap' HOT 1
- Real Time? HOT 1
- RuntimeError: Unable to open ../shape_predictor_68_face_landmarks.dat HOT 1
- Face texture. HOT 5
- google colab HOT 1
- mouth HOT 5
- How to interupt the script? HOT 1
- How to make eye blinking HOT 6
- How can run zad2.py without camera HOT 1
- Face Vibrating HOT 2
- Multiple faces in source or target video HOT 4
- How to create my own candide.npz
- Faces not properly aligned in the final image
- Error with predictor HOT 1
- About gesture control and masks
- cv2.error: OpenCV(4.5.2-dev) :-1: error: (-5:Bad argument) in function 'pointPolygonTest' HOT 3
- face reading 3D...
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
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.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from faceswap.