Sonarworks Headphone Calibration Software

Talk about your MIDI interfaces, microphones, keyboards...

Moderators: MattKingUSA, khz

User avatar
funkmuscle
Established Member
Posts: 2800
Joined: Mon Jun 02, 2008 2:30 pm
Has thanked: 129 times
Been thanked: 31 times

Sonarworks Headphone Calibration Software

Post by funkmuscle »

As many of us here are bedroom musicians meaning we all don't have pro studios to do our music so we're in our bedrooms, apartments, etc., shared with others so mixing with monitors is not always a first or good choice.

I came across this and wanted to know if we have anything like this for Linux?:
https://www.youtube.com/watch?v=mBUZpHwzgQ8
from:
https://www.sonarworks.com/headphones/trial

I personally live in a condo and even when watching a movie with home theatre on, jackass neighbours complain.
I've been using Bauer stereophonic to binaural as I read somewhere that when mixing with headphones, something like that is necessary.
CrocoDuck
Established Member
Posts: 1133
Joined: Sat May 05, 2012 6:12 pm
Been thanked: 17 times

Re: Sonarworks Headphone Calibration Software

Post by CrocoDuck »

I came across Sonarworks few days ago.

To my understanding (I just quickly glimpsed over their website) they have a database of headphone frequency responses. So, in few words, a headphone is like a filter: it has a frequency response. You can "undo" it by measuring it and creating a filter which is the exact specular of it: it will attenuate what the headphone boosts and boost what the headphone attenuates.

So, the chain would be: audio software -> matched inverse filter -> headphone. The combo matched inverse filter -> headphone yields, in theory, to perfectly flat frequency response.

Now, there are few caveats that make me skeptical about Sonarworks (and anything similar).

The main reason is the following: most likely they measured the responses using the B&K HATS. That is brilliant, as it has microphones inside that simulate the acoustic impedance of real ears. Now, you have your own ears instead. What is gonna change?

In the page you linked we can see a plot. That's a fairly typical headphone frequency response. All the stuff below 1 kHz is fairly stable and consistent between different measurement techniques. It is mostly dictated by speakers, front earcup volume, rear earcup volume, acoustic ports and cushions (yes, they define the acoustics too, and are very important). However, that is consistent as long as the fitting of the headphone doesn't vary too much. A earcup not properly sealed against the ear or head or a different clamping force can very significantly alter the low frequency (< 100 Hz). What you see after the first few kilohertz instead is dictated by your ear. The shape of your pinna and ear canal dictate what you see (and hear) there. That part of the response varies between every human being.

Another thing is that headphones have sometimes a lot of production variability.

So, I am not really sure about how well that works in reality really. Moreover, to make a good simulation, one would need to create a crossover based on head related transfer functions. I think there is already an open source library for that.

So, can we have that for Linux?

In a way, yes. The core idea is simple. However, to do it correctly there are two approaches (that I am aware of):

1) Have a database of many many responses of different headphones measured in the same conditions. Then average over to get the best estimate of the response of each model (compensating for sensitivity differences first). Then, just fit a trend after 4 kHz so that it will sort of work for everybody. I believe this is what Sonarworks is doing. But we can't: we don't have resources to build such a database (and you can see that even Sonarworks supports only a (not seemingly big) number of headphones).
2) Create an adaptive algorithm which aims to flatten out the final response. We must do it without a probe mic entering the ear of the user to get a reference signal... which is gonna make it super hard.

So, in few words: the idea is simple but headphone responses vary so much that I don't genuinely believe these calibrator really do work as advertised, even though perhaps they can improve things up to the first few kilohertz. To replicate something like that the best approach in open source world would be some kind of adaptive algorithm.

So, yeah... my two cents.

EDIT:
There is also a third way: the artisanal way. Measure the response of your personal headphone against a very crude ear simulator mic: a flat rigid surface with a hole in the middle where you insert the tip of maybe this mic, making sure that the hole is very well sealed. Blu tack is good for that. Then, to make the inverse filter you need just some maths... maybe not very easy math if you want low latency. If not, I think there are FIR filter programs that can do the filtering already. You will still have poor high frequency match, but you can increase it by replicating the ear canal length in the plate instead of just using a hole.
User avatar
funkmuscle
Established Member
Posts: 2800
Joined: Mon Jun 02, 2008 2:30 pm
Has thanked: 129 times
Been thanked: 31 times

Re: Sonarworks Headphone Calibration Software

Post by funkmuscle »

croc, thanx for the info.
so does this match up or help in anyway?
http://bs2b.sourceforge.net/
Also anything from Fons?
Also Sonarworks sells their own calibrated headphones. You think that could be a marketing gimmick?
CrocoDuck
Established Member
Posts: 1133
Joined: Sat May 05, 2012 6:12 pm
Been thanked: 17 times

Re: Sonarworks Headphone Calibration Software

Post by CrocoDuck »

funkmuscle wrote:croc, thanx for the info.
so does this match up or help in anyway?
http://bs2b.sourceforge.net/
Never heard of that before. From the description it looks like a digital implementation of analog filters designed to match crude models of Head Related Transfer Functions.

In few words, when the sounds gets from a source to your ears, the shape of your head and torso influences the frequency content that ends up impinging on your eardrums. Head and torso in fact diffract the sound, and this means that the sound arriving from a source to the two different ears is filtered by two different propagation paths. This is, by the way, one of the most important mechanism behind spatial localization of a sound source.

So, when you listen to stereo speakers, some right audio gets to your left ear, and some left audio gets to your right ear. Both of them filtered differently due to your head and torso shape. To simulate "using monitors" with headphones, one has to cross fade somewhat. There are few different methods.

1) Just do a simple cross fade.
2) Use filters that roughly approximate ideal Head Related Transfer Functions (HRTF) for normal listening positions.
3) Use the full ideal HRTFs.

Where ideal is either an average from measurements on humans or measured on something like the B&K HATS.

So, the stuff you linked should help for sure, but to recreate the spatiality of real speakers. It does nothing to "remove" the coloring effects of headphones on the sound.

I think that today it should be possible to go with full HRTFS: video games do it (it is the way spatial audio is implemented) (here there is an open source library).
CrocoDuck
Established Member
Posts: 1133
Joined: Sat May 05, 2012 6:12 pm
Been thanked: 17 times

Re: Sonarworks Headphone Calibration Software

Post by CrocoDuck »

funkmuscle wrote: Also anything from Fons?
Also Sonarworks sells their own calibrated headphones. You think that could be a marketing gimmick?
I don't know whether Fons did some work in this regards, but I would bet that there is something useful flouting around in his code.

As for calibrated headphones, it is hard to tell really. The only way would be to get one and measure its response on few different ears, through a probe microphone (for example this, yes, they are ludicrously expensive) and see how it looks. I really have 0 trust in what manufacturers declare.

However, calibrated headphones are a thing. They are used for listening tests, for example perceptual comparison of 2 headphone models. They are headphones with very very flat frequency response. Flatness is improved in the high end of the frequency response by use of absorption, usually. Those high frequency peaks are resonances and they can be flattened out by absorptive material.

Then, if 2 headphones are to be compared, their response is simulated digitally and used to filter (often not in realtime, but beforehand, to have very high accuracy) the program material sent to the calibrated headphones, so that the listeners don't know which is which and they are not biased by the look of the headphones. They will just switch between different program materials and rate the quality somehow.

The digital simulation of the headphones to be compared, in proper listening tests, is done starting by measurements with probe mics in the ears of the different test subjects, so they are actually very accurate: for each test subject only the responses measured on his/her ears are used for the simulation. Similarly, the calibrated headphones are measured against the ears of the test subjects and every unflatness is removed with an inverse filter tailored to the subject (yes, not even so called calibrated headphones are ideally flat on every head).

So, as you can see, flattish responses can be achieved, but ideal flatness has to be individually calibrated for each wearer. These are the cons of headphones: they are a device tightly coupled with the user, so the user anatomy and physiology end up influencing its behavior. Loudspeakers don't suffer from this, but somewhat similarly are influenced by different rooms.
Last edited by CrocoDuck on Sun Oct 08, 2017 8:53 pm, edited 1 time in total.
User avatar
funkmuscle
Established Member
Posts: 2800
Joined: Mon Jun 02, 2008 2:30 pm
Has thanked: 129 times
Been thanked: 31 times

Re: Sonarworks Headphone Calibration Software

Post by funkmuscle »

so by me sending them my headphones so they can calibrate it as one of Sonarworks suggestions, would not work because I would need to be present if I understand correctly?
I'm following most of what you're saying but I'd be stupid to not ask for clarification on certain things after all, only way to learn is by asking what you don't know. :D
CrocoDuck
Established Member
Posts: 1133
Joined: Sat May 05, 2012 6:12 pm
Been thanked: 17 times

Re: Sonarworks Headphone Calibration Software

Post by CrocoDuck »

funkmuscle wrote:so by me sending them my headphones so they can calibrate it as one of Sonarworks suggestions, would not work because I would need to be present if I understand correctly?
Yeah, I think so. If what they do is to collect the headphone response and transform it in an inverse filter (which totally looks like it is what they are doing, at least at the very core), the only proper way to correctly calibrate the headphone would be to measure its response on your ears (which in most cases are not equal, by the way), by using a probe microphone. Otherwise, the calibration will hold correctly only up to 2, maybe 3 kHz. Around 4 kHz you find the most important effect: ear canal resonance, so if the calibration is done on someone else ear or on some HATS, its reliability will start breaking down there for sure.

Now, it might as well be that the sound will feel more neutral anyway, maybe even significantly, but their claim that they can achieve ideal neutrality sounds way too far fetched to me. As I said, similar techniques to what they seem to be doing are used in pyschoacoustics experiments, where real neutrality is needed, but to work correctly a different calibration is done on each test subject.

I must confess that as of now, given the information they give on their website, I wouldn't buy their product: i would first want to see more about their methods and be sure to know its limits, so that I can do a well informed purchase.
User avatar
funkmuscle
Established Member
Posts: 2800
Joined: Mon Jun 02, 2008 2:30 pm
Has thanked: 129 times
Been thanked: 31 times

Re: Sonarworks Headphone Calibration Software

Post by funkmuscle »

thanx man!! you were very helpful!
User avatar
funkmuscle
Established Member
Posts: 2800
Joined: Mon Jun 02, 2008 2:30 pm
Has thanked: 129 times
Been thanked: 31 times

Re: Sonarworks Headphone Calibration Software

Post by funkmuscle »

dude I found something from zam-plugins called ZamHeadX2! (you'll need to scroll down to it)
http://www.zamaudio.com/?p=976

it's description:

Code: Select all

HRTF acoustic filtering plugin for directional sound.
CrocoDuck
Established Member
Posts: 1133
Joined: Sat May 05, 2012 6:12 pm
Been thanked: 17 times

Re: Sonarworks Headphone Calibration Software

Post by CrocoDuck »

Oh, now I remember where I saw one. I guess you could use that to do a pretty realistic cross fade.
User avatar
funkmuscle
Established Member
Posts: 2800
Joined: Mon Jun 02, 2008 2:30 pm
Has thanked: 129 times
Been thanked: 31 times

Re: Sonarworks Headphone Calibration Software

Post by funkmuscle »

CrocoDuck wrote:Oh, now I remember where I saw one. I guess you could use that to do a pretty realistic cross fade.
Sweet! Now I need to figure out how the heck to use it because I'm very new to this. If you do try it out man, let me know what you did and in the meantime I will try to figure it out too.
CrocoDuck
Established Member
Posts: 1133
Joined: Sat May 05, 2012 6:12 pm
Been thanked: 17 times

Re: Sonarworks Headphone Calibration Software

Post by CrocoDuck »

funkmuscle wrote:Sweet! Now I need to figure out how the heck to use it because I'm very new to this. If you do try it out man, let me know what you did and in the meantime I will try to figure it out too.
I played with it a tiny bit and I think it works like this:

HRTFs are functions of polar coordinates centered in the middle of the head. So, elevation should be the angle you use to locate a source vertically, measured from the horizon. Azimuth should be the angle you use to locate a source horizontally, measured from a vertical line just in front of you.

This is the recommended placement of stereo speakers, they are the level of your head.

So, I think the setup in this screenshot should be correct:

Image

Two instances of the plugins are running. One simulates the right speaker, the other the left speaker (ZamHeadX2 (2)). As such, only right audio goes into the right speaker HRTF simulation, and only left audio goes into the left speaker HRTF simulation (the source is Audacity (portaudio), just streaming a stereo song).
User avatar
funkmuscle
Established Member
Posts: 2800
Joined: Mon Jun 02, 2008 2:30 pm
Has thanked: 129 times
Been thanked: 31 times

Re: Sonarworks Headphone Calibration Software

Post by funkmuscle »

thanx croco.. I'll have to test with a commercial mix as I tried it connected to MixBus and it didn't sound good.. all the highs

EDIT: tried with Youtube.. the high freq are lethal on the ear drums using ZamHeadX2.. gonna stick with bs2b ladspa plugin. great for ear fatigue. I will just listen between headphones and monitors while mixing like I've been doing.
thanx again.
CrocoDuck
Established Member
Posts: 1133
Joined: Sat May 05, 2012 6:12 pm
Been thanked: 17 times

Re: Sonarworks Headphone Calibration Software

Post by CrocoDuck »

It didn't seem to me to have bad high frequency, but I didn't like it either. I felt like the sound was sort of glitchy and compressed. Not my cup of tea either, but perhaps it can be vastly improved.
User avatar
funkmuscle
Established Member
Posts: 2800
Joined: Mon Jun 02, 2008 2:30 pm
Has thanked: 129 times
Been thanked: 31 times

Re: Sonarworks Headphone Calibration Software

Post by funkmuscle »

CrocoDuck wrote:It didn't seem to me to have bad high frequency, but I didn't like it either. I felt like the sound was sort of glitchy and compressed. Not my cup of tea either, but perhaps it can be vastly improved.
Damien the dev himself said he didn't like it and work needs to be done on it.
Post Reply