Skip to content

Commit

Permalink
Merge pull request #140 from lissyx/fixes-0.5.1
Browse files Browse the repository at this point in the history
Fixes 0.5.1
  • Loading branch information
lissyx authored Aug 26, 2020
2 parents 5ab025a + 23e16fc commit 35b7828
Show file tree
Hide file tree
Showing 5 changed files with 18 additions and 13 deletions.
3 changes: 3 additions & 0 deletions DeepSpeech/Dockerfile.train
Original file line number Diff line number Diff line change
Expand Up @@ -173,6 +173,9 @@ RUN patch -p1 < corpora.patch
# Avoid "error: pandas 1.1.0 is installed but pandas==1.0.5 is required by {'modin'}"
RUN pip install pandas==1.0.5

# error: parso 0.8.0 is installed but parso<0.8.0,>=0.7.0 is required by {'jedi'}
RUN pip install parso==0.7.0

RUN python setup.py install

WORKDIR $HOMEDIR
Expand Down
20 changes: 10 additions & 10 deletions DeepSpeech/build_lm.sh
Original file line number Diff line number Diff line change
Expand Up @@ -18,8 +18,7 @@ popd

pushd $HOME/ds/

if [ ! -f "/mnt/lm/kenlm.scorer" ]; then

if [ ! -f "/mnt/lm/lm.binary" ]; then
python data/lm/generate_lm.py \
--input_txt /mnt/extracted/sources_lm.txt \
--output_dir /mnt/lm/ \
Expand All @@ -31,15 +30,16 @@ pushd $HOME/ds/
--binary_a_bits 255 \
--binary_q_bits 8 \
--binary_type trie

./generate_scorer_package \
--alphabet /mnt/models/alphabet.txt \
--lm /mnt/lm/lm.binary \
--vocab /mnt/lm/vocab-${LM_TOP_K}.txt \
--package /mnt/lm/kenlm.scorer \
--default_alpha ${LM_ALPHA} \
--default_beta ${LM_BETA}
fi;

./generate_scorer_package \
--alphabet /mnt/models/alphabet.txt \
--lm /mnt/lm/lm.binary \
--vocab /mnt/lm/vocab-${LM_TOP_K}.txt \
--package /mnt/lm/kenlm.scorer \
--default_alpha ${LM_ALPHA} \
--default_beta ${LM_BETA}

popd

if [ "${ENGLISH_COMPATIBLE}" = "1" ]; then
Expand Down
2 changes: 1 addition & 1 deletion DeepSpeech/fr/metadata.sh
Original file line number Diff line number Diff line change
Expand Up @@ -9,5 +9,5 @@ export METADATA_CONTACT_INFO="https://discourse.mozilla.org/c/voice/fr"
export METADATA_LICENSE="MIT-0"
export METADATA_LANGUAGE="fr-FR"
export METADATA_MIN_DS_VERSION="0.7"
export METADATA_MAX_DS_VERSION="0.8"
export METADATA_MAX_DS_VERSION="0.9"
export METADATA_DESCRIPTION="A free and re-usable French model for DeepSpeech"
4 changes: 2 additions & 2 deletions DeepSpeech/package.sh
Original file line number Diff line number Diff line change
Expand Up @@ -7,13 +7,13 @@ pushd /mnt
if [ ! -f "model_tensorflow_fr.tar.xz" ]; then
tar -cf - \
-C /mnt/models/ output_graph.pbmm alphabet.txt \
-C /mnt/lm/ lm.binary trie | xz -T0 > model_tensorflow_fr.tar.xz
-C /mnt/lm/ kenlm.scorer trie | xz -T0 > model_tensorflow_fr.tar.xz
fi;

if [ ! -f "model_tflite_fr.tar.xz" ]; then
tar -cf - \
-C /mnt/models/ output_graph.tflite alphabet.txt \
-C /mnt/lm/ lm.binary trie | xz -T0 > model_tflite_fr.tar.xz
-C /mnt/lm/ kenlm.scorer trie | xz -T0 > model_tflite_fr.tar.xz
fi;

if [ ! -f "checkpoint_fr.tar.xz" ]; then
Expand Down
2 changes: 2 additions & 0 deletions DeepSpeech/run.sh
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,8 @@ set -xe
THIS=$(dirname "$0")
export PATH=${THIS}:${THIS}/${MODEL_LANGUAGE}:$PATH

export TF_CUDNN_RESET_RND_GEN_STATE=1

env

checks.sh
Expand Down

0 comments on commit 35b7828

Please sign in to comment.