PathMind is an advanced, high-performance pathfinding visualizer built with a striking Neo-Brutalist aesthetic. It allows you to explore and compare various search algorithms—ranging from classic A* and Dijkstra to advanced Bidirectional BFS and IDA*—through three interactive lenses:
- Sandbox Mode: Manually build grids, place walls, and watch algorithms solve paths in real-time.
- Algorithm Comparator: A "racing" view where multiple algorithms compete on the same maze to compare speed and efficiency.
- Real-World Showcase: Interactive demonstrations of how these algorithms power everyday tech like GPS navigation, flight routing, and social network analysis.
- 🏎️ Algorithm Comparator: A dedicated racing view where you can watch 6 algorithms (BFS, DFS, A*, UCS, Greedy, Bi-BFS) compete side-by-side on identical mazes to compare speed, efficiency, and optimality.
- 🌍 Real-World Showcase: An interactive, application-first view mapping search algorithms to their real-world counterparts (e.g., BFS for Social Networks, A* for GPS, DLS for Tic-Tac-Toe AI).
- 🏗️ Neo-Brutalist Design: A high-contrast, premium interface featuring sharp edges, bold typography (Plus Jakarta Sans), and a curated color palette for a truly modern feel.
- ⚡ High-Speed Execution: Backend-driven pathfinding logic implemented in Python for precision, bridged with smooth HTML5 Canvas animations.
- 🛠️ Interactive Sandbox: Paint walls, drag start/end markers, adjust search limits, and watch the algorithms adapt in real-time.
- 🌙 Theme Support: Seamless switching between high-contrast Light and Dark modes.
PathMind implements a wide array of search strategies, categorized by their approach:
- Breadth-First Search (BFS): Guaranteed to find the shortest path in unweighted grids.
- Depth-First Search (DFS): Prioritizes depth over optimality; efficient in memory but rarely shortest.
- Uniform Cost Search (UCS): Dijkstra's algorithm optimized for grid costs.
- Depth-Limited Search (DLS): A controlled version of DFS with a hard depth cutoff.
- Bidirectional BFS: Meets in the middle for exponential performance gains in large spaces.
- A Search*: The "Gold Standard"—uses Manhattan heuristics to find optimal paths with minimal exploration.
- Greedy Best-First Search: Focused entirely on the goal; blazing fast but can get trapped in local optima.
- IDA (Iterative Deepening A)**: Explores paths with increasing cost limits, combining the optimality of A* with the memory efficiency of DFS.
- Backend: Python 3.x / Flask
- Frontend: Vanilla JavaScript (ES6+), HTML5 Canvas, CSS3 Custom Properties
- Logic: Modular pathfinding library in
src/supporting weighted and unweighted grids. - Styling: Neo-Brutalist framework using
Plus Jakarta Sans&Syne.
- Python 3.8 or higher
pip(Python package manager)
-
Clone the repository:
git clone https://github.com/yourusername/Pathmind.git cd Pathmind -
Set up a Virtual Environment (recommended):
python -m venv .venv # Windows: .venv\Scripts\activate # macOS/Linux: source .venv/bin/activate
-
Install Dependencies:
pip install -r requirements.txt
-
Run the App:
python app.py
-
Explore: Navigate to
http://127.0.0.1:5000in your browser.
Pathmind/
├── app.py # Flask Application Entry Point
├── src/ # Core Algorithm Implementations (A*, BFS, etc.)
├── comparator_logic/ # Multi-grid maze generation and racing logic
├── static/ # Frontend assets (CSS, JS)
├── templates/ # HTML Templates (Sandbox, Showcase, Comparator)
└── requirements.txt # Project dependencies
A huge thank you to paratesai316 for the co-development of key features, including:
- Real Map Implementation: Integration of geographical coordination and grid-to-map mapping.
- Flight Search: Development of specialized pathfinding logic for airline routing and global city discovery.
Distributed under the MIT License. See LICENSE for more information.
Developed with ❤️ by Parth 🚀