ValueError: Scorer initialization failed with error code 1

Im trying to study the project deepspeech , but when i run ‘’./bin/run-ldc93s1.sh" , it return err : ValueError: Scorer initialization failed with error code 1, anybody met the same problem? i will appreciate grately for your warmheart help. details as following:
File “DeepSpeech.py”, line 877, in main
test()
File “DeepSpeech.py”, line 635, in test
samples = evaluate(FLAGS.test_files.split(’,’), create_model)
File “/home/zhangp/tmp/deepspeech-venv/DeepSpeech/evaluate.py”, line 49, in evaluate
FLAGS.scorer_path, Config.alphabet)
File “/home/zhangp/tmp/deepspeech-venv/lib/python3.6/site-packages/ds_ctcdecoder/init.py”, line 36, in init
raise ValueError(‘Scorer initialization failed with error code {}’.format(err))
ValueError: Scorer initialization failed with error code 1

1 Like

It means the scorer hasn’t been installed. You need to install git-lfs and do git lfs pull to download it.

Thanks for your warmheart answer my issue , im new to tensorflow , i `ve followed the steps of the tutorial :“https://github.com/mozilla/DeepSpeech/blob/master/doc/TRAINING.rst#training-a-model”, and i have install git-lfs , could you please tell me how to install scorer? and what the code of install it? thank you!

And i haved installes ds-ctcdecoder :follow is all i have installed

(deepspeech-venv) zhangp@zhangp:~/tmp/deepspeech-venv/DeepSpeech$ pip list
Package Version


absl-py 0.9.0
astor 0.8.1
attrdict 2.0.1
audioread 2.1.8
beautifulsoup4 4.8.2
bs4 0.0.1
certifi 2019.11.28
cffi 1.14.0
chardet 3.0.4
decorator 4.4.2
deepspeech 0.6.1
ds-ctcdecoder 0.7.0a2
gast 0.2.2
google-pasta 0.1.8
grpcio 1.27.2
h5py 2.10.0
idna 2.9
joblib 0.14.1
Keras-Applications 1.0.8
Keras-Preprocessing 1.1.0
librosa 0.7.2
llvmlite 0.31.0
Markdown 3.2.1
numba 0.48.0
numpy 1.18.1
opt-einsum 3.1.0
pandas 1.0.1
pip 20.0.2
pkg-resources 0.0.0
progressbar2 3.47.0
protobuf 3.11.3
pycparser 2.19
python-dateutil 2.8.1
python-utils 2.3.0
pytz 2019.3
pyxdg 0.26
requests 2.23.0
resampy 0.2.2
scikit-learn 0.22.2
scipy 1.4.1
semver 2.9.1
setuptools 45.2.0
six 1.14.0
SoundFile 0.10.3.post1
soupsieve 2.0
sox 1.3.7
tensorboard 1.15.0
tensorflow-estimator 1.15.1
tensorflow-gpu 1.15.0
termcolor 1.1.0
urllib3 1.25.8
Werkzeug 1.0.0
wheel 0.34.2
wrapt 1.12.0

Please re-clone the project after that step. If you did clone before git-lfs was setup, you need to manually call git lfs update or git lfs checkout

Make sure when running DeepSpeech.py that the flag “–score_path” directs to the scorer.
Default is “…/DeepSpeech/data/lm/kenlm.scorer”

Why do we need to re-clone the project? Clone the project, then git lfs install, git lfs pull, reclone, that’s quite strange. For some reason it didn’t help when I specified reclone in my Dockerfile, I need to reclone manually every time I run a container and that takes a lot of time
It used to work without git lfs install in 0.6.1

because it’s simpler and I don’t remember the git lfs magic to properly fetch data.

No idea what you are talking about. Make sure git-lfs is installed prior to the git clone, that should be enough.

No, git lfs is here since a very long time, we made no change to that.

1 Like

Yeah, that works. I thought I also need to run git lfs pull
Thanks