gammatone
gammatone copied to clipboard
Example!!
I can have an example of Gamma tone gram generation written in Python?
It depends on what exactly you need. In the readme file it shows how you can do it from the command line with:
python -m gammatone FurElise.wav -d 10
All this does is call render_audio_from_file
. Does that answer your question?
Thank you! But in this case in the method "render_audio_from_file" the "function" parameter is just: -> function = gammatone.gtgram.gtgram ? Is there any parameter that escapes me?
-> function = gammatone.gtgram.gtgram ?
This parameter is the function used to create the gammatone spectrogram, it can be either:
-
gammatone.gtgram.gtgram
- the slower but more accurate method that uses a full gammatone filterbank -
gammatone.fftweight.fft_gtgram
- the faster method (but less precise) that uses weights applied to an FFT
The other parameters are the path
to the .wav
file and the time in seconds from the start you want to render until.