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

the running time of JPS #11

Open
GitaHubMartin opened this issue Jun 20, 2024 · 1 comment
Open

the running time of JPS #11

GitaHubMartin opened this issue Jun 20, 2024 · 1 comment

Comments

@GitaHubMartin
Copy link

Why is the python version of JPS not as efficient as A*?

@omigeft
Copy link
Collaborator

omigeft commented Jun 23, 2024

In my testing, JPS took much less time than A*. If you still encounter situations where JPS runtime performance is not as good as A*, please provide your map and specific runtime of the two planners.
Below is a simple testing example:

import time
import python_motion_planning as pmp

a_star_planner = pmp.AStar((5, 5), (45, 25), pmp.Grid(51, 31))
start_time = time.time()
cost, path, expand = a_star_planner.plan()
print("AStar Planning time: ", time.time() - start_time)

jps_planner = pmp.JPS((5, 5), (45, 25), pmp.Grid(51, 31))
start_time = time.time()
cost, path, expand = jps_planner.plan()
print("JPS Planning time: ", time.time() - start_time)

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

2 participants