Disentangling Dual-Encoder Masked Autoencoder for Respiratory Sound Classification

Peidong, Shiyu, Lin · 2025

Read Disentangling Dual-Encoder Masked Autoencoder for Respiratory Sound Classification by Peidong, Shiyu, Lin (2025) in the Tower of Babel, a free online library of public-domain works preserved in clean, searchable text. No sign-up. The full text is served as a plain-text file at a predictable URL, where text is present: https://antarctic-labs.com/tower-of-babel/arxiv-2506-10698.txt.

Introduction

Lung sounds carry clues about disease, but recordings are scarce and differ by stethoscope, clinic, and patient. Peidong Wei, Shiyu Miao, and Lin Li tackle that mess in a 2025 paper on sorting breathing sounds by computer. Their model learns from spectrograms, pictures of sound, with most of each picture hidden during training.

The design uses two encoders that split what they learn into disease-related signals and everything else. Keeping those streams apart should stop clinic-specific quirks from polluting the diagnosis. On a standard lung sound data set, the method reached scores that rival prior work. The authors aim for tools that travel well between hospitals, not just the one that recorded the training sounds.

Catalog record

CREATORPeidong, Shiyu, Lin
YEAR2025
COLLECTIONPAPERS
FORMATTXT
FILE SIZE20 KB
VERSION1.0
LICENSEhttp://creativecommons.org/licenses/by/4.0/
RIGHTSCC BY
SOURCEarXiv

Source: https://arxiv.org/abs/2506-10698

Browse the full library · About the Tower of Babel

Full text

The opening of the work, from the library's hosted text:

Disentangling Dual-Encoder Masked Autoencoder for Respiratory Sound Classification Peidong, Shiyu, Lin Abstract Deep neural networks have been applied to audio spectrograms for respiratory sound classification, but it remains challenging to achieve satisfactory performance due to the scarcity of available data. Moreover, domain mismatch may be introduced into the trained models as a result of the respiratory sound samples being collected from various electronic stethoscopes, patient demographics, and recording environments. To tackle this issue, we proposed a modified Masked Autoencoder (MAE) model, named Disentangling Dual-Encoder MAE (DDE-MAE) for respiratory sound classification. Two independent encoders were designed to capture disease-related and disease-irrelevant information separately, achieving feature disentanglement to reduce the domain mismatch. Our method achieves a competitive performance on the ICBHI dataset. Wei Miao Li* Xiamen UniversityChina keywords respiratory sound classification, ICBHI, feature disentanglement, masked autoencoder † † email: [email protected] 1 Introduction Respiratory sound classification is an essential task in the early detection and diagnosis of respiratory diseases. Accurate classification can assist healthcare professionals in identifying conditions such as asthma, bronchitis, and pneumonia from respiratory sounds [ 1 ] . However, several challenges arise due to the variability in recording conditions. Respiratory sound data are collected from different patients using various stethoscopes in diverse environments. This variability introduces significant domain mismatch problems [ 2 ] , making it difficult for models to generalize across different datasets [ 3 ] [ 4 ] . Furthermore, in real-world scenarios, respiratory sound data are often from unseen domains, and obtaining information about these specific domains is frequently impractical. This makes the challenge of domain adaptation even more difficult to address. Recently, numerous studies have attempted various methods to improve model performance. For instance, Audio Spectrogram Transformer with Patch-Mix and Contrastive Learning (AST + Patch-Mix CL) [ 5 ] employs a mix-based data augmentation method and establishes a corresponding contrastive learning approach to address the issue of data scarcity. The Multi-View Spectrogram Transformer (MVST) [ 6 ] adopts an ensemble approach that combines multiple models trained on different views of the data to achieve performance enhancement. Bridging Text and Sound Modalities (BTS) [ 7 ] is a multimodal approach, integrating textual information, such as patient demographics (age, gender) and stethoscope recording conditions, with audio data. Furthermore, some researchers have attempted to address domain adaptation by utilizing the classification labels of the stethoscope used during recording and incorporating these labels into domain adversarial [ 8 ] training methods [ 9 ] . Although it is helpful in improving performance, the approach still heavily depends on the availability of labeled information, which is often limited. For instance, the ICBHI dataset [ 10 ] includes only four types of stethoscopes, and relying on these limited labels restricts the model’s ability to generalize to new, unseen environments or stethoscope types. In this paper, we propose a novel self-supervised approach that does not require label information of domain (e.g., types of stethoscopes). The overall structure, the Disentangling Dual-Encoder Masked Autoencoder [ 11 ] (DDE-MAE) is shown in Fig. 1 , which leverages the power of self-supervised learning to disentangle disease-related features from disease-irrelevant features. Hence, our model can achieve effective domain adaptation without the need for extensive domain labels. Figure 1: Overview of Proposed DDE-MAE Our DDE-MAE model employs two independent encoders. The disease-related encoder captures features directly related to respiratory diseases. The disease-irrelevant encoder captures background and non-disease-related features by processing both the original spectrogram and a time-shuffled version of the spectrogram, using a Siamese loss to enforce feature invariance to temporal changes. Additionally, To ensure that the embeddings captured by the two encoders are independent, we employ the variational Contrastive Log-ratio Upper Bound (vCLUB) algorithm [ 12 ] to estimate and minimize the mutual information between the embeddings from the disease-related encoder and the disease-irrelevant encoder. Our contributions can be summarized as follows: • We introduce a dual-encoder architecture for respiratory sound classification that disentangles disease-related and disease-irrelevant information. • We propose a self-supervised learning approach that addresses domain adaptation without relying on domain information. • We demonstrate the effectiveness of our method on the ICBHI dataset, achieving a competitive performance and highlighting its potential for real-world applications. 2 Methodology 2.1 Overview of Proposed DDE-MAE Our proposed model, Disentangling Dual-Encoder MAE (DDE-MAE), leverages the principles of the Masked Autoencoder (MAE) architecture to address the domain adaptation challenges in respiratory sound classification. The MAE architecture typically consists of an encoder-decoder structure. The encoder processes the input spectrograms by masking a portion of the input and learning to represent the unmasked parts efficiently. The decoder reconstructs the masked parts from the encoded representations, ensuring that the encoder captures meaningful features of the input data [ 11 ] . To disentangle disease-related and disease-irrelevant information, we modify the MAE architecture to include two independent encoders: Disease-Related Encoder. This encoder (denoted as E_{r} ) captures features directly related to respiratory diseases by processing the input spectrograms without modifications. Disease-Irrelevant Encoder. This encoder (denoted as E_{i} ) captures background and non-disease-related features. It processes two inputs in parallel: the original spectrogram and a time-shuffled version. The time-shuffling process involves randomly shuffling the time axis of the spectrogram, disrupting temporal dependencies while preserving spectral content. A Siamese loss function [ 13 ] enforces similarity between the representations of the shuffled and original spectrograms, encouraging the encoder to focus on static features. The decoder architecture remains consistent with the original MAE design [ 11 ] , combining the outputs from both encoders to reconstruct the masked portions of the input spectrograms. This reconstruction ensures that the encoders learn complementary features that together capture the full information content of the input. 2.2 vCLUB Algorithm To ensure the embeddings captured by the two encoders, Z_{R} and Z_{I} , are independent, we utilize a mutual information (MI) [ 14 ] loss. Specifically, we employ the variational Contrastive Log-ratio Upper Bound (vCLUB) algorithm to estimate and minimize the mutual information between the embeddings from the disease-related encoder and the disease-irrelevant encoder. Mutual information is a measure of the dependence between two different variables A and B , formulated as: \mathcal{I}(A,B)=\int_{A}\int_{B}P(A,B)\log\frac{P(A,B)}{P(A)P(B)} (1) where P(A) and P(B) are the marginal distributions of A and B respectively, and P(A,B) denotes the joint distribution of A and B . Without the exact distribution functions of the variables, computing the precise value of mutual information is usually challenging. The vCLUB algorithm provides an efficient method to estimate the upper bound of mutual information, which can be used to minimize mutual information. For two different variables A and B , it is defined as: \displaystyle I(A,B)= \displaystyle\mathbb{E}_{p(A,B)}\left[\log q_{\theta}(B\mid A)\right] (2) \displaystyle-\mathbb{E}_{p(A)}\mathbb{E}_{p(B)}\left[\log q_{\theta}(B\mid A)\right] where q_{\theta}(B|A) is a variational distribution with parameter \theta to approximate p(B|A) . In DDE-MAE, the upper bound of MI between the disease-related representation Z_{R} and the disease-relevant representation Z_{I} is derived as: \displaystyle I(Z_{R},Z_{I})= \displaystyle\mathbb{E}_{p(Z_{R},Z_{I})}\left[\log q_{\theta}(Z_{I}\mid Z_{R})\right] (3) \displaystyle-\mathbb{E}_{p(Z_{R})}\mathbb{E}_{p(Z_{I})}\left[\log q_{\theta}(Z_{I}\mid Z_{R})\right] Then, the estimator for vCLUB with sample { z_{R_{i}},z_{I_{i}} } from { Z_{R},Z_{I} } is: \displaystyle L_{MI}(z_{R_{i}},z_{I_{i}}) \displaystyle=\frac{1}{N^{2}}\sum_{i=1}^{N}\sum_{j=1}^{N}\left[\log q_{\theta}\left(z_{I_{i}}\mid z_{R_{i}}\right)\right. \displaystyle\quad\left.-\log q_{\theta}\left(z_{I_{j}}\mid z_{R_{i}}\right)\right]. (4) 2.3 Training Procedure We fine-tune the Audio-MAE [ 15 ] model (MAE pretrained on AudioSet [ 16 ] ) in two stages: (i) Fine-Tuning for disentanglement: We duplicate the encoder to create the disease-related and disease-irrelevant encoders:

Read the complete text