[SOLVED] FaceSwap not using GPU. "cudnn64_8.dll" not found. CUDA setup failed.

Installing and setting up FaceSwap


Forum rules

Read the FAQs and search the forum before posting a new topic.

Please mark any answers that fixed your problems so others can find the solutions.

Post Reply
User avatar
localxboy
Posts: 5
Joined: Mon Jan 06, 2025 10:58 pm
Answers: 1
Has thanked: 1 time

[SOLVED] FaceSwap not using GPU. "cudnn64_8.dll" not found. CUDA setup failed.

Post by localxboy »

Hi! ;)

I'm kind of new to the stuff, so excuse me for not understanding things.

  • (Also worth mentioning. I have kinda old gaming laptop (Lenovo with NV GTX1050 4GB and i5-8300H Turbo 3,9)

What I did:

  • 1. Installed FaceSwap app through original x64 installer. (Selected NVidia Support)
  • 2. Extracted faces, etc.
  • 3. Launched Training
  • 4. GPU Usage 2%, Rate: 7 EG/s like it's a joke.
  • 5. Installed (Globally) lastest cudatoolkit, lastest cudnn, & lastest compatible tensorflow (Bc FaceSwap didn't want to install them)
  • 6. Reinstalled FaceSwap and Conda
  • 7. Training. 2%. Same thing.
  • 8. Uninstalled FaceSwap
  • 9. Did a clear installation of FaceSwap by that guide: NB: It is imperative...
  • 10. Training once again, all the same.

FaceSwap installation log:

► Show Spoiler

GPU-Z
Image
Image

FaceSwap System Info

► Show Spoiler

Training Launch Log

► Show Spoiler

It says "Could not load dynamic library 'cudnn64_8.dll'; dlerror: cudnn64_8.dll not found", but as you can see, other libraries loaded just fine. And you can clearly see presence of "cudnn64_8.dll" library in CUDNN main folder. I've even added the folder to the path.
Image

I did Cuda installations by following this guide: https://support.echoview.com/WebHelp/_I ... ibrary.htm

I guess I need a help in CUDNN 8.1 on my windows machine. Because faceswap can't see the dll i've installed on my own.

Thank you in advance.

► Show Spoiler
by localxboy » Wed Jan 08, 2025 6:03 pm

SOLVED!

If you have a problem like me where the CUDA and CUDNN can't be installed by FaceSwap installer you should try doing...

  1. Go to Control Panel -> Apps -> Check for presence and delete "NVIDIA Frameview", "NVIDIA Nsight", "NVIDIA Cuda"
  2. Run "pip list" from your CMD. Check if tensorflow is installed and remove it through "pip uninstall tensorflow" (+every package containing that name)

Code: Select all

pip uninstall tensorflow, tensorboard, tensorboard-data-server, tensorflow-estimator, tensorflow-intel, tensorflow-io-gcs-filesystem, tensorboard-plugin-wit -y

or

pip uninstall tensorflow -y
pip uninstall tensorboard -y
pip uninstall tensorboard-data-server -y
pip uninstall tensorflow-estimator -y
pip uninstall tensorflow-intel -y
pip uninstall tensorflow-io-gcs-filesystem -y
pip uninstall tensorboard-plugin-wit -y

Then:

  1. Go to your FaceSwap direcory (/Users/<name>/FaceSwap), and check the setup log, CTRL+F and search for "CUDA", then find the right version of CUDA and CUDNN to install, e.g. "cudatoolkit = 11.2", "cudnn = 8.1"
  2. In the same log file search for "tensorflow" version, mine was 2.10.0
  3. Install it, CMD -> "pip install tensorflow==2.10.0"
  4. Download the right CUDA and CUDNN versions

Links:
CUDA: https://developer.nvidia.com/cuda-toolkit-archive
CUDNN: https://developer.nvidia.com/rdp/cudnn-archive (for windows download x86)

  1. Install CUDA. Choose "Custom Installation" when prompted. Uncheck "Visual Studio Integration" and "GF" installation as in screenshots.
    Image
    Image

  2. Install CUDNN. Download the CUDNN archive and extract it to path "C:\Program Files\NVIDIA\GPU Computing Toolkit\CUDNN\v8.1" replace "v8.1" with your version. Choose to replace if prompted.
    Image

Looks like this is it. Have fun! ;) <3

Go to full post
Last edited by localxboy on Thu Jan 09, 2025 4:30 pm, edited 16 times in total.
User avatar
Andentze
Posts: 16
Joined: Mon Dec 06, 2021 6:34 pm
Has thanked: 1 time
Been thanked: 22 times

Re: FaceSwap not using my GPU. 1050. "cudnn64_8.dll" not found.

Post by Andentze »

4. GPU Usage 2%, Rate: 7 EG/s like it's a joke.

Seems like you're using Task Manager to monitor usage, which can work... ...if you set one of the tabs to "CUDA usage"...

Second of all, it is recommended you delete ALL global cuda/cudnn installs and reboot your system before trying to install Faceswap again.
Sending faceswap_setup.log(located at your faceswap folder) would help us locate the issue with cuda/cudnn installs with conda, since the install log you attached isn't verbose enough. But it very well might be a conflict between your install and conda's attempt to install.

All of that is located at FAQ's and Install Guide so make sure you give those a read or two.

User avatar
localxboy
Posts: 5
Joined: Mon Jan 06, 2025 10:58 pm
Answers: 1
Has thanked: 1 time

Re: FaceSwap not using my GPU. 1050. "cudnn64_8.dll" not found.

Post by localxboy »

Andentze wrote: Wed Jan 08, 2025 3:48 pm

4. GPU Usage 2%, Rate: 7 EG/s like it's a joke.

Seems like you're using Task Manager to monitor usage, which can work... ...if you set one of the tabs to "CUDA usage"...

Second of all, it is recommended you delete ALL global cuda/cudnn installs and reboot your system before trying to install Faceswap again.
Sending faceswap_setup.log(located at your faceswap folder) would help us locate the issue with cuda/cudnn installs with conda, since the install log you attached isn't verbose enough. But it very well might be a conflict between your install and conda's attempt to install.

All of that is located at FAQ's and Install Guide so make sure you give those a read or two.

No, I was using Task Manager to show that my CPU usage is at 100%.
But for monitoring GPU I use GPU-Z usage was 2%.

When I was installing FaceSwap the first time I had basically clean windows installation (I didn't do any CUDA and TF installations), no CUDA installs at all. And the only moment i've installed CUDA and CUDNN globally it's when FaceSwap didn't want to install 'em on it's own.

The setup log file: https://system.tips/text/view?q=fnxyvxec

Last edited by localxboy on Wed Jan 08, 2025 4:53 pm, edited 1 time in total.
User avatar
localxboy
Posts: 5
Joined: Mon Jan 06, 2025 10:58 pm
Answers: 1
Has thanked: 1 time

Re: FaceSwap not using my GPU. 1050. "cudnn64_8.dll" not found.

Post by localxboy »

SOLVED!

If you have a problem like me where the CUDA and CUDNN can't be installed by FaceSwap installer you should try doing...

  1. Go to Control Panel -> Apps -> Check for presence and delete "NVIDIA Frameview", "NVIDIA Nsight", "NVIDIA Cuda"
  2. Run "pip list" from your CMD. Check if tensorflow is installed and remove it through "pip uninstall tensorflow" (+every package containing that name)

Code: Select all

pip uninstall tensorflow, tensorboard, tensorboard-data-server, tensorflow-estimator, tensorflow-intel, tensorflow-io-gcs-filesystem, tensorboard-plugin-wit -y

or

pip uninstall tensorflow -y
pip uninstall tensorboard -y
pip uninstall tensorboard-data-server -y
pip uninstall tensorflow-estimator -y
pip uninstall tensorflow-intel -y
pip uninstall tensorflow-io-gcs-filesystem -y
pip uninstall tensorboard-plugin-wit -y

Then:

  1. Go to your FaceSwap direcory (/Users/<name>/FaceSwap), and check the setup log, CTRL+F and search for "CUDA", then find the right version of CUDA and CUDNN to install, e.g. "cudatoolkit = 11.2", "cudnn = 8.1"
  2. In the same log file search for "tensorflow" version, mine was 2.10.0
  3. Install it, CMD -> "pip install tensorflow==2.10.0"
  4. Download the right CUDA and CUDNN versions

Links:
CUDA: https://developer.nvidia.com/cuda-toolkit-archive
CUDNN: https://developer.nvidia.com/rdp/cudnn-archive (for windows download x86)

  1. Install CUDA. Choose "Custom Installation" when prompted. Uncheck "Visual Studio Integration" and "GF" installation as in screenshots.
    Image
    Image

  2. Install CUDNN. Download the CUDNN archive and extract it to path "C:\Program Files\NVIDIA\GPU Computing Toolkit\CUDNN\v8.1" replace "v8.1" with your version. Choose to replace if prompted.
    Image

Looks like this is it. Have fun! ;) <3

Last edited by localxboy on Thu Jan 09, 2025 8:30 am, edited 3 times in total.
User avatar
localxboy
Posts: 5
Joined: Mon Jan 06, 2025 10:58 pm
Answers: 1
Has thanked: 1 time

Re: FaceSwap not using my GPU. 1050. "cudnn64_8.dll" not found.

Post by localxboy »

Laptop 1050 can run 150 EG/s, that's actually not bad at all ;)

Image

Last edited by localxboy on Thu Jan 09, 2025 8:34 am, edited 2 times in total.
Post Reply