Why use Chirplab - loudifier/chirplab GitHub Wiki

Why use Chirplab?

When there are many commercial audio measurement tool available on the market, and even free software readily available on the internet, in what situations does it make sense to use Chirplab instead of something that you are already familiar with?

You want a sanity check that your measurements are producing valid data

For users of any other measurement software

Most of Chirplab's measurement types can take a sample of the idle channel noise preceeding the chirp response signal and estimate the noise floor of that measurement. This helps you quickly assess whether low-level measurement levels, like distortion artifacts, are actually the signal that you want to measure, or just the noise floor of the system. See Measurement noise floor for a detailed explanation of the process and how it can be used.

You want complete control over the measurement process

For users of any other measurement software (unless you prefer to write your own analysis from scratch)

Chirplab is structured in a way to expose all of the meaningful details about how a measurement is calculated, and if anything is unclear you can inspect the source code to see every step. Further, if you want to tweak a measurement for your specific use case or create an entirely new measurement, you are free to do exactly that. See CLMeasurements for details on how to modify existing measurements or add new measurements to Chirplab.

You need fully open-loop processing or would like to process data offline

Primarily for users of Room EQ Wizard, sometimes AP, SoundCheck, or others

Most audio software has adapted to the modern realities of variable-latency and open-loop signal paths, but it is unfortunately still common to find that a particular measurement or even an entire audio analysis program expects to have full control over the signal path. All Chirplab measurements are open-loop native, using cross-correlation to detect and time-align the chirp signal in the captured response. This means you can take measurements live using a sound card for input and output, or from recorded audio files and get the exact same results. You can save recordings from a variety of test setups, distances, angles, etc. and easily batch process them later, or experiment with different measurements or measurement settings without having to set everything up and take a new measurement.

A benefit of Chirplab not being bound to any particular hardware setup and also being free and open source, is that it has full functionality on any device at any time. You do not need to be connected to an analyzer box to analyze chirp recordings, and there are no license dongles to manage or fees associated with running Chirplab on multiple computers.

You want to easily automate measurements and/or scale out cost-effectively

Primarily for users of Room EQ Wizard, or manufacturing tests using SoundCheck

Chirplab's command line interface is built directly into the main script/executable and uses the same plaintext project files as the GUI. There is no need to run a Chirplab server and write a client interface, or write a script or special program to make use of some sort of Chirplab API, just call the same main chirplab script or executable with the '-c' flag. This makes it very easy to scale up manufacturing tests for audio devices without incurring additional licencing fees for each additional test station, or needing to coordinate multiple test machines to send data to a central computer that does all of the processing.

If you do want to integrate Chirplab more deeply into your automated testing, first please consider working on improving Chirplab's CLI startup and processing times and contributing your updates back to the project. Then, if faster CLI startup does not solve your challenges, you should be able to look at the wiki pages describing the Chirplab code structure and use chirplab.py as a template for how to instantitate a project and measurements, update input data, and process and output measurement data.

You only want one specialized measurement from Chirplab

For users of AP, SoundCheck

If you have a preferred measurement system that you are happy with, but you would like to use a specialized or custom Chirplab measurement that your software doesn't support, there is a good chance that your software can use Chirplab for an external processing step.

  1. Create a Chirplab project file that includes the measurement that you would like to add to your audio software
  2. Generate a chirp stimulus file with Chirplab
  3. Import the stimulus file to your software
  4. Capture the DUT response using a generic signal capture or recording step
  5. Export the recording to an audio file on the host PC
  6. Configure your software to call Chirplab to measure the recorded audio file using the preconfigured project file
  7. You will most likely need an additional post processing step to convert the Chirplab output data to a format that is compatible to import to your software
  8. Import the Chirplab measurement output for any post processing, limit checking, graph formatting, etc.

To call Chirplab from an Audio Precision sequence, the projects for each program would look something like this

Calling Chirplab from AP

You insist on using open source software

For FOSS warriors

You design your speaker cabinets in FreeCAD, and touch up photos of them with GIMP (on your Arch Linux machine, of course). You refuse to use Room EQ Wizard because it is "free as in beer" but not "free as in speech". You are annoyed that Chirplab is hosted on GitHub instead of GitLab, but it will free you from trying to analyze audio measurements using custom Octave scripts.

When to not use Chirplab

Chirplab is not the only piece of audio analysis software that you will ever need.

You need professional support

I am enthusiastic about audio measurements, want to ensure that Chirplab is accurate, bug-free, and easy to use, and I am happy to chat about your particular needs. However, Chirplab is a hobby project provided as-is for free and I have a day job. I believe that Chirplab is usable for R&D and automated testing, and can be used for mission-critical applications like any other open source software - with your own knowledgable and capable dev team and the understanding that if something breaks you may need to fix it on your own. If you want audio software that is hardware-agnostic and has a price that scales (relatively) well for automated testing, but you also want dedicated support staff and guaranteed response times, Listen SoundCheck is probably a better fit.

You need to measure very low level or very high frequency electrical signals

Chirplab is designed to generate and receive audio signals using audio files or PC sound cards. While you could theoretically convert audio files to/from specialized equipment like an oscilloscope or DAQ, using software tools specifically made for that equipment will usually give you a better workflow with a more "native" experience.

When you need to characterize the performance of a high resolution DAC or ADC, even professional audio sound cards will likely not have high enough resolution and low enough noise to make accurate measurements, and even with a suitable interface you will probably need to manually calibrate voltage levels. If building or testing audio ADCs/DACs is part of your business charter, then you should have room in your capital expenditure budget for an Audio Precision analyzer, which will be much more capable and tailored for that task than any sound card and can still be augmented with Chirplab measurements, as mentioned above.

You are primarily interested in characterizing a speaker's electromechanical properties

Speaker modeling software usually needs to be tightly coupled to a calibrated hardware interface to accurately measure impedance and derive Thiele-Small parameters. There are many products purpose-built for this task ranging from Dayton DATS on the hobbyist end of the spectrum to Klippel laser systems suited for commercial R&D work at the other end. Chirplab may support basic versions of these types of measurements in the future (and you are free to implement them yourself, of course), but many of the more advanced measurements, like Klippel's nonlinear parameter modeling, require stimuli and analysis that are well outside the scope of Chirplab's focus.

However, Chirplab can still be used with other speaker measurement systems. You can use TS parameters measured with DATS, along with Frequency, Phase, and Impulse Response measurements from Chirplab to design and model a crossover with VituixCAD. Klippel software includes many advanced measurements and distortion analyses, but the range of measurements can be expanded even further by sending the raw laser excursion output signal to a sound card for analysis with Chirplab.

You are performing noise surveys or are looking for an RTA

The world of noise measurement is vast and generally outside Chirplab's scope of measuring the linear response and distortion of devices and transducers.

There is a large and healthy industry specializing in noise measurement for everything from architectural sound isolation to machinery noise emmisions regulations. If you are in industry and need to perform regulatory noise surveys, a company like NTi probably has a noise measurement solution for you, or if you are in R&D a microphone company like HB&K has everything from probe mics to sound-camera arrays.

If you need a free tool, Room EQ Wizard has a solid RTA with A and C weighted noise meters. If you need a free tool and want to measure noise in recorded audio files, SoX is a powerful (but sometimes obtuse) tool that can be adapted for specialized filtering and level metering. Audio editors like Audacity and full DAWs like REAPER include basic filtering and analysis tools that can be augmented with plugins. (Note that Audacity's spectrum analysis tool is functionally broken and should not be trusted)

You are primarily interested in characterizing or EQing a room response

Chirplab can be used to measure reflections and room responses, by recording past the end of the chirp response and increasing the post-sweep analysis time, but room response is not a primary focus for development. Chirplab is specialized for fine control over distortion analyses that are difficult or impossible to measure with other software, with the convenient side effect that many standard audio measurements can be easily derived "for free" from a fast logchirp capture.

Taking acoustic measurements in near field, time-gated, or true anechoic conditions allows you to characterize the response of the device under test while minimizing the effects of the test environment. Reading through Sean Olive and Floyd Toole's research at Harman into listners' perferences for speaker and headphone response, some conclusions stand out

  • Listeners prefer speakers that have an extended, flat on-axis response under anechoic conditions and controlled off-axis directivity
  • Further, listeners prefer those speakers regardless of the size and acoustic treatment of the room those speakers are in
  • Listeners prefer headphones that measure on HATS similarly to HATS responses of flat speakers in well-treated rooms, which corresponds to a slight downward tilt in the response from reverberation and a bump at low frequencies from room gain (and to some extent modern music preferences). This can be interpreted as the response of an average listening environment, erring on the side of smaller rooms with less reverb.

In essence, accurate reproduction in an anechoic environment translates to preferred reproduction in a reverberant environment.

Research in spatial audio (from industry experience - sorry I don't have any references on hand) shows that one of the most important factors in convincing spatial audio rendering for augmented reality is that the reverberation of the spatialized audio matches the size and reverberation of the room that the listener is in. Your eyes, ears, and brain understand your environment and have an expectation for how sound sources in that space "should" sound.

In light of these psychoacoustic effects, measuring the reverberant response of a room and generating an EQ curve to "correct" the response is a questionable practice. If your speakers already have a flat anechoic response then EQing to compensate for the room could cause the sound to deviate significantly from what your brain expects to hear in that room from a source at the speaker position. If you insist on EQing your room, please take measurements at several locations outside of the listening "sweet spot", use a light touch, and use Room EQ Wizard to take the measurements and generate your EQ curve, it is much better suited to the task.