Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

Commit c3308f6

Browse files
Update README.md
1 parent dbdc8c3 commit c3308f6

File tree

1 file changed

+58
-19
lines changed

1 file changed

+58
-19
lines changed

‎README.md

Lines changed: 58 additions & 19 deletions
Original file line numberDiff line numberDiff line change
@@ -1,30 +1,69 @@
11
# Pathfinding_Visualization_Tool_Python
2-
It allows users to visualize the behavior of two popular pathfinding algorithms: A* (A-star) and BFS (Breadth-First Search). The tool features an intuitive graphical interface where users can interactively set up obstacles and start points, then watch in real-time as the algorithms calculate and display the shortest path.
32

4-
#Features of the tool:
3+
## Description
54

6-
- Implement Algorithms: Implement pathfinding algorithms like A*, Dijkstra's, and Breadth-First Search (BFS).
7-
- Visualization: Visualize the algorithms in real-time using a graphical user interface.
8-
- Interactive: Allow users to set start and end points, and obstacles on a grid.
9-
- User Control: Provide options to step through the algorithm or run it in real-time.
5+
This Python tool allows users to visualize the behavior of two popular pathfinding algorithms: A* (A-star) and Breadth-First Search (BFS). It features an intuitive graphical interface where users can interactively set up obstacles, start, and end points on a grid. Users can then watch in real-time as the algorithms calculate and display the shortest path. This tool is excellent for understanding how these algorithms work and comparing their performance.
106

11-
#Interacting with the Tool
7+
## Features
128

13-
- Start Point: Click on a cell in the grid where you want to set the start point. The cell will turn green.
14-
- End Point: Click on a cell in the grid where you want to set the end point. The cell will turn blue.
15-
- Obstacles: Click on any cell to place an obstacle (wall). The cell will turn gray.
16-
- Removing Points and Obstacles:
17-
- Right Mouse Button: Click on a cell with the right mouse button to remove obstacles or clear the start and end points. The cell will return to the default color (black).
9+
* **Algorithm Implementations:** Implements A* (A-star) and Breadth-First Search (BFS) pathfinding algorithms. 🤖
1810

19-
# Running the Algorithm:
11+
***Real-time Visualization:** Visualizes the search process of the algorithms in real-time using a graphical user interface. 👀
2012

21-
- A Algorithm*: Press the SPACE key to run the A* pathfinding algorithm. The algorithm will search for a path from the start point to the end point and visualize the search process.
22-
- BFS Algorithm: Press the B key to run the Breadth-First Search (BFS) algorithm. Similar to A*, it will search for a path and visualize the process.
23-
Visual Feedback:
13+
* **Interactive Grid:** Users can interactively set start and end points, and place obstacles (walls) on the grid. 🧱
2414

25-
- Open Cells: Cells being explored during the search will turn white.
26-
- Closed Cells: Cells that have been fully explored and cannot be part of the path will turn gray.
27-
- Path: Once the path is found, it will be highlighted in red.
15+
* **User Control:** Options to step through the algorithm or run it in real-time. ⏯️
16+
17+
* **Start/End Point Placement:** Click to set the start (green) and end (blue) points. 🟢🔵
18+
19+
* **Obstacle Placement:** Click to place obstacles (walls) on the grid (gray). 🚧
20+
21+
* **Removal:** Right-click to remove obstacles or clear start/end points (back to black). ⬛
22+
23+
* **A* Algorithm Execution:** Press SPACE to run the A* algorithm. ✨
24+
25+
* **BFS Algorithm Execution:** Press B to run the BFS algorithm. 🔍
26+
27+
* **Visual Feedback:**
28+
* **Open Cells (Explored):** Cells being explored turn white. ◻️
29+
* **Closed Cells (Fully Explored):** Cells that have been fully explored turn gray. ⬛
30+
* **Path:** The final shortest path is highlighted in red. 🟥
31+
32+
## Technologies Used
33+
34+
* **Python:** The primary programming language. 🐍
35+
36+
* **Pygame (or similar GUI library):** For creating the graphical user interface. 🎮
37+
38+
## Ideal For
39+
40+
* **Students:** Learning about pathfinding algorithms and data structures. 🧑‍🎓
41+
42+
* **Game Developers:** Visualizing pathfinding for game AI. 🎮
43+
44+
* **Algorithm Enthusiasts:** Exploring and comparing different search algorithms. 🤓
45+
46+
## How to Run
47+
48+
1. **Clone the repository:** `git clone <repo url>`
49+
50+
2. **Install Pygame:** `pip install pygame` (or `pip install -r requirements.txt` if you have one)
51+
52+
3. **Run the program:** `python pathfinding_visualizer.py` (or `python3 pathfinding_visualizer.py`)
53+
54+
## How to Use
55+
56+
1. Click on the grid to set the start (green) and end (blue) points.
57+
58+
2. Click on cells to create obstacles (walls - gray).
59+
60+
3. Right-click to remove obstacles or clear start/end points.
61+
62+
4. Press SPACE to run the A* algorithm.
63+
64+
5. Press B to run the BFS algorithm.
65+
66+
6. Observe the visualization of the search process and the final path (red).
2867

2968
# A* Algorithm
3069

0 commit comments

Comments
(0)

AltStyle によって変換されたページ (->オリジナル) /