HydrogenAudio

Lossy Audio Compression => MP3 => MP3 - General => Topic started by: masterridley on 2010-03-29 16:48:21

Title: -V2 gives way too high bitrate!?!
Post by: masterridley on 2010-03-29 16:48:21
I use dbpoweramp and I encode flac tracks to LAME 3.98r -V2. Usually this results in ~170 to ~220 kbps files (close to 192kbps CBR quality)

Well, not so for 2 As I Lay Dying albums that I have (think REALLY LOUD metal). When I encode those I get 230-270 kbps and of course the resulting files are quite big.

My question is: is this a bug or completely natural?
Furthermore (if it's not a bug), isn't it just better to encode in 192kbps and get a smaller file, since that's the quality I was going for anyway?

Cheers
Title: -V2 gives way too high bitrate!?!
Post by: dv1989 on 2010-03-29 16:52:23
Natural. VBR targets quality, not bitrate. Loud metal has a lot of HF in cymbals, etc., which LAME allocates more bits to achieve a given quality.

If you want a lower bitrate, try -V3; it's not rocket science.

Quote
Usually this results in ~170 to ~220 kbps files

The key word is usually. Again, VBR doesn't have to target any bitrate. Any quoted figures are averages from particular test sets only.
Title: -V2 gives way too high bitrate!?!
Post by: dsimcha on 2010-03-29 16:56:15
Natural. VBR targets quality, not bitrate. Loud metal has a lot of HF in cymbals, etc., which LAME allocates more bits to achieve a given quality.


I also find that cymbals in metal, punk rock, etc. are usually the first place that noticeable artifacts show up.  Furthermore, I haven't tested this formally or researched the theory of it, but I think based on anecdotal evidence that music with a lot of clipping and/or dynamic range compression (the way REALLY LOUD metal is probably mastered) is pretty hard to encode.
Title: -V2 gives way too high bitrate!?!
Post by: [JAZ] on 2010-03-29 17:06:45
metal (being loud and "noisy"*) kicks on one limitation of mp3 as a format (aside of being difficult to encode by nature).

Two ways to workaround (workaround not equal fix) this is either use something lower than -V2 (like -V3), or use -V2, -V1 or -V0 with the additional -Y parameter.

I preffer not to enter again in the discussion of what this paramater does, and what does not do. If you use it, it simply will not use as much bitrate for songs that have lots of frequency content above 16Khz.




*noisy defined as important amount of signal at the top end of the frequency range.
Title: -V2 gives way too high bitrate!?!
Post by: masterridley on 2010-03-29 17:07:21
Damn! That's what I suspected too (compression). It's just that the numbers seemed a bit ridiculous to my eyes! (~260 VBR for -V2, which I thought corresponded to 192 CBR)

Now I have to try other settings because the files are HUGE as it stands.

Anyway thanks!
Title: -V2 gives way too high bitrate!?!
Post by: robert on 2010-03-29 17:13:21
You could update to LAME 3.98.4, as previous 3.98 versions tried to workaround some Fhg decoder bug, which results in some bloating. Maybe try to reduce file size with mp3repacker (http://www.hydrogenaudio.org/forums/index.php?showtopic=32379) too.
Title: -V2 gives way too high bitrate!?!
Post by: pdq on 2010-03-29 17:14:00
Furthermore (if it's not a bug), isn't it just better to encode in 192kbps and get a smaller file, since that's the quality I was going for anyway?

Wrong! 192 kbps is NOT a quality it is a bitrate. Quality at this fixed bitrate could be just about anything.

If you really want the best quality while restricting to this approximate bitrate then use abr 192 instead.
Title: -V2 gives way too high bitrate!?!
Post by: dv1989 on 2010-03-29 17:24:55
Quote
If you really want the best quality while restricting to this approximate bitrate then use abr 192 instead.

Or just try a lower VBR setting, which will produce smaller files that may well have an average bitrate more to your liking.
Title: -V2 gives way too high bitrate!?!
Post by: masterridley on 2010-03-29 17:26:48
Quote
Two ways to workaround (workaround not equal fix) this is either use something lower than -V2 (like -V3), or use -V2, -V1 or -V0 with the additional -Y parameter.

I forgot to add that my hearing is pretty awful. Specifically, I can barely hear anything above 17k in this test (http://www.egopont.com/hearing_tests.php?soundID=17000&lang=en)

Is there an option to cut content above 17k instead of 16k as -Y does?
Title: -V2 gives way too high bitrate!?!
Post by: greynol on 2010-03-29 17:43:48
-Y does not cut content above 16k; it is not a lowpass.

[JAZ] really didn't want to get into this, and I don't blame him.  Unfortunately it's opened up the door for these kinds of false assumptions.

Answering your question, you can try --lowpass 17.

Regarding -Y, doesn't it kick in with -V settings greater than 2 (such as 2.1), or is it at 3 and higher?
Title: -V2 gives way too high bitrate!?!
Post by: lvqcl on 2010-03-29 18:06:12
Quote
Regarding -Y, doesn't it kick in with -V settings greater than 2 (such as 2.1), or is it at 3 and higher?

The latter.
-Y is always on for -V 3 ... -V 9.999 and off by default for -V 0 ... -V 2.999. (and, there can be a noticeable difference in bitrate between -V 2.999 and -V 3)
Title: -V2 gives way too high bitrate!?!
Post by: Aleron Ives on 2010-03-30 04:59:09
I hate to continue discussion about -Y since it seems to be one of the least favourite LAME aspects to bring up, but there doesn't seem to be a definitive description of what it does. The best information I've seen is the topic from 2002 where Dibrom talks about its purpose, which I gathered is essentially to tell LAME not to encode frequencies > 16 Khz if doing so will significantly increase the bitrate. Aside from his statement that this means ~80% of 16 Khz or higher frequencies won't get encoded, I haven't found any more in-depth descriptions of exactly how much content gets cut. The topic also mentions that a person's frequency response in a test scenario like the egopont test page or the ff123 sweep test isn't necessarily the same as what that person can hear in music, i.e. just because you can hear the 17 Khz beep on the "test your hearing" page doesn't  mean you will be able to ABX music with a lowpass of 16 or the Y switch. Consequently, is the only real answer to the -Y question to encode some files without -Y and also with -Y, then try to ABX them and if you can't hear a difference, you might as well use -Y to save space?

Also, the -Y description from --longhelp says that it ignores sfb21 noise like in CBR. Does this mean that in CBR mode, if you're encoding at a bitrate which uses a lowpass of > 16 Khz, LAME will discard 80% of the content at > 16 Khz so as to make the content < 16 Khz sound better? Presumably if this is the case, it's because since CBR mode is so restrictive, encoding frequencies at > 16 Khz would consume the majority of the available bitrate in CBR mode, and thus all the frequencies < 16 Khz would sound significantly worse. As a result, I assume CBR mode would ignore ~80% of the > 16 Khz content so that there would be sufficient bitrate to make the lower frequencies, which are usually more important, sound better.

I hope I'm not too far off track with this, haha.
Title: -V2 gives way too high bitrate!?!
Post by: greynol on 2010-03-30 05:20:34
Consequently, is the only real answer to the -Y question to encode some files without -Y and also with -Y, then try to ABX them and if you can't hear a difference, you might as well use -Y to save space?

Pretty much, yes, though you might want to include -V3 in your testing.
Title: -V2 gives way too high bitrate!?!
Post by: Aleron Ives on 2010-03-30 05:48:13
Consequently, is the only real answer to the -Y question to encode some files without -Y and also with -Y, then try to ABX them and if you can't hear a difference, you might as well use -Y to save space?

Pretty much, yes, though you might want to include -V3 in your testing.

Well, -V 3 would also cause a drop in bitrate as it relates to overall quality, whereas enabling -Y for -V 0 - 2 would still employ the respective qualities that those settings normally use at the frequencies below 16 kHz (and in the > 16 kHz frequencies that were still included), right?

I hope somebody can shed light on the CBR relationship that is mentioned in the -Y help.
Title: -V2 gives way too high bitrate!?!
Post by: shadowking on 2010-03-30 11:10:59
I suggest not to fiddle with -Y . If you want a lower bitrate and still keep reasonable quality: V3
V2 - Y is hardly better than V3 on problem samples. Also -Y will totally change the mp3 bitrate distribution and quality is affected - whether you hear it or not.

Another approach would be -V2.99 ~ -V2.5 as you still encode HF content but less aggressively.

The V3 is a more efficient method than cbr 192k encoding, it isn't restricted. It will use 200k when needed and drop to 160k when not.
Title: -V2 gives way too high bitrate!?!
Post by: [JAZ] on 2010-03-30 12:03:22
I am preparing to put this on the wiki (but my user has to be validated still. Also, if someone with more knowledge sees any error in the technical description, feel free to correct me)


The -Y switch of LAME

The short and consice:

It is not:[blockquote]
    The -Y switch is not a lowpass filter, nor does it remove high frequencies per-se.
    It does not filter, it does not prevent frequencies higher than 16Khz to exist.
[/blockquote]
It is:[blockquote]
    The -Y switch tells the encoder to use a more coarse representation for the higher frequencies, in the parts where it would cause an over-encoding of all the other bands.
    The -Y switch tells the encoder to not be so strict with the higher frequencies, *IF* they are going to cause an increase of bitrate.
[/blockquote]


The technical and know how:

Preface: [blockquote]
   MP3 audio is stored in the frequency domain instead of time domain.
    The frequencies are then subdivided in several bands.
   The values for these bands are quantized to increase their compressability.
   The scale factor is the amount of quantization. (higher quantization, less resolution. Resolution means the amount of possible values from minimum range to maximum range)
   There is also another quantizer, the global gain, that affects all bands.
[/blockquote]
The problem, described (based on mp3-tech.org (http://www.mp3-tech.org/content/?Mp3%20Limitations)):[blockquote]
   The last scalefactor band (sfb21 for long blocks or sfb12 for short blocks) has no own scalefactor.
   This scalefactor band covers the range from 16kHz up to the higher frequency limit, when using 44.1 or 48kHz sampling frequency.
   If the resolution of this part of the spectrum must be increased (determined by the psychoacoustic model), the local scalefactor, which is missing, can not be used to adjust its resolution.
   To increase the resolution in this case, the only solution is to reduce the global gain value (its quantization). This impacts all other scalefactors, which are also reduced.
   But once they reach a value of 0, they can not be reduced anymore, meaning that a higher than needed resolution will locally be used in those bands, leading to an inflate of the bitrate.
   When encoding sfb21 content, it is common to encounter some scalefactor bands that are encoded with a too high resolution just to accomodate the coding needs of sfb21.
[/blockquote]

The -Y switch in LAME:[blockquote]
   The -Y switch considers the last scalefactor band as different, and tries not to increase its resolution to the point of causing the sbf21 problem.
[/blockquote]
Title: -V2 gives way too high bitrate!?!
Post by: benski on 2010-03-30 17:35:18
very short version: -Y switch makes LAME not encode high frequencies accurately, because doing so can cause disproportional increases in bitrate.
Title: -V2 gives way too high bitrate!?!
Post by: greynol on 2010-03-30 17:42:30
It was not too long and is well worth reading, benski.  If you don't have the time to devote to the entire post, you should have at least read what was labeled "short and concise".  It would have certainly taken no more time than it took you to post what you did.

I think [JAZ]'s entire post is quite worthy of being in the wiki provided that it is technically accurate (I have no reason to think it isn't technically accurate).  I might be wrong, but I think you've pretty much said the same thing that [JAZ] wrote, but more dense, which might be harder for a lay person to understand.  I don't see any reason why that should preclude what you wrote from being in the article if what you wrote can be used to improve it, however.
Title: -V2 gives way too high bitrate!?!
Post by: benski on 2010-03-30 17:44:38
It was not too long and is well worth reading, benski; at least what was labeled "short and concise".  I think it's very worthy to be in the wiki provided that it is technically accurate (I have no reason to think it isn't technically accurate).


Sorry, I meant it as "the very short version" and not a slight at JAZ at all.  I'll edit so no one takes it the wrong way
Title: -V2 gives way too high bitrate!?!
Post by: greynol on 2010-03-30 17:55:33
I hope you caught my edits above since I think your "the very short version" looks excellent to me as well, provided that it is later expanded upon a bit in order to reach a wider audience.

I wish I could do more than just cheer from the sidelines.  While I feel comfortable reading what you guys wrote, it is clear that the two of you are much more intimate with the subject.
Title: -V2 gives way too high bitrate!?!
Post by: Aleron Ives on 2010-03-30 23:38:04
I suggest not to fiddle with -Y . If you want a lower bitrate and still keep reasonable quality: V3
V2 - Y is hardly better than V3 on problem samples. Also -Y will totally change the mp3 bitrate distribution and quality is affected - whether you hear it or not.

I find this to be a bit counter-intuitive. -V 3 has the Y switch enabled by default, so would it not be true that using -V 2 -Y would still yield superior results to -V 3, since -V 3 is actually using -V 3 -Y?  Also, I think I should point out that saying "quality is affected - whether you hear it or not" is rather irrelevant, as the entire point of MP3 is to reduce quality as long as you don't hear it in the name of saving space. 

As probably the resident "lay" person in this topic, I will attempt to repeat [JAZ]'s technical explanation, and hopefully it will give some idea as to how effective that post would be in the wiki to answer the -Y question for people who aren't experts. I fully expect this summary to be less technically accurate than his post, but the purpose is theoretically to show how much of the explanation's content was absorbed more-or-less correctly by someone unfamiliar with the inner-workings of MP3.

In bullet form:



...so, how far off am I?

The one thing that I'm still hoping someone will further enlighten me on is: does CBR mode employ a tactic like the Y switch by default? That is to say, if you encode at a CBR bitrate where the lowpass filter is above 16 kHz, does LAME focus its efforts on the scale factor bands other than sfb21, so that since the available bits are restricted, it can apply what's available to the bands that are deemed more important? If so, I would assume this means that, like with VBR -Y, CBR mode uses lower resolution in sfb21 because it can't afford to lower the global gain to accomodate sfb21's needs, as CBR bitrate limitations mean that LAME has to be frugal in the way it allocates bits.

I continue to bring this up, because I think if my analysis is correct, it might be worthwhile to add the correlation between -Y and CBR to in effect reassure people that if they are generally satisfied with CBR's frequeny range reproduction, they need not fear using -Y in VBR mode, as CBR always has a similar behaviour enabled.
Title: -V2 gives way too high bitrate!?!
Post by: [JAZ] on 2010-03-31 10:25:33
I would like an answer from robert, or someone that has studied this part of the code.

My interpretation of what i've heard is that in CBR mode, the code works in a way that increases the resolution only if enough bits are free and only by the amount the free bits allow.  (Effectively, trying to maximize the quality for the given amount of bits).
In other words, at 320kbps, it would be working more like -V0 (without -Y), and at 192kbps would be working more like -V3 (with -Y)


@Aleron : Your explanation of the subject is correct and correlates to what i've written. I will use part of your tests to make the technical part more understandable.
Title: -V2 gives way too high bitrate!?!
Post by: Aleron Ives on 2010-03-31 10:53:00

I would like an answer from robert, or someone that has studied this part of the code.

My interpretation of what i've heard is that in CBR mode, the code works in a way that increases the resolution only if enough bits are free and only by the amount the free bits allow.  (Effectively, trying to maximize the quality for the given amount of bits).
In other words, at 320kbps, it would be working more like -V0 (without -Y), and at 192kbps would be working more like -V3 (with -Y)

Would I be correct in assuming that every bitrate except 320 would probably behave as though -Y was enabled, seeing as since 320 is the maximum bitrate, -Y isn't really needed? If so, perhaps 320 isn't the best CBR example to use in the explanation, as it's sort of the exception to the rule.

I figure there must be some correlation between -Y in VBR and CBR mode, seeing as the LAME long help says:

-Y    lets LAME ignore noise in sfb21, like in CBR

@Aleron : Your explanation of the subject is correct and correlates to what i've written. I will use part of your tests to make the technical part more understandable.

If you feel that I've correctly distilled the essence of -Y's function, feel free to use anything that you think would improve the quality and accessibility of the wiki entry. My paraphrase certainly isn't as precise as your post, but I hope it might be slightly more understandable to the layman who could still be somewhat confused after reading your in-depth explanation.
Title: -V2 gives way too high bitrate!?!
Post by: shadowking on 2010-03-31 11:52:55
-Y is still 'experimental'.  It was never supposed to be used by non-developers. This is what Dibrom once said. I think these matters are too technical and will never be fully understood.

Another way to look at it is that the original --alt-preset design was get quality 1st THEN reduce bitrate if possible. APS -Y sorta fits it but not really - you are telling it that bitrate is more important (in the context of sacrificing HF quality)  . Preset medium took this even further to get a lower bitrate (sacrifice HF + more aggressive ATH)

By using V2~v0 -Y you are putting yourself into quality is important but bitrate comes 1st. That is against the original design. You are sacrificing something. So V3 is targeting the old APS -Y user by giving a level between APS (V2) and medium (V4). That is more or less what APS -Y did in the old days.
Title: -V2 gives way too high bitrate!?!
Post by: robert on 2010-03-31 12:33:53

I would like an answer from robert, or someone that has studied this part of the code.

My interpretation of what i've heard is that in CBR mode, the code works in a way that increases the resolution only if enough bits are free and only by the amount the free bits allow.  (Effectively, trying to maximize the quality for the given amount of bits).
In other words, at 320kbps, it would be working more like -V0 (without -Y), and at 192kbps would be working more like -V3 (with -Y)

CBR/ABR: the target bitrate is given, the quantization step sizes are adjusted until the target bitrate is reached. LAME does this by in-/decreasing the global gain and evaluating the quantization noise where sfbs are adjustable. It does not evaluate quantization noise in sfb21!
VBR: the target quantization noise within the sfbs is given, the quantization step sizes are choosen such that they result in given quantization noise. At higher quality settings, sfb21 gets evaluated and setting global gain is the only way to control the quantization step size for it. Now, adding -Y lets LAME ignore whatever quantization noise will be in sfb21, just as CBR does.
Title: -V2 gives way too high bitrate!?!
Post by: [JAZ] on 2010-03-31 13:16:53
Thanks robert. I've used your explanations as a way improve the article.

Btw... do you still remember the updated docs i did waaaaaay ago?

http://www.hydrogenaudio.org/forums/index....showtopic=65756 (http://www.hydrogenaudio.org/forums/index.php?showtopic=65756)

I've checked the last changes to the documentation, and probably they will need to be updated too, but at least remember that those exist.



@ shadowking : I was going to say that the switch is not experimental, but two sources from LAME claim the opposite (it is not listed in the switches.html, and it is explicitely shown in the experimental part in lame --longhelp)

But i have to disagree partially with the reasoning behind not using -Y on -V2. -Y is not the only parameter that changes between -V3 and -V2, and -Y does not necesarily affect quality.
If we were to recommend a setting, it is clear that -V2 -Y is not something to recommend.
If we were to recommend a setting for the current case of this topic, -V2 -Y is a recommendation, if the user wants to keep using -V2.

We would need to find a sample where -Y had an impact, and -V2 vs -V3 was ABXable to determine how much -Y affects audibly, if any, in that case.



Ooops! I forgot to put the link:

http://wiki.hydrogenaudio.org/index.php?title=LAME_Y_SWITH (http://wiki.hydrogenaudio.org/index.php?title=LAME_Y_SWITH)
Title: -V2 gives way too high bitrate!?!
Post by: Ajax on 2010-03-31 14:16:57
The original poster "masterridley" (a new member) clearly stated in his first sentence that he is using dBpoweramp from Illustrate software to conduct his LAME MP3 encodings. AFAIK, the dBpoweramp GUI does not allow for -Y switches or -Y parameter changes in the LAME MP3 configuration choice. It does however have a user selectable choice for "high or normal quality" MP3 encodings but I do not think this is the same as a -Y switch (however I could be wrong about this). So "masterridley" if you are still reading this topic, you should know that the -Y switch discussion in your topic may not directly affect your usage of dBpoweramp to encode MP3 files.

Also, a message for Winamp developer Benski who posted before me in this topic.

Benski, it would be nice if there was a way for Winamp users to make -Y switches as well as more detailed LAME MP3 parameter changes in the Winamp GUI. For example, I believe the LAME MP3 configuration GUI in Winamp's current version 5.55 is getting a little outdated and should be updated. Winamp still uses the older "-- alt preset fast standard" LAME MP3 VBR quality selection format which I believe is outdated (but still the same quality as the newer -V selection methods).
Title: -V2 gives way too high bitrate!?!
Post by: robert on 2010-03-31 14:25:34
global gain: is the global quantization step size (value range 0 - 255)
scale factor per band: amount how much to reduce the global quantization step size for this band, (value range different per bands, ie sfb0: 0-15)

Code: [Select]
    ifqstep = (scalefac_scale == 0) ? 2 : 4;
    for (sfb = 0; sfb < psymax; ++sfb)
        quantization_stepsize = global_gain - ((scalefac[sfb] + (preflag ? pretab[sfb] : 0)) * ifqstep) + subblock_gain[window[sfb]] * 8);
Title: -V2 gives way too high bitrate!?!
Post by: pdq on 2010-03-31 14:47:50
@[JAZ]

You might also point out that for older folks like myself the use of --lowpass less than 16 kHz makes -Y a moot point, since sfb21 will now be empty.
Title: -V2 gives way too high bitrate!?!
Post by: shadowking on 2010-03-31 14:53:08
We should not be recommending or documenting -Y unless there is a big issue. I think since v3.94 and the -V scale, there is no need for -Y, -ms etc . IMO if a few album come out @ 270k its not a big deal. That should be an exception rather than the rule. Should we recommend -Y if the rest of the OP's collection is around 200k ?

If  V2 is too high use -V2.5, -V3 or --lowpass 17.5, 17  .  -Y encourages tinkering like the old days.


Basically, I'm saying that in the old 3.90 days -Y was mentioned because there was only APS / APE and everything outside wasn't tuned.. Today there is a tuned V scale for precise control, So there is no need for things like -Y and probably even --lowpass.
Title: -V2 gives way too high bitrate!?!
Post by: dv1989 on 2010-03-31 15:04:13
Quote
LAME Y SWITH

Surely I needn't say it, but perhaps there's a better title?
Title: -V2 gives way too high bitrate!?!
Post by: [JAZ] on 2010-03-31 20:45:58
DOH!

I saw something strange in that, but i didn't realize the typo. Fixed!

http://wiki.hydrogenaudio.org/index.php?title=LAME_Y_SWITCH (http://wiki.hydrogenaudio.org/index.php?title=LAME_Y_SWITCH) 

If you really meant a completely different title... then i'm open to opinions.



As for documenting, explaining and/or recommending the -Y switch, i've done so to have a place to point to, when that question arises again.

Since it only applies to the settings -V2 , -V1 and -V0, because everything else uses it, i cannot see how it can be seen as  a detrimental or damaging setting.
It surely makes the resulting file lower quality than not using it, but if the problem manifests, it can be seen as offering *more* quality than what it targets. (Not because of bitrate increment, but because of why it increases).
Title: -V2 gives way too high bitrate!?!
Post by: dv1989 on 2010-03-31 21:09:06
The spelling was one thing. Also, it may not matter for reasons other than aesthetics (people are unlikely to directly search for the article title, redirects could be set up, and I think wikis 'normalise' case), but must it be ALL CAPS? I thought brick wall limiting was frowned upon here.

Personally, I would use "LAME -Y switch" or such--but as I said, it doesn't much matter, as redirects could catch most users trying other titles.


Edit: grammerz, etc.
Title: -V2 gives way too high bitrate!?!
Post by: Aleron Ives on 2010-03-31 23:58:07
I would like to thank robert for explaining the correlation between -Y in VBR and the default CBR/ABR behaviour. My question has finally been answered.

-Y is still 'experimental'.  It was never supposed to be used by non-developers. This is what Dibrom once said. I think these matters are too technical and will never be fully understood.

While it's true that the Y switch is quite technical and its purpose is difficult to explain, I don't think that means that trying to explain it is automatically a bad idea. I came into this topic having very little understanding of the way MP3 works and having no idea what "sfb21" was, and now I have at least a rudimentary comprehension of what sfb21 is, why it's different from the other sfb's, and why it can cause excessive bitrate in -V 0 - 2. I don't claim to fully understand everything, but I think this topic has taught me enough to make a moderately well-informed decision on whether I want to use -Y. I think that everyone should at least have the chance to receive the same information, so they too can make informed decisions on how they use LAME. No, not everybody will understand -Y after reading the explanation, but that's no reason to deliberately withhold the information, IMO. Isn't the purpose of this site to give people a venue to discuss digital audio, and hopefully learn about it in the process?

As for the "experimental" nature of -Y...

I was going to say that the switch is not experimental, but two sources from LAME claim the opposite (it is not listed in the switches.html, and it is explicitely shown in the experimental part in lame --longhelp)

It seems that -Y has moved into a netherrealm between "experimental" and "standard". While its existence is hidden from the user, -Y is actually probably being employed by many people who use LAME. It's enabled by default from -V 3 all the way to -V 9, and since the -V n presets have been fine-tuned for various quality levels, it seems to me that the developers have already decided that -Y isn't really "experimental"-- it must have a clear benefit that doesn't cause disproportionate decreases in quality, or they wouldn't be including it in the VBR presets.
Title: -V2 gives way too high bitrate!?!
Post by: shadowking on 2010-04-01 10:49:42
This is still going back to my point. Users don't need to make an informed decision unless the current V system is broken. This was the case 7 yrs ago when the was no V system and preset medium couldn't be 'trusted' . Today from what I read people are having a hard time with -V5 - not -V3 or even -V4.

All mentions of  -Y in the wiki look confusing and not professional. In the last 128k tests -V5.7 was used to obtain desired bitrate and NOT some random collection of switches. This worked put very well.

It would be wiser to mention *possible* bloating on some material - rock / metal due to mp3 limitations and that encoder is still doing the right job (its VBR after all). To maintain reasonable quality at an economic bitrate one should consider -V2.7 or -V3. It should be said those settings are still quality tuned but encode HF to lesser precision.
Title: -V2 gives way too high bitrate!?!
Post by: Aleron Ives on 2010-04-01 11:18:24
This is still going back to my point. Users don't need to make an informed decision unless the current V system is broken. This was the case 7 yrs ago when the was no V system and preset medium couldn't be 'trusted' . Today from what I read people are having a hard time with -V5 - not -V3 or even -V4.

All mentions of  -Y in the wiki look confusing and not professional. In the last 128k tests -V5.7 was used to obtain desired bitrate and NOT some random collection of switches. This worked put very well.

Maybe it's just me, but I think deliberately trying to keep people in the dark is "unprofessional". It seems like you're saying, "Most people are too stupid to understand any of this, so let's not even bother trying to explain things in the first place."

There's nothing wrong with having a very simple, well-tuned set of presets for the novice user to get good results with LAME, but I also don't think there's anything wrong with giving more in-depth explanations of how things work. LAME has a ton of configuration options that aren't all very well-explained in the longhelp, so having another resource to turn to for information is beneficial. If the purpose of LAME was to just provide a very simple and static set of MP3 encoding options limited to preset configurations, then all the switches wouldn't exist. The fact that the developers haven't removed them suggests to me that they figure somebody somewhere might have use of them. Consequently, it's nice to explain to people what they do should they wish to read such information. It's not like we're forcing people to read any of the in-depth wiki information. They can easly just see "use -V 2" on the main LAME page or in the LAME recommended usage message if they want the super-simple answer. The fact that someone is reading the wiki page on LAME suggests that they do in fact want more information.

While I can see the merit of trying to separate the in-depth information from the basic information, I think more than just the Y switch is "confusing" in that regard. The entire technical table of V settings ought to be moved to an advanced LAME settings page, as under the assumption that "people don't need to make informed decisions", knowing things like the lowpass for each setting is superfluous.
Title: -V2 gives way too high bitrate!?!
Post by: [JAZ] on 2010-04-01 11:22:50
Robert, can you comment on this line of the article?

Quote
If global gain is zero, resolution will need to be increased (and quantization lowered) on every other scale factor band.


This is mostly extracted from the mp3-tech.org explanation of the sfb21 defect, but from your explanation of the relation between the global gain and the scale factors, isn't it the opposite? Like this:

Quote
Since the range of the scalefactors is small, if global gain is reduced and any of the scale factors cannot be incremented to compensate this reduction, the resolution of that band is increased innecessarily.



I've put up some updates to the article. (orthographic corrections and a couple of further explanations/formatting)
Title: -V2 gives way too high bitrate!?!
Post by: robert on 2010-04-01 11:37:57
Quote
If global gain is zero, resolution will need to be increased (and quantization lowered) on every other scale factor band.

The sentence from the wiki makes no sense. Though the corresponding section at mp3-tech.org does explain the sfb21 problematic very well.

Quote
Scale factor refers to how much quantization (loss of precision) is applied to each band, where higher quantization causes greater compression, and consequently less variation between the minimum and maximum values (resolution).

- scale factors allow to reduce the quantization step size per sfb, within a limited range, as a deviation from the global step size (global gain).
- quantization is a process. larger quantization step sizes allow greater compression, this results in more quantization noise.

Quote
Global gain is an extra quantizer that affects all bands simultaneously.

This is plain wrong.

Quote
The only way to increase the resolution on sfb21 is therefore to reduce the global gain quantization, since global gain applies to all bands.

Needs correction.

Quote
If global gain is zero, resolution will need to be increased (and quantization lowered) on every other scale factor band.

If global gain is zero, then there is nothing you can do anymore.

Quote
LAME implements the -Y switch as a way to activate the alternate logic that CBR uses in respect to quantization noise in the sfb21 band.

No, it's an off switch. It turns off code that's used in higher quality VBR settings.

Quote
Since the sfb21 does not have quantization, its quantization noise is not evaluated.

Makes no sense. The content of sfb21 will surely get quantized.

Quote
In MPEG2 (16,22,24Khz), it is sfb12.

This is wrong. Long blocks have 22 sfbs (sfb0 - sfb21), short blocks have 13 sfbs (sfb0-12). The short block sfb12 has no scale factor of its own, like the long block sfb21.
Title: -V2 gives way too high bitrate!?!
Post by: [JAZ] on 2010-04-01 13:39:39
    

Talk about failing to read... 


I didn't fully understood how could the scalefactor be decreased if the gain was decreased too, and that's why I "invented" the other definition. It is much more clear now that I know that what is stored is not the scale factor itself, but a relative factor.


I've amended the article.
Title: -V2 gives way too high bitrate!?!
Post by: greynol on 2010-04-01 18:28:42
Users don't need to make an informed decision unless the current V system is broken.

I see great benefit in any wiki article that prevents continually recurring discussions/misconceptions about technical matters.

All mentions of  -Y in the wiki look confusing and not professional.

So what?!? They don't necessarily have to be, do they?