mirror of
https://github.com/k2-fsa/icefall.git
synced 2025-09-18 13:34:20 +00:00
minor bug fixes for existing scripts
This commit is contained in:
parent
91044348bb
commit
14f0cb5977
@ -412,7 +412,7 @@ def main():
|
||||
s = "\n"
|
||||
for filename, hyp in zip(params.sound_files, hyps):
|
||||
words = " ".join(hyp)
|
||||
words = words.replace("▁", " ").strip()
|
||||
words = words.replace("▁", "").strip()
|
||||
s += f"{filename}:\n{words}\n\n"
|
||||
logging.info(s)
|
||||
|
||||
|
@ -274,7 +274,7 @@ def main():
|
||||
params.update(vars(args))
|
||||
|
||||
token_table = k2.SymbolTable.from_file(params.tokens)
|
||||
params.vocab_size = num_tokens(token_table)
|
||||
params.vocab_size = num_tokens(token_table) + 1 # +1 for blank
|
||||
params.blank_id = token_table["<blk>"]
|
||||
assert params.blank_id == 0
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user