What is machine listening?

Stephen M. Walker II · Co-Founder / CEO

What is machine listening?

Machine listening, closely related to audio signal processing and computational auditory scene analysis, refers to the use of computer algorithms and models to analyze and extract information from audio signals. This field has applications in various areas such as speech recognition, music information retrieval, noise reduction, and biomedical engineering.

Machine listening involves several stages:

  1. Data acquisition — The first step is capturing an audio signal using microphones or other sensors. This may be done in real-time (e.g., during a phone call) or offline (e.g., processing pre-recorded music files).
  2. Signal processing — The raw audio data is then transformed into more manageable representations that can be analyzed by machine learning algorithms. Common techniques include Fourier transforms, Mel-frequency cepstral coefficients (MFCCs), and spectrograms.
  3. Feature extraction — Next, relevant features are extracted from the processed signals to describe important aspects of the audio content (e.g., pitch, timbre, volume). These features may be computed using statistical methods or hand-engineered heuristics based on domain knowledge.
  4. Model training and inference — Finally, machine learning models are trained on labeled datasets containing examples of various types of audio signals (e.g., speech, music, environmental sounds). The trained models can then be used to classify new input data into different categories or predict specific attributes based on the learned patterns and relationships within the feature space.

Machine listening is an active area of research with ongoing developments in algorithmic techniques, hardware capabilities, and application domains. Some popular tools for working with audio signals include libraries like Librosa (Python), MIR Toolbox (Matlab), and TarsosDSP (Java).

What are some common machine listening tasks in AI?

Building on that foundation, several concrete tasks make up most machine listening applications, spanning domains such as speech recognition, music information retrieval, environmental sound classification, and bioacoustics. Here are some common machine learning tasks related to machine listening in AI:

  1. Speech recognition — This task aims to transcribe spoken words into text by identifying individual phonemes (smallest units of sound) and assembling them into meaningful words or sentences. Techniques for speech recognition include hidden Markov models, dynamic time warping, and deep neural networks.
  2. Audio classification — This involves categorizing different types of audio signals based on their characteristics (e.g., musical instruments, environmental sounds). Machine learning algorithms can be trained to identify patterns in spectrograms or other feature representations of the audio data, enabling accurate classification.
  3. Speaker identification and verification — These tasks involve determining whether a given voice sample belongs to a specific individual (identification) or confirming that it does indeed belong to that person (verification). Common techniques include i-vector extraction, probabilistic linear discriminant analysis (PLDA), and deep neural networks.
  4. Audio event detection — This task focuses on identifying specific events within an audio stream, such as the occurrence of a particular musical note or the presence of certain environmental sounds like footsteps or car horns. Machine learning models can be trained to recognize these events by learning their characteristic spectral and temporal patterns.
  5. Music information retrieval — This field encompasses various tasks related to analyzing, organizing, and accessing music content using computational methods. Examples include genre classification, mood detection, melody extraction, and chord estimation. These tasks often require the use of specialized feature representations like MFCCs or chromagrams.
  6. Audio synthesis — This involves generating artificial audio signals that mimic real-world sounds or music compositions. Techniques for audio synthesis include physical modeling synthesis (e.g., digital waveguide synthesis), subtractive synthesis, and granular synthesis.
  7. Noise reduction — This task aims to improve the quality of an audio signal by reducing unwanted background noise or interference. Methods for noise reduction include spectral subtraction, Wiener filtering, and adaptive filters.

These are just a few examples of common machine listening tasks in AI. As research progresses and hardware capabilities continue to advance, we can expect even more innovative applications and techniques to emerge within this field.

What are some common features used in machine listening?

To effectively process and understand audio signals, researchers extract relevant features that capture different characteristics of the sound data. Some common features used in machine listening include:

  1. Fourier transforms — This is a widely-used technique for converting time-domain signals into their frequency-domain counterparts (e.g., spectrograms). Spectral information can provide valuable insights into the composition and structure of complex audio signals, such as music or speech.
  2. Mel-frequency cepstral coefficients (MFCCs) — These are a set of features commonly used in speech recognition tasks. MFCCs capture the spectral envelope of an audio signal by applying a Mel-scale filter bank followed by a discrete cosine transform (DCT). This representation is particularly useful for modeling phonetic properties and distinguishing between different spoken words or languages.
  3. Chromagrams — These are spectrogram representations that focus on the tonal content of an audio signal, specifically its harmonic structure. Chromagrams can be computed using various techniques like pitch detection algorithms (e.g., YIN) or phase-vocoder-based methods (e.g., constant-Q transform). They are often used in music information retrieval tasks such as melody extraction and chord estimation.
  4. Zero-crossing rate — This feature measures the number of times a signal changes its sign within a given time window, which can be indicative of different types of sounds (e.g., speech vs. music). Zero-crossing rates are commonly used in audio event detection tasks for identifying specific sound events like footsteps or car horns.
  5. Energy and power spectral density — These features provide information about the overall intensity and distribution of energy across different frequency bands within an audio signal. They can be computed using various techniques such as windowed Fourier transforms or short-time Fourier transforms (STFT). Energy and power spectral density are often used in noise reduction tasks for filtering out unwanted background noise.
  6. Cepstral coefficients — These are a set of features derived from the cepstrum, which is the inverse Fourier transform of the logarithm of the power spectral density. Cepstral coefficients can capture various aspects of an audio signal's spectral envelope, including its formant structure and pitch characteristics. They are commonly used in speaker identification and verification tasks.
  7. Entropy-based features — These features measure the degree of randomness or uncertainty within an audio signal, often using statistical techniques like entropy estimation or Kurtosis calculation. Entropy-based features can be useful for distinguishing between different types of sounds (e.g., speech vs. music) and identifying specific sound events in noisy environments.
  8. Linear predictive coding (LPC) coefficients — These are a set of parameters that model the spectral envelope of an audio signal using an all-pole filter. LPC coefficients can capture various aspects of a signal's formant structure and have been widely used in speech recognition tasks, particularly for low-complexity applications like telecommunication systems.

These features represent just a few examples of the many techniques used in machine listening to analyze and understand complex audio signals. The choice of features depends on the specific application or task at hand, as well as the quality and characteristics of the input data.

What are some common evaluation metrics for machine listening?

There are several evaluation metrics used to measure the performance of machine listening systems, many of them specific to the audio domain:

  1. Word error rate (WER) — Used to evaluate speech recognition systems, WER measures the number of insertions, deletions, and substitutions needed to turn a system's transcript into the reference transcript, divided by the number of words in the reference. Lower WER indicates a more accurate transcription.
  2. Perceptual evaluation of speech quality (PESQ) — A standardized metric that compares a processed or transmitted speech signal against a clean reference to estimate perceived audio quality, commonly used to evaluate noise reduction and codec performance.
  3. Short-time objective intelligibility (STOI) — A metric that estimates how intelligible a degraded or enhanced speech signal is compared to a clean reference, often used alongside PESQ when evaluating speech enhancement algorithms.
  4. Equal error rate (EER) — Used in speaker verification and identification tasks, EER is the point at which the false acceptance rate and false rejection rate are equal. A lower EER indicates a more accurate verification system.
  5. Accuracy, precision, recall, and F1 score — These general classification metrics are still applied to tasks like audio event detection and audio classification, measuring how well a system's predicted labels match the true labels.
  6. Signal-to-noise ratio (SNR) — Used in noise reduction and speech enhancement tasks, SNR compares the level of the desired audio signal to the level of background noise, with higher values indicating cleaner audio.

These metrics provide a useful way to compare the performance of different machine listening systems across tasks and domains, and the appropriate metric depends on the specific application being evaluated.

More terms

Continue exploring the glossary.

Learn how teams define, measure, and improve LLM systems.

Glossary term

What is declarative programming?

Declarative programming is a high-level programming concept that abstracts away the control flow for logic required for software to perform an action. Instead of specifying how to achieve a task, it states what the task or desired outcome is. This is in contrast to imperative programming, which focuses on the step-by-step process to achieve a result.
Read term

Glossary term

What is Argument Mining?

Argument mining, also known as argumentation mining, is a research area within the field of natural language processing (NLP). Its primary goal is the automatic extraction and identification of argumentative structures from natural language text. These argumentative structures include the premise, conclusions, the argument scheme, and the relationship between the main and subsidiary argument, or the main and counter-argument within discourse.
Read term

It's time to build

Collaborate with your team on reliable Generative AI features.
Want expert guidance? Book a 1:1 onboarding session from your dashboard.

Talk to sales