andreeabodea commited on
Commit
54bc479
1 Parent(s): 9f2d229

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +13 -2
app.py CHANGED
@@ -1,4 +1,4 @@
1
- import gradio as gr
2
  from transformers import pipeline
3
 
4
  pipe = pipeline("image-to-text",
@@ -12,4 +12,15 @@ iface = gr.Interface(launch,
12
  inputs=gr.Image(type='pil'),
13
  outputs="text")
14
 
15
- iface.launch()
 
 
 
 
 
 
 
 
 
 
 
 
1
+ """import gradio as gr
2
  from transformers import pipeline
3
 
4
  pipe = pipeline("image-to-text",
 
12
  inputs=gr.Image(type='pil'),
13
  outputs="text")
14
 
15
+ iface.launch()
16
+ """
17
+
18
+ import gradio as gr
19
+
20
+ def greet(name):
21
+ return "Hello, " + name + "!"
22
+
23
+ demo = gr.Interface(
24
+ fn=greet,
25
+ inputs=["text", "slider"],
26
+ outputs=["text"],