dewdrop_world

Joined: Aug 28, 2006 Posts: 858 Location: Guangzhou, China
Audio files: 4
|
Posted: Sat Sep 23, 2006 2:31 pm Post subject:
Some audio snippets to play with |
 |
|
Hi all,
I've been confronting a compositional rut by doing some short, one-week composition challenges using material culled from a field recording at Dupont Circle in Washington DC. After a couple of weeks of research on comparing the spectra of short snippets for similarity, I'm ready to begin on the second installment and thought I would open it up to others, as before. (I was not on this board when I did the first... my short track is at http://www.dewdrop-world.net/audio/runway1.mp3).
The materials are located at http://www.dewdrop-world.net/audio/runway/challenge2.zip -- inside the archive there are two files:
denoise3-compacted.aiff -- A series of 328 fragments from the field recording, each 0.15 seconds exactly. Within each sample, 0.05-0.10s is the portion that was spectrally analyzed. I included 0.05 seconds on either side to help with enveloping.
challenge2.csv -- The analysis data, in the form of a matrix. Each row contains the comparison results for the corresponding file fragment. The metric is the result of the comparison: higher values mean the fragment sounds more different from the reference.
index, metric, peak amplitude triplets:
Row 0 (metric values are compared against sample 0): index0, metric0, peak0, index1, metric1, peak1
I'm using the following initialization code in SuperCollider. I'm sure the analysis data could be read into Max, PD, csound, maybe even some other packages. Or you can ignore the analysis data altogether.
s.boot;
~buf = Buffer.readAndQuery(s, "sounds/runway/denoise3-compacted.aiff");
// actual parts that were fft-compared; 0.05s before+after too
~pts = Array.series(328, 0.05, 0.15);
~matrix = CSVFileReader.read("~/SCServer/trax/project-runway/challenge2/challenge2.csv".standardizePath, false, false, _.asFloat);
~amps = ~matrix[0].clump(3).flop[2].reciprocal;
// Sort with more similar samples toward the beginning
~matrix = ~matrix.collect({ |row| row.clump(3).sort({ |a, b| a[1] <= b[1] }).flop });
Thus, if you choose a row from the matrix, row[0] gives you the index into the ~pts and ~amps arrays, row[1] gives the analysis values (which may or may not be compositionally useful outside of sorting), and row[2] is the peak amplitude of the segment that was fft-analyzed. ~amps[] is the reciprocal of each peak, which can be used as a scaling factor to normalize the sound levels.
The rules for this challenge are that the snippets are your only sound source. Playing portions of the source file longer than 0.15 seconds, or playing misaligned portions, will produce clicks or pops in the output -- which is a legitimate sound, sure, but if it isn't what you want, be aware that indexing into the audio file will require some care.
I plan to have my little track done by next Saturday, or maybe Sunday if I'm feeling lazy.
Any other takers?
(I do plan to release the code I used to produce the analysis. There's a bug in the live use version that I need to fix before I can do it. I'll work on that after I finish the piece.)
hjh _________________ ddw online: http://www.dewdrop-world.net
sc3 online: http://supercollider.sourceforge.net |
|