Spaces:
Build error
Build error
patrickvonplaten
commited on
Commit
·
81017ad
1
Parent(s):
4eef8ac
Update app.py
Browse files
app.py
CHANGED
@@ -14,7 +14,7 @@ def process_audio_file(file):
|
|
14 |
input_values = feature_extractor(data, return_tensors="pt").input_values
|
15 |
return input_values
|
16 |
|
17 |
-
def transcribe(
|
18 |
|
19 |
target_code = target_language.split("(")[-1].split(")")[0]
|
20 |
forced_bos_token_id = MAPPING[target_code]
|
@@ -71,7 +71,7 @@ iface = gr.Interface(
|
|
71 |
outputs="text",
|
72 |
layout="horizontal",
|
73 |
theme="huggingface",
|
74 |
-
title="
|
75 |
description="A simple interface to translate English Speech to 15 possible languages.",
|
76 |
)
|
77 |
iface.launch()
|
|
|
14 |
input_values = feature_extractor(data, return_tensors="pt").input_values
|
15 |
return input_values
|
16 |
|
17 |
+
def transcribe(file, target_language):
|
18 |
|
19 |
target_code = target_language.split("(")[-1].split(")")[0]
|
20 |
forced_bos_token_id = MAPPING[target_code]
|
|
|
71 |
outputs="text",
|
72 |
layout="horizontal",
|
73 |
theme="huggingface",
|
74 |
+
title="XLS-R 300M EN-to-15 Speech Translation",
|
75 |
description="A simple interface to translate English Speech to 15 possible languages.",
|
76 |
)
|
77 |
iface.launch()
|