Spaces:
Running
Running
Update app.py
Browse files
app.py
CHANGED
|
@@ -155,16 +155,6 @@ def image_to_wd14_tags(image: Image.Image, model_name: str, threshold: float,
|
|
| 155 |
if __name__ == '__main__':
|
| 156 |
with gr.Blocks() as demo:
|
| 157 |
with gr.Row():
|
| 158 |
-
with gr.Column():
|
| 159 |
-
gr_input_image = gr.Image(type='pil', label='Chen')
|
| 160 |
-
with gr.Row():
|
| 161 |
-
gr_model = gr.Radio(list(WAIFU_MODELS.keys()), value='wd14-vit', label='Waifu Model')
|
| 162 |
-
gr_threshold = gr.Slider(0.0, 1.0, 0.5, label='Chen Chen Chen Chen Chen')
|
| 163 |
-
with gr.Row():
|
| 164 |
-
gr_space = gr.Checkbox(value=True, label='Chen " " Chen Chen "_"')
|
| 165 |
-
|
| 166 |
-
gr_btn_submit = gr.Button(value='Chening', variant='primary')
|
| 167 |
-
|
| 168 |
with gr.Column():
|
| 169 |
gr_input_image = gr.Image(type='pil', label='Original Chen')
|
| 170 |
with gr.Row():
|
|
@@ -191,5 +181,4 @@ if __name__ == '__main__':
|
|
| 191 |
inputs=[gr_input_image, gr_model, gr_threshold, gr_space, gr_escape, gr_confidence, gr_order],
|
| 192 |
outputs=[gr_ratings, gr_output_text, gr_tags],
|
| 193 |
)
|
| 194 |
-
|
| 195 |
-
demo.queue(os.cpu_count()).launch()
|
|
|
|
| 155 |
if __name__ == '__main__':
|
| 156 |
with gr.Blocks() as demo:
|
| 157 |
with gr.Row():
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 158 |
with gr.Column():
|
| 159 |
gr_input_image = gr.Image(type='pil', label='Original Chen')
|
| 160 |
with gr.Row():
|
|
|
|
| 181 |
inputs=[gr_input_image, gr_model, gr_threshold, gr_space, gr_escape, gr_confidence, gr_order],
|
| 182 |
outputs=[gr_ratings, gr_output_text, gr_tags],
|
| 183 |
)
|
| 184 |
+
demo.queue(os.cpu_count()).launch()
|
|
|