Repainting the Mona Lisa with a genetic algorithm

This is my take on Roger Alsing’s Mona Lisa problem, where the mentioned image has to be reproduced as faithfully as possible using only 50 triangles. My implementation is less than 400 lines of C++ and uses a parallel genetic algorithm for optimization. Genetic algorithms can solve a multitude of optimization problems by the digital modeling of natural selection, mutation and recombination. This algorithm attempts to draw a faithful representation of the Mona Lisa using only a few triangles. The code for the implementation is available for download below.


The Mona Lisa drawn with a Genetic algorithm.

Genetic Algorithm



How does it work?