tonytz commited on
Commit
1921a11
1 Parent(s): e4d4362

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +3 -3
app.py CHANGED
@@ -2,8 +2,8 @@ import gradio as gr
2
  from gtts import gTTS
3
  import os
4
 
5
- def swahiliTTs(mytext):
6
- obj = gTTS(text=mytext, lang="sw", slow=False)
7
  obj.save("demo.mp3")
8
  return "demo.mp3"
9
 
@@ -20,7 +20,7 @@ iface = gr.Interface(fn = swahiliTTs,
20
  description = 'A simple application to convert Swahili text into audio speech. Type your Swahili text',
21
  article =
22
  '''<div>
23
- <p style="text-align: center"> All you need to do is to type Swahili and hit submit, then wait for compiling. After that click on Play/Pause to listing to the audio. The audio is saved in an mp3 format.</p>
24
  </div>''',
25
  examples=examples
26
  )
 
2
  from gtts import gTTS
3
  import os
4
 
5
+ def swahiliTTs(swahilitext):
6
+ obj = gTTS(text=swahilitext, lang="sw", slow=False)
7
  obj.save("demo.mp3")
8
  return "demo.mp3"
9
 
 
20
  description = 'A simple application to convert Swahili text into audio speech. Type your Swahili text',
21
  article =
22
  '''<div>
23
+ <p style="text-align: center"> All you need to do is to type Swahili text and hit submit, then wait for compiling. After that click on Play/Pause to listing to the audio. The audio is saved in an mp3 format.</p>
24
  </div>''',
25
  examples=examples
26
  )