From a4c4e0df72b369365839f9a8ba6ff55fc7199770 Mon Sep 17 00:00:00 2001 From: Zhaoheng Ni Date: Fri, 1 Apr 2022 20:39:49 +0100 Subject: [PATCH] fix args in ctc decoding --- examples/asr/librispeech_ctc_decoder/inference.py | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/examples/asr/librispeech_ctc_decoder/inference.py b/examples/asr/librispeech_ctc_decoder/inference.py index af08dbb05a..0790722e1f 100644 --- a/examples/asr/librispeech_ctc_decoder/inference.py +++ b/examples/asr/librispeech_ctc_decoder/inference.py @@ -35,14 +35,14 @@ def run_inference(args): lexicon=lexicon_file, tokens=tokens, lm=kenlm_file, - nbest=1, - beam_size=1500, - beam_size_token=None, - beam_threshold=50, + nbest=args.nbest, + beam_size=args.beam_size, + beam_size_token=args.beam_size_token, + beam_threshold=args.beam_threshold, lm_weight=args.lm_weight, word_score=args.word_score, - unk_score=float("-inf"), - sil_score=0, + unk_score=args.unk_score, + sil_score=args.sil_score, log_add=False, )