An interactive AI-powered rescue drone simulation that navigates a grid environment to locate victims using BFS, DFS, and A* search algorithms — with a stunning sci-fi visualizer.
┌─────────────────────────────────────────────────────┐
│ 🚁 SKYSENTINEL · AI RESCUE DRONE AGENT │
│ ▸ BFS · DFS · A* PATHFINDING · GRID WORLD ENGINE │
├──────────────┬──────────────┬───────────────────────┤
│ ALGORITHM │ PATH LENGTH │ NODES EXPLORED │
│ A* │ 7 │ 7 │
├──────────────┴──────────────┴───────────────────────┤
│ . # . . . . . . # 🚁 = Drone Start │
│ . . # . # . . . . 🎯 = Victim |
│ # # . . . # . . . * = A* Path │
│ . . . . # . # . . # = Obstacle │
│ # . . . . V * * * . = Free Cell │
└─────────────────────────────────────────────────────┘
| Feature | Description |
|---|---|
| 🧠 3 AI Algorithms | Full BFS, DFS, and A* implementations with real pathfinding |
| 🗺️ Dynamic Grid World | Configurable 10×25 grid with random obstacles and victim placement |
| 📊 Live Comparison | Side-by-side stats — path length and nodes explored for all 3 algorithms |
| 🎨 Sci-Fi UI | Dark HUD-style Streamlit interface with Orbitron fonts and neon accents |
| 📈 Visual Charts | Bar charts comparing algorithm efficiency in real time |
| ⚡ Interactive Controls | Adjust grid size, obstacle density, and algorithm — regenerate instantly |
| 🏆 Winner Detection | Automatically highlights the optimal algorithm with ★ OPTIMAL badge |
🔵 BFS — Breadth First Search
- Uses a
dequeas the frontier queue (FIFO) - Explores all neighbours level by level
- Guarantees the shortest path
- Higher node exploration count compared to A*
- Returns:
(path, nodes_explored)
🟠 DFS — Depth First Search
- Uses a
listas a stack (LIFO) - Dives deep along one branch before backtracking
- Does NOT guarantee shortest path
- Can find paths quickly on open grids
- Returns:
(path, nodes_explored)
🟢 A\* — A-Star Search
- Uses
heapq(priority queue) withf = g + h g_cost= steps taken so farh_cost= Manhattan distance to victim- Optimal AND efficient — fewest nodes explored
- Returns:
(path, nodes_explored)
🚁 rescue-drone-agent/
│
├── 📄 algorithms.py # BFS, DFS, A* search implementations
├── 📄 environment.py # Grid world engine (obstacles, victim, drone)
├── 📄 main.py # Integration layer + run_simulation()
├── 📄 app.py # Streamlit UI (sci-fi visualizer)
└── 📄 requirements.txt # Python dependencies
git clone https://github.com/yourusername/skysentinel.git
cd skysentinelpip install -r requirements.txtpython -m streamlit run app.pyhttp://localhost:8501
1. ⚙️ Set Grid Size → Drag the slider (10–25)
2. 🧱 Set Obstacle Density → Lower = easier path, Higher = harder
3. 🧠 Select Algorithm → BFS / DFS / A*
4. ▶️ Click RUN SIMULATION → Watch the drone find its path
5. 📊 Compare Results → See which algorithm wins
💡 Tip: Set obstacle density to ~0.20 for best results. Too high and no path can be found!
| Algorithm | Path Optimality | Nodes Explored | Speed |
|---|---|---|---|
| BFS | ✅ Shortest | High | Medium |
| DFS | ❌ Not optimal | Medium | Fast |
| A* | ✅ Shortest | Lowest | Fastest |
A* wins every time — it finds the shortest path while exploring the fewest nodes, thanks to the Manhattan distance heuristic.
Python 3.10+ → Core language
NumPy 2.x → Grid world array operations
Matplotlib 3.x → Grid & chart visualizations
Streamlit 1.x → Interactive web UI
heapq → A* priority queue
collections.deque → BFS frontier queue| Member | Roll No | Role |
|---|---|---|
| Bhoomika Poddar | RA2411026010571 | AI Core & Algorithms |
| Farzan Alam | RA2411026010573 | Simulation & Integration |
| Akshit Gaurana | RA2411026010576 | Frontend UI & Demo |
21CSC206T — Artificial Intelligence | SRM Institute of Science and Technology
MIT License — free to use, modify, and distribute.
**Made with ❤️
21CSC206T · Artificial Intelligence · SRM IST
⭐ Star this repo if you found it helpful!