Skip to content
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

There may be infinite loop if there is no way from start point to goal point #44

Open
TachikakaMin opened this issue Sep 27, 2022 · 6 comments

Comments

@TachikakaMin
Copy link

I think it could have infinite loop if no way from start point to goal point since there is an additional parameter(time) in State. And when you add a State to the set and queue, timestep may be different for same (x,y) so the set won't have any effort.

Correct me if I'm wrong.

@whoenig
Copy link
Owner

whoenig commented Sep 27, 2022

For A*, the algorithm is correct. For CBS (and related variants), you are correct that they do not terminate if no solution exist. This is also the case in the original papers. Termination can be achieved by using CBS+SIPP at the low-level, or by first checking if a solution exists using suboptimal solvers (not implemented here).

@yfb10
Copy link

yfb10 commented Jun 23, 2023

For A*, the algorithm is correct. For CBS (and related variants), you are correct that they do not terminate if no solution exist. This is also the case in the original papers. Termination can be achieved by using CBS+SIPP at the low-level, or by first checking if a solution exists using suboptimal solvers (not implemented here).

Hi,
Thanks for your information. Could you provide an example code for CBS+SIPP at the low level. And how do you expect the performance of SIPP as the low level search compared to A* in CBS?

@whoenig
Copy link
Owner

whoenig commented Jun 25, 2023

I don't have example code ready, but you essentially just replace the low-level planner template from Astar to SIPP. When I tried it a few years back, it was slightly slower than regular CBS.
However, other authors have reported advantages, see https://github.com/PathPlanning/Continuous-CBS/tree/master for link to papers and an alternative implementation.

@yfb10
Copy link

yfb10 commented Jun 27, 2023

I don't have example code ready, but you essentially just replace the low-level planner template from Astar to SIPP. When I tried it a few years back, it was slightly slower than regular CBS. However, other authors have reported advantages, see https://github.com/PathPlanning/Continuous-CBS/tree/master for link to papers and an alternative implementation.

I assume aside from replacing the low-level search to Sipp, converting constraints of high level to safe interval of the cell is also needed, right?
Another confusion comes from the "wait" actions from Sipp and CBS. The CBS_a* takes an extra wait action in get_neighbors while a* explores the map, and SIPP adds a "wait" time. From what I'm understanding, it will be repeated if I directly merge CBS with SIPP. I should abandon the wait in get_neighbors and use the wait time in SIPP, right?

@whoenig
Copy link
Owner

whoenig commented Jun 30, 2023

Correct (to both questions). If you get it working it would be nice if you share it. I remember having implemented it before with this library, but it doesn't seem to be in any of the branches.

@yfb10
Copy link

yfb10 commented Jul 1, 2023

Correct (to both questions). If you get it working it would be nice if you share it. I remember having implemented it before with this library, but it doesn't seem to be in any of the branches.

Thanks. Will pull the request once I make it works.

One more question comes with setting the safe intervals from constraints for an agent.
It's quite straightforward to set safe intervals from vertex constraints. But how should we deal with the edge constraints?
Following the convention in sipp.hpp, I should iterate over all constraints and use "setCollisionIntervals" to save all safe intervals in m_safeIntervals. And m_safeIntervals is iterated and checked when exploring neighbors. Another method I came up with is to iterate over the constraints and build corresponding safe intervals directly in the process of getting neighbors. That is to build SI based on whether constraints are found upon the next location and time of the "neighbors". This method will be theoretically a bit faster than the previous one as it gets rid of m_safeinterval, right?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants