ROS kinetic语音识别
1.安装依赖
1.1安装ros-kinetic-audio-common
sudo apt-get install ros-kinetic-audio-common
1.2 安装libasound2
sudo apt-get install libasound2
1.3 安装libgstreamer0.10
sudo apt-get install gstreamer0.10-*
1.4安装python-gst0.10
sudo apt-get install python-gst0.10
2.安装 libsphinxbase1
下载地址:https://packages.debian.org/jessie/libsphinxbase1
sudo dpkg -i libsphinxbase1_0.8-6_amd64.deb
3. 安装libpocketsphinx1
下载地址:https://packages.debian.org/jessie/libpocketsphinx1
sudo dpkg -i libpocketsphinx1_0.8-5_amd64.deb
4.安装gstreamer0.10-pocketsphinx
下载地址:https://packages.debian.org/jessie/gstreamer0.10-pocketsphinx
sudo dpkg -i gstreamer0.10-pocketsphinx_0.8-5_amd64.deb
5.安装pocketsphinx
5.1进入工作空间,git源码
cd ~/dev/catkin_ws/src
git clone https://github.com/mikeferguson/pocketsphinx
5.2下载英文语音包pocketsphinx-hmm-en-tidigits (0.8-5)
下载的网站:https://packages.debian.org/jessie/pocketsphinx-hmm-en-tidigits
sudo dpkg -i pocketsphinx-hmm-en-tidigits_0.-5_all.deb
会加压安装到/usr/share/目录如下所示
/usr/share/doc/pocketsphinx-hmm-en-tidigits/changelog.Debian.gz
/usr/share/doc/pocketsphinx-hmm-en-tidigits/changelog.gz
/usr/share/doc/pocketsphinx-hmm-en-tidigits/copyright
/usr/share/pocketsphinx/model/hmm/en/tidigits/feat.params
/usr/share/pocketsphinx/model/hmm/en/tidigits/mdef
/usr/share/pocketsphinx/model/hmm/en/tidigits/means
/usr/share/pocketsphinx/model/hmm/en/tidigits/sendump
/usr/share/pocketsphinx/model/hmm/en/tidigits/transition_matrices
/usr/share/pocketsphinx/model/hmm/en/tidigits/variances
/usr/share/pocketsphinx/model/lm/en/tidigits.DMP
/usr/share/pocketsphinx/model/lm/en/tidigits.dic
/usr/share/pocketsphinx/model/lm/en/tidigits.fsg
在包pocketsphinx下面建一个model目录,存放语音模型文件
cd ~/dev/catkin_ws/src/pocketsphinx
mkdir model
将下载好的语音文件,解压后,将其中的model文件下的所有文件拷贝到~/dev/catkin_ws/src/pocketsphinx/model下,也可以不复制。
6 启动pocketsphinx测试
直接运行pocketsphinx启动脚本命令“roslaunch pocketsphinx robocup.launch”会出现如下错误,

为此,首先我对recognizer.py的做了如下修改:
1)注释掉self.asr.set_property('configured', True)
2)添加lm,dict,hmm支持英语识别(如果是其他语言(如普通话)可以改为别的路径)
self.asr.set_property('lm', '/usr/share/pocketsphinx/model/lm/en/tidigits.DMP')
self.asr.set_property('dict', '/usr/share/pocketsphinx/model/lm/en/tidigits.dic')
self.asr.set_property('hmm', '/usr/share/pocketsphinx/model/hmm/en/tidigits')

这些安装好之后,可以开始测试pocketsphinx的语音识别功能了:
1.终端运行launch启动文件:
roslaunch pocketsphinx robocup.launch
2.尝试说一些简单的语句,(如果使用英文库,说一些数字;如果使用普通话库讲中文),查看识别结果
3.用rostopic echo进行查看识别的输出,即ROS发布的结果消息)
rostopic echo /recognizer/output
7.也可以下载其他包进行测试
中文普通话
pocketsphinx-hmm-zh-tdt https://packages.debian.org/jessie/pocketsphinx-hmm-zh-tdt
pocketsphinx-lm-zh-hans-gigatdt https://packages.debian.org/jessie/pocketsphinx-lm-zh-hans-gigatdt
后期考虑在launch文件中设置参数,在recognizer.py加载参数的读取
参考:http://blog.csdn.net/x_r_su/article/details/53022746?locationNum=1&fps=1
http://www.ncnynl.com/archives/201701/1220.html
ROS kinetic语音识别的更多相关文章
- ROS Kinetic 使用PocketSphinx进行语音识别报错
已解决,重启电脑,装环境把声卡驱动那些似乎死机了 ROS Kinetic 使用PocketSphinx进行语音识别教程 https://www.ncnynl.com/archives/201701/ ...
- ros kinetic安装rbx1
1.首先安装一些依赖包 sudo apt-get install ros-kinetic-turtlebot-bringup \ ros-kinetic-turtlebot-create ros-ki ...
- Ubuntu 16.04 + ROS Kinetic 机器人操作系统学习镜像分享与使用安装说明
Ubuntu 16.04 + ROS Kinetic 镜像分享与使用安装说明 内容概要:1 网盘文件介绍 2 镜像制作 3 系统使用与安装 ---- 祝ROS爱好者和开发者新年快乐:-) ---- ...
- ROS_Kinetic_02 ROS Kinetic 迁移指南及中文wiki指南(Migration guide)
ROS_Kinetic_02 ROS Kinetic 迁移指南(Migration guide) 对于ROS Kinetic Kame有些功能包已经更新改变,提供关于这些包的迁移注意或教程.主要针对于 ...
- ROS_Kinetic_01 在ubuntu 16.04安装ROS Kinetic 2017.01更新
ROS_Kinetic系列学习(一),在ubuntu 16.04安装ROS Kinetic. Celebrating 9 Years of ROS! ubuntu16.04已经发布半年多了,ROS的K ...
- SLAM+语音机器人DIY系列:(二)ROS入门——3.在ubuntu16.04中安装ROS kinetic
摘要 ROS机器人操作系统在机器人应用领域很流行,依托代码开源和模块间协作等特性,给机器人开发者带来了很大的方便.我们的机器人“miiboo”中的大部分程序也采用ROS进行开发,所以本文就重点对ROS ...
- Ros Kinetic 配置 OpenCV2和CV_bridge (Python, C++)
本篇介绍如何在Ros-kinetic环境下运用opencv2进行开发的配置,系统平台为64位Ubuntu16.04. 需要系统环境: 1.Ros kinetic版本,一般自带cv_bridge, 若没 ...
- Ubuntu 16.04 使用docker资料汇总与应用docker安装caffe并使用Classifier(ros kinetic+usb_cam+caffe)
Docker是开源的应用容器引擎.若想简单了解一下,可以参考百度百科词条Docker.好像只支持64位系统. Docker官网:https://www.docker.com/ Docker - 从入门 ...
- 在ROS Kinetic和Gazebo 8中使用智能汽车仿真演示
在ROS Kinetic和Gazebo 8中使用智能汽车仿真演示 智能车无人驾驶技术是目前人工智能和机器人技术的研究热点,有许多开源平台可以使我们零基础零成本入门无人驾驶技术.本文分享一下目前ROS官 ...
随机推荐
- echart折线图系列一:折线图基本配置
引入echart插件 页面上准备一个容器:<div id="box" style="height:400px;width: 800px;padding: 20px& ...
- Django与Celery配合实现定时任务
一.前言 Celery是一个基于python开发的分布式任务队列,而做python WEB开发最为流行的框架莫属Django,但是Django的请求处理过程都是同步的无法实现异步任务,若要实现异步任务 ...
- 原生javascript制作时钟
用JavaScript来制作实时的时钟 效果图如下: 接下来,我会一步一步向大家介绍如何制作,并将里面的一些值得注意的事项提出来. 首先是把框架搭构起来, <div> <canvas ...
- CSS3_元素拖曳原理_设置全局点击捕获_九宫格碰撞检测_自定义滚动条
拖曳原理: 元素的初始位置 + 鼠标距离差 = 元素最终位置 使元素可以拖动 function dragElement(obj){ obj.onmousedown = function(e){ e = ...
- mobile_点透_传透_touch-action
点透(传透) <meta name="viewport" content="width=device-width, initial-scale=1.0, user- ...
- SSM的 日常错误 之 mybatis
HTTP Status 500 - Request processing failed; nested exception is org.mybatis.spring.MyBatisSystemExc ...
- Go笔记
#Go在win下安装 1. https://golang.google.cn/dl/下载 amd64 版本的zip包 2. 解压后将bin目录添加入path 3. go version可显示版本信息
- 《PHP内核剖析 - 变量/内存管理》
本文总结自: <PHP7 内核剖析 - 变量的内部实现> 一:变量的实现 - 变量是一个语言实现的基础. - 在PHP中,变量的组成部分为 变量名(zval) 变量值(zend_value ...
- Mybatis异常--There is no getter for property named 'XXX' in 'class java.lang.String'
第一种 在service层加@Param(value="ip") void deleteIpsetup(@Param(value="ip")String ip) ...
- HTML技巧篇:如何让单行文本以及多行文本溢出时显示省略号(…)
参考:https://baijiahao.baidu.com/s?id=1621362934713048315&wfr=spider&for=pc 本篇文章主要给大家介绍一下在html ...