pkhungurn / talking-head-anime-demo

Demo for the "Talking Head Anime from a Single Image."
MIT License
1.99k stars 286 forks source link

Low frame rate and low GPU occupancy rate #10

Closed JadyXuan closed 4 years ago

JadyXuan commented 4 years ago

The torch.cuda.is_available() print out True, and the dlib also use gpu (dlib.DLIIB_USE_CUDA() is True) However when the script runs it occupies 20% CPU and only 0.5% GPU TIM图片20200217153328 And the frame rate only 4 fps I wonder if it is other step that slow the frames output rate?How can I accelerate it><

dragonmeteor commented 4 years ago

Thank you for the information. The answer is: I don't know. Maybe you can find out and tell me. :)

dragonmeteor commented 4 years ago

A theory is that the Windows Task Manager might not be the best tool to measure how much your GPU is used. Use Open Hardware Monitor (https://openhardwaremonitor.org/) instead and you might see a different number.

When I used the Puppeteer tool, Windows Task Manager showed that only 0.4% of the GPU was used by the Python process. On the other hand, Open Hardware Monitor showed that 39% of the GPU was used instead of just 0.5%

gpu-usage

JadyXuan commented 4 years ago

BN4SL23YDZ2ZHSIIV4OU__G That' true, it's my GPU that can't run faster. I think it's time to get a more expensive GPU. xwx