Skip to content
This repository has been archived by the owner on Sep 25, 2021. It is now read-only.

Unable to run and debug panda compl_planner_example #1

Closed
gautz opened this issue Aug 18, 2020 · 5 comments
Closed

Unable to run and debug panda compl_planner_example #1

gautz opened this issue Aug 18, 2020 · 5 comments

Comments

@gautz
Copy link

gautz commented Aug 18, 2020

Hi,

Trying to run following in an Ubuntu VirtualBox:
~/planning_ws$ rosrun planning_plugin_examples compl_planner_example

I am getting following error:

[ INFO] [1597761226.433289249]: Loading robot model 'panda'...
[ERROR] [1597761226.544413210]: Exception while loading planner 'elion/ElionPlanner': According to the loaded plugin descriptions the class elion/ElionPlanner with base class type planning_interface::PlannerManager does not exist. Declared types are  chomp_interface/CHOMPPlanner compl_interface/COMPLPlanner lerp_interface/LERPPlanner ompl_interface/OMPLPlanner pilz::CommandPlanner
Available plugins: chomp_interface/CHOMPPlanner compl_interface/COMPLPlanner lerp_interface/LERPPlanner ompl_interface/OMPLPlanner pilz::CommandPlanner 
[ WARN] [1597761227.046479357]: Topic '/display_robot_state' unable to connect to any subscribers within 0.5 sec. It is possible initially published visual messages will be lost.
[ WARN] [1597761227.549092476]: Topic '/visualization_marker_array' unable to connect to any subscribers within 0.5 sec. It is possible initially published visual messages will be lost.
[ INFO] [1597761227.656594905]: No planning scene passed into moveit_visual_tools, creating one.
[ INFO] [1597761227.662894279]: Loading robot model 'panda'...
[ INFO] [1597761227.828048704]: Publishing maintained planning scene on ''
Segmentation fault (core dumped)

Any hint?

I am also unable to debug any MoveIt tutorial via launch file in Visual Studio Code. How did you manage to get debugging work? Do you have an example of a working launch.json file?

@JeroenDM
Copy link
Owner

JeroenDM commented Aug 19, 2020

Hello, thank you for trying out the code.

The error you showed is caused by the fact that it is looking for a plugin called 'elion/ElionPlanner', which is not defined in this repository, but in a newer one here. The plugin defined in this repository is called compl_interface/COMPLPlanner. (You can find this name in compl_interface_description.xml.) You can change this as I did in this commit.

But with that problem solved I would expect it is very likely that you encounter other problems. For example, the position might be infeasible for the panda robot. Feel free to submit pull requests to clean up the code :)

I shifted my attention to the new implementation, elion, which in itself was preparation for hopefully adding it to MoveIt in the near future...

(Debugging tips follow in the next message.)

@JeroenDM
Copy link
Owner

Debugging in VSCode

First, make sure you build the workspace in debug mode by doing:

catkin config --cmake-args -DCMAKE_BUILD_TYPE=Debug

before catkin build.

I create a launch file that runs the node I want to debug, for example:

<launch>
    <node name="planning_plugin_examples" pkg="planning_plugin_examples" type="compl_planner_example" output="screen"/>
</launch>

Then I use the ROS extension. In the debug tab you can go Add configuration and then choose ROS: Launch. This will add a configuration to your .vscode/launch.json that looks like this:

        {
            "name": "ROS: Launch",
            "type": "ros",
            "request": "launch",
            "target": "absolute path to launch file"
        }

Where you have to put the absolute path to the launch file in the target field. (You can right-click on a launch file and select Copy path.) For example, on my computer the path to the launch file was /home/jeroen/ros/temp_ws/src/moveit_constrained_planning_plugin/planning_plugin_examples/launch/debugging.launch.

Now you should be able to add breakpoints and launch the debugger. For more details, see the documentation of the ROS extension.

@gautz
Copy link
Author

gautz commented Aug 26, 2020

Thanks for the detailed answers and your work that will surely help the ROS Industrial community.

In the end I tried you recent tutorial on planning with OMPL constrained state space and it worked. Do I understand well that elion repo was some preliminary work to get constrained state space planning working in MoveIt. Else what is the aim of it?

@JeroenDM
Copy link
Owner

I'm glad to hear you tried it out and it worked! It is not always easy to predict whether something that works on my computer also works for others. (Although the CI helps.)

Do I understand well that elion repo was some preliminary work to get constrained state-space planning working in MoveIt.

Exactly :)

With the MoveIt integrated version you can also plan to pose goals and do other types of planning with the same plugin. (The constrained planning will only be selected if there is a single position or orientation path constraint.

Elion, however, still contains more types of constraints, so there is still work to be done. See for example this issue.

@JeroenDM
Copy link
Owner

I'm archiving this repository to make it clear that it is outdated.

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants