Spaces:
Runtime error
Runtime error
Update app.py
Browse files
app.py
CHANGED
@@ -11,8 +11,12 @@ description = "Gradio demo for finetuned Wav2Vec2 model on a custom dataset to p
|
|
11 |
|
12 |
|
13 |
def classify_audio(audio):
|
14 |
-
|
15 |
-
|
|
|
|
|
|
|
|
|
16 |
|
17 |
|
18 |
iface = gr.Interface(
|
|
|
11 |
|
12 |
|
13 |
def classify_audio(audio):
|
14 |
+
preds = pipe(audio)
|
15 |
+
outputs = {}
|
16 |
+
for p in preds:
|
17 |
+
outputs[p["label"]] = p["score"]
|
18 |
+
return outputs
|
19 |
+
|
20 |
|
21 |
|
22 |
iface = gr.Interface(
|