-
Notifications
You must be signed in to change notification settings - Fork 1.8k
Ability to get a path from the planner from any 2 poses (start_pose and goal): add use_start_pose and start_pose to ComputePathToPose action #2179
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Merged
SteveMacenski
merged 10 commits into
ros-navigation:main
from
wyca-robotics:add_use_start_pose
Mar 5, 2021
Merged
Changes from all commits
Commits
Show all changes
10 commits
Select commit
Hold shift + click to select a range
410cfc5
add use_start_pose to ComputePathToPose.action
6ac2b5e
add use_start_pose to ComputePathToPose bt
e866db6
start instead of start_pose + else if
8a770b1
[ComputePathToPose Action API break] change 'pose' for 'goal' +use_start
ef1774f
test wip
dd22a17
add compute path to pose BT test for use_start
0a10ae0
last start_pose renaming
4ed8eb0
Transform start and goal in costmap frame
ad27806
Revert "Transform start and goal in costmap frame"
658f80d
lint
File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Uh oh!
There was an error while loading. Please reload this page.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This test calls the fixture and not the actual planner server, so it doesn't fully test what we need to test. We need a test that is going to call the actual planner server itself and shows that when the planner server has the start set that it creates a valid plan using that information. You can do this using the
system_tests/plannertests. There's a random and fixed map tests you could add an additional test case to where you setuse_startand astartto show that it respects that and not the current robot TF starting pose.This test is helpful for completion (showing the BT is reacting well), but this isn't a test that fully encapsulates the main thing we need to have coverage over (that changing the start actually "works").
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
It is more complex than that, as I tried to express above, the current
system_tests/plannertests are never testing theComputePathToPoseaction_serverof theplanner_serverdefined here:https://github.com/ros-planning/navigation2/blob/2d88d14b1dd9f678e9b95dd50c5db774667cd62e/nav2_planner/src/planner_server.cpp#L132-L136
And hence, the logic of getting the pose of the robot as a start of the path (or the
use_startpotential override) as implemented in the action server of planner_server is never tested.Instead, it is the only the
createPlan(start, goal)fonction of theplanner_serverwhich is tested, not the full action. And theplanner_testerimplements its own logic for retrieving the start pose of the path, see here:https://github.com/ros-planning/navigation2/blob/2d88d14b1dd9f678e9b95dd50c5db774667cd62e/nav2_system_tests/src/planning/planner_tester.hpp#L77-L86
What we need, I believe, is to create tests calling the
ComputePathToPoseaction_serverof theplanner_server, for bothuse_starttrueandfalse. I might consider doing it if align and if you give me pointers on the architecture of it. Shouldplanner_testerbe extended to call the action ? Or a separate class ?Uh oh!
There was an error while loading. Please reload this page.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Got it, thanks for the explanation. I agree those tests are not probably in the structure for this testing.
The system tests have this structure of launching a launch description (which could just contain a lifecycle manager to transition up the planner server and the planner server) and then a test python node to trigger inputs and outputs. That could work here but the issue I see is that no info would actually come to the planner server, so you'd need to also have a
map_serverto publish some map for the planner server's costmap to be aware of. Then when you calledComputePathToPosein the python tester and be done (but probably have to fake out TF, which there are examples for in system_tests).It turns into a bit of a challenge. I could wave the testing of this one in CI if you verified locally that this worked fully. Though it might be a good exercise if you haven't done something like that before and I would never argue with more 😄
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Hum, it will be indeed a good exercise. No promise as I am very busy atm, but don't hesitate to ping me in a week or so if you see no progress (and yes, it was tested locally).