Hello,
I am trying to get some speech to text output from the respeaker package that comes within the catking ws that is installed via hello-robot shell file. But I am getting the following error when I talk to the microphone:
hello-robot@stretch-re2-2014:>catkin_ws$ roslaunch respeaker_ros respeaker.launch
... logging to /home/hello-robot/.ros/log/613e11f4-6f69-11ee-932d-c915c5b5e8ce/roslaunch-stretch-re2-2014-29129.log
Checking log directory for disk usage. This may take a while.
Press Ctrl-C to interrupt
Done checking log file disk usage. Usage is <1GB.
started roslaunch server http://10.65.18.187:34049/
SUMMARY
========
PARAMETERS
* /rosdistro: noetic
* /rosversion: 1.15.15
* /speech_to_text/language: $(arg language)
* /speech_to_text/self_cancellation: $(arg self_cancel...
* /speech_to_text/tts_tolerance: 0.5
NODES
/
respeaker_node (respeaker_ros/respeaker_node.py)
sound_play (sound_play/soundplay_node.py)
speech_to_text (respeaker_ros/speech_to_text.py)
static_transformer (tf/static_transform_publisher)
auto-starting new master
process[master]: started with pid [29144]
ROS_MASTER_URI=http://localhost:11311/
setting /run_id to 613e11f4-6f69-11ee-932d-c915c5b5e8ce
process[rosout-1]: started with pid [29161]
started core service [/rosout]
process[static_transformer-2]: started with pid [29164]
process[respeaker_node-3]: started with pid [29169]
process[sound_play-4]: started with pid [29170]
process[speech_to_text-5]: started with pid [29176]
/opt/ros/noetic/lib/sound_play/soundplay_node.py:330: PyGIDeprecationWarning: Since version 3.11, calling threads_init is no longer needed. See: https://wiki.gnome.org/PyGObject/Threading
GObject.threads_init()
/opt/ros/noetic/lib/sound_play/soundplay_node.py:331: PyGIDeprecationWarning: GObject.MainLoop is deprecated; use GLib.MainLoop instead
self.g_loop = threading.Thread(target=GObject.MainLoop().run)
[INFO] [1697820890.651790]: Initializing Respeaker device (takes 10 seconds)
[INFO] [1697820901.090814]: Respeaker device initialized (Version: 16)
[WARN] [1697820901.506349]: Failed to find respeaker device by name. Using default input
[WARN] [1697820901.507423]: 32 channel is found for respeaker
[WARN] [1697820901.508421]: You may have to update firmware.
[INFO] [1697820901.509473]: Using channels range(0, 32)
[INFO] [1697820905.573201]: Speech detected for 3.944 seconds
[ERROR] [1697820905.603939]: bad callback: <bound method SpeechToText.audio_cb of <__main__.SpeechToText object at 0x7f071190e130>>
Traceback (most recent call last):
File "/opt/ros/noetic/lib/python3/dist-packages/rospy/topics.py", line 750, in _invoke_callback
cb(msg)
File "/home/hello-robot/catkin_ws_tony/src/respeaker_ros/scripts/speech_to_text.py", line 73, in audio_cb
result, confidence = self.recognizer.recognize_google(
TypeError: recognize_google() got an unexpected keyword argument 'with_confidence'
I also tried to run the stretch_respeaker_test.py command and it seems to work. However, the launch file command that is mentioned in the resepaker tutorial on the hello robot documentation isn’t in the respeaker folder anymore. That’s why I am running a different one.