Skip to content

Instantly share code, notes, and snippets.

@tinpark
tinpark / makeSpectrogram.sh
Last active July 10, 2018 13:53 — forked from hrywlms/generate sox spectrograms.sh
A quick way to generate spectrograms for a bunch of audio files
### Generate PNG spectrograms using SoX
### Use the input file name as the title within the image as well as the output file name
### Set the width to 2000 (seems to output a ~2140px wide image)
### Generate for five arguments,
### arg 1 = file type to make spectrograms from, e.g. .wav,
### arg 2 = width of the spectrogram
### arg 3 = hight of the spectrogram
### arg 4 = the dB level of sounds to pick out, ignoring sounds below that threshold
### arg 5 = the frequencies to hone in on e.g. 4k will give you a spectrogram that draws sounds up to 2k