You're reading an old version of this documentation. If you want up-to-date information, please have a look at 0.10.0.
Get the sampling rate for a given file.
- pathstring, int, or file-like
The path to the file to be loaded As in
load, this can also be an integer or open file-handle that can be processed by
- srnumber > 0
The sampling rate of the given audio file
Get the sampling rate for the included audio file
>>> path = librosa.ex('trumpet') >>> librosa.get_samplerate(path) 22050