Spaces:
Running
on
Zero
Running
on
Zero
Update feifeilib/feifeitexttoimg.py
Browse files- feifeilib/feifeitexttoimg.py +17 -1
feifeilib/feifeitexttoimg.py
CHANGED
@@ -24,14 +24,30 @@ def feifeitexttoimg(
|
|
24 |
num_inference_steps=4,
|
25 |
guidance_scale=3.5,
|
26 |
num_strength=0.35,
|
|
|
27 |
progress=gr.Progress(track_tqdm=True),
|
28 |
):
|
29 |
prompt,generator = feifeiprompt(randomize_seed,seed,prompt,quality_select,styles_Radio,FooocusExpansion_select)
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
30 |
|
31 |
image = pipe(
|
32 |
# prompt="",
|
33 |
# prompt_2=prompt,
|
34 |
-
|
35 |
width=width,
|
36 |
height=height,
|
37 |
num_inference_steps=num_inference_steps,
|
|
|
24 |
num_inference_steps=4,
|
25 |
guidance_scale=3.5,
|
26 |
num_strength=0.35,
|
27 |
+
FeiFei=0.85,
|
28 |
progress=gr.Progress(track_tqdm=True),
|
29 |
):
|
30 |
prompt,generator = feifeiprompt(randomize_seed,seed,prompt,quality_select,styles_Radio,FooocusExpansion_select)
|
31 |
+
|
32 |
+
pipe.load_lora_weights(
|
33 |
+
hf_hub_download("aifeifei798/feifei-flux-lora-v1.1", "feifei-v1.1.safetensors"),
|
34 |
+
adapter_name="feifei",
|
35 |
+
)
|
36 |
+
|
37 |
+
pipe.set_adapters(
|
38 |
+
["feifei"],
|
39 |
+
adapter_weights=[FeiFei],
|
40 |
+
)
|
41 |
+
|
42 |
+
pipe.fuse_lora(
|
43 |
+
adapter_name=["feifei"],
|
44 |
+
lora_scale=1.0,
|
45 |
+
)
|
46 |
|
47 |
image = pipe(
|
48 |
# prompt="",
|
49 |
# prompt_2=prompt,
|
50 |
+
prompt_2=prompt,
|
51 |
width=width,
|
52 |
height=height,
|
53 |
num_inference_steps=num_inference_steps,
|