squawk rawk

click here to look at the code. (messy)
click here to listen to the mp3.

this song is dedicated to my parakeet, kapow. his favorite music is curt roads. mostly he checks himself out in the mirror, but sometimes he will bite you if you put your finger in his cage.

savage altruism

click here to look at the code.

click here to listen to the piece. (or press play in the widget below...)

in this improvisation, i was exploring the convolution of particulate sounds; looking for unique ways of generating impulses to convolve with responses to derive grains. one trick i stumbled upon is a way to produce harmonic distortion by convolving a sound with an low-passed, soft-clipped impulse. this effect emphasizes odd harmonics and sounds similar to decimation. another trick i played with was to dynamically change the size of the convolution window, to get different sized grains.

for the interested / critical, i have a few words on why i sometimes do this kind of work. these pieces are studies. i am honing my skills for both my own satisfaction and ideally for the enjoyment of the interested. eventually, all this work will prove useful when it comes time to work on something else. while these pieces offer very little narrative on their own, they are usually inspired by events or emotions that are completely unrelated to the techniques they showcase. i attempt to hint at these more subtle origins with titles. while i recognize this activity to be essentially flawed or incomplete, i find most communicative activity to be so as well. the brief, shallow pleasure of 'self expression,' a phrase i have come to despise, is actually what drives these studies. video artist paul chan would call this 'the cheap thrill of understanding.'

'savage altruism' could be an act of kindness that is ultimately undertaken for the sake of the person who undertook it, ie flattery. it could also be an act of utter cruelty performed for the sake of the victim it is inflicted upon, ie euthanasia. either case requires a fair amount of self-deception on the part of the altruist.

i am unsure of the extent to which savage altruism comprises social behavior.

aggressive slinky improvisation, part II

last week, i discovered that the quality of the lm386 amp could be vastly improved by increasing the operating voltage. in so doing, i increased the headroom considerably. i am currently supplying 20v to the amp.
i implemented the amp in a simple feedback instrument, pictured below.
by coupling the slinky to the contact mic, and draping it over the speaker cone, feedback is produced. there is also a small stone phaser - which i've fixed for someone- involved.



click here to listen to sinewaves pumping through this jar.
click here to listen to 3 minutes of carl sagan's cosmos pumping through this jar.

a few people who caught the concert at theaterlab on sunday made remarks about the above piece of handmade equipment, so i thought i'd explain it in this post.

ring modulation, theoretically speaking, refers to the multiplication of two signals. in a software system, depending on your context, the same term can sometimes apply to somewhat more complex operations such as the product plus the sum of two signals. some software synthesis environments, such as supercollider, have a bevy of ring modulation operators, since the mathematical implementation may change depending on the intended application.

the preserves jar contains the original ring modulation circuit. the term 'ring modulation' in fact comes from the diode ring through which the signals pass, after going through center-tapped transformers. this particular ring mod uses two fairly high-quality, vintage transformers, and the diode ring is made from four vintage germanium diodes, desoldered from some ancient piece of gear. my source for parts is richard matthews, bob seer's tech, who works out of a massive unmarked garage in greenpoint. love that guy.

while i can't tell you exactly what it does from a mathematical standpoint, i can tell you that it's not any of those definitions i mentioned above. germanium diodes have a particularly crunchy sound to them, which is why they are so sought after for distortion circuits. i don't think i could satisfactorily model this effect in software.

n.b. the carl sagan recording introduced some weird buffer artifacts, so while it still sounds cool, the sinewaves do a better job of demonstrating the effect.

MMiX Festival Wraps Up with Performances!

tonight, at theaterlab, there will be performances by a few of my friends and me. i will be doing an improvised set on homemade and hacked analog electronics. an oscilloscope will accompany the set to provide a visual cue for the sound. i'm hoping it will be both aggressive and dynamic. i will try to remember to record it.

the program:

Joe Mariglio (that's me!!)
And um yeah
Steven Litt
Ben Neill & Bill Jones

space will be limited, so come early!

heat escapes

click here to listen to the aiff.
click here to look at the code.

i made this one last night and promptly passed out while waiting for it to upload. i'll warn you that the code is messy and incomplete as this was a livecoding session. i didn't start recording at the beginning of the session, however, so i don't want to use the term 'livecoding' to describe what's going on here. perhaps the term 'improvisation' is more apt.

the sounds are made by causing filters to malfunction, and waveshaping the result. as you can see from the code, i'm using ringing and bandpass filters with frequencies around 1 hz. that's what i mean by 'causing filters to malfunction.' filters generally misbehave around these regions. i have quite a few in parallel (ie a filterbank) and two in series. the gamut of the filterbank, not that you can hear it as such, is based on a just tempered locrian mode.

balu, II

many people who have run into me at festivals are familiar with 'balu,' that lovable little handheld noise synth that reacts to light. for ages now, people have been asking me to make them their own similar synths. since i have a lot of trouble turning people down, the waitlist for these things is rather long. however, a few proud friends of mine already have received theirs for occasions such as boxing day and shark week. the above synth is for a friend of mine who lives in atlanta. behind me, as i do the demo, you'll notice the original balu, sitting on my workbench. he needed a new switch, and now he's good as new!

yay noise synth friends!!! ^.^

a tender palsy

click here to listen to the aiff file.
click here to look at the code (messy, i'm warning you).

when i was livecoding in the park yesterday, i was experimenting with sets of impulses. as i have been interested in irrational rhythmic relationships recently, i was playing with an octave of 32-tone equal temperament, from 1 - 2 hz. i love the sound of filtered impulses, especially when i use convolution as the filter, but i'm often disappointed with windowed convolutions because they don't provide ample time domain resolution in the response. while this is fairly trivial in certain contexts, the lack of resolution is very pronounced when attempting a convolution with something close to an ideal impulse, which is what i'm doing here. it occurred to me to use several layers of convolution, with different window sizes, to allow for more resolution. i had tried this a few years ago with somewhat unsatisfactory results, because i was using nested filters to cross-over between resolutions. this improvisation does no such thing. there are no cross-overs implemented here, so i imagine there's a fair amount of combing.

the recording i have provided does not follow the standard rules for livecoding because it is a reconstruction of a livecoded event. my laptop had one of its rare freak-outs this morning just before i could save yesterday's work. saving work is one of those areas where my process needs to develop. grrrr. anyways, reconstructing the code was a good exercise because i could then expand on the idea. i think i've found some interesting territory. i'll definitely be refining this parallel convolution process, ideally with some kind of cross-over that doesn't suck. now that i know a little more about what i'm doing, i think it's possible.

the piece itself made me think of some of the sleep incidents i've had growing up. i suffer from sleep paralysis, a disorder also called 'night terrors.' they aren't always bad, in fact sometimes they can be quite amorous, if you get my drift, but they always involve a large portion of my body being paralyzed, while i lie there completely alert. occasionally this is accompanied by the sensation of my head exploding. sometimes i'm able to move my head and talk, in which case i try to yell as loud as i can, in order to wake myself up. i remember, as a child, being able to predict one of these episodes coming on because i could hear it. the sound was a kind of whooshing noise, a bit like a off-balance drier, but more intense. this recording reminds me of that a little, hence the title 'a tender palsy.'

ps - i decided not to embed or link to the mp3 because lossy compression artifacts are absolutely wretched on material like this.

barren neptune

i made another distortion circuit. this one is very stable, and very loud. based on my limited understanding of the subject, this one works by overdriving the components inside the opamp, rather than using a diode to clip the peaks of the waveform. despite how primitive and brutal this circuit is, it doesn't do much self-oscillating, and actually gates a lot of low-level signal, which is a good thing when dealing with amps and guitars.

actually, the gain is so high on the output that i believe it will need a third opamp to attenuate the signal, because otherwise any guitar player who uses it will most likely just destroy their amp.

to test this and future pedals i'll be using an actual electric guitar, since the impedance isn't quite the same coming from a contact-mic'ed kalimba. it's an american strat-- not mine-- and i have almost no competence with the instrument anymore. regardless, i refuse to tune it, because i really like the sound of a well-detuned guitar.

this pedal currently has no knobs or switches; it can only be on or off. eventually, a volume control and wet / dry knob might make an appearance.

improvisation on hacked reverb unit.

ah the yamaha r1000. possibly the worst digital reverb ever invented. it has four discrete settings which are labeled, cryptically, 1 through 4. it sounds nothing like reverb. it was a gift from my flatmate. i've been looking forward to hacking this thing for some time, and it has not disappointed me.

last night i almost killed it completely. i was messing with it manually and decided i wanted to use bare metal to bend the circuit instead of my hands. big mistake. everything got really cool for about fifteen seconds, and then all went dark and the sound got somewhat less cool. then it wouldn't fully turn back on. i rued the day.

today i woke up and tested the four fuses in the non-power-oriented part of the circuit, and found that all of them had been blown out. on replacing them, the unit sprang back to life. sort of. more accurately, its zombified body sprang into soulless action. it no longer works as a reverb unit- which it sucked at anyway, let's face it - and now only works as a hacked instrument. it's probably my favorite instrument in my rig now, if only because it's so massive and novel. i spent today isolating interesting regions on the circuit and getting some chops on the board. i practiced until my hands started bleeding and i had to stop. i still have a ways to go.

dictionary sex, part II

more sample level markov chain work.

sources used for this briccolage are mostly contact mic recordings of things like single drops of water, screwdrivers scraping wood surfaces, and music box tines. a pitch constellation was achieved by limiting the possible chain depth to only a few different values.

i'm fond of the dynamic range of this recording. this patch seems to create some pretty compelling textures. i hope i eventually put them to good use. for now, i definitely think of these pieces as studies, in case you were getting concerned.

dictionary sex

i was a bit concerned about using the above title for this post, because obviously it opens me up as a target for the spam hordes. however, i trust my filters, and the title is just too apt.

i have been working on some python code that makes music using a statistical algorithm called a markov chain . with all the running around i have been doing of late, i have had little time to document the past few days' work.

in addition to the problem of racing against time, i have to contend with the added issue of documenting partially working or completely non working code. this has been an issue with analog projects as well. i think my future strategy will be to document failures as well as successes, so other makers who read my blog (all two of you, one being my mom. hi mom!) have the opportunity to see me fail -- er, learn from my mistakes.

"dictionary sex" is an appropriate title for what i've been trying to achieve with this application. i have not quite gotten there yet, but i've only really been debugging it for the past two days (today will be the third). the idea is simple: analyze a sound file, and generate a data file from it. take two of these data files and make a third by mashing them together. use the third file to generate a new sound file that has equal properties from both parents. cute, huh? now if only i could get this to work and not take a million years, that would be great.

i have been looking at ways in python of saving data into files for later applications to use. the pickle library seemed like a reasonable place to start, and soon i moved to cpickle because it operates so much faster, being implemented in c. however, despite being up to 1000x faster than pickle, it's still a very long process to save such huge amounts of data into a file. depending on the type of analysis, these files can be much larger than the original wav file. this is a problem i'll attend to later.

so i started this post three days ago, and as i finish, it's no longer a sob-story. i have actually achieved dictionary sex. here is an example of what i'm talking about:

in this recording is a ménage à trois of transition spaces, each coming from different sound sources as well as different analysis parameters. from a single dictionary file, i can generate an arbitrarily long sound file. frankly, i don't remember what the different parts were anymore. here's the code: markovSamp_4.py and markovCat.py.

that the cessation of suffering is attainable

otherwise known as the third Noble Truth, of four Truths the Shakyamuni Buddha brought to us after his experience under the Bodhi tree. in Pali, this concept is summed up by a single word: nirodha.
in addition to pointing to this salient idea, nirodha is also the name of one of my computers. it is part of a cluster of four computers, the other three of which are named after the other Noble Truths. the cluster as a unit is called the cattri, Pali for "the Four." more information on my cluster can be found here. nirodha's hard drive failed during an installation of Sanction of the Victim, a LAN composition that involves running processes that are directly at odds with one another. since all the computers in the cattri are more or less identical in hardware, and since i have a ton of identical spare parts and identical spare computers lying around, i decided to ghost dukkha (that there is suffering), over ethernet, into a new machine, renaming it nirodha.

to begin, i used a live cd for knoppix v5.1.1 because later versions apparently don't come with sshd installed. since i still have no WAN connection for my cattri router, i needed to use a livecd that would be ready to go without using apt. plus i like knoppix.
while this version of knoppix came with sshd already installed, i needed to generate the host keys and start the daemon. i kept running into the following error: "could not load host keys." finally, i just went through the gui and started sshd using their menu option, but not before generating the host keys.
running off the livecd, i used dd over netcat to ghost dukkha's drive. the command pair i used was:
(target): nc –l –p 7000 | gzip –dfc | sudo dd of=[TARGET_HARD_DRIVE_NAME]
(source): sudo dd if=[SOURCE_HARD_DRIVE_NAME] | gzip -cf | nc [TARGET_IP] 7000 –q 10

i started the target code first, because it acts as a listener. there's no visual output (!) while this process happens. my pair did it in 1742.15 seconds, at a rate of 11.4 MB/s.
after rebooting nirodha into the ghosted drive, the machine was an exact clone of dukkha. well, almost exact. the ethernet interface for some reason had gotten renamed from 'eth0' to 'eth1.' evidently this is common with ghosting and no one knows why. check out post #14 on this board. using ' ifconfig -a ' i found the device and renamed it in /etc/network/interfaces.
finally, to change the hostname from dukkha to nirodha, i ran the following (from this documentation):

hostname nirodha
sudo echo "nirodha" > /etc/hostname
sudo /etc/init.d/hostname.sh start

and now i have a new computer! ^.^


click here to look at the code.
cliick here to listen to the mp3.

i added a new feature to my monstrous sample level markov chain script. this one lets the user specify a number of repetitions per unit of the chain. the result sounds a bit like waveset stretching, but it's different because it's not based on zero crossings and because it generates new material rather that simply slowing down playback.

My source material comes from yesterday's field recording. I think they're shaping metal with some kind of pneumatic powertool.

Sorry this is so short but I am so very exhausted. More documentation will come tomorrow.

mornings sit on roofs

every morning i spend in greenpoint, i climb onto the roof and sit for about an hour. i have been doing this since i moved into the place in july. my practice is nothing fancy, mostly just counting my breaths up to 21 - if i make it that far - and starting over. sometimes i repeat specific phrases.

the neighborhood is rather industrial. largely it consists of auto-body garages, construction shops, and the water treatment plant. the first thing i noticed about the area was the beautiful swirling hiss that the plant emits. on some days, the various metalworking machines pound polyrhythms, their origins confounded by their reverberations through the concrete.

the recording was made on a pair of binaural microphones. they can very closely simulate the experience of being there listening to the sounds they record. i recorded for just over an hour straight, and i left the recording completely unedited and unprocessed. it won't stay that way, but i wanted to start by presenting the entire hour untouched. unfortunately, it was somewhat windy today and the wind-guards couldn't keep everything out.

i truly enjoy these mornings. it was a pleasure bringing you along with me this time.

hubris, for tape

i have been playing with this reel-to-reel, which i fixed for one of my clients, for the past few days. it has been an amazing experience working with tape. for the recording, i used only analogue equipment, most predominantly, an ancient and tortured fostex mixer that i used for "no input" mixing. additionally, i used a hacked small stone analogue phaser, some commercial distortion pedal, and two of my own pedals: a distorted bandpass kind of thing, and an arpeggiating octave divider. there is also some amplified spring in there. when i finished the improvisation, i digitized several versions of the tape, with slight variations in mix, tape speed, and additional slinky reverb. i arranged these different versions so they would line up at some points, creating a manual flange / delay effect. truly beautiful things happen to tape when you overdrive it. the tone is so dark and warm. i'm considering recording some computer music to tape and re-digitizing it, just for the saturation. i don't want to give it back!


yeah -  that one pedal's housing is from an old-school motion detector.  that's the octave arpeggiator, otherwise known as the lunar lounge 2025.


this post continues the idea from my previous post about massive irrationally related sets. one impressive thing about these things is that they extend infinitely and never repeat, despite that they initially are completely aligned. another way of saying this is that for each set there is only one singularity. we can assume that any set of irrationally related periodic signals will have, in the fullness of time and if we extend them in both directions of time, one and only one singularity. but how can we predict when that singularity will occur? if our set of periodic signals happens to be an equal temperament, we can use the following formula to delay the singularity by one cycle of the lowest signal in the set:

for every signal x, xdelay = 1/f0 - 1/x

where f0 is the frequency of the lowest signal in the set, and x is the frequency of the signal to which we apply the delay.

to delay the singularity by more than one cycle, simply replace those 1's with the number of cycles.

we can now generate sequences of mostly periodic signals whose phase we occasionally manipulate to get singularities whenever we want them.

click here to look at the code.
click here to listen to the mp3.

to make this improvisation, i not only play with definitions of the streams as they run, but also the synthdefs. among other things, i mess around with the probability of a grain to be muted. as you can see from the commented out bits, i was trying to create fadeIn and fadeOut routines to automate this with reflexive code.


ah irrationality.  possibly my favorite aspect of the human condition...

consider equal temperament.  the geometric series that coincides with an n -tone equal temperament scale is highly irrational, with ratios based on the nth root of 2.  since 2 is the lowest prime, all equal tempered gamuts are based on irrational numbers.  for a while now, people have been arguing over this compromise in music, specifically in the context of tuning.  for reference, i direct the interested reader to google.  i would say this is one of the great controversies in the field of music.  personally, i tend to use just intonation in my work, because i love how it sounds.  often, a piece written in just intonation simply pulls on my emotions in ways that equal temperament just doesn't.  as a piano player, i also love the tuning system that grand pianos use, which contrary to popular belief is not equal temperament.  generally a well tuned grand piano uses a stretched octave due to the weird overtone structure of piano strings.

another reason i often use just intonation in my music is that i have the tendency to re-apply ideas from one domain, such as tuning, to another, such as rhythm.  harmonies are determined by whole number ratios in just intonation; the parallel in rhythm is the polyrhythm.  but ever since a year or so ago, i started playing with massive sets of equal tempered sines.  the result is an infinitely expanding wavefront, made up of many smaller waves, who start out perfectly aligned and march inexorably into entropy.

click here to look at the code.  (apparently from some kind of tutorial i was writing at some point)

click here to listen to the mp3.

so i've been thinking recently about massive, irrational, rhythmic structures.  this has led me to the following patch:

click here to look at the code.

click here to listen to the mp3.

it's made up of a set of 100 irrational relationships, each one mapping to a different place in a soundfile, and a different rate of occurrence.  since these rates begin completely in phase and theoretically will never line up again (remember computers can offer only finite representations of values...), we get the same richness, but in a different domain.  more on this in the next hackpact entry...

the universe is also in brooklyn

click here to listen to the mp3.

click here to look at the code.

this is yet another unfinished piece, so please keep that in mind.  the main pulse is divided into fives.  i also experiment with spatializing the sound using allpass filters.  i have to wake up in 3 hours, so sorry if this seems curt.  g'night.

acousmatic comets

today i started working on some sound design for an acousmatic piece.  i mentioned in an earlier post that i was interested in working on a few compositions with more narrative presence.  in the itemized list you'll find in that earlier post, this piece is #3a-- or as i have come to call it, "the damned grotto."  it's inspired by the gorgeous scene in "harry potter and the half-blood prince" where dumbledor fights hordes of the living dead with fireballs as they climb out of the black water in a cavern.  for tonight's work, i laid the foundations (still buggy) for some of the sound design in general, as well as specifically beginning the design process for a short (~14.5 second) sequence where a few fireballs skitter by and ignite some debris in a safely distant part of the cave.  everything needs work, nothing is final.  any criticism would be helpful at this stage.

click here to look at the code.

click here to listen to the sample.

ps- thank you so much, freesound!  and more specifically, thank you, homejrande for your beautiful field recording!

reel whirled

i'm fixing this otari mx5050 8-track reel-to-reel for a client who's a recording engineer. this thing is so pretty i thought i'd share some pictures:

and here's a shot of it in my studio.  i just might have to "test" it -by recording some stuff- once it's fixed.  it's kind of like how parents justify eating their kids' halloween candy by saying it could be poisoned...


mmmm poison...

a slow, hopeless fire

today i made a battery-powered amplifier out of an LM386 chip and some other, mostly recycled components.  the schematic i used can be found in the datasheet (it's a pdf).  i went for the 200x gain circuit.  it's housed in what appears to be a jewelery box, but really it was a container for one of those space pens.  funny how during the space race the americans thought space pens were such an important design problem, while the soviets used pencil.  maybe that's just an urban legend.  i don't know.


the easy access this case provides is certainly a bonus.  i will definitely be improving on the circuit as time progresses.  i decided to house the amp so neatly because it's something that comes in handy often.

after i had some wine, i got into playing with amplified slinkies and the filter / distortion effect circuit from a few nights ago.  the whole setup looked like this:

i'm calling the track that resulted from improvising with all this "a slow, hopeless fire."  it's a bit aggressive.  i'm still pretty angry about the most recent hand i've been dealt.  this is the most constructive thing i can think to do about it.  enough said.

aside from a little dynamics processing, everything was improvised and totally analogue.  the sound comes from feedback from the little speaker -driven by the new amp- through the spring, and that crazy filter.  i think i'll house that thing the next night i spend here in my studio, which unfortunately won't be for a few days.  it's just as well; there's plenty of computer music to make, too!


click here to listen to the mp3.

click here to look at the code.

i wrote much of today's patch on the bus back to NYC.  i'd done some experiments in the past using sc3's JITlib to make recursive patterns, so i decided to start there and see where i ended up.  i kind of like where that paradigm took me, especially with the drums.  i'll definitely be revisiting it in the future.

* * *

here's a recording of a somewhat cleaner version of that patch.  i removed some of the reverb from the low end and softer bits.  (thanks to randall for the suggestion!)  by adding a gate before the reverb, and then mixing the original (ungated) material with it, i was able to make the quieter parts drier.  to remove some of the low end muck, i used a 2nd order high-pass filter before the control signal for the gate.  this way, the low end has to work harder to open the gate. in sc3:

SynthDef(\master, {|in = 16, out = 0, wet = 0.125, thresh = 0.1|
var input, signal;
input = InFeedback.ar([in, in+1]);
signal = Compander.ar(input, HPF.ar(input, 1600), thresh, 10, 1, 0.01, 0.01);
signal = Mix.ar([FreeVerb2.ar(signal[0], signal[1], 1, 0.7, 0.9)*(wet**2), input*((1-wet)**2)]);
signal = Limiter.ar(signal, 0.9);
Out.ar(out, signal)


for today's hackpact, i made a new distortion effect, starting with the circuit from last night as a base.  this circuit is a bit less stable, and it's harder to tell exactly what's going on sonically.  it sounds a bit like a ring mod with a filter that occasionally self-oscillates.  it's still very simple in terms of design, but its tone is more complex.  here's the schematic:

to make the previous circuit, simply replace the photoresistor that connects the input to ground (the one at the top of the schematic) with a 220 MΩ resistor, and remove the 220 μF capacitor.

i tested this circuit with the same amplified kalimba from the previous post.  what a fun instrument!  i added a few delays in supercollider:

{Limiter.ar(Mix.ar([CombC.ar(SoundIn.ar(0), 2, [8/7, 6/5], 32), Mix.ar([CombC.ar(SoundIn.ar(0), 1, 1, 16), SoundIn.ar(0!2)])]), 0.9)}.play;

click here to listen to part one.

click here to listen to part two.

electric kalimba

for my fourth hackpact, i decided to go with something electronic.  i spent a while getting back into the workflow; it's especially difficult because I'm at my parents' house and not at my typical space.  i ended up prototyping a simple active filter / distortion effect from an op-amp and a few other components.  using a piezodisc as a pickup, i tested the circuit with a kalimba i found.  i believe it's from a resort gift shop in jamaica.  i'll draw up a schematic tomorrow.


click here to listen.

mulch, dust, talc

so in addition to working yet another 8 hour shift, on less than 3 hours of sleep, installing security cameras in a manhattan apartment building, today i also drove for 4.5 hours to get to my parents' house in pennsylvania, arriving just before midnight.  still, i've made this hackpact, and i have every intention of keeping it.  just please forgive me if today's seems a little smaller in scale.

</preemptive apology>

i have updated my markov_samp.py to allow for a randomly varying depth.  this breaks up some of the synchronicity of the resulting mulchy textures. previous versions of the code only allowed the user to select a single value for the depth parameter, which sounds a lot more angular and choppy when applied to a sample-level markov chain.  in the new alternate version, this value is a maximum.  the patch is a bit computationally intensive, especially when analyzing larger soundfiles, so the single-second field recordings i've been messing with are pretty ideal fodder.

i made a short audio sketch out of some material i got from this patch.  i'd like to revisit it sometime soon- i feel like i'm only scratching the surface of what it could do.  the sketch uses a single second from that night in berkeley.

you can look at the code here.

you can listen to the piece here.

half-songs carved from intimacy

click here to listen to the piece.

click here to look at the code.

this piece is a further development of the material from this patch.  the samples i use here come from an extremely intimate source: the last night my partner and i spent together before she left me.  its liberating, in a way, for me to use this material to make something beautiful, and it kind of shocks me that i actually ended up documenting the event in the first place.  it's a little like how i described in a previous post about the method i used to gather the samples: the recordings are like jars of earth that sailors keep for long treks across the sea.  here, the process is one of sculpture in the sense of chipping away at masses of the material to derive shapes.  you can hear incomprehensible bits of candid speech, quiet artifacts of movement, and the motors and birds from the street outside the window in the small berkeley apartment.  from these sources, a fragile little half-melody almost shows itself, and then vanishes into the everyday.

hackpact day 1

for a definition of what hackpact is, or who else might be doing something like this, see the dedicated page on the TOPLAP website.  essentially this all means I'll be making and documenting one creative thing every day for the month of September.

for this first piece, i decided to go with something that could be thought of as both complete and as a spring board for a few other projects.

I drove out to San Fransisco with my partner of 4 years.  We made quite the road trip out of it, staying with old friends along the way.  It was such a great experience.  I love driving, and it took a particularly brutal stretch of road-- which lasted for more than 20 hours and landed us somewhere in Montana-- to get me to give up the wheel.  Something about the constant state of focus really calms me down and helps me think.  We had been living together for about 3 years, and both of us were looking forward to this summer as a way of establishing some space before she started classes at San Diego in the fall, and I moved out there with her.  Unfortunately, it doesn't look like this is going to happen anymore.

Along the way, I made quite a few field recordings.  I brought a cheap but discrete lav mic and set up my computer to record in just about each place we stopped and stayed during our trip.  The recordings are unique because they are the result of a simple supercollider patch.  Every 12 seconds or so (I experimented with the specifics as I went), the patch recorded one second of audio.  The resulting streams I stored as individual files in a directory tree, so that someday I'd figure out what to do with them and iterating over them would be simple.  Today is the first time in a long time that I've listened to these recordings.

My hackpact goal for today was to come up with a simple assemblage for one of these micro-recording sessions.  While I am not totally satisfied with the assemblage as a self-contained whole, my secondary goal for today was to end up with a framework for playing with similar material in the future.  This piece uses the entire last night we spent together.  It's very personal, and I find it pretty difficult to listen to.  Hopefully you'll find it beautiful.

Here's the code:
//load all samples in directory:
var pipe, line, dir, index;
dir = "/Users/josephmariglio/Music/samples/pennsylvania/sf/";
pipe = Pipe.new("ls -f"+ dir, "r");
line = pipe.getLine;
index = 0;
var path;
path = dir ++ line;
Buffer.read(s, path, bufnum: index); line = pipe.getLine;
index = index + 1;
~num_bufs = index;
//a synthdef for playing them:
SynthDef(\samp, {|rate = 1, vol = 1, out = 16, buf = 0| Out.ar(out, (PlayBuf.ar(1, buf, rate, doneAction:2))*vol)}).store;
//define patterns to arrange the sound-events
~a = Pbind(*[
instrument: \samp,
out: 0,
buf: Pseq((0..~num_bufs), 1),
dur: 1
~b = Pbind(*[
instrument: \samp,
out: 1,
buf: Pseq((0..~num_bufs).reverse, 1),
dur: 1
//play them together
[~a, ~b].do{|x| x = x.play;}

So the piece is a near palindrome, made up of a stream of samples indexed diachronically and reversed, one stream on either channel of audio.  They meet up in the middle.

Click here for the mp3.

hackpact 09/09!

For a definition and links to other participants, check out:


Basically, I want to use this month to make and document something small, creative and techie every day.  I imagine these things will be mostly sonic in nature, but i can't promise that I won't document at least a few days of breadmaking or some other such thing.  Since I'm not sure where the month of September will take me, I also have to keep my options open regarding the mediums I'll use.  I'm going to venture a guess and say there will be mostly analog circuits and supercollider patches, with perhaps a few python things and the occasional loaf of bread.  I'm starting the month off by making an assemblage from the field recordings I took this summer.  Stay tuned for documentation...

a few summer projects

I spent June traveling across the continental USA, visiting friends and making field recordings.  I will cover that month's activities in a future post. 

In July, I moved into a retired auto-body shop in industrial Greenpoint.  I am helping my flatmate convert it into a recording studio.  In the meantime, I have been fiendishly networking and putting together creative projects.  Starvation and searching for jobs have also taken up some time, as well as taking online TEFL certification classes and reading up on the GRE.  The ideas I have for projects are as follows, in no particular order:

1) I have been playing the piano a lot more regularly.  I want to start incorporating my love of home-brew analogue electronics with my fake (but much lighter) electric piano, in preparation for buying an old fender suitcase once I move out west.  I've never stopped loving to play piano, but only recently have I regained faith in it as a significant creative tool.

2) Learn MATLAB.  It's actually quite simple and well documented since it's commercial software.  Obviously I stole it, but if I start using it a lot I might get whatever Ph.D. program I end up in to pay for a legit version.  A cursory glance at the signal processing and wavelet libraries suggest some cool and very musical applications.

3) Acousmatic "scenes".  I am interested in using sound design to create narrative, stylized experiences.  This occurred to me while watching the latest Harry Potter movie (the dialogue for which was ridiculously bad).   I found that many times, sound takes over and carries the experience for the audience when other cues fail.  While there exist conventions for how this sound-language works, they are by no means rigidly defined, and certainly not purely representational.  I often think of musique concrete and acousmatic musics as analogous to computer animated features: the same 'uncanny valley' must be avoided.  Successful CGI commonly employs a healthy dose of painterly sensibilities, and de-emphasizes the ultra-photo-realism that plagues the genre.  I have specific scenes in mind that I want to do.  Briefly:

a) The scene in the new Harry Potter movie with the zombies and underwater fireballs.

b) A dream I had about screaming, tearing my clothes off and running into the forrest surrounding the village I lived in.

c) Waiting in a clock-garden.  Birds giggle and turn into distant female archetypes.

4) build a composition using successive passes of impulses and convolution with new impulses.  i'm talking either digital band-limited impulses or analogue logic circuit impulses.

5) take two inputs.  find approximate pitch (using autocorrelation) of input 1.  find n strongest partials of input 2. granulate input 1, retuning grains to each partial, remapping partial amplitude to probability weight.

6) using geometric series for rhythms.  

7) fix and expand Cattri into a new cluster currently missing a working title.

Items 1 and 3 are more like ends to means, while 2, 4, 5, 6, and 7 (and others not listed here) are more like means to ends.

On top of this, I have several projects I am working on for others.  They will also be documented as photo- and recording- ops present themselves.

adventures in auto-surveillance

every twelve minutes, a script on my computer recorded a one-second sample from a condenser mic pointed out my window.  this is what it heard.




while i find the idea intriguing, i think it needs a lot of refinement.  the idea of auto-surveillance came up as i was working 8 - 10 hour days doing landscaping for my parents' house in pennsylvania.  the original idea, which i still would like to pursue, was to analyze the incoming signal with a filter bank to classify events by their timbre and amplitude.  this way, i could build a database of short environmental samples for later use.  as i have had very little time to write any code, this experiment proved quick to implement and yields some satisfying results.  since i'm about to push off for a long road trip across the country, it feels a bit like how sailors would take handfuls of dirt and put them into jars.  i am looking forward to collecting more specimens as we travel.

tdat recording available online!

you may read & listen here.

we recorded the evening of 25.5.09, after dinner and wine.  we improvised mic stands from spring clamps and pop filters from spandex.  we hung a condenser from the light fixture.  it was good fun.  

once more i'd like to thank everybody involved with this project for putting up with me as i clawed and chewed my way through this crisis ---er, thesis.  it has been wonderfully murky.


our ramshackle setup:



The prospect of analyzing, categorizing, or evaluating something before it has reached fruition is somewhat problematic. However, for practical reasons I find it necessary to put some thoughts on "The Data and Tension" into type. "The Data and Tension" (abbrev. tdat) is a language-event for four vocalists. I find it useful to describe vocalist interaction as though it were a game. For a thorough explanation of the rules, libretti, or development of this family of compositions, I refer the reader to the project page, and to my thesis; both are available here.

My goals in constructing tdat changed as my understanding of it did. The major changes that occurred along my process involved tdat's content, production, and naming. Perhaps the most significant of these changes emerged when I began talking about tdat as an oral notative event.

For the first iterations of tdat, the rulesets were constructed through a labor-intensive analysis method of an arbitrary text. At first these texts were hand-edited and compiled from various sources, from class notes to pro-gun blogs. The most frequent significant words were rated for their frequencies and selected to be part of the rulesets. Then, using hand-drawn matrices, I attempted to construct rulesets that seemed balanced. The result was an arbitrarily structured game whose dynamics were unpredictable. After doing around six of these, I gave up with this method and inverted the process. I wrote a simulation library in SuperCollider and encoded the structural components of the games into a character string. Then I began searching for strings representing games with specific traits. Despite that the first few searches were not fully automated, the results were impressive. I eventually took each step in the algorithm and wrote a routine to schedule them, searching a very wide space for the perfect candidate. When the time came to realize one of these pieces, I replaced each of the characters with a sentence, written by me. The sentences, put in order of the characters in the string, would comprise the text. I eventually made one further inversion to the process, which was to write out the entire text in the order I wanted it, and to determine the mapping between the sentences and their functions from there.

As I worked, I became increasingly invested in the idea that my model of creative processes should support nested systems of signification. This decision also precipitated as I pored over book after book calling for the universal reform of the common practice notational system. It frustrated me that, even today, music discourses are obsessed with the Western canons' practices of visualized parameterization. An oral notation is subversive to these practices because they comprise an event that is experienced through time. This subversion is attractive because oral notation practices are extremely common, even in the Western conservatory system. When is an event a notation for another event?

Another impetus for moving toward calling tdat a notation were some of the responses I would get from individuals regarding my thesis and the genealogy
of my compositions. It was suggested by numerous individuals that since "Solo for Amplified Window" came from the realization of a meta-notation of "Sanction of the Victim" (and indeed many other compositions), that tdat must bear the same relationship to "Sanction" as well. These individuals wanted me to explicitly define, in the form of another notation, the mapping between the two pieces' parameters. I do not believe such a notation is necessary, nor does it contribute to the richness of the two pieces relating to each other.

I will probably continue my explorations into vocal/theatrical modes of production. While it is technologically deterministic to assume that computers make good performers or composers on their own, since it attributes intention, it is not unreasonable to consider that they offer the performing or composing human very sophisticated tools. I have been questioning what the term "computer music" even refers to. In the past, computers required a great amount of expertise and money to operate, and music-making was a separate practice. Today, computers are very easily and effectively integrated with musical processes and are much more readily understood, purchased, and maintained. What, then, is a specifically computerized music?

This composition requires a level of virtuosity on the part of the performer, both in that the task itself is difficult to complete and difficult to listen to. This virtuosic listening is also required of the experiencer. Rehearsal gave the performers the ability to make the piece more intelligible, or at least to consider intelligibility as an issue and exploit the elegance or performativity of the unintelligible. For the audience, the experience of being overwhelmed by language is attractive because it provides the opportunity for multiple paths through the arc of the piece. However, in order for this to be successful there must be an adequate recognition of the pleasure and care with which the performance is realized. This experience can be difficult to communicate effectively. To a certain extent, however, it is my intention that the experience of this piece also remain outside the realm of the understood, because I don't fully understand it either, because the mere event of having all of these parties strive jointly for the communication of pleasure precludes the understanding of such an event. Paul Chan said it best:

There is nothing to be gained by making work that relates, except perhaps the cheap thrill of understanding. Better to let the work be as foreign and distant as a star, or an ambush.

This thesis is, in some ways, rather inappropriate to the conventions of ITP: it is academic, murky, and, genetic algorithms aside, fairly low-tech. In some other ways, however, it speaks a language that I hope resonates with the people of that program. I want its strangeness to elicit laughter at the familiar.

the remix metaphor in intermedia

Merce's Isosurface (Excerpt) from Golan Levin on Vimeo.

Above is a stunning example of data visualization by Golan Levin. It is a realization of data transcribed with a motion capture system of Merce Cunningham's body performing, presumably culled and edited by the OpenEnded Group. The meta-notation consists of an invitation to re-purpose the data into new digital forms, for an exhibition / performance at MIT over the next few days. More information on the event here.

I am interested in the use of the 'remix' metaphor, which could be stated either as an alternative to the metaphor I'm currently exploring -- notation -- or as a kind of subset. I am inclined to believe the latter-- that notative practices encompass remix practices.

The reason we can take a remix to be a form of re-realization is that a recorded artifact can be taken to be a transcriptive notation. This conceit has important results, and I would sum those up with the notion of a homolog / analog axis-- a 'concreteness' parameter. To say that a recording of an event is a notation of the event is to say that the notation bears a concrete relationship to its realization. To remix this recording, then, is to re-realize this notation.

The remix metaphor is something I have a bit of experience with in my own practice. As a computer musician, often the only notations I have to work with are concrete. This notative modality, as any other, comes with a unique set of semiotic assets and liabilities. The remix favors certain levels of meanings and deprecates others. Despite the fact that this tendency is universal and there is no escape, we can problematize it in the hopes of enriching the practice.

In my experience, the biggest issue that comes with the remix is that it deprecates the hierarchical aspects of its remixed. This is because of the flattening out of the dimensionality inherent in the recording process. Yes, one may have access to, say, the vocal multis of a recorded work, or one can isolate those parts in order to drop them into new material, but the remix metaphor requires the direct manipulation of the material comprising the remixed. Even if remix practice is re-evaluated in terms of intermedia, as in the above example, the underlying compositional motives, overarching social context, or specific technical implementation are not sufficient conditions for a remix.

For example, there exists the distinction between the cover and the remix, where a cover implies other restrictions on form, but the source of that material becomes unfixed. If one were to supply a piece comprising entirely new material that bears formal similarity to a component of a previous piece, then one has participated in an act of quoting. All of these modes may be distinct subsets of notational practice, if that practice is re-evaluated in terms of intermedia.

Of course, Golan's remix of Merce and OpenEnded Group is still very much a remix. And still very much awesome.

tdat performance today!!!

I can't wait!  This is actually turning out to be more fun than terrifying.  For a while there, it was pretty terrifying...

I found a group of ITP students who seem to like doing the piece, and do it well.  They are: Elizabeth Fuller, Ted Hayes (Tedb0t), Lee-Sean Huang, and Kristen Smart.  I could not have asked for a better group, to be honest.

Our first performance will be today at 12:30 and I am totally psyched and not at all terrified.  The project site may be found here.

The text that we have settled on is technically version 8A, although this is misleading because between version 6 and 7, and version 7 and 8, are a very large number of simulated versions that were never tried by humans.  That number is even larger for the 'demo' versions a and b, which may not end up happening at all.  At least the genome files are intact for the demo versions, so they can be pored through and represented / appropriated however anyone should see fit.  The entire genome for demo b, a trio, is available here.

The version we will be performing is available in pdf form here: rules, text.

I plan on making an audio recording of the debut.  I'll post it when I do.

tdat performance considerations

this week i have four final project presentations in a row, and "the data and tension" will comprise no less than three of them.  mostly, this decision was arrived at for practical reasons: i want my performers to have a few chances to practice before the actual presentation on may 8th.  it will also be nice to have the experience of trying to explain it a few times before the big date as well.

i have decided that in addition to my preamble where i problematize transiency and opacity in creative work with technology, just after i play the binaural recordings from the installation, i should engage two audience members in a demonstration of the tdat system.  this way, in explaining the rules we can see them applied to a smaller system first, and the audience has the opportunity to experience the dilemma i'm trying to communicate.

this new ruleset is currently being located by a massive automated genetic search algorithm i wrote in supercollider.  i'm searching for this new ruleset with a lot of improvements to the code that both automate the entire workflow and properly log each step of the process for future sonification / visualization work.

i am still uncertain if a duet version is viable, because it's currently on its 140th generation of 32 and we're still not getting reasonable results.  i may can the duet idea and go for a trio instead, but i'm going to let this run for a few more hours and we'll see if i eat my words.  i hope i do, words are tasty.

linguini photo shoot

before i distribute these guys, i thought i'd get a few shots of them all lined up.  space baffles me- notice how, in each perspective, no two constructions can occupy the same region.  i know that idea is really basic but it's also somewhat counter intuitive. these are digital representations of physical objects, whereas i'm used to working with digital representations of digital objects.  the physical objects themselves are representations of a digital signal, itself a representation of a mathematical construct (wavelet analysis) applied to the representation of audio, which is a representation of a single point of entry for a computer flock in a previous iteration of my composition for LAN which i call 'sanction of the victim'.  the title refers to the fact that the auditory processes that play out in the composition represent extra-formal ideas- in other words, it is programmatic, it "tells a story".  the story is a critique of the network, where flocks of order-seekers are assaulted by the network's exploit, a fork-bomb.

these sculptures are notated forms, in that they are transcriptions of a previous event (that particular moment in 'sanction of the victim'), but also in that they will prescribe some event-artifacts.  they will be realized, in other words.  i hope to distribute them among my co-conspirators this weekend and afterward, so their ambiguities and limitations can be exploited.  i made them 'the same', in that the instructions i followed to construct them remained constant for each piece, because

a) they are not the same (this is different from the digital case)

b) i want to emphasize the multi-centeredness of the realization space by varying the realization conditions (who, when, and how), while keeping the notation as a constant

little tongues

"linguini" are what im calling this family of objects. originally their shape comes from analyzing a very short section of recorded audio. since the analysis divides the single burst of audio into many hierarchically organized streams (some bigger/more influential than others, in a tree format), and also due to their noodle-like appearance, i'm calling them "linguini" (little languages). they've all been constructed the same way, so they look pretty similar. at first, i was going to assemble each one slightly differently, but this is the layout that i kept coming back to. even so, each one is different simply due to their physicality-- that and my incompetence with regard to fabrication. i made these in an attempt to play with the idea that a sculpture could serve as notation for something else. already, without further realizing, the linguini are transcriptions of a previous event. they are inscribed with the representation of that event's micro-worlds. since they are the result of an analysis process (the Haar wavelet transform), the details are encoded rather than directly represented. i find the form itself to fairly reek of musicality: there are 8 layers, with each successive layer (after the first two) doubling in complexity, with most complex layers approaching the look of a noisy, organic surface.


there is, as always, a fairly rich precedent for visualizing sound, even into sculpture. formally speaking, the linguini do not break new ground. it's their proposed function that does.

what does calling an (otherwise formally pleasing, sculptural) object a notation really accomplish? musical notation is a system that contributes to the creation of worlds pertaining to specific roles, artifacts, and events. Cage and others categorize the roles involved as "composer" /"performer" / "listener", while still others prefer categories that favor other aspects of this dynamic. the artifacts of music could be things like instruments, venues, and notations. (i even begrudgingly concede the inclusion of the grammy award as an artifact.) events may include composition, audition, practice, participation, experience, etc. semiologically, notation participates in an infinite regress of meaning, and, especially in the thoroughly fragmented worlds of contemporary thought on the subject, notation implies a relationship between events, any of which must be potentially resolvable to another notation. because of this troublingly recursive nature of the system at play, a piece like Paik's "Zen for Head" can be positioned as a realization of La Monte Young's "Composition 1960 #10", and Young's piece "Second Composition for David Tudor" a pithy realization of Cage's 4'33". in the continuum of African American creative music, this practice may be observed as well, for example in the work of restructural master Charlie Parker. notation is essentially incomplete, by which i mean it is almost always analogic to its signified, and often there is a loss of clarity at the more homologic end of the spectrum. examples of more homologic notational practices include the concrete arts, where tape-splicing or typography have the tendency to 'point to themselves'. pop musics may often allude to this practice as well.

despite its apparent ambiguity as a notation, a physical object has mass, texture, fragility, uniqueness, and an abundance of other attributes that can constrain the variety of approaches to realize it. while the set of legal realizations remains infinite (just the same as, say, the set of legal realizations of a Bach fugue), the notation's physicality both enriches and limits the variations among set members.

against my better judgement, i have attempted to realize the first linguini, "A", by amplifying it with a contact microphone and rubbing it. using that sound material as a source, i produced a sonification of the most recent TDAT system. this sonification only responds to the pauses that happen as the result of a player hitting the end of her text without further re-triggering. i actually sonify each unit with a different grain lifted from the source material, but i constrained the amplitude such that we only hear the pauses, and perhaps part of the following and preceding units. each player's stream is differentiated by a filter that emphasizes one of four resonant tones of the object, derived from a fourier analysis.

i'm very excited to distribute these notations among friends to see their decisions. that's such an essential part of this idea: that a tool that was such a normalizing force, one that eventually grew up to encompass the property aspects of a piece of music, could be used in a way that confounds traditional forms of ownership, and meanwhile, lets us try to disentangle (or re-entangle) the idea from the technology.

the data and tension - 7A-D

finally, after all manner of disasters, i have 4 fully functional vocal pieces. all using the same text, this complex represents the 20th generation of a rigorous genetic algorithm whose fitness function takes an average over 32 scenarios. in a tested setting, piece 7A should be the most likely to continue indefinitely, since its average running time was 72,167.65625 turns. each generation of the algorithm spanned 32 possible pieces, and tested them 32 times to get a reasonable average for the fitness function. given the wide variation in output, however, i wouldn't mind it if future generations applied some other filtering techniques to punish inconsistency. right now, though, i feel good about these four. they not only test well, but they look good too, imho: i have come up with a rough draft of filled in verbal 'content'. from here, i'll probably pick one of the four (most likely 7A but you never know) and i'll spend the rest of my time tweaking it until it's just right. i also have to leave some time in to find a group and rehearse. my current plan is to have this piece comprise a large portion of my thesis talk-- a pretty risky move, considering how many other things i'm doing that i could talk about. i really don't want to address the thesis paper directly, and i think a lot of the concepts are better seen from a multi-resolutioned perspective. hey-- it's that or show documentation footage. this seems more enjoyable for my audience.

still unclear if i'll project the entire text or just the rulesets. the rulesets all happen to be nice and oblique for system 7, so if it stays that way, i may just project the rules to the audience and let the more prose like stuff lean on the conversational side.

genetic algorithm updates

continuing the thread from the previous post...

i'm on generation lucky thirteen, and i have doubled the gene pool size to 32 rulesets.  i've also automated the testing - scoring - averaging process, which was the bit that was so time consuming and required the majority of the mindless repetitive human input.  now i have a routine taking care of that for me, although i had to fork it off the SystemClock instead of the TempoClock to avoid overloading the scheduler.  also, it still takes about half a minute to run through each game, which means about 15 minutes for each generation.  again, this isn't because the processor is slow, but because the turns actually take miniscule (but not zero) amounts of time.  i did this because i can't figure out how to model the system in any way that does not involve forked scheduled routines.  at least im not still sitting in front of my computer pressing buttons every few seconds like a trained monkey.  well... that's debatable.

also, i have been writing out data files representing the genomes for each generation, but i discovered today that the first 10 files had been corrupted.  i have fixed the problem, and was able to save my breeders for generation 11.

i am interested in the possibility of sonifying rulesets as computer music.  obviously i'm interested in sonifying them as vocal music and instrumental music, but today i was thinking about how i'd do it with a computer as the source.  i think the concept that hurt my head when thinking about computer sonification before was that i assumed i'd let each unit resolve to a sound.  a more attractive approach, at least to me, would be to let only significant units (ie those with transitions) resolve to audible sounds, and let everything else resolve to blocks of silence.

tdat- a genetic approach

so, the last post on this topic left me with a ruleset that i liked and moving on to start filling in those ascii characters with meaningful content. i am sorry to say that i have hit a snag. that is, i ran a few simulations of the 'tHl' ruleset and got enough unsatisfactory results that i decided to can it. i was not thrilled to do this, to be sure.

i have somewhat intentionally been allowing my ideas to stew about what to fill into those characters, since i will be performing the piece as my thesis presentation and i'm still doing some research. it no longer worries me that i do not have this content, since i'm bursting at the seams with ideas for what that content should be. what worries me now is that the structure is inadequate, and that i had prematurely settled on such a structure.

my solution has been to use a genetic algorithm to traverse the massive search space and find a ruleset with a reasonably good chance of lasting longer than a few asynchronous turns. i am not modeling sexual reproduction because the bitmasking involved makes it somewhat unwieldy. in other situations breeding would make more sense. Jenny and i just aren't ready for that just yet. har har har. seriously though, sexual reproduction is terrifying.

so these rulesets don't breed, they split and mutate. charming, no? i spend most of my time testing them, all 16 variants at a time, 32 times per generation. the variants are then evaluated for their average longevity. in my implementation, since i do plan on sonifying these systems, each player in each game is a routine forked off of the system clock. that is, each turn does take an amount of time, albeit small. i have tuned down this timing element to vary between 1/128 to 1/256 th of a second. i was able to do smaller subdivisions with smaller gene pools, but i decided to go for bigger populations. at the end of each generation, i write out a little data file, keeping track of the population as it evolves, and then remove all but the top 25%. these four are permitted to pass on their genes to 3 other children each, and themselves live on to compete in the next generation.

right now, i'm on my fifth generation. generations take about 20 minutes each and require intermittent input. not the best implementation, but for now it'll do. i may eventually get this running on its own. perhaps i could distribute the breeding process across the cattri. right now that seems like more trouble than it's worth, but who knows. there are so many variables at play here that perhaps the only way though is by brute force.

flight of the cattri

for those who need to be refreshed, the Cattri = my linux cluster.  currently, it's four old-ish computers i got for free, connected with a router, which communicate with each other (and anyone on the wireless network) over OpenSoundControl (UDP) and SSH.  the name comes from the Pali word for the Four Noble Truths in Buddhism, literally "the four".  each computer is named after one of the Noble Truths.  i use these computers to make music.

last semester, i composed a piece for the cattri called "Sanction of the Victim", and implemented a few proofs-of-concept.  eventually i performed it at  Diapason art  space  for a crowd consisting mostly of my classmates.  if you'd like more in-depth documentation, feel free to dig around in my blog archives.  there have been lots of versions of this composition.  the basic idea is that there are two systems, like species of organisms, let's say, living on a single network, sharing its resources.  one organism likes to band together into herds, and those herds tend to band together into meta-herds, and so fourth.  these are represented in sound as a pitch constellation, played by a virtual instrument that resembles the Gamelan, but in only the most extended sense.  it also sounds a bit like a drippy shower head.  the other organism spreads virally, using up network resources and eventually disabling the router.  it exploits minute differences in the timing across the network.  this beast sounds a bit like a furious tremolo on a rubber band orchestra.  when i performed the piece, after i infected the network with the virus, i got up and theatrically unplugged each computer from the router, performing a kind of quarantine.  if you caught the reference from the title, it is a case of "Belkin Shrugged".

in addition to relating to my thesis, this composition is significant because i will be performing a revised version of this piece at the SuperCollider symposium on April 10.  until recently, i had been focusing a lot of my efforts on the flocking algorithm that directs the pitch constellation.  there was also an issue with representing the positional data of the flocks with the pitch constellation, which i solved using a hyperbolic wave terrain (see terrains-- they're pretty!).  each of these tests i ran on my blazingly fast macbook pro.  when i first tried to implement the flocks on Dukkha ("the reality of suffering"), often the first "remote" location i test things on, it pretty much started emitting smoke.  ...ok that's an exaggeration, but it was bad!

i spent the next few days trying to make the algorithm more zippy.  i overhauled the synthesis functions and got them under control.  initially i had wanted each note to ring out for a period inversely proportional to its frequency, so lower notes would last longer.  when this was implemented, the fact that each note brought with it more cpu overhead became a serious problem.  to solve this, i ended up using a physical modeling approach where each 'note' is triggered by a similar excitation signal-- basically enveloped pink noise-- and the different notes are really the result of a ringing filter, simulating a resonant body, like a bell or drum.  this way, i raised the overhead for the whole system, but decreased the cpu spikes that would occur if many notes overlapped, since the excitation signals are very short.

once the synthesis functions were more efficient, i tried to tighten up the logic that triggered them.  the problem was the flocking algorithm itself.  no matter how i sliced it, or which scheduler i used, nothing was happy.  the fact of the matter is that using my implementation and hardware, a flock of 40 automatons is simply too much to handle per cpu.  i realize that i could use a kd-tree structure or something similar to divide up the space into smaller quadrants, but that is for a later revision.  for now, the problem has been solved by distributing the pitch constellation across the cluster with a good deal of redundancy.  i let each cpu handle a constellation of 13 flocking pitch-creatures, giving me 12 pitches that are doubled.  i mapped these out to make sure they are not in reinforcing sections of the octave.  since each cpu will have representations of the other cpu's average positions and headings to flock with, i am not concerned with the computational tradeoff.

then came the problem of distributing the flocks across the network.  i had gone through a lot of testing to ensure that a model of the process would work between my macbook and Dukkha.  because much of SuperCollider is an interpreted environment, working on many computers at once can be somewhat troublesome.  it's hard to remember exactly what you have going on in each environment on the network.  it's like trying to keep track of four different conversations at once.  a lot of networked music solutions i've seen in SuperCollider, Chuck, and PD do not address this problem, since the common assumption is that each computer is manned by a different performer.  i have developed a tool to extend the supercollider environment so that it is readily distributed on my hardware.  i made no real efforts to generalize it, since my needs are my own, but in reality it would not take very much to use it on other distributed SuperCollider setups.  even with this tool, i was running into problems with addressing multiple computers simultaneously and transcribing the event into a reasonably easy to interpret notation.  i resolved this problem-- and thus arrived at code that lets my Cattri flock together-- by further extending this tool.  now, i can make transcriptions of code that gets sent to each computer, with notes on which computers received the code.  i realize now that as a performer of "SoV", my instrument is not only the Cattri itself but the tool i created to interface into it, so a static representation of the code that runs the piece in the abstract is not enough to allow for simple realizations.  for a notation to work properly, it must be something that takes into account instructions for me as well as my cybernetic extensions.  in other words, i am now a firm believer in documentation.  of course, eventually it is conceivable that i could condense this notation into instructions for my laptop to conduct the piece, without my direction at all.

so i have some documentation videos and sound recordings, but i'm afraid i'll have to wait to release them until after the 10th.


I'm still working on SoV.  Now that the flocking is fixed, I've moved on to debugging the parameter space itself.  I had been saying this whole time, since winter, that the x,y coords relate to the frequency and phase of the notes being struck, but I found out today that this is not quite the case.

If it were the case, and you mapped the phase information (whether the note should be struck or not) for every point, it might look like this:


In the picture above, colour is used to denote where in the phase the oscillation should be, given that position.  It's a wave terrain, basically.  Now for the fun part.  When I first started trying to notate (!) the system into a function system, I ended up with some chaotic-seeming behaviors.  Graphing the system revealed the bizarre truth, yielding something that looked like this:


This is not what I was expecting!  Above we see the same terrain as before but zoomed way out.  The patterns are the result of aliasing.  Even using a very high resolution, these patterns appear (in fact they get worse).  They are the result of sampling itself, and actually require a smoothing filter to reduce the artifacts, much like sound aliasing.    And, also like its sonic counterpart, I think it's gorgeous.


This one is even higher resolution.  The self-similarity is so pleasing to me.  And finally, my favorite:


I have actually made a few animations of these, where I alter the z-axis and you can see the whole system seem to bubble and seethe when you are really just zooming in or out.  This last one looks like it was knit or something.  I think it would rule as a sweater or blanket.

Don't worry, I'm still working on SoV, but I thought this accident was worth stopping a moment and considering on its own terms.  Also this has brought me some insight into another use of notation.  Our ears are very precise, but only in certain capacities.  While the same could be said for our eyes, these two modalities tend to appear complementary in many of their fortes and foibles.  Seeing something plotted out can not only help explain what a performer is to do, but it also facilitates certain kinds of analysis.  I had been using graphics previously to show my audience something about the music.  I do not think this is necessary for something like SoV, nor is it the only way to use graphic notation for systems music.  Nor are we stuck with max-patches.  This experience was an example of what happens when transcription is used for analytic purposes, as an aid for the composer.  I would say the same for my experiences with the much less visually pleasing display for TDAT.  TDAT's application of transcription was more symbolically oriented, however, which lends itself to still other types of analysis.

flocking study

The patch documented above uses a similar parameter space to the previous study, with each ellipse representing a static tone in a constellation, and the x,y coordinates of each ellipse determining the frequency and relative placement (phase) of the occurrence of that tone.  Here's some SC code for it: Boid.sc, boid_test_0.scd.  This particular example uses a random pitch constellation, instead of the one for Sanction of the Victim.  Boid.sc is directly based on Shiffman's Processing class, itself directly based on Reynold's synonymous algorithm, commonly used in computer graphics.

It's kind of amazing and wonderful that different self-organizing algorithms make such wildly different outputs, even with the same (or very similar) parameter mapping.  This one reminds me of tape delay.  A nice tweak to the parameter space could be to have the left edge (x=0) be rationally related to the right edge (x=width), and let there be a more smooth fade between those two states.  That way, there would be no discontinuity of frequency, and the x axis would comprise a Risset-Sheppard phenomenon (ritardando or accelerando).  I will also be playing with tactics for increasing sparseness in the sound masses, such as constraining the x-mapping to comparatively low frequencies, or making entrances and exits happen for one pitch at a time.  Also, the prospect of applying this parameter space to sampled sounds might be interesting, so instead of letting each boid represent a different pitch, let each boid represent a brief sampled 'grain' from a soundfile.  That way, the listener might have more attention to devote to the sequence of the firings.

repel study

Each ellipse corresponds to a pitch in a constellation, with regular occurrences (events of 'striking the bell') determined by position in the window (frequency vs phase). Ellipses have a mass directly proportional to their size and inversely proportional to their pitch. The ellipses are attracted to each other according to gravitational laws, and repel each other according to a 'force field', whose magnitude may vary across the arc of the video. When two ellipses repel each other, a transient sound event (grain-like) occurs, whose spectrum is determined by the ratio of the two pitches involved. When more than three ellipses repel each other at once, a squealing bowed metal sound occurs, also related to the ratios between constellation pitches.

I wrote the code in SuperCollider as part of an effort to clean up the sourcecode for other pieces based on dynamic systems, such as Sanction of the Victim's flocking algorithm.  Actually, this study uses SoV's pitch constellation and mapping of frequency and phase to x,y coordinates. SoV's debut performance at Diapason used classes based on Fredrik Olofsson's "Red Universe" class library, which I modified to get a "Boids"-esque behavior. While his class library was useful as a springboard, I found its implementation slightly troublesome. Not that his code was somehow bad or anything, but there were a few things I would do differently. Specifically, the reliance on inheritance made for confusing code, although I assume that his reasons for using that style were didactic. So my project has been to rebuild a class library specific to my needs and coding style. This gravitational forces study contributes to that effort.

Source code for the above movie available here: Class Definition, Implementation Script.

object as transcription

detail shot
detail shot
front (zoomed)
full frontal
"myspace" angle
"myspace" angle
side view
side view
top view
top view

I've been thinking about the different functions of notation, such as transcription or transmission, and the different forms that these things can take, such as schematics or so-called 'concrete' scores (recordings), and trying to put some strain on the meanings to come up with some murkiness. After seeing the beautiful 'ur-scores' of Doug Wadle-- and initially misinterpreting them to be of mixed media rather than paint, due to the fact that I was looking at pictures-- I decided to investigate the possibility of using a 3-dimensional object as a kind of notation. Precedents include (but are not exhausted by) Cage's "Rocks Role (after Riyoanji)", the aforementioned Wadle, Xenakis' work with architecture, and the use of electronic circuits themselves -- not their schematics-- as scores by the likes of Tudor, De Marinis, etc. How can the ambiguity inherent in using an object as notation be overcome and used as a strength?

After making my portfolio recording of 'Sanction of the Victim', a composition for 2 or more networked computers, I was looking at the waveform up close and found this really cool shape that lasts ~0.09 seconds. It turns out, this artifact happens a few times in the recording, and it is the result of all the tones in a pitch constellation flock being struck at once, and the filterbank momentarily blowing up. Because of the flocking algorithm used to determine rate and alignment between the tones in the constellations this only happens once per computer. It occurs at the moment when the system on a particular computer starts up. I grabbed the brief snippet (only 4096 samples long) and performed an analysis of it, breaking it into 12 layers using haar wavelets. I first cut the shapes of these layers out in foamcore, discarding the top 4 layers because they were way too complex to cut out at that scale. As it turned out, the top two layers were still nearly impossible to do in foam with an xacto knife. I sent the vectors, along with some 1/2" thick medium density fiberboard, to AMS for lasercutting. I was dismayed to find that 1/2" MDF proved too difficult for their laser to cut through without starting a fire, and they sent me home with a charred piece of synthetic wood. I came back with 1/4" thick masonite, which they lasercut without incident. The resulting layers I fixed together with woodglue so that the lowest values lined up and the piece could stand upright. All this was painstaking work, but a nicely different pace from directing vocal pieces for humans or programming computers to simulate them. Also, I do enjoy the feeling of carrying around raw materials in Manhattan. For some reason, there is a level of devotion to a composition that is felt when one's arms ache from schlepping as the result of it, which is different from the devotion one feels to a massively complex piece of software. Well... sometimes. 'Sanction of the Victim' is both a massive piece of software and four computers, so my arms and brain felt the devotion to that one. The weight and dimensionality of this first masonite form (there will be three more) certainly work for me as components inspiring devotedness.

I do not know the proper way to realize this score. I have suggestions, though. One could trace or rub the score onto paper, superimposing staves perhaps. It could be a Rainforest object. It could be a Cartridge Music object. It could be that you're a computer science enthusiast and you make a table of the wavelet coefficients (with applied scale) of the values implied by the score and resynthesize the original recording (at a lossy compression, due to the missing top 4 layers).

tdat systems testing: a bottom-up approach

The vocal piece and its corresponding realization as an instrumental piece uses the following algorithm:

Four players share an identical sourcetext, divided into four sections. Each player has all four sections.

Each player has a unique ruleset consisting of four trigger words, each linked to one of the four sections of the sourcetext.

The piece starts with one player starting from anywhere in the text. The player reads aloud ten of the words in the section. Since the player may start anywhere on a given section, the player should wrap up to the top of the section when she hits the end.

When a player hears one of the other three players say one of her trigger words, she must move to the section of the sourcetext associated with that trigger word in her ruleset, beginning anywhere within the section. Players do not trigger themselves. If a trigger word is said that would move her to the same page she is already on, she ignores it.

An end state is reached when all four players have stopped reading.

In the above description I refer to the smallest significant unit of text as words, but this clearly need not be the case. It is actually a much easier prospect to listen for longer events such as phrases or sentences. Scale is a huge factor. For the instrumental realization of this piece I am planning to have my performers listen for musical phrases or contours, not absolute pitch.

I wrote a small class library in SuperCollider for handling simulations of rulesets. There are two classes: a player and a game. In various implementations ( 0 1 2 3 ) I have been using them slightly differently to pull different kinds of data from them. I started by running a few lines of code that generates sourcetexts with pseudorandom numbers. I was able to collapse rulesets and sourcetexts into one axis by keeping the rulesets the same throughout. I used the ascii characters [a-zA-Z] to stand for 'words', and the ruleset matrix remains

A    B    C    D

E     F    G    H

I     J    K    L

M     N     O    P

where along the rows are players, and along the columns are sections triggered by the character. Since all other ascii letters trigger nothing, they are interchangeable. What is really significant is where each of the trigger words are placed within the text. To simulate playing the game without turns, I had each player fork off and make moves after pausing for an exponentially weighted random amount of time, spanning from 1x to 2x. I am working, then, with sourcetexts of 52 'words', divided into 4 sections with 13 'words' in each.

When I was first testing this piece out with people, I would start with a sourcetext that I liked, divided it up by hand, and performed word frequency analysis to arrive at a ruleset. This was incredibly labour intensive. Also, I found that despite certain top-down constraints I would work within, such as maintaining a balanced transition matrix or placing trigger words for each player in each sourcetext, etc, the systems would sometimes misbehave. That could mean we'd get stuck in a loop or the system would end prematurely, or that players would miss out on reading a particular section of material entirely. There are so many sensitive factors that go into the initial conditions of this system that to parameterize these and come up with some linear solving strategy seemed way out of my league. And initial conditions aside, the mere fact that these games are played asynchronously provides us with a further level of inconsistency. There was no way I could be sure that my intuitions in composing the rulesets were guiding the outcomes at all! Plus, how many times can you really find four people willing to try out this exercise, even in grad school?

Using this class library, I'm able to test rulesets out at extremely high speeds, in high numbers, and generate massive datasets from the outcomes of those hundreds of games. I started by randomly generating about 50 systems and testing them for longevity, using a metric that makes sense in light of the fact that we can't measure time in synchronous turns. From this first round, I selected 13 systems whose longevity metrics were significantly higher than the rest, and tested those for longevity, also generating markovian transition matrices to determine the probability of a particular rule being carried out at any time. A more balanced matrix would suggest a more even distribution of sections to be read by players. Finally, I honed in on two systems whose longevity scores were an order of magnitude higher than the others. I ran tests on both systems to determine the average length of a game started by each player. During this process, I selected the system that will become my piece by taking the average longevity score of all the players longevity scores: tHlcqbunKdrifgojIPEDLXwxmNGMQVJRahZBFUkWsOeAyCpTYzvS. I've been calling it 'tHl' for short. The initial condition preference weights end up thusly: [ 0.26285490520858, 0.45210917667393, 0.18168356048467, 0.10335235763283 ], so player 2 should start ~45% of the time, with player 1 starting ~26% of the time.

To programmatically allow for changes in density, I would like to try having certain non-trigger words resolve to silences. Because I decided this while I was running tests (a nice affordance calculating machines give us is to let us pay attention to how we're interpreting them), I was keeping track of the number of times a player reached the end of their sourcetext before getting triggered to change to a new section.

Since I am to perform this piece (possibly as the thesis presentation itself!) in May, I have decided to stop there with the analysis / synthesis of systems and get on with replacing those ascii letters with meaningful bits of stuff. However, with a more rigorously organized setup, I could see myself crunching a lot of numbers to come up with something better. With all that data, I would probably be able to come up with alternative realizations / infra-notations of all kinds. One particularly interesting realization could be to produce a statistically analogous outcome using a classical markov chain based on the transition tables I'm getting from the analyses. That would mean very different things, since in the presentation of the piece I'm also trying to frame the performers' dilemma for the audience. Because the outcomes could potentially be fairly similar, it raises some interesting points (at least to me) about the typical parameters that conventionally comprise an alternative realization.

ps I will be sonifying this system many times over-- that's why I decided to go with SC instead of python.


here's a simple markovian sample munger written in python2.5.1. should be compatible with 2.6. all bets are off for 3.0.

analyzes wave files. don't be a joker and run mp3's through it unless you're willing to accept the consequences.

it takes a really long time to generate transition tables for each sample. this is mostly because i'm new to python and my programs are not optimized. eventually i'd like to have some flag that lets you save transition tables based on samples so you can generate new soundfiles from old transition tables without having to re-analyze the soundfile. on any reasonable machine hovering around 2 ghz, a one second sample takes a few seconds (<30) to analyze. generating the soundfile may take a few seconds depending on how long a file you asked for. run the script without params to get its usage. usage is also covered in the comment block at the top of the script.

usage (assuming python aliases python2.5 / 2.6):

python markovSamp.py <path-to-infile (unix-legal paths only)> <depth (samples per unit)> <length (number of units in output file> <path-to-outfile (will write to new file if filename doesn't exist at path)>

happy munging!

ps- I used this script to generate the following stereo signal from one of the Unwashed guys' dark psy kicks.  They called it 'the monster', hence the name.

Markov Monster