Spaces:
Sleeping
Sleeping
Update app.py
Browse files
app.py
CHANGED
@@ -42,15 +42,20 @@ def main():
|
|
42 |
example_image = Image.open("imgs/example2.jpg").convert("RGB")
|
43 |
|
44 |
|
45 |
-
def load_example(
|
|
|
|
|
|
|
|
|
|
|
46 |
example_instruction = random.choice(example_instructions)
|
47 |
return [example_image, example_instruction] + generate(
|
48 |
example_image,
|
49 |
example_instruction,
|
50 |
seed,
|
51 |
0,
|
52 |
-
text_cfg_scale
|
53 |
-
image_cfg_scale
|
54 |
)
|
55 |
|
56 |
def generate(
|
|
|
42 |
example_image = Image.open("imgs/example2.jpg").convert("RGB")
|
43 |
|
44 |
|
45 |
+
def load_example(
|
46 |
+
seed: int,
|
47 |
+
randomize_seed: bool,
|
48 |
+
text_cfg_scale: float,
|
49 |
+
image_cfg_scale: float,
|
50 |
+
):
|
51 |
example_instruction = random.choice(example_instructions)
|
52 |
return [example_image, example_instruction] + generate(
|
53 |
example_image,
|
54 |
example_instruction,
|
55 |
seed,
|
56 |
0,
|
57 |
+
text_cfg_scale,
|
58 |
+
image_cfg_scale,
|
59 |
)
|
60 |
|
61 |
def generate(
|