audioflux.utils.power_to_db

audioflux.utils.power_to_db(X, min_db=-80)

Convert power spectrogram to relative decibel(dB) spectrogram.

Parameters
X: np.ndarray [shape=(…, fre, time)]

Input array

min_db: float

Minimum dB. Values smaller than min_db will be set to min_db

Returns
out: np.ndarray [shape=(…, fre, time)]

relative dB array