Update app.py
Browse files
app.py
CHANGED
@@ -176,21 +176,22 @@ min-width:200px;
|
|
176 |
}
|
177 |
"""
|
178 |
with gr.Blocks(css=css, theme=theme) as app:
|
179 |
-
with gr.
|
180 |
-
with gr.
|
181 |
-
|
182 |
-
|
183 |
-
|
184 |
-
|
185 |
-
|
186 |
-
|
187 |
-
|
188 |
-
|
189 |
-
|
190 |
-
|
191 |
-
|
192 |
-
|
193 |
-
|
|
|
194 |
|
195 |
if __name__ == "__main__":
|
196 |
timeout = 100
|
|
|
176 |
}
|
177 |
"""
|
178 |
with gr.Blocks(css=css, theme=theme) as app:
|
179 |
+
with gr.Tab("Text to Image"):
|
180 |
+
with gr.Row():
|
181 |
+
with gr.Column():
|
182 |
+
inp=gr.Textbox(label="Prompt")
|
183 |
+
btn=gr.Button()
|
184 |
+
with gr.Column():
|
185 |
+
col = gr.ColorPicker(label="Color Tint")
|
186 |
+
tint = gr.Slider(label="Tint Strength", minimum=0, maximum=1, step=0.01, value=0.30)
|
187 |
+
|
188 |
+
with gr.Row():
|
189 |
+
model_drop=gr.Dropdown(label="Models", choices=models, type='index', value=models[0])
|
190 |
+
cnt = gr.Number(value=1)
|
191 |
+
out_html=gr.HTML()
|
192 |
+
outp=gr.Gallery()
|
193 |
+
btn.click(run_dif_color,[inp,model_drop,cnt,col,tint],[outp,out_html])
|
194 |
+
app.queue(default_concurrency_limit=200, max_size=200) # <-- Sets up a queue with default parameters
|
195 |
|
196 |
if __name__ == "__main__":
|
197 |
timeout = 100
|