Coder Social home page Coder Social logo

2dgeometricshapesgenerator's Introduction

2D Geometric shapes generator

A generator of 2D geometric shape data set, this data set is composed of a set of images stored in png files. Each image contains one of the following shapes : Square, Traingle, Circle, Star, Polygon, Heptagone, Hexagone, Octagone and Nonagon.

Each image is generated within the following parameters :

  • A fixed size of 200x200 pixel

  • A random background colour

  • A random filling colour of each shape

  • A random rotation angle between -180° and 180°

  • A random position inside of the containing image

  • A random perimeter

All the parameters described above are generated for each sample independently and identically.

Installation

Clone the source code with :

clone https://github.com/elkorchi/2DGeometricShapesGenerator.git

Install project requirements specified in requirements.txt :

pip install - r requirements.txt 

Run the data set generation with :

python shape_generator.py generate-shapes --size=1000 --destination=/storage/directory

The generation command may accept the following option :

  • --size (required): The number of generated images per each shape
  • --destination (required): The path of the folder where the generated images will be stored.
  • --show-animation (optional): If specified the drawing animation of each image, will be activated. Note that if this option is activated, the generation process will be very slow.

2dgeometricshapesgenerator's People

Contributors

csyuhao avatar dependabot[bot] avatar elkorchi avatar

Watchers

 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.