Lurker News
I worked on a web service that allows you to import a song and define a target length that the song will be shortened or lengthened to. It does this by analyzing the song and finding repeating audio patterns. This is helpful for making any song match a video or performance with a set duration. You can also specify areas of the song to prefer or avoid. An example is available here: https://mofi.loud.red/edit/8bd3fdf780f8c3927e41029f3b957f8a7...

The cool thing is that after the song is analyzed on the server, the client can recompute and preview the results completely client-side through an implementation that uses Web Workers and WebAssembly. The audio previewing uses Tone.js. I am thinking of writing up some more details about the implementation in the future.
I'm still working on a way to explain this easily, but I like the idea of carrying over the concept of content-aware fill from images to audio.
Please let me know if you have any comments or questions!

Comments (161) 65 threads

Earlier comments
wpietri1 reply#
My big question: what have you learned while working on this (very cool) project?
jaflo1 reply#
This project brought together a lot of different pieces of engineering and was a larger personal project for me, so there were a lot of parts and making those work together was a challenge at times.

For the backend, I found it helpful to implement monitoring proactively to be able to detect and debug issues without having to bug users which has been really helpful so far and allowed me to make some performance improvements too!
For the frontend it was interesting to optimize the result searching using the Web Worker + WebAssembly approach. I found some interesting ways to speed up things by parallelizing and, interestingly, manually collecting garbage in the WASM runtime.
And of course learning about the entire audio analysis portion and reading on how to find similar sections of audio!

RyanShook#
Thank you for making this tool. So impressive how many features work well in this initial version.
SillyUsername#
Please add the option for a longer fade out, plenty of songs finish too early and it would be great if they could just fade out rather than stop abruptly.
smokeydoe#
This works great with the clips made from MusicGen. The loops are seamless. Thank you for making it free. I would love to know more about how you are analyzing the audio.
KolmogorovComp1 reply#
Seems really nice, though for some reason after pasting a YouTube link it's stuck when reaching 100%, would have liked to give it a try.
jaflo1 reply#
Looks like the machine ran out of disk space, I bumped it and it should work. Could you try again?
KolmogorovComp#
Works well now, thanks! Overhaul quite impressive even though sometimes the cut is still noticeable.

Load more comments