background preloader

Genetic Programming: Evolution of Mona Lisa

Genetic Programming: Evolution of Mona Lisa
[EDIT] Added FAQ here: Gallery here: This weekend I decided to play around a bit with genetic programming and put evolution to the test, the test of fine art :-) I created a small program that keeps a string of DNA for polygon rendering. The procedure of the program is quite simple: 0) Setup a random DNA string (application start) 1) Copy the current DNA sequence and mutate it slightly 2) Use the new DNA to render polygons onto a canvas 3) Compare the canvas to the source image 4) If the new painting looks more like the source image than the previous painting did, then overwrite the current DNA with the new DNA 5) repeat from 1 Now to the interesting part :-) Could you paint a replica of the Mona Lisa using only 50 semi transparent polygons? That is the challenge I decided to put my application up to. The image below is the result of that test: (The number below each image is the number of generations it took to reach that specific painting) So what do you think? Like this: Like Loading...

Related:  Algorithms and Design Patterns

Recursion Explained with the Flood Fill Algorithm (and Zombies and Cats) The source code of everything in this article can be downloaded here: Consider the Lazy Zombie This is a cat: This is a normal human: PLoS ONE : accelerating the publication of peer-reviewed science Advertisement advanced search Browse Subject Areas:

Optimizing JavaScript code - Make the Web Faster Authors: Gregory Baker, Software Engineer on GMail & Erik Arvidsson, Software Engineer on Google Chrome Recommended experience: Working knowledge of JavaScript Client-side scripting can make your application dynamic and active, but the browser's interpretation of this code can itself introduce inefficiencies, and the performance of different constructs varies from client to client. Operational transformation Operational transformation (OT) is a technology for supporting a range of collaboration functionalities in advanced collaborative software systems. OT was originally invented for consistency maintenance and concurrency control in collaborative editing of plain text documents. Two decades of research has extended its capabilities and expanded its applications to include group undo, locking, conflict resolution, operation notification and compression, group-awareness, HTML/XML and tree-structured document editing, collaborative office productivity tools, application-sharing, and collaborative computer-aided media design tools (see OTFAQ).

Is Design Dead? For many that come briefly into contact with Extreme Programming, it seems that XP calls for the death of software design. Not just is much design activity ridiculed as "Big Up Front Design", but such design techniques as the UML, flexible frameworks, and even patterns are de-emphasized or downright ignored. In fact XP involves a lot of design, but does it in a different way than established software processes. Living Earth Simulator will simulate the entire world Described as a “knowledge collider,” and now with a pledge of one billion euros from the European Union, the Living Earth Simulator is a new big data and supercomputing project that will attempt to uncover the underlying sociological and psychological laws that underpin human civilization. In the same way that CERN’s Large Hadron Collider smashes together protons to see what happens, the Living Earth Simulator (LES) will gather knowledge from a Planetary Nervous System (PNS — yes, really) to try to predict societal fluctuations such as political unrest, economic bubbles, disease epidemics, and so on. The scale of the LES, when it’s complete, will be huge. It is hoped that supercomputing centers all over the world will chip in with CPU time, and data will be corralled from existing projects and a new Global Participatory Platform, which is basically open data on a worldwide scale. The project also has commercial backing from Microsoft Research, IBM, Yahoo Research, and others.

HTML5, JavaScript and OpenGL: The Upcoming 3D Internet Technologies HTML5, JavaScript, OpenGL and other technologies are paving the way for an upcoming explosion of 3D content which users can interact with on the World Wide Web. These new technologies will continue to help TrueHit Designs build unique websites, web advertisements, entertainment and other media which is attractive to the end user. We have compiled a short list of demonstrations to show you these unique technologies. We recommend viewing these demonstrations in the popular internet browser, Google Chrome, however, any updated web browser should do.

Why Bloom filters work the way they do Imagine you’re a programmer who is developing a new web browser. There are many malicious sites on the web, and you want your browser to warn users when they attempt to access dangerous sites. For example, suppose the user attempts to access You’d like a way of checking whether domain is known to be a malicious site. What’s a good way of doing this?

API Design One of the development tasks I do most often is designing the API for a reusable component. The components are usually for iOS (though sometimes they’re for OS X), and are invariably GUI controls or views of some kind. I’ve designed literally dozens of component APIs over the years, including for clients like Apple, and I’ve learned quite a bit about the process. The decline effect and the scientific method On September 18, 2007, a few dozen neuroscientists, psychiatrists, and drug-company executives gathered in a hotel conference room in Brussels to hear some startling news. It had to do with a class of drugs known as atypical or second-generation antipsychotics, which came on the market in the early nineties. The drugs, sold under brand names such as Abilify, Seroquel, and Zyprexa, had been tested on schizophrenics in several large clinical trials, all of which had demonstrated a dramatic decrease in the subjects’ psychiatric symptoms. As a result, second-generation antipsychotics had become one of the fastest-growing and most profitable pharmaceutical classes.

Workshop / Chrome Experiments Unfortunately, either your web browser or your graphics card doesn't support WebGL. We recommend you try it again with Google Chrome. Bloom filter Bloom proposed the technique for applications where the amount of source data would require an impracticably large hash area in memory if "conventional" error-free hashing techniques were applied. He gave the example of a hyphenation algorithm for a dictionary of 500,000 words, out of which 90% follow simple hyphenation rules, but the remaining 10% require expensive disk accesses to retrieve specific hyphenation patterns. With sufficient core memory, an error-free hash could be used to eliminate all unnecessary disk accesses; on the other hand, with limited core memory, Bloom's technique uses a smaller hash area but still eliminates most unnecessary accesses. For example, a hash area only 15% of the size needed by an ideal error-free hash still eliminates 85% of the disk accesses (Bloom (1970)). More generally, fewer than 10 bits per element are required for a 1% false positive probability, independent of the size or number of elements in the set (Bonomi et al. (2006)).

Most Code Is an Ugly Mess. Here’s How to Make It Beautiful Courtesy The Daily WTF This is what ugly code looks like. It’s a dependency diagram—a representation of interdependence or coupling (the black lines) between software components (the grey dots) within a program. A high degree of interdependence means that changing one component inside the program could lead to cascading changes in all the other connected components, and in turn to changes in their dependencies, and so on. Astronomers Catch Black Hole Spitting Out Material Jet "bullets" emanating from the region around a black hole. Credit: NRAO, GSFC/NASA AUSTIN, Tex.—One of the great ironies of the universe is that black holes, the ultimate vacuum cleaners, create more of a mess than they clean up. (It is a complaint that many people who finally prevailed on spouses and roommates to clean up after themselves might appreciate.)