Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add support for half precision in face renderer #704

Open
wants to merge 3 commits into
base: main
Choose a base branch
from

Conversation

vardanagarwal
Copy link

By adding a support for half precision, I was able to speed up the operations by more than 50%.
image

To use in the inference.py add the --half flag. In the gradio demo, created a checkbox for enabling half precision.

Initially, I was applying it on all the models in src/modules/make_animation, but then the output head movement was almost non-existant so sticking to applying it only on the main generator. The output is also very similar to the one without half precision but not entirely same.

I have tested it with different combinations of preprocessors and reference videos and did not face an issue, but if there is some test suite to test against please do that or let me know.

@vardanagarwal
Copy link
Author

#625 #309

@2catycm
Copy link

2catycm commented Jan 22, 2024

Awesome! I am trying to make sadtalker faster too! This PR helps me a lot

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants