miojizzy commited on
Commit
c11ae4f
·
1 Parent(s): 3594539

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +17 -18
app.py CHANGED
@@ -27,21 +27,20 @@ def greet2(v):
27
  print(ret)
28
  return ret
29
 
30
- demo = gr.Interface(
31
- fn=greet,
32
- inputs=gr.Video(),
33
- outputs="text",
34
- examples = "./example",
35
- )
36
-
37
- demo.queue().launch(debug=True)
38
-
39
-
40
-
41
- #def my_function(x, progress=gr.Progress()):
42
- # progress(0, desc="Starting...")
43
- # time.sleep(1)
44
- # for i in progress.tqdm(range(100)):
45
- # time.sleep(0.1)
46
- # return x
47
- #gr.Interface(my_function, gr.Textbox(), gr.Textbox()).queue().launch()
 
27
  print(ret)
28
  return ret
29
 
30
+ #demo = gr.Interface(
31
+ # fn=greet,
32
+ # inputs=gr.Video(),
33
+ # outputs="text",
34
+ # examples = "./example",
35
+ #)
36
+ #demo.queue().launch(debug=True)
37
+
38
+
39
+
40
+ def my_function(x, progress=gr.Progress()):
41
+ progress(0, desc="Starting...")
42
+ time.sleep(1)
43
+ for i in progress.tqdm(range(100)):
44
+ time.sleep(0.1)
45
+ return x
46
+ gr.Interface(my_function, gr.Textbox(), gr.Textbox()).queue().launch()