jameslyons/python_speech_features — pull request #7 by adamstark (2014-11-17 16:49:50+00:00)
Title: Added small constants to feat and energy before log is taken to avoid divide by zero

Hi,

I found that any magnitude spectrum frame I had that contained zeros was producing divide by zero warnings when numpy.log() was applied in the mfcc() calculation. This was resulting in NaNs in the mfcc outputs.

To avoid this, I have replaced any zeros with very tiny positive constants to avoid divide by zeros. Does that seem like a good solution?