-
Notifications
You must be signed in to change notification settings - Fork 1.4k
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
[MPPI] obstacles critic alternative #4057
Comments
Sorry, its taken me some time to get to this, Guillaume and I had alot of outcomes from our onsite week and finally ready to address this one! Can you explain the dual checks on cost at point; those are expensive to do this many The main thing I'd like to discuss is the actual scoring part. I have a main concern:
This bit means that the non-circular footprint's cost could be marked as
How sensitively did you have to tune the gains to make it work reasonably well? If you made It also treats unknown space as an obstacle without a call out to say its OK, but that's easy enough to fix. Note to self.
I'm curious, did you try normalizing this from 0-1.0 instead of using the raw costs? Did you run into any issues with that? That way the weights could be in a similar order as the others. Note to self: I decoupled this into a separate At the end of the day, if it works; it works and happy to have another person take a look and succeed where I did not! I am concerned about working with confined spaces and how sensitive the parameter space is, so your experiences creating and tuning this would be valuable. I'll plan to download and play with this after I get your notes and see what I think too |
After some testing: while I don't believe its the end-all-be-all solution for eveything, I suppose it doesn't hurt to provide options. I found that it struggled
I'm going to do a little code cleanup and open a new PR for inclusion with documentation. I'll link back here for you to review |
#4090 Please review! Pausing for lunch, but if you're reading this, I probably already added the docs and unit tests, which are my next steps. Once I'm done with those quality steps and I have your testing 👍 I can merge and announce the update! |
Its still heavy to check even just the point. I've done benchmarking on this, even with just checking a single point cost each of the In my refactor, I restored it to only a single point check.
Ah, that's the subtlty here, you're checking collisions based on the SE2 footprint, but scoring based on center costs. That is subtle and worth you testing to make sure I didn't break anything with that refactor. I'll also make a note of that in the code since I missed that and I read / refactored it. |
I will check again. |
As discussed in PR #3878 , here is an Issue to start a discussion about the obstacles critic.
Feature discussion
The
ObstaclesCritic
is a critic to increase trajectory score based on the distance to obstacles. With this critic, the MPPI will prefer trajectories that avoid obstacles. It works well but some points can be discussed.obstacles_critic
uses the cost frominflattion_layer
to compute distances by using the invert function of the cost.It makes inflation_layer
cost_scaling_factor
tunning useless, it's good because it reduces tunning and it may be dangerous as it has a quantization effect on the distance. It also increases the computation load.The repulsive cost uses the inflation radius that is not related to safety distance. The
traj_cost
is computed but only used iftrajectory_collide
.footprintCostAtPose
returns the highest cost which will be "INSCRIBED" whatever the distance to the obstacle,distanceToObstacle(cost)
will return the same distance so the score will be the same in a situation where it is important to evade obstacles.Proposed alternative
The proposed
InflationCostCrtic
is a simplified version of theObstaclesCritic
;repulsive_cost[i] += pose_cost.cost
This critic benefits from the exponential factor of the inflation layer, it creates a behavior where the robot is forced in the middle of narrow corridors but can easily evade obstacles in wider spaces. It will be able to take shortcuts from the path without going too close to corners.
Here are the default parameters:
Implementation considerations
I will create a PR to share my code but it is not up to date this the latest commits.
The text was updated successfully, but these errors were encountered: