SD安装笔记
./webui.sh --server-name=0.0.0.0 --listen --device-id 1
set COMMANDLINE_ARGS=–share
/etc/apt/sources.list.d/cuda-ubuntu2204-12-2-local.list
如果要删除nividia驱动,这个源必须删除。
wget https://developer.download.nvidia.com/compute/cuda/12.2.0/local_installers/cuda_12.2.0_535.54.03_linux.run
sudo sh cuda_12.2.0_535.54.03_linux.run
run文件删除,是成功率比较大的
CUDA的下载页面
sudo vim /etc/modprobe.d/blacklist-nouveau.conf
blacklist nouveau
options nouveau modeset=0
sudo update-initramfs -u
lsmod | grep nouveau
禁用nouveau
sudo ubuntu-drivers devices
查看已经安装的驱动
import torch
torch.version
‘2.1.0+cu121’
torch.cuda.is_available()
查看Torch版本
import torch
torch.version
‘2.1.0+cu121’
torch.cuda.is_available()
查看Torch版本
https://blog.csdn.net/zxdd2018/article/details/127705627
cuDNN的安装
sudo apt-get -f install
修复依赖问题,但是大多数的时候不太好用, 还是得删除了,重新装最干净
sudo apt-get upgrade
cannot import name ‘_compare_version‘ from ‘torchmetrics.utilities.imports‘
https://zhuanlan.zhihu.com/p/619901627
比较全的安装CUDA的方法。
export CUDA_VISIBLE_DEVICES=0,1,2,3
pip config set global.index-url https://mirrors.aliyun.com/pypi/simple
还是不行,然后换成下面的命令:
pip install open-clip-torch
open-clip-torch 使用 阿里的镜像好用
–xformers
–reinstall-torch
sudo .run --silent --driver
CUDA_VISIBLE_DEVICES=0,1,2,3 python launch.py --share
No module ‘xformers’. Proceeding without it.
pip install xformers==0.0.16
pip install xformers-0.0.23.post1
装0.0.16版本,装高版本的没法用。
Installing collected packages: torch, xformers
Attempting uninstall: torch
Found existing installation: torch 1.13.1+cu117
Uninstalling torch-1.13.1+cu117:
Successfully uninstalled torch-1.13.1+cu117
Attempting uninstall: xformers
Found existing installation: xformers 0.0.16
Uninstalling xformers-0.0.16:
Successfully uninstalled xformers-0.0.16
set COMMANDLINE_ARGS=--xformers
webui.sh --xformers