Spaces:
Runtime error
Runtime error
Update app.py
Browse files
app.py
CHANGED
|
@@ -11,6 +11,7 @@ from gradio_client import Client
|
|
| 11 |
from detoxify import Detoxify
|
| 12 |
import os
|
| 13 |
import tempfile
|
|
|
|
| 14 |
|
| 15 |
toxicity = Detoxify('original')
|
| 16 |
|
|
@@ -360,7 +361,7 @@ with gr.Blocks() as vote:
|
|
| 360 |
gr.Markdown(INSTR)
|
| 361 |
with gr.Group():
|
| 362 |
with gr.Row():
|
| 363 |
-
image = gr.Image(container=False, show_label=False, min_width=0)
|
| 364 |
btn = gr.Button("Synthesize", variant='primary')
|
| 365 |
model1 = gr.Textbox(interactive=False, lines=1, max_lines=1, visible=False)
|
| 366 |
model2 = gr.Textbox(interactive=False, lines=1, max_lines=1, visible=False)
|
|
|
|
| 11 |
from detoxify import Detoxify
|
| 12 |
import os
|
| 13 |
import tempfile
|
| 14 |
+
import PIL.Image
|
| 15 |
|
| 16 |
toxicity = Detoxify('original')
|
| 17 |
|
|
|
|
| 361 |
gr.Markdown(INSTR)
|
| 362 |
with gr.Group():
|
| 363 |
with gr.Row():
|
| 364 |
+
image = gr.Image(container=False, type='pil', show_label=False, min_width=0)
|
| 365 |
btn = gr.Button("Synthesize", variant='primary')
|
| 366 |
model1 = gr.Textbox(interactive=False, lines=1, max_lines=1, visible=False)
|
| 367 |
model2 = gr.Textbox(interactive=False, lines=1, max_lines=1, visible=False)
|