Spaces:
Running
Running
mrfakename
commited on
Commit
•
64df066
1
Parent(s):
7988d6c
Update app.py
Browse files
app.py
CHANGED
@@ -54,14 +54,14 @@ def run(t, r):
|
|
54 |
if r == 'phonemizer': return phonemizerfunc(t)
|
55 |
if r == 'gruut': return gruut(t)
|
56 |
if r == 'deep_phonemizer': return dp(t)
|
57 |
-
if r == 'g2p_en': return g2pen(t)
|
58 |
if r == 'charsiu (slow)': return docharsiu(t)
|
59 |
return f'Error: Phonemizer {r} not found, please try another Phonemizer and create a Community discussion on HF.'
|
60 |
with gr.Blocks() as demo:
|
61 |
gr.Markdown("# PhonemizerHub")
|
62 |
t = gr.Textbox(label="Text", placeholder="Enter text...", interactive=True)
|
63 |
-
r = gr.Radio(choices=['phonemizer', 'gruut', 'deep_phonemizer', 'g2p_en', 'charsiu (slow)'], value='phonemizer', interactive=True, label='Select a phonemizer')
|
64 |
b = gr.Button("Phonemize")
|
65 |
-
out = gr.Textbox(interactive=
|
66 |
b.click(run, inputs=[t, r], outputs=[out])
|
67 |
demo.queue().launch()
|
|
|
54 |
if r == 'phonemizer': return phonemizerfunc(t)
|
55 |
if r == 'gruut': return gruut(t)
|
56 |
if r == 'deep_phonemizer': return dp(t)
|
57 |
+
if r == 'g2p_en (buggy)': return g2pen(t)
|
58 |
if r == 'charsiu (slow)': return docharsiu(t)
|
59 |
return f'Error: Phonemizer {r} not found, please try another Phonemizer and create a Community discussion on HF.'
|
60 |
with gr.Blocks() as demo:
|
61 |
gr.Markdown("# PhonemizerHub")
|
62 |
t = gr.Textbox(label="Text", placeholder="Enter text...", interactive=True)
|
63 |
+
r = gr.Radio(choices=['phonemizer', 'gruut', 'deep_phonemizer', 'g2p_en (buggy)', 'charsiu (slow)'], value='phonemizer', interactive=True, label='Select a phonemizer')
|
64 |
b = gr.Button("Phonemize")
|
65 |
+
out = gr.Textbox(interactive=False, label="Phonemes")
|
66 |
b.click(run, inputs=[t, r], outputs=[out])
|
67 |
demo.queue().launch()
|