Commit
·
637a445
1
Parent(s):
2b04666
Update start.txt
Browse files
start.txt
CHANGED
@@ -1,9 +1,3 @@
|
|
1 |
-
import subprocess
|
2 |
-
from IPython.display import display, HTML
|
3 |
-
from PIL import Image
|
4 |
-
html="<h1><code>BẮT ĐẦU CÀI ĐẶT CHƯƠNG TRÌNH - VUI LÒNG ĐỢI ...</code></h1><h3><code>☕️ Pha một ly cà phê đợi 10 phút nữa nhé ...</code></h3><h3><code>☕️ Hãy để ý nháy vào đường dẫn <a>gradio.live</a> để sử dụng</code></h3><p>_________</p>"
|
5 |
-
display(HTML(html))
|
6 |
-
|
7 |
apt -y update -qq
|
8 |
wget http://launchpadlibrarian.net/367274644/libgoogle-perftools-dev_2.5-2.2ubuntu3_amd64.deb
|
9 |
wget https://launchpad.net/ubuntu/+source/google-perftools/2.5-2.2ubuntu3/+build/14795286/+files/google-perftools_2.5-2.2ubuntu3_all.deb
|
@@ -16,4 +10,31 @@ rm *.deb
|
|
16 |
|
17 |
apt -y install -qq aria2 libcairo2-dev pkg-config python3-dev
|
18 |
pip install -q torch==2.0.0+cu118 torchvision==0.15.1+cu118 torchaudio==2.0.1+cu118 torchtext==0.15.1 torchdata==0.6.0 --extra-index-url https://download.pytorch.org/whl/cu118 -U
|
19 |
-
pip install -q xformers==0.0.19 triton==2.0.0 -U
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
apt -y update -qq
|
2 |
wget http://launchpadlibrarian.net/367274644/libgoogle-perftools-dev_2.5-2.2ubuntu3_amd64.deb
|
3 |
wget https://launchpad.net/ubuntu/+source/google-perftools/2.5-2.2ubuntu3/+build/14795286/+files/google-perftools_2.5-2.2ubuntu3_all.deb
|
|
|
10 |
|
11 |
apt -y install -qq aria2 libcairo2-dev pkg-config python3-dev
|
12 |
pip install -q torch==2.0.0+cu118 torchvision==0.15.1+cu118 torchaudio==2.0.1+cu118 torchtext==0.15.1 torchdata==0.6.0 --extra-index-url https://download.pytorch.org/whl/cu118 -U
|
13 |
+
pip install -q xformers==0.0.19 triton==2.0.0 -U
|
14 |
+
|
15 |
+
git clone https://github.com/camenduru/sd-webui-tunnels /content/SDVN/extensions/sd-webui-tunnels
|
16 |
+
git clone https://huggingface.co/embed/negative /content/SDVN/embeddings/negative
|
17 |
+
git clone https://huggingface.co/embed/lora /content/SDVN/models/Lora/positive
|
18 |
+
sample= !ls /content/drive/MyDrive/SD-Data/Lyco
|
19 |
+
if sample == ["ls: cannot access '/content/drive/MyDrive/SD-Data/Lyco': No such file or directory"] :
|
20 |
+
print("Khởi tạo thư mục lần đầu")
|
21 |
+
mkdir /content/drive/MyDrive/SD-Data/
|
22 |
+
mkdir /content/drive/MyDrive/SD-Data/Model
|
23 |
+
mkdir /content/drive/MyDrive/SD-Data/Lora
|
24 |
+
mkdir /content/drive/MyDrive/SD-Data/Embeddings
|
25 |
+
mkdir /content/drive/MyDrive/SD-Data/Lyco
|
26 |
+
mkdir /content/drive/MyDrive/SD-Data/wildcards
|
27 |
+
mkdir /content/drive/MyDrive/SD-Data/Hypernetworks
|
28 |
+
sudo apt-get install aria2
|
29 |
+
rm /content/SDVN/ui-config.json
|
30 |
+
aria2c --continue --console-log-level=error -c -x 16 -s 16 -k 1M https://huggingface.co/bstungnguyen/SDColab/resolve/main/ui-config.json -d /content/SDVN/ -o ui-config.json
|
31 |
+
rm /content/SDVN/style.css
|
32 |
+
aria2c --continue --console-log-level=error -c -x 16 -s 16 -k 1M https://huggingface.co/bstungnguyen/SDColab/resolve/main/style.css -d /content/SDVN/
|
33 |
+
|
34 |
+
aria2c --continue --console-log-level=error -c -x 16 -s 16 -k 1M https://civitai.com/api/download/models/65898 -d /content/SDVN/models/Stable-diffusion -o SDVN-Real-v2.ckpt
|
35 |
+
aria2c --continue --console-log-level=error -c -x 16 -s 16 -k 1M https://huggingface.co/stabilityai/sd-vae-ft-mse-original/resolve/main/vae-ft-mse-840000-ema-pruned.ckpt -d /content/SDVN/models/Stable-diffusion -o VAE84.vae.pt
|
36 |
+
|
37 |
+
ln -s /content/SDVN/models/Stable-diffusion /content/drive/MyDrive/SD-Data/Model
|
38 |
+
ln -s /content/SDVN/models/Lora /content/drive/MyDrive/SD-Data/Lora
|
39 |
+
ln -s /content/SDVN/embeddings /content/drive/MyDrive/SD-Data/Embeddings
|
40 |
+
ln -s /content/SDVN/models/Lora /content/drive/MyDrive/SD-Data/Lyco
|