Page 1 of 8

Tutorial : Generative music in Live

Posted: Fri Jul 06, 2007 5:50 pm
by Angstrom

Generative music in Live


Here is a brief tutorial on making generative music with Live.
Generative music is music where you provide 'seeds' and the computer grows you some music, Brian Eno being the most famous practitioner.

-------- EDIT 2014 --------
Ableton Live Generative tutorial and example files
. I advise you to go here for the tutorial,images and files, because the links in this thread are all dead, it's 7 years old.
------------------------------------


Why make generative music, or get Live to make music for you?

Generative music is a different beast from making a track of your own, it is more like planting a garden.
In fact a generative piece is like a glorified wind chime, why do people have wind chimes rather than stand in the garden hitting aluminium themselves? Because the sounds are quite beautiful and can be suprisingly interesting, with a wide range of expression a generative peice will sustain interest for hours!

Live is quite a good environment for creating generative music and I have two methods to do so, an audio based method and a midi method.

I will focus on the more midi-oriented method here.
There are limitations to how far you can go with Live and generative music, but what you can achieve is entertaining.


How it is achieved in Live


To make generative music we need to make Live play or do something whenever a condition is met, we get flexibility by giving the program some freedom. Instead of saying "EVERY time a bar starts play a C minor chord", we want variation. An example might be "Sometimes play a chord (from a selection of chords) on either the first or third beat, and if you do then perhaps play one of these ralated chords after it, or perhaps think about playing this tune instead"

So now we have a random event which is constrained by a limited set of outcomes, it sounds passably like music.


Tools of the trade


Midi Devices
Random - togenerate random pitches
Scale - to make those pitches be less random
Velocity - to make random note start triggers
Pitch - to transpose phrases chords and notes
Note Length - to give variation to the note length
Chord - a variety of uses

Audio
AutoPanner - can be used for 'cross-fading' between one component and another
AutoFilter - similar but different
BeatRepeat - repeating random stuff makes it sound like you meant it!

obviously the other Live devices such as Reverb get used, but the above are the ones that are strictly 'generative'




Getting started - 'plinky plonk world'


Lets make a bad start!
Drop a Midi instrument on a track so you can hear what is happening during the exploration process, use a simple patch like an electric piano (or a Simpler with a triangle wave in) and give it a long release. At the start the output will sound pretty dull, trust me it gets better.

we need a timing pulse to begin with, I use a single midi C3 note in a session clip, I loop this on a quarter bar.

Image
This gives me a nice regular trigger at a 120bpm for the random events to take their cue from. Thats all the midi programming we will need done!


next we need to make that 'trigger' random
, to do this we use the Velocity device. Actually two velocity devices, like this

Image

The first takes the incoming repetitive note and randomizes the velocity.
The second one only lets notes through which fall in the selected velocity range.

This is the core concept of how we will select and filter random values in Live. How we can decide "do I do something, or not?"

In the image that range is from 0 to 59. You will see that I assign the range to a macro called 'chance'. Try this, it will soon become apparent what 'chance' does.
Remember to set the Velocity device to 'gate' mode.

You might notice I also set the 'random' high on the second Velocity - this is so that further down the chain I have a ready made scattering of random values to make use of for further filtering (you'll see!)

Now we need to make the pitches change, the most brutal way is to use the Random Device, simply dropping it in the rack after the Velocity section will give you an annoying random 'tune'.

Give it some pattern with the use of the Scale plugin, choose a nice preset or set your own if you know how ... and there you have your first very basic generative thing. A bit shit though isn't it. It plays random notes, they have random pitches which conform in a brutal way to a scale. It's a start. It's hardly music though.

Image




Make it sound more interesting

There are a few things about our example above which make it a bit dull, unpleasant and it just .. well, un-interesting.
It sounds very machine like in its random nature rather than musical, there is no tonal variance such as there might be in a human musical peice, there is no sense of drama, no sense of space or *cough* ambience. If we can simulate any of that, it would help.



Conditions of Interest

We used the velocity devices to set a 'condition', if the value is within a certain range the note sounds. We can expand this to become what programmers know as an 'if - else' conditional.

Image
Here we set two ranges, one produces one outcome, the other will produce another outcome.
This can help us get some drama and tonal variance in there, for example: by allowing any (random) value between 60 and 70 to trigger one chord, while anything between 70 and 80 might trigger a different chord.

Those are 'conditions' , when a condition is met an action is taken. To a programmer this might read as if (var>60 && var<70) { do this } else if(var>70 && var<80) {do that}

We can make our piece more interesting by cascading the variations, or to put it in English " if the value is between 60 and seventy then do either this chord or that chord, if you do that chord then consider these further three variations"

A second choice of conditions follows the first, cunning use of these cascades provides potentially musical output.


Cascading The Variations . You saw how I set a 'condition' with two Velocity plugins, and how we can set two different outcomes using 'if - else'. Now imagine dividing the random values up into many zones, this way you can create little themic areas.
You can start to go further down the fractal tree, each conditional zone can have a new random value generated to make new notes for itself. Each 'conditional zone' can be a different part of your song. The 'riff' , the 'bassline' , the 'chords' .
Each of them can watch a zone and do some more complicated 'riff' or 'chord' related actions anytime that rack is triggered by the main condition.

here we have the zones of a random seed divided into themes

Image

and in this example the watched zones are further divided to play notes of a riff, each riff note is also conditional. The cascade effect first decides if a note should play on a particular beat and then it decides which note from its small pallet of notes. Out of view here, a further conditional decides whether to transpose the eventual riff.

Image


This is making my brain hurt!

Although this sounds very technical, in fact (if you are anything like me) you will simply set up a few conditions and then add stuff where it seems right, until it makes a nice noise. Once you have an idea of the basic principles you can simply sculpt or garden yourself a tune in an ad-hoc manner. You will notice that my example files aren't exactly exemplary of order and fore-thought.
But it certainly helps to have some kind of plan!

I think that's enough to absorb for now.
So, here are some example files



Examples

Zawinul - a complex peice which should sustain a lengthy listen
Harpist - an example of riffs riffing away
Experimentaloid - a more simple example
Infinity Plus one - more of the same.

Image Download the Live Pack

Posted: Fri Jul 06, 2007 6:22 pm
by XPM
Cheers buddy,
Been looking forward to this one.

Posted: Fri Jul 06, 2007 6:26 pm
by kuniklo
Thanks for taking the time to put that together. Some useful ideas for sure.

Posted: Fri Jul 06, 2007 6:47 pm
by Bong Sau
Great stuff. Thanks very much.

Posted: Fri Jul 06, 2007 7:43 pm
by rasputin
Thanks for putting together the tutorial, angstrom. It's good reading.

A couple notes on the Live pack as seen here: unless I'm missing something, the experimentaloid set needs TrueVerb, and pegs my CPU past 100% anyway; the zawinul set seems to be missing three samples that don't seem to show up in the Samples/ folder; harpists6c is missing one, infinity+1 loads up but also goes to 100% cpu right away.

I guess I shouldn't be trying to run these on such a feeble CPU (it's 2.2GHz Celeron running XP SP2)

Cheers!

r.

Posted: Fri Jul 06, 2007 7:45 pm
by Vaughan
Excellent. Thanks a lot.

Posted: Fri Jul 06, 2007 7:51 pm
by Angstrom
rasputin wrote:the zawinul set seems to be missing three samples that don't seem to show up in the Samples/ folder; harpists6c is missing one, infinity+1 loads up but also goes to 100% cpu right away.

I guess I shouldn't be trying to run these on such a feeble CPU (it's 2.2GHz Celeron running XP SP2)

Cheers!

r.
Damn, I thought they would all be encapsulated.
I've now repacked it and re-uploaded it

yes, apologies to those with older CPUs, I have a terrible habit of using lots of processing power. Although I did think these would be usable on most people computers.

If it's any guide these sets normally sit at around 25% on a Core2 2.45 mhz CPU.

Posted: Fri Jul 06, 2007 9:17 pm
by Nev
Awesome, many thanks.

Nev

Posted: Fri Jul 06, 2007 9:19 pm
by Obineg
Top Stuff , Thanks for sharing

Posted: Sat Jul 07, 2007 1:17 am
by Angstrom
oh yeah, one thing I forgot to mention.

when 'listening' to this stuff you ideally need to stare vacantly out of a window at an unseasonably rainy day until someone shouts "what the fuck are you doing".
Please, don't make the mistake of staring at the screen and waiting for the beats to rock your world. ;)

This stuff is meant to be wallpaper.

Posted: Sat Jul 07, 2007 2:45 am
by Thinktanx
Thanks a lot, Angstrom. Cool stuff. 8)

Posted: Sat Jul 07, 2007 9:23 am
by Vaughan
Angstrom wrote:oh yeah, one thing I forgot to mention.

when 'listening' to this stuff you ideally need to stare vacantly out of a window at an unseasonably rainy day until someone shouts "what the fuck are you doing".
Please, don't make the mistake of staring at the screen and waiting for the beats to rock your world. ;)

This stuff is meant to be wallpaper.
Heh, today is a good day for that.

Posted: Sat Jul 07, 2007 10:17 am
by itook4lefts
thanks angstrom.

stickystickysticky.

Posted: Sun Jul 08, 2007 7:31 pm
by itook4lefts
Angstrom wrote:I did think these would be usable on most people computers.
don't try running these on a 1.33ghz ibook. holy shit. 143% with the "simple" example. does anyone want to buy me a new computer? awesome ideas though!

Posted: Sun Jul 08, 2007 8:33 pm
by longjohns
Yeah, I can _barely_ play these - get glitches every now and then.

Hopefully will look at the racks to learn some tricks

Thanks for this post!!