plot_onset_strength

plot_onset_strength(y: npt.ArrayLike, sr:int, standard: bool = True, custom_mel: bool = False, cqt: bool = False)

circle-info

Function description

To plot the onset strength of the input signal with time-axis

circle-info

Parameter

y: input signal

sr: sampling rate (22050 Hz by default)

standard: using STFT to calculate

custom_mel: using Mel-scale to calculate

cqt: using CQT to calculate

circle-info

Return

None

circle-info

Example

from audioviz import *
import librosa
import numpy as np
from audioviz import BeatAnalysis

y, sr = librosa.load('Mozart_Turkish_March.wav', duration = 45)
BeatAnalysis.plot_onset_strength(y = y, sr = sr, standard = True, custom_mel = True, cqt = True)

Last updated