Update app.py
Browse files
app.py
CHANGED
|
@@ -2,6 +2,8 @@ import gradio as gr
|
|
| 2 |
import time
|
| 3 |
|
| 4 |
def greet(text):
|
|
|
|
|
|
|
| 5 |
print('start sleep')
|
| 6 |
time.sleep(20)
|
| 7 |
print('end sleep')
|
|
@@ -9,7 +11,7 @@ def greet(text):
|
|
| 9 |
|
| 10 |
with gr.Blocks() as demo:
|
| 11 |
input_text = gr.Textbox()
|
| 12 |
-
output_text = gr.Textbox()
|
| 13 |
btn = gr.Button("Run")
|
| 14 |
btn.click(fn=greet, inputs=input_text)
|
| 15 |
|
|
|
|
| 2 |
import time
|
| 3 |
|
| 4 |
def greet(text):
|
| 5 |
+
print('\n')
|
| 6 |
+
print(text)
|
| 7 |
print('start sleep')
|
| 8 |
time.sleep(20)
|
| 9 |
print('end sleep')
|
|
|
|
| 11 |
|
| 12 |
with gr.Blocks() as demo:
|
| 13 |
input_text = gr.Textbox()
|
| 14 |
+
#output_text = gr.Textbox()
|
| 15 |
btn = gr.Button("Run")
|
| 16 |
btn.click(fn=greet, inputs=input_text)
|
| 17 |
|