Help - Search - Members - Calendar
Full Version: -Y switch: strange behaviour (Lame 3.96.1/3.97a10)
Hydrogenaudio Forums > Lossy Audio Compression > MP3 > MP3 - Tech
sTisTi
Hi,
I just made some tests with the -Y switch with Lame 3.90.3, 3.96.1 and 3.97a10 and was surprised about the strange, inconsistent behaviour:

- 3.96.1 (VBR old): It encodes lots of HF content up to 19 kHz when used with --preset standard (or 18 kHz when used with --preset medium, which uses -Y by default). In fact, it seems to have relatively little impact on cutting HF content.
- 3.96.1 (VBR new): It encodes nothing at all above 16 kHz (both APFS -Y/APM), looks like lowpass.

Note: When used with 3.90.3, APS -Y works as I expected: It cuts out most content > 16 kHz, but there remain some spikes in places with much HF energy.

- 3.97a10: (VBR old): looks very similar to 3.90.3, i.e. some spikes remain.
- 3.97a10 (VBR new): same as 3.96.1 VBR new (all >16 kHz content is killed)

I must say I am confused by this behaviour. The complete cutting of anything above 16kHz in VBR new modes with 3.96.1 and latest alpha seems to be wrong. OTOH, 3.96.1 with VBR-old keeps much more HF content than either 3.90.3 or 3.97a10, which also seems strange.
This leads me to think that some modes could have a bug and should not be recommended at the moment, e.g. --preset fast medium unsure.gif

Of course this doesn't mean these "buggy"(?) modes sound worse, as most people are not good at hearing beyond 16 kHz in actual music, but I thought I'd point out this inconsistent behaviour in case something has really gone wrong in 3.96.1 and/or 3.97a10.
shadowking
Interesting..How many samples did you test?

In my test preset fast medium 3.96 is less annoying than 3.90.3 in problem samples.
Dibrom
Both vbr modes in LAME use completely different code (or did the last time I messed with LAME). Furthermore, -Y was never meant to be used by the public, but for some reason the LAME devs left it exposed. In other words, you shouldn't even really count on -Y behaving any specific way as it's an experimental flag. Obviously in this case, the different vbr implementations are probably interpreting the switch in a different manner.

So if -Y changes behavior in different versions, this doesn't necessarily imply anything is broken. This is one of the obvious downsides of leaving this sort of functionality exposed through the frontend.
ChiGung
I cant figure out if any non -Y altered presets are effectively lowpassing at 16k ?
It may be tweaked so almost no energy is being put into 16k for presets with higher lowpass's. Despite peoples wishes for reaching numbers of KHz, past screeech, and twieieieng.
kevinsham
http://www.hydrogenaudio.org/forums/index....96&#entry281196

Just tested again, the bug is already fixed in 3.97a10.
Gabriel
This was a bug in vbr-new.
However, it should be fixed now.
sTisTi
QUOTE(Dibrom @ Jun 18 2005, 05:29 PM)
Both vbr modes in LAME use completely different code (or did the last time I messed with LAME).  Furthermore, -Y was never meant to be used by the public, but for some reason the LAME devs left it exposed.  In other words, you shouldn't even really count on -Y behaving any specific way as it's an experimental flag.  Obviously in this case, the different vbr implementations are probably interpreting the switch in a different manner.

So if -Y changes behavior in different versions, this doesn't necessarily imply anything is broken.  This is one of the obvious downsides of leaving this sort of functionality exposed through the frontend.
*


Hmm, I thought -Y was expressly recommended (also by you) as the best and most sensible way of lowering the bitrate if --preset standard bloats too much for one's taste, but what you say implies that it shouldn't be used at all because its behaviour is not predictable. Is it at least safe to use with Lame 3.90.3?

What also worries me is that -Y is hardcoded into all VBR modes below -V2 in Lame 3.95.1 and above, so it actually is already widely used and cannot even be deactivated. So I guess it should be made sure that it works as it should.
sTisTi
QUOTE(shadowking @ Jun 18 2005, 05:24 PM)
Interesting..How many samples did you test?

In my test preset fast medium 3.96 is less annoying than 3.90.3 in problem samples.
*


I tested it with several complete songs. Did you also compare the quality of --preset medium with --preset fast medium in 3.96?
guruboolez
QUOTE(sTisTi @ Jun 19 2005, 02:50 PM)
QUOTE(shadowking @ Jun 18 2005, 05:24 PM)
Interesting..How many samples did you test?

In my test preset fast medium 3.96 is less annoying than 3.90.3 in problem samples.
*


I tested it with several complete songs. Did you also compare the quality of --preset medium with --preset fast medium in 3.96?
*



If you're interested, I've tested medium preset (or V4) two times in a recent past:
- 3.97 alpha 5: --preset medium (V4) was significantly worse than --preset fast medium (V4 --vbr-new). Both encodings were compared to 3.09.3 ABR and 3.96.1.
- 3.97 alpha 7: Gabriel tuned -V4, and the gap between -V4 and -V4 --vbr-new was lowered, minor but still present, especially for some samples (micro-attacks problems).
sTisTi
QUOTE(Gabriel @ Jun 19 2005, 12:40 AM)
This was a bug in vbr-new.
However, it should be fixed now.
*


Hmm, I downloaded the latest alpha10 again from rarewares, and VBR old/new still show quite different behaviour. Here's 40 seconds of an example:
Edit: Damn, I can't figure out how to upload the spectrogram screenshots. I'll do so in the uploads section and post the link.
OK, here they are.
shadowking
Fast was worse on a group of samples where i hear a pitch distorsion, old vbr doesn't have it or its much less. Then I found a cure song 'night like this' where i abxed 3.96.1 -aps but not --vbr-new - so sometimes 'new' is better ?!

On -apx I can't seem to tell anything apart on normal music on both vbr modes. Little problems are easier to spot on V5 / V4 and I'll upload some material soon.
beto
Does that mean that --preset fast medium is buggy with 3.96.1? And if so, is it audible?

The reason I ask is because I have a lot of songs encoded with --preset fast medium and LAME 3.96.1 and I want to assess if a reencode is necessary.

thanks.
guruboolez
I also obtain a flat lowpass at 16000 hertz with 3.97a10, -V4 --vbr-new -Y (and --preset fast medium, checked just in case...).
shadowking
Beto, 3.90.3 vbr-new was no better on those samples. I also think that the fast mode can outdo the old mode on others.
sTisTi
QUOTE(beto @ Jun 19 2005, 06:22 AM)
Does that mean that --preset fast medium is buggy with 3.96.1? And if so, is it audible?

The reason I ask is because I have a lot of songs encoded with --preset fast medium and LAME 3.96.1 and I want to assess if a reencode is necessary.

thanks.
*


I think it is confirmed that 3.96.1 has a buggy -Y switch with vbr-new, so -V3 --vbr-new and below will have a flat 16 kHz lowpass. If it is audible depends on your HF hearing capability, so only you can decide.
beto
My intention is not to create noise so I think it's better to be more clear biggrin.gif

Personally I can't hear a difference between 3.96.1 --preset fast medium and original, but since this discussion is about a bug that involves --preset fast medium with 3.96.1 (and newer) I thought encodings might be affected in a negative manner with more frequency and could be spotted easily by ear trained people.

I understand from shadowking's post and guru's last tests on LAME that this is not the case.
tycho
QUOTE(guruboolez @ Jun 19 2005, 06:24 AM)
I also obtain a flat lowpass at 16000 hertz with 3.97a10, -V4 --vbr-new -Y (and --preset fast medium, checked just in case...).
*


This has to be wrong. I just encoded a file with that encoder/setting and viewed it with Nero Wave Editor, which gave me exactly what I expected; A main 16Khz front with a lot of spikes up to 18Khz all the way through. Same with -V3, but more spikes.

/edit: 3.96.1 creates the flat 16khz lowpass. 3.97a10 has it fixed.
guruboolez
Weird... There are maybe various alpha 10 version, with some corrected and some other not. Are you sure that you've used --vbr-new?
Gabriel
Perhaps it is simply because of the content.
Some tracks might not exhibit many any high freqs once encoded, and the thresholds are different between the 2 vbr modes.
tycho
Gabriel must be right. Try with the sample I used, and you'll see what I mean:
Miles_Davis-Amandla(trk2).flac
Miles_Davis-Amandla(trk2).mp3

/edit spelling
sTisTi
QUOTE(tycho @ Jun 20 2005, 07:24 AM)
Gabriel must be right. Try with the sample I used, and you'll see what I mean:
*


OK, I tried it with your file and also with another track which I know has really heavy HF content (Nouvelle Vague - I Just Can't Get Enough) and both of them showed spikes above 16kHz with --preset fast medium. With less extreme tracks, however, it really looks like a lowpass. I encoded my track also to --preset medium, and it shows a lot more spikes. I'd estimate that --preset medium encodes at least 5 times as much HF content for this track, despite 8kbps lower bitrate. I'll put the screenshots in the upload section (see here)

So what do we conclude? Are both modes working OK (i.e. "normal" variation) or could either one be too little or too much sensitive with regard to HF content?
ChiGung
It doesnt look bad to me. Theres no solid cut off in either graph, and the frequency limiting doesnt appear as sporadic - which I was wary of. I can see fast mode is encoding less high frequencies than slow mode, but still a fair amount past 16K - and no sharp transition.

The spikes all the way up to 22Khz are curious - they might be artifacts of the spectrogram generator.

Edit:
I suppose for people who specificaly want very high frequency content included, these graphs could indicate that vbr-new is unsuitable.
tycho
QUOTE(ChiGung @ Jun 20 2005, 11:35 AM)
The spikes all the way up to 22Khz are curious - they might be artifacts of the spectrogram generator.

With -V3 and -V4 --vbr-new I also get those 22khz spikes (in Adobe Aud 1.5). I see this on overcompressed, loud samples, where clipping has occured. When using --scale 0.9 or samples with no clipping, they don't appear.
QUOTE
Edit:
I suppose for people who specificaly want very high frequency content included, these graphs could indicate that vbr-new is unsuitable.
*

Only -V3 and below. --vbr-new -V2 includes a lot of HF content, and has no 22Khz spikes!
sTisTi
QUOTE(tycho @ Jun 20 2005, 12:28 PM)
QUOTE(ChiGung @ Jun 20 2005, 11:35 AM)
The spikes all the way up to 22Khz are curious - they might be artifacts of the spectrogram generator.

With -V3 and -V4 --vbr-new I also get those 22khz spikes (in Adobe Aud 1.5). I see this on overcompressed, loud samples, where clipping has occured. When using --scale 0.9 or samples with no clipping, they don't appear.
QUOTE
Edit:
I suppose for people who specificaly want very high frequency content included, these graphs could indicate that vbr-new is unsuitable.
*

Only -V3 and below. --vbr-new -V2 includes a lot of HF content, and has no 22Khz spikes!
*


Yeah, that's because V2 and above don't use -Y wink.gif
About the spikes: The sample I used is indeed very loud (RG -9db) and suffers from clipping.
This is a "lo-fi" version of our main content. To view the full version with more information, formatting and images, please click here.
Invision Power Board © 2001-2008 Invision Power Services, Inc.