Spaces:
Running
on
Zero
Running
on
Zero
刘虹雨
commited on
Commit
·
0a9d3cd
1
Parent(s):
2f1e1a3
update code
Browse files
app.py
CHANGED
@@ -358,8 +358,7 @@ def launch_pretrained():
|
|
358 |
)
|
359 |
logging.info("delete models.")
|
360 |
|
361 |
-
|
362 |
-
os.remove('./pretrained_model/sd21/v2-1_512-nonema-pruned.ckpt')
|
363 |
|
364 |
# 下载 CrucibleAI/ControlNetMediaPipeFace 的所有文件
|
365 |
snapshot_download(
|
@@ -695,6 +694,7 @@ def style_transfer(processed_image, style_prompt, cfg, strength, save_base,image
|
|
695 |
save_dir = os.path.join(save_base, 'style_img')
|
696 |
os.makedirs(save_dir, exist_ok=True)
|
697 |
control_image = generate_annotation(src_img_pil, max_faces=1)
|
|
|
698 |
trg_img_pil = pipeline_sd(
|
699 |
prompt=style_prompt,
|
700 |
image=src_img_pil,
|
|
|
358 |
)
|
359 |
logging.info("delete models.")
|
360 |
|
361 |
+
|
|
|
362 |
|
363 |
# 下载 CrucibleAI/ControlNetMediaPipeFace 的所有文件
|
364 |
snapshot_download(
|
|
|
694 |
save_dir = os.path.join(save_base, 'style_img')
|
695 |
os.makedirs(save_dir, exist_ok=True)
|
696 |
control_image = generate_annotation(src_img_pil, max_faces=1)
|
697 |
+
print(style_prompt)
|
698 |
trg_img_pil = pipeline_sd(
|
699 |
prompt=style_prompt,
|
700 |
image=src_img_pil,
|