From: Siarhei Siamashka <siarhei.siamashka@nokia.com>
To: "ext Marcel Holtmann" <marcel@holtmann.org>
Cc: hoene@uni-tuebingen.de, "'ext Brad Midgley'" <bmidgley@gmail.com>,
"'Jaska Uimonen'" <jaska.uimonen@nokia.com>,
linux-bluetooth@vger.kernel.org
Subject: Re: Testing SBC filtering functions
Date: Mon, 29 Dec 2008 17:04:03 +0200 [thread overview]
Message-ID: <200812291704.03444.siarhei.siamashka@nokia.com> (raw)
In-Reply-To: <200812291636.16207.siarhei.siamashka@nokia.com>
[-- Attachment #1: Type: text/plain, Size: 5248 bytes --]
On Monday 29 December 2008 16:36:15 ext Siarhei Siamashka wrote:
> On Monday 29 December 2008 14:04:29 ext Marcel Holtmann wrote:
> > Hi Siarhei,
> >
> > > > I wrote this script to make some tests on the SBC decoder and encoder using
> > > > the recommended testing procedure with the reference bitstreams, the
> > > > reference codec and PEAQ.
> > > > http://net.cs.uni-tuebingen.de/html/nexgenvoip/html/
> > > > I got little bit confused with all the latest patches and whether they are
> > > > included or not. Just send me an email on which patch you like to have
> > > > tested. Running the tests just takes half an hour; me to answer my emails
> > > > maybe a bit longer.
> > >
> > > Please try the following patch (apply it to the latest git):
> > > http://marc.info/?l=linux-bluetooth&m=123054787830678&w=2
> > >
> > > You can try the patch "as is", and also with SBC_HIGH_PRECISION define
> > > uncommented. High precision mode is naturally more likely to pass the
> > > conformance tests.
> > >
> > > I used my own script for testing with 'tiny_psnr' tool for comparing original file
> > > before encoding and the final decoded result (it measures standard deviation
> > > and PSNR). It would be interesting to see how our results correlate.
> >
> > can you open source tiny_psnr an we merge it into the BlueZ source?
>
> It is already open source. This very simple tool is used in ffmpeg project
> regression tests (and is part of ffmpeg distribution). It does not do
> anything extraordinary, but just analyzes the difference between several
> audio files and gets standard deviation and PSNR statistics. I just did not
> feel like reinventing the wheel and used it for estimating quality :)
>
> I only use the following patch on top of it (it can do automatic shift detection):
> http://article.gmane.org/gmane.comp.video.ffmpeg.devel/74597
> I find this patch quite useful (especially as it turns out for SBC), but ffmpeg
> developers do not think so...
>
> A crude ruby script (sorry, I don't speak shell scripting language) is attached.
> I have been using it for testing audio quality.
>
> For example, here is the test of a high precision sbcenc build (bitpool=255):
>
> ./sbc_encode_test.rb BigBuckBunny-stereo.flac
> [2, 48000]
> ["-j -S -s8 -B16 -b255", "-j -l16 -n8 -r1569000"]
> --- comparing original / sbcenc + sbcdec ---
> stddev: 108.67 PSNR: 55.60 bytes:114519261/114520000
>
> --- comparing original / sbcenc + sbc_decoder.exe ---
> stddev: 1.09 PSNR: 95.56 bytes:114519260/114520000
>
> --- comparing original / sbc_encoder.exe + sbc_decoder.exe ---
> stddev: 1.09 PSNR: 95.56 bytes:114519260/114520000
>
> --- comparing sbcenc + sbc_decoder.exe / sbc_encoder.exe + sbc_decoder.exe
> stddev: 0.01 PSNR:130.99 bytes:114519552/114519552
>
> Test of a standard sbcenc build (bitpool=255):
>
> ./sbc_encode_test.rb BigBuckBunny-stereo.flac
> [2, 48000]
> ["-j -S -s8 -B16 -b255", "-j -l16 -n8 -r1569000"]
> --- comparing original / sbcenc + sbcdec ---
> stddev: 108.71 PSNR: 55.59 bytes:114519261/114520000
>
> --- comparing original / sbcenc + sbc_decoder.exe ---
> stddev: 2.07 PSNR: 89.98 bytes:114519260/114520000
>
> --- comparing original / sbc_encoder.exe + sbc_decoder.exe ---
> stddev: 1.09 PSNR: 95.56 bytes:114519260/114520000
>
> --- comparing sbcenc + sbc_decoder.exe / sbc_encoder.exe + sbc_decoder.exe
> stddev: 1.77 PSNR: 91.34 bytes:114519552/114519552
[...]
> By the way, 'sbcdec' seems to introduce quite a noticeable distortion and
> is orders of magnitude less precise than the encoder.
Please disregard this statement. I only tried to add support for sbcdec as the
last minute change (I did not pay any attention to the decoder audio quality
before today) and forgot to change its output to a normal WAV format
before comparing files. Sorry about that. A fixed script is attached and
updated results are below.
Test of a high precision sbcenc build (bitpool=255):
./sbc_encode_test.rb BigBuckBunny-stereo.flac
[2, 48000]
["-j -S -s8 -B16 -b255", "-j -l16 -n8 -r1569000"]
--- comparing original / sbcenc + sbcdec ---
stddev: 4.49 PSNR: 83.26 bytes:114519260/114520000
--- comparing original / sbcenc + sbc_decoder.exe ---
stddev: 1.09 PSNR: 95.56 bytes:114519260/114520000
--- comparing original / sbc_encoder.exe + sbc_decoder.exe ---
stddev: 1.09 PSNR: 95.56 bytes:114519260/114520000
--- comparing sbcenc + sbc_decoder.exe / sbc_encoder.exe + sbc_decoder.exe
stddev: 0.01 PSNR:130.99 bytes:114519552/114519552
Test of a standard sbcenc build (bitpool=255):
./sbc_encode_test.rb BigBuckBunny-stereo.flac
[2, 48000]
["-j -S -s8 -B16 -b255", "-j -l16 -n8 -r1569000"]
--- comparing original / sbcenc + sbcdec ---
stddev: 4.85 PSNR: 82.60 bytes:114519260/114520000
--- comparing original / sbcenc + sbc_decoder.exe ---
stddev: 2.07 PSNR: 89.98 bytes:114519260/114520000
--- comparing original / sbc_encoder.exe + sbc_decoder.exe ---
stddev: 1.09 PSNR: 95.56 bytes:114519260/114520000
--- comparing sbcenc + sbc_decoder.exe / sbc_encoder.exe + sbc_decoder.exe
stddev: 1.77 PSNR: 91.34 bytes:114519552/114519552
Still the sbcdec seems to be the major contributor to quality loss in all cases.
Best regards,
Siarhei Siamashka
[-- Attachment #2: sbc_encode_test.rb --]
[-- Type: application/x-ruby, Size: 2811 bytes --]
next prev parent reply other threads:[~2008-12-29 15:04 UTC|newest]
Thread overview: 35+ messages / expand[flat|nested] mbox.gz Atom feed top
2008-11-28 13:35 [RFC/PATCH] sbc: new filtering function for 8 band fixed point encoding Jaska Uimonen
2008-11-28 14:18 ` Marcel Holtmann
2008-11-28 14:24 ` Jelle de Jong
2008-11-28 15:20 ` Jaska Uimonen
2008-11-28 18:13 ` David Sainty
2008-11-28 15:14 ` Jaska Uimonen
2008-12-02 20:15 ` Jim Carter
2008-12-12 17:14 ` Siarhei Siamashka
2008-12-12 19:19 ` Brad Midgley
2008-12-15 12:54 ` Siarhei Siamashka
2008-12-15 15:16 ` Brad Midgley
2008-12-16 22:37 ` Siarhei Siamashka
2008-12-17 8:16 ` Jaska Uimonen
2008-12-19 22:12 ` Siarhei Siamashka
2008-12-22 23:30 ` Siarhei Siamashka
2008-12-23 1:00 ` Marcel Holtmann
2008-12-23 8:20 ` Jaska.Uimonen
2008-12-23 11:14 ` Siarhei Siamashka
2008-12-23 10:45 ` Siarhei Siamashka
2008-12-23 11:48 ` Marcel Holtmann
2008-12-29 9:16 ` Testing SBC filtering functions Christian Hoene
2008-12-29 10:00 ` Marcel Holtmann
2008-12-29 10:55 ` Christian Hoene
2008-12-29 12:03 ` Marcel Holtmann
2008-12-29 12:31 ` Christian Hoene
2008-12-29 12:41 ` Marcel Holtmann
2008-12-29 13:11 ` Christian Hoene
2008-12-29 13:17 ` Marcel Holtmann
2009-01-01 14:29 ` Testing SBC encoder correctness with sbctester works Christian Hoene
2008-12-29 11:06 ` Testing SBC filtering functions Siarhei Siamashka
2008-12-29 12:04 ` Marcel Holtmann
2008-12-29 14:36 ` Siarhei Siamashka
2008-12-29 15:04 ` Siarhei Siamashka [this message]
2008-12-29 10:46 ` [RFC/PATCH] sbc: new filtering function for 8 band fixed point encoding Siarhei Siamashka
2008-12-29 11:56 ` Marcel Holtmann
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=200812291704.03444.siarhei.siamashka@nokia.com \
--to=siarhei.siamashka@nokia.com \
--cc=bmidgley@gmail.com \
--cc=hoene@uni-tuebingen.de \
--cc=jaska.uimonen@nokia.com \
--cc=linux-bluetooth@vger.kernel.org \
--cc=marcel@holtmann.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox