-
Notifications
You must be signed in to change notification settings - Fork 158
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
Fail early when Connect stage start state is in collision #573
Conversation
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.
With this change, you don't really fail earlier, do you?
Still, for all possible pairs of start and end states, the compute()
method is called, immediately failing if the start state is in collision.
The only thing you "save", is the instantiation of the planning infrastructure, which should immediately notice that the start state is in collision as well.
If that takes a significant amount of time, it should be better fixed in MoveIt's planning pipeline.
To me, it looks like that you just introduce yet another collision check, which seems redundant.
You mentioned that your console is spammed with error messages from the planning pipeline. I expect, that now the console is spammed with your generated error messages. Is simply printing these messages too slow?
I didn't yet considered the modified example. Will do that later, if I find time.
I was surprised, that the Connect stage considers input states that should have failed beforehand (due to collision). |
Sure, you can fail "early" in the adapter as well. |
Then why do some of them not succeed? You can see in the comment that the trajectory was "fixed" |
|
I mean why did the MTC stage not succeed? You can see that the comment on some of the trajectories were EDIT:
|
I implemented my suggestion from #573 (comment) in master: 9c05305 |
Thanks for the help and advice here @rhaschke! |
I have a project that I'm working on that was having motion planning failures when the start state of a Connect stage was in collision. My MoveIt config is on Humble and was missing the request_adapter
default_planner_request_adapters/FixStartStateBounds
so I was not getting any info other than planning failed and the terminal was spammed withMotion planning start tree could not be initialized!
for several seconds.After I added the request_adapter
default_planner_request_adapters/FixStartStateBounds
I could see which links were causing the failure but the Connect stage still attempted to search for a long period of time even though it was not possible to find a solution (I believe the amount of time is# of connecting states * myConnectStage.setTimeout(Value)
).This PR is a bit of a hack but I wanted to see if you think checking the start state for collisions before planning would be a useful addition. I have modified the demo program to highlight the issue if you would like to test it out. I was surprised that I could not replicate the issue by simply removing the Forbid collision (object support) stage so I added a second table to the scene that causes collision after the cylinder is lifted.
Right now my proposed solution is failing much faster but still not working as expected because it is not properly reporting the failure's to the Rviz MTC widget.