> I copied this approach in my first implementation, but found that much better results could be achieved with a breeding population of genes.
Ohhh, interesting, thanks for posting this! I just started playing around with this myself a few days ago in Javascript (it has no UI so no link yet, but I uploaded some samples [0]), and it also uses the original simple approach. I wondered about an "actual" gene pool and cross-breeding, but shyed away from the additional effort for uncertain benefit... so this helps, greatly :)
One thing I intend to try is to get the fittest (in terms of likeness to target image), and then calculate the fitness of the other genomes by taking the difference (in terms of variables that determine the shapes) to that "champion". I see you take the two most fittest as is, maybe this could be useful for picking the second one?
Also, when the Mona Lisa thing was posted on HN, someone suggested marking areas of the target image as "more important", to maybe make facial features etc. more recognizable. I'll also see if making such a mask automatically, e.g. influenced by contrast, helps any.
> I see you take the two most fittest as is, maybe this could be useful for picking the second one?
Yep, we take the two most fittest unchanged, and breed the rest randomly along a non-uniform distribution tending towards the top.
> Also, when the Mona Lisa thing was posted on HN, someone suggested marking areas of the target image as "more important", to maybe make facial features etc. more recognizable.
This is a really good idea and would definitely make a difference. In my penguin example, with too few polys, sometimes we reach a local maxima before the eyes (small details) look any good. I combatted this somewhat by encouraging new polys to be (a) small and (b) regular. But I like the idea of a more guided approach.
I already knew the altered qualia link, and actually meant that one when I talked about the post on HN (the link to which I got from the bottom of that page) xD
Thanks! I just use what the HTML canvas has to offer: circles, n-gons, and n-gons made of bezier curves. Those can get drawn both filled and as outline, which in turn aren't drawn with plain colors, but gradients made of 3 HSLA colors (alpha ranges from 0.05 to 0.85, to make sure everything matters at least a bit and doesn't just get covered up or disappear), with the position of the middle color stop, as well as the coordinates that define the gradient direction, being variable.
The linewidth is variable, and it can also use dashed lines with a randomized pattern, which looks funky but I haven't gotten a good result with it yet. Another thing I'll do is add allowing picking a random compositing mode (and in the spirit of the expedition, do that for both fill and outline), but then it will be too unpredictable to look like being made of shapes, I expect.
The background also has a gradient consisting of no less than 6 colors, with 4 variable color stops.. what can I say, I like enums and copy and paste haha. Though of course adding more degrees of freedom nilly-willy might not be the best idea.. I have to improve the whole evolution/mutation stuff a lot first, and then I intend to throw just about anything at it I can find, at least as an option. Right now I added words, though that doesn't seem very promising. But having one basic common function to setup fill and outline gradients for any and all shapes I might come up with makes experimenting with this a breeze.
I kind of feel I should be doing this with WebGL, but then I wouldn't have all those convenient drawing functions.. but still, whenever WebGL 2.0 comes (which will make a lot of compute-ish things a lot easier AFAIK), I want to do at least a polgon/circle/bitmaps thing with it, because I feel a speedup factor of a gazillion might just make up for that :)
Ohhh, interesting, thanks for posting this! I just started playing around with this myself a few days ago in Javascript (it has no UI so no link yet, but I uploaded some samples [0]), and it also uses the original simple approach. I wondered about an "actual" gene pool and cross-breeding, but shyed away from the additional effort for uncertain benefit... so this helps, greatly :)
One thing I intend to try is to get the fittest (in terms of likeness to target image), and then calculate the fitness of the other genomes by taking the difference (in terms of variables that determine the shapes) to that "champion". I see you take the two most fittest as is, maybe this could be useful for picking the second one?
Also, when the Mona Lisa thing was posted on HN, someone suggested marking areas of the target image as "more important", to maybe make facial features etc. more recognizable. I'll also see if making such a mask automatically, e.g. influenced by contrast, helps any.
[0] http://imgur.com/a/4duom