Posted
by
samzenpus
on Monday December 21, 2009 @03:57PM
from the survival-of-the-grooviest dept.

maccallr writes "The DarwinTunes experiment needs you! Using an evolutionary algorithm and the ears of you the general public, we've been evolving a four bar loop that started out as pretty dismal primordial auditory soup and now after >27k ratings and 200 generations is sounding pretty good. Given that the only ingredients are sine waves, we're impressed. We got some coverage in the New Scientist CultureLab blog but now things have gone quiet and we'd really appreciate some Slashdotter idle time. We recently upped the maximum 'genome size' and we think that the music is already benefiting from the change."

This is different from all other sounds, including regular music, how?

Square waves [wikipedia.org], triangle waves [wikipedia.org], sawtooth waves [wikipedia.org], and the ever popular noise (play with a SID chip someday). Sure, they're approximated by putting together sine waves, and they might even just happen to "evolve" from selected sine wave combinations, but the meaning came across just fine.

A guitar's waveform is complex, so you won't get evenly timed transitions even with infinite overdrive and perfect clipping. Second, infinite overdrive sounds harsh so few guitarists use it (thus the continuing popularity vacuum tube amplifiers). Finally, the sound of electric guitars is also influenced by a speaker cabinet (or simulation thereof) with essentially no treble response.

I used to play with 555 timers for making noise as a kid. The sound has a brain numbing clickety quality. H [wikimedia.org]

Really? I hope orchestral music counts as music. Bowed strings and brass are closer to sawtooth waves, flutes and woodwinds are squarish. Plucked strings *can* approach sine waves, but you're still going to have harmonics that change the timbre, which really just means "the shape of the wave."

Of course, with the use of synthesizers all over the place now, quite a lot of music makes use of pure and modified waves of all types.

As someone who makes music, and has build and programmed some synths, I can tell you that pretty much the most of all electronic music comes from a hand full of different wave shapes, and samples.The waves shapes include square, triangle, sawtooth and sine as the most basic ones.

Then everything is modulated, modulating each other, filtered, etc, etc, and out comes pretty much every synthetic sound you ever heard.

Try making an instrument (/patch) with any softsynth, and you see what I mean.

In general things like that don't actually exist in the real world. If you want to produce a square wave, for example, you actually end up approximating it, effectively with sinusoids. In the real world you just can't make things vibrate like that, and that includes air.

darwintunes.org has no ads at all - it's an academic experiment website, it would be inappropriate. Even my slightly more commercial evolectronica.com doesn't have ads. From my experience that would just be a colossal waste of time and turn people away.

What newscientist.com (or perhaps DNS hackers) do with their ads is nothing to do with me!

And finally, it was Slashdot who made the New Scientist link look like the main link for the article, not me! See my original submission:http://sl [slashdot.org]

How about an infinite piece of non-repeating music, consisting of say, a beep at every prime second and silence otherwise?

This isn't remotely my area of expertise, but I believe that would be representable with an infinitely large set of sine waves.

A simpler "gotcha" is a perfectly square pulse. For example, 1 HZ for 1 second, complete silence before and after that second. I believe that requires an infinite number of sine waves to model as well.

Technically, you can take the Fourier transform of any Lebesgue-integrable function, which all of these seem to be. Unfortunately, the simplest non-integrable functions tend to infinite values at some points (think integral of 1/x from 0 to 3), which would probably be pretty hard on the ears. So yeah, I'm gonna go with country music.

When you say "noise", I think you're talking about a random, unpredictable waveform, right?

I think the right way to look at it is this: Once the noise has been generated, there's no longer any uncertainty about the waveform. It's going to be a messy waveform, but at least it's a specific waveform at that point. So Fourier transforms can still be applied, because they work on arbitrary waveforms, including noise.

To model any input signal you need an infinite series of sine waves of different frequencies. Some input signals are better approximated by the first n terms in the series. Some signals (like the square wave) are difficult and you need more terms.

Any perfectly square wave requires an infinate amount of sine waves to be replicated (or: consists of the same).

You cannot perfectly create a square wave from sine waves, even if you had an infinite number of them. This problem occurs with any jump discontinuity and is referred to as the Gibbs phenomenon [wikipedia.org].

A long time ago when I was learning lisp, I worked through an interesting book [comcast.net] by Heinrich Taube called Notes from the Metalevel [amazon.com]. A very enlightening and interesting work for people interested in both music theory and computer science.

Well, nothing in particular. But this experiment is about evolving electronic music, as opposed to mainstream music. I suppose it would be possible to "steer" the song towards a familiar tune, but it would be pretty difficult given that all of the loops I heard were comprised of elements of the electronic genre, and also because the individually-rated loops are so short.

I don't think that COTS is going to work. He'll have to have some kind of custom liquid cooling package. Maybe they could have a mic hooked up to the CPU and the sound they're actually trying to get is what happens acoustically when a CPU dies.

Drew Curtis (of Fark) has the same kind of sentiment. "You want traffic? Be careful what you wish for."

Not really. Instead of thinking of it as music you like versus music you don't like, think of it as music that succedes and music that doesn't. By analogy, imagine the listeners are hunters and the music the prey, better music is equivilent to prey that is better at evading preditors.

Maybe a more interesting experiment would be to have a baseline of human generated music which the computer generated music would have to hide in. Play it as a loop with computer generated music randomly interspersed with hu

I've written a few genetic algorithm/programming things for "music" over the years. However, not being a musician, I approached it only from an algorithmic perspective. The last of these, called "grammidity" can attempt to evolve sequences of midi events based on a kind of grammar that evolves (loosely based on the ideas behind L-systems). I had it online for a couple of years, but it never evolved much of anything interesting. The source code (java) is on sourceforge [sourceforge.net] and includes ways to evolve "plants" and a fuzzer that generates html and which worked quite nicely to break browsers a couple of years back.

I was able to do some rating for a while, and I think the results are fairly cool, but it may not produce anything very interesting for a couple reasons.

The first is that there isn't strong enough evolutionary pressure. There are too many people rating with very different opinions of what sounds good. I think it would be much more interesting to create different channels. Classical, jazz, ambient, electronica, whatever. It's still a very broad definition but not so much that our ratings aren't just n

"Secondly, the algorithms used to generate the music are really important."They are fundamentaly flawed...

I Like ketchup, beer and chocolate, but put these all in a blender and it tastes like shit.

To top it: evolution is no longer pressent. What is evolution? Those who are fit for their environment survive and all others die. Currently we are no longer adapting to our invironment, but adapting our environment to ourselves.

"You are incorrect. There is plenty of evidence to suggest that human evolution is not only still happening, but accelerating."Yeah... ever heared of traveling? The world is getting smaller you know...

"The rest of your post was equally nonsensical."What do you mean? Did you even RTFA, all joking aside? It goes like this:Create random techno loops. Which ones do you like? Ah you like loop 1, 2 and 3 (ketchup, beer and chocolate).

I think that you might need to rethink this. Every time someone selects a mate and reproduces, they are reacting to their environment and, well, evolving! It's hard for me to fathom how you could successfully argue that there is no selection pressure on humans. Sure, the "death before reproduction" aspect may be all but gone in the developed world, but there's still quite a bit of mating going on - and plenty of selection. And in the developing world, well, you still have plenty of good old fashioned death

"Every time someone selects a mate and reproduces, they are reacting to their environment and, well, evolving!"Not really. Or at least not in the western world... It is humans that devine culture. It is culture that devines evolution. Todays hot, might be tommorows not. Skinny girls on TV? Suddenly that's hot. Remember the days that chest hair was cool? Now it's disgusting, suddenly. Being manly was the way to go. Today it's metrosexual...

Or at least not in the western world... It is humans that devine culture.

I wasn't referring to pop culture so much... we select mates in ways that might surprise you. If you are a reader, you might enjoy "The Third Chimpanzee" by Jared Diamond... it has a whole section on mate selection.

There is. Sure there is. It's just that we make our own...

But some of us are better at "the game" than others, and this does change our genome.

I was able to do some rating for a while, and I think the results are fairly cool, but it may not produce anything very interesting for a couple reasons.

The first is that there isn't strong enough evolutionary pressure. There are too many people rating with very different opinions of what sounds good. I think it would be much more interesting to create different channels. Classical, jazz, ambient, electronica, whatever. It's still a very broad definition but not so much that our ratings aren't just noise.

You're right, and this is why we wanted to do the experiment. Nearly a month ago we had 120 Imperial College students do 250 ratings each for us over a week. We replicated the experiment 3 times (40 students per population) and assumed that these students would have a mix of musical and cultural backgrounds. We got 75 generations out of it, and the results were much more musical than the random material we started with [darwintunes.org], but now we realise that 200+ generations is where it's at!

Secondly, the algorithms used to generate the music are really important. I couldn't find any information on it, but the way the notes are put together seems fairly random. I think it's important to stick to what we do know sounds good... to an extent. For example, the gene could contain information on which way to move the current note, rather than the specific note. That way you could limit it to 2 or 3 steps and lay it over a scale or mode. The willy nillyness of it will guarantee that we pick 'safe' consonant sounding harmonies. 5ths and 4ths with beep boop melodies.

I did some ratings, and having a musical background I intentionally listened for and voted up stuff that was more adventurous. There were one or two that had some very nice dominant 7ths in them--not too far off the beaten path (since they're in every blues song ever) but more interesting to my ear.

I stopped rating for the night because I noticed I was getting bored with the single-note drone that underlay all the loops I heard, which made it hard to distinguish among many loops. Something almost identica

I see their individual loops are covered by the creative commons license for non-commercial use with attribution, but I'm search of new On Hold music, so I'm hoping we can come up with some sort of solution. It's a problem when you have zero budget though. heh

I'm looking forward to future generations when they start to do good transitions between different loops, that will be interesting.

Found myself with some time to kill, so I had a go at this. Here are my thoughts:

1. The original loop (linked to in the summary) has a recognizable beat, even if many of the accompanying tones sound dreadful together. I'll put it this way: generation 0 sounded way better than a lot of the stuff I've seen try to pass for "electronic music" on YouTube. The original loop already had a fair amount of complexity to start with. I'd be more impressed if they began with a loop that had several sine waves with compl

Thanks for the comments. I'll take them one by one (while I wait for the algorithm to tick over to 250 generations).

1. to give a fair comparison with the hand-picked better sounding loops given in all the subsequent "tasters", the time=zero loops are also hand-picked. Rest assured that most of them sounded pretty horrific. Yes we did set a minimum amount of complexity (I think it was at least 8 different "tracks") in the initial Adam and Eve, but then let them evolve under no selection for a long time.

2. yes we have to keep it short so that rating can happen in this lifetime:-) I have put several tracks together for my own projects (just me doing the ratings, and using pre-recorded samples as well as evolved synths) - here's the best example.

Hey, I dig this. Also enjoyed Like Ani.

3. there are no constraints on harmonies or anything, however the "palette" of notes is defined once (all evolved from random) and then the notes are picked from the palette. Mutations to the palette are going to be rare (beca

The phase space of this experiment is too large to explore with the simple rating system. No wonder the "survivors" all sound hyper-sequenced and repetitive, and nothing like Beethoven. What's happening is a bifurcation of the binary number space, because a music sequence is just a binary value occurring on a binary timeline, and each vote of plus or minus is a bifurcation of that space. An "i love it" vote is no less a simple plus, just a plus with extra survival chances.

Do you not understand the word-symbols you're putting into your computer-box or do you just like being contrarian?
God 'designs' things the way he wants them the first time. This music is generated randomly, then subjected to fitness tests in the form of listener reviews. The fittest members survive and provide the input material which is then randomly mutated again for the next generation.

At first glance, I agreed that the original poster looked like flamebait, but there is actually some sense to what is being said. In natural evolution, selection happens as a result of the environment, which determines if and when creatures die or reproduce. In this case, people rate music, deciding how successful each loop is. If people were doing this with creatures and not music, it would be fair to call it selective breeding.

Yes, that's the point I was trying to make. The original poster suggested that this was like playing god, and my point was that if you notice that this amounts to selective breeding of music, then such a comment makes sense.

No problems loading here. After a couple of minutes, I'm tired of it. Time to kill it. No cowbells. No drums. No strings. No piano. Nada. Just strange synthesizer noises from decades ago - as has already been pointed out. A couple of loops almost sound good, but mostly just boring repetition.