#1006·wav2letter

使用 Beam 搜索解码器进行解码时出现 ArrayFire 异常 (设备内存不足:101)

作者: abramovi创建于 2022年4月6日更新于 2022年4月17日
标签bug

问题描述 我正在使用 Beam 搜索对 30 分钟的音频文件进行推理,但立即出现以下错误: terminate called after throwing an instance of 'af::exception' what(): ArrayFire Exception (Device out of memory:101): In function af_err af_matmul(void**, af_array, af_array, af_mat_prop, af_mat_prop) In file src/api/c/blas.cpp:237 #### 重现步骤 [请提供重现步骤,如果您的问题需要此步骤:] 我运行的命令如下: !../../build/bin/asr/fl_asr_tutorial_inference_ctc --am_path=am_transformer_ctc_stride3_letters_300Mparams.bin --tokens_path=tokens.txt --lexicon_path=lexicon.txt --lm_path=lm_common_crawl_small_4gram_prun0-6-15_200kvocab.bin --logtostderr=true --sample_rate=16000 --beam_size=50 --beam_size_token=30 --beam_threshold=100 --lm_weight=1.5 --word_score=0 --audio_list=audio.lst 输出如下: `I0406 17:32:38.839179 11262 InferenceCTC.cpp:66] Gflags after parsing --flagfile=; --fromenv=; --tryfromenv=; --undefok=; --tab_completion_columns=80; --tab_completion_word=; --help=false; --helpfull=false; --helpmatch=; --helpon=; --helppackage=false; --helpshort=false; --helpxml=false; --version=false; --am_path=am_transformer_ctc_stride3_letters_300Mparams.bin; --audio_list=audio.lst; --beam_size=50; --beam_size_token=30; --beam_threshold=100; --lexicon_path=lexicon.txt; --lm_path=lm_common_crawl_small_4gram_prun0-6-15_200kvocab.bin; --lm_weight=1.5; --sample_rate=16000; --tokens_path=tokens.txt; --word_score=0; --alsologtoemail=; --alsologtostderr=false; --colorlogtostderr=false; --drop_log_memory=true; --log_backtrace_at=; --log_dir=; --log_link=; --log_prefix=true; --logbuflevel=0; --logbufsecs=30; --logemaillevel=999; --logfile_mode=436; --logmailer=/bin/mail; --logtostderr=true; --max_log_size=1800; --minloglevel=0; --stderrthreshold=2; --stop_logging_if_full_disk=false; --symbolize_stacktrace=true; --v=0; --vmodule=; I0406 17:32:38.839272 11262 InferenceCTC.cpp:89] [Inference tutorial for CTC] Reading acoustic model from am_transformer_ctc_stride3_letters_300Mparams.bin I0406 17:32:40.061904 11262 InferenceCTC.cpp:140] [Inference tutorial for CTC] Network is loaded. I0406 17:32:40.433898 11262 InferenceCTC.cpp:152] [Inference tutorial for CTC] Number of classes/tokens in the network: 29 I0406 17:32:40.433930 11262 InferenceCTC.cpp:155] [Inference tutorial for CTC] Number of words in the lexicon: 200001 I0406 17:32:40.667213 11262 InferenceCTC.cpp:166] [Inference tutorial for CTC] Language model is constructed. I0406 17:32:41.800864 11262 InferenceCTC.cpp:177] [Inference tutorial for CTC] Trie is planted. I0406 17:32:41.801892 11262 InferenceCTC.cpp:196] [Inference tutorial for CTC] Beam search decoder is created

内容来源: flashlight/wav2letter