Skip to content

RohanKP1/pathfinding-visualizer

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

7 Commits
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Pathfinding Algorithms Visualizer

The "pathfinding-visualizer" project is a Python-based application that utilizes the Pygame library and custom tkinter components. Its primary purpose is to provide a visual representation of three different pathfinding algorithms: A-star, Dijkstra, and Depth-First Search (DFS).

Users of this project can interact with it to observe how these algorithms work in finding the optimal paths within a specified grid or maze. Here are some key features and components of the project:

  1. Python-Based: The project is written in Python, making it accessible to a wide range of users who are familiar with the language.

  2. Pygame: Pygame is used for rendering graphics and creating an interactive environment for visualizing the pathfinding algorithms. It offers a simple way to handle graphics and user input.

  3. tkinter Components: Custom tkinter components are integrated into the project's user interface to provide user controls and options for selecting algorithms, adjusting settings, and interacting with the visualization.

  4. Pathfinding Algorithms:

    • A-star: A-star is a popular pathfinding algorithm known for finding the shortest path efficiently while considering both the cost to reach a node and a heuristic estimate of the remaining cost.
    • Dijkstra: Dijkstra's algorithm is used to find the shortest path in a weighted graph, considering only the cost to reach a node without any heuristic estimation.
    • DFS (Depth-First Search): DFS is a graph traversal algorithm that explores as far as possible along each branch before backtracking.
  5. Grid or Maze Environment: Users can create custom grids or mazes within the application, providing a practical scenario for testing and visualizing the pathfinding algorithms.

Overall, the "pathfinding-visualizer" project is a valuable tool for educational purposes and practical applications, allowing users to gain insights into the behavior and efficiency of different pathfinding algorithms by visually observing their operation within a grid or maze environment.

Screenshot-2023-09-10-174155 Screenshot-2023-09-10-174615

Commands:

  • SPACE - Starts the algorithm
  • R - Resets the screen
  • LEFT MOUSE BUTTON - Draw the node
  • RIGHT MOUSE BUTTON - Erase the node