Spaces:
Runtime error
Runtime error
Update app.py
Browse files
app.py
CHANGED
|
@@ -43,7 +43,7 @@ def update_imgbox(choices):
|
|
| 43 |
def random_choices():
|
| 44 |
import random
|
| 45 |
random.seed()
|
| 46 |
-
return random.choices(561, k=num_models)
|
| 47 |
|
| 48 |
|
| 49 |
# https://huggingface.co/docs/api-inference/detailed_parameters
|
|
@@ -133,7 +133,7 @@ with gr.Blocks(theme='Nymbo/Nymbo_Theme', fill_width=True, css=CSS) as demo:
|
|
| 133 |
seed_rand.click(randomize_seed, None, [seed], queue=False)
|
| 134 |
with gr.Row():
|
| 135 |
gen_button = gr.Button(f'Generate up to {int(num_models)} images from 10 seconds to 3 minutes total', variant='primary', scale=3)
|
| 136 |
-
random_button = gr.Button(f'Random {int(num_models)} ??', variant='secondary', scale=1)
|
| 137 |
#gen_button.click(lambda: gr.update(interactive = True), None, stop_button)
|
| 138 |
gr.Markdown("Scroll down to see more images and select models.", elem_classes="guide")
|
| 139 |
|
|
@@ -162,7 +162,7 @@ with gr.Blocks(theme='Nymbo/Nymbo_Theme', fill_width=True, css=CSS) as demo:
|
|
| 162 |
model_choice = gr.CheckboxGroup(models, label = f'Choose up to {int(num_models)} different models from the {len(models)} available!', value=default_models, interactive=True)
|
| 163 |
model_choice.change(update_imgbox, model_choice, output)
|
| 164 |
model_choice.change(extend_choices, model_choice, current_models)
|
| 165 |
-
random_button.click(random_choices, None, model_choice)
|
| 166 |
|
| 167 |
gr.Markdown("Based on the [TestGen](https://huggingface.co/spaces/derwahnsinn/TestGen) Space by derwahnsinn, the [SpacIO](https://huggingface.co/spaces/RdnUser77/SpacIO_v1) Space by RdnUser77 and Omnibus's Maximum Multiplier!")
|
| 168 |
|
|
|
|
| 43 |
def random_choices():
|
| 44 |
import random
|
| 45 |
random.seed()
|
| 46 |
+
#return random.choices(561, k=num_models)
|
| 47 |
|
| 48 |
|
| 49 |
# https://huggingface.co/docs/api-inference/detailed_parameters
|
|
|
|
| 133 |
seed_rand.click(randomize_seed, None, [seed], queue=False)
|
| 134 |
with gr.Row():
|
| 135 |
gen_button = gr.Button(f'Generate up to {int(num_models)} images from 10 seconds to 3 minutes total', variant='primary', scale=3)
|
| 136 |
+
#random_button = gr.Button(f'Random {int(num_models)} ??', variant='secondary', scale=1)
|
| 137 |
#gen_button.click(lambda: gr.update(interactive = True), None, stop_button)
|
| 138 |
gr.Markdown("Scroll down to see more images and select models.", elem_classes="guide")
|
| 139 |
|
|
|
|
| 162 |
model_choice = gr.CheckboxGroup(models, label = f'Choose up to {int(num_models)} different models from the {len(models)} available!', value=default_models, interactive=True)
|
| 163 |
model_choice.change(update_imgbox, model_choice, output)
|
| 164 |
model_choice.change(extend_choices, model_choice, current_models)
|
| 165 |
+
#random_button.click(random_choices, None, model_choice)
|
| 166 |
|
| 167 |
gr.Markdown("Based on the [TestGen](https://huggingface.co/spaces/derwahnsinn/TestGen) Space by derwahnsinn, the [SpacIO](https://huggingface.co/spaces/RdnUser77/SpacIO_v1) Space by RdnUser77 and Omnibus's Maximum Multiplier!")
|
| 168 |
|