All Projects โ†’ ghostwriternr โ†’ Lowpolify

ghostwriternr / Lowpolify

Licence: mit
Create low-poly art from any image ๐ŸŒŸ๐ŸŒŸ

Programming Languages

javascript
184084 projects - #8 most used programming language
python
139335 projects - #7 most used programming language

Projects that are alternatives of or similar to Lowpolify

Computer Vision Video Lectures
A curated list of free, high-quality, university-level courses with video lectures related to the field of Computer Vision.
Stars: โœญ 154 (+3.36%)
Mutual labels:  computer-graphics, image-processing
Pytorch Cyclegan
A clean and readable Pytorch implementation of CycleGAN
Stars: โœญ 558 (+274.5%)
Mutual labels:  computer-graphics, image-processing
Graphite
Open source 2D node-based raster/vector graphics editor (Photoshop + Illustrator + Houdini = Graphite)
Stars: โœญ 223 (+49.66%)
Mutual labels:  image-processing, art
Imgp
๐Ÿ“ธ High-performance cli batch image resizer and rotator
Stars: โœญ 744 (+399.33%)
Mutual labels:  image-processing, multiprocessing
Computational Graphics Thu 2018
Computational Graphics - THU Spring 2018
Stars: โœญ 104 (-30.2%)
Mutual labels:  computer-graphics, image-processing
L1stabilizer
๐ŸŽฅ Video stabilization using L1-norm optimal camera paths.
Stars: โœญ 111 (-25.5%)
Mutual labels:  computer-graphics, image-processing
Gerbolyze
Render high-resolution bitmap images to PCB gerber files
Stars: โœญ 169 (+13.42%)
Mutual labels:  computer-graphics, art
St Cgan
Dataset and Code for our CVPR'18 paper ST-CGAN: "Stacked Conditional Generative Adversarial Networks for Jointly Learning Shadow Detection and Shadow Removal"
Stars: โœญ 13 (-91.28%)
Mutual labels:  computer-graphics, image-processing
Awesome Creative Coding
Creative Coding: Generative Art, Data visualization, Interaction Design, Resources.
Stars: โœญ 8,696 (+5736.24%)
Mutual labels:  computer-graphics, art
Photomosaic Generator
photomosaic generator (image to image, video to video)
Stars: โœญ 106 (-28.86%)
Mutual labels:  image-processing, art
Reproducible Image Denoising State Of The Art
Collection of popular and reproducible image denoising works.
Stars: โœญ 1,776 (+1091.95%)
Mutual labels:  image-processing, art
Scene Text Recognition
Scene text detection and recognition based on Extremal Region(ER)
Stars: โœญ 146 (-2.01%)
Mutual labels:  image-processing
Art Dcgan
Modified implementation of DCGAN focused on generative art. Includes pre-trained models for landscapes, nude-portraits, and others.
Stars: โœญ 1,882 (+1163.09%)
Mutual labels:  art
Siberian
Siberian Single App Edition (SAE), free and open-source app builder.
Stars: โœญ 144 (-3.36%)
Mutual labels:  angularjs
Tai
tai (Terminal Ascii Image) tool to convert images to ascii written in Rust
Stars: โœญ 144 (-3.36%)
Mutual labels:  image-processing
Carrots Admin Ajax
ๅŸบไบŽAngularJS1.3.18 + BootStrap 3.3.7 + +jQuery3.2.1 ็š„ๅŽๅฐ็ฎก็†็ณป็ปŸๆ–นๆกˆ
Stars: โœญ 147 (-1.34%)
Mutual labels:  angularjs
Primitive
Reproducing images with geometric primitives.
Stars: โœญ 11,657 (+7723.49%)
Mutual labels:  art
Ascension
ANSI/ASCII art viewer for Mac OS X
Stars: โœญ 143 (-4.03%)
Mutual labels:  art
Highcharts Ng
AngularJS directive for Highcharts
Stars: โœญ 1,741 (+1068.46%)
Mutual labels:  angularjs
Paper
๐ŸŒˆ ไธ€ไธช็ฑป็บธ้ฃŽ็š„ไธป้ข˜paper๐ŸŽ‰(still updating...)
Stars: โœญ 142 (-4.7%)
Mutual labels:  art

lowpolify

npm version Build Status Deployment Status License

โ€œIโ€™ve been waiting for you, Obi-Wan. We meet again, at last. The circle is now complete. When I left you, I was but the learner; now I am the master.โ€ ๐Ÿ˜Ž๐Ÿ˜Ž๐Ÿ˜Ž

Warrior

PS. Formal introductions are yet to begin, in case you were wondering. ๐Ÿ˜…

Introduction

The goal of lowpolify is quite simple. Generate low poly versions of any given image.

Now what is 'low poly' you may ask.

Here's what Wikipedia has for you: Low poly is a polygon mesh in 3D computer graphics that has a relatively small number of polygons. Low poly meshes occur in real-time applications (e.g. games) and contrast with high poly meshes in animated movies and special effects of the same era. The term low poly is used in both a techni... yada yada yada you get the idea. Basically objects composed of only polygons. ๐Ÿ’๐Ÿ’

If you'd like to skip all the chit chat, here's the DEMO. Arr, matey, thar be ye booty!
https://lowpolify.ghostwriternr.me/

Approach

Take an image, lowpolify it and poof!! ๐Ÿ’ฅ LOW POLY, BABY!! ๐Ÿ’ƒ๐Ÿ’ƒ

Here's an ELI5 TLDR ๐Ÿ‘ถ :

  • Pre-process the input image to remove noise and reduce image size
  • Detect edges in the input image
  • If the image contains humans faces, detect facial features as well
  • Choose a random subset of the above detected points / edges
  • Triangulate using Delaunay Triangulation
  • Fill the triangles with the mean value of all pixels contained by it (in parallel for faster computation)
  • LOW POLY, BABY! ๐Ÿ’ƒ๐Ÿ’ƒ

Sample output

Lo and Behold!

High-poly input Low-poly output
Deepika Padukone Deepika Padukone
Jon Snow Jon Snow
Leonardo DiCaprio Leonardo DiCaprio
Wall-E Wall-E
Gorgeous Woman Gorgeous Woman

Screenshots

Now everybody loves to see the master at work, right? Right?? AMIRITE???
Screenshot

Dependencies

  • Node.js
  • Python3 (Along with the following python modules):
    • cv2
    • numpy
    • scipy
    • sharedmem
    • dlib

How to use

If you only need to run the script

  • Download the core script from here.
wget https://raw.githubusercontent.com/ghostwriternr/lowpolify/master/scripts/lowpolify.py
  • Download and extract the .dat file from dlib for facial features detection. Place the extracted file under scripts (the same directory as the lowpolify.py script).

  • Run the python script as:

python lowpolify.py <input-image> <output-image> <cFraction>

Here, cFraction denotes the fraction of points from original edges to be taken for triangulation.

If you would like to use the webapp

  • Clone the repo
git clone https://github.com/ghostwriternr/lowpolify
  • Navigate into the cloned repository
cd lowpolify
  • Install all npm modules
npm install
  • Create a file secrets.json under the app/secrets/ directory. The structure of the file should look like this:
{
  "apiKey": "xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx"
}

You can create your own apiKey at your Clarifai Developer account page.

  • Download and extract the .dat file from dlib for facial features detection. Place the extracted file under scripts (the same directory as the lowpolify.py script).

  • Start the server using node

node server.js

License

MIT ๐ŸŽ“

Psst

In case you too got bored reading this README, foxy here wants to give you a hugsy!

foxy

Note that the project description data, including the texts, logos, images, and/or trademarks, for each open source project belongs to its rightful owner. If you wish to add or remove any projects, please contact us at [email protected].