seawolf2357 commited on
Commit
7d7260f
·
verified ·
1 Parent(s): 95ae26b

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +23 -28
app.py CHANGED
@@ -220,37 +220,32 @@ def main():
220
  denoiser.eval()
221
 
222
 
223
- config_components = [
224
- gr.Slider(0, 1, 0.333, label="TTV Temperature"),
225
- gr.Slider(0, 1, 0.333, label="VC Temperature"),
226
- gr.Slider(0, 1, 1.0, label="Duration Temperature"),
227
- gr.Slider(0.5, 2, 1.0, label="Duration Length"),
228
- gr.Slider(0, 1, 0, label="Denoise Ratio"),
229
- gr.Slider(0, 9999, 1111, label="Random Seed")
230
- ]
231
-
232
- config_section = gr.Collapsible("Advanced Configuration", config_components)
233
-
234
-
235
- demo_play = gr.Interface(fn = tts,
236
- inputs = [gr.Textbox(max_lines=6, label="Input Text", value="I am Taylor Swif. Be the change that you wish to see in the world", info="Up to 200 characters"),
237
- gr.Audio(type='filepath', value="./example/TaylorSwift.wav"),
238
- config_section
239
  ],
240
- outputs = 'audio',
241
- title = 'ZeroShot Voice',
242
- description = '''<div>
243
- <p style="text-align: left"> ZeroShot Voice is a 'Zero shot' speech synthesis model.</p>
244
- </div>''',
245
  examples=[["I am Dasvader of Starwars. I am your Father. Be the change that you wish to see in the world", "./example/dasvader.wav", 0.333,0.333, 1.0, 1.0, 0, 1111],
246
- ["I am Taylor Swif. Be the change that you wish to see in the world", "./example/TaylorSwift.wav", 0.333,0.667, 1.0, 1.0, 0, 1790],
247
- ["I am Marlon Brando of God Father. Be the change that you wish to see in the world", "./example/MarlonBrando.wav", 0.333,0.333, 1.0, 1.0, 0, 1111],
248
- ["I am Obama. Be the change that you wish to see in the world", "./example/obama.wav", 0.333,0.333, 1.0, 1.0, 0, 1111],
249
- ["I am Trump. Be the change that you wish to see in the world", "./example/trump.wav", 0.333,0.333, 1.0, 1.0, 0, 1111],
250
- ],
251
- css=css
252
  )
253
  demo_play.launch()
254
 
255
  if __name__ == '__main__':
256
- main()
 
220
  denoiser.eval()
221
 
222
 
223
+ demo_play = gr.Interface(fn=tts,
224
+ inputs=[
225
+ gr.Textbox(max_lines=6, label="Input Text", value="I am Taylor Swift. Be the change that you wish to see in the world", info="Up to 200 characters"),
226
+ gr.Audio(type='filepath', value="./example/TaylorSwift.wav"),
227
+ gr.Section("Advanced Configuration", [
228
+ gr.Slider(0, 1, 0.333, label="TTV Temperature"),
229
+ gr.Slider(0, 1, 0.333, label="VC Temperature"),
230
+ gr.Slider(0, 1, 1.0, label="Duration Temperature"),
231
+ gr.Slider(0.5, 2, 1.0, label="Duration Length"),
232
+ gr.Slider(0, 1, 0, label="Denoise Ratio"),
233
+ gr.Slider(0, 9999, 1111, label="Random Seed")
234
+ ])
 
 
 
 
235
  ],
236
+ outputs='audio',
237
+ title='ZeroShot Voice',
238
+ description='''<div>
239
+ <p style="text-align: left"> ZeroShot Voice is a 'Zero shot' speech synthesis model.</p>
240
+ </div>''',
241
  examples=[["I am Dasvader of Starwars. I am your Father. Be the change that you wish to see in the world", "./example/dasvader.wav", 0.333,0.333, 1.0, 1.0, 0, 1111],
242
+ ["I am Taylor Swift. Be the change that you wish to see in the world", "./example/TaylorSwift.wav", 0.333,0.667, 1.0, 1.0, 0, 1790],
243
+ ["I am Marlon Brando of God Father. Be the change that you wish to see in the world", "./example/MarlonBrando.wav", 0.333,0.333, 1.0, 1.0, 0, 1111],
244
+ ["I am Obama. Be the change that you wish to see in the world", "./example/obama.wav", 0.333,0.333, 1.0, 1.0, 0, 1111],
245
+ ["I am Trump. Be the change that you wish to see in the world", "./example/trump.wav", 0.333,0.333, 1.0, 1.0, 0, 1111]],
246
+ css=css
 
247
  )
248
  demo_play.launch()
249
 
250
  if __name__ == '__main__':
251
+ main()