(ps, norm=1)
return lps
Compute the log power spectorgram features from powerspec.

    :param ps: power spectrum
    :param norm: If norm=1, the log power spectrum is normalised so that the max value (across all frames) is 0.
    :returns: If frames is an NxD matrix, output will be Nx(NFFT/2+1). Each row will be the log power spectrum of the corresponding frame.
Compute the log power spectorgram features from powerspec.
Compute the log power spectorgram features from powerspec .
def logpowerspec(ps, norm=1):
  """Compute the log power spectorgram features from powerspec.

    :param ps: power spectrum
    :param norm: If norm=1, the log power spectrum is normalised so that the max value (across all frames) is 0.
    :returns: If frames is an NxD matrix, output will be Nx(NFFT/2+1). Each row will be the log power spectrum of the corresponding frame.
    """
  ps[ps <= 1e-30] = 1e-30
  lps = 10 * numpy.log10(ps)
  if norm:
    return lps - numpy.max(lps)
  return lps
def logpowerspec ( ps , norm = 1 ) : ps [ ps <= 1e-30 ] = 1e-30 lps = 10 * numpy . log10 ( ps ) if norm : return lps - numpy . max ( lps ) return lps