Category Archives: Research & Development

Latency calculations for Zathras

Because Zathras-1 now has to interact with linearly interpolated timestretches, we had to calculate the latency of our timestretcher.

Multiple results were new to me and interesting to see.

  1. An sliding window fourier transform has a latency of 0. I did not expect that at all.
  2. When an input frame is stretched, then each sample of the inputframe will have  a different latency.
  3. The latencies of all samples, except the middle one, depend on the playback speed. Yes, you read that right: the playback speed affects the latency. And that is really something we do not want to compensate for. Therefore, use as reference the middle of the frame.
  4. It is possible to have negative latencies. Part of the signal is already out before we believe we provided it to the timestretcher.

http://werner.yellowcouch.org/Papers/zathras15/#toc23

Brainwaves note combinations

Below is a table showing which notes generate what brainwave oscilations. The idea is that each note is played in a separate channel.

Brainwave 1.9446332095341745 C1 and C#1
Brainwave 2.060267117566937 C#1 and D1
Brainwave 2.1827769755841757 D1 and D#1
Brainwave 2.3125716488486177 D#1 and E1
Brainwave 2.4500843150167455 E1 and F1
Brainwave 2.5957739098288073 F1 and F#1
Brainwave 2.7501266587643656 F#1 and G1
Brainwave 2.9136576997744896 G1 and G#1
Brainwave 3.086912802506866 G#1 and A1
Brainwave 3.2704701897611983 A1 and A#1
Brainwave 3.464942467254282 A#1 and B1
Brainwave 3.670978668134147 B1 and C2
Brainwave 3.8892664190683774 C2 and C#2
Brainwave 4.004900327101112 C1 and D1
Brainwave 4.1205342351338885 C#2 and D2
Brainwave 4.243044093151113 C#1 and D#1
Brainwave 4.365553951168337 D2 and D#2
Brainwave 4.495348624432793 D1 and E1
Brainwave 4.625143297697278 D#2 and E2
Brainwave 4.762655963865363 D#1 and F1
Brainwave 4.90016863003342 E2 and F2
Brainwave 5.045858224845553 E1 and F#1
Brainwave 5.191547819657643 F2 and F#2
Brainwave 5.345900568593173 F1 and G1
Brainwave 5.500253317528745 F#2 and G2
Brainwave 5.663784358538855 F#1 and G#1
Brainwave 5.827315399548979 G2 and G#2
Brainwave 6.000570502281356 G1 and A1
Brainwave 6.173825605013732 G#2 and A2
Brainwave 6.187677302685287 C1 and D#1
Brainwave 6.3573829922680645 G#1 and A#1
Brainwave 6.540940379522397 A2 and A#2
Brainwave 6.5556157419997305 C#1 and E1
Brainwave 6.73541265701548 A1 and B1
Brainwave 6.929884934508564 A#2 and B2
Brainwave 6.945432939449539 D1 and F1
Brainwave 7.135921135388429 A#1 and C2
Brainwave 7.341957336268308 B2 and C3
Brainwave 7.3584298736941705 D#1 and F#1
Brainwave 7.560245087202524 B1 and C#2
Brainwave 7.778532838136755 C3 and C#3
Brainwave 7.795984883609918 E1 and G1
Brainwave 8.009800654202266 C2 and D2
Brainwave 8.241068470267749 C#3 and D3
Brainwave 8.259558268367662 F1 and G#1
Brainwave 8.486088186302226 C#2 and D#2
Brainwave 8.500248951533905 C1 and E1
Brainwave 8.731107902336703 D3 and D#3
Brainwave 8.750697161045721 F#1 and A1
Brainwave 8.990697248865615 D2 and E2
Brainwave 9.005700057016476 C#1 and F1
Brainwave 9.250286595394527 D#3 and E3
Brainwave 9.271040692042554 G1 and A#1
Brainwave 9.525311927730698 D#2 and F2
Brainwave 9.541206849278346 D1 and F#1
Brainwave 9.800337260066868 E3 and F3
Brainwave 9.822325459522347 G#1 and B1
Brainwave 10.091716449691063 E2 and F#2
Brainwave 10.108556532458536 D#1 and G1
Brainwave 10.383095639315286 F3 and F#3
Brainwave 10.406391325149627 A1 and C2
Brainwave 10.691801137186388 F2 and G2
Brainwave 10.709642583384408 E1 and G#1
Brainwave 10.95033326655065 C1 and F1
Brainwave 11.000506635057462 F#3 and G3
Brainwave 11.025187554456807 A#1 and C#2
Brainwave 11.327568717077725 F#2 and G#2
Brainwave 11.346471070874529 F1 and A1
Brainwave 11.601473966845283 C#1 and F#1
Brainwave 11.654630799097788 G3 and G#3
Brainwave 11.680779322336413 B1 and D2
Brainwave 12.001141004562712 G2 and A2
Brainwave 12.02116735080692 F#1 and A#1
Brainwave 12.291333508042712 D1 and G1
Brainwave 12.347651210027436 G#3 and A3
Brainwave 12.375354605370603 C2 and D#2
Brainwave 12.714765984536129 G#2 and A#2
Brainwave 12.735983159296836 G1 and B1
Brainwave 13.022214232233026 D#1 and G#1
Brainwave 13.081880759044992 A3 and A#3
Brainwave 13.111231483999504 C#2 and E2
Brainwave 13.47082531403096 A2 and B2
Brainwave 13.493304127656494 G#1 and C2
Brainwave 13.546107176379458 C1 and F#1
Brainwave 13.796555385891274 E1 and A1
Brainwave 13.859769869017128 A#3 and B3
Brainwave 13.890865878899035 D2 and F2

Timestretcher

timestretchsegmentsThe timestretcher I’ve been working on is going ahead quite well. I’m currently working on timestretcher parameter changes. When changing the tempo, the segments should still align correctly. In the image  each color is a new synthesized segment. As can be seen, they overlap nicely.  A wave from one segment is picked up by the next, and so on.

 

Speed requirements timestretcher

I’m currently optimizing my timestretcher. Just to give an idea of the speed we need to achieve: with a windowsize of 4096 samples and an overlap of 16 frames. We have about 5.8 milliseconds between frame calculations. Now, this is stereo which means that we only have 2.9 milliseconds/frame. In each frame we have to detect sine waves, extract them relocate them to other positions. Typically we have around ~600 peaks per frame. That leaves us about 4.8 microseconds per peak. Each peak must be detected, extracted, repositioned, resampled and added to the final frame again. Currently I manage to do this in 13 microseconds. And now the push is on. Can we speed this further up with a factor 2.7 ?

BpmDj at Chaos Communication Camp 2015

This year we will again be at the Chaos Communication Camp 2015 (which takes place around Berlin)

At CCC 2011, we gave a talk on how BpmDj performs its audio analysis. Two years later, at OHM 2013, we explained how the nearest neighbor detection and associated weight matrix is created. This year, we won’t talk about the project anymore, but instead give you the opportunity to meet the developers.

Actually, we want you to come to us with ~100 tracks and an idea for a mix. We will then sit together and create that mix. As a reward you will receive one of our heat sensitive ‘stay-tuned-stay-sharp-keep-mixing’ cups.

11782341_10205654209527497_5904057869868228386_o

Updated version of the audiosplitter

The old VCC/2 line, which I originally made with a second opamp has been replaced with a 100K resistor pair. Not the best solution because now it hums even louder. The grounds and the opamp bias have been properly decoupled this time (still hum). Some of the capacitor values have been lower in cutoff frequency (still hum). I tried placing a resistor over the input to remove the hum. That works if the resistor is ~680 Ohm. Yet in that case, if there is an input signal, it is barely amplified (no hum, no signal). Putting the entire thing in a metal box did not do a thing. So no pickup of magenetic fields (still hum). Replacing the powersupply with a batterypack resulted in >huray< no hum ! So it is most certainly a power supply problem. Hum removal is a non trivial problem. Grmpf.

11802511_10205599263433879_911238989618258279_o