Author Topic: (Version 1.3.4) EBUR 128 - Loudness and Dynamic Range Plugin / Tagging Tool  (Read 31817 times)

zkhcohen

  • Sr. Member
  • ****
  • Posts: 346
This is the page for tracking the development of a plugin which will display / tag files with their associated EBU R128 loudness metrics:

  Integrated loudness:
    I:          (LUFS)
    Threshold: (LUFS)

  Loudness range:
    LRA:         (LU)
    Threshold:  (LUFS)
    LRA low:    (LUFS)
    LRA high:    (LUFS)

  True peak:
    Peak:         (dBFS)

The stats will be displayed in a panel plugin, and it will (optionally) write them to tags in your files.

The plugin leverages the FFMPEG audio library.
Last Edit: June 07, 2019, 02:57:43 PM by zkhcohen

zkhcohen

  • Sr. Member
  • ****
  • Posts: 346
COPIED FROM THE OLD THREAD

I tried running that one in conjunction with the VST support plugin for Music Bee, but I haven't had any luck yet.

Still looking into alternatives.

The documentation indicates that there is both a stand-alone and VST version in the TT-DR installer--did you try the standalone version?  I was thinking that might be convenient to run via MB Tools on selected libray files.  I'd try it myself but DR analysis has really no interest for me, but Mr. Trev might give it a shot.  I did extract the installer via 7-Zip and it shows a "DR-Offline.exe" file and its own folder structure with own graphics as well as a VST dll in a separate folder.

I was thinking about doing a conversion of the TT-DR CLI someone made for Linux but then I found the ebur128 library in FFMPEG:

Code
FOR %a IN ("*.mp3") DO (ffmpeg -i "%a" -af ebur128=peak=true -f null - 2>&1 | FINDSTR /BIC:" ")


...should analyze every mp3 in a folder and spit out data like this:

Code
  Integrated loudness:
    I:         -12.9 LUFS
    Threshold: -23.3 LUFS
  Loudness range:
    LRA:        11.2 LU
    Threshold: -33.3 LUFS
    LRA low:   -20.7 LUFS
    LRA high:   -9.5 LUFS
  True peak:
    Peak:        0.2 dBFS

This is really efficient and the output is easy to work with. I'm no audio engineer, so it'll take a while for me to determine whether this is the best approach.

https://auphonic.com/blog/2012/08/02/loudness-measurement-and-normalization-ebu-r128-calm-act/


EDIT:


The following command will create a text file for each .mp3 which includes the data at the end:

Code
FOR %a IN ("*.mp3") DO (ffmpeg -i "%a" -af ebur128=peak=true -f null - > %a-output.txt 2>&1)


This would be really easy to implement into a MusicBee Plugin.
Last Edit: March 18, 2019, 11:56:54 PM by zkhcohen

sveakul

  • Sr. Member
  • ****
  • Posts: 2438
Thanks for this new project which I'm sure many MB users will be glad to add to their config!  Excellent on making tagging vs. values display optional.  If the Spectrogram plugin is any indication, I can see you flying through this one :)  Please offer use of an external path to ffmpeg as before.

alec.tron

  • Sr. Member
  • ****
  • Posts: 752
Neat! If this were a MB plug-in that optionally writes the info to metadata as well, this would be well useful. With additional txt files (if I understood correctly) I'll need to see if this would fit my library. But very interesting to see this realized either way!
Thanks a lot!
c.

zkhcohen

  • Sr. Member
  • ****
  • Posts: 346
Neat! If this were a MB plug-in that optionally writes the info to metadata as well, this would be well useful. With additional txt files (if I understood correctly) I'll need to see if this would fit my library. But very interesting to see this realized either way!
Thanks a lot!
c.


Yep! Working on the part which writes to the file's metadata right this second.

Hoping to have updates very soon.

zkhcohen

  • Sr. Member
  • ****
  • Posts: 346
Here's the first alpha release:

http://www.mediafire.com/file/nx3xtcyxqiaiib9/BETA_-_mb_Loudness_Analyzer.zip/file


PLEASE READ THIS:

Firstly, this is in ALPHA - you've been warned. There is plenty of room for improvement here, but I want to make it available to you guys for testing.

ALSO NOTE: This current implementation will OVERWRITE Custom Tag 10-16. For the love of God, do NOT run this on your DB and then complain that you lost those tags. You've been warned.


Installation:

1. Copy the plugins folder into your MusicBee directory, merging it with your default Plugins folder (or copy the .dll to that location).
2. Copy the Dependencies folder to your MusicBee AppData directory. Copy the ENTIRE folder, not just its contents.
3. Configure the names for your Custom Tags (10-16) and displayed columns. This is the format:

Custom Tag 10: Integrated Loudness
Custom Tag 11: IL Threshold
Custom Tag 12: LRA (Dynamic Range)
Custom Tag 13: Threshold
Custom Tag 14: LRA Low
Custom Tag 15: LRA High
Custom Tag 16: True Peak

...and here's a (rough) example of what it can look like:





Usage:

1. Select 1+ files that you'd like to tag (I don't recommend more than 10 at a time on a low-powered machine with this current alpha build, but up to 100 on a high-powered machine).
2. Right-click and then click "EBU R128 Tag" from the Context Menu.
3. Accept the prompt to begin the tagging process. Wait for a couple of seconds (up to 5 for the first file) and then the file tags should quickly begin populating.

NOTE: You may have to click between files to see the tags updating in your columns. I plan on fixing this.
Last Edit: March 25, 2019, 05:07:06 AM by zkhcohen

sveakul

  • Sr. Member
  • ****
  • Posts: 2438
Some questions:

1.  In its current alpha state, does it only write to tags, or can it just do a pop-up GUI value display and NOT write to tags?

2.  Can a path be supplied to an external ffmpeg.exe?

This is just for my own curiosity.  The best testers will be those who actually apply and use R128/ReplayGain tags.  Good luck on your new project!

zkhcohen

  • Sr. Member
  • ****
  • Posts: 346
There's no pop-up at the moment since I'm guessing that very few (if any) people will need this info on the fly. I've adjusted the purpose of this plugin to be a pure substitute to the functionality of Foobar2000 and the Dynamic Range Analyzer plugin.

Yeah - you can create a path.txt file in the dependencies folder with the path to FFMPEG contained within it.


Mr. Trev

  • Sr. Member
  • ****
  • Posts: 454
Nice. I'll play around with this later.

Quick question…

Am I correct to assume that tag 12 (LRA) is the equivalent of the numbers spit out on http://dr.loudness-war.info?
Does this also give an album average or just on a per track basis?

zkhcohen

  • Sr. Member
  • ****
  • Posts: 346
Nice. I'll play around with this later.

Quick question…

Am I correct to assume that tag 12 (LRA) is the equivalent of the numbers spit out on http://dr.loudness-war.info?
Does this also give an album average or just on a per track basis?

Yes - LRA (Loudness Range) is the rough equivalent to the dynamic range number spit out by MAAT.

https://ask.audio/articles/demystifying-the-confusion-around-loudness-metering-levels

It uses a different algorithm so it doesn't always line up perfectly, but EBU R128 is generally considered a better standard.

This does not currently give an album-rating. To be honest, I'm not sure why that number is useful beyond comparing/complaining about the Loudness War. I'm not an audio engineer, so let me know if there's another reason.

Mr. Trev

  • Sr. Member
  • ****
  • Posts: 454
Nice. I'll play around with this later.

Quick question…

Am I correct to assume that tag 12 (LRA) is the equivalent of the numbers spit out on http://dr.loudness-war.info?
Does this also give an album average or just on a per track basis?

Yes - LRA (Loudness Range) is the rough equivalent to the dynamic range number spit out by MAAT.

https://ask.audio/articles/demystifying-the-confusion-around-loudness-metering-levels

It uses a different algorithm so it doesn't always line up perfectly, but EBU R128 is generally considered a better standard.

This does not currently give an album-rating. To be honest, I'm not sure why that number is useful beyond comparing/complaining about the Loudness War. I'm not an audio engineer, so let me know if there's another reason.

I'm not concerned if it aligns perfectly with MAAT - I've just gotten used to the 1-14+ scale they use.

As far as the album average rating, what I would use it for is for determining what music I want to compress and what I want to leave lossless on my portable devices. I look at the DR range for the album, see where it sits on that 1-14+ scale. If it has a low DR rating than i will convert the files to AAC to save space and max the amount of music that'll fit on my sd cards. I'll leave lossless for the albums where the artist/producers make to most of the DR range (basically comparing/complaining about loudness wars)
 
This is probably a very user specific reason, but its my reason anyways. Personally, I really can't say I need anything other than an album average rating TBH (I don't use replaygain or anything like it)

Cheers, looking forward to see what comes next

frankz

  • Sr. Member
  • ****
  • Posts: 3834
Don't go by me and start feeling pressured to add features based on what I think because the chances I'll ever use this are small (although it looks very cool), but Album DR ranges are useful in identifying specific sources and masterings for albums of which there are many different releases, vinyl vs CD versions, remasters, remixes, etc which aren't always identified in the tags when you "acquire" them.

zkhcohen

  • Sr. Member
  • ****
  • Posts: 346
Thanks for the suggestions.

I'll look into adding an album DR rating.

I'll almost certainly implement it as a second sub-menu item that averages the DR over the selected songs (assuming that's how MAAT calculates it).

zkhcohen

  • Sr. Member
  • ****
  • Posts: 346
Hi folks,

Reposting this since it was lost in the migration.

The link has been updated with version 1.1. This update includes a context menu option for averaging the dynamic range values for a selection of files.