Spaces:
Running
on
Zero
Running
on
Zero
Update app_merged.py
Browse files- app_merged.py +8 -4
app_merged.py
CHANGED
@@ -98,10 +98,6 @@ transform_image = transforms.Compose(
|
|
98 |
#hf_hub_download(repo_id="YarvixPA/FLUX.1-Fill-dev-gguf", filename="flux1-fill-dev-Q5_K_S.gguf", local_dir="models/")
|
99 |
|
100 |
|
101 |
-
fill_pipe = FluxFillPipeline.from_single_file(
|
102 |
-
"https://huggingface.co/SporkySporkness/FLUX.1-Fill-dev-GGUF/flux1-fill-dev-fp16-Q5_0-GGUF.gguf", torch_dtype=torch.bfloat16
|
103 |
-
).to("cuda")
|
104 |
-
|
105 |
|
106 |
# Load
|
107 |
|
@@ -168,6 +164,8 @@ text_encoder = CLIPTextModel.from_pretrained(sd15_name, subfolder="text_encoder"
|
|
168 |
vae = AutoencoderKL.from_pretrained(sd15_name, subfolder="vae")
|
169 |
unet = UNet2DConditionModel.from_pretrained(sd15_name, subfolder="unet")
|
170 |
|
|
|
|
|
171 |
try:
|
172 |
import xformers
|
173 |
import xformers.ops
|
@@ -495,6 +493,12 @@ dpmpp_2m_sde_karras_scheduler = DPMSolverMultistepScheduler(
|
|
495 |
|
496 |
# Pipelines
|
497 |
|
|
|
|
|
|
|
|
|
|
|
|
|
498 |
t2i_pipe = StableDiffusionPipeline(
|
499 |
vae=vae,
|
500 |
text_encoder=text_encoder,
|
|
|
98 |
#hf_hub_download(repo_id="YarvixPA/FLUX.1-Fill-dev-gguf", filename="flux1-fill-dev-Q5_K_S.gguf", local_dir="models/")
|
99 |
|
100 |
|
|
|
|
|
|
|
|
|
101 |
|
102 |
# Load
|
103 |
|
|
|
164 |
vae = AutoencoderKL.from_pretrained(sd15_name, subfolder="vae")
|
165 |
unet = UNet2DConditionModel.from_pretrained(sd15_name, subfolder="unet")
|
166 |
|
167 |
+
|
168 |
+
|
169 |
try:
|
170 |
import xformers
|
171 |
import xformers.ops
|
|
|
493 |
|
494 |
# Pipelines
|
495 |
|
496 |
+
|
497 |
+
fill_pipe = FluxFillPipeline.from_single_file(
|
498 |
+
"https://huggingface.co/SporkySporkness/FLUX.1-Fill-dev-GGUF/flux1-fill-dev-fp16-Q5_0-GGUF.gguf", text_encoder= text_encoder, torch_dtype=torch.bfloat16
|
499 |
+
).to("cuda")
|
500 |
+
|
501 |
+
|
502 |
t2i_pipe = StableDiffusionPipeline(
|
503 |
vae=vae,
|
504 |
text_encoder=text_encoder,
|