Departments

Weblog
BlameGear
BucketMouse Pocket
Hilarious Webcomic Manager
The Life of Ninja
Mugen Downloads
Undergraduate Software Projects

Subscribe

Add to Google
The RSS feed

Information

Valid CSS!
[Valid RSS]

Contact Me

Articles by Brian Jackson

From the Computer's Sketchbook: Hill Climbing and Automated Creativity

17 January 2015

I was fascinated by the algorithm I found online a couple of years ago: someone had suggested that a program could read an image, then generate a sort of "impressionist" version of it by placing random shapes and gradually improving the similarity between the rendered image and the input.

Naturally, I had to implement it - and so, every once in a while, I pick it back up and play around with the program for "image evolution." My implementation differs in a few important details from the one suggested by Roger Alsing (who is, as far as I remember, the one who came up with the idea), but uses a fairly straightforward procedure:

Each step, the algorithm chooses a modification: either adding a new shape (a triangle, specifically), "wobbling" the color of a shape (adding a Gaussian random variable to either red, green, blue, or alpha), changing the position of one vertex on a shape, or changing its degree (triangles to quadrilaterals to pentagons, et cetera). Finally, if the changes decrease an error measure between the rendered output and the input image, the changes are retained; otherwise, they are discarded.

I suppose that there are probably a family of algorithms that could be used to synthesize any number of new images from a collection of images of the same subject. Perhaps something for the future?

Below are some of my favorite results. None of these took more than an hour or two to render, and some were certainly more challenging than others.


"Purple"


Deadpool


Starry Night (you can tell how challenging this one was)


Tim's no-longer-self portrait


Kermit

Comments

No comments yet...

Leave a comment:


Name (optional):

Homepage (also optional):

Location: