Spaces:
Running
Running
Brian Watson
commited on
Commit
•
edb2002
1
Parent(s):
592b915
Update app.py
Browse files
app.py
CHANGED
@@ -16,7 +16,7 @@ models = [
|
|
16 |
|
17 |
current_model = models[0]
|
18 |
|
19 |
-
text_gen = gr.Interface.load("spaces/
|
20 |
|
21 |
models2 = []
|
22 |
for model in models:
|
@@ -47,7 +47,7 @@ with gr.Blocks() as myface:
|
|
47 |
|
48 |
with gr.Row():
|
49 |
with gr.Row():
|
50 |
-
input_text = gr.Textbox(label="Prompt idea", lines=1)
|
51 |
# Model selection dropdown
|
52 |
model_name1 = gr.Dropdown(
|
53 |
label="Choose Model",
|
@@ -63,29 +63,29 @@ with gr.Blocks() as myface:
|
|
63 |
with gr.Row():
|
64 |
output1 = gr.Image(label="")
|
65 |
output2 = gr.Image(label="")
|
66 |
-
with gr.Row():
|
67 |
-
magic1 = gr.Textbox(lines=2)
|
68 |
-
magic2 = gr.Textbox(lines=2)
|
69 |
-
with gr.Row():
|
70 |
output3 = gr.Image(label="")
|
71 |
-
output4 = gr.Image(label="")
|
72 |
with gr.Row():
|
73 |
-
|
74 |
-
|
|
|
75 |
with gr.Row():
|
|
|
76 |
output5 = gr.Image(label="")
|
77 |
output6 = gr.Image(label="")
|
78 |
with gr.Row():
|
79 |
-
|
80 |
-
|
81 |
-
|
|
|
82 |
output7 = gr.Image(label="")
|
83 |
output8 = gr.Image(label="")
|
|
|
84 |
with gr.Row():
|
85 |
-
magic7 = gr.Textbox(lines=2)
|
86 |
-
magic8 = gr.Textbox(lines=2)
|
|
|
87 |
|
88 |
-
model_name1.change(set_model, inputs=model_name1, outputs=[output1, output2, output3, output4, output5, output6, output7, output8])
|
89 |
|
90 |
run.click(send_it, inputs=[magic1, model_name1], outputs=[output1])
|
91 |
run.click(send_it, inputs=[magic2, model_name1], outputs=[output2])
|
@@ -95,6 +95,7 @@ with gr.Blocks() as myface:
|
|
95 |
run.click(send_it, inputs=[magic6, model_name1], outputs=[output6])
|
96 |
run.click(send_it, inputs=[magic7, model_name1], outputs=[output7])
|
97 |
run.click(send_it, inputs=[magic8, model_name1], outputs=[output8])
|
|
|
98 |
|
99 |
see_prompts.click(text_it, inputs=[input_text], outputs=[magic1])
|
100 |
see_prompts.click(text_it, inputs=[input_text], outputs=[magic2])
|
@@ -104,6 +105,7 @@ with gr.Blocks() as myface:
|
|
104 |
see_prompts.click(text_it, inputs=[input_text], outputs=[magic6])
|
105 |
see_prompts.click(text_it, inputs=[input_text], outputs=[magic7])
|
106 |
see_prompts.click(text_it, inputs=[input_text], outputs=[magic8])
|
|
|
107 |
|
108 |
myface.queue(concurrency_count=200)
|
109 |
-
myface.launch(inline=True, show_api=False, max_threads=400)
|
|
|
16 |
|
17 |
current_model = models[0]
|
18 |
|
19 |
+
text_gen = gr.Interface.load("spaces/daspartho/prompt-extend")
|
20 |
|
21 |
models2 = []
|
22 |
for model in models:
|
|
|
47 |
|
48 |
with gr.Row():
|
49 |
with gr.Row():
|
50 |
+
input_text = gr.Textbox(label="Prompt idea", placeholder="", lines=1)
|
51 |
# Model selection dropdown
|
52 |
model_name1 = gr.Dropdown(
|
53 |
label="Choose Model",
|
|
|
63 |
with gr.Row():
|
64 |
output1 = gr.Image(label="")
|
65 |
output2 = gr.Image(label="")
|
|
|
|
|
|
|
|
|
66 |
output3 = gr.Image(label="")
|
|
|
67 |
with gr.Row():
|
68 |
+
magic1 = gr.Textbox(label="Generated Prompt", lines=2)
|
69 |
+
magic2 = gr.Textbox(label="Generated Prompt", lines=2)
|
70 |
+
magic3 = gr.Textbox(label="Generated Prompt", lines=2)
|
71 |
with gr.Row():
|
72 |
+
output4 = gr.Image(label="")
|
73 |
output5 = gr.Image(label="")
|
74 |
output6 = gr.Image(label="")
|
75 |
with gr.Row():
|
76 |
+
magic4 = gr.Textbox(label="Generated Prompt", lines=2)
|
77 |
+
magic5 = gr.Textbox(label="Generated Prompt", lines=2)
|
78 |
+
magic6 = gr.Textbox(label="Generated Prompt", lines=2)
|
79 |
+
with gr.Row():
|
80 |
output7 = gr.Image(label="")
|
81 |
output8 = gr.Image(label="")
|
82 |
+
output9 = gr.Image(label="")
|
83 |
with gr.Row():
|
84 |
+
magic7 = gr.Textbox(label="Generated Prompt", lines=2)
|
85 |
+
magic8 = gr.Textbox(label="Generated Prompt", lines=2)
|
86 |
+
magic9 = gr.Textbox(label="Generated Prompt", lines=2)
|
87 |
|
88 |
+
model_name1.change(set_model, inputs=model_name1, outputs=[output1, output2, output3, output4, output5, output6, output7, output8, output9])
|
89 |
|
90 |
run.click(send_it, inputs=[magic1, model_name1], outputs=[output1])
|
91 |
run.click(send_it, inputs=[magic2, model_name1], outputs=[output2])
|
|
|
95 |
run.click(send_it, inputs=[magic6, model_name1], outputs=[output6])
|
96 |
run.click(send_it, inputs=[magic7, model_name1], outputs=[output7])
|
97 |
run.click(send_it, inputs=[magic8, model_name1], outputs=[output8])
|
98 |
+
run.click(send_it, inputs=[magic9, model_name1], outputs=[output9])
|
99 |
|
100 |
see_prompts.click(text_it, inputs=[input_text], outputs=[magic1])
|
101 |
see_prompts.click(text_it, inputs=[input_text], outputs=[magic2])
|
|
|
105 |
see_prompts.click(text_it, inputs=[input_text], outputs=[magic6])
|
106 |
see_prompts.click(text_it, inputs=[input_text], outputs=[magic7])
|
107 |
see_prompts.click(text_it, inputs=[input_text], outputs=[magic8])
|
108 |
+
see_prompts.click(text_it, inputs=[input_text], outputs=[magic9])
|
109 |
|
110 |
myface.queue(concurrency_count=200)
|
111 |
+
myface.launch(inline=True, show_api=False, max_threads=400)
|