• WANTED: Happy members who like to discuss audio and other topics related to our interest. Desire to learn and share knowledge of science required. There are many reviews of audio hardware and expert members to help answer your questions. Click here to have your audio equipment measured for free!

True Peak may be a matter of definition...

AnalogSteph

Major Contributor
Joined
Nov 6, 2018
Messages
4,215
Likes
4,362
Location
.de
I have been playing with the options for "True peak scan" in the Foobar2000 ReplayGain scanner lately, which allows you to use any resampler DSP installed for the oversampling. This made me notice a marked difference in results between "auto 4x oversample" - which I presume uses the filtering suggested in ITU-R BS.1770-5 (or maybe not?) - and e.g. doing 4x upsampling in the SoX resampler DSP with default settings (quality normal, passband 95%, phase response 50% = linear). As the latter is the resampler I routinely use for resampling to either 48 or 192 kHz, this is not exactly an academic exercise.

For example, here's my CD with the highest peaks I could find, Heathers "Kingdom" from 2012 that was a bit behind the times as it clearly was not mastered using an oversampled brickwall limiter which were gaining widespread acceptance at the time (and dare I say it, it always sounded broken to me), using the SoX resampler DSP as outlined above:
rg-heathers-kingdom-sox-4x.png


And this is the result with Auto 4x:
rg-heathers-kingdom-auto-4x.png


They cannot even completely agree about which tracks have the highest peak levels in which order, although there's the same 4 tracks to be found in the top 5. In the case of Underground Beneath, there's a whopping 1.67 dB difference between both upsampling algorithms.

For a slightly more common release, here's Ladyhawke's s/t from 2008, arguably the peak loudness war year (I don't have Death Magnetic, X&Y or other notorious examples as I tended to stay well clear of such records at the time). First SoX 4x:
rg-ladyhawke-sox-4x.png

And then Auto 4x:
rg-ladyhawke-auto-4x.png

Again, there is some disagreement, up to 1.68 dB in this case. (And yes, the SoX resampler DSP with its SSE3 optimizations seems to be quicker than the auto algorithm indeed.)

In short, oops. True peak is clearly a function of DAC (or resampler) reconstruction filter, and those may vary. The advice to master to -1 dBTP may not only be completely justified, but even falling short by a bit.

Now what about some modern releases then? Going all the way to 2024, Caroline Rose's Art of Forgetting is not atypical for what I'm seeing these days. Again, first SoX:
rg-carolinerose-artofforgetting-sox-4x.png

...and then Auto 4x:
rg-carolinerose-artofforgetting-auto-4x.png

Disagreements between algorithms have shrunk to 0.24 dB, and worst-case peak is +0.655 dBFS.

I assume that they were going for 0 dBTP, but clearly they slightly missed the mark. The filter used for TP metering must be less steep than either of the resampler options I tried.

Finally a slightly hotter one, fairly fresh off the presses as it only released about a month ago, Desperate Journalist's No Hero - first with SoX again:
rg-desperatejournalist-nohero-sox-4x.png

...and then Auto 4x:
rg-desperatejournalist-nohero-auto-4x.png

That's about a 0.66 dB disagreement on the first track, and a worst-case peak of +1.51 dBFS.
 
Last edited:
Nice work, appreciate it. Read your blog, have to dig in a little more. Tried to explain this topic to some young fellas at a venue, with a Allen and Heath digital mixer - to no avail.
 

Attachments

  • BurlB2.JPG
    BurlB2.JPG
    27.3 KB · Views: 43
Tried to explain this topic to some young fellas at a venue, with a Allen and Heath digital mixer - to no avail.
You tend to have a much easier time grasping overs if you are familiar with the Gibbs phenomenon first. Ultimately they are at least in part the same thing. You are sending a signal that is not inherently band-limited (as the output of a nonlinear operation like a brickwall limiter tends to be) through a lowpass filter. Then of course the whole aspect of being digital still adds the possibility of signals whose sample values are always smaller than their true peak amplitude which happens to be reached in between those sample points, case in point the fs/4 +3dBFS test signal.
 
Last edited:
TP is always an estimate.
we also have to look at where the -1dB comes from. it's a safety margin for encoding into lossy formats.
the best way to deal with those peaks is to generate lossy versions and listen for glitches.
Competitive masters have to be above -14Lufs anyway, so there is no need to be concerned about the Spotify limiter, for example.
 
Yikes! :eek: Is that lossless or MP3? (Also, what sort of monstrous CPU do you have there? 5950X? 7950X? Threadripper? 13900K? 14900K? Some Xeon?)

I still found a CD with higher peaks here - Grimes' 2015 Art Angels:
rg-grimes-artangels-sox-4x.png

(And that's about as fast as my poor little i7-11700 will go, even when not using my usual "eco mode" ThrottleStop preset.)

Didn't I mention that 2008 was peak loudness war? Here's Santogold's (now known as Santigold) s/t:
rg-santogold-sox-4x.png

The main culprit here is that remix at the end, athough there's at least two other tracks with overs in the 1.30s.

Here's Aussie group Sneaky Sound System's 2009 s/t compilation with material from the 2006 and 2008 albums:
rg-sneakysoundsystem-sox-4x.png


I think we can discern a pattern... a lot of the worst offenders are some kind of electronic dance music or adjacent.

In MP3 format, Maddy Ellwanger's 2013 Gruesome Minds takes the biscuit:
rg-maddyellwanger-gruesomeminds-sox-4x.png

I'm just not sure whether this wasn't screwed with (e.g. MP3Gain) at some point, but it was a legit Amazon MP3 download. In any case, nobody is going to be surprised when I say that it is rather lo-fi and I don't think I've listened to it more than once or twice. (2017's Hunny has a lot more civil levels and as an aside is a pretty cool album if Danielle Dax in the Wild West is your vibe.)
 
Last edited:
Yikes! :eek: Is that lossless or MP3? (Also, what sort of monstrous CPU do you have there? 5950X? 7950X? Threadripper? 13900K? 14900K? Some Xeon?)
That's FLAC. 13700k overclocked to 5.7Ghz.

e: Sorry it was MP3. The FLAC looks much better:

1730064687729.png


I think the speed has more to do with the storage than the CPU. If your files are FLAC you have indeed beaten me with the true peak. But yeah just goes to show that the true peak measurement is not very accurate.
 
Last edited:
With the latest (12B) microcode, I hope.

You don't have true peak scanning enabled.
Yeah. So far mine has no degradation, I think even tho I experimented a lot. Sorry didn't know about true peak scanning. So the FLAC is.

1730065204823.png


And the MP3 is:

1730065233399.png


1730065248498.png


Even with True Peak enabled it doesn't seem to change things much.


e: Using my default resampler settings with Sox with 48khz looks like this (and this is the FLAC!):

1730065392298.png
 
e: Using my default resampler settings with Sox with 48khz looks like this (and this is the FLAC!):
That's odd. With a 48k target I'm just getting peaks slightly below those for SoX with 4x upsampling on the Sneaky Sound System and Santogold CDs, which would mean yours ought to increase further when going from 48k to 4x. :eek:

Just for reference, what are your default settings? Mine are bog standard (normal quality, 95%, 50 % = linear). I'm obviously using "Best" quality for actual output but it doesn't make a difference for peak scanning other than slowing things down.
 
That gives me a moderate increase in peak levels on Sneaky Sound System, with "Best" quality being somewhat higher than "Normal" still:
rg-sneakysoundsystem-sox-best-95-45-48k.png

Interesting.

Could you try with bog standard settings in return? I reckon you'll still end up well in the 1.70s.

Oddly enough, Santogold goes in the exact opposite direction, with peak levels dropping noticeably:
rg-santogold-sox-best-95-45-48k.png

Even at 4x they're still lower than with the purely linear phase filter.

The Grimes album is similar. Ladyhawke as well.
 
Last edited:
Ok,I'll play ,found the most hideous example of my library,some stuff my nephew gives me of unknown origin:

48k.PNG


48kHz



x4.PNG


x4 sox upsample

(don't dare judge my CPU,it's only 12yo,an I5 :p )

set.PNG
 
Last edited:
Also,sox 4x upsample (both mods i have),48k and automatic PG x4 upsample are all in perfect agreement.
 
Do things get closer together from different paths of upsampling if you upsample more than 4x? I usually upsample by 16x when working within a DAW. I can do the experiment myself, but perhaps some of you have already done it.
 
Do things get closer together from different paths of upsampling if you upsample more than 4x? I usually upsample by 16x when working within a DAW. I can do the experiment myself, but perhaps some of you have already done it.
They should. Upsampling produces additional points between the original ones. The larger the factor, the more points are added. The more points are sampled, the closer you’ll get to the real peak, since the interval between points gets smaller.
 
They should. Upsampling produces additional points between the original ones. The larger the factor, the more points are added. The more points are sampled, the closer you’ll get to the real peak, since the interval between points gets smaller.
That is what I had in mind. The reason I upsample to 16x in a DAW wasn't due to the peak issues. It seemed to me that it would reduce/eliminate any differences in peak values by being closer to the waveform peak thru the mechanism you describe.
 
Back
Top Bottom