rst-tu-dortmund / teb_local_planner_tutorials

This package contains supplementary material and examples for teb_local_planner tutorials.
163 stars 99 forks source link

move_base crash when using teb_local_planner #13

Closed richban closed 3 years ago

richban commented 3 years ago

I'm trying to run one of your tutorial examples for a carlike robot however I am encountering this error message below. I am using the same config files as in the tutorial for the carlike robot. Any ideas what's wrong?

ROS Distro: Kinetic

ERROR

NODES
  /
    amcl (amcl/amcl)
    map_server (map_server/map_server)
    move_base (move_base/move_base)
    robot_state_publisher (robot_state_publisher/robot_state_publisher)
    rviz (rviz/rviz)

ROS_MASTER_URI=http://192.168.0.15:11311

process[map_server-1]: started with pid [12123]
process[amcl-2]: started with pid [12124]
[ INFO] [1596022923.105448960]: Loading map from image "/home/nvidia/racecar-ws/src/racecar_nav/racecar_control/maps/office_corridor.pgm"
process[robot_state_publisher-3]: started with pid [12132]
process[rviz-4]: started with pid [12153]
process[move_base-5]: started with pid [12174]
[ INFO] [1596022923.188501803]: Read a 1024 X 1024 map @ 0.050 m/cell
[ INFO] [1596022923.497155113]: Subscribed to map topic.
[ INFO] [1596022923.679318227]: Received a 1024 X 1024 map @ 0.050 m/pix

[ INFO] [1596022923.800350587]: Initializing likelihood field model; this can take some time on large maps...
[ INFO] [1596022923.935969236]: Done initializing likelihood field model.
terminate called after throwing an instance of 'std::bad_alloc'
  what():  std::bad_alloc
[move_base-5] process has died [pid 12174, exit code -6, cmd /home/nvidia/racecar-ws/devel/lib/move_base/move_base __name:=move_base __log:=/home/nvidia/.ros/log/be4eac8a-d18a-11ea-bbda-00044ba84f8d/move_base-5.log].
log file: /home/nvidia/.ros/log/be4eac8a-d18a-11ea-bbda-00044ba84f8d/move_base-5*.log

move_base-5.log

^[[33m[ WARN] [1596022923.970113586]: global_costmap: Pre-Hydro parameter "static_map" unused since "plugins" is provided^[[0m
  1 ^[[33m[ WARN] [1596022923.971636866]: global_costmap: Pre-Hydro parameter "map_type" unused since "plugins" is provided^[[0m
  2 ^[[0m[ INFO] [1596022923.973848502]: global_costmap: Using plugin "static_layer"^[[0m
  3 ^[[0m[ INFO] [1596022923.997815503]: Requesting the map...^[[0m
  4 ^[[0m[ INFO] [1596022924.207625435]: Resizing costmap to 1024 X 1024 at 0.050000 m/pix^[[0m
  5 ^[[0m[ INFO] [1596022924.306135233]: Received a 1024 X 1024 map at 0.050000 m/pix^[[0m
  6 ^[[0m[ INFO] [1596022924.306185711]: Subscribing to updates^[[0m
  7 ^[[0m[ INFO] [1596022924.327088735]: global_costmap: Using plugin "obstacle_layer"^[[0m
  8 ^[[0m[ INFO] [1596022924.341171882]:     Subscribed to Topics: laser_scan_sensor^[[0m
  9 ^[[0m[ INFO] [1596022924.429135753]: global_costmap: Using plugin "inflation_layer"^[[0m
 10 ^[[33m[ WARN] [1596022924.549366610]: local_costmap: Pre-Hydro parameter "static_map" unused since "plugins" is provided^[[0m
 11 ^[[33m[ WARN] [1596022924.550454065]: local_costmap: Pre-Hydro parameter "map_type" unused since "plugins" is provided^[[0m
 12 ^[[0m[ INFO] [1596022924.552724786]: local_costmap: Using plugin "static_layer"^[[0m
 13 ^[[0m[ INFO] [1596022924.565805623]: Requesting the map...^[[0m
 14 ^[[0m[ INFO] [1596022924.571638651]: Resizing static layer to 1024 X 1024 at 0.050000 m/pix^[[0m
 15 ^[[0m[ INFO] [1596022924.670827766]: Received a 1024 X 1024 map at 0.050000 m/pix^[[0m
 16 ^[[0m[ INFO] [1596022924.680981053]: local_costmap: Using plugin "obstacle_layer"^[[0m
 17 ^[[0m[ INFO] [1596022924.691879528]:     Subscribed to Topics: laser_scan_sensor^[[0m
 18 ^[[0m[ INFO] [1596022924.827972487]: Created local_planner teb_local_planner/TebLocalPlannerROS^[[0m
 19 ^[[0m[ INFO] [1596022925.050979533]: Footprint model 'line' (line_start: [0,0]m, line_end: [0.4,0]m) loaded for trajectory optimization.^[[0m
 20 ^[[0m[ INFO] [1596022925.051124092]: Parallel planning in distinctive topologies enabled.^[[0m
 21 ^[[0m[ INFO] [1596022925.051198965]: No costmap conversion plugin specified. All occupied costmap cells are treaten as point obstacles.^[[0m
richban commented 3 years ago

Here is my launch file just in case:

<?xml version="1.0"?>
<launch>
    <master auto="start"/>

    <!-- Launch a map from the maps folder-->
    <arg name="map_file" default="$(find racecar_control)/maps/office_corridor.yaml" />

    <node pkg="map_server" name="map_server" type="map_server" args="$(arg map_file)" respawn="true" output="screen" />

    <!-- AMCL Localization -->
    <include file="$(find racecar_control)/launch/includes/hypharos_amcl.launch.xml"/>

    <!-- Launch the racecar model -->
    <include file="$(find racecar_control)/launch/racecar_model.launch"/>

    <!-- Launch rviz -->
    <node type="rviz" name="rviz" pkg="rviz" args="-d $(find racecar_control)/rviz/move_base.rviz" />

    <!-- Move base -->
    <node pkg="move_base" type="move_base" respawn="false" name="move_base">
        <!-- params -->
        <param name="base_local_planner" value="teb_local_planner/TebLocalPlannerROS"/>  
        <param name="base_gloabal_planner" value ="global_planner/GlobalPlanner"/>
        <param name="planner_frequency" value="1.0" />
        <param name="planner_patience" value="5.0" />
        <param name="controller_frequency" value="5.0" />
        <param name="controller_patience" value="15.0" />
        <param name="clearing_rotation_allowed" value="false" />
        <!-- planner -->
        <rosparam file="$(find racecar_control)/config/racecar/teb_local_planner_params.yaml" command="load"/>
        <!-- costmap layers -->    
        <rosparam file="$(find racecar_control)/config/racecar/local_costmap_params.yaml" command="load"/>
        <rosparam file="$(find racecar_control)/config/racecar/global_costmap_params.yaml" command="load"/> 
        <rosparam file="$(find racecar_control)/config/racecar/costmap_common_params.yaml" command="load" ns="global_costmap" />
        <rosparam file="$(find racecar_control)/config/racecar/costmap_common_params.yaml" command="load" ns="local_costmap" />

    </node>
</launch>

and all the config files https://github.com/richban/racecar_ws/tree/master/racecar_control/config/racecar

richban commented 3 years ago

Screen Shot 2020-07-29 at 2 37 23 PM

posshe commented 2 years ago

Hello, @richban How do you solve the problem about the move_base crash? I have the similar issue. Thank you very much !

richban commented 2 years ago

Can't recall but it has something to do with version.