Spaces:
Sleeping
Sleeping
dlaiu
commited on
Commit
·
a01aab6
1
Parent(s):
e701383
changed to pitch processing
Browse files
app.py
CHANGED
@@ -1,7 +1,18 @@
|
|
1 |
import gradio as gr
|
2 |
|
3 |
-
def greet(name):
|
4 |
-
|
5 |
|
6 |
-
demo = gr.Interface(fn=greet, inputs="text", outputs="text")
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
7 |
demo.launch()
|
|
|
|
1 |
import gradio as gr
|
2 |
|
3 |
+
# def greet(name):
|
4 |
+
# return "Hello " + name + "!!"
|
5 |
|
6 |
+
# demo = gr.Interface(fn=greet, inputs="text", outputs="text")
|
7 |
+
# demo.launch()
|
8 |
+
|
9 |
+
import parselmouth
|
10 |
+
|
11 |
+
def get_pitch(audio_file):
|
12 |
+
sound = parselmouth.Sound(audio_file)
|
13 |
+
pitch = sound.to_pitch()
|
14 |
+
return pitch
|
15 |
+
|
16 |
+
demo = gr.Interface(fn=get_pitch, inputs="audio", outputs="text")
|
17 |
demo.launch()
|
18 |
+
|