IPB

Welcome Guest ( Log In | Register )

2 Pages V   1 2 >  
Reply to this topicStart new topic
WavPack VBR (quality oriented) mode
softrunner
post Mar 22 2013, 03:34
Post #1





Group: Members
Posts: 48
Joined: 19-July 12
Member No.: 101579



bryant, are you going to implement some quality mode in WavPack? Three years ago you wrote: "I would someday like to add a VBR “quality based” mode to WavPack hybrid (which would counter one advantage of LossyWAV)". Maybe the time for it has come? I do not see, how it is possible to be satisfied with ABR, because for some files 192 kbps is enough, and some needs 400+ kbps. Using 400+ kbps for all files hits file size, while using lower bitrate hits quality.
Go to the top of the page
+Quote Post
shadowking
post Mar 24 2013, 09:55
Post #2





Group: Members
Posts: 1529
Joined: 31-January 04
Member No.: 11664



I would like this too. I still think you will end up with 350..400k for normal signals but critical signals could get a lot more. Moreover, quality differences between the modes will be eliminated.

ABR is less flexible but not really worse than VBR in the higher bitrates. As you said 400+k would suffice but is wasteful. For lossywav I find that without noise shaping you also need a similar rate and 350k at the very least. I think with these codecs to cannot achieve consistently good quality and make it alternative to the TC: you need double the rate - 300k or more.

Currently I find a setting of -b4 -x5 to be sufficient so far on my collection of 400 cd's. This yields 370k on average.


--------------------
Wavpack -b450s0.7
Go to the top of the page
+Quote Post
darkbyte
post Mar 24 2013, 17:35
Post #3





Group: Members
Posts: 155
Joined: 14-June 11
Member No.: 91517



Although i'm testing Opus nowadays for portable use i vote for this. It would be still awesome if the achievements of LossyWAV could be more tightly intergrated with WavPack hybrid for example. smile.gif


--------------------
Wavpack -b450x1c
Go to the top of the page
+Quote Post
softrunner
post Mar 25 2013, 03:22
Post #4





Group: Members
Posts: 48
Joined: 19-July 12
Member No.: 101579



QUOTE (shadowking @ Mar 24 2013, 12:55) *
Currently I find a setting of -b4 -x5 to be sufficient so far on my collection of 400 cd's. This yields 370k on average.

Do you remove .wvc files (permanently)?

This post has been edited by softrunner: Mar 25 2013, 03:22
Go to the top of the page
+Quote Post
bryant
post Mar 28 2013, 06:36
Post #5


WavPack Developer


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



I still would like to work on this as an enhancement to the lossy mode some day, but the problem is that I really don't know how to go about it. I tried a real psychoacoustic hearing model early on but abandoned it when it didn't work well. I have thought about adding some simple analysis that would tweak up or down the bitrate (maybe based on a tonality estimate) but I'm not sure if that would work well either. I don't have the time to get involved with the level of testing and tweaking that LossyWAV went through, and I don't think I can use the LossyWAV algorithm directly because I would end up with the exact same bitrate.

If anyone else wanted to give this a shot I would be happy to help and bounce ideas around, but at this point I don't have the spare time to put any effort into it myself.
Go to the top of the page
+Quote Post
shadowking
post Mar 28 2013, 11:06
Post #6





Group: Members
Posts: 1529
Joined: 31-January 04
Member No.: 11664



QUOTE (softrunner @ Mar 25 2013, 13:22) *
QUOTE (shadowking @ Mar 24 2013, 12:55) *
Currently I find a setting of -b4 -x5 to be sufficient so far on my collection of 400 cd's. This yields 370k on average.

Do you remove .wvc files (permanently)?



I think its not a bad idea to back them up (.WVC) to external HDD or optical media. Use only .WV as your main collection and include them in your backup routine.


To be clear I am usually happy with lame 150..200k as long as you don't use DSP, transcode, have unusual listening habit, have or listen to particular troublesome samples. In that sense lossless offers little to no benefit and ripping straight to Lame -V3 is fine with me. I would however like the ability to transcode to another format, bitrate or even CBR. I would like high quality - some thing a bit more than mp3. At the same time like yourself I consider lossless excessive: 370k vs 870k. The ability to go lossless may also be important and mp3, mpc, acc ,ogg don't make that easy or possible at all.

-


--------------------
Wavpack -b450s0.7
Go to the top of the page
+Quote Post
softrunner
post Mar 30 2013, 15:02
Post #7





Group: Members
Posts: 48
Joined: 19-July 12
Member No.: 101579



QUOTE (bryant @ Mar 28 2013, 09:36) *
I still would like to work on this as an enhancement to the lossy mode some day, but the problem is that I really don't know how to go about it. I tried a real psychoacoustic hearing model early on but abandoned it when it didn't work well. I have thought about adding some simple analysis that would tweak up or down the bitrate (maybe based on a tonality estimate) but I'm not sure if that would work well either. I don't have the time to get involved with the level of testing and tweaking that LossyWAV went through, and I don't think I can use the LossyWAV algorithm directly because I would end up with the exact same bitrate.

If anyone else wanted to give this a shot I would be happy to help and bounce ideas around, but at this point I don't have the spare time to put any effort into it myself.

It is sad, because if you don't do it, probably nobody will. Some first step is needed, then, at least, some testing will be possible. Currently there is nothing to work with.

QUOTE (shadowking @ Mar 28 2013, 14:06) *
I think its not a bad idea to back them up (.WVC) to external HDD or optical media. Use only .WV as your main collection and include them in your backup routine.

This is not my case, I would like to drop it permanently.
Go to the top of the page
+Quote Post
shadowking
post Mar 31 2013, 06:05
Post #8





Group: Members
Posts: 1529
Joined: 31-January 04
Member No.: 11664



Perhaps making an experimental encoder using simple tonality estimation would be a start. Maybe if it works with the current DNS quality might be better than expected.


--------------------
Wavpack -b450s0.7
Go to the top of the page
+Quote Post
shadowking
post Mar 31 2013, 06:34
Post #9





Group: Members
Posts: 1529
Joined: 31-January 04
Member No.: 11664



QUOTE (softrunner @ Mar 25 2013, 13:22) *
QUOTE (shadowking @ Mar 24 2013, 12:55) *
Currently I find a setting of -b4 -x5 to be sufficient so far on my collection of 400 cd's. This yields 370k on average.

Do you remove .wvc files (permanently)?


I would too. But keeping them is not always for quality reasons. It just adds flexibility . One thing is that these days I am against using the -hh or even -h for lossy mode as I find a normal mode + -x to work better without altering decoding speed. I still have old encodes with -hh and cannot reverse it.

I find it easy to move the correction files to a zip archive dump that file offline.

I don't think one has to distrust ABR. Its true that a proper tuned VBR is ideal, but the current system is also safe even for high demand using -b350x5 . The -x and -dns are doing constant analysis to prevent quality from falling too much. So there is a very basic 'psymodel' in place.


--------------------
Wavpack -b450s0.7
Go to the top of the page
+Quote Post
shadowking
post Jul 31 2013, 15:54
Post #10





Group: Members
Posts: 1529
Joined: 31-January 04
Member No.: 11664



I've experimented further this time with the aim to find *consistent* behavior at 'economical bitrates' < 400+k . The aim is high-extreme high quality for those who dont want to keep correction files, a possibility to transcode to mp3 or other lossy and a substitute to lossywav.

I arrived at -b320hhx6 as the lower end economy setting and -b380hhx6 as the top end setting. The lower setting is probably enough for nearly all commercial CD's . Bad cases may be a slight elevation of hiss probably not perceptible at normal listening situations -b380hhx6 can be used for rare CD's or paranoid needs. Of course 500k will also do but the aim is economy and quality without correction files. -h may be used instead of -hh for those concerned with portable use. There may be a slight quality decrease. For PC archiving / use I'd go with -hh. -x5 also works well and can save %20 encode time. To minimize CPU load when multitasking , the -l switch can be used. I also noted a positive improvement using -b320hhx6 --blocksize=4410.

This post has been edited by shadowking: Jul 31 2013, 15:58


--------------------
Wavpack -b450s0.7
Go to the top of the page
+Quote Post
bryant
post Aug 3 2013, 22:22
Post #11


WavPack Developer


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



QUOTE (shadowking @ Jul 31 2013, 07:54) *
I've experimented further this time with the aim to find *consistent* behavior at 'economical bitrates' < 400+k . The aim is high-extreme high quality for those who dont want to keep correction files, a possibility to transcode to mp3 or other lossy and a substitute to lossywav.

Thanks for documenting your experiments, shadowking! These pretty much match my expectations and matches what I use (except I use 384 kbps just because it's a “standard”, which is a little silly on my part because WavPack lossy does not hold the bitrates that tight anyway).

One thing interesting though is your observation about short blocks helping. I have suspected that the “extra” modes might benefit from shorter blocks because that would allow the predictors to be tuned more quickly to changing audio. However, you might want to check the actual resulting bitrates because the overhead associated with each block will be greater, especially with -hh (the higher modes have longer headers).

David
Go to the top of the page
+Quote Post
shadowking
post Aug 4 2013, 14:31
Post #12





Group: Members
Posts: 1529
Joined: 31-January 04
Member No.: 11664



I did some more tests. --blocksize=4410 adds 6 /8 / 9 kbps to normal / -h / -hh. So yes its not a lot but the -hh seems to suffer more than default mode with bloat. I started wondering about an alternative route using the normal mode. This decreases decoding overheads and allows faster encoding. I still want economical bitrates if possible. I know in the past I used an inflated bitrate to counter the quality loss going from high modes to normal. I started with 350x6 and 410x6 as the upper limit.

I also tested the Atem lied sample again at medium volume. I could abx 320hhx6, 350hhx6 and the --blocksize=4410 variant. There is one spot that is not to hard to abx. I felt --blocksize=4410 was better but could not prove it with this sample. At 384hhx6 i was defeated several times in abx but -b384x6 was much inferior. Using my upper end alternative of -b415x6 was the solution. I tried -b415x4 and was equally impressed. I tried -b384x6 which was easy to abx, this time with --blocksize=4410 and there was really an improvement. I arrived at 6/8 vs 9/10 for -b384x6.

My alternative [faster] but higher bitrate version using the normal mode:

350 ~ 415k using at least -x4. --blocksize=4410 may also help - bitrate increases by 1.5 %. Average bitrate is 367 ~ 433.

This post has been edited by shadowking: Aug 4 2013, 14:33


--------------------
Wavpack -b450s0.7
Go to the top of the page
+Quote Post
DARcode
post Aug 11 2013, 13:14
Post #13





Group: Members (Donating)
Posts: 682
Joined: 10-January 05
From: Italy
Member No.: 18968



QUOTE (shadowking @ Aug 4 2013, 14:31) *
At 384hhx6 i was defeated several times in abx but -b384x6 was much inferior. Using my upper end alternative of -b415x6 was the solution. I tried -b415x4 and was equally impressed. I tried -b384x6 which was easy to abx, this time with --blocksize=4410 and there was really an improvement. I arrived at 6/8 vs 9/10 for -b384x6.
Very interesting indeed, thank you very much.
I know you're trying to steer clear of high modes, but do you think you could find the time to test -b384hx6 with default block size (or even better -b4hx6)?
That's what I'm using, since my Android smartphone can handle the workload with just a minor hit on battery life, and your ears are waaay better'n mine, thanks.

This post has been edited by DARcode: Aug 11 2013, 13:24


--------------------
WavPack 4.70.0 -b384hx6cmv/qaac 2.43 -V 100
Go to the top of the page
+Quote Post
darkbyte
post Aug 18 2013, 21:24
Post #14





Group: Members
Posts: 155
Joined: 14-June 11
Member No.: 91517



I wonder if it's feasible to achieve good quality with WavPack lossy in the 275-320kbps bitrate range on CD audio. That's what i am using for high quality lossy setting at the moment (lame3100k -V1 --cvbr 8 or Ogg Vorbis q8) and because i'm listening to more and more music with A2DP on my car headunit i thought i could achieve better sound quality by using a non transform codec encoded audio on my phone which doesn't do spectrum manipulation which propably makes the stupidly simple SBC codec's job harder. PowerAMP already decodes WavPack very well, i've used such lossy files in the past but maybe a 384kbps wv lossy is overkill in portable environment or in a noisy car, so i wonder how safe is to move lower in bitrate. From WavPack's doc i can see that a 256kbps WV is quality wise somewhere between a 160kbps and 192kbps mp3. Is that still true? How about a 275kbps wavpack? Can it achieve a quality of a 224kbps mp3? I know it's all theoritical without ABX-ing but maybe somebody already tried this. smile.gif

This post has been edited by darkbyte: Aug 18 2013, 21:29


--------------------
Wavpack -b450x1c
Go to the top of the page
+Quote Post
shadowking
post Aug 19 2013, 04:31
Post #15





Group: Members
Posts: 1529
Joined: 31-January 04
Member No.: 11664



I think quality should be excellent down to 285k and similar to high VBR mp3. Experiment and use your own music rather than test signals. If encoding time isn't critical you can use a high -x setting alone or in conjunction with -h for additional headroom.


--------------------
Wavpack -b450s0.7
Go to the top of the page
+Quote Post
darkbyte
post Aug 19 2013, 12:52
Post #16





Group: Members
Posts: 155
Joined: 14-June 11
Member No.: 91517



I'll give it a try, thanks.

I know the general opinion is to avoid -h when coding for portable devices but i wonder how big the penalty is when i use this switch? WavPack is a simpler codec than mp3 so decoding should be less CPU demanding. Using the -h switch should be still in the same or lower class than decoding and mp3, right? If i'm thinking right using the -h switch is not so evil considering the quality boost it provides on lossy encoding, especially on such low bitrates what we are talking about here.


--------------------
Wavpack -b450x1c
Go to the top of the page
+Quote Post
DARcode
post Aug 19 2013, 14:10
Post #17





Group: Members (Donating)
Posts: 682
Joined: 10-January 05
From: Italy
Member No.: 18968



@darkbyte: As mentioned in my previous post I use -b4hx6 lossy files on my Android smartphone (HTC One SV) with a really minor hit on battery life.

@shadowking: I know you're trying to steer clear of high modes, but do you think you could find the time to test -b384hx6 with default block size (or even better -b4hx6)?


--------------------
WavPack 4.70.0 -b384hx6cmv/qaac 2.43 -V 100
Go to the top of the page
+Quote Post
darkbyte
post Aug 19 2013, 20:37
Post #18





Group: Members
Posts: 155
Joined: 14-June 11
Member No.: 91517



Thanks DARcode! I'll give it a try smile.gif

Not closely related but i've wondered if it's possible to modify WavPack lossy in such way to allow different sampling rate in the lossy layer. Say i have a 88.2Khz 24bit audio file but i only want 44.1Khz in the lossy layer encoded with 4bits but keep the 88.2Khz 24bit audio with the correction applied. Currently i can't do this because the lossy layer's sample rate must match the correction file's one. This yields a lot higher bitrate in my case. I wonder if this difference could be handled somehow.

This post has been edited by darkbyte: Aug 19 2013, 20:37


--------------------
Wavpack -b450x1c
Go to the top of the page
+Quote Post
shadowking
post Aug 20 2013, 03:24
Post #19





Group: Members
Posts: 1529
Joined: 31-January 04
Member No.: 11664



QUOTE (DARcode @ Aug 11 2013, 22:14) *
QUOTE (shadowking @ Aug 4 2013, 14:31) *
At 384hhx6 i was defeated several times in abx but -b384x6 was much inferior. Using my upper end alternative of -b415x6 was the solution. I tried -b415x4 and was equally impressed. I tried -b384x6 which was easy to abx, this time with --blocksize=4410 and there was really an improvement. I arrived at 6/8 vs 9/10 for -b384x6.
Very interesting indeed, thank you very much.
I know you're trying to steer clear of high modes, but do you think you could find the time to test -b384hx6 with default block size (or even better -b4hx6)?
That's what I'm using, since my Android smartphone can handle the workload with just a minor hit on battery life, and your ears are waaay better'n mine, thanks.



I've done some more tests and I'll report in the next few days.


--------------------
Wavpack -b450s0.7
Go to the top of the page
+Quote Post
shadowking
post Aug 20 2013, 03:41
Post #20





Group: Members
Posts: 1529
Joined: 31-January 04
Member No.: 11664



QUOTE (darkbyte @ Aug 19 2013, 21:52) *
I'll give it a try, thanks.

I know the general opinion is to avoid -h when coding for portable devices but i wonder how big the penalty is when i use this switch? WavPack is a simpler codec than mp3 so decoding should be less CPU demanding. Using the -h switch should be still in the same or lower class than decoding and mp3, right? If i'm thinking right using the -h switch is not so evil considering the quality boost it provides on lossy encoding, especially on such low bitrates what we are talking about here.



I don't think adding -h will have a negative effect on any modern device. Bryant made it for portable use when -hh gave an ipod some trouble so the advice was to avoid -hh . My old pentium 550mhz easily played wavpack lossy -hh and monkeys audio (high). I tested poweramp last year and -hh wavpack lossy was no problem at all (25 % vs 18 % normal mode cpu) . -h is probably somewhere in between. Transcoding is faster with normal and fast modes though . If I want to make quick mp3s the normal mode has the advantage.

This post has been edited by shadowking: Aug 20 2013, 03:45


--------------------
Wavpack -b450s0.7
Go to the top of the page
+Quote Post
shadowking
post Sep 4 2013, 10:04
Post #21





Group: Members
Posts: 1529
Joined: 31-January 04
Member No.: 11664



Ok I tested atemlied and other problem samples over the last few weeks. Taking into account the original goal of lowest possible bitrate for archiving - there is concern at using 450..500k bitrates to achieve constant quality & different settings for different samples.
I found that combining -h / -hh with -x6 / x5 brings much more stable quality across the board that becomes apparent starting from 380k. In other words extreme high quality kicks in at that level. Average bitrate is 390..400 . I believe even the worst cases are either eliminated or greatly reduced close to nil while normal signals are always perfect. For me that is acceptable for archiving. I

results of atemlied:

b4hx6 = 13/16
b384hx6 = 10/16
b380hhx5 = 11/16
b380hhx6 = 2/9
b380hhx4 = 11/16

This post has been edited by shadowking: Sep 4 2013, 10:04


--------------------
Wavpack -b450s0.7
Go to the top of the page
+Quote Post
DARcode
post Sep 4 2013, 17:19
Post #22





Group: Members (Donating)
Posts: 682
Joined: 10-January 05
From: Italy
Member No.: 18968



Thank you very much shadowking, appreciated.
Now let's see if I got it right: since you've never scored 12/16 or better with anything else besides b4hx6 it means all other settings produce actual transparency to your ears right?
b4hx6, my choice, and b384hx6 are pretty close in terms of average bitrate produced, so how come the difference you think?


--------------------
WavPack 4.70.0 -b384hx6cmv/qaac 2.43 -V 100
Go to the top of the page
+Quote Post
shadowking
post Sep 15 2013, 04:30
Post #23





Group: Members
Posts: 1529
Joined: 31-January 04
Member No.: 11664



The 30kbit difference is around 2db noise. That could be significant when noise within hearing threshold.

I also tested the lower redesigned x-1 ~ 3. These were supposed to be used for daily tasks and offer a practical improvement in compression / speed / quality. I find that the defensive mechanisms kicks in at -x2 and its much faster than -x3 and yields similar quality or compression. In comparison to -x(1) -x2 is always better to my ears , compresses better and still fast. It seems to work well with -h and -hh .


--------------------
Wavpack -b450s0.7
Go to the top of the page
+Quote Post
darkbyte
post Oct 29 2013, 17:24
Post #24





Group: Members
Posts: 155
Joined: 14-June 11
Member No.: 91517



Compression speed with b380hhx6 is very slow so i wonder how much bitrate should i spend if i like to use the fast mode instead but still achieve transparency in hybrid mode. I'm curious about fast mode because encoding my whole collection takes a lot time and i'm also working on a Wavpack decoder written in Dart and i can achieve considerably lower CPU usage by decoding fast mode encoded files.

I've tried b420fx4 yesterday and it gave a very good 45x compression speed on my computer instead of 6-12x compression speed with b380hhx6.
I wonder how transparent is this setting for you shadowking? In the final average bitrate it's only 40-50kbps higher for me than the what you suggested which is acceptable (around 448kbps for me) but it's a lot faster.

This post has been edited by darkbyte: Oct 29 2013, 17:37


--------------------
Wavpack -b450x1c
Go to the top of the page
+Quote Post
bryant
post Oct 31 2013, 00:31
Post #25


WavPack Developer


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



I would not presume to speak for shadowking, but my initial reaction would be to not recommend the “fast” mode if quality is a high concern (and that is definitely the point of shadowking's testing). The “fast” mode only provides two decorrelator passes for the “extra” mode to work with, so it's pretty limited in what it can do in difficult situations. However the default mode provides five, which gives it a lot more flexibility.

Without a comment from shadowking, my guess is that b420x4 would provide the same quality margin as his version, and still be reasonably fast to encode and easy to decode.
Go to the top of the page
+Quote Post

2 Pages V   1 2 >
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 December 2014 - 12:11