You are here

The "float/fixed" debate and more digital myths

For everything after the recording stage: hardware/software and how you use it.

The "float/fixed" debate and more digital myths

Postby desmond » Thu Jan 02, 2020 9:45 pm

Having a delightful thread over on GS regarding dithering, specifically one guy who is annoyed that when importing 32-bit float files into Logic, Logic converts to 24-bit fixed files, without dithering, and he's convinced the audio sounds worse as a result (after all, 32-bit to 24-bit, you should always dither, which is his argument).

My understanding of 32-bit *float* files, is that, unlike regular 32-bit fixed point files, 32-bit float files *do not* contain 32-bits worth of audio data, they actually contain the regular 24-bit audio data, with (8-bits worth of) scaling values to let that 24-bit audio slide up and down the dynamic range - which is of course useful.

So a 32-bit float file does not contain any extra audio "precision" over a 24-bit fixed point one, and as, during Logic's import, no word length reduction is occurring when saving out the 32-float file to 24-fixed, so no dither is necessary - in short, the audio signal should be identical (assuming the audio is within a typical dynamic range scenario of course).

GS thread:
https://www.gearslutz.com/board/apple-l ... st14420490

Of course, you can find people saying similar - eg a nice post from Bob Ohlsson that 32-float files don't contain any more data than 24-fixed, but people with other "opinions" do things like this, where they say that dithering should be applied when going from 32-bit float to 24-bit fixed: https://www.sonicsciencelab.com/dithering/

So, I'm doing a quality check on my understanding - am I correct, or am I mistaken in this?

Come to my rescue, digital audio nerds! :thumbup:
User avatar
desmond
Jedi Poster
Posts: 9239
Joined: Tue Jan 10, 2006 1:00 am
mu:zines | music magazine archive | difficultAudio

Re: The "float/fixed" debate and more digital myths

Postby James Perrett » Thu Jan 02, 2020 10:06 pm

desmond wrote:So, I'm doing a quality check on my understanding - am I correct, or am I mistaken in this?

That's my understanding too - although as it is GS facts should never get in the way of a good argument :headbang: :headbang: :headbang:
User avatar
James Perrett
Moderator
Posts: 8902
Joined: Mon Sep 10, 2001 12:00 am
Location: The wilds of Hampshire
JRP Music - Audio Mastering and Restoration. JRP Music Facebook Page

Re: The "float/fixed" debate and more digital myths

Postby desmond » Thu Jan 02, 2020 10:19 pm

I think it's a general rule at GS that you can make up whatever "facts" best support your argument... :lol:

Thanks James. :thumbup:
User avatar
desmond
Jedi Poster
Posts: 9239
Joined: Tue Jan 10, 2006 1:00 am
mu:zines | music magazine archive | difficultAudio

Re: The "float/fixed" debate and more digital myths

Postby Folderol » Thu Jan 02, 2020 10:36 pm

32bit float doesn't give you more precision than 24bit fixed, but it does give you greater range. Think of it like having a stepped amplifier/attenuator on the front end.
User avatar
Folderol
Jedi Poster
Posts: 10084
Joined: Sat Nov 15, 2008 1:00 am
Location: The Mudway Towns, UK
Yes. I am that Linux nut.
Onwards and... err... sideways!

Re: The "float/fixed" debate and more digital myths

Postby Hugh Robjohns » Thu Jan 02, 2020 10:59 pm

Yes Desmond. Your understanding is generally correct, assuming the source file audio lies withing the normal dynamic range.

However, if it happened to be a very quiet signal that was created within a floating-point domain, one that peaked at -40dBFS for example, it could be that the floating-point version would contain valid audio data below the fixed-point LSB (24th bit level), and it should therefore be dithered during the translation, as some word-length reduction would be occurring...

But if that was the case, you've probably got much bigger problems to deal with than a bit of theoretical truncation distortion! :lol:

Sadly, my experience on GS has not been good. There certainly are some extremely knowledgable and intelligent posters there -- industry gurus in many cases -- but they are totally overwhelmed by many who are not... :shock:
User avatar
Hugh Robjohns
Moderator
Posts: 26339
Joined: Fri Jul 25, 2003 12:00 am
Location: Worcestershire, UK
Technical Editor, Sound On Sound

Re: The "float/fixed" debate and more digital myths

Postby desmond » Thu Jan 02, 2020 11:03 pm

Thanks Hugh - yes, I'm aware that when you start to hit extremes, thing change a little bit, but I'm talking basically "normal" levels.

Someone else just verified Logic's handling of this by bouncing out a 32f file, reimporting it (Logic converting it to 24-fixed), then rebouncing out to 32f again, and comparing those two 32f files - they were bit identical. Basically, there is no "throwing away" of audio data, or loss of precision when importing 32f files to Logic, when it converts them to 24-fixed (likely for efficiency).

Anyway, thanks for the sanity check, just to make sure my understanding is sound (!). :thumbup:
User avatar
desmond
Jedi Poster
Posts: 9239
Joined: Tue Jan 10, 2006 1:00 am
mu:zines | music magazine archive | difficultAudio

Re: The "float/fixed" debate and more digital myths

Postby wireman » Fri Jan 03, 2020 12:37 pm

desmond wrote:Having a delightful thread over on GS regarding dithering, specifically one guy who is annoyed that when importing 32-bit float files into Logic, Logic converts to 24-bit fixed files, without dithering, and he's convinced the audio sounds worse as a result (after all, 32-bit to 24-bit, you should always dither, which is his argument).

I'm interested in this but don't use Logic so don't understand the question.

Does Logic import a 32-bit float file and operate on it in 32-bit floats internally (I assume so).
So where does the 24-bit fixed file come from, does it only have an option to save in 24 bits or is the imported file taken into some project folder and convered into a 24 bit file?

In either case it would be useful to understand what happens if the peak in the floating-point input file was say +20dB or -20dB.
wireman
Regular
Posts: 357
Joined: Fri Dec 17, 2004 1:00 am

Re: The "float/fixed" debate and more digital myths

Postby Folderol » Fri Jan 03, 2020 12:48 pm

wireman wrote:
desmond wrote:Having a delightful thread over on GS regarding dithering, specifically one guy who is annoyed that when importing 32-bit float files into Logic, Logic converts to 24-bit fixed files, without dithering, and he's convinced the audio sounds worse as a result (after all, 32-bit to 24-bit, you should always dither, which is his argument).

I'm interested in this but don't use Logic so don't understand the question.

Does Logic import a 32-bit float file and operate on it in 32-bit floats internally (I assume so).
So where does the 24-bit fixed file come from, does it only have an option to save in 24 bits or is the imported file taken into some project folder and convered into a 24 bit file?

In either case it would be useful to understand what happens if the peak in the floating-point input file was say +20dB or -20dB.


All the audio code I've worked with uses floats internally, and normalised to the range 0 to +- 1 (peak), converting any other format only at the entry and exit points (if/as requested). Some hardware can also send and receive audio as floats, in which case in no conversion is needed.

Actual AD/DA converters work at fixed discrete levels, hence fixed point of whatever resolution they are capable of.
User avatar
Folderol
Jedi Poster
Posts: 10084
Joined: Sat Nov 15, 2008 1:00 am
Location: The Mudway Towns, UK
Yes. I am that Linux nut.
Onwards and... err... sideways!

Re: The "float/fixed" debate and more digital myths

Postby wireman » Fri Jan 03, 2020 1:17 pm

Folderol wrote:Actual AD/DA converters work at fixed discrete levels, hence fixed point of whatever resolution they are capable of.

Where this is getting interesting is in the use of multiple converters to cover parts of the input range, something Sound Devices have picked up on.
wireman
Regular
Posts: 357
Joined: Fri Dec 17, 2004 1:00 am

Re: The "float/fixed" debate and more digital myths

Postby desmond » Fri Jan 03, 2020 1:37 pm

wireman wrote:Does Logic import a 32-bit float file and operate on it in 32-bit floats internally (I assume so).
So where does the 24-bit fixed file come from, does it only have an option to save in 24 bits or is the imported file taken into some project folder and convered into a 24 bit file?

When you import a 32-bit float file into Logic, Logic first converts it to a 24-bit fixed point file, and then uses that 24-bit file in the project from then on - Ie, it doesn't directly use the original 32-bit float file after the import process.

Logic's mixer is 32-float format by default, but does have a 64-bit high precision engine option if you want.
User avatar
desmond
Jedi Poster
Posts: 9239
Joined: Tue Jan 10, 2006 1:00 am
mu:zines | music magazine archive | difficultAudio

Re: The "float/fixed" debate and more digital myths

Postby Hugh Robjohns » Fri Jan 03, 2020 1:42 pm

So on importing a floating-point file it basically just takes the mantissa and ignores the scalar, assuming it to be unity?

I can kind of see why given that all other local input sources will be fixed point... but given that the mix engine is floating point anyway it seems a rather backward step...

H
User avatar
Hugh Robjohns
Moderator
Posts: 26339
Joined: Fri Jul 25, 2003 12:00 am
Location: Worcestershire, UK
Technical Editor, Sound On Sound

Re: The "float/fixed" debate and more digital myths

Postby Hugh Robjohns » Fri Jan 03, 2020 1:47 pm

wireman wrote:Where this is getting interesting is in the use of multiple converters to cover parts of the input range, something Sound Devices have picked up on.

Sound Devices weren't the first, and won't be the last... although they have engineered their version in a slightly different and ingenious way compared to others, and with some useful claimed benefits...

However, while the additional cost and complexity of this approach might be justified in applications handling unpredictably wide dynamic ranges -- so in digital microphones and location sound recorders, for example -- it is simply not required in the vast majority of everyday recording applications where the dynamic range is known, modest, and predictable, and routinely far less than the 120dB plus range that a modern delta-sigma fixed-point converter can provide very cheaply easily, and accurately.
User avatar
Hugh Robjohns
Moderator
Posts: 26339
Joined: Fri Jul 25, 2003 12:00 am
Location: Worcestershire, UK
Technical Editor, Sound On Sound

Re: The "float/fixed" debate and more digital myths

Postby desmond » Fri Jan 03, 2020 2:00 pm

Hugh Robjohns wrote:So on importing a floating-point file it basically just takes the mantissa and ignores the scalar, assuming it to be unity?

I don't know on the internals of the behaviour offhand. It might ignore the scalar if it doesn't matter, but if it's significant, it may choose to do something differently (eg, scale down and dither, or perhaps even keep and use the 32f file in these circumstances.) - I don't know offhand without checking.

Hugh Robjohns wrote:I can kind of see why given that all other local input sources will be fixed point... but given that the mix engine is floating point anyway it seems a rather backward step...

As I suggested on the thread, it's likely for performance reasons - there's not much point adding additional disk overhead to stream audio files with the 8 extra unused and unecessary bits, so converting down to 24-bit might be a lot more efficient to deal with, and the engine may be optimised heavily for it.

It's actually fairly recently that Logic allowed you to import and export 32-bit files (of any flavour) at all - up until LPX, the best you could do was freeze (which actually does save 32float files, as those frozen instrument channels might be well over 0dBFS), and use those directly. But there is a disk overhead with 32float files over 24.
User avatar
desmond
Jedi Poster
Posts: 9239
Joined: Tue Jan 10, 2006 1:00 am
mu:zines | music magazine archive | difficultAudio

Re: The "float/fixed" debate and more digital myths

Postby Folderol » Fri Jan 03, 2020 2:02 pm

wireman wrote:
Folderol wrote:Actual AD/DA converters work at fixed discrete levels, hence fixed point of whatever resolution they are capable of.

Where this is getting interesting is in the use of multiple converters to cover parts of the input range, something Sound Devices have picked up on.
Which must require some mind-mumbingly precise silcon :o
User avatar
Folderol
Jedi Poster
Posts: 10084
Joined: Sat Nov 15, 2008 1:00 am
Location: The Mudway Towns, UK
Yes. I am that Linux nut.
Onwards and... err... sideways!

Re: The "float/fixed" debate and more digital myths

Postby Kwackman » Fri Jan 03, 2020 2:13 pm

Folderol wrote:
wireman wrote:
Folderol wrote:Actual AD/DA converters work at fixed discrete levels, hence fixed point of whatever resolution they are capable of.

Where this is getting interesting is in the use of multiple converters to cover parts of the input range, something Sound Devices have picked up on.
Which must require some mind-mumbingly precise silcon :o

See the dialog box titled "Floating Free" in Hugh's review of the SD Mixpre-6
https://www.soundonsound.com/reviews/so ... ixpre-6-ii
User avatar
Kwackman
Frequent Poster
Posts: 1551
Joined: Thu Nov 07, 2002 1:00 am
Location: Belfast
Cubase, guitars.

Next