From c2689e183bf47445d501749ab09bf867e8eb1303 Mon Sep 17 00:00:00 2001 From: Christopher Williams Date: Sat, 1 Oct 2022 16:36:41 -0400 Subject: [PATCH] GFPGAN model is needed in the folder --- README.md | 6 ++++++ install_sdco.bat | 5 ++++- install_sdco.sh | 5 ++++- 3 files changed, 14 insertions(+), 2 deletions(-) diff --git a/README.md b/README.md index d56cba9..9809293 100644 --- a/README.md +++ b/README.md @@ -61,6 +61,12 @@ https://huggingface.co/CompVis/stable-diffusion-v-1-4-original copy the file to your stable-diffusion-cpuonly-main directory +### Download the GFPGAN model + +https://github.com/TencentARC/GFPGAN/releases/download/v1.3.0/GFPGANv1.3.pth + +copy the file to your stable-diffusion-cpuponly-main directory + ### Windows - Running the install script open a terminal or powershell and cd to your stable-diffusion-cpuonly-main directory and run diff --git a/install_sdco.bat b/install_sdco.bat index 15fbcea..d90658b 100755 --- a/install_sdco.bat +++ b/install_sdco.bat @@ -1,11 +1,14 @@ echo This Script is now installing a Stable Diffusion cpu only variant. -mkdir "models/ldm/stable-diffusion-v1/" +mkdir "models/ldm/stable-diffusion-v1" mkdir "outputs/extras-samples" mkdir "outputs/img2img-samples/samples" mkdir "outputs/txt2img-samples/samples" +mkdir "src/gfpgan/experiments/pretrained_models" copy sd-v1-4.ckpt "models/ldm/stable-diffusion-v1/model.ckpt" del sd-v1-4.ckpt +copy GFPGANv1.3.pth "src/gfpgan/experiments/pretrained_models/GFPGANv1.3.pth" +del GFPGANv1.3.pth call conda install pytorch torchvision torchaudio cpuonly -c pytorch call conda env create -f environment-cpuonly.yaml diff --git a/install_sdco.sh b/install_sdco.sh index b9bad1e..b73a384 100755 --- a/install_sdco.sh +++ b/install_sdco.sh @@ -2,12 +2,15 @@ echo This Script is now installing a Stable Diffusion cpu only variant. -mkdir -p models/ldm/stable-diffusion-v1/ +mkdir -p models/ldm/stable-diffusion-v1 mkdir -p outputs/extras-samples mkdir -p outputs/img2img-samples/samples mkdir -p outputs/txt2img-samples/samples +mkdir src/gfpgan/experiments/pretrained_models cp sd-v1-4.ckpt models/ldm/stable-diffusion-v1/model.ckpt rm sd-v1-4.ckpt +cp GFPGANv1.3.pth src/gfpgan/experiments/pretrained_models/GFPGANv1.3.pth +rm GFPGANv1.3.pth conda install pytorch torchvision torchaudio cpuonly -c pytorch conda env create -f environment-cpuonly.yaml