RafaG commited on
Commit
a6b6441
1 Parent(s): fb76add

Update app_colab.py

Browse files
Files changed (1) hide show
  1. app_colab.py +9 -9
app_colab.py CHANGED
@@ -1554,8 +1554,8 @@ with gr.Blocks(theme=gr.themes.Default(primary_hue="green", secondary_hue="blue"
1554
  with gr.Column():
1555
  with gr.Row():
1556
  dropbox = gr.File(label="Arraste seu arquivo de áudio e clique em atualizar.")
1557
- with gr.Row():
1558
- record_button=gr.Audio(source="microphone", label="Ou você pode usar seu microfone!", type="filepath")
1559
  with gr.Row():
1560
  input_audio0 = gr.Dropdown(
1561
  label="2.Escolha o arquivo de áudio",
@@ -1565,8 +1565,8 @@ with gr.Blocks(theme=gr.themes.Default(primary_hue="green", secondary_hue="blue"
1565
  dropbox.upload(fn=save_to_wav2, inputs=[dropbox], outputs=[input_audio0])
1566
  dropbox.upload(fn=change_choices2, inputs=[], outputs=[input_audio0])
1567
  refresh_button2 = gr.Button("Atualizar", variant="primary", size='sm')
1568
- record_button.change(fn=save_to_wav, inputs=[record_button], outputs=[input_audio0])
1569
- record_button.change(fn=change_choices2, inputs=[], outputs=[input_audio0])
1570
  with gr.Row():
1571
  with gr.Accordion('ElevenLabs / Google TTS', open=False):
1572
  with gr.Column():
@@ -1576,18 +1576,18 @@ with gr.Blocks(theme=gr.themes.Default(primary_hue="green", secondary_hue="blue"
1576
  with gr.Column():
1577
  tfs = gr.Textbox(label="Digite o seu Texto", interactive=True, value="Isso é um teste.")
1578
  tts_button = gr.Button(value="Falar")
1579
- tts_button.click(fn=elevenTTS, inputs=[api_box,tfs, elevenid, lang], outputs=[record_button, input_audio0])
1580
  with gr.Row():
1581
  with gr.Accordion('Wav2Lip', open=False, visible=False):
1582
  with gr.Row():
1583
  size = gr.Radio(label='Resolution:',choices=['Half','Full'])
1584
- face = gr.UploadButton("Upload A Character",type='file')
1585
  faces = gr.Dropdown(label="OR Choose one:", choices=['None','Ben Shapiro','Andrew Tate'])
1586
  with gr.Row():
1587
  preview = gr.Textbox(label="Status:",interactive=False)
1588
  face.upload(fn=success_message,inputs=[face], outputs=[preview, faces])
1589
  with gr.Row():
1590
- animation = gr.Video(type='filepath')
1591
  refresh_button2.click(fn=change_choices2, inputs=[], outputs=[input_audio0, animation])
1592
  with gr.Row():
1593
  animate_button = gr.Button('Animate')
@@ -1604,7 +1604,7 @@ with gr.Blocks(theme=gr.themes.Default(primary_hue="green", secondary_hue="blue"
1604
  ilariaid=gr.Dropdown(label="Voz:", choices=ilariavoices, value="Brazilian-Antonio- (Male)")
1605
  ilariatext = gr.Textbox(label="Digite o seu Texto", interactive=True, value="Isso é um teste.")
1606
  ilariatts_button = gr.Button(value="Falar")
1607
- ilariatts_button.click(fn=ilariaTTS, inputs=[ilariatext, ilariaid], outputs=[record_button, input_audio0])
1608
 
1609
  #with gr.Column():
1610
  with gr.Accordion("Configuração de Index", open=False):
@@ -2138,5 +2138,5 @@ with gr.Blocks(theme=gr.themes.Default(primary_hue="green", secondary_hue="blue"
2138
  Feito com 💖 por Ilaria | Traduzido por Rafael Godoy | Suporte no servidor do Discord AI HUB Brasil ou Global
2139
  """
2140
  )
2141
- app.queue(concurrency_count=511, max_size=1022).launch(share=True, quiet=False)
2142
  #endregion
 
1554
  with gr.Column():
1555
  with gr.Row():
1556
  dropbox = gr.File(label="Arraste seu arquivo de áudio e clique em atualizar.")
1557
+ # with gr.Row():
1558
+ # record_button=gr.Audio(source="microphone", label="Ou você pode usar seu microfone!", type="filepath")
1559
  with gr.Row():
1560
  input_audio0 = gr.Dropdown(
1561
  label="2.Escolha o arquivo de áudio",
 
1565
  dropbox.upload(fn=save_to_wav2, inputs=[dropbox], outputs=[input_audio0])
1566
  dropbox.upload(fn=change_choices2, inputs=[], outputs=[input_audio0])
1567
  refresh_button2 = gr.Button("Atualizar", variant="primary", size='sm')
1568
+ # record_button.change(fn=save_to_wav, inputs=[record_button], outputs=[input_audio0])
1569
+ # record_button.change(fn=change_choices2, inputs=[], outputs=[input_audio0])
1570
  with gr.Row():
1571
  with gr.Accordion('ElevenLabs / Google TTS', open=False):
1572
  with gr.Column():
 
1576
  with gr.Column():
1577
  tfs = gr.Textbox(label="Digite o seu Texto", interactive=True, value="Isso é um teste.")
1578
  tts_button = gr.Button(value="Falar")
1579
+ tts_button.click(fn=elevenTTS, inputs=[api_box,tfs, elevenid, lang], outputs=[input_audio0])
1580
  with gr.Row():
1581
  with gr.Accordion('Wav2Lip', open=False, visible=False):
1582
  with gr.Row():
1583
  size = gr.Radio(label='Resolution:',choices=['Half','Full'])
1584
+ face = gr.UploadButton("Upload A Character",type='filepath')
1585
  faces = gr.Dropdown(label="OR Choose one:", choices=['None','Ben Shapiro','Andrew Tate'])
1586
  with gr.Row():
1587
  preview = gr.Textbox(label="Status:",interactive=False)
1588
  face.upload(fn=success_message,inputs=[face], outputs=[preview, faces])
1589
  with gr.Row():
1590
+ animation = gr.Video()
1591
  refresh_button2.click(fn=change_choices2, inputs=[], outputs=[input_audio0, animation])
1592
  with gr.Row():
1593
  animate_button = gr.Button('Animate')
 
1604
  ilariaid=gr.Dropdown(label="Voz:", choices=ilariavoices, value="Brazilian-Antonio- (Male)")
1605
  ilariatext = gr.Textbox(label="Digite o seu Texto", interactive=True, value="Isso é um teste.")
1606
  ilariatts_button = gr.Button(value="Falar")
1607
+ ilariatts_button.click(fn=ilariaTTS, inputs=[ilariatext, ilariaid], outputs=[input_audio0])
1608
 
1609
  #with gr.Column():
1610
  with gr.Accordion("Configuração de Index", open=False):
 
2138
  Feito com 💖 por Ilaria | Traduzido por Rafael Godoy | Suporte no servidor do Discord AI HUB Brasil ou Global
2139
  """
2140
  )
2141
+ app.queue().launch(share=True, quiet=False)
2142
  #endregion