Spaces:
Running
Running
admin
commited on
Commit
·
b6b77a2
1
Parent(s):
dfca8bb
upd audio label
Browse files
app.py
CHANGED
|
@@ -122,6 +122,7 @@ def infer(wav_path: str, log_name: str, folder_path=TEMP_DIR):
|
|
| 122 |
|
| 123 |
try:
|
| 124 |
model = EvalNet(log_name, len(TRANSLATE)).model
|
|
|
|
| 125 |
except Exception as e:
|
| 126 |
return None, f"{e}"
|
| 127 |
|
|
@@ -155,7 +156,7 @@ if __name__ == "__main__":
|
|
| 155 |
gr.Interface(
|
| 156 |
fn=infer,
|
| 157 |
inputs=[
|
| 158 |
-
gr.Audio(label="上传录音 Upload a recording", type="filepath"),
|
| 159 |
gr.Dropdown(
|
| 160 |
choices=models, label="选择模型 Select a model", value=models[0]
|
| 161 |
),
|
|
|
|
| 122 |
|
| 123 |
try:
|
| 124 |
model = EvalNet(log_name, len(TRANSLATE)).model
|
| 125 |
+
|
| 126 |
except Exception as e:
|
| 127 |
return None, f"{e}"
|
| 128 |
|
|
|
|
| 156 |
gr.Interface(
|
| 157 |
fn=infer,
|
| 158 |
inputs=[
|
| 159 |
+
gr.Audio(label="上传录音 Upload a recording (>40dB)", type="filepath"),
|
| 160 |
gr.Dropdown(
|
| 161 |
choices=models, label="选择模型 Select a model", value=models[0]
|
| 162 |
),
|