Uberi / speech_recognition

Speech recognition module for Python, supporting several engines and APIs, online and offline.
https://pypi.python.org/pypi/SpeechRecognition/
BSD 3-Clause "New" or "Revised" License
8.41k stars 2.4k forks source link

Sphinx can't recognize Mandarin Chinese very well comparing with other api or still my installation issue?How to tune it? #239

Closed lyxminnie closed 6 years ago

lyxminnie commented 7 years ago

Steps to reproduce

  1. install the Sphinx Mandarin Chinese language following the instructions

  2. run audio_transcribe.py in the example with AUDIO_FILE = path.join(path.dirname(path.realpath(file)), "chinese.flac")

Expected behaviour

Sphinx can recognize the words in the audio file

Actual behaviour

Sphinx thinks you said 上述 得奖 Google Speech Recognition thinks you said 砸自己的脚

System information

(Delete all the statements that don't apply.)

My system is <Mac OS X EI Capitan 10.11.6>. (For example, "Ubuntu 16.04 LTS x64", "Windows 10 x64", or "macOS Sierra".)

My Python version is <3.5>. (You can check this by running python -V.)

My Pip version is <8.1.1>. (You can check this by running pip -V.)

My SpeechRecognition library version is <3.6.5>. (You can check this by running python -c "import speech_recognition as sr;print(sr.__version__)".)

My PyAudio library version is / I don't have PyAudio installed. (You can check this by running python -c "import pyaudio as p;print(p.__version__)".)

I installed PocketSphinx from . (For example, from the Debian repositories, from Homebrew, or from the source code.)

hzzengyang3 commented 6 years ago

I get the same problem as you, did you get the answer?

secsilm commented 6 years ago

@lyxminnie @hzzengyang3 I met the same issue. Have you get it done guys?

palikar commented 6 years ago

I don't think this is the library's (speech_recognition) fault. From what I understand, there isn't actually an "error" on the behalf of the code from speech_recognition. It's just that Sphinx does not recognize the utterance properly. There isn't that much that a maintainer of speech_recognition can do as this is not part of the library. speech_recognition just binds several APIs together but the actual recognition of is done by other libraries. If you are not satisfied with the quality of the recognition, you should look for help by the maintainers of the corresponding library.

secsilm commented 6 years ago

@palikar Yes I agree with you. The quality of the recognition maybe depend on the lm and dict file.

palikar commented 6 years ago

OK, closing for now. Feel free to comment, if you guys have something more concrete.

xf15 commented 4 years ago

Hi @lyxminnie @hzzengyang3 @secsilm, I wonder if you have found other tools (in python or matlab) with better performances? And maybe also some advice on how to install them? Thank you for reading this