lojban commited on
Commit
49b5b9a
·
1 Parent(s): fb043b2

add vits links

Browse files
Files changed (1) hide show
  1. app.py +12 -9
app.py CHANGED
@@ -188,7 +188,8 @@ outputs = []
188
  css = """
189
  h1 {font-size:200%;}
190
  h2 {font-size:120%;}
191
- a {color: #0020c5;text-decoration: underline;}
 
192
  img {display: inline-block;height:32px;}
193
  """
194
 
@@ -198,12 +199,13 @@ def conditionally_hide_widgets(voice):
198
  else:
199
  return gr.update(visible=True), gr.update(visible=True), gr.update(visible=True)
200
 
 
 
 
 
201
  with gr.Blocks(css=css) as demo:
202
- title = "<h1>la vitci voksa - <i><img src='/file/assets/jbolanci.png'/>Lojban text-to-speech</i></h1>"
203
  gr.HTML(title)
204
- description = "<h2>VITS & Nix-TTS text-to-speech adapted to Lojban. Join <a href='https://discord.gg/BVm4EYR'>Lojban Discord live chat</a> to discuss further.</h2>"
205
- gr.HTML(description)
206
- article = "<p style='text-align: center'><a href='https://arxiv.org/abs/2106.06103'>Conditional Variational Autoencoder with Adversarial Learning for End-to-End Text-to-Speech</a> | <a href='https://github.com/jaywalnut310/vits'>Github Repo</a></p>"
207
  with gr.Row():
208
  with gr.Column():
209
  input_text = gr.Textbox(lines=4, value=defaults["text"], label="Input text", placeholder="add your text, or click one of the examples to load them")
@@ -228,12 +230,12 @@ with gr.Blocks(css=css) as demo:
228
  voices.change(fn=conditionally_hide_widgets, inputs=voices,outputs=vits_inputs)
229
 
230
  with gr.Column():
231
-
232
- btn = gr.Button("Vocalize")
233
  ipa_block = gr.Textbox(label="International Phonetic Alphabet")
234
- audio = gr.Audio(type="numpy", label="Output audio")
235
-
236
  outputs = [ ipa_block, audio ]
 
 
237
  btn.click(fn=inference, inputs=inputs, outputs=outputs, api_name="cupra")
238
 
239
  examples = list(map(lambda el: el[0:len(el)] + defaults["example"][len(el):], [
@@ -245,5 +247,6 @@ with gr.Blocks(css=css) as demo:
245
  ["We propose VITS, Conditional Variational Autoencoder with Adversarial Learning for End-to-End Text-to-Speech.", "English"],
246
  ]))
247
  gr.Examples(examples, inputs, fn=inference, outputs=outputs, cache_examples=True, run_on_click=True)
 
248
 
249
  demo.launch(server_name="0.0.0.0")
 
188
  css = """
189
  h1 {font-size:200%;}
190
  h2 {font-size:120%;}
191
+ h2 a {color: #0020c5;text-decoration: underline;}
192
+ p a {text-decoration: underline;}
193
  img {display: inline-block;height:32px;}
194
  """
195
 
 
199
  else:
200
  return gr.update(visible=True), gr.update(visible=True), gr.update(visible=True)
201
 
202
+ title = "<h1>la vitci voksa - <i><img src='/file/assets/jbolanci.png'/>Lojban text-to-speech</i></h1>"
203
+ description = "<h2>VITS & Nix-TTS text-to-speech adapted to Lojban. Join <a href='https://discord.gg/BVm4EYR'>Lojban Discord live chat</a> to discuss further.</h2>"
204
+ article = "<p style='text-align: center'><a href='https://arxiv.org/abs/2106.06103'>Conditional Variational Autoencoder with Adversarial Learning for End-to-End Text-to-Speech</a> | <a href='https://github.com/jaywalnut310/vits'>Github Repo</a></p>"
205
+
206
  with gr.Blocks(css=css) as demo:
 
207
  gr.HTML(title)
208
+ gr.HTML(description)
 
 
209
  with gr.Row():
210
  with gr.Column():
211
  input_text = gr.Textbox(lines=4, value=defaults["text"], label="Input text", placeholder="add your text, or click one of the examples to load them")
 
230
  voices.change(fn=conditionally_hide_widgets, inputs=voices,outputs=vits_inputs)
231
 
232
  with gr.Column():
 
 
233
  ipa_block = gr.Textbox(label="International Phonetic Alphabet")
234
+ audio = gr.Audio(type="numpy", label="Output audio")
235
+
236
  outputs = [ ipa_block, audio ]
237
+
238
+ btn = gr.Button("Vocalize")
239
  btn.click(fn=inference, inputs=inputs, outputs=outputs, api_name="cupra")
240
 
241
  examples = list(map(lambda el: el[0:len(el)] + defaults["example"][len(el):], [
 
247
  ["We propose VITS, Conditional Variational Autoencoder with Adversarial Learning for End-to-End Text-to-Speech.", "English"],
248
  ]))
249
  gr.Examples(examples, inputs, fn=inference, outputs=outputs, cache_examples=True, run_on_click=True)
250
+ gr.HTML(article)
251
 
252
  demo.launch(server_name="0.0.0.0")