2
$\begingroup$

Given that the pitch harmonics of speech, are higher frequency features than the spectral envelope (of the pitch harmonics), I had an idea that computing the DCT of a spectrogram and discarding the higher frequency coefficients may achieve the result of retaining features of the envelope while discarding features of the harmonics. Is this reasonable? Why does no one give this interpretation? Does anyone attempt to reconstruct the spectrogram from the retained coefficients? Would the DCT or DFT be good at extracting the spectral envelope?

Here's some additional context, to properly frame the question:

https://haythamfayek.com/2016/04/21/speech-processing-for-machine-learning.html

It turns out that filter bank coefficients computed in the previous step are highly correlated, which could be problematic in some machine learning algorithms. Therefore, we can apply Discrete Cosine Transform (DCT) to decorrelate the filter bank coefficients and yield a compressed representation of the filter banks. Typically, for Automatic Speech Recognition (ASR), the resulting cepstral coefficients 2-13 are retained and the rest are discarded; num_ceps = 12. The reasons for discarding the other coefficients is that they represent fast changes in the filter bank coefficients and these fine details don’t contribute to Automatic Speech Recognition (ASR).

https://dsp.stackexchange.com/a/362/49786

You can think of the DCT as a compression step. Typically with MFCCs, you will take the DCT and then keep only the first few coefficients.

When you take the DCT and discard the higher coefficients, you are taking this spectral shape, and only keeping the parts that are more important for representing this smooth shape. If you used the Fourier transform, it wouldn't do such a good job of keeping the important information in the low coefficients.

$\endgroup$

1 Answer 1

1
$\begingroup$

Computing the DCT of anything and discarding the N highest ones should be like a crude lowpass filter. If that is what you want, why not just lowpass filter the magnitude spectrogram?

$\endgroup$
1
  • $\begingroup$ I didn't think of that (I'm not a dsp guy). I suppose a low pass filter would extract the spectral envelope $\endgroup$ Commented Aug 2, 2022 at 7:55

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.