mipra commited on
Commit
5743c3b
Β·
1 Parent(s): 357d948

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +3 -2
app.py CHANGED
@@ -4,7 +4,8 @@ import requests
4
 
5
 
6
 
7
-
 
8
 
9
 
10
 
@@ -30,5 +31,5 @@ model = AutoModelForSeq2SeqLM.from_pretrained("salesken/translation-hi-en")
30
  # due to covid, we have reduced our debt interest
31
 
32
 
33
- iface = gr.Interface(fn=translate, inputs="text", outputs="text")
34
  iface.launch()
 
4
 
5
 
6
 
7
+ image = gr.outputs.Image(type="pil", label="Your result")
8
+ css = ".output-image{height: 528px !important} .output-carousel .output-image{height:272px !important} a{text-decoration: underline}"
9
 
10
 
11
 
 
31
  # due to covid, we have reduced our debt interest
32
 
33
 
34
+ iface = gr.Interface(fn=translate, inputs="text",outputs=[image,gr.outputs.Carousel(label="Individual images",components=["image"]),gr.outputs.Textbox(label="Error")], css=css)
35
  iface.launch()