Error during evaluate required positional argument: 'alphabet'

I have this output

I Early stop triggered as (for last 4 steps) validation loss: 153.417343 with standard deviation: 1.086464 and mean: 147.303814
I FINISHED optimization in 19:13:26.734802
Traceback (most recent call last):
  File "./", line 969, in <module>
  File "/home/adrian/.local/lib/python3.6/site-packages/absl/", line 299, in run
    _run_main(main, args)
  File "/home/adrian/.local/lib/python3.6/site-packages/absl/", line 250, in _run_main
  File "./", line 946, in main
  File "./", line 685, in test
    samples = evaluate(FLAGS.test_files.split(','), create_model, try_loading)
  File "/home/adrian/DeepSpeech/", line 47, in evaluate
    FLAGS.scorer_path, Config.alphabet)
TypeError: __init__() missing 1 required positional argument: 'alphabet'

I execute this

./ --train_files ./../clips/train.csv --test_files ./../clips/test.csv --dev_files ./../clips/dev.csv --train_batch_size 1 --dev_batch_size 1 --test_batch_size 1 --n_hidden 100 --early_stop True --export_dir ./../modeles_export --checkpoint_dir ./../modeles_export --alphabet_config_path ./../alphabet.txt --export_tflite ./../modeles_tflite --export_language ./../es/ --alphabet ./../alphabet.txt

Thanks for helping

Please have a look at --helpfull and documentation, this should be --alphabet_config_path, which you already pass before. So why have it twice ?

As well, this is wrong, it should just be a string for the name of the language.

Sorry @lissyx “–export_language ./…/es/” this was added on my last test but it was a mistake, I executed this::

python3 ./ --train_files ./../clips/train.csv --test_files ./../clips/test.csv --dev_files ./../clips/dev.csv --train_batch_size 1 --dev_batch_size 1 --test_batch_size 1 --n_hidden 100 --early_stop True --export_dir ./../modeles_export --checkpoint_dir ./../modeles_export --alphabet_config_path ./../alphabet.txt --export_tflite ./../modeles_tflite --export_language ./../es/

Your error is weird. What version are you running, please ?

Are you sure this is correct, readable, etc. ?

These are my versions:
Ubuntu 18.04
Python 3.7.4
DeepSpeech 0.6.1

No local change, please ?

Sorry I dont understand you, sorry!

@lissyx What versions do you recommend to train my own model in Spanish?

I want to ensure you have not changed anything to our code …

The latest stable or master, depending on you.

I don’t see ds_ctcdecoder, have you properly installed it according to the documentation ?

Yes, ds-ctcdecoder (0.7.0a1)

So yeah, that is already not good. If you have 0.6.1 checkout, you should use 0.6.1 decoder.

Thanks @lissyx !! I will try to reinstall everything again with the latest versions this weekend and I share the result. I find the alignment of the versions very complicated for everything to work Thanks!!Thank you very much for your time!!

It should all be very well simple if you read the documentation, so please file issues or send PR to make the documentation better.

Hey guys, I’m also running into this same error using the same command with the proper --alphabet_config_path argument to the correct path. My versions are nearly identical as well…

macOS Catalina 10.15.2
Python 3.7.6
DeepSpeech 0.6.1

I also had ds-ctcdecoder 0.7.0a1 installed so I uninstalled it and reinstalled running the command pip3 install $(python3 util/ --decoder) with the version set to 0.6.1 and I get the following error:

Collecting ds-ctcdecoder==0.6.1
ERROR: HTTP error 404 while getting https://community-
ERROR: Could not install requirement ds-ctcdecoder==0.6.1 from because of error 404 Client Error: Not Found for url:
ERROR: Could not install requirement ds-ctcdecoder==0.6.1 from because of HTTP error 404 Client Error: Not Found for url: for URL

I’m kind of a noob when it comes to python and package installations so I’m assuming that either my formatting is off or there isn’t a current version being hosted that matches the version number of DeepSpeech. Thank you for any help.

Edit: Ok, I realized that the url was wrong. So I’m now using ds-ctcdecoder 0.6.1 and I’m getting this error:

DeepSpeech version (0.7.0-alpha.1) requires CTC decoder to expose version. Please upgrade the ds_ctcdecoder package to version 0.7.0-alpha.1

I’m not really sure what to do next. pip list shows that my version of deepspeech is 0.6.1 so I must be missing something.

It doesn’t look like you have checked out the 0.6.1 version of the sources. Please make sure you are using the 0.6.1 version of the sources.

Ok, so I pulled down the latest changes from master, and decided to upgrade everything to the latest version (0.7.0-alpha.2) and now I’m getting a new error:

ValueError: Scorer initialization failed with error code 1

Anybody else experiencing this?

Why? Please stick to a stable release or be prepared to follow the development process close enough to see the changes happening. The scorer format and generation process has changed recently on master as part of our API polish work so you’ll need to make sure that’s correct on your side.