ubuntu 系统下,安装stable diffusion解决下载速度慢的问题

在Ubuntu系统下,安装过程中需要下载大量的文件,如果直接从GitHub下载,可能会因为网络问题导致失败。中国大陆地区可以使用清华大学提供的镜像源来加速下载。

首先,你需要确保已经安装了git和curl。如果没有安装,可以使用以下命令安装:

sudo apt update

sudo apt install git curl

然后,你可以使用以下命令来下载并安装Stable Diffusion的Web UI:

cd ~

git clone https://github.com/AUTOMATIC1111/stable-diffusion-webui.git

cd stable-diffusion-webui

git checkout webui-v4.9.1 # 切换到稳定的版本

修改install.sh文件,使用清华大学的镜像源

sed -i 's/https:\/\/github.com\//\/\/git.code.tencent.com\/'\

'/stable-diffusion-webui\//g' install.sh

修改webui.sh文件,使用清华大学的镜像源

sed -i 's/https:\/\/github.com\//\/\/git.code.tencent.com\/'\

'/stable-diffusion-webui\//g' webui.sh

修改download_dependencies.sh文件,使用清华大学的镜像源

sed -i 's/https:\/\/github.com\//\/\/git.code.tencent.com\/'\

'/stable-diffusion-webui\//g' download_dependencies.sh

修改download_model.sh文件,使用清华大学的镜像源

sed -i 's/https:\/\/huggingface.co\//\/\/huggingface.bj.bcebos.com\/'\

'/stable-diffusion-webui\//g' download_model.sh

修改prereqs.sh文件,使用清华大学的镜像源

sed -i 's/https:\/\/github.com\//\/\/git.code.tencent.com\/'\

'/stable-diffusion-webui\//g' prereqs.sh

修改download_models.sh文件,使用清华大学的镜像源

sed -i 's/https:\/\/github.com\//\/\/git.code.tencent.com\/'\

'/stable-diffusion-webui\//g' download_models.sh

修改download_prompts.sh文件,使用清华大学的镜像源

sed -i 's/https:\/\/github.com\//\/\/git.code.tencent.com\/'\

'/stable-diffusion-webui\//g' download_prompts.sh

修改download_ui.sh文件,使用清华大学的镜像源

sed -i 's/https:\/\/github.com\//\/\/git.code.tencent.com\/'\

'/stable-diffusion-webui\//g' download_ui.sh

修改download_repositories.sh文件,使用清华大学的镜像源

sed -i 's/https:\/\/github.com\//\/\/git.code.tencent.com\/'\

'/stable-diffusion-webui\//g' download_repositories.sh

修改download_repositories_and_models.sh文件,使用清华大学的镜像源

sed -i 's/https:\/\/github.com\//\/\/git.code.tencent.com\/'\

'/stable-diffusion-webui\//g' download_repositories_and_models.sh

修改download_repositories_and_models_v2.sh文件,使用清华大学的镜像源

sed -i 's/https:\/\/github.com\//\/\/git.code.tencent.com\/'\

'/stable-diffusion-webui\

相关推荐
小成202303202656 小时前
Linux高级02
linux·开发语言
mounter6256 小时前
【硬核前沿】CXL 深度解析:重塑数据中心架构的“高速公路”,Linux 内核如何应对挑战?-- CXL 协议详解与 LSF/MM 最新动态
linux·服务器·网络·架构·kernel
++==6 小时前
Linux 进程间通信与线程同步技术详解:IPC 机制、线程 API、同步工具与经典同步问题
linux
特长腿特长6 小时前
centos、ubantu系列机的用户和用户组的结构是什么?具体怎么配置?用户组权限怎么使用?这篇文章持续更新,帮助你复习linux的基础知识
linux·运维·centos
zzzyyy5387 小时前
Linux环境变量
linux·运维·服务器
pluvium277 小时前
记对 xonsh shell 的使用, 脚本编写, 迁移及调优
linux·python·shell·xonsh
无级程序员7 小时前
centos7 安装 llvm-toolset-7-clang出错的问题解决
linux·centos
CHHC18808 小时前
NetCore树莓派桌面应用程序
linux·运维·服务器
云栖梦泽9 小时前
Linux内核与驱动:9.Linux 驱动 API 封装
linux·c++
橘子编程9 小时前
JavaScript与TypeScript终极指南
javascript·ubuntu·typescript