Spaces:
Sleeping
Sleeping
make demo faster
Browse files
app.py
CHANGED
@@ -33,7 +33,7 @@ def inference(wav,data):
|
|
33 |
# Decoding parameters are not included in the model file
|
34 |
lang_prompt_token="<|en|> <|ner|> <|SLURP|>",
|
35 |
prompt_token_file="UniverSLU-17-Task-Specifier/add_tokens-Copy1.txt",
|
36 |
-
beam_size=
|
37 |
ctc_weight=0.0,
|
38 |
penalty=0.1,
|
39 |
nbest=1
|
@@ -60,6 +60,7 @@ def inference(wav,data):
|
|
60 |
lang_prompt_token="<|en|> <|ic|> <|fsc|>",
|
61 |
prompt_token_file="UniverSLU-17-Task-Specifier/add_tokens-Copy1.txt",
|
62 |
ctc_weight=0.0,
|
|
|
63 |
nbest=1
|
64 |
)
|
65 |
nbests = speech2text(speech)
|
@@ -78,6 +79,7 @@ def inference(wav,data):
|
|
78 |
lang_prompt_token="<|en|> <|ic|> <|SNIPS|>",
|
79 |
prompt_token_file="UniverSLU-17-Task-Specifier/add_tokens-Copy1.txt",
|
80 |
ctc_weight=0.0,
|
|
|
81 |
nbest=1
|
82 |
)
|
83 |
nbests = speech2text(speech)
|
@@ -93,7 +95,7 @@ def inference(wav,data):
|
|
93 |
lang_prompt_token="<|nl|> <|scr|> <|grabo_scr|>",
|
94 |
prompt_token_file="UniverSLU-17-Task-Specifier/add_tokens-Copy1.txt",
|
95 |
ctc_weight=0.0,
|
96 |
-
beam_size=
|
97 |
nbest=1
|
98 |
)
|
99 |
nbests = speech2text(speech)
|
@@ -289,7 +291,7 @@ def inference(wav,data):
|
|
289 |
lang_prompt_token="<|en|> <|sp|> <|STOP|>",
|
290 |
prompt_token_file="UniverSLU-17-Task-Specifier/add_tokens-Copy1.txt",
|
291 |
ctc_weight=0.0,
|
292 |
-
beam_size=
|
293 |
penalty=0.1,
|
294 |
nbest=1
|
295 |
)
|
|
|
33 |
# Decoding parameters are not included in the model file
|
34 |
lang_prompt_token="<|en|> <|ner|> <|SLURP|>",
|
35 |
prompt_token_file="UniverSLU-17-Task-Specifier/add_tokens-Copy1.txt",
|
36 |
+
beam_size=1,
|
37 |
ctc_weight=0.0,
|
38 |
penalty=0.1,
|
39 |
nbest=1
|
|
|
60 |
lang_prompt_token="<|en|> <|ic|> <|fsc|>",
|
61 |
prompt_token_file="UniverSLU-17-Task-Specifier/add_tokens-Copy1.txt",
|
62 |
ctc_weight=0.0,
|
63 |
+
beam_size=1,
|
64 |
nbest=1
|
65 |
)
|
66 |
nbests = speech2text(speech)
|
|
|
79 |
lang_prompt_token="<|en|> <|ic|> <|SNIPS|>",
|
80 |
prompt_token_file="UniverSLU-17-Task-Specifier/add_tokens-Copy1.txt",
|
81 |
ctc_weight=0.0,
|
82 |
+
beam_size=1,
|
83 |
nbest=1
|
84 |
)
|
85 |
nbests = speech2text(speech)
|
|
|
95 |
lang_prompt_token="<|nl|> <|scr|> <|grabo_scr|>",
|
96 |
prompt_token_file="UniverSLU-17-Task-Specifier/add_tokens-Copy1.txt",
|
97 |
ctc_weight=0.0,
|
98 |
+
beam_size=1,
|
99 |
nbest=1
|
100 |
)
|
101 |
nbests = speech2text(speech)
|
|
|
291 |
lang_prompt_token="<|en|> <|sp|> <|STOP|>",
|
292 |
prompt_token_file="UniverSLU-17-Task-Specifier/add_tokens-Copy1.txt",
|
293 |
ctc_weight=0.0,
|
294 |
+
beam_size=1,
|
295 |
penalty=0.1,
|
296 |
nbest=1
|
297 |
)
|