融合动态障碍物

简介:考虑怎样把其他节点发布的动态障碍物考虑进来

1.本部分演示了动态障碍物该如何被包含到teb_local_planner中。

2.写一个简单的动态障碍物的发布器publish_dynamic_obstacles.py

#!/usr/bin/env python2

3import rospy, math, tf4 fromcostmap_converter.msg import ObstacleArrayMsg, ObstacleMsg5 fromgeometry_msgs.msg import Point32, QuaternionStamped, Quaternion, TwistWithCovariance6 fromtf.transformations import quaternion_from_euler7

8

9def publish_obstacle_msg():10 pub = rospy.Publisher('/test_optim_node/obstacles', ObstacleArrayMsg, queue_size=1)11 rospy.init_node("test_obstacle_msg")12

13 y_0 = -3.0

14 vel_x = 0.0

15 vel_y = 0.3

16 range_y = 6.0

17

18 obstacle_msg =ObstacleArrayMsg()19 obstacle_msg.header.stamp =rospy.Time.now()20 obstacle_msg.header.frame_id = "odom" # CHANGE HERE: odom/map21

22# Add point obstacle23obstacle_msg.obstacles.append(ObstacleMsg())24 obstacle_msg.obstacles[0].id = 99

25 obstacle_msg.obstacles[0].polygon.points =[Point32()]26 obstacle_msg.obstacles[0].polygon.points[0].x = -1.5

27 obstacle_msg.obstacles[0].polygon.points[0].y = 0

28 obstacle_msg.obstacles[0].polygon.points[0].z = 0

29

30 yaw =math.atan2(vel_y, vel_x)31 q = tf.transformations.quaternion_from_euler(0,0,yaw)32 obstacle_msg.obstacles[0].orientation = Quaternion(*q)33

34 obstacle_msg.obstacles[0].velocities.twist.linear.x =vel_x35 obstacle_msg.obstacles[0].velocities.twist.linear.y =vel_y36 obstacle_msg.obstacles[0].velocities.twist.linear.z = 0

37 obstacle_msg.obstacles[0].velocities.twist.angular.x = 0

38 obstacle_msg.obstacles[0].velocities.twist.angular.y = 0

39 obstacle_msg.obstacles[0].velocities.twist.angular.z = 0

40

41 r = rospy.Rate(10) # 10hz42 t = 0.0

43 whilenot rospy.is_shutdown():44

45# Vary y component of the point obstacle46 if (vel_y >= 0):47 obstacle_msg.obstacles[0].polygon.points[0].y = y_0 + (vel_y*t)%range_y48 else:49 obstacle_msg.obstacles[0].polygon.points[0].y = y_0 + (vel_y*t)%range_y -range_y50

51 t = t + 0.1

52

53pub.publish(obstacle_msg)54

55r.sleep()56

57

58 if __name__ == '__main__':59 try:60publish_obstacle_msg()61except rospy.ROSInterruptException:62 pass

View Code

运行:

roslaunch teb_local_planner test_optim_node.launch

roslaunch mypublisher publish_dynamic_obstacles.py

3.设置规划器来考虑动态障碍物

启动rosrun rqt_reconfigure rqt_reconfigure;选中参数include_dynamic_obstacles,teb local planner使用一个常速度模型来预测障碍物将来的行为。现在的轨迹是根据时间和空间来避免障碍物而不是仅仅考当前障碍物的位置来避免。对于速度模型的估计精确性是很重要的,常速度假设是合理且满足的。

如果调节参数visualize_with_time_as_z_axis,可以可视化规划的和预测的速度的时间变化。设置该参数值为0.1。在rviz中的z轴被解释为时间轴,且可被扩展。也可以看到homotopy-class-planning把动态障碍物的预测考虑进去。

相关的参数

~/min_obstacle_dist: Desired minimal distance from (staticand dynamic) obstacles~/inflation_dist: Non-zero cost region around (static) obstacles~/include_dynamic_obstacles: Specify whether the motion of dynamic obstacles should be included (constant-velocity-model) or not.~/dynamic_obstacle_inflation_dist: Non-zero cost region around (dynamic) obstacles~/include_costmap_obstacles: Deactivate costmap obstacles completely~/costmap_obstacles_behind_robot_dist: Maximum distance behind the robot searched foroccupied costmap cells.~/obstacle_poses_affected: Specify how many trajectory configurations/poses should be taken into account next to the closest one.~/weight_obstacle: Optimization weight for keeping a distance to staticobstacles.~/weight_inflation: Optimization weight for inflation costs of staticobstacles.~/weight_dynamic_obstacle: Optimization weight forkeeping a distance to dynamic obstacles.~/weight_dynamic_obstacle_inflation: Optimization weight forinflation costs of dynamic obstacles.~/footprint_model: The robot footprint model

View Code

rqt teb参数动态调试工具_teb教程8相关推荐

  1. rqt teb参数动态调试工具_teb教程2

    http://wiki.ros.org/teb_local_planner/Tutorials/Inspect%20optimization%20feedback 检查优化反馈 简介:怎样检查优化的轨 ...

  2. rqt teb参数动态调试工具_teb

    Template Engine Benchmark 作者决定废弃原EBM测试工具,重新设计了TEB,功能和准确度都较EBM有了提高: 目前网络上的Java模板引擎测试基本上都是非独立JVM测试的, 这 ...

  3. rqt teb参数动态调试工具_16.ROS常用工具:Rviz/rqt

    >>点赞,收藏+关注,理财&技术不迷路<< RViz(The Robot Visualization tool可视化工具): 作用:把一些抽象的复杂的传感器信息以图像的 ...

  4. [网络安全自学篇] 七十二.逆向分析之OllyDbg动态调试工具(一)基础入门及TraceMe案例分析

    这是作者网络安全自学教程系列,主要是关于安全工具和实践操作的在线笔记,特分享出来与博友们学习,希望您们喜欢,一起进步.前文分享了外部威胁防护和勒索病毒对抗.这篇文章将讲解逆向分析OllyDbg动态调试 ...

  5. ML307S使用MQTT连接阿里云---动态注册连接教程

    ML307S使用MQTT连接阿里云-动态注册连接教程 文章目录 ML307S使用MQTT连接阿里云---动态注册连接教程 前言 一.阿里云的动态注册流程简介 二.连接步骤 1.在阿里云物联网控制台增加 ...

  6. 函数参数---动态参数

    形参的第三种:动态参数 动态参数分为两种: 1.动态接受位置参数; 注意:形参的顺序:   位置参数, 动态参数, 默认参数 动态接受参数的时候要注意:动态参数必须在位置参数后面 关键参数必须要放在位 ...

  7. kettle根据参数动态派生列

    kettle根据参数动态派生列 抽取数据的时候没有日期字段,需要根据抽取日期自动生成月份,如下图结构 表输入_参数部分,接收来自其他系统传过来的参数(JAVA程序或者页面),具体设置如图 在查询数据时 ...

  8. iphone主屏幕动态壁纸_iPhone8怎么设置动态壁纸?iPhone8动态壁纸设置教程

    iPhone8怎么设置动态壁纸?朋友们平时想把一些拍摄的动态图片设置iPhone8壁纸,该怎么设置呢?估计有 不少朋友还不知道如何设置, 在这里我就来为大家介绍一下iPhone8设置动态壁纸的教程,一 ...

  9. v-for 循环 @click 动态传参(参数动态)

    v-for 循环 @click 动态传参(参数动态) 代码示下: @click="function('id_'+data.id)" 以上就是关于"v-for 循环 @cl ...

最新文章

  1. S-BEV:用于天气和光照不变的3-DoF定位的语义鸟瞰视图表示
  2. JavaScript实现permutate Without Repetitions无重复排列算法(附完整源码)
  3. 成为编程高手的二十二条军规
  4. 棋牌游戏服务器架构: 详细设计(三) 数据库设计
  5. Java 中15种锁的介绍:公平锁,可重入锁,独享锁,互斥锁,乐观锁,分段锁,自旋锁等等
  6. 【BP神经网络】使用反向传播训练多层神经网络的原则+“常见问题”
  7. 打包Spring Boot应用
  8. CYQ.Data 轻量数据层之路 V3.0版本发布-Xml绝对杀手(三十二)
  9. 用极大似然法估计因子载荷矩阵_spss教程:因子分析
  10. 交换机不同vlan不同网段通过核心交换机配置VLANIF通信
  11. IT项目经理面试题分解
  12. scl语言用plc脉冲做定时器_scl语言用plc脉冲做定时器_西门子PLC SCL语言开发学习笔记(二)...
  13. 改变linux 背景修改命令,Linux命令行下更改桌面背景(GNOME环境)
  14. HTML Purifier解决XSS问题
  15. python求级数的值_python中的级数和
  16. PS之人物通道磨皮法
  17. 气氛组担当竟推出了表情包,快来一键Get!
  18. 分享 29 款 Chrome 插件,总有一款适合你
  19. Simpsons’ Hidden Talents(辛普森一家的隐藏天赋 )(kmp经典模板题) HDU - 2594
  20. 阳光的测试工作历程(转载)

热门文章

  1. win10打开计算机加载很慢,win10我的电脑打开慢怎么办_win10此电脑打开慢解决方法-win7之家...
  2. 远程同步软件rsync(一)
  3. 关于copy和clone
  4. JavaScript-IIFE
  5. 关于远心镜头的基础知识
  6. Excel公式大全【300函数】
  7. 几种软件开发方法对比
  8. jsPlumb使用学习-在线流程设计器demo参考说明
  9. 使用ffmpeg工具进行YUV420P到RGB32的格式转换问题总结
  10. 经典PID控制及应用体会总结