# Software for calculating long-duration false-colour spectrogram?

I'd like to calculate a set of false colour spectrograms, from long-duration audio -- i.e. the type of visualisation introduced by Michael Towsey's research group at QUT, like this:

The QUT Ecoacoustics group have open-sourced their own analysis code which is the "official" implementation. It runs on Windows/Mac/Linux. (But it's implemented using Windows tools (Mono and Powershell) so on my Linux laptop I'd have to install a lot of extra kit to get it running.)

I wrote (together with Sarab Sethi) a Python script to calculate them. (It produced the lower image shown above.) It has the advantage of being a simple standalone Python script, but it's not perfect -- it doesn't implement all the same acoustic indices as the QUT original.

Hence my question: Has this type of long-duration spectrogram been implemented in any other software or scripts?

• Purpose of these plots? research/discovery or presentation? IMHO, too many colours are hard to digest as customer, but can be instructive for the person that generated them
– WMXZ
Oct 14, 2022 at 15:54
• @WMXZ The purpose, for me at least, is visual data mining. There's a nice example published by Znidersic et al about using them to discover cryptic species in long audio recordings. Towsey et al have published quite a lot showing that they're useful. You do need to be experienced with them to "read" them well. Oct 15, 2022 at 11:29
• @DanStowell is it a spectrogram that you are after, showing time vs frequency, or a false colour plot e.g. time vs date, with three acoustic indices represented on the RGB channels? Obvs the latter is much easier to code. Oct 19, 2022 at 8:55
• @CarlosAbrahams false-colour spectrogram. BUT as you see in the images I showed, these are still time versus frequency. The acoustic indices are measured separately for each frequency bin, so each pixel represents something like 1 minute for 1 frequency bin. I think I know the other version that you're thinking of, which is even more zoomed-out where 1 pixel is 1 entire day - that's not what I'm looking for. Oct 19, 2022 at 12:42

scikit-maad seems to have the ability to extract acoustic indices, in a format that can then be plotted like this. See the code example on this page, with a false-colour spectrogram plotted at the bottom of the page.

scikit-maad is a Python software package.

@DanStowell - Thanks, thought that might be the issue. Just picking up from our comments, I've only generated false-colour images for acoustic indices across the whole bandwidth, not for frequency bins - resulting in plots as below, which don't show any frequency spectral data

For anyone interested in this type of plot, R code would be something like:

# Rescale acoustic indices to 0-1 for RGB colours
ai_data <- ai_data %>%
mutate(
ACInorm = rescale(ACI),
BInorm = rescale(BI),
fill = rgb(red = ai_data$$ACInorm)), green = ai_data$$BInorm)),