Spaces:
Sleeping
Sleeping
Update app.py
Browse files
app.py
CHANGED
@@ -1,5 +1,6 @@
|
|
1 |
import os
|
2 |
import shutil
|
|
|
3 |
|
4 |
'''
|
5 |
os.system("pip install -U huggingface_hub")
|
@@ -9,6 +10,8 @@ os.system("pip install -U diffusers")
|
|
9 |
if os.path.exists("wuerstchen"):
|
10 |
shutil.rmtree("wuerstchen")
|
11 |
os.system("git clone https://huggingface.co/warp-ai/wuerstchen")
|
|
|
|
|
12 |
|
13 |
import sys
|
14 |
|
@@ -22,7 +25,8 @@ from diffusers.pipelines.wuerstchen.pipeline_wuerstchen_prior import DEFAULT_STA
|
|
22 |
|
23 |
device = 'cuda' if torch.cuda.is_available() else 'cpu'
|
24 |
|
25 |
-
|
|
|
26 |
torch_dtype=torch.float32)
|
27 |
'''
|
28 |
pipe = AutoPipelineForText2Image.from_pretrained("warp-ai/wuerstchen",
|
|
|
1 |
import os
|
2 |
import shutil
|
3 |
+
from pathlib import Path
|
4 |
|
5 |
'''
|
6 |
os.system("pip install -U huggingface_hub")
|
|
|
10 |
if os.path.exists("wuerstchen"):
|
11 |
shutil.rmtree("wuerstchen")
|
12 |
os.system("git clone https://huggingface.co/warp-ai/wuerstchen")
|
13 |
+
if os.path.exists("wuerstchen/.git"):
|
14 |
+
shutil.rmtree("wuerstchen/.git")
|
15 |
|
16 |
import sys
|
17 |
|
|
|
25 |
|
26 |
device = 'cuda' if torch.cuda.is_available() else 'cpu'
|
27 |
|
28 |
+
|
29 |
+
pipe = AutoPipelineForText2Image.from_pretrained(Path("wuerstchen"),
|
30 |
torch_dtype=torch.float32)
|
31 |
'''
|
32 |
pipe = AutoPipelineForText2Image.from_pretrained("warp-ai/wuerstchen",
|