目标:测试social_navigation_layers

方法:

使用move_base接口启动costmap_2d

这样就能直接用configure方法来进行测试不用自己写代码

一、启动move_base

  1、launch file

<launch>
<!-- Launch move_base and load all navigation parameters -->
<include file="$(find costmap_test)/config/move_base_config/move_base.xml"/> <!-- Run the map server with a blank map -->
<node name="map_server" pkg="map_server" type="map_server" args="$(find pioneer_xtion)/stage_config/maps/blank_map.yaml" /> <!--costmap 必须的tf变换 看http://wiki.ros.org/costmap_2d#tf Required tf Transforms-->
<!--global costmap -->
<node name="static_tf0" pkg="tf" type="static_transform_publisher" args="2 0 0 0 0 0 /map /base_link 100"/>
<!--local costmap -->
<node name="static_tf1" pkg="tf" type="static_transform_publisher" args="0 0 0 0 0 0 /odom /map 100"/>
<!--发布people msgs-->
<node name = "people" pkg="people_velocity_tracker" type="static.py" args="2 2 1 1"/> <node name="rviz" pkg="rviz" type="rviz" args="-d $(find costmap_test)/rviz/single_robot.rviz" />
</launch>

  

  2、movebase config,common costmap config,local costmap config,global costmap config

<launch>
<!--
Example move_base configuration. Descriptions of parameters, as well as a full list of all amcl parameters, can be found at http://www.ros.org/wiki/move_base.
-->
<node pkg="move_base" type="move_base" respawn="false" name="move_base_node" output="screen">
<param name="footprint_padding" value="0.01" />
<param name="controller_frequency" value="10.0" />
<param name="controller_patience" value="3.0" /> <param name="oscillation_timeout" value="30.0" />
<param name="oscillation_distance" value="0.5" /> <param name="base_local_planner" value="dwa_local_planner/DWAPlannerROS" />   <!-- ns = global costmap 加载参数到 global costmap这个node里-->
<rosparam file="$(find costmap_test)/config/move_base_config/costmap_common_params.yaml" command="load" ns="global_costmap" />
<rosparam file="$(find costmap_test)/config/move_base_config/costmap_common_params.yaml" command="load" ns="local_costmap" />
<rosparam file="$(find costmap_test)/config/move_base_config/local_costmap_params.yaml" command="load" />
<rosparam file="$(find costmap_test)/config/move_base_config/global_costmap_params.yaml" command="load" />
<rosparam file="$(find costmap_test)/config/move_base_config/base_local_planner_params.yaml" command="load" /> <rosparam file="$(find costmap_test)/config/move_base_config/dwa_local_planner_params.yaml" command="load" /> </node>
</launch>

common costmap config

#This file contains common configuration options for the two costmaps used in the navigation stack for more details on the parameters in this file, and a full list of the parameters used by the costmaps, please see http://www.ros.org/wiki/costmap_2d

#For this example we'll configure the costmap in voxel-grid mode
map_type: voxel #Voxel grid specific parameters
origin_z: 0.0
z_resolution: 0.2
z_voxels: 10
unknown_threshold: 9
mark_threshold: 0 #Set the tolerance we're willing to have for tf transforms
transform_tolerance: 0.5 #Obstacle marking parameters
obstacle_range: 2.5
max_obstacle_height: 2.0
raytrace_range: 3.0 #The footprint of the robot and associated padding
#footprint: [[-0.325, -0.325], [-0.325, 0.325], [0.325, 0.325], [0.46, 0.0], [0.325, -0.325]]
robot_radius: 0.2
footprint_padding: 0.01 #Cost function parameters
inflation_radius: 0.5
cost_scaling_factor: 0.1 #The cost at which a cell is considered an obstacle when a map is read from the map_server
lethal_cost_threshold: 100 #Configuration for the sensors that the costmap will use to update a map #configuration for plugins
plugins:
- {name: static_map, type: "costmap_2d::StaticLayer"}
- {name: obstacles, type: "costmap_2d::VoxelLayer"}
- {name: proxemicLayer, type: "social_navigation_layers::ProxemicLayer"}
  

 global costmap config

#Independent settings for the global planner's costmap. Detailed descriptions of these parameters can be found at http://www.ros.org/wiki/costmap_2d
<!--global costmap config 如果global_costmap改成其他名字,则param名字也会改-->
global_costmap:
#Set the global and robot frames for the costmap
global_frame: map
robot_base_frame: base_link #Set the update and publish frequency of the costmap
update_frequency: 2.0
publish_frequency: 0.0 #We'll use a map served by the map_server to initialize this costmap
static_map: true
rolling_window: false footprint_padding: 0.02

local costmap config

#Independent settings for the local planner's costmap. Detailed descriptions of these parameters can be found at http://www.ros.org/wiki/costmap_2d

local_costmap:
#We'll publish the voxel grid used by this costmap
publish_voxel_map: true #Set the global and robot frames for the costmap
global_frame: odom
robot_base_frame: base_link #Set the update and publish frequency of the costmap
update_frequency: 2.0
publish_frequency: 2.0 #We'll configure this costmap to be a rolling window... meaning it is always
#centered at the robot
static_map: false
rolling_window: true
width: 6.0
height: 6.0
resolution: 0.01
origin_x: 0.0
origin_y: 0.0

  

  

 

二、发布people_msgs

使用

http://wiki.ros.org/people_velocity_tracker?distro=kinetic

people_velocity_tracker

static.py

效果图

往速度方向增长代价

测试social_navigation_layers的更多相关文章

  1. SignalR系列续集[系列8:SignalR的性能监测与服务器的负载测试]

    目录 SignalR系列目录 前言 也是好久没写博客了,近期确实很忙,嗯..几个项目..头要炸..今天忙里偷闲.继续我们的小系列.. 先谢谢大家的支持.. 我们来聊聊SignalR的性能监测与服务器的 ...

  2. Apache Ignite之集群应用测试

    集群发现机制 在Ignite中的集群号称是无中心的,而且支持命令行启动和嵌入应用启动,所以按理说很简单.而且集群有自动发现机制感觉对于懒人开发来说太好了,抱着试一试的心态测试一下吧. 在Apache ...

  3. 测试一下StringBuffer和StringBuilder及字面常量拼接三种字符串的效率

    之前一篇里写过字符串常用类的三种方式<java中的字符串相关知识整理>,只不过这个只是分析并不知道他们之间会有多大的区别,或者所谓的StringBuffer能提升多少拼接效率呢?为此写个简 ...

  4. TechEmpower 13轮测试中的ASP.NET Core性能测试

    应用性能直接影响到托管服务的成本,因此公司在开发应用时需要格外注意应用所使用的Web框架,初创公司尤其如此.此外,糟糕的应用性能也会影响到用户体验,甚至会因此受到相关搜索引擎的降级处罚.在选择框架时, ...

  5. .NET Core系列 :4 测试

    2016.6.27 微软已经正式发布了.NET Core 1.0 RTM,但是工具链还是预览版,同样的大量的开源测试库也都是至少发布了Alpha测试版支持.NET Core, 这篇文章 The Sta ...

  6. 渗透测试工具BurpSuite做网站的安全测试(基础版)

    渗透测试工具BurpSuite做网站的安全测试(基础版) 版权声明:本文为博主原创文章,未经博主允许不得转载. 学习网址: https://t0data.gitbooks.io/burpsuite/c ...

  7. 在ubuntu16.10 PHP测试连接MySQL中出现Call to undefined function: mysql_connect()

    1.问题: 测试php7.0 链接mysql数据库的时候发生错误: Fatal error: Uncaught Error: Call to undefined function mysqli_con ...

  8. 【初学python】使用python调用monkey测试

    目前公司主要开发安卓平台的APP,平时测试经常需要使用monkey测试,所以尝试了下用python调用monkey,代码如下: import os apk = {'j': 'com.***.test1 ...

  9. CoreCRM 开发实录——Travis-CI 实现 .NET Core 程度在 macOS 上的构建和测试 [无水干货]

    上一篇文章我提到:为了使用"国货",我把 Linux 上的构建和测试委托给了 DaoCloud,而 Travis-CI 不能放着不用啊.还好,这货支持 macOS 系统.所以就把 ...

随机推荐

  1. 阿里云服务器 linux下载 jdk

    直接从本地下载包上传比较慢.直接在服务器上下载安装包: 1.进入orcle官网; 2.选择需要下载的版本,下载需要同意orcle协议, 3.点击下载,获取到下载请求的cookie, 复制所有cooki ...

  2. php serialize讲解与json性能测试

    [序列化的概念] 序列化是将对象状态转换为可保持或可传输的格式的过程.与序列化相对的是反序列化,它将流转换为对象.这两个过程结合起来,可以轻松地存储和传输数据. 将对象的状态信息转换为可以存储或传输的 ...

  3. 购物车实现思路:cookie + 数据库

    一.加入购物车 1.用户未登录  ==> 将商品id和商品数量存为数组 ==>序列化后存到cookie中 代码: if(!isset($_SESSION['uid'])){ if(empt ...

  4. [C/C++] malloc内存分配与free内存释放原理

    1.问题的引入: 为什么要使用malloc,主要是因为在代码中,为了节约内存,很多数据都是动态生成的,所以会用malloc,对应于C++中的new,底层还是调用malloc. 2.碎片的问题: 会有内 ...

  5. kali linux下的常用bash命令

    虚拟机版本默认用户root 密码toor ls:显示当前目录包含的文件及文件夹 ls -l:以常规格式显示当前目录包含的文件及文件夹(开头字母解释:d:目录 -:文件 c:设备文件 l:链接 b:块设 ...

  6. Ubuntu下Eclipse中运行Hadoop程序的参数问题

    需要统一的参数: 当配置好eclipse中hadoop的程序后,几个参数需要统一一下: hadoop安装目录下/etc/core_site.xml中 fs.default.name的端口号一定要与ha ...

  7. 【ZJ选讲·调整】

    给出n个点,m条有向边(带正权),起点S,终点T.(n<=2000,m<=30000) 再给出一个k,表示可以把最多k条边的权值调整为任意非负整数.(k<=100) 问是否可以通 ...

  8. BZOJ day8

    好吧,, 补一天题解. 1001  狼抓兔子 妥妥的网络流啊,难度仅次于草地排水,边都给出来了.就是注意反向边也要有流量就行. 1007 水平可见直线 这个题按斜率排序(注意不是绝对值),然后将直线入 ...

  9. HDU - 1880 魔咒词典~哈希入门

    哈利波特在魔法学校的必修课之一就是学习魔咒.据说魔法世界有100000种不同的魔咒,哈利很难全部记住,但是为了对抗强敌,他必须在危急时刻能够调用任何一个需要的魔咒,所以他需要你的帮助. 给你一部魔咒词 ...

  10. 简单配置oracle11g

    一.配置 Systemd file(开机可以自动oracle,也可以查看启动状态) a.定义环境变量 [oracle@ol7 ~]$ cat /etc/sysconfig/DB11G.oracledb ...