How to avoid sending a robot to an unsafe area?
I am using some data to predict the trajectory using the global and local planners, the model sometime predicts the position of the final goal out of the map.
Note: I am using python code, the figure only shows us where the model predicts the goal.
How to make it to send the goal at least near the boundary map.
Please your suggestion.
If you want to assure the planner will not route out of the map, you should edit the map file and manually complete the perimeter with a solid black line. With that, the planner will not plan outside the map. I've used the same method to prevent planning the robot down my stairs.
@billy, I did that, but when the goal is out of the map, it gives me a message shows that there are some errors. Thereby, the robot doesn't move at all. How to solved it, please?
So you want the planner to provide a plan to a goal outside your map....I've never tried it and don't think it will work, assuming you're using the planners in move base, you could try setting your goal tolerance really really large and see what happens. I've always assumed the goal tolerance is for how close the actual robot gets to the goal, but maybe it works for how close the planner can get to it as well.
also work with
(more)