Skip to content

Commit

Permalink
merged nt.utils.NoiseGenerator with nt.speech_enhancement.noise chang…
Browse files Browse the repository at this point in the history
…ed nt.evaluate.input_sxr to use power instead of var like in nt.speech_enhancement.noise
  • Loading branch information
boeddeker committed Aug 16, 2019
1 parent c3c1d60 commit 6d6b412
Showing 1 changed file with 4 additions and 0 deletions.
Original file line number Diff line number Diff line change
@@ -1,6 +1,10 @@
import numpy


def get_power(x, axis=None):
return numpy.sum(numpy.abs(x * x.conj()), axis=axis)


def get_snr(X, N):
"""
Return SNR of time signals or STFT signals in dB.
Expand Down

0 comments on commit 6d6b412

Please sign in to comment.