Patt commited on
Commit
fbf21da
·
1 Parent(s): 121157e

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +6 -17
app.py CHANGED
@@ -1,13 +1,3 @@
1
- # -*- coding: utf-8 -*-
2
- """Test deploying model on huggingface space.ipynb
3
-
4
- Automatically generated by Colaboratory.
5
-
6
- Original file is located at
7
- https://colab.research.google.com/drive/1VRB3YKw0bl47Lp_CuxXwyCsU9JGXq3sY
8
- """
9
-
10
-
11
  import gradio as gr
12
  from transformers import pipeline
13
 
@@ -19,12 +9,11 @@ def translate(text):
19
 
20
 
21
 
22
- description = "Arabic-English translation machine"
23
- title = "Translate"
24
-
25
-
26
- interface = gr.Interface(fn=translate, inputs="text", outputs=["text"],
27
- description=description)
28
 
29
- interface.launch()
30
 
 
 
 
 
 
 
 
 
 
 
 
1
  import gradio as gr
2
  from transformers import pipeline
3
 
 
9
 
10
 
11
 
12
+ interface = gr.Interface(fn=translate,
13
+ inputs="text",
14
+ outputs=["text"],
15
+ title = "Translator",
16
+ description="Arabic-English translation machine")
 
17
 
18
+ interface.launch(inline=False)
19