CreateModel failed with error code 12288

I have downloaded deepspeech model from

https://github.com/mozilla/DeepSpeech/releases/download/v0.5.1/deepspeech-0.5.1-models.tar.gz
tar xvfz deepspeech-0.5.1-models.tar.gz

On checking the version of deepspeech downloaded; deepspeech - v0.6.0-alpha.5-0-g5fa6d23 ; tensorflow - v1.14.0-14-g1aad02a78e

On running the predict function i am getting an error- CreateModel failed with error code 12288.

Using the following parameters -
N_FEATURES = 25
N_CONTEXT = 9
BEAM_WIDTH = 500

Where am i going wrong?

1 Like

Welcome to the forums @adesara.amit :slightly_smiling_face:

I could be wrong (what you’ve written about what you’ve done isn’t totally clear to me) but it looks like you installed from master. You’d need to install from the checkpoint for the last full release (ie 0.5.1) if you want to use the pre-trained model (which only exists for 0.5.1 and before)

1 Like

Hey,

I am new to deepspeech hence the issues. followed the below process to install

a) pip install deepspeech
b) wget https://github.com/mozilla/DeepSpeech/releases/download/v0.5.1/deepspeech-0.5.1-models.tar.gz
tar xvfz deepspeech-0.5.1-models.tar.gz

Is it the right process? How do i install from checkpoint?

Thanks in advance

You need deepspeech 0.5.1 instead of 0.6.0-alphaxxx

Iam also facing the same issue…

@adesara.amit I would suggest you to check the 2 file path paramaters in the Model() Function.

When I updated the code from
ds = Model('deepspeech-0.5.1-models/output_graph.pbmm', N_FEATURES, N_CONTEXT, 'deepspeech-0.5.1-models/alphabet.txt', BEAM_WIDTH)

to
ds = Model('deepspeech-0.5.1-models/deepspeech-0.5.1-models/output_graph.pbmm', N_FEATURES, N_CONTEXT, 'deepspeech-0.5.1-models/deepspeech-0.5.1-models/alphabet.txt', BEAM_WIDTH)

It worked.

1 Like

I am getting the same error–> RuntimeError : CreateModel failed with error 12288

I am using the version :
Tensorflow : v1.13.1-10-g3e0cc53
DeepSpeech : v0.5.1-0-g4b29b78

I am using this through a virtual environment. What am I doing wrong ?

You need to install the 0.5.1 version of deep speech if you use the 0.5.1 model.

Hey everyone! this is my version
TensorFlow: v1.14.0-21-ge77504ac6b
DeepSpeech: v0.6.1-0-g3df20fe

I does that
(deepspeech-venv) C:\Users\User\HOME\tmp\deepspeech-venv\Scripts\deepspeech-0.6.0-models> deepspeech --model models/output_graph.pbmm --audio my_audio_file.wav
and i getting this error:

Not found: NewReadOnlyMemoryRegionFromFile failed to Create/Open: models/output_graph.pbmm : ╤шёЄхьх эх єфрхЄё эрщЄш єърчрээ√щ яєЄ№.
; No such process
Traceback (most recent call last):
File “c:\python\python37_2\lib\runpy.py”, line 193, in run_module_as_main
main”, mod_spec)
File “c:\python\python37_2\lib\runpy.py”, line 85, in run_code
exec(code, run_globals)
File "C:\Python\Python37_2\Scripts\deepspeech.exe_main
.py", line 7, in
File “c:\python\python37_2\lib\site-packages\deepspeech\client.py”, line 113, in main
ds = Model(args.model, args.beam_width)
File "c:\python\python37_2\lib\site-packages\deepspeech_init
.py", line 42, in init
raise RuntimeError(“CreateModel failed with error code {}”.format(status))
RuntimeError: CreateModel failed with error code 12288

Please help!

Hello can you help me?

same here

pip3 install deepspeech  

then

cat /etc/os-release && uname -a && python3 --version && deepspeech --version
PRETTY_NAME="Raspbian GNU/Linux 10 (buster)"
NAME="Raspbian GNU/Linux"
VERSION_ID="10"
VERSION="10 (buster)"
VERSION_CODENAME=buster
ID=raspbian
ID_LIKE=debian
HOME_URL="http://www.raspbian.org/"
SUPPORT_URL="http://www.raspbian.org/RaspbianForums"
BUG_REPORT_URL="http://www.raspbian.org/RaspbianBugs"
Linux raspberrypi 4.19.97-v7+ #1294 SMP Thu Jan 30 13:15:58 GMT 2020 armv7l GNU/Linux
Python 3.7.3
TensorFlow: v1.14.0-21-ge77504a
DeepSpeech: v0.6.1-0-g3df20fe
pi@raspberrypi:~/animal-guesser/deepspeech-0.6.1-models $ deepspeech --model output_graph.pbmm --audio tds.wav
Loading model from file output_graph.pbmm
TensorFlow: v1.14.0-21-ge77504a
DeepSpeech: v0.6.1-0-g3df20fe
ERROR: Model provided has model identifier '='+;', should be 'TFL3'

Error at reading model file output_graph.pbmm
Traceback (most recent call last):
File "/home/pi/.local/bin/deepspeech", line 10, in <module>
    sys.exit(main())
File "/home/pi/.local/lib/python3.7/site-packages/deepspeech/client.py", line 113, in main
    ds = Model(args.model, args.beam_width)
File "/home/pi/.local/lib/python3.7/site-packages/deepspeech/__init__.py", line 42, in __init__
    raise RuntimeError("CreateModel failed with error code {}".format(status))
RuntimeError: CreateModel failed with error code 12288

By googling “ERROR: Model provided has model identifier ‘=’+;’, should be ‘TFL3’ RuntimeError: CreateModel failed with error code 12288

I found this issue:

one of the answers Lissyx recommends switching to tflite model, due to the fact that binaries are pre-configured to use TensorFlow Lite runtime. Since the error

Lissyx: “As documented, RPi3/4 binaries are using the TensorFlow Lite runtime, so you need to pass output_graph.tflite and not output_graph.pbmm .”
Therefore it seems that you are using tensorflow lite runtime in your installation.
Try:
deepspeech --model output_graph.tflite --audio myaudio.wav

My output:

Loading model from file output_graph.tflite

TensorFlow: v1.14.0-21-ge77504a

DeepSpeech: v0.6.1-0-g3df20fe

INFO: Initialized TensorFlow Lite runtime.

Loaded model in 0.0428s.

Warning: original sample rate (48000) is different than 16000hz. Resampling might produce erratic speech recognition.

Running inference.

one two one two on to three four five six

Inference took 15.384s for 15.000s audio file.

That’s a common challenge, I want to know more.
Keep up the good work.
MCB