speech-recognition

ImportError: No module named SpeechRecognition

冷暖自知 提交于 2021-02-20 18:56:06
问题 My code is import SpeechRecognition as sr # obtain audio from the microphone r = sr.Recognizer() with sr.Microphone() as source: print("Say something!") audio = r.listen(source) # recognize speech using Microsoft Bing Voice Recognition BING_KEY = "Somevalue" # Microsoft Bing Voice Recognition API keys 32-character lowercase hexadecimal strings try: print("Microsoft Bing Voice Recognition thinks you said " + r.recognize_bing(audio, key=BING_KEY)) except sr.UnknownValueError: print("Microsoft

Get numbers from Android Voice Regnition

会有一股神秘感。 提交于 2021-02-18 19:40:56
问题 I have implemented a recognizer intent like this. Intent intent = new Intent(RecognizerIntent.ACTION_RECOGNIZE_SPEECH); intent.putExtra(RecognizerIntent.EXTRA_LANGUAGE_MODEL, RecognizerIntent.LANGUAGE_MODEL_FREE_FORM); intent.putExtra(RecognizerIntent.EXTRA_PROMPT, "Tell me stuff"); startActivityForResult(intent, REQUEST_CODE); With a return like this if (requestCode == REQUEST_CODE && resultCode == RESULT_OK) { ArrayList<String> matches = data.getStringArrayListExtra( RecognizerIntent.EXTRA

How can I use Opus Codec from JavaScript

谁说胖子不能爱 提交于 2021-02-17 19:13:27
问题 I would like to see if it's possible to have direct access to Opus using getUserMedia or anything similar from the latest browsers. I've been researching on it a lot but with no Good results. I'm aware that either Opus or Speex are actually used in webkitSpeechRecognition API. I would like to do speech recognition but using my own server rather than Google's. 回答1: So there are a lot of suggestions about Emscripten but nobody did, so I ported the encoder opus-tools to JavaScript using

How can I use Opus Codec from JavaScript

余生长醉 提交于 2021-02-17 19:12:15
问题 I would like to see if it's possible to have direct access to Opus using getUserMedia or anything similar from the latest browsers. I've been researching on it a lot but with no Good results. I'm aware that either Opus or Speex are actually used in webkitSpeechRecognition API. I would like to do speech recognition but using my own server rather than Google's. 回答1: So there are a lot of suggestions about Emscripten but nobody did, so I ported the encoder opus-tools to JavaScript using

How can I use Opus Codec from JavaScript

独自空忆成欢 提交于 2021-02-17 19:12:01
问题 I would like to see if it's possible to have direct access to Opus using getUserMedia or anything similar from the latest browsers. I've been researching on it a lot but with no Good results. I'm aware that either Opus or Speex are actually used in webkitSpeechRecognition API. I would like to do speech recognition but using my own server rather than Google's. 回答1: So there are a lot of suggestions about Emscripten but nobody did, so I ported the encoder opus-tools to JavaScript using

Python speech recognition slowing down

[亡魂溺海] 提交于 2021-02-16 21:20:50
问题 I have developed a new program to speak to my chatbot. It works very well, but there is one strange issue I can't seem to figure out. Every time the process repeats (the console outputs listening and does speech recognition), it slows down. The 1st go is quick, the 2nd a little slower, the 3rd slow, and then it just gets too slow to respond from there on. Please help me figure out what syntax could be causing this. import speech_recognition as sr r = sr.Recognizer() with sr.Microphone() as

Python speech recognition error converting mp3 file

跟風遠走 提交于 2021-02-16 08:51:02
问题 My first try on audio to text. import speech_recognition as sr r = sr.Recognizer() with sr.AudioFile("/path/to/.mp3") as source: audio = r.record(source) When I execute the above code, the following error occurs, <ipython-input-10-72e982ecb706> in <module>() ----> 1 with sr.AudioFile("/home/yogaraj/Documents/Python workouts/Python audio to text/show_me_the_meaning.mp3") as source: 2 audio = sr.record(source) 3 /usr/lib/python2.7/site-packages/speech_recognition/__init__.pyc in __enter__(self)

Python speech recognition error converting mp3 file

拜拜、爱过 提交于 2021-02-16 08:47:32
问题 My first try on audio to text. import speech_recognition as sr r = sr.Recognizer() with sr.AudioFile("/path/to/.mp3") as source: audio = r.record(source) When I execute the above code, the following error occurs, <ipython-input-10-72e982ecb706> in <module>() ----> 1 with sr.AudioFile("/home/yogaraj/Documents/Python workouts/Python audio to text/show_me_the_meaning.mp3") as source: 2 audio = sr.record(source) 3 /usr/lib/python2.7/site-packages/speech_recognition/__init__.pyc in __enter__(self)

VoiceRecognition Android Taking Too Long To React

社会主义新天地 提交于 2021-02-11 12:35:11
问题 I'm trying to find a way to get the SpeechRecognizer to react to speech a lot quicker. I have found that the process from onBeginning of speech onwards is pretty fast, but I need the actual reaction to speech meaning onBeginning of speech to have a timelimit before deciding what word is said. Let me know possible suggestions. 回答1: Your question isnt very clear but if you want more fine-grained control over when speech should start recording or the minimum length of the speech etc. you can set

How to fix None Exception iterating requests! issue

这一生的挚爱 提交于 2021-02-11 03:41:53
问题 I'm fresh in speech recognition topic I'm working on project in which I can find some usecases for Pepper bot in the workspace. Playing with Pepper we figured out some issues with it's speech recognition ability. I've found that we can try to connect it with external engines for that and I picked up DialogFlow from GCP. Also because I've found some integrations with this service. I've used code from this project import traceback from naoqi import qi # [START dialogflow_detect_intent_streaming