Maze generator and solver with python

Overview

Procedural-Maze-Generator-Algorithms

Check out my youtube channel : Auctux

Ressources

Requirements

PYGAME : pip install pygame

Commands Controls:

  • Esc to close the program
  • Enter to start to genrate the maze
  • H to show the heuristic cost value
  • S to show the path from the starting to the goal node
  • Space to switch between the color modes

files

  • run main.py for grid mazes
  • run polarMaze.py for polarGrid maze
  • run hexMaze.py for hexGrid maze
  • run imageMaze.py for maskGrid maze
  • run weightedMaze.py for weightedGrid maze

you can also braid your mazes when it done , by calling the function grid.Braid(). braiding a maze simply assures that the maze doens't have any deadends

colors modes

Mode 1 : Mode 2 :

other Maze Grid:

Polar Grid : HexGrid : maskGrid :

Show heuristic and path

  • heuristic :
  • showPath :

Bugs & Unsolved Issues

  • The code need a lot of refactoring
  • the visualization of the polar maze need a lot of improvement
  • the the imagemaze.py file need to be refactored for it to be able to work on every size of images , for now it's only working for images wich has the same size with the screen size
  • the recursive backtracker class need a little bit of cleaning
  • add Comments
  • implement the ui interface
  • the djikistra algorithm need to take the weights of cells in consideration for weightedGrid

mazes


initialize:
 binary_tree = BinaryTree(Grid(rows, cols, cell_size), "GREEN")
 wilson = Wilson(Grid(rows, cols, cell_size), "PURPLE_E")
 side_winder = SideWinder(Grid(rows, cols, cell_size), "BLUE")
 hunt_and_kill = HuntAndKill(Grid(rows, cols, cell_size), "RED")
 aldous_broder = AldousBroder(Grid(rows, cols, cell_size), "GREEN")
 recursive_backtracker = RecursiveBacktracker(Grid(rows, cols, cell_size), "BLUE")
 kruskal = Kruskals(Kruskals.State(Grid(rows, cols, cell_size)))
 simplePrims = SimplePrims(Grid(rows, cols, cell_size), "CYAN")
 prims = Prims(Grid(rows, cols, cell_size))
 growingTree = GrowingTree(Grid(rows, cols, cell_size), "GREEN")
 ellers = Ellers(Grid(rows, cols, cell_size), 0, "RED")
mainloop():
 wilson.Generate(screen, show_text, color_mode, show_path)
 binary_tree.Generate(screen, show_text, color_mode, show_path)
 kruskal.Generate(screen, show_text, color_mode, show_path)
 side_winder.Generate(screen, show_text, color_mode, show_path)
 hunt_and_kill.Generate(screen, show_text, color_mode, show_path)
 aldous_broder.Generate(screen, show_text, color_mode, show_path)
 recursive_backtracker.Generate(screen, show_text, color_mode, show_path)
 simplePrims.Generate(screen, show_text, color_mode, show_path)
 prims.Generate(screen, show_text, color_mode, show_path)
 growingTree.Generate(screen, show_text, color_mode, show_path)
 ellers.Generate(screen, show_text, color_mode, show_path)

  • Aldous Broder

  • Binary Tree

  • Eller's Algorithm

  • Growing Tree

  • Hunt And kill

  • Kruskal's algorithm

  • Prims Algorithm

  • Simplified Prims

  • Wilson algorithm

  • Sidewinder Algorithm

  • Recursive Backtracker

Enjoy ✌️

Owner
Joseph
Change the world, one line of code at a time ; )
Joseph
Comparison-of-OCR (KerasOCR, PyTesseract,EasyOCR)

Optical Character Recognition OCR (Optical Character Recognition) is a technology that enables the conversion of document types such as scanned paper

21 Dec 25, 2022
governance proposal to make fei redeemable for eth

Feil Proposal 🌲 Abstract Migrate all ETH from Fei protocol-controlled value into Yearn ETH Vault. Allow redemptions of outstanding FEI for yvETH. At

13 Mar 31, 2022
caffe re-implementation of R2CNN: Rotational Region CNN for Orientation Robust Scene Text Detection

R2CNN: Rotational Region CNN for Orientation Robust Scene Text Detection Abstract This is a caffe re-implementation of R2CNN: Rotational Region CNN fo

candler 80 Dec 28, 2021
nofacedb/faceprocessor is a face recognition engine for NoFaceDB program complex.

faceprocessor nofacedb/faceprocessor is a face recognition engine for NoFaceDB program complex. Tech faceprocessor uses a number of open source projec

NoFaceDB 3 Sep 06, 2021
Responsive Doc. scanner using U^2-Net, Textcleaner and Tesseract

Responsive Doc. scanner using U^2-Net, Textcleaner and Tesseract Toolset U^2-Net is used for background removal Textcleaner is used for image cleaning

3 Jul 13, 2022
Text to QR-CODE

QR CODE GENERATO USING PYTHON Author : RAFIK BOUDALIA. Installation Use the package manager pip to install foobar. pip install pyqrcode Usage from tki

Rafik Boudalia 2 Oct 13, 2021
Convolutional Recurrent Neural Network (CRNN) for image-based sequence recognition.

Convolutional Recurrent Neural Network This software implements the Convolutional Recurrent Neural Network (CRNN), a combination of CNN, RNN and CTC l

Baoguang Shi 2k Dec 31, 2022
A document scanner application for laptops/desktops developed using python, Tkinter and OpenCV.

DcoumentScanner A document scanner application for laptops/desktops developed using python, Tkinter and OpenCV. Directly install the .exe file to inst

Harsh Vardhan Singh 1 Oct 29, 2021
Write-ups for the SwissHackingChallenge2021 CTF.

SwissHackingChallenge 2021 : Write-ups This repository contains a collection of my write-ups for challenges solved during the SwissHackingChallenge (S

Julien Béguin 3 Jun 07, 2021
Handwritten Character Recognition using CNN

Handwritten Character Recognition using CNN Problem Definition The main objective of this project is to solve the problem of handwritten character rec

Mohit Kaushik 4 Mar 02, 2022
Automatic Number Plate Recognition (ANPR) is a highly accurate system capable of reading vehicle number plates without human intervention

ANPR ANPR is therefore the underlying technology used to find a vehicle license/number plate and it, in turn, supplies this information to a next stag

Melih Emin Kılıçoğlu 1 Jan 09, 2022
Controlling Volume by Hand Gestures

This program allows the user to control the volume of their device with specific hand gestures involving their thumb and index finger!

Riddhi Bajaj 1 Nov 11, 2021
Repository relating to the CVPR21 paper TimeLens: Event-based Video Frame Interpolation

TimeLens: Event-based Video Frame Interpolation This repository is about the High Speed Event and RGB (HS-ERGB) dataset, used in the 2021 CVPR paper T

Robotics and Perception Group 544 Dec 19, 2022
Hand gesture detection project with aweome UI implementation.

an awesome hand gesture detection project for you to be creative! Imagination is the limit to do with this project.

AR Ashraf 39 Sep 26, 2022
An interactive document scanner built in Python using OpenCV

The scanner takes a poorly scanned image, finds the corners of the document, applies the perspective transformation to get a top-down view of the document, sharpens the image, and applies an adaptive

Kushal Shingote 1 Feb 12, 2022
The Open Source Framework for Machine Vision

SimpleCV Quick Links: About Installation [Docker] (#docker) Ubuntu Virtual Environment Arch Linux Fedora MacOS Windows Raspberry Pi SimpleCV Shell Vid

Sight Machine 2.6k Dec 31, 2022
A little but useful tool to explore OCR data extracted with `pytesseract` and `opencv`

Screenshot OCR Tool Extracting data from screen time screenshots in iOS and Android. We are exploring 3 options: Simple OCR with no text position usin

Gabriele Marini 1 Dec 07, 2021
Open Source Differentiable Computer Vision Library for PyTorch

Kornia is a differentiable computer vision library for PyTorch. It consists of a set of routines and differentiable modules to solve generic computer

kornia 7.6k Jan 04, 2023
Document Layout Analysis

Eynollah Document Layout Analysis Introduction This tool performs document layout analysis (segmentation) from image data and returns the results as P

QURATOR-SPK 198 Dec 29, 2022
"Very simple but works well" Computer Vision based ID verification solution provided by LibraX.

ID Verification by LibraX.ai This is the first free Identity verification in the market. LibraX.ai is an identity verification platform for developers

LibraX.ai 46 Dec 06, 2022