IPB

Welcome Guest ( Log In | Register )

4 Pages V   1 2 3 > »   
Reply to this topicStart new topic
lossyWAV 1.3.0 released, Added noise WAV bitdepth reduction method.
Nick.C
post Aug 6 2011, 21:50
Post #1


lossyWAV Developer


Group: Developer
Posts: 1772
Joined: 11-April 07
From: Wherever here is
Member No.: 42400



lossyWAV 1.3.0 is released.

lossyWAV is a near lossless audio processor which dynamically reduces the bitdepth of the signal on a block-by-block basis. Bitdepth reduction adds noise to the processed output. The added noise is adaptively shaped by default and can alternatively be fixed noise shaped or white noise depending on command line parameters. When lossyWAV processed output is compressed with certain lossless codecs (FLAC, Wavpack, Tak, LPAC, MPEG-4 ALS and WMA-Lossless) the bitrate of the output file is significantly* reduced compared to the lossless original.

Changes from 1.2.0b:
  • Adaptive noise shaping method kindly provided by SebastianG introduced and enabled by default;
  • Fixed noise shaping reworked to allow effective shaping of samplerates other than 44.1kHz / 48kHz.
  • Revised quality presets;
  • Enhanced information output options;
  • Major code cleanup.
Download* on average, depending on content.

This post has been edited by Nick.C: Aug 10 2011, 21:12


--------------------
lossyWAV -q X -a 4 --feedback 4| FLAC -8 ~= 320kbps
Go to the top of the page
+Quote Post
Nick.C
post Aug 6 2011, 21:53
Post #2


lossyWAV Developer


Group: Developer
Posts: 1772
Joined: 11-April 07
From: Wherever here is
Member No.: 42400



CODE
lossyWAV 1.3.0, Copyright (C) 2007-2011 Nick Currie. Copyleft.

This program is free software: you can redistribute it and/or modify it under
the terms of the GNU General Public License as published by the Free Software
Foundation, either version 3 of the License, or (at your option) any later
version.

This program is distributed in the hope that it will be useful,but WITHOUT ANY
WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A
PARTICULAR PURPOSE.  See the GNU General Public License for more details.

You should have received a copy of the GNU General Public License along with
this program.  If not, see <http://www.gnu.org/licenses/>.

Process Description:

lossyWAV is a near lossless audio processor which dynamically reduces the
bitdepth of the signal on a block-by-block basis. Bitdepth reduction adds noise
to the processed output. The amount of permissible added noise is based on
analysis of the signal levels in the default frequency range 20Hz to 16kHz.

If signals above the upper limiting frequency are at an even lower level, they
can be swamped by the added noise. This is usually inaudible, but the behaviour
can be changed by specifying a different --limit (in the range 10kHz to 20kHz).

For many audio signals there is little content at very high frequencies and
forcing lossyWAV to keep the added noise level lower than the content at these
frequencies can increase the bitrate dramatically for no perceptible benefit.

The noise added by the process is shaped using an adaptive method provided by
Sebastian Gesemann. This method, as implemented in lossyWAV, aims to use the
signal itself as the basis of the filter used for noise shaping. Adaptive noise
shaping is enabled by default.

Usage   : lossyWAV <input wav file> <options>

Example : lossyWAV musicfile.wav

Quality Options:

-q, --quality <t>    where t is one of the following (default = standard):
    I, insane        highest quality output, suitable for transcoding;
    E, extreme       higher quality output, suitable for transcoding;
    H, high          high quality output, suitable for transcoding;
    S, standard      default quality output, considered to be transparent;
    C, economic      intermediate quality output, likely to be transparent;
    P, portable      good quality output for DAP use, may not be transparent;
    X, extraportable lowest quality output, not fully transparent.

Standard Options:

-C, --correction     write correction file for processed WAV file; default=off.
-f, --force          forcibly over-write output file if it exists; default=off.
-h, --help           display help.
-L, --longhelp       display extended help.
-M, --merge          merge existing lossy.wav and lwcdf.wav files.
-o, --outdir <t>     destination directory for the output file(s).
-v, --version        display the lossyWAV version number.
-w, --writetolog     create (or add to) lossyWAV.log in the output directory.

Advanced Options:

-                    take WAV input from STDIN.
-c, --check          check if WAV file has already been processed; default=off.
                     errorlevel=16 if already processed, 0 if not.
-q, --quality <n>    quality preset (-5.0<=n<=10.0); (-5=lowest, 10=highest;
                     default=2.5; I=10; E=7.5; H=5; S=2.5; C=0; P=-2.5; X=-5).
--, --stdout         write WAV output to STDOUT.
    --stdinname <t>  pseudo filename to use when input from STDIN.

Advanced Quality Options:

-A, --adaptive <n/t> modify settings for Sebastian Gesemann's adaptive noise
                     shaping method. takes a parameter to set the order of the
                     FIR filter, (32<=n<=96; default=64; multiple of 8 only);
                     "OFF" to disable adaptive shaping; "NOWARP" to disable
                     default frequency warping;
-a, --analyses <n>   set number of FFT analysis lengths, (2<=n<=6; default=3,
                     i.e. 32, 64 & 1024 samples. n=2, remove 32 sample FFT;
                     n>3 add 512; n>4, add 256; n>6, add 128) nb. FFT lengths.
                     stated are for 44.1/48kHz audio, higher sample rates will
                     automatically increase all FFT lengths as required.
-l, --limit <n>      set upper frequency limit to be used in analyses to n Hz;
                     (10000<=n<=20000; default=16000).
    --linkchannels   revert to original single bits-to-remove value for all
                     channels rather than channel dependent bits-to-remove.
    --maxclips <n>   set max. number of acceptable clips per channel per block;
                     (0<=n<=16; default=3,3,3,3,3,2,2,2,2,2,1,1,1,0,0,0).
-m, --midside        analyse 2 channel audio for mid/side content.
    --nodccorrect    disable DC correction of audio data prior to FFT analysis,
                     default=on; (DC offset calculated per FFT data set).
    --scale <n>      factor to scale audio by; (0.0625<n<=8.0; default=1).
-s, --shaping [n]    enable fixed noise shaping, takes optional parameter [n]
                     to allow user defined shaping proportion (0.0<=n<=1.0),
                     otherwise default to quality setting dependent value.
                     Disables adaptive noise shaping.
    --static <n>     set minimum-bits-to-keep-static to n bits (default=6;
                     7<=n<=28, limited to bits-per-sample - 4).
-U, --underlap <n>   enable underlap mode to increase number of FFT analyses
                     performed at each FFT length, (n = 2, 4 or 8, default=2).

Output Options:

    --bitdist        show distrubution of bits to remove.
    --blockdist      show distribution of lowest / highest significant bit of
                     input codec-blocks and bit-removed codec-blocks.
-d, --detail         enable per block per channel bits-to-remove data display.
-F, --freqdist       enable frequency analysis display of input data.
-H, --histogram      show sample value histogram (input, lossy and correction).
    --longdist       show long frequency distribution data (input/lossy/lwcdf).
    --perchannel     show selected distribution data per channel.
-p, --postanalyse    enable frequency analysis display of output and
                     correction data in addition to input data.
    --sampledist     show distribution of lowest / highest significant bit of
                     input samples and bit-removed samples.
    --spread [full]  show detailed [more detailed] results from the spreading/
                     averaging algorithm.
-W, --width <n>      select width of output options (79<=n<=255).

System Options:

-B, --below          set process priority to below normal.
    --low            set process priority to low.
-N, --nowarnings     suppress lossyWAV warnings.
-Q, --quiet          significantly reduce screen output.
-S, --silent         no screen output.

Special thanks go to:

David Robinson       for the publication of his lossyFLAC method, guidance, and
                     the motivation to implement his method as lossyWAV.

Horst Albrecht       for ABX testing, valuable support in tuning the internal
                     presets, constructive criticism and all the feedback.

Sebastian Gesemann   for the adaptive noise shaping method and the amount of
                     help received in implementing it and also for the basis of
                     the fixed noise shaping method.

Matteo Frigo and     for libfftw3-3.dll contained in the FFTW distribution
Steven G Johnson     (v3.2.1 or v3.2.2).

Mark G Beckett       for the Delphi unit that provides an interface to the
(Univ. of Edinburgh) relevant fftw routines in libfftw3-3.dll.

Don Cross            for the Complex-FFT algorithm originally used.

Link to the hydrogenaudio wiki article

Suggested foobar2000 converter setup:

lossyFLAC:
CODE
Encoder: c:\windows\system32\cmd.exe
Extension: lossy.flac
Parameters: /d /c c:\"program files"\bin\lossywav - --quality standard --silent --stdout|c:\"program files"\bin\flac - -b 512 -5 -f -o%d --ignore-chunk-sizes
Format is: lossless or hybrid
Highest BPS mode supported: 24
lossyTAK:
CODE
Encoder: c:\windows\system32\cmd.exe
Extension: lossy.tak
Parameters: /d /c c:\"program files"\bin\lossywav - --quality standard --silent --stdout|c:\"program files"\bin\takc -e -p2m -fsl512 -ihs - %d
Format is: lossless or hybrid
Highest BPS mode supported: 24
lossyWV:
CODE
Encoder: c:\windows\system32\cmd.exe
Extension: lossy.wv
Parameters: /d /c c:\"program files"\bin\lossywav - --quality standard --silent --stdout|c:\"program files"\bin\wavpack -hm --blocksize=512 --merge-blocks -i - %d
Format is: lossless or hybrid
Highest BPS mode supported: 24
lossyWMALSL*:
CODE
Encoder: c:\windows\system32\cmd.exe
Extension: lossy.wma
Parameters: /d /c c:\"program files"\bin\lossywav - --quality standard --silent --stdout|c:\"program files"\bin\wmaencode.exe - %d --codec lsl --ignorelength
Format is: lossless or hybrid
Highest BPS mode supported: 24

Enclose the element of the path containing spaces within double quotation marks ("), e.g. C:\"Program Files"\directory_where_executable_is\executable_name. This is a Windows limitation.

*: Uses the wmaencoder executable written by lvqcl. Found here.

This post has been edited by Nick.C: Sep 4 2011, 21:20


--------------------
lossyWAV -q X -a 4 --feedback 4| FLAC -8 ~= 320kbps
Go to the top of the page
+Quote Post
Steve Forte Rio
post Aug 7 2011, 08:35
Post #3





Group: Members
Posts: 432
Joined: 4-October 08
From: Ukraine
Member No.: 59301



BRAVO!
Go to the top of the page
+Quote Post
halb27
post Aug 7 2011, 09:37
Post #4





Group: Members
Posts: 2414
Joined: 9-October 05
From: Dormagen, Germany
Member No.: 25015



Great work! Thank you, Nick.


--------------------
lame3100m --bCVBR 300
Go to the top of the page
+Quote Post
TBeck
post Aug 11 2011, 01:11
Post #5


TAK Developer


Group: Developer
Posts: 1095
Joined: 1-April 06
Member No.: 29051



Really cool! Thank you!
Go to the top of the page
+Quote Post
punkrockdude
post Aug 11 2011, 16:11
Post #6





Group: Members
Posts: 243
Joined: 21-February 05
Member No.: 20022



Nick.C: Do you play FLAC/LossyWAV with your Android HD2? If so, what application do you use to play them? Regards.
Go to the top of the page
+Quote Post
vvneagleone
post Aug 11 2011, 16:20
Post #7





Group: Members
Posts: 6
Joined: 4-February 11
Member No.: 87921



Nice work! For what purposes do you think this will be most commonly used?
Go to the top of the page
+Quote Post
Nick.C
post Aug 11 2011, 17:44
Post #8


lossyWAV Developer


Group: Developer
Posts: 1772
Joined: 11-April 07
From: Wherever here is
Member No.: 42400



QUOTE (punkrockdude @ Aug 11 2011, 16:11) *
Nick.C: Do you play FLAC/LossyWAV with your Android HD2? If so, what application do you use to play them? Regards.
I use deadbeef - it's a nice simple player.

QUOTE (vvneagleone @ Aug 11 2011, 16:20) *
Nice work! For what purposes do you think this will be most commonly used?
Not really got a firm opinion on that one. Some might use it as a space saving alternative to lossless (say, extreme or insane). Some certainly use it for digitized vinyl. I use it on my DAP of choice (extraportable). lossyWAV sits in its niche - it's not all things to all users - it's just another possible way for users to enjoy audio.


--------------------
lossyWAV -q X -a 4 --feedback 4| FLAC -8 ~= 320kbps
Go to the top of the page
+Quote Post
punkrockdude
post Aug 11 2011, 20:21
Post #9





Group: Members
Posts: 243
Joined: 21-February 05
Member No.: 20022



QUOTE (Nick.C @ Aug 11 2011, 18:44) *
QUOTE (punkrockdude @ Aug 11 2011, 16:11) *
Nick.C: Do you play FLAC/LossyWAV with your Android HD2? If so, what application do you use to play them? Regards.
I use deadbeef - it's a nice simple player.
Thank you. Regards.
Go to the top of the page
+Quote Post
larryfine
post Aug 11 2011, 22:35
Post #10





Group: Members
Posts: 48
Joined: 21-September 10
Member No.: 84040



Great! Thank you very much! biggrin.gif


--------------------
loquor mee menti: factus de materia, cinis elementi...
Go to the top of the page
+Quote Post
Nick.C
post Aug 14 2011, 11:44
Post #11


lossyWAV Developer


Group: Developer
Posts: 1772
Joined: 11-April 07
From: Wherever here is
Member No.: 42400



I've just completed a full music collection transcode FLAC (-5) to lossyWAV (--quality extraportable --maxclips 0|FLAC -5 -b 512 -p 3072) resulting in 307 kbit/s (from 882 kbit/s).


--------------------
lossyWAV -q X -a 4 --feedback 4| FLAC -8 ~= 320kbps
Go to the top of the page
+Quote Post
zerowalker
post Aug 17 2011, 04:16
Post #12





Group: Members
Posts: 239
Joined: 6-August 11
Member No.: 92828



Is this a Almost Lossless compression?
As that is what i get it to be after reading this.
I tried it out, but didnīt really get it to work, it just made lossy.wav that was the same size (or a bit larger i think) as the original wave.
Is there a GUI for this, as i am probably failing with commands, as i just tried to drag and drop randomly;P

Other than my stupidity, it seems very interesting, and if it is what i think, i would very likely experiment with it:)!
Go to the top of the page
+Quote Post
bryant
post Aug 17 2011, 06:40
Post #13


WavPack Developer


Group: Developer (Donating)
Posts: 1287
Joined: 3-January 02
From: San Francisco CA
Member No.: 900



QUOTE (zerowalker @ Aug 16 2011, 20:16) *
I tried it out, but didnīt really get it to work, it just made lossy.wav that was the same size (or a bit larger i think) as the original wave.

This is the expected behavior. However, what's not obvious is that the resulting WAV file has redundancies (lots of zeros in the less significant bits) that lossless compressors can take advantage of to get much better compression than they would on the original WAV file.

The sizes that you should be comparing are the original WAV files compressed with FLAC and the lossy.wav files compressed with FLAC.
Go to the top of the page
+Quote Post
zerowalker
post Aug 17 2011, 19:29
Post #14





Group: Members
Posts: 239
Joined: 6-August 11
Member No.: 92828



QUOTE (bryant @ Aug 17 2011, 07:40) *
QUOTE (zerowalker @ Aug 16 2011, 20:16) *
I tried it out, but didnīt really get it to work, it just made lossy.wav that was the same size (or a bit larger i think) as the original wave.

This is the expected behavior. However, what's not obvious is that the resulting WAV file has redundancies (lots of zeros in the less significant bits) that lossless compressors can take advantage of to get much better compression than they would on the original WAV file.

The sizes that you should be comparing are the original WAV files compressed with FLAC and the lossy.wav files compressed with FLAC.


Okay, what settings or command is recommended?
Thank you:)
Go to the top of the page
+Quote Post
Nick.C
post Aug 17 2011, 19:38
Post #15


lossyWAV Developer


Group: Developer
Posts: 1772
Joined: 11-April 07
From: Wherever here is
Member No.: 42400



The settings for foobar2000 conversion to lossyFLAC, lossyWV and lossyTak are in post #2.


--------------------
lossyWAV -q X -a 4 --feedback 4| FLAC -8 ~= 320kbps
Go to the top of the page
+Quote Post
punkrockdude
post Aug 18 2011, 00:37
Post #16





Group: Members
Posts: 243
Joined: 21-February 05
Member No.: 20022



QUOTE (Nick.C @ Aug 17 2011, 20:38) *
The settings for foobar2000 conversion to lossyFLAC, lossyWV and lossyTak are in post #2.
I have had a problem with the LossyFLAC command line and had to seperate "-o%d" into "-o %d". Regards.
Go to the top of the page
+Quote Post
Nowings69
post Aug 18 2011, 08:29
Post #17





Group: Members
Posts: 95
Joined: 22-December 09
From: nicyoume
Member No.: 76223



Congratulations
Go to the top of the page
+Quote Post
punkrockdude
post Aug 21 2011, 21:15
Post #18





Group: Members
Posts: 243
Joined: 21-February 05
Member No.: 20022



As an intrigued fan of LossyWAV may I ask what you are working on for the next major update or beta version? Regards.
Go to the top of the page
+Quote Post
Anakunda
post Aug 21 2011, 21:17
Post #19





Group: Members
Posts: 414
Joined: 24-November 08
Member No.: 63072



HI! I'm curious what listening configuration is loosywaw -q standard targetted. I have achieved average bitrate at 398kbps. It's higher than lame preset insane, is the quality also higher? I guess this is suitable for lower class home hifi audio equipment. If I'm wrong correct me biggrin.gif
The auCDtect is pretty fooled laugh.gif saying CDDA-100% for most tracks.
Anyway I'd like to see a public listening tst between loosless format, loosyWAV and MP3@320k. Hopefully someone gets the idea too cool.gif

This post has been edited by Anakunda: Aug 21 2011, 21:17
Go to the top of the page
+Quote Post
drumliner
post Aug 21 2011, 23:41
Post #20





Group: Members
Posts: 80
Joined: 25-November 01
Member No.: 537



just tried lossywav to create some lossy.flac files and i'm having a strange issue with it, so some help would be most welcome. i'm using it through foobar, having copied the settings directly from this thread. while the encoding takes place as i would expect it to and the size of the resulting files seems appropriate, there's something wrong with the files as they're all reported by various players as being 405'47'' long, no matter what their real length is (except for a 1'' sample that came out supposedly 270' long). players are also unable to seek the files, reported bitrates are obviously abnormally low and audiotester reports the lossyflacs as being truncated at their real length.
Go to the top of the page
+Quote Post
Nick.C
post Aug 22 2011, 07:48
Post #21


lossyWAV Developer


Group: Developer
Posts: 1772
Joined: 11-April 07
From: Wherever here is
Member No.: 42400



@punkrockdude: I'm not active developing at the moment - having a bit of time off. Identification and implementation of a psychoacoustic model may take some time....

@Anakunda: I would love to see the results too - but it takes a group with the time and inclination to carry out a listening test....

@drumliner: Apologies - settings updated. There was a change in foobar2000 that required the use of the "ignore-chunk-sizes" parameter in FLAC. I omitted to include the latest settings in post #2.


--------------------
lossyWAV -q X -a 4 --feedback 4| FLAC -8 ~= 320kbps
Go to the top of the page
+Quote Post
drumliner
post Aug 22 2011, 13:05
Post #22





Group: Members
Posts: 80
Joined: 25-November 01
Member No.: 537



thanks Nick. working properly now smile.gif
Go to the top of the page
+Quote Post
Nick.C
post Sep 4 2011, 21:22
Post #23


lossyWAV Developer


Group: Developer
Posts: 1772
Joined: 11-April 07
From: Wherever here is
Member No.: 42400



Added: foobar2000 settings for producing lossyWMALSL. Thanks for developing wmaencoder, lvqcl!


--------------------
lossyWAV -q X -a 4 --feedback 4| FLAC -8 ~= 320kbps
Go to the top of the page
+Quote Post
chrizoo
post Sep 19 2011, 14:43
Post #24





Group: Members
Posts: 345
Joined: 25-March 08
Member No.: 52274



I updated from 1.1.0c (which the wiki currently points to) to 1.3.0
and detected that it processes my test file 6 times slower than 1.1.0c (5x instead of 33x). Is this known? What is the reason? Thank you.
Go to the top of the page
+Quote Post
Northpack
post Sep 19 2011, 15:13
Post #25





Group: Members
Posts: 455
Joined: 16-December 01
Member No.: 664



QUOTE (chrizoo @ Sep 19 2011, 14:43) *
I updated from 1.1.0c (which the wiki currently points to) to 1.3.0
and detected that it processes my test file 6 times slower than 1.1.0c (5x instead of 33x). Is this known? What is the reason? Thank you.


That's because of the adaptive noise shaping introduced in version 1.3.0. It gives a higher quality/bitrate ratio but slows down processing. You can disable it with "--adaptive OFF".
Go to the top of the page
+Quote Post

4 Pages V   1 2 3 > » 
Reply to this topicStart new topic
1 User(s) are reading this topic (1 Guests and 0 Anonymous Users)
0 Members:

 



RSS Lo-Fi Version Time is now: 18th April 2014 - 16:58