NORMALIZE(1)

πŸ“¦
version 0.7.7 Β· 2 versions
, in fedora 43, fedora 44, nixos 26.05, nixpkgs unstable

✨ NORMALIZE(1) ✨

okay bestie, gather round, because normalize is one of those little tools that just fixes your whole audio situation and nobody talks about it enough. it lives in section 1 of the manual, it's giving "quiet kid in class who's actually a genius," and today we're getting into it. πŸ’–

🌸 NAME 🌸

normalize β€” adjusts volume levels of audio files.


πŸŽ€ SYNOPSIS πŸŽ€

normalize [ options ] [ -- ] file ...

πŸ’… DESCRIPTION πŸ’…

normalize is the girl who shows up to the group project and makes everyone sound even. it adjusts the volume of wav audio files to a standard volume level. why do you care? because things like creating mp3 mixes are a nightmare otherwise β€” different recording levels on different albums mean the volume jumps around wildly from song to song, and nothing ruins a vibe faster than having to lunge for the volume knob every three minutes. 😭

here's the tea on how it works: normalize operates in two phases.

  1. phase one β€” it analyzes the files you specified as wav audio files, and computes the volume of each file.
  2. phase two β€” it applies a volume adjustment to each file to set each file's volume to a standard level.

two steps, one glow-up. periodt. ✨


πŸ‘‘ OPTIONS πŸ‘‘

  • -a, --amplitude=AMPLITUDE β€” adjusts the RMS volume to the target amplitude AMPLITUDE, which has to be between 0.0 and 1.0. if you slap a number with dB or dBFS on the end, the amplitude is assumed to be in decibels from full scale. default is -12dBFS.
  • -b, --batch β€” turns on batch mode. go read the BATCH MODE section below, bestie.
  • -c, --compression β€” deprecated, lowkey a fossil. back in previous versions this enabled the limiter, but now the limiter is enabled by default anyway. so like… it's fine, it's just not doing anything new.
  • --clipping β€” disables the limiter and just clips any samples that are too large. same effect as -l 0dBFS.
  • --fractions β€” displays all values as decimal fractions instead of in decibels. by default, volume adjustments are shown in decibels, and volume levels in dBFS, where 0 dBFS is the level of a square wave of maximum amplitude.
  • -g, --gain=GAIN β€” skips the volume computation phase entirely. no computing the volume adjustment from the current volumes of the files. instead it just applies the given gain as a volume adjustment to all files. as a plain number this is just a multiplier applied to all samples; if a number suffixed by dB is specified, all volumes are adjusted by that many decibels.
  • --id3-compat β€” use this when adjusting MPEG audio files if your MP3 player does not recognize ID3v2.4 tags. details are in MPEG AUDIO ADJUSTMENT below. 🎧
  • --id3-unsync β€” use this one when adjusting MPEG audio files if your MP3 player does not recognize ID3v2 tags and has trouble playing some ID3v2 tagged MP3 files. again, MPEG AUDIO ADJUSTMENT below has the lore.
  • -l, --limiter=LEVEL β€” controls the behavior of the limiter. by default, all samples above -6dBFS (0.5) are limited, but this option sets the limiting level to LEVEL. setting LEVEL to 1 (or 0dBFS) does no limiting (clipping is done instead); setting LEVEL to 0 does limiting on all samples. the default value is recommended unless you know what you're doing. 🫢
  • -m, --mix β€” turns on mix mode. see MIX MODE below. heads up: batch mode and mix mode are mutually exclusive, you cannot have both.
  • -n, --no-adjust β€” computes and outputs the volume adjustment that would set the volume to the target, but doesn't apply it to any of the files (i.e. it skips the second phase). if you use this option, your files will not be altered in any way. zero damage, all info. πŸ™ˆ
  • --no-progress β€” don't print any progress information. all other messages are printed as normal according to the verbosity level.
  • --peak β€” adjust using peak levels instead of RMS levels. each file will be adjusted so that its maximum sample is at full scale. this just gives a file the maximum volume possible without clipping; no normalization is done.
  • -q, --quiet β€” don't output progress information. only error messages are printed.
  • -t, --average-threshold=THRESHOLD β€” when averaging volume levels for batch mode or mix mode, throw out any volumes that are more than THRESHOLD decibels from the average. a high value here (say, 50) will make sure that the volumes of all files are considered in the average.
  • -T, --adjust-threshold=THRESHOLD β€” if an adjustment to be made to a file is smaller than THRESHOLD decibels, consider the file already normalized and don't do the adjustment. this is 0.125 by default, or 0 if the -g option is given.
  • -v, --verbose β€” increase verbosity. this option can be repeated for more messages. πŸ—£οΈ
  • -w, --output-bitwidth β€” force output files to have samples that are W bits wide. this option is ignored when adjusting MP3 files.
  • -h, --help β€” display usage information and exit.
  • -V, --version β€” print version information and exit.
  • -- β€” terminate option list. the classic "okay I'm done with flags now" divider. βœ‹

πŸ’– MIX MODE πŸ’–

this mode is made especially for making mixed CD's and the like. you want every song on the mix to be the same volume, but honestly? it doesn't matter if they're the same volume as the songs on some other mix you made last week. different mix, different era, different vibes.

in mix mode, the average level of all the files is computed, and each file is separately normalized to this average volume. so everyone matches this mix, and only this mix. πŸ’


πŸ¦‹ BATCH MODE πŸ¦‹

when you're operating on a group of unrelated files, you usually want all of them at the same level β€” and that's the default behavior. easy.

but here's where it gets nuanced: a group of music files all from the same album is generally meant to be listened to at the relative volumes they were recorded at. the artist chose that, and you shouldn't stomp on it.

in batch mode, all the specified files are considered to be part of a single album and their relative volumes are preserved. how? by averaging the volumes of all the files, computing a single adjustment from that, and applying the same adjustment to all the files. some analysis is also done so that files with volumes that appear to be statistical aberrations are not considered in the average. super useful if you have albums (like many of the author's) in which there is one "quiet song" that throws off the average. we've all got one. 😭


🌈 MPEG AUDIO ADJUSTMENT 🌈

MP3 files are "adjusted" by setting a relative volume adjustment frame in their ID3 tags. there is a frame for this, called RVA2, that does exactly what we want, and is a native frame in ID3v2.4.

unfortunately, many MP3 players do not support v2.4 tags, and the RVA2 tag is not native in previous ID3 versions. in fact, adding an RVA2 frame to a v2.3 tag confuses some MP3 players. so we're left with two choices when trying to add volume adjustment information to an ID3 tag:

  1. go ahead and upgrade the tag to version 2.4, and use RVA2 tags. this is the default behavior, in the hope that eventually MP3 players will support v2.4 tags and this won't be a problem anymore.
  2. upgrade the tag to only version 2.3. instead of RVA2, use an XRVA tag with the same format as an RVA2 tag. this isn't a native frame, but since it starts with an "X", it's considered experimental and therefore legal, according to the ID3 spec. the --id3-compat option turns on this behavior. the disadvantage of the first method is that your MP3 player may no longer read the ID3 tags on your files. bug the author of your favorite MP3 player to support ID3v2.4 tags! πŸ“£

the disadvantage of the second method is that the XRVA frame is only recognized by the xmms-rva plugin that is packaged with normalize. on the other hand, I don't know of any MP3 players that recognize the RVA2 frame, either, so it may not make any difference. 🀷

the other option related to ID3 tags, --id3-unsync, is only necessary for compatibility with old MP3 players that don't recognize ID3v2 tags at all. if your MP3 player complains of garbage at the start of tagged files, or is unable to play the files at all, turn this option on. this option should never hurt, but if your MP3 player knows about ID3v2 tags, you don't need it.


πŸ’€ CAVEATS πŸ’€

note that your version of normalize must be compiled with MAD library support to analyze MP3 file volume levels. no MAD, no MP3 analysis. that's just the rules. 😀

🫢 AUTHOR 🫢

Chris Vaill <chrisvaill@gmail.com>


⭐ SEE ALSO ⭐

sox(1)


and that's the whole page, bestie. this one's from 14 September 2005, and it's NORMALIZE(1) β€” go forth, fix your volume, and make the mix of your dreams. you're gonna slay. πŸ’–βœ¨πŸŽ€

πŸ“¦ where this page comes from