Tuesday, January 29, 2013

Caleb Continues

Just FYI, fellow fan and Fox foe Caleb Hines has continued his study of the Coulton and Glee "Baby Got Back" tracks, over on his own blog, in a new article.

Monday, January 28, 2013

Crowd-Sourced Forensic Audio Analysis (or, How Glee Did It)

Before you read the rest of this: go here and read about what Jonathan Coulton has done to try to make the best of an ugly situation, and buy his track!

OK, now welcome back.

So, I've long known that Jonathan Coulton's fans were... different. Enthusiastic, one might say. Insane, one might say, but in the nicest way. My experience has been that they are great people, and very sharp people. Nerds? Well, that does kind of go with the territory. And honestly, while Mr. Coulton is very talented, Coulton fandom seems, to me, to be not so much a cult of personality as it is a group of people interested in new possibilities. What if musicians didn't need labels? What if they didn't even need studios or producers? As the Glee incident shows, though, they do need lawyers. And it doesn't hurt that they have fans who will watch their backs for them.

So in my last post I isolated the duck quack on the Glee version of "Baby Got Back." My previous blog entry was linked up by Wired and even CNN, and others. Some of them quoted me. Some tried to summarize my point. Some of them even got the basic idea right, but some seemed to say that I had shown that there was no smoking gun, which is the opposite of what I set out to show. So, ummm... let's see... let me make this as clear as possible:

I made a little video to go with this essay.
What I believe we’ve shown -- I say we, because other Jonathan Coulton fans have contributed their brains and ears -- is that Glee used Coulton’s Karaoke track as a starting point, then center-cancelled it to get rid of the bass, and some of the percussion. Then they did some editing, to simplify the banjo parts a little bit, and to kill some of the more complicated bits of Coulton's backing vocals, and mixed their new bass, drums, and vocals with it.
They did not start with the full song in FLAC form or from the CD track, because if they had done that, they could have perfectly killed the duck quack. They didn't start with Jonathan Coulton's distribution of source tracks, because if they had, they wouldn't have had the "quack" in there (it isn't even present on any of those source tracks). They didn’t start with the regular song in MP3 format, because if they had done that, the center kill would have left a hint of Coulton’s lead vocal. They did not use Coulton’s bass line, as Caleb Hines has shown. They used the Karaoke track, and it left a trace of the duck quack there. 
They chopped it up and copied and pasted some segments to choose simpler parts of the banjo and get rid of some of the bits of Coulton’s backing vocals (the “little/middle” bits). They tweaked the opening hand claps (as Jon Schell has shown). Most of Coulton’s backing vocals, though, are _still there_. They added a new bass line and some of the percussion. They added some new backing vocals (with a sh*t ton of auto-tune) and added a new lead vocal, and some little fake “string squeak” noises. 
So that’s what they did, and in the text below I describe in more detail how they did it. If you don’t believe me, try the experiment yourself!

OK, still here? Let's go into it a little deeper.

The various versions of "Baby Got Back" that Coulton released -- the MP3, the Ogg, the FLAC, and the versions on the Thing a Week and JoCo Looks Back CDs -- all have the duck quack. They are all made from the same stereo mix. If you want to listen to it, it's at 2 minutes 40 seconds into the song -- you can hear it in this video. Or you can listen to this short clip taken directly from the FLAC of Coulton's "Baby Got Back."

OK, so in the last article I mentioned that Jon Schell proved it is possible to cancel out the "center" of Coulton's song. Let me clarify what that means.

In a stereophonic music track, we have two channels, left and right. But audio engineers tend to think a little bit differently. When preparing a song, they want to make sure it will sound good on as many different kinds of playback devices as possible. They test for mono compatibility -- does it still sound reasonably good on one speaker? They test to make sure it still sounds OK on a system that can't reproduce low bass notes. They test to make sure it sounds OK on a car stereo, where the driver might hear mostly the left channel. So we are accustomed to thinking of them as just those two channels, but audio engineers sometimes think of them a little bit differently -- as middle and side channels. How much sound, and what sound, is in the middle, and how much exists only on the side? To find out, you do a "center-cancelling" trick.

If you take a stereo audio track, copy it, flip the copy upside down, and mix them together, then the second copy will have a waveform below zero at the point where the first copy has a waveform above zero, and vice-versa. The net effect, in digital audio, is that the two tracks will perfectly cancel each other out -- you will hear silence.

But you can do a more complicated trick than that. You can invert one side of a track, and leave the other side intact, and them mix them to mono. What is left is a negative copy of the musical data that is identical on both sides -- everything that is different has been cancelled out. You can then mix this "negative center" track with another copy of the same track un-modified, and the result is a track where everything that is mixed right in the center is killed. If the main vocal is mixed dead-center (and this is not always the case), you've completely killed the main vocal. If it works, you've just made a free karaoke track.

In the case of Coulton's "Baby Got Back," this works really well, as you can hear in this sample. That's the same bit of the song as the previous clip, with the center killed. So, Fox could have used that track to turn Jonathan Coulton's track into a karaoke track and added their own singers on top of it. But there are two complications: first, the bass and some of the drums are also centered. So these are also completely killed. The track now has no bass and has only shaker and tambourine and hand claps for percussion.

So, to use this technique, Fox would have to re-record the bass and drums. Caleb Hines has done a close investigation of the bass line, and his results suggest that they did just that.

And second, if they did this, the duck sound would have been killed, just like it is in my sample. Right?

Well. Hmmm.

If you listen closely to the Glee track, you might notice that their backing instrumentation doesn't sound very good. It's a little distorted. There's a reason for that. The reason is that they used Jonathan Coulton's Karaoke MP3 file to build it. (Here's a link to the store on his web site). So they were starting out with compressed audio, which they uncompressed, and then added tracks to, and then re-compressed.

How do I know they used it? Via a process of elimination. The "ghost quack" is present in the track -- so they didn't use the FLAC or a track copied directly from one of his CDs. But there are no "ghost vocals." What do I mean by these "ghost" sounds? To understand this, you have to understand a little bit about MP3 compression. MP3 compression basically throws away most of the information in your music. It replaces your original music with, essentially, instructions to your computer for creating something that sounds vaguely like your music. (This, by the way, is why I buy most my music in CD form instead of MP3 form).

It's sort of the like difference between the Mona Lisa and a paint-by-numbers copy of the Mona Lisa. You don't get back the original waveform, you get back a waveform that has most of the same frequency and timing information as the original. The details of the actual audio waveforms will not look the same when viewed up close. The stereo image of the reconstructed audio may be shifted slightly -- the balance of information between the left and right tracks no longer perfectly matches. And so, the center cancel doesn't work perfectly. The result sounds like this.

In that clip you can just barely hear a little sibilant trace of Coulton's vocal, and the quack. It's a little bit more audible if you apply some equalization: here's the same clip with the high frequencies isolated.

So they didn't use this full track, or at least I think they did not, because we don't hear those "ghost vocals" in the Glee mix.

But we do hear the quack. So that leaves only the karaoke version -- which has no lead vocal at all. They did the "center kill" technique to remove the quack (and with it the bass and some of the drums), leaving only the "ghost quack." Here's the same clip from the karaoke track. Here's the same clip with the center killed. Here's the center-killed clip with the same high-pass equalization.

Now, to compare. I realized that if this technique works to help isolate Coulton's accompaniment distinct from the lead vocal, why not try to isolate Glee's accompaniment too? Sauce for the 47% and all that, right?

Here's the same part of the song, Glee's version. You might be able to hear the remnant of the "quack" better if you listen to it reduced to mono -- it makes the mid/side distinction less distracting to the ear.

And now Glee's version, with the center killed. That version leaves a sort of "Glee backing track" in which you can hear Coulton's instruments more clearly. The Glee lead vocal is almost completely killed, but there are some odd sibilant leftovers due to MP3 compression. There's also a lot of processing with the auto-tune effect. Wow, do they use a lot of auto-tune, especially in the backing vocals at the end of the song. I guess it's cheaper than hiring people who can sing.

Anyway, so we have a Glee "backing track" now. What does that give us, besides a way to make fun of the backing vocals? It gives us a way to more clearly compare just the accompaniment. I'm not going to post the entire Coulton and Glee center-killed tracks here, because I think that would be pushing the fair use exception of copyright a little too far, but you can do this experiment yourself, and then compare them by any means you like. Here's a clip: in the left ear, Coulton's backing track. In the right ear, Glee's backing track. Funny, it sounds like the same track, just with some Glee vocals added on the right. Isn't that interesting? Those are Coulton's instruments: his banjo, his mandolin, his guitar, copied and pasted to repeat certain parts of the original and leave out others. You can even hear some of Coulton's original backing vocals, slightly buried under Glee singers, although some bits like, the part where he sang "little middle," have been edited out with more copying and pasting.

Anyway, that's today's crowd-sourced forensic audio analysis. The Coulton fans have discovered some other interesting facts. We've discovered that Glee added fake string squeaks to try to "sell" the video clip and make it look like the guy miming playing banjo was really playing the banjo part -- in the context of this blatant theft, that's almost sad. That was Caleb again -- he's got a great ear. We've discovered the ways in which Glee copied and pasted segments of the synthesized backing track to simplify Coulton's string parts and cut out some bits of the backing vocals on the karaoke track. At this point there's really no question as to whether Glee took Coulton's audio track; there's no question as to how. I am curious as to the exact details, but that's mainly to determine just how correct I was. Oh, and of course, there is still the small matter of whether they are going to get nailed for copyright infringement.

And finally -- you don't have to just take my word for it. Grab the tracks. Listen. If you have an audio-editing program like Pro Tools, Apple Logic, or even the free and open source Audacity, and a little patience and willingness to learn, you can hear what I'm hearing and judge for yourself!

Saturday, January 26, 2013

Bloodthirsty Vegetarians Episode #213

In this week's episode of the Bloodthirsty Vegetarians podcast, Rich and I talk about Lance Armstrong, The Big Bang Theory (is the show offensive to geeks?), and the controversy over Glee's production of Sir Mix-a-lot's song "Baby Got Back," with arrangement (and perhaps instrumental backing) by the uncredited Jonathan Coulton. Includes songs by Coulton and Marian Call!

Wednesday, January 23, 2013

About That Quack

UPDATE: the case that the producers of Glee appropriated Jonathan Coulton's recording has gained some further evidence. I have done some more recent work on this issue, and so have some other Coulton fans; you might want to take a look at my newer article here.

So, the Internetz are abuzz with the story that Glee, a tele-visual musical drama of some kind that I've never seen, um, appropriated Jonathan Coulton's arrangement and/or recording of the Sir Mix-a-lot easy-listening hit "Baby Got Back," an ode on the callipygian ideal.

We're still waiting to see if the song will actually air on the TV show tomorrow, but meanwhile there is a lot of commentary. The issues roughly break down like so.

First, why is this a big deal? Coulton recorded a cover, and paid the artist through the usual channels to release his cover, and presumably so did Glee.

Well, there are covers, and there are covers. The original song has no melody to speak of, and no chordal accompaniment to speak of; it's mainly a rap. Coulton created a sung melody for the song, and an elaborate backing for it, including banjo, mandolin, guitar, and sound effects. Coulton altered the original lyrics slightly (singing "Johnny C's in trouble" instead of "Mix-a-lot's in trouble," "take your pretty picture" instead of "take your picture," and a few other minor changes. Glee used Coulton's lyrics exactly.

OK, so maybe he has some kind of legal or moral entitlement to his altered lyrics -- they aren't big alterations, right? That isn't a big deal, is it?

Well, not only did they use his altered lyrics, but they sang his melody -- identical in every detail to the one he wrote, except they ended the song a verse earlier and didn't use his spoken bridge. Oh, and they used his arrangement. It is not entirely clear to me whether Coulton can claim legal copyright on his melody and arrangement, but morally -- it's his original work.

OK, well, so they just recorded a new "sound-alike" song and replicated his arrangement with some bored studio musicians, right?

Not so fast. Not only did Fox use his lyrics, melody, and arrangement, but they used his recording.

Coulton has released his song in several different forms. It was on the Thing-a-Week collection for download. It was on the Thing-a Week CDs. You can download it in Ogg format. You can download it in FLAC format. But they couldn't have used that as a backing track, right? It's got his lyrics on it?

Well, maybe. But it is actually often possible to do a studio trick that will cancel a lead vocal very effectively. Fox might have done that. They might have bought his full song in FLAC format at high quality, cancelled the main vocal, and layered new parts on top of that. Jon Schell demonstrated that this can be done with JoCo's full song here. He also showed that the Glee track probably involved cutting and pasting Coulton's original  handclaps in the intro. Actually that's a lot of proof, right there.

Coulton's also released his track in the form of a Karaoke track -- an MP3-only version that has all the instruments but no lead vocal. They might have used this track and also done that handclap fix to remove some extraneous backing vocals during the handclaps.

And, he's also released, at least in a limited way, his source tracks -- in the form of MP3 files of each aligned track that he mixed together to make the final song. He offered these as a special bonus for a a fundraiser for Creative Commons, if I recall correctly. Anyway, now, some musicians and home studio nerds like me have been trying to figure out just exactly what Fox appropriated.

I've been listening to the banjo, guitar, and mandolin parts against the Glee track and they align perfectly. Even some of his minor playing glitches are replicated. It's absolutely clear that they used Coulton's recording somehow. But there are some fades, and so I don't think they built it up from his source tracks. They might have done the vocal-removal trick on his finished song and mixed their vocal with that as a backing track, or they might have used the Karaoke track with all the instruments pre-mixed.

It's a little hard to prove it. What we have from Glee is a compressed audio file. Its been remastered and had new vocals mixed over it. As a musician I'm absolutely convinced they used Coulton's recorded material, because I can hear it in the mix, but as an audio engineer it's difficult to prove it really conclusively. If I had an un-mastered, uncompressed recording of their mix, it might be possible to do some things like "phase cancellation," where if Coulton's track is perfectly lined up and mixed with their track but inverted, it should cancel out his instruments. In fact I can get some cancellation, but when you remix, remaster, and compress a track, it changes it quite a bit and does a lot of damage to the stereo imaging, and so it won't cancel completely.

So here's a quacking gun.

Coulton noted that he thought he heard a "duck quack" in the Fox track. What's the duck quack? In his recording, Coulton bleeps the word "fuck" and replaces it with a sound effect of a duck quacking. It's not in his separated lead vocal source track; he just left silence there. Anyway, here it is in Coulton's Karaoke track. This is the waveform:


That quack is pretty loud. The big "pop" at the beginning there is probably a kick drum and a slightly off-the-beat bass string pluck.

Here it is in a spectrum view: you can see the "arc" of the quack sound effect in the midrange, almost like a spine that you might see in an ultrasound:


In the Fox track, they were starting with one of Coulton's tracks, and wanted to kill the duck sound, they might have used a tool like Izotope RX, or they might have applied some equalization to that spot in the mixed track. There's a problem, though -- in a mixed audio track with a lot of different instruments and vocals playing in different frequency ranges, you can't just surgically remove one thing, especially not when it exists in some of the same frequency ranges as the other sounds, without producing collateral damage. Tools like RX are very good, but if you take too much out the result will sound funny. They took out as much as they could and covered up the change with some high-pitched backing vocal "aaahs," but if you listen closely, you can still hear the "ghost" of the quack in the Glee song.

It's a little hard to hear. If you are listening to the mixed track on ordinary desktop computer speakers, it would be very hard to hear, buried in the mix. I have some good studio monitors and that helps. And this might help: here's a clip where I took Fox's version from the iTunes store and selected a few seconds around the "quack," with a narrow EQ band applied, created by selecting only a band of midrange frequencies in Izotope RX and exporting just that selection. The "ghost duck" sounds kind of like a French person saying "oui" in that flat, nasal way you sometimes hear it said, right where the f-bomb would go.

For these comparison images, I used a bit of audio captured from the Glee song from YouTube. The ghost of the quack is hard to see, but it reveals some other interesting features. Here's the YouTube capture showing roughly the same milliseconds of the Glee song, around the point where the "quack" was in Coulton's track:


It's been re-mastered and re-compressed, and that alters everything. This hides frequencies and rounds-off and approximates a lot of the details in the track. The effect is kind of like the way JPEG compression adds artifacts that appear unnaturally sharp, while losing some of the smooth gradations of the original. Despite these changes, you can see that the ghost quack is still there. Here is the spectrum view:


The horizontal line that appears mostly in the left channel is the new background vocal "ahhhhs." It's been distorted, but a narrow band of the "arc" of the quack is still there. Let's look a little closer, showing the waveform and spectrum together. Coulton, then Glee:



These are maybe a little hard to "read," in but basically, see if you can align features vertically between the two versions; left channel is on top and right channel is on the bottom in each of those screen shots. The features in the Glee capture show signs of additional lossy audio compression, which blurs and alters the details of the spectrum, but in my opinion these similar features indicate that Fox used Coulton's backing track and altered it to hide the quack. The spectrum views just confirm what the ear can hear.

Update: the next part of this argument I now consider incorrect and obsolete, since further investigation suggests that the producers of Glee did in fact replace the bass and drum parts.

Besides the quack, the very low end actually shows even more smoking-gun similarity. That's the bass, and kick drum. The energy from the kick drum and bass are represented by the very lowest edge of the spectrum display, and the pattern is energy in those frequencies is just too similar to be coincidence. This view is displaying under a second of audio -- more like a quarter second -- and so it would be extremely unlikely for re-recorded bass and percussion parts to "land" like this and leave the same "footprints" on the spectrum within that same quarter-second.

Let's take a look at that low end in more detail. Here's a color spectrum version that I set up to look more closely at frequencies below 4KHz, using Soundtrack Pro:



Click any of those to get a bigger version.

Would this hold up in court? I have no idea. Would Coulton or his representatives try to use the evidence of some random bearded geek on the internet? Probably not. But I think it's pretty convincing. Together with some investigation that other Coulton fans have done, ranging from putting the tracks side-by-side for comparison, to pointing out how the vocals could have been cancelled in the original, to noting other glitches in the editing, it's compelling. It's not a case of appropriating Coulton's lyrics, or his arrangement, or his melody -- they appropriated his recordings. And to date he's been given no compensation or credit of any kind.

If you want to try to replicate my results with your tools, you can find my short audio excerpts here. Coulton "Quack" Clip and Glee "Missing Quack" Clip.

Monday, January 21, 2013

How to Remember the Dwarves

OK, this is how we're memorizing the dwarf names at the Potts House. The dwarves can be organized into five groups of relatives: two groups of two, and three groups of three. Each pair is two brothers, and each trio is two brothers plus another brother, cousin, or uncle.

You can memorize the nickname for each group and rattle them off using the fingers of one hand. The groups are the ALINS, the ÓINS, the ILIS, the ORIS, and the URS. (They run almost like the list of vowels: A, O, I, O, U). Remember this list, and "two twos, three threes," and you're almost there.

The 2 ALINS ("ah-linz") are the brothers BALIN and DWALIN.

The 2 ÓINS ("oh-inz") are the brothers ÓIN and GLÓIN.

The 3 ILIS ("ee-leez") are the brothers FILI and KILI and their uncle THORIN.

The 3 ORIS ("or-eez") are the brothers ORI, NORI, and DORI.

The 3 URS ("urz") are the brothers BOFUR and BOMBUR and their cousin BIFUR.

Got that? Practice counting the five groups off on the fingers of one hand and reciting the members of each group a few times, and you'll be a true Tolkien nerd!

There are two naming rules that apply to most of the the thirteen dwarves.

First, the "brother name" rule: if the names differ only by opening (or missing) consonant sounds, they are brothers: Balin and Dwalin; Glóin and Óin; Fili and Kili; Dori, Nori, and Ori. Bombur's name breaks this rule. He is Bofur's brother. If his name followed the rule, it would have been something like Grofur or Ofur.

Second, the "cousin name" rule: if dwarves have the same last syllable but differ by a vowel sound before that syllable, they are cousins. So: brothers Balin and Dwalin are the cousins of brothers Glóin and Óin; Bifur is the cousin of Bofur.

I don't have an rule for Thorin. His name makes it sound like he could be related to Glóin and Óin, but he's not. You'll just have to remember that he goes with Fili and Kili.

Now for a few details to help you get their biographies and faces into your head. This will help you recognize them easily in the movies and know just a bit about their roles in the group.

THE ALINS

Balin has a big white ski-slope beard and winning smile. He's the second dwarf that shows up at Bilbo's hole. He will later (after the events of _The Hobbit_) lead an expedition to retake Moria from the orcs, and wind up in the tomb there, eventually discovered by Gimli.

Dwalin is the only dwarf with a bald head, and his scalp is covered with tattoos. He's the younger brother of Balin, and the first dwarf that shows up at Bilbo's hole.

THE ÓINS

Óin is an older dwarf, with coiled braids in his beard, a gray mustache, and knit gloves. He is somewhat deaf, and uses an ear trumpet. He will eventually be killed by the "Watcher in the Water" at the gate of Moria.

Glóin is the father of Gimli, and looks an older, red-haired version of Gimli. To remember which one is Gimli's father, keep in mind that Gimli and Glóin both start with G, and Glóin is the only dwarf in the group whose name starts with G. In the book, Glóin and Óin are responsible for kindling "glowing" fires.

Note: Balin and Dwalin are first cousins to Óin and Glóin. Their father, Fundin, is the brother of Gróin, the father of Óin and Glóin. We could have put the four of them into the same group, the INS, but it seemed easier to memorize the dwarves primarily as groups of brothers, with two exceptions, rather than mixing up the groups. If you prefer, think of the ALINS and the ÓINS as one big group and use the brother and cousin naming rules to keep track of their relationships.

THE ILIS

Fili has hair that is dirty blonde, and little beads in his braided mustache. Fili and Kili are the youngest of the group. These two brothers and Thorin all have smaller noses and more human-looking features than the other dwarves.

Kili has long, dark brown hair that is not braided. He has smoldering dark eyes and only a very minimal beard and mustache (perhaps he's just out of Dwarf puberty). Tolkien's own writings differ on whether Fili or Kili was youngest; Appendix A of _Lord of the Rings_ says Kili is youngest, and it looks like the film producers went with that interpretation.

Thorin Oakenshield is the party's leader, king in exile, and the uncle of Fili and Kili. He looks quite a bit like Kili, but his hair is just starting to go gray, and has a more regal bearing. In the movie he wears a big fur coat and uses an oak log as a shield.

THE ORIS

Ori is one dorky-looking dwarf. He has the bowl-cut bangs and an assortment of braids that make him look a bit like a Hasidic Jew, and a wispy mustache. He's the scribe of the group, and often seen writing. He will eventually write the last words in the Book of Mazarbul, in Balin's chamber in Moria, which say "We cannot get out. A shadow moves in the dark. We cannot get out. They are coming." Poor Ori!

Nori continues his brother Ori's Hasidic theme with a six-pointed, star of David-shaped hairdo, complete with metal beads everywhere, even on his braided eyebrows. He definitely wins the "most ridiculous dwarf hair" contest.

Dori is the oldest of these three brothers and has silver hair, bushy eyebrows, a long mustache and strikingly light-colored gray eyes. He also has lots of braids and beads, and metal ear cuffs.

THE URS

Bofur has the winged hat and an impressive Salvador Dali-style curled mustache to match. He's one of the friendlier dwarves. Like Balin, he's usually smiling, and he has a touching scene with Bilbo in the Misty Mountains, right before the party is captured by orcs.

Bombur is the "bomber" -- he's the biggest dwarf, with the red beard that forms a loop, and fingerless gloves. He breaks the furniture at Rivendell due to his weight. In Tolkien's books we learn that he will eventually require six younger dwarves to carry him.

Note: the two brothers in this group have names that are more similar (both start with "Bo"). Bombur's name breaks the brother name rule.

Bifur is the cousin of Bofur and Bombur. He the one with the bifur-cated head (sort of) -- he's got an orc's axe blade stuck in his forehead. He's also got a bi-color beard -- black and gray braided together. His black hair is unkempt, his uneven eyes make him look slightly crazy, and he only speaks Dwarvish. This probably has something to do with his little "accident."