Giter VIP home page Giter VIP logo

maze's Introduction

Maze

Create Mazes of different types or generate Datasets to train your Maze GANs or Reinforcement Learning agents. Rectangular Maze Dataset on Kaggle.

hexagonal-maze.mp4

To understand how these Mazes are constructed, watch the accompanying ⏵︎video tutorials.

Quick Start

No installations required. Just clone this repository and run code

$ git clone https://github.com/emadehsan/maze

$ cd maze/src

# draw a rectangular maze
$ python rectangular.py

# or a circular maze
$ python circular.py

# or a triangular maze
$ python triangular.py

# or a hexagonal maze
$ python hexagonal.py

Generate Maze Dataset

You can also generate a dataset of Mazes. Right now, only Rectangular (actually Squared) Mazes are supported.

Use the scripts in src/datasets.

Example:

$ cd src/datasets/
$ python generate_rect_dataset.py -rows 10 -width 10 -items 1000

This will create a folder inside src/datasets with name rectangular_mazes_TIME. The folder will contain

  • Mazes as png images
  • logs.txt containing information about process (can be discarded)
  • spanning_tree.txt containing the Spanning Tree edges used to create the corresponding maze

Link to Rectangular Maze Dataset on Kaggle.

Current Mazes

  • Rectangular Maze using Randomized Prim's Algorithm [ tutorial ]

    Squared Maze using Prims Algorithm
  • Circular Maze using Depth First Search [ tutorial ]

    Circular Maze using Depth First Search
  • Triangular Maze using Depth First Search

    Triangular Maze using Depth First Search
  • Triangular Maze using Kruskal's Algorithm

    Triangular Maze using Kruskal Algorithm
  • Hexagonal Maze using Depth First Search

    Hexagonal Maze using Depth First Search

Note

  • Please share your feedback by creating an issue or on Twitter

maze's People

Contributors

emadehsan avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.