We can apply many techniques to analyze audio, and, therefore, we can debate at length about which techniques are most appropriate. The most obvious method is purportedly the FFT. As a variation, we can use the short-time Fourier transform (STFT). The STFT splits the signal in the time domain into equal parts, and it then applies the FFT to each segment. Another algorithm we will use is the cepstrum, which was originally used to analyze earthquakes but was later successfully applied to speech analysis. The power cepstrum is given by the following equation:
The algorithm is as follows:
Calculate the Fourier transform.
Compute the squared magnitude of the transform.
Take the logarithm of the previous result.
Apply the inverse Fourier transform.
Calculate the squared magnitude again.
The cepstrum is, in general, useful when we have large changes in the frequency domain. An important use case of the cepstrum is to form feature vectors for audio classification...