Page 1 of 1

Faceswap.py Does not startup after installing it and installing the missing modules

Posted: Sat Aug 29, 2020 3:41 pm
by theimagera

Hi, I have tried to setup faceswap.py peviously on an old pc and it worked.
I have chosen the same configuration and it somehow does not work. When I try to open it with the power shell, it gives me this error;

Code: Select all

Traceback (most recent call last):
  File "faceswap.py", line 5, in <module>
    from lib.cli import args
  File "C:\Users\randy\Faceswap\lib\cli\args.py", line 11, in <module>
    from lib.utils import get_backend
  File "C:\Users\randy\Faceswap\lib\utils.py", line 18, in <module>
    from tqdm import tqdm
ModuleNotFoundError: No module named 'tqdm'

I then installed the module with pip and then get this error;

Code: Select all

Setting Faceswap backend to CPU
Traceback (most recent call last):
  File "faceswap.py", line 5, in <module>
    from lib.cli import args
  File "C:\Users\randy\Faceswap\lib\cli\args.py", line 12, in <module>
    from lib.gpu_stats import GPUStats
  File "C:\Users\randy\Faceswap\lib\gpu_stats.py", line 20, in <module>
    import pynvml

Now I installed that with pip and I get this final error;

Code: Select all

Setting Faceswap backend to CPU
There was an error reading from the Nvidia Machine Learning Library. Either you do not have an Nvidia GPU (in which case this warning can be ignored) or the most likely cause is incorrectly installed drivers. If this is the case, Please remove and reinstall your Nvidia drivers before reporting.Original Error: NVML Shared Library Not Found
No GPU detected. Switching to CPU mode
Traceback (most recent call last):
  File "faceswap.py", line 48, in <module>
    _main()
  File "faceswap.py", line 33, in _main
    generate_configs()
  File "C:\Users\randy\Faceswap\lib\config.py", line 364, in generate_configs
    mod.Config(None)
  File "C:\Users\randy\Faceswap\lib\config.py", line 27, in __init__
    self.set_defaults()
  File "C:\Users\randy\Faceswap\plugins\convert\_config.py", line 31, in set_defaults
    self.load_module(filename, import_path, plugin_type)
  File "C:\Users\randy\Faceswap\plugins\convert\_config.py", line 40, in load_module
    mod = import_module("{}.{}".format(module_path, module))
  File "C:\Users\randy\AppData\Local\Programs\Python\Python38-32\lib\importlib\__init__.py", line 127, in import_module
    return _bootstrap._gcd_import(name[level:], package, level)
  File "<frozen importlib._bootstrap>", line 1014, in _gcd_import
  File "<frozen importlib._bootstrap>", line 991, in _find_and_load
  File "<frozen importlib._bootstrap>", line 961, in _find_and_load_unlocked
  File "<frozen importlib._bootstrap>", line 219, in _call_with_frames_removed
  File "<frozen importlib._bootstrap>", line 1014, in _gcd_import
  File "<frozen importlib._bootstrap>", line 991, in _find_and_load
  File "<frozen importlib._bootstrap>", line 961, in _find_and_load_unlocked
  File "<frozen importlib._bootstrap>", line 219, in _call_with_frames_removed
  File "<frozen importlib._bootstrap>", line 1014, in _gcd_import
  File "<frozen importlib._bootstrap>", line 991, in _find_and_load
  File "<frozen importlib._bootstrap>", line 961, in _find_and_load_unlocked
  File "<frozen importlib._bootstrap>", line 219, in _call_with_frames_removed
  File "<frozen importlib._bootstrap>", line 1014, in _gcd_import
  File "<frozen importlib._bootstrap>", line 991, in _find_and_load
  File "<frozen importlib._bootstrap>", line 961, in _find_and_load_unlocked
  File "<frozen importlib._bootstrap>", line 219, in _call_with_frames_removed
  File "<frozen importlib._bootstrap>", line 1014, in _gcd_import
  File "<frozen importlib._bootstrap>", line 991, in _find_and_load
  File "<frozen importlib._bootstrap>", line 961, in _find_and_load_unlocked
  File "<frozen importlib._bootstrap>", line 219, in _call_with_frames_removed
  File "<frozen importlib._bootstrap>", line 1014, in _gcd_import
  File "<frozen importlib._bootstrap>", line 991, in _find_and_load
  File "<frozen importlib._bootstrap>", line 961, in _find_and_load_unlocked
  File "<frozen importlib._bootstrap>", line 219, in _call_with_frames_removed
  File "<frozen importlib._bootstrap>", line 1014, in _gcd_import
  File "<frozen importlib._bootstrap>", line 991, in _find_and_load
  File "<frozen importlib._bootstrap>", line 973, in _find_and_load_unlocked
ModuleNotFoundError: No module named 'Users'

I am using python 3,8.5 with the latest version of faceswap.py.
Can anyone please help me? I would really appreciate it.


Re: Faceswap.py Does not startup after installing it and installing the missing modules

Posted: Sun Aug 30, 2020 10:47 am
by torzdf

How are you installing Faceswap? What OS are you using?


Re: Faceswap.py Does not startup after installing it and installing the missing modules

Posted: Sun Aug 30, 2020 1:40 pm
by theimagera

I am using Windows and I installed it with the windows installation guide.


Re: Faceswap.py Does not startup after installing it and installing the missing modules

Posted: Sun Aug 30, 2020 1:46 pm
by theimagera

I also don't have that great of a GPU but I did install with the CPU option
The GPU is Nvidia GTX 275.
The CPU is AMD FX(tm)-4100 Quad-Core Processor


Re: Faceswap.py Does not startup after installing it and installing the missing modules

Posted: Mon Aug 31, 2020 7:24 am
by torzdf

Yeah, there is no way that that GPU will run faceswap.

If you still want to proceed though, then please follow (all) of these steps and then run the Windows Installer
app.php/faqpage#f1r1


Re: Faceswap.py Does not startup after installing it and installing the missing modules

Posted: Mon Aug 31, 2020 1:52 pm
by theimagera

Hi, weirdly enough I still get the same error after doing these steps as you asked.
I removed python with anaconda and miniconda.
I removed every python file & conda file.
I couldn't find any CUDA files for some reason.
I removed the faceswap folder
I rebooted the machine and then I re-installed it and still get the same error.

Maybe there are still some cuda files somewhere that I could not find. If so, can you please tell me where they normally get installed?


Re: Faceswap.py Does not startup after installing it and installing the missing modules

Posted: Mon Aug 31, 2020 4:03 pm
by abigflea

Torzdf mentioned your gpu. He's 99.8% correct usually :-)
Think you need to support cuda 10.5 on the gpu?
AT less than 2GB VRAM I don't think it would run anyway.
I can't look it up easily from work. The 900 series on works.l with 4gb++ vram


Re: Faceswap.py Does not startup after installing it and installing the missing modules

Posted: Mon Aug 31, 2020 10:09 pm
by theimagera

Yeah, Thanks anyway tho. Will a Nvidia GTX 1650 work with the faceswap program and if it does, does it actually run faster than a CPU?