Remove graph nodes from locked-off hallways when searching for paths #253
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.
This kind of started as a hack, but I'm really warming up to it in that I can't think of anything better that won't take some serious recursive / geometric analysis...
I recently ran into a "feature" with navigating to a hallway. Take this world:
If you are navigating to the hallway between
office
andcloset
, the default heuristic will tell the robot to go to the left side of the hallway because it's nearer to the current robot pose as the crow flies. But as you see, path planning will fail.This PR will look for "landlocked" hallways as described above by checking that there is at least one open hallway on either room, or that the robot isn't inside that room. If there isn't (like in the case of
closet
in the screenshot above), the navigation graph node on that side gets eliminated from consideration.If the hallway is locked on both rooms, then... yeah, path planning will fail in that there is no valid target. But I think that's okay.