[SciPy-User] Signal to noise ratio

Ivo Maljevic ivo.maljevic@gmail....
Wed Feb 24 09:35:23 CST 2010


Josef,
Maybe the definition you use is for some specific field I'm not familiar
with. AFIK, SNR is defined as the ratio of powers and not amplitudes, but my
background is in electrical engineering / communiation theory.

Please take a look at the following links - but this is just a couple of
links from the sea of ones you can find on the web:

http://www.scholarpedia.org/article/Signal-to-noise_ratio

where it says: Thus, the SNR equals [image: \mathsf{E}[S^2]/\sigma^2_N].

http://authors.library.caltech.edu/3763/1/CUIieeecl06a.pdf  (formula 16)

Ivo







On 24 February 2010 10:23, <josef.pktd@gmail.com> wrote:

> On Wed, Feb 24, 2010 at 10:16 AM, Ivo Maljevic <ivo.maljevic@gmail.com>
> wrote:
> > One would think that you can always rely on wikipedia when it comes to
> math
> > and engineering, but it seems that is not tha case.
> > Josef, In the page you referenced, the SNR, or signal to noise ratio, is
> > defined as the ratio between the signal and noise powers. Consequently,
> in
> > terms of signals and standard deviations, it is defined as a ratio of the
> > average signal power and the noise variance (NOT its squre root, or
> standard
> > deviation). Or:
> >
> > SNR = P_s / sigma^2
> >
> > where P_s is the average signal power, and the noise variance is used to
> > measure the noise power. The assumption here is that the noise is a zero
> > mean process, otherwise variance and power wouldn't be the same thing.
>
> Note: I linked to #Statistical_definition not the top of the wikipedia page
> and I checked the source in scipy.stats:
>    Calculates the signal-to-noise ratio, defined as the ratio between the
> mean
>    and the standard deviation.
>
>    m = np.mean(a, axis)
>    sd = samplestd(a, axis)
>    return np.where(sd == 0, 0, m/sd)
>
> I didn't know about the different definitions until I read the
> Wikipedia page, but that's what's currently in scipy.stats
>
> Josef
>
> >
> > Nils, your question is way too generic for anyone to help you directly. I
> > can only point to you that your signal to noise ratio is quite low:
> >
> >>>> 10*math.log10(0.0447)
> > -13.496924768680636
> >
> > Maybe your signal is to narrow compared to the overal band you are
> working
> > with (or you have DS spread spectrum signal?).
> > Anyway, you will need to figure out which filter you want to use (e.g.,
> > butterworth for maximally flat characteristic in the passband, etc).
> >
> >
> > On 24 February 2010 09:33, <josef.pktd@gmail.com> wrote:
> >>
> >> On Wed, Feb 24, 2010 at 8:12 AM, Nils Wagner
> >> <nwagner@iam.uni-stuttgart.de> wrote:
> >> > Hi all,
> >> >
> >> > I have two questions concerning signal processing
> >> >
> >> > I have used scipy.stats.signaltonoise to compute the
> >> > signal-to-noise ratio.
> >> > The value is 0.0447.
> >> > How can I judge it ?
> >>
> >> It's just mean over standard deviation
> >>
> http://en.wikipedia.org/wiki/Signal-to-noise_ratio#Statistical_definition
> >>
> >> I never use it, but the interpretation will depend on what your
> >> level/mean/expected_value means.
> >>
> >> >
> >> > How can I filter out high frequencies using scipy ?
> >> > How can I eliminate noise from the signal ?
> >>
> >> (I'm no help here) There are many prefabricated filters in
> >> scipy.signal, but I only use lfilter.
> >>
> >> Josef
> >>
> >> >
> >> > Nils
> >> > _______________________________________________
> >> > SciPy-User mailing list
> >> > SciPy-User@scipy.org
> >> > http://mail.scipy.org/mailman/listinfo/scipy-user
> >> >
> >> _______________________________________________
> >> SciPy-User mailing list
> >> SciPy-User@scipy.org
> >> http://mail.scipy.org/mailman/listinfo/scipy-user
> >
> >
> > _______________________________________________
> > SciPy-User mailing list
> > SciPy-User@scipy.org
> > http://mail.scipy.org/mailman/listinfo/scipy-user
> >
> >
> _______________________________________________
> SciPy-User mailing list
> SciPy-User@scipy.org
> http://mail.scipy.org/mailman/listinfo/scipy-user
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://mail.scipy.org/pipermail/scipy-user/attachments/20100224/0ca44170/attachment.html 


More information about the SciPy-User mailing list