News from this site

 Rental advertising space, please contact the webmaster if you need cooperation


+focus
focused

classification  

no classification

tag  

no tag

date  

no datas

使用stable diffusion webui时,安装gfpgan失败的解决方案(windows下的操作)

posted on 2023-05-07 21:30     read(229)     comment(0)     like(29)     collect(5)


1. Problem description

  • When you open the stable diffusion webui for the first time, you need to install github projects such as gfpgan. But when installing gfpgan, it showsRuntimeError: Couldn't install gfpgan
    insert image description here

2. Solutions

  • The reason why gfpgan cannot be installed is a network problem. Even if it has been scientifically surfed the Internet and set it globally, the source code cannot be downloaded from github, resulting in the failure of the install.
  • The solution is to go directly to github to download the GFPGAN code locally and install it locally .
  • Because stable diffusion will create a virtual python environment venv in its root directory, the installation method is different from github. You can refer to the following methods:
    • Download the source file of GFPGAN from github to the local. In this step, you can use git clone or download the zip file directly. After downloading, unzip it (if you use git clone, you don’t need it) to d:\\stable-diffusion-webui\venv\Scriptsthe directory (stable-diffusion-webui is the root directory of your stable diffusion webui, this address is only in my computer, please adjust it according to your own location).
    • Open cmd, cd to d:\\stable-diffusion-webui\venv\Scripts\GFPGAN-masterthe next.
    • Use the command d:\\stable-diffusion-webui\venv\Scripts\python.exe -m pip install basicsr facexlibto install the dependencies of GFPGAN.
    • Then use d:\\stable-diffusion-webui\venv\Scripts\python.exe -m pip install -r requirements.txtthe dependencies to install GFPGAN.
    • d:\\stable-diffusion-webui\venv\Scripts\python.exe setup.py developInstall GFPGAN using .
  • After the installation is complete, open the stable diffusion root directory and webui-user.batyou will find that GFPGAN is no longer required to be installed. If you encounter other modules on github that cannot be installed, you can use the same method.


Category of website: technical article > Blog

Author:Believesinkinto

link:http://www.pythonblackhole.com/blog/article/392/70fa7a907beb8c37bbd1/

source:python black hole net

Please indicate the source for any form of reprinting. If any infringement is discovered, it will be held legally responsible.

29 0
collect article
collected

Comment content: (supports up to 255 characters)