-
-
Notifications
You must be signed in to change notification settings - Fork 101
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
Implementation Of Astar Path Planning #22
Conversation
src/components/obstacle/obstacle.py
Outdated
@@ -36,6 +36,8 @@ def __init__(self, state, accel_mps2=0.0, yaw_rate_rps=0.0, | |||
[width_m, width_m, -width_m, -width_m, width_m]]) | |||
self.array = XYArray(contour) | |||
|
|||
|
|||
|
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.
These added two lines are empty, they should be reverted before merging.
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.
This pycache file should not be committed. You can add this to .gitignore to ignore.
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.
This class includes a grid map construction algorithm simultaneously. This can be divided into the following two algorithm classes.
- Binary occupancy grid map construction class with clearances.
- A* global path planner class
A grid map base class has already existed in the repository and been used for the existing NDT map construction class. You also can refer to them. And then, it is required to be able to save the constructed map data as an external file like json. I consider that the A* path planner class can plan a global path by importing the saved external map data file.
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.
I have created 2 separate PR's for the other 2 classes.
@@ -0,0 +1,120 @@ | |||
""" | |||
ndt_map_construction.py |
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.
Please fix the file name in this header comment.
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.
Fixed it
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.
This simulation should be divided into the following three simulation files.
-
Binary occupancy grid map construction simulation file
A binary occupancy grid map with clearances can be constructed and the map data can be saved and exported as an external file like json or image. -
A* global path planning simulation file
A global path from start to goal can be planned by importing the above map data file. And then, the planned global path data can be saved and exported as an external file like json. -
Path tracking simulation file
The vehicle tracks the above planned global path interpolated with Cubic spline by importing the above path data file.
Please implement these simulation files individually and send me those PRs sequentially from 1 to 3.
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.
I have created the first 2. For the third one I wasn't sure if it should just have the path tracking or everything together. If the 3rd requires just the path tracking I will make the changes. Every class has it's own way of saving and loading results.
After you completed resolving each conversations, please add those unit test codes refer to the existing test codes finally. |
This PR can not be accepted because should be recreated as multiple new PRs. |
PR Description: A* Path Planning Implementation for Autonomous Vehicles
Overview
This PR introduces an A* path planner designed for autonomous vehicle applications. The implementation includes robust grid-based path planning, obstacle handling, and visualization, along with the ability to generate sparse paths for cubic spline interpolation. Below are the key features, considerations, and future enhancements of this project.
Key Features
Grid-Based A* Path Planning:
x_lim
,y_lim
) and resolution.Obstacle Handling and Clearance:
Action Set:
Visualization:
Efficient Exploration:
Sparse Path Generation:
Integration with CubicSplineCourse:
CubicSplineCourse
class, which creates a smooth course for the vehicle to follow.Considerations and Future Enhancements
Improved Motion Model:
Action Set Optimization:
Visualization Improvements:
Animation Speed:
Dynamic Obstacles:
How to Use
Input:
x_lim
,y_lim
) and resolution.Path Planning:
Sparse Path Generation:
Cubic Spline Integration:
CubicSplineCourse
class to create a smooth course.Limitations
Conclusion
This implementation provides a foundational A* path planner with efficient exploration, robust obstacle handling, and integration with cubic spline trajectory generation. It serves as a base for further enhancements to address car-specific needs and dynamic environments.