Answer the question
In order to leave comments, you need to log in
Why are the MFCC coefficients different for the same window?
Please explain why the code produces the following results.
There is a wav file with a frequency of 48000 Hz, I extract Mel-frequency cepstral coefficients from it, a window and an offset of 240 samples (from the logic of 50ms * 48000).
def mel(wav_file):
samples, sample_rate = librosa.load(wav_file, sr=None)
mfccs = librosa.feature.mfcc(samples, sample_rate, hop_length=int(0.005 * sample_rate), n_fft=int(240))
mfccs1 = librosa.feature.mfcc(samples[0:240], sample_rate, hop_length=int(0.005 * sample_rate), n_fft=int(240))
print(mfccs[0][0], mfccs[1][0], mfccs[2][0], mfccs[3][0])
print(mfccs1[0][0], mfccs1[1][0], mfccs1[2][0], mfccs1[3][0])
-814.967 19.22025 13.9679365 8.873832
-984.62683 -13.866039 1.2349255 15.176905
Answer the question
In order to leave comments, you need to log in
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question