Caution

You're reading an old version of this documentation. If you want up-to-date information, please have a look at 0.10.2.

librosa.filters.constant_q_lengths

librosa.filters.constant_q_lengths(sr, fmin, n_bins=84, bins_per_octave=12, window='hann', filter_scale=1, gamma=0)[source]

Return length of each filter in a constant-Q basis.

Parameters:
srnumber > 0 [scalar]

Audio sampling rate

fminfloat > 0 [scalar]

Minimum frequency bin.

n_binsint > 0 [scalar]

Number of frequencies. Defaults to 7 octaves (84 bins).

bins_per_octaveint > 0 [scalar]

Number of bins per octave

windowstr or callable

Window function to use on filters

filter_scalefloat > 0 [scalar]

Resolution of filter windows. Larger values use longer windows.

Returns:
lengthsnp.ndarray

The length of each filter.

Notes

This function caches at level 10.