1

I'm trying to install stable diffusion. hitting this error after torch is finished installing.

made sure to add python to PATH

deleted venv folder.

reinstalled python 10.6 a few times

not sure how to proceed.

Sorry for the poor formatting of the code

'''

Installing gfpgan
Traceback (most recent call last):
File "C:\Users\B\Downloads\ai\stable-diffusion-webui\launch.py", line 294, in <module>
prepare_environment()
File "C:\Users\B\Downloads\ai\stable-diffusion-webui\launch.py", line 212, in 
prepare_environment
run_pip(f"install {gfpgan_package}", "gfpgan")
File "C:\Users\B\Downloads\ai\stable-diffusion-webui\launch.py", line 78, in run_pip
return run(f'"{python}" -m pip {args} --prefer-binary{index_url_line}', desc=f"Installing 
{desc}", errdesc=f"Couldn't install {desc}")
File "C:\Users\B\Downloads\ai\stable-diffusion-webui\launch.py", line 49, in run
raise RuntimeError(message)
RuntimeError: Couldn't install gfpgan.
Command: "C:\Users\B\Downloads\ai\stable-diffusion-webui\venv\Scripts\python.exe" -m pip 
install git+https://github.com/TencentARC/GFPGAN.git@8d2447a2d918f8eba5a4a01463fd48e45126a379 
--prefer-binary
Error code: 1
stdout: Collecting 
git+https://github.com/TencentARC/GFPGAN.git@8d2447a2d918f8eba5a4a01463fd48e45126a379
Cloning https://github.com/TencentARC/GFPGAN.git (to revision 
8d2447a2d918f8eba5a4a01463fd48e45126a379) to c:\users\b\appdata\local\temp\pip-req-build- 
rnu9_mu9

stderr:   Running command git clone --filter=blob:none --quiet 
https://github.com/TencentARC/GFPGAN.git 'C:\Users\B\AppData\Local\Temp\pip-req-build- 
rnu9_mu9'
fatal: expected 'packfile'
error: subprocess-exited-with-error

git clone --filter=blob:none --quiet https://github.com/TencentARC/GFPGAN.git 
'C:\Users\B\AppData\Local\Temp\pip-req-build-rnu9_mu9' did not run successfully.
exit code: 128

See above for output.

note: This error originates from a subprocess, and is likely not a problem with pip.
error: subprocess-exited-with-error

git clone --filter=blob:none --quiet https://github.com/TencentARC/GFPGAN.git 
'C:\Users\B\AppData\Local\Temp\pip-req-build-rnu9_mu9' did not run successfully.
exit code: 128

See above for output.

note: This error originates from a subprocess, and is likely not a problem with pip.

[notice] A new release of pip available: 22.2.1 -> 22.3.1
[notice] To update, run: C:\Users\B\Downloads\ai\stable-diffusion- 
webui\venv\Scripts\python.exe -m pip install --upgrade pip

'''

StateOfB
  • 29
  • 1
  • 9
  • 1
    You have an old or broken Git installation. If you can turn off the `--filter=blob:none` option, that may help, otherwise try installing the most recent Git version. – torek Dec 22 '22 at 16:04
  • Please show the command you're running to install this package. Question: any reason you're not just using `pip install gfpgan` which would get the latest from PyPI? – joanis Dec 22 '22 at 19:27
  • There is no "Python 10.6". Did you mean 3.10.6? – Karl Knechtel Jan 16 '23 at 15:31
  • "deleted venv folder." Don't do that. Instead, **make sure you understand how venvs work**. – Karl Knechtel Jan 16 '23 at 15:33

3 Answers3

0

Maybe you're installing the package in venv environment. I open the terminal in vscode and pip install gfpgan in the venv terminal and it succeed.

Youth overturn
  • 341
  • 5
  • 7
0

You can install gfpgan manually..

Run this command from your installation directory

"\stable-diffusion-webui\venv\Scripts\python.exe" -m pip install https://github.com/TencentARC/GFPGAN/archive/8d2447a2d918f8eba5a4a01463fd48e45126a379.zip --prefer-binary

nawaz anjum
  • 81
  • 1
  • 2
0

If your network has problems, you can first download GFPGAN.zip, then run this in venv.

python.exe -m pip install "your path\GFPGAN-8d2447a2d918f8eba5a4a01463fd48e45126a379.zip" --prefer-binary
FengZi
  • 41
  • 6