Interactive audio spectrograms - new user

I am new to Julia and would like to visualize, annotate, and listen to audio clips, eventually in a Pluto notebook. Ideally, I would like to import a sound file and create a spectrogram with a play button to hear the clip. Then I would like to zoom in on an area of the spectrogram, have the piece fill the window, and be able to play that section.

There are javascript libraries that do most of this (e.g. which uses the Web Audio API. It’s been used with some annotation code for RShiny (GitHub - Athospd/wavesurfer: R interface to wavesurfer).

Most of the features needed (or close) seem to have been implemented in Julia, but they are scattered about.

  1. Has something like this been implemented as a simple package in Julia/Pluto already? There was a tutorial for creating a spectrogram that was nice, but the Julia code doesn’t work out of the box (it’s from 2014 and hasn’t been updated).

  2. If not, I would be willing to work on it and contribute; however, I don’t know what package this would fall under…there are a lot and I find it difficult to tell which are still active. Tutorials are not yet as plentiful as some other languages. Is there a central place to begin? A pool of mentors somewhere willing to guide new contributors?

  3. Is there an Julia audio tutorial? I have tried to make my way around the JuliaAudio collection. It’s not easy to navigate if you are not already familiar with the libraries.

I believe this tool would be valuable for audio analysis. R has a lot of these capabilities written in easy(ish) to use libraries, but I can’t just take R code and apply it to very large audio files (TB+). Julia would be pretty exciting to apply to research and teaching with the same code.

Thank you!

1 Like

It’s not exactly what you’re asking for, but I wrote this function some time ago to visualize many spectrograms and play the corresponding sound when one of them was clicked. It worked quite well, perhaps you could repurpose the code to do what you want

When it comes to audio in Julia, I guess it depends a bit on what you’d like to do.
DSP.jl for standard signal processing, including spectrograms.
SignalAnalysis.jl if you want some additional features as well as built in Visualization.
WAV.jl to read such files.

1 Like

Yes, I think I can start with this and build up. Thank you!

Yes, it does come down to what you want to do in audio. If you are new to Julia, this is a bit overwhelming if your goal is to get work done. Some walk-throughs for particular applications would be helpful (e.g. A really brief introduction to audio signal processing in Julia | seaandsailor) to figure out which packages are appropriate for which applications. I’m pretty sure the existing packages will do most of what I want…just need to sort them out :slight_smile:

Regarding the Pluto aspect there were a couple at PlutoCon which may help you

1 Like