Click4Ai

534.

Medium

MFCC (Mel-Frequency Cepstral Coefficients) are a widely used feature extraction technique in speech recognition systems. They are used to represent the acoustic characteristics of speech signals. In this problem, you will implement an MFCC extraction function using NumPy.

**Example:** Extract MFCC features from a sample audio signal.

**Constraints:** Use the Mel scale to calculate the frequency bins, and apply a Hamming window to the signal before taking the FFT.

**Note:** You can use the librosa library to load the audio signal, but you should implement the MFCC extraction function from scratch.

Test Cases

Test Case 1
Input: [[1, 2, 3], [4, 5, 6]]
Expected: [[1.0, 2.0, 3.0], [4.0, 5.0, 6.0]]
Test Case 2
Input: [[7, 8, 9], [10, 11, 12]]
Expected: [[7.0, 8.0, 9.0], [10.0, 11.0, 12.0]]
+ 3 hidden test cases