SoX Optimizations: Direct USB versus UPnP/DNLA

I asked for these specific graphs because there are specific discussions I want to have about these particular comparisons that I believe may be helpful to people in thinking about how to adjust Audirvana’s filter settings.

@mhsmit, thank you kindly for these.

Today is a busy day (old and dear friends are in town), so my response/discussion will have to wait until somewhat later this evening at least.

2 Likes

Corollary to the discussion regarding subjective assessment of sound-quality in the tuning of upsampling filter response. this little graphical reference is useful for just about anybody and for other descriptive lexicon:

Also corollary in the discussion:

What we hear:
Basic dimensions of auditory experience
HST.725 Music Perception and Cognition, Spring 2009
Harvard-MIT Division of Health Sciences and Technology
Course Director: Dr. Peter Carian

The actual quote is this


“It doesn’t make sense to hire smart people and then tell them what to do, We hire smart people so they can tell us what to do.”

:notes: :eye: :headphones: :eye: :notes:

1 Like

So, in your own .pdf language, you told @mhsmit that he or she was right?

No I was just trolling for you wisdom :smirk:

I know

OK, let’s start to talk about what these graphs are showing us, and what they can tell us about setting up our systems.

First it’s useful to remember that digital filtering is a balancing act between minimizing frequency-based distortion (aliasing and imaging, where frequencies above the audio band are made by the filter to “fold down” into the audible frequency range, causing distortion) and minimizing time-based distortion (ringing, more properly the Gibbs effect, where the filter causes oscillation at the frequency where it cuts the signal).

Regarding aliasing, let’s look at the first two images showing the transition bands for r8brain 1.5 linear phase and SoX 14.4 intermediate phase. Both filters do very nicely, beginning to cut above audible frequencies so we don’t lose any of the highs, and cutting nearly all response by the Nyquist frequency, 22050Hz, so we won’t have any appreciable aliasing or imaging.

Now let’s look at the impulse responses of these two filters, where we get a somewhat more interesting comparison.

We see with the r8brain linear phase filter there is some pre-ringing, that is, oscillation before the main impulse. A couple of things about this: First, recall that the ringing frequency is at the point where the filter cuts, and we saw this was above audible frequencies. Second, notice the very low amplitude (energy) of the ringing. Given these two facts, it is at least controversial and perhaps even doubtful whether the ringing has any audible effect. This is really saying no more than that the filter, with its cutoff that is not as sharp as the SoX one, is pretty nicely designed to minimize both ringing energy and aliasing/imaging. Finally, one last item of note for the sharp-eyed: The amplitude of the main impulse is quite high, reaching approximately -0.7dB. This means we will hear powerful transients if they are in the musical signal.

Looking at the SoX intermediate phase impulse response, we see unsurprisingly, because phase is timing, that the intermediate phase filter has moved the pre-ringing energy and some of the main impulse energy so it occurs after the main impulse. While there is no pre-ringing, the amplitude of the main impulse is approximately -4.4dB, about 3.7dB down from the r8brain amplitude, quite possibly enough to be audible. And the first few cycles of post-ringing are pretty energetic, though remember again that these are occurring at higher than audible frequency. Thus from the SoX filter, if we hear a difference from the r8brain filter at all, it might be in the form of a less energetic transient response, with a possibility of an enhanced “reverb tail” to the signal caused by the greater post-ringing energy.

Comparison of r8brain minimum phase and SoX intermediate phase shows the same transition band performance (since we haven’t changed that aspect of these filters). Regarding impulse response, we see as we get to minimum phase, there is even lower amplitude of the main impulse and an even longer “reverb tail” (again emphasizing the ringing is taking place above audible frequencies) than intermediate phase.

Comparing the two linear phase filters, we see the Sox filter’s sharper cutoff results in just very slightly more ringing energy than r8brain, but still quite low, which is to be expected.

Finally, let’s look at the “aliasing enabled” SoX filter in comparison to r8brain 2.12 linear phase. Note that the SoX filter really minimizes ringing energy in the impulse measurement. But the very gentle cutoff that enables this comes with two costs: The cut starts at the top of the audible range, with thus a very slight possibility of removing a bit of the high end (though unlikely for anyone except very young people); and more importantly, as it says in the filter name, there will be some aliasing with this filter, because it only cuts by 18dB at the Nyquist frequency.

What does all this mean for filter settings in Audirvana?

First, bandwidth: Don’t go below 91 (20/22.05), or you’ll begin to cut in the audible range. Also remember that ringing occurs at the point of the cutoff, so you may want to put this a bit above the audible range.

Second, attenuation or anti-aliasing: It’s OK to back off just a little from the maximum on this to minimize ringing energy, but not so much that you’ll introduce aliasing/imaging.

Phase: If you’re tremendously worried about pre-ringing, back off to intermediate phase or set to minimum phase, depending on whether you’re using SoX or r8brain. My own personal thinking, and what I think these graphs help to illustrate, is that very low ringing energy above audible frequencies may well not be a problem, and intermediate or minimum phase settings may even cause a loss of energy on transients. But you’re the one listening to your system, so do what sounds best to you.

Finally, filter length (SoX): A longer filter means the filter operates on the signal for a longer time, causing a sharper cutoff and more ringing, so don’t make the filter much if any longer than the default.

3 Likes

The post Fc stop band noise is not reverb
 it is residual harmonic energy that has not been completely filtered-off and attenuated.

1 Like

@Amarok1969
This link to Filter Ringing will graphically explain what @Jud is describing to you
 Apparently he and Yuri, the Founder, Audiophile Inventory are friends
 I don’t know why he does not utilize the wealth of graphical information found there at Audiophile Inventory?

:notes: :eye: :headphones: :eye: :notes:

1 Like

Well, @Jud @Agoldnear @mhsmit
It is detailed and understandable information. Thank you all for the effort.

I plan to do some extra research with guidance of your information and with that come to understand my set up more and (most important) come to know what are the best settings for me. I have to get back with you on that.

2 Likes

When I first learned about the technical aspects SoX settings, I often found it very difficult to match with what I was hearing. I originally relied mostly on what was published on the Audirvāna website and did some Googling.

I’m talking 10-5 years ago, before r8brain came out, with a more limited amount of experiences shared on forums, and before AI as an additional aggregated source).

It was also a time when my system was less resolving. While I already heard clear differences in the cutoff frequency (% Nyquist), what I heard was probably at 1% steps. With the Aliasing Filter, I heard clear differences between the extremes, but didn’t hear differences with smaller than around 200 increments. The phase setting was more obvious to my ear, always ending up somewhere between 60 and 72%. In my studio I had it set to 70%, but in my new house, after a few years of acoustic treatment optimization, I clearly prefer 66%.

It has become very obvious to me that I originally simply could not hear the differences because their effects were masked by contaminated power and possibly RFI (and maybe ground potential differences) on the USB and Ethernet lines. IsoRegen made a huge difference. EtherRegen switch a big one, too. Going from Mac-USB to Mac-Ethernet-UltraRendu-USB made a smaller difference before I added EtherRegen and different Ethernet cables. But now the added clarity of the UltraRegen DLNA path is very significant. Especially after adding LPSes to IsoRegen, UltraRendu and Mac mini late last year. I couldn’t believe that I also heard the difference when I connected a different power cable to the Mac mini‘s LPS.

Note that this is all after I had the new house (a wooden cabin or “lodge” if you will, built with a power phase dedicated to audio, making sure that no switching devices (such as LED lamp, microwave etc) are on the same circuit. I did this because identical optimizations had made a big difference in my old house when I built the studio ten years ago.

I can now hear the Audirvāna optimizations much more clearly and the resulting musical enjoyment is fantastic. It’s a bit like going to a concert in a hall with amazing acoustics (I was in Prague last year and Smetena Hall blew me away when a cello started playing. That hall didn’t have the most comfy seats but wow
 the body and reverb of the strings was amazing, even from the 15th row).

Finally, I now understand more clearly how the upsampling settings influence each other. For example, having a low setting for the Anti-Aliasing filter can make the music sound more “lively” and even harsh, causing me to perhaps set the cutoff frequency too low. And adding too much filtering (setting anti-aliasing too high, or selecting a DSD conversion/modulation order that is above 4 or 5) can “deaden” the sound, causing me to select a cutoff frequency that was too high. I have found out over time that getting to my “magical” setting required all of the parameters to be just right. And this takes a lot of time listening.

Thanks for this detailed explanation.

What I also found interesting, were the more gradual phase curves with Sox Intermediate and SoX Minimum Phase. I have a feeling that these are relevant for what I find so enjoyable about the body and harmonics of acoustic instruments, as well as the finesse of instrument positioning with deep and wide soundstage (all of which I find contribute to natural, analog-like sound).

With the SoX Aliasing curve, we can see that it goes into the higher frequency range, which requires the anti-aliasing filter to start doing serious work to avoid distortion and smearing in the audible range. The slower curve may result in more natural sound to my ears. Filter length and anti-aliasing filter % may become even more critical and audible because of it.

I have a feeling that the granular setting of phase with SoX is important to my ears. I have always found Audirvana to sound better than any DAC I’ve listened to without upsampling. The typical built-in filter settings (slow, fast, etc) are quite coarse, and the processing speed built into DACs limited. This may also explain why r8brain’s Minimum and Linear phase switch don’t “do” it for me.

1 Like

What??? No Faraday shielding? :wink:

I’ve got the audio equipment on a separately derived circuit fed by an isolation transformer. I trust (I hope :slightly_smiling_face:) it helps.

1 Like

I have found that the more I cleaned up power (even fuses!), the more clearly I started to hear prior optimizations.

For example, about 8 years ago I tested USB cables. Found an expensive USB cable to sound only (very) marginally better than inexpensive ones, including a $8 6”/15cm Lindy cable I found on Amazon. Told the vendor, who then gave me a huge discount and suggested I keep the high end cable.

After I moved houses, I initially left the high end cable in the studio. But decided to give it a try after my recent power supply upgrades. And to my surprise, the high end cable now made a much more noticeable difference.

Sometimes an optimization step can remain masked by other limitations and imperfections in the system. I think investing in your transformer may have provided a clean baseline for the future, even if you didn’t notice a huge difference initially.

1 Like

I feel constrained to point out the gentlest phase curve of all is a flat line (linear phase). :wink: But as the Benchmark provides its own filtering, the final product is going to look different than the graphs for SoX or r8brain alone that are pictured above.

One way to make sure that what you’re attracted to in intermediate or minimum phase settings isn’t the milder transients is a particular test track from Brian Bromberg’s album “Wood” entitled “The Saga of Harrison Crabfeathers.” On this track Bromberg plays a 300 year old bass. If you aren’t afraid for the structural integrity of that old bass during this track, your system isn’t giving you the full impact of transients. It’s nice that the transients are coming from a bass, because it prevents a false impression of transient attack simply from an overemphasis on the higher range. There’s also a beautifully played piano (by someone who accompanied Sinatra), which is an excellent test of both transient attack and balanced frequency response. (Plus excellent drum and cymbal work
 you get the idea.)

2 Likes

Listening now, and wow what a beautifully recorded track! It literally sounds like the bass is actually in the room, slightly behind the speakers, perfectly centered. With amazing texture and harmonics, and dynamic. The subtle snare drum and overheads further behind it. The piano also is clear and smooth.

I love listening to such great sounding tracks. While Jazz isn’t even my favorite genre.

Another track I’ve been listening to a lot this year is “Chicago Blues” on album “Where We Are” by Joshua Redman. I love the saxophone and especially xylophone in that track. I can almost see the sticks hitting it, each note in its own location in the soundstage :slight_smile:

1 Like

Yes indeed! But as you noted, this is a compromise. For me, anything above 72% or so becomes less natural in harmonics (especially in orchestral music, but also in the character of an acoustic guitar or even the bass similar to the Brian Bromberg track. For me Min. Phase sucks the life out of recordings like that. And Linear Phase makes them perhaps even too detailed. At 66% I’m finding a life-like naturalness with such instruments.

BTW, the Wood album (I’m still listening :)) is already 96kHz high res on Qobuz. My SoX upsampling settings (to my ears) make many 44.1kHz tracks sound extremely close in character.

1 Like

Your reference to Brian Bromberg’s album (which sounds amazing) prompted me to re-listen to one of my favorite albums by bass player Avishai Cohen “Two Roses” with symphonic orchestra. After this year’s optimizations, I now hear it clearer and the soundstage is deeper than ever. I saw that he has new albums I haven’t yet listened to. Great weekend listening ahead!

1 Like

Anyone using Con Kolivas megataps.patch to SoX? :sunglasses:
Have been using this since 2021 ish
 In my some what??? “subjective/objective”??? opinion it is touch better than the Pan Galactic Gargle Blaster (PGGB)


And I am sure AgoldenRear will have some gargle to blast us with
 Lol