Skip to content

A visualization tool for path finding algorithms such as breadth first search, multi-source breadth first search, and A*. Features include, the ability to convert images to maps using edge detection, custom maps by drawing, and variable play/grid settings. And just for fun a convolutional neural network predicts the optimal settings for the A* h…

License

Notifications You must be signed in to change notification settings

LPRowe/path-finding-visualizer

Repository files navigation

path-finding-visualizer

Readme is under construction, cleaner details to come...

Intro

A path finding visualizer that implements BFS, Multisource BFS, and A* algorithms to find the shortest path between the two blue points.

Press i to spawn pdf images where a sobel filter is applied and the images are converted to maze like arrays.

Press f (fast) or s (slow) to adjust program's frame rate.

Greediness of the A* algorithm is an adjustable parameter, in the path_finder_2.py version the optimal greed is automatically estimated by a machine learning model.

Grids can be randomly generated using the random grid button.

The density of the grids can be adjusted by the grid density buttoms

Use the reset button to clear the previous solution before running a new solution.

Colors

Grey pixels are obstacles. Black pixels are unvisited open spaces. Blue pixels mark the start point, target point, and optimal path.
Orange pixels are visited nodes.
Green pixels are nodes that are currenlty in the queue to be visited.

Try it yourself

Method 1: Click the Gitpod button below - wait a minute - pop the window out by clicking the expand button circled in the image below.

Open in Gitpod

Method 2: Clone this repo and run path_finder_2.py in python3, dependencies are listed in requirements.txt, if you do not already have TensorFlow installed, it may be simpler to just use path_finder_1. It has all of the same features except that it does not predict the optimal greediness for A*.

Examples:

Multisource Breadth First Search






Single Source Breadth First Search




A*





About

A visualization tool for path finding algorithms such as breadth first search, multi-source breadth first search, and A*. Features include, the ability to convert images to maps using edge detection, custom maps by drawing, and variable play/grid settings. And just for fun a convolutional neural network predicts the optimal settings for the A* h…

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages