ADPAR1

From STX Wiki
Jump to navigationJump to search

ADPAR1

The spectral weighting (if AW=1) and the frequency range truncation (FMIN .. FMAX) is applied to all input spectra. The further processing of the spectra depends on the selected TYPE.

TYPE=0

The RMS energy (in dB) of the spectrum (band) is computed and stored in the output vector Y.

TYPE=1|2

The pre-processed spectra are converted to dB and copied to the output array SPG (1 row per spectrum).

TYPE=2

After collecting all input spectra, the following descriptors are computed.

Y[i,0] = rms - RMS energy of the spectrum (dB)

Y[i,1] = am - mean amplitude of the spectrum (dB)

Y[i,2] = ad - standard deviation of the spectrum (dB)

Y[i,3] = sl - spectral slope (dB / kHz)

Y[i,4] = acno - mean amplitude of the normalized spectrum (dB)

Y[i,5] = fcno - spectral centroid frequency (Hz)

Y[i,6] = spno - spectral spread

Y[i,7] = fx - spectral flux (1st order, correlation of spectrum i-1 and i)

Y[i,8] = skno - spectral skewness

Note: all descriptors with the subscript no are computed from the normalized spectrum. The spectra are normalized as follows:

offset = max(SPG[*,*]) - ARANGEif A[i,j]>offset, then Ano[i,j]=A[i,j]-offsetotherwise, Ano[i,j] = 0with: i = frameindex, j = frequency bin indexThis SPAtom was developed for the NOIDESc project in 2006.

Usage:

ADPAR1 TYPE N A AW AREF ARANGE DF FMIN FMAX

Parameters:
TYPE
The following types are supported:
0 = RMS track

1 = spectrogram 2 = descriptors

N
The number of frames (>1).
A
The linear amplitude spectrum.
AW
Apply amplitude weighting:
NONE|0 - no spectrum weighting
A|1 - spectrum weighting in dBA.
AREF
The reference amplitude (linear).
ARANGE
The amplitude normalization range for descriptors (TYPE=2) in dB.
DF
The FFT frequency resolution in Hz.
FMIN, FMAX
The analysis frequency range.
Outputs:
Y
If TYPE==0, the rms track (rms[0..N-1]).
If TYPE==1, the spectrogram array (one spectrum per row).
SPG
The logarithmic amplitude spectrogram.
If TYPE=0 - this is not initialized.
If TYPE=1|2 - N x nf (= the number of frequency bins in the selected range).

Navigation menu

Personal tools