Spaces:
Runtime error
Runtime error
Commit
·
fb6afc7
1
Parent(s):
25f8353
code change
Browse files
app.py
CHANGED
@@ -41,19 +41,20 @@ class App:
|
|
41 |
def main():
|
42 |
app = App()
|
43 |
|
44 |
-
|
45 |
-
|
46 |
-
|
47 |
-
|
48 |
-
|
49 |
-
|
50 |
-
|
51 |
-
|
52 |
-
|
53 |
-
|
54 |
-
|
55 |
-
|
56 |
-
|
|
|
57 |
demo.queue(max_size=20)
|
58 |
demo.launch()
|
59 |
|
|
|
41 |
def main():
|
42 |
app = App()
|
43 |
|
44 |
+
gr.Interface(
|
45 |
+
app,
|
46 |
+
inputs=[
|
47 |
+
gr.Radio(app.models, label='The STR model to use', default=app.models[0]),
|
48 |
+
gr.Image(type='pil', label='Image')
|
49 |
+
],
|
50 |
+
outputs=[
|
51 |
+
gr.Textbox(max_lines=1, label='Model output'),
|
52 |
+
gr.Dataframe(row_count=2, col_count=0, label='Raw output with confidence values ([0, 1] interval; [B] - BLANK token; [E] - EOS token)')
|
53 |
+
],
|
54 |
+
live=True,
|
55 |
+
analytics_enabled=False,
|
56 |
+
title=app.title.replace('<br/>', ' ')
|
57 |
+
)
|
58 |
demo.queue(max_size=20)
|
59 |
demo.launch()
|
60 |
|