Greg (gregstoll) wrote,
Greg
gregstoll

  • Mood:
  • Music:

adieu genetic Mona Lisa

That project I was working on? Yeah, not so much. After running it overnight, here's what I got:
The target imageA bunch of colored polygons
Um, so it seems to have figured out the image is mostly pink. Hooray?

Things I did learn:
- I originally tried crossover for breeding (specifically cut and splice) and that was just terrible. I think the algorithm really needs lots and lots of new polygons to be tried, and the weakness of crossover is that you're just combining existing ones.
- Originally I had a generation size of 500, and I implemented the image difference calculation in Python. This took around 500 seconds, which is way way way too long. After some optimizing, I got it down to around 280 seconds.

I had planned to wait until I had things working to write a C module for Python to do the difference, but I figured I couldn't really make progress until I could actually do the difference in a reasonable amount of time. After writing it in C (not even with MMX or anything) the total time went down to 1 second. Win!
- The best results seem to come from having a very small generation size and randomly mutating, which is pretty much what the original guy did.

Wanna see something else cool? Virgil did these: Books that make you dumb and Music that makes you dumb by correlating popular books and music at universities (found on Facebook) with average SAT scores. Obviously correlation is not causation but it's still pretty interesting. Guster, Ben Folds, and Radiohead fans should feel good, I suppose :-)
Tags: projects
Subscribe
  • Post a new comment

    Error

    Anonymous comments are disabled in this journal

    default userpic

    Your reply will be screened

    Your IP address will be recorded 

  • 9 comments