mirror of
https://github.com/mozilla/DeepSpeech.git
synced 2025-10-26 11:19:39 +00:00
23 lines
934 B
Bash
23 lines
934 B
Bash
#!/bin/bash
|
|
|
|
set -xe
|
|
|
|
source $(dirname "$0")/tc-tests-utils.sh
|
|
|
|
aot_model=$1
|
|
|
|
download_material "/tmp/ds" "${aot_model}"
|
|
|
|
phrase_pbmodel_nolm=$(LD_LIBRARY_PATH=/tmp/ds/:$LD_LIBRARY_PATH /tmp/ds/deepspeech /tmp/${model_name} /tmp/LDC93S1.wav /tmp/alphabet.txt)
|
|
assert_correct_ldc93s1 "${phrase_pbmodel_nolm}"
|
|
|
|
phrase_pbmodel_withlm=$(LD_LIBRARY_PATH=/tmp/ds/:$LD_LIBRARY_PATH /tmp/ds/deepspeech /tmp/${model_name} /tmp/LDC93S1.wav /tmp/alphabet.txt /tmp/lm.binary /tmp/trie)
|
|
assert_correct_ldc93s1 "${phrase_pbmodel_withlm}"
|
|
|
|
if [ "${aot_model}" = "--aot" ]; then
|
|
phrase_somodel_nolm=$(LD_LIBRARY_PATH=/tmp/ds/:$LD_LIBRARY_PATH /tmp/ds/deepspeech "" /tmp/LDC93S1.wav /tmp/alphabet.txt)
|
|
phrase_somodel_withlm=$(LD_LIBRARY_PATH=/tmp/ds/:$LD_LIBRARY_PATH /tmp/ds/deepspeech "" /tmp/LDC93S1.wav /tmp/alphabet.txt /tmp/lm.binary /tmp/trie)
|
|
|
|
assert_correct_ldc93s1_somodel "${phrase_somodel_nolm}" "${phrase_somodel_withlm}"
|
|
fi;
|