Earphone adaptive noise reduction curve adjusting method and system
By obtaining an individual ear canal transfer function model through adaptive test signal generation and multi-stage signal-to-noise ratio enhancement technology, and combining hierarchical scene recognition and multi-sensor fusion methods, the problem of traditional active noise-canceling headphones being unable to adapt to individual ear canal differences and changes in wearing status is solved, achieving stable noise cancellation effect and smooth parameter updates, thus improving the user experience.
Patent Information
- Application Number
- CN202611260911.7
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2026-08-19
- Publication Date
- 2026-11-03
AI Technical Summary
Traditional active noise-canceling headphones cannot adapt to individual differences in ear canals and changes in wearing conditions, resulting in unstable noise cancellation effects. Furthermore, parameter updates introduce transient noise, affecting the user experience.
Adaptive test signal generation and multi-stage signal-to-noise ratio enhancement techniques are used to obtain the individual ear canal transfer function model. Combined with hierarchical scene recognition and multi-sensor fusion methods, the wearing status is evaluated in real time. The noise reduction curve is quickly adjusted through parameter library indexing and local optimization. An adaptive transition window and smooth interpolation mechanism are introduced to achieve smooth parameter transition.
It achieves stable noise reduction performance under different usage conditions, avoids transient noise and sound quality fluctuations, and improves the continuity and comfort of the user experience.
Smart Images

Figure CN123035403A_ABST
Abstract
Description
Technical Field
[0001] This invention relates to the field of audio signal processing technology, and more specifically, to a method and system for adjusting the adaptive noise reduction curve of headphones. Background Technology
[0002] Active noise-canceling headphones work by collecting ambient noise and generating anti-phase sound waves to cancel it out, providing users with a quiet listening environment. Traditional active noise-canceling headphones use fixed noise cancellation curve parameters, which are optimized during the product design phase based on a standard ear canal model and ideal wearing conditions. However, different users have individual differences in ear canal shape, size, and acoustic characteristics, and the wearing conditions of the same user may also change at different times, causing fixed parameters to be unsuitable for actual use.
[0003] The main problems with existing technologies include: First, fixed noise cancellation parameters cannot match individual ear canal differences. When the user's ear canal transfer function deviates from the standard model, the noise cancellation effect decreases significantly, especially in the low-frequency range where insufficient noise cancellation depth or the introduction of additional noise is common. Second, changes in wearing status cause fluctuations in noise cancellation performance. When users walk, exercise, or adjust the headphone position, the seal and fit change, increasing leakage and degrading the noise cancellation effect, but the system cannot detect and compensate for these changes. Third, parameter updates lack a smooth transition mechanism. Even if the system can detect changes in status and adjust parameters, sudden parameter switching can introduce transient noise and sound quality fluctuations, affecting the user experience.
[0004] Therefore, a method is needed that can adaptively adjust the noise cancellation curve parameters according to individual ear canal characteristics and real-time wearing status, so as to achieve a smooth transition of parameters while ensuring noise cancellation performance, thereby improving the stability and user experience of active noise-canceling headphones in actual use. Summary of the Invention
[0005] This invention provides a method and system for adjusting the adaptive noise reduction curve of headphones, which solves the technical problems in related technologies where fixed noise reduction parameters cannot adapt to individual differences in the ear canal and changes in wearing status, resulting in unstable noise reduction performance and the introduction of transient noise during parameter updates.
[0006] This invention provides a method for adjusting the adaptive noise reduction curve of headphones, comprising the following steps: S1. Based on environmental noise perception and multi-stage signal-to-noise ratio enhancement, an individual ear canal transfer function model is obtained by adaptive test signal generation and coherent averaging processing. S2, collect sensor data and obtain the individual ear canal transfer function model, and use hierarchical scene recognition and adaptive weight fusion method to obtain real-time wearing status evaluation results; S3 receives the individual ear canal transfer function model and real-time wearing status evaluation results, and uses parameter library indexing and local optimization methods to obtain the noise reduction curve parameters that are quickly and adaptively adjusted. S4: Receive the noise reduction curve parameters and parameter update trigger flag, and use an adaptive transition window and smooth interpolation method to obtain the noise reduction curve parameters after smooth transition; S5 acquires the noise reduction curve parameters after a smooth transition, and uses hybrid active noise reduction processing and audio equalization to obtain a low-noise environment in the ear canal and high-fidelity audio output.
[0007] In a preferred embodiment, S1 includes: Environmental noise samples were collected using a feedforward microphone, and the noise power spectral density distribution was analyzed using fast Fourier transform to obtain the noise energy characteristics of each frequency band. Based on noise energy characteristics, low-noise and high-noise frequency bands are identified. A spectrum notch detection algorithm is used to mark the preferred frequency points of the test signal, resulting in an adaptive test frequency point distribution scheme. Based on the adaptive test frequency point distribution scheme, a multi-tone test signal is generated. The test signal is emitted by a loudspeaker while the in-ear microphone and feedback microphone simultaneously collect the response signal, resulting in a noisy response signal. Based on the noisy response signal, coherent averaging technique is used to repeatedly measure multiple times, and adaptive noise cancellation and frequency domain selective enhancement are employed to obtain a clean response signal with high signal-to-noise ratio. Based on a high signal-to-noise ratio pure response signal and a known test signal, the transfer function at each test frequency point is calculated using the frequency domain ratio method. Conformal interpolation is then used to extend it into a full-band transfer function model, resulting in an ear canal transfer function model that includes the amplitude frequency response curve, phase frequency response curve, and measurement confidence level.
[0008] In a preferred embodiment, S2 includes: Low-frequency gain features are extracted based on the ear canal transfer function model, and acoustic sealing score is calculated using a gain mapping model to obtain a quantitative index of sealing quality. Based on the pressure sensor array, the contact pressure distribution is measured, and the pressure uniformity and total pressure are calculated by statistical analysis to obtain the physical bonding stability index. Based on the measurement of headphone motion signals using a triaxial accelerometer, time-frequency feature extraction and pattern recognition are employed to obtain the usage scenario type identifier; Based on the energy difference of noise signals between the feedforward microphone and the in-ear microphone, the energy ratio method is used to quantify the leakage degree and obtain a quantitative estimate of the leakage rate. Based on scene type identification and sensor data reliability analysis, a hierarchical weight configuration and dynamic adjustment strategy is adopted to obtain scene-adaptive sensor fusion weights; based on sealing score, fit stability score and leakage rate, scene-adaptive weights are used for weighted fusion to obtain a comprehensive wearing status evaluation result.
[0009] In a preferred embodiment, S3 includes: Feature parameters are extracted based on the ear canal transfer function model, and state parameters are extracted based on the wearing state evaluation results. These are combined to form a parameter library index key. Based on the index key of the parameter library, matching entries are retrieved in the noise reduction curve parameter library, and the nearest neighbor search algorithm is used to obtain the initial noise reduction curve parameters; Based on the initial noise reduction curve parameters and the ear canal transfer function model, a local gradient optimization algorithm is used to obtain finely optimized noise reduction curve parameters. Based on the quantitative value of leakage rate, compensation parameters are retrieved from the leakage compensation parameter library, and the parameter superposition method is used to obtain the noise reduction curve parameters after leakage compensation. Based on the measurement confidence distribution, the noise reduction parameters in the low confidence band are conservatively adjusted, and a parameter attenuation strategy is adopted to obtain noise reduction curve parameters with enhanced reliability. Based on the comparison between the noise reduction curve parameters enhanced by reliability and the currently used parameters, the parameter update trigger flag is obtained by using difference evaluation and threshold judgment.
[0010] In a preferred embodiment, S4 includes: The parameter update process is initiated based on the parameter update trigger flag, and the parameter change magnitude is calculated based on the parameter difference vector to obtain the update process control signal. Based on the parameter change amplitude and the wearing status change rate, an adaptive window length calculation algorithm is used to obtain the transition window length parameter; A parameter transition sequence is generated based on the transition window length parameter, and a smooth transition is achieved by using the cosine interpolation method to obtain the transition parameter sequence for each frame. The transition parameter sequence of each frame is applied frame by frame in the noise reduction process, and the output signal quality is monitored at the same time to obtain the application status of the noise reduction curve parameters after smooth transition is completed. Based on the detection results of sudden changes in wearing status, it is determined whether to activate the emergency response. A fast transition channel is used to achieve rapid parameter switching, so as to obtain a noise reduction curve that adapts quickly in emergency scenarios.
[0011] In a preferred embodiment, S5 includes: Based on the feedforward filter coefficients in the current noise reduction curve parameters, the environmental noise signal collected by the feedforward microphone is filtered to obtain the feedforward anti-noise signal. Based on the feedback filter coefficients in the current noise reduction curve parameters, the in-ear noise signal collected by the feedback microphone is filtered to obtain the feedback anti-noise signal. Based on the hybrid gain coefficient in the current noise reduction curve parameters, the feedforward and feedback noise immunity signals are weighted and mixed to obtain a hybrid noise immunity signal. The mixed noise-resistant signal is pre-compensated and filtered based on the secondary channel transfer function to obtain the compensated noise-resistant signal; Personalized equalization processing of audio source signals is performed based on the ear canal transfer function model to obtain equalized audio signals. The compensated noise-resistant signal is mixed and superimposed with the equalized audio signal, and then played through a digital-to-analog converter and a speaker to obtain a low-noise environment and high-fidelity audio effect in the ear canal.
[0012] In a preferred embodiment, the step of identifying low-noise and high-noise frequency bands based on noise energy characteristics, marking preferred frequency points of the test signal using a spectral notch detection algorithm, and obtaining an adaptive test frequency point distribution scheme includes: The average noise energy across the entire frequency band is calculated as a benchmark. The noise energy of each frequency band is compared with the benchmark value. Frequency bands with noise energy lower than the benchmark value by a preset first percentage are marked as low noise frequency bands, and frequency bands with noise energy higher than the benchmark value by a preset second percentage are marked as high noise frequency bands. The local minimum points of the power spectral density curve are calculated using a spectral depression detection algorithm, and the detected spectral depression locations are used as the preferred frequency points of the test signal. Generate a complete test frequency distribution scheme, which includes preferred frequency points in the low-noise frequency band and necessary frequency points in the high-noise frequency band. The total number of test frequency points is set to a preset first quantity range, covering a preset frequency range. The test signal amplitude is assigned to each test frequency point. The standard amplitude is used in the low noise frequency band, and the boosted amplitude is used in the high noise frequency band. The amplitude boost ratio is calculated based on the noise energy and the target signal-to-noise ratio.
[0013] In a preferred embodiment, the step of obtaining scene-adaptive sensor fusion weights based on scene type identification and sensor data reliability analysis, using a hierarchical weight configuration and dynamic adjustment strategy, includes: Based on the scene type identifier, the corresponding sensor fusion weight configuration is retrieved from the preset scene parameter library. The scene parameter library contains the basic weight values of acoustic sensors, pressure sensors and acceleration sensors under various scene types. The consistency and quality indicators of the data from each sensor are analyzed. Consistency is measured by the correlation of evaluation results from different sensors, and quality indicators are measured by the signal-to-noise ratio or confidence level of the sensor signals. Increase the weight of sensors with high consistency and good quality, and decrease the weight of sensors with conflicting indications or poor quality. After weight adjustment, normalization is performed to ensure that the sum of all sensor weights is a preset value, thus obtaining scene-adaptive sensor fusion weights.
[0014] In a preferred embodiment, the step of obtaining finely optimized noise reduction curve parameters based on the initial noise reduction curve parameters and the ear canal transfer function model using a local gradient optimization algorithm includes: A noise reduction performance evaluation model is established. The input of the model is the noise reduction curve parameters and the ear canal transfer function. The output is the noise reduction depth evaluation value. The noise reduction depth is obtained by simulating the residual noise energy in the ear canal. Establish an optimization objective function, where the objective function is the negative noise reduction depth, and the optimization objective is to minimize the objective function. Establish constraints, including system stability constraints, intraocular sound pressure level constraints, and frequency response flatness constraints; Constrained gradient descent algorithm is used for local optimization. Gradient descent calculates the gradient of the objective function with respect to each parameter and updates the parameters along the negative gradient direction to reduce the value of the objective function. Iteratively perform gradient calculation, parameter update, and constraint projection until the objective function converges or reaches the preset maximum number of iterations, to obtain finely optimized noise reduction curve parameters.
[0015] In a preferred embodiment, a headphone adaptive noise cancellation curve adjustment system is used to perform the steps of the above-described headphone adaptive noise cancellation curve adjustment method, including: Feedforward microphone module, feedback microphone module, in-ear microphone module, pressure sensor array module, accelerometer module, digital signal processor module, speaker module, and memory module; The feedforward microphone module is deployed on the outside of the earphone to collect ambient noise signals; The feedback microphone module and the in-ear microphone module are deployed inside the earphone near the ear canal to collect sound signals from inside the ear canal; A pressure sensor array module is deployed at the contact point between the earbud and the ear canal to measure the contact pressure distribution. An accelerometer module is deployed on the main body of the earphone to detect the earphone's motion. The digital signal processor module serves as the core computing unit, executing signal processing, parameter optimization, and noise reduction control algorithms. The speaker module is used to play noise-resistant signals and audio signals; The memory module is used to store the noise reduction curve parameter library, ear canal transfer function model, and algorithm program.
[0016] The beneficial effects of this invention are as follows: By acquiring an individual ear canal transfer function model through adaptive test signal generation and multi-stage signal-to-noise ratio enhancement technology, the acoustic characteristics of the user's ear canal can be accurately characterized, providing precise and personalized basis for noise reduction parameter optimization. Combined with a hierarchical scene recognition and multi-sensor fusion wearing status assessment method, the system can perceive changes in seal, fit stability, and leakage level in real time, dynamically adjusting sensor weights according to different usage scenarios. This improves the accuracy and reliability of status assessment, enabling the noise reduction curve parameters to respond promptly to individual differences and wearing variations, maintaining stable noise reduction performance under various practical usage conditions. A rapid adaptive adjustment method combining parameter library indexing and local optimization is employed. Initial parameters are quickly obtained from a pre-established noise reduction curve parameter library, and then refined parameters are obtained through local gradient optimization, avoiding the computational burden of global optimization and achieving rapid response. Simultaneously, an adaptive transition window and a smooth transition mechanism using cosine interpolation are introduced to dynamically adjust the transition time based on the magnitude of parameter changes and the rate of change in wearing status. This ensures timely parameter updates while eliminating transient noise and sound quality fluctuations, improving the continuity and comfort of the user's auditory experience. Attached Figure Description
[0017] Figure 1 This is a flowchart of a headphone adaptive noise reduction curve adjustment method according to the present invention; Figure 2 This is a block diagram of an adaptive noise reduction curve adjustment system for headphones according to the present invention. Detailed Implementation
[0018] The subject matter described herein will now be discussed with reference to exemplary embodiments. It should be understood that these embodiments are discussed only to enable those skilled in the art to better understand and implement the subject matter described herein, and changes may be made to the function and arrangement of the elements discussed without departing from the scope of this specification. Various processes or components may be omitted, substituted, or added as needed in the examples. Furthermore, some features described in the examples may be combined in other examples.
[0019] At least one embodiment of the present invention discloses a method for adjusting the adaptive noise reduction curve of headphones, such as... Figure 1 As shown, it includes the following steps: S1. Based on environmental noise perception and multi-stage signal-to-noise ratio enhancement, an individual ear canal transfer function model is obtained by adaptive test signal generation and coherent averaging processing. S11: Based on the collection of environmental noise samples by the feedforward microphone, the noise power spectral density distribution is analyzed by fast Fourier transform to obtain the noise energy characteristics of each frequency band; The digital signal processor module controls the feedforward microphone module to acquire noise samples from the current environment. The acquisition time is set to 2 seconds to obtain statistically stable noise characteristics. The acquired noise signal is a discrete-time signal with a sampling rate of 48000Hz, and each sampling point is represented by 16 bits of data. A Fast Fourier Transform (FFT) is performed on the acquired noise time-domain signal to convert it into a frequency-domain representation. The FFT uses a radix-2 algorithm, and the number of transformation points is set to 4096 to obtain sufficient frequency resolution. The frequency resolution is calculated by dividing the sampling rate by the number of transformation points; in this embodiment, the frequency resolution is approximately 11.7Hz. The spectrum of the noise signal is obtained after the transformation, and the spectrum contains the amplitude and phase information of each frequency component. The power spectral density (PSD) of the noise signal is calculated. The PSD is equal to the square of the spectral amplitude, and the unit is power divided by the frequency bandwidth. The PSD is smoothed by using a moving average filter to average the PSD values of adjacent frequency points. The smoothing window width is set to 5 to 10 frequency points to suppress random fluctuations in the PSD estimation. A smoothed noise power spectral density distribution curve is obtained, which describes the energy distribution characteristics of environmental noise in different frequency bands. The power spectral density distribution curve is then divided into frequency bands, with the entire frequency band from 20Hz to 20000Hz divided into multiple sub-bands using logarithmic intervals to obtain higher frequency resolution in the low-frequency range. The average power spectral density value of each sub-band is calculated as the noise energy characteristic of that band.
[0020] S12, based on noise energy characteristics, identify low-noise frequency bands and high-noise frequency bands, use the spectrum notch detection algorithm to mark the preferred frequency points of the test signal, and obtain an adaptive test frequency point distribution scheme; The digital signal processor module analyzes the noise energy characteristics of each frequency band obtained by S11 and calculates the average noise energy across the entire frequency band as a benchmark. The noise energy of each frequency band is compared with the benchmark value. Frequency bands with noise energy below 80% of the benchmark value are marked as low-noise bands, those above 120% are marked as high-noise bands, and those in between are marked as medium-noise bands. Low-noise bands have less noise interference, and test signals can easily achieve a high signal-to-noise ratio in these bands; therefore, low-noise bands are preferentially selected as test frequencies for transfer function measurement. A spectral depression detection algorithm is used to further refine the selection of frequency points in the low-noise bands. Spectral depression detection calculates the local minimum points of the power spectral density curve; these local minimums correspond to the depression locations of noise energy. By calculating the first derivative of the power spectral density, the position where the derivative sign changes from negative to positive corresponds to the local minimum. The detected spectral depression locations are selected as the preferred frequency points for the test signal, as these frequencies have the lowest noise energy and the highest signal-to-noise ratio. For high-noise frequency bands, especially the low-frequency traffic noise concentration band from 100Hz to 500Hz, although the noise energy is high, this band has a critical impact on the noise reduction effect, and transfer function measurements must be performed. When selecting test frequency points in the high-noise band, a uniform interval distribution is used to cover the entire band, with the interval set to 30Hz to 50Hz. A complete test frequency point distribution scheme is generated, including preferred frequency points in the low-noise band and necessary frequency points in the high-noise band. The total number of test frequency points is set to 50 to 80, covering the range of human ear-sensitive frequencies from 20Hz to 20000Hz. Test signal amplitudes are assigned to each test frequency point; standard amplitude is used in the low-noise band, and boosted amplitude is used in the high-noise band. The amplitude boost ratio is calculated based on the noise energy and the target signal-to-noise ratio (SNR), which is set to 20 dB to 30 dB. The SNR is defined as the ratio of the test signal power to the noise power. The calculation formula is that the boost ratio equals the ratio of the noise power to the standard signal power multiplied by the linear value corresponding to the target SNR.
[0021] S13, generate multi-tone test signals based on adaptive test frequency distribution scheme, use loudspeaker to transmit test signals while in-ear microphone and feedback microphone synchronously collect response signals to obtain noisy response signals; The digital signal processor module generates a multi-tone test signal based on the test frequency distribution scheme obtained in S12. The multi-tone test signal is a composite signal containing multiple sine waves of different frequencies, with each test frequency corresponding to a sine wave component. The amplitude of the sine wave corresponding to each frequency point is set according to the amplitude value allocated in S12, and the phase uses random or optimized phase to reduce the peak-to-average power ratio (PAPR). The sine wave components of each frequency point are time-domain superimposed to generate a complete multi-tone test signal. The duration of the multi-tone test signal is set to 0.5 to 1 second; the duration needs to be long enough to ensure the spectral resolution of each frequency component, but not too long to avoid measurement delay. The generated digital multi-tone test signal is converted into an analog signal by a digital-to-analog converter (DAC), with a sampling rate of 48000 Hz and a bit depth of 16 bits. The analog test signal is amplified to a suitable sound pressure level by a power amplifier. The sound pressure level setting needs to consider the audibility of the test signal and user comfort, typically set to 60 to 80 dB. The speaker module is controlled to play the amplified test signal. After being emitted from the speaker, the test signal propagates within the earphone acoustic cavity, passing through the ear canal and reflecting. The in-ear microphone module and the feedback microphone module synchronously acquire the response signal of the test signal after it has traveled through the acoustic path. Synchronous acquisition is ensured by a unified sampling clock, provided by the digital signal processor module, ensuring precise time alignment between speaker playback and microphone acquisition. The in-ear microphone, located deep within the ear canal, acquires a response signal containing the component of the test signal after it has traveled through the entire ear canal. The feedback microphone, located inside the earphone cavity, acquires a response signal containing the component of the test signal after it has traveled through a portion of the acoustic path. The acquired response signal is an analog signal, converted to a digital signal by an analog-to-digital converter (ADC). The ADC sampling rate is consistent with the digital-to-analog converter (DAC) sampling rate, both being 48000Hz. The acquired response signal contains not only the test signal component but also ambient noise components, thus it is a noisy response signal. Ambient noise superimposed on the test signal in both the time and frequency domains affects the accuracy of subsequent transfer function estimation.
[0022] S14, based on the noisy response signal, the coherent averaging technique is used to repeatedly measure multiple times, and adaptive noise cancellation and frequency domain selective enhancement are used to obtain a clean response signal with high signal-to-noise ratio; The digital signal processor module performs multi-stage signal-to-noise ratio (SNR) enhancement processing on the noisy response signal obtained by S13. The first stage uses coherent averaging to improve the SNR. Coherent averaging is based on the determinism of the test signal and the randomness of noise, repeatedly transmitting the same test signal multiple times and acquiring the response signal each time. The number of repetitions is set to 5 to 10 times; the more repetitions, the more significant the SNR improvement, but the measurement time also increases accordingly. The multiple acquired response signals are aligned and averaged in the time domain. Time-domain alignment involves detecting the starting position of each response signal, using a cross-correlation algorithm to calculate the time delay between each signal and the reference signal, and compensating for the time shift based on the delay. The aligned multiple response signals are then averaged point-by-point. In the averaged signal, the amplitude of the test signal component is maintained due to coherence, while the noise components cancel each other out due to randomness. The SNR improvement after coherent averaging is a multiple of the square root of the number of repetitions; for example, 10 repetitions can achieve an approximately 3.16-fold SNR improvement. The second stage uses adaptive noise cancellation to further improve the SNR. Adaptive noise cancellation uses the ambient noise signal collected by the feedforward microphone as reference noise. An adaptive filter is used to filter the reference noise, making the filtered output approximate the noise components in the response signal. A minimum mean square error adaptive algorithm is employed, which iteratively adjusts the filter coefficients to minimize the mean square value of the difference between the response signal and the filtered output. During the iteration process, the filter coefficients gradually converge to the optimal value, and the output of the optimal filter is the best estimate of the noise components. The noise estimate is subtracted from the response signal to obtain the noise-suppressed signal. Adaptive noise cancellation can suppress noise components related to the reference noise, but its effect on unrelated noise components is limited. The third stage uses frequency-domain selective enhancement to further extract the clean response signal. A fast Fourier transform is performed on the signal processed in the first two stages to convert the signal to the frequency domain. Selective processing is performed on each frequency component in the frequency domain. The frequency components corresponding to the test frequency points are preserved and amplified, with the amplification factor set to 2 to 5 times to enhance the test signal components. Frequency components corresponding to non-test frequency points are suppressed or zeroed out; these frequency components are mainly residual noise, and the suppression ratio is set to 80% to 100%. Selective enhancement is achieved through a frequency-domain mask, which is a frequency-domain filter. The gain is greater than 1 at the test frequency and less than 1 or 0 at non-test frequencies. The frequency-selectively enhanced signal is then converted back to the time domain using an inverse fast Fourier transform to obtain a clean response signal with a high signal-to-noise ratio. In this signal, the test signal component dominates, while noise components are significantly suppressed, typically achieving a signal-to-noise ratio of over 30 dB.
[0023] S15. Based on the high signal-to-noise ratio pure response signal and the known test signal, the transfer function of each test frequency point is calculated by the frequency domain ratio method. The transfer function model is extended to the full-band transfer function model by conformal interpolation, and the ear canal transfer function model including the amplitude frequency response curve, phase frequency response curve and measurement confidence level is obtained. The digital signal processor module performs a Fast Fourier Transform (FFT) on the high signal-to-noise ratio (SNR) clean response signal obtained from S14 and the known test signal, converting both to the frequency domain to obtain their spectra. The spectrum of the response signal is denoted as H-response, and the spectrum of the test signal is denoted as H-test. For each test frequency point, the transfer function value is calculated as the response signal spectrum divided by the test signal spectrum. Specifically, at the test frequency point f, the transfer function H(f) is equal to H-response(f) divided by H-test(f). Since the spectrum is a complex number, containing amplitude and phase information, the division operation is a complex number division. The amplitude of the transfer function is equal to the response signal amplitude divided by the test signal amplitude, and the phase of the transfer function is equal to the response signal phase minus the test signal phase. This calculation is repeated for all test frequency points to obtain the transfer function values at discrete test frequency points. These discrete transfer function values constitute the sampling points of the ear canal transfer function. To obtain a transfer function model over a continuous frequency range, an interpolation method is used to extend the discrete sampling points into a continuous function. The interpolation method used is conformal piecewise cubic interpolation. Conformal interpolation ensures that the monotonicity and concavity of the interpolation curve are consistent with the sampling points, avoiding non-physical oscillations. Piecewise cubic interpolation constructs a cubic polynomial between adjacent sampling points, and the polynomial coefficients are determined by boundary conditions and continuity conditions. The boundary conditions require the interpolation curve to pass through all sampling points, and the continuity conditions require that the function values, first derivatives, and second derivatives of adjacent segments are continuous. Solving the linear equation system yields the cubic polynomial coefficients for each segment, constructing a complete interpolation function. After interpolation, an ear canal transfer function model is obtained across the entire frequency range from 20Hz to 20000Hz. The transfer function model includes amplitude-frequency response curves and phase-frequency response curves. The amplitude-frequency response curve describes the change in the transfer function amplitude with frequency, reflecting the amplification or attenuation characteristics of the ear canal for sound waves of different frequencies. The phase-frequency response curve describes the change in the transfer function phase with frequency, reflecting the delay characteristics of the ear canal for sound waves of different frequencies. The confidence level of the transfer function measurement is calculated to evaluate the reliability of the measurement results at each frequency point. Confidence level calculation is based on the signal-to-noise ratio (SNR) metric, which is calculated as the ratio of the energy at the test frequency to the average energy at the non-test frequencies in the response signal. A high SNR indicates strong test signal components and weak noise interference, resulting in high measurement reliability, and the confidence level is set to high. A low SNR indicates strong noise interference and low measurement reliability, and the confidence level is set to low. The confidence level is quantified as a value between 0 and 1, where 1 represents complete confidence and 0 represents complete unreliability. Frequency bands with confidence levels below a threshold are marked as low-confidence regions, with the threshold set between 0.7 and 0.8. Low-confidence regions mainly occur in high-noise frequency bands, where noise interference remains strong even after SNR enhancement.
[0024] S2, collect sensor data and obtain the individual ear canal transfer function model, and use hierarchical scene recognition and adaptive weight fusion method to obtain real-time wearing status evaluation results; S21. Based on the ear canal transfer function model, low-frequency gain features are extracted, and the acoustic sealing score is calculated using the gain mapping model to obtain a quantitative index of sealing quality. The digital signal processor module extracts the low-frequency amplitude-frequency response data from the ear canal transfer function model obtained from S1. The low-frequency range is defined as 20Hz to 200Hz, which is sensitive to sealing performance. The average value of the low-frequency amplitude-frequency response is calculated as a low-frequency gain characteristic. The average value is calculated using either an arithmetic mean or a logarithmic mean, with the logarithmic mean being more sensitive to low gain values. When the seal is good, the earphone and ear canal form a relatively closed acoustic cavity, effectively confining low-frequency sound waves within the cavity, resulting in a high low-frequency gain, typically in the range of 10 to 20 dB. When the seal is poor, leakage paths exist, allowing low-frequency sound waves to escape, significantly reducing the low-frequency gain, typically in the range of 0 to 5 dB. A mapping model between low-frequency gain and sealing performance is established, based on statistical analysis of a large amount of measured data. The mapping model uses a piecewise linear function or an S-curve function to map the low-frequency gain value to a sealing performance score. The sealing score ranges from 0 to 100, where 100 represents a complete seal with no leakage, and 0 represents a complete open seal with no seal. The piecewise linear mapping model uses multiple segmentation points: a sealing score of 0–20 when the low-frequency gain is less than a first threshold; a score of 20–60 when the low-frequency gain is between the first and second thresholds; and a score of 60–100 when the low-frequency gain is greater than the second threshold. The thresholds are determined based on statistical data; the first threshold is typically set to 3–5 dB, and the second threshold to 12–15 dB. The currently measured low-frequency gain value is input into the mapping model to calculate the acoustic sealing score, which quantifies the current sealing quality.
[0025] S22, based on the pressure sensor array, the contact pressure distribution is measured, and the pressure uniformity and total pressure are calculated by statistical analysis to obtain the physical bonding stability index; The digital signal processor module acquires pressure measurements from the pressure sensor array module. The pressure sensor array contains 4 to 8 sensors, deployed at different points of contact between the earbud and the ear canal. Each sensor outputs a pressure value, expressed in kilopascals or millimeters of mercury. Statistical characteristics of the pressure distribution are calculated to quantify fit stability. The first statistical characteristic is pressure uniformity, measured using standard deviation or coefficient of variation. The standard deviation is calculated as the square root of the sum of the squares of the differences between each sensor's pressure value and the average pressure value. The coefficient of variation is calculated by dividing the standard deviation by the average pressure value, eliminating the influence of the average pressure level. Uniform pressure distribution indicates consistent force at all contact points between the earphone and the ear canal, resulting in a stable fit. Uneven pressure distribution indicates excessive pressure at some contact points and insufficient pressure at others, leading to an unstable fit or tilting. The second statistical characteristic is total pressure, calculated as the sum or weighted average of all sensor pressure values. Total pressure reflects the overall tightness of the fit between the earphone and the ear canal. Insufficient total pressure indicates loose earphones and poor sealing. Excessive total pressure indicates that the earphone is pressing too tightly into the ear canal, potentially causing discomfort. A fit stability assessment model is established. The model inputs are pressure uniformity and total pressure, and the output is a fit stability score. The score range is set from 0 to 100, where 100 represents perfect and stable fit, and 0 represents poor and unstable fit. The assessment model employs a multidimensional mapping or decision tree algorithm. Multidimensional mapping establishes a mapping function from two-dimensional input to one-dimensional output; a high score is achieved when pressure uniformity is high and total pressure is moderate, while a low score is achieved when pressure uniformity is low or total pressure is abnormal. The moderate range of total pressure is set based on user comfort and sealing requirements, typically between 2 kPa and 8 kPa. The currently measured pressure uniformity and total pressure are input into the assessment model to calculate the physical fit stability score.
[0026] S23, based on the measurement of headphone motion signals by a triaxial accelerometer, uses time-frequency feature extraction and pattern recognition to obtain the usage scenario type identifier; The digital signal processor (DSP) module acquires triaxial acceleration signals from the accelerometer module, with the three axes being the front-to-back axis, left-to-right axis, and up-to-down axis. The acceleration signal sampling frequency is set to 200Hz, and the sampling duration is 2 to 5 seconds to obtain sufficient statistical samples. A composite acceleration is calculated from the triaxial acceleration signals; the composite acceleration is equal to the square root of the sum of the squares of the three acceleration components. The composite acceleration reflects the overall motion intensity of the headphones, eliminating direction dependence. The time-domain characteristics of the composite acceleration signal are calculated, including the root mean square (RMS) value, peak value, zero-crossing rate, and crest factor. The RMS value reflects the average energy level of the acceleration signal; a large RMS value indicates high motion intensity. The peak value is the maximum absolute value of the signal, reflecting the maximum impact of the motion. The zero-crossing rate is the frequency at which the signal crosses zero, reflecting the signal's oscillatory characteristics. The crest factor is the peak value divided by the RMS value, reflecting the signal's impulse characteristics. The frequency-domain characteristics of the acceleration signal are calculated by performing a Fast Fourier Transform (FFT) to obtain the spectrum. The dominant frequency component of the spectrum is extracted; the dominant frequency is the frequency component with the highest energy. Extract the energy distribution characteristics of the spectrum and calculate the proportion of low-frequency, mid-frequency, and high-frequency energy. Different movement modes have different spectral characteristics; the dominant frequency of walking is between 1Hz and 3Hz, while that of running is between 2Hz and 4Hz. The spectral energy of stillness is mainly concentrated in the low frequencies, while the spectral energy distribution of movement is wider. Establish a scene recognition model. The model input is a time-frequency feature vector, and the output is a scene type identifier. Scene types include completely stillness, slight movement, walking, running, and riding in a vehicle. The scene recognition model uses decision trees, support vector machines, or neural network algorithms. Decision trees classify layer by layer based on feature thresholds; for example, first, they distinguish between stillness and movement based on the root mean square value threshold, and then they distinguish between walking and running based on the dominant frequency. Support vector machines construct a classification hyperplane in the feature space to separate feature points of different scenes. Neural networks learn the complex mapping relationship between features and scenes through multi-layer nonlinear transformations. Input the currently extracted time-frequency features into the scene recognition model, and the output is the current scene type identifier.
[0027] S24. Based on the energy difference of noise signals between the feedforward microphone and the in-ear microphone, the energy ratio method is used to quantify the leakage degree and obtain a quantitative estimate of the leakage rate. The digital signal processor module acquires noise signal samples from both the feedforward microphone module and the in-ear microphone module, with the acquisition time set to 1 to 2 seconds. The signal energy is calculated for each noise signal, and the signal energy is equal to the average of the sum of squares of the signal samples. The feedforward microphone acquires external ambient noise, denoted as Eouter. The in-ear microphone acquires residual noise within the ear canal, denoted as Einner. Under ideal noise reduction and sealing conditions, the residual noise energy within the ear canal is much smaller than the external noise energy, resulting in a large energy difference. When acoustic leakage exists, external noise enters the ear canal directly through the leakage path, bypassing the noise reduction system, leading to an increase in in-ear noise energy and a decrease in the energy difference. A quantitative relationship model between leakage rate and energy difference is established. The energy ratio R is calculated as Einner divided by Eouter, reflecting the proportion of in-ear noise to external noise. Ideally, the energy ratio R in the absence of leakage is the residual noise ratio of the noise reduction system, typically 0.01 to 0.1, corresponding to a noise reduction depth of 20 to 40 dB. The energy ratio R increases with the presence of leakage; the more severe the leakage, the larger the energy ratio. The leakage rate L is defined as the relative increment of the energy ratio R beyond the ideal value. The calculation formula is L = R minus Rideal divided by 1 minus Rideal. The leakage rate L ranges from 0 to 1, where 0 represents no leakage and 1 represents complete leakage with no noise reduction. The currently measured energy ratio R is input into the leakage rate calculation formula to obtain a quantitative estimate of the leakage rate. The leakage rate quantifies the impact of acoustic leakage on noise reduction performance, providing a basis for subsequent noise reduction curve compensation.
[0028] S25. Based on scene type identification and sensor data reliability analysis, a hierarchical weight configuration and dynamic adjustment strategy are adopted to obtain scene-adaptive sensor fusion weights. The digital signal processor module retrieves the corresponding sensor fusion weight configuration from a pre-defined scene parameter library based on the scene type identifier obtained in S23. The scene parameter library is pre-established and contains basic weight values for acoustic sensors, pressure sensors, and accelerometers under various scene types. The basic weight values are determined based on the reliability and importance of each sensor in different scenes. For a completely static scene, the acoustic and pressure sensor data are stable and reliable, while the accelerometer data has low energy and may be affected by noise; therefore, the acoustic sensor weight is set to 0.5, the pressure sensor weight to 0.4, and the accelerometer weight to 0.1. For a walking scene, the accelerometer effectively captures changes in wear caused by movement, increasing its importance; therefore, the accelerometer weight is increased to 0.4, and the acoustic and pressure sensor weights are adjusted to 0.3 and 0.3, respectively. For a vehicle-riding scene, vehicle vibration causes the accelerometer data to contain a large amount of interference from non-wearing changes, reducing reliability; therefore, the accelerometer weight is reduced to 0.2, the acoustic sensor weight is increased to 0.5, and the pressure sensor weight is 0.3. The retrieved basic weight configuration for the current scene is used as the initial value for the fusion weights. The system dynamically adjusts the weights based on the baseline to adapt to real-time data characteristics. The digital signal processor module analyzes the consistency and quality metrics of the data from each sensor. Consistency is measured by the correlation between the evaluation results of different sensors; high consistency is indicated when both the acoustic sealing score and the physical bonding stability score are simultaneously high or simultaneously low. Quality metrics are measured by the signal-to-noise ratio (SNR) or confidence level of the sensor signals; a high SNR indicates good data quality. For sensors with high consistency and good quality, their weights are increased, with weight increments set to 0.05 to 0.1. For sensors with conflicting indications or poor quality, their weights are decreased, with weight reductions set to 0.05 to 0.1. After weight adjustment, normalization is performed to ensure that the sum of all sensor weights is 1. Normalization is achieved by dividing each sensor weight by the sum of its weights. Scene-adaptive sensor fusion weights are obtained, which comprehensively consider scene characteristics and real-time data quality, enabling the selection of the most reliable sensor data in different scenarios.
[0029] S26. Based on the sealing score, fit stability score and leakage rate, a weighted fusion with scene adaptive weights is used to obtain a comprehensive wearing status evaluation result. The digital signal processor module uses the sealing score obtained in S21, the fit stability score obtained in S22, and the leakage rate obtained in S24 as fusion inputs. The sealing score and fit stability score both range from 0 to 100, while the leakage rate ranges from 0 to 1. To standardize the units, the leakage rate is converted to a leakage score using the formula: leakage score = 100 minus 100 times the leakage rate. After conversion, the leakage score also ranges from 0 to 100, with a higher score indicating less leakage. A weighted summation method is used for sensor fusion. The comprehensive wearing status score S equals the sealing score multiplied by the acoustic sensor weight, plus the fit stability score multiplied by the pressure sensor weight, plus the leakage score multiplied by the acoustic sensor weight. Since both sealing and leakage rates come from the acoustic sensor, they can be fused first and then multiplied by the acoustic sensor weight. The comprehensive acoustic score equals the average of the sealing score and the leakage score. The comprehensive wearing status score S equals the comprehensive acoustic score multiplied by the acoustic sensor weight, plus the fit stability score multiplied by the pressure sensor weight. Since the accelerometer is mainly used for scene recognition rather than state quantization, its weight primarily affects scene judgment rather than state scoring. A comprehensive wearing condition score S is calculated, ranging from 0 to 100. A high score indicates good wearing condition, good sealing, stable fit, and low leakage, while a low score indicates poor wearing condition, such as poor sealing or looseness. The system also outputs various sub-indicators, including sealing score, fit stability score, quantitative leakage rate, scene type identifier, and assessment confidence level. The assessment confidence level is calculated based on the overall quality and consistency of the data from each sensor. High confidence level indicates good consistency and quality, while low confidence level indicates inconsistencies or poor quality. The confidence level ranges from 0 to 1, where 1 indicates a completely reliable assessment and 0 indicates an unreliable assessment.
[0030] S3 receives the individual ear canal transfer function model and real-time wearing status evaluation results, and uses parameter library indexing and local optimization methods to obtain the noise reduction curve parameters that are quickly and adaptively adjusted. S31, extract feature parameters based on the ear canal transfer function model, extract state parameters based on the wearing state evaluation results, and combine them to form a parameter library index key; The digital signal processor module extracts key feature parameters from the ear canal transfer function model obtained in S1. These parameters characterize the acoustic properties of the ear canal. The first feature parameter is the low-frequency average gain, calculated as the average amplitude-frequency response in the 100Hz-200Hz band, reflecting the ear canal's amplification of low-frequency sound waves. The second feature parameter is the main resonance frequency, determined by searching for local maxima in the amplitude-frequency response curve. The resonance frequency reflects the inherent resonance characteristics of the ear canal, typically in the 2000Hz-4000Hz range. The third feature parameter is the main resonance amplitude, the amplitude-frequency response value at the resonance peak location, reflecting the intensity of the resonance. The fourth feature parameter is the phase response slope, calculated as the first derivative of the phase response curve in the mid-frequency band, reflecting the group delay characteristics. These feature parameters constitute a compact representation of the ear canal's acoustic properties, significantly reducing data dimensionality compared to the complete transfer function. State parameters are extracted from the wearing status assessment results obtained in S2, including a seal score and a quantitative leakage rate. The seal score reflects the sealing quality, and the leakage rate reflects the degree of leakage. The seal score is discretized into seal levels, categorized into high seal, medium seal, and low seal. A seal score of 80 or above is considered high seal, 50 to 80 is medium seal, and below 50 is low seal. The leakage rate is discretized into leakage levels, categorized into no leakage, slight leakage, and severe leakage. A leakage rate below 0.2 is considered no leakage, 0.2 to 0.5 is slight leakage, and above 0.5 is severe leakage. A parameter library index key is formed by combining ear canal characteristic parameters and wearing status parameters. The index key is a multi-dimensional vector, with dimensions representing low-frequency average gain, main resonance frequency, main resonance amplitude, phase response slope, seal level, and leakage level, respectively. The index key uniquely identifies a combination of ear canal acoustic characteristics and wearing status, used to retrieve the best-matching pre-optimized parameters in the noise reduction curve parameter library.
[0031] S32, based on the index key of the parameter library, retrieve matching entries in the noise reduction curve parameter library, and use the nearest neighbor search algorithm to obtain the initial noise reduction curve parameters; The digital signal processor module accesses a pre-built noise reduction curve parameter library in the memory module. This library contains a large number of pre-optimized noise reduction curve parameter entries, each corresponding to a set of index keys and the corresponding noise reduction curve parameters. The noise reduction curve parameters include feedforward noise reduction filter coefficients, feedback noise reduction filter coefficients, and hybrid gain coefficients. The feedforward filter coefficients are tap coefficients of a finite impulse response filter, with 64 to 256 coefficients. The feedback filter coefficients are also tap coefficients of a finite impulse response filter, with 32 to 128 coefficients. The hybrid gain coefficients are weighted coefficients of the feedforward and feedback paths, and can be a single scalar or a frequency-dependent vector. The parameter library is built offline, covering the main combinations of ear canal transfer function characteristic parameters and wearing status parameters. During the parameter library construction process, the parameter space is gridded or clustered for sampling, and the optimal noise reduction curve parameters are calculated and stored at each sampling point using a multi-objective optimization algorithm. The number of parameter library entries typically ranges from hundreds to thousands, covering common ear canal types and wearing statuses. The nearest neighbor search algorithm is used to find the entry in the parameter library that best matches the index key obtained in S31. The nearest neighbor search calculates the distance between the current index key and the index keys of all entries in the parameter library, selecting the entry with the smallest distance. The distance calculation uses weighted Euclidean distance, and the formula is the sum of the squared differences of each dimension multiplied by their corresponding weights, then taken as the square root. The weights reflect the importance of each feature parameter to the noise reduction performance; important parameters have larger weights. Low-frequency average gain and leakage level have a significant impact on noise reduction, with weights set to 2 to 3. The main formant parameter has a relatively small impact, with a weight set to 1. The sealing level has a moderate impact, with a weight set to 1.5 to 2. The weighted distance between the current index key and the index keys of all entries in the parameter library is calculated, and the entry with the smallest distance is selected as the nearest neighbor match. Noise reduction curve parameters are extracted from the matched entries as initial parameters. The initial parameters have been optimized for similar ear canal characteristics and wearing conditions, approaching the optimal solution under the current conditions, avoiding the convergence time and computational cost of optimizing from random or default values.
[0032] S33, based on the initial noise reduction curve parameters and the ear canal transfer function model, uses a local gradient optimization algorithm to obtain finely optimized noise reduction curve parameters; The digital signal processor module uses the initial noise reduction curve parameters obtained from S32 as a starting point to perform local optimization to adapt to the current precise ear canal transfer function and wearing status. A noise reduction performance evaluation model is established, with the noise reduction curve parameters and ear canal transfer function as inputs and the noise reduction depth evaluation value as output. The noise reduction depth is obtained by simulating the residual noise energy within the ear canal. During the simulation, the ambient noise is assumed to be unit white noise. The noise is filtered through a feedforward path to generate a feedforward anti-noise signal, and then filtered through a feedback path to generate a feedback anti-noise signal. The two are weighted by a mixed gain to generate the total anti-noise signal. The anti-noise signal is superimposed with the ambient noise, and the superimposed signal is transmitted through the ear canal transfer function to obtain the sound signal within the ear canal. The energy of the sound signal within the ear canal is calculated as the residual noise energy. The noise reduction depth is defined as the ratio of ambient noise energy to residual noise energy, expressed in decibels (dB). A larger noise reduction depth indicates a better noise reduction effect. An optimization objective function is established, with the objective function being the negative noise reduction depth. The optimization objective is to minimize the objective function, which is equivalent to maximizing the noise reduction depth. Constraints are established, including system stability constraints, intra-ear sound pressure level (IELTS) constraints, and frequency response flatness constraints. System stability constraints require that all poles of the closed-loop transfer function of the feedback loop lie within the unit circle. IELTS constraints require that the total IELTS level does not exceed a comfort threshold, set at 85-90 dB. Frequency response flatness constraints require that the variance or ripple of the frequency response curve after the audio signal passes through the noise reduction system be less than the threshold, ensuring no degradation in sound quality. A constrained gradient descent algorithm is used for local optimization. Gradient descent calculates the gradient of the objective function with respect to each parameter and updates the parameters along the negative gradient direction to reduce the objective function value. Gradient calculation uses a numerical differentiation method, applying small perturbations to each parameter, calculating the change in the objective function, and dividing the change by the perturbation to obtain an approximate gradient value. The update step size is determined using a line search method, searching for the step size that maximizes the decrease in the objective function along the negative gradient direction. Constraint handling uses a projection method; after parameter updates, constraints are checked, and if a constraint is violated, the parameters are projected onto the boundary of the feasible region where the constraint is satisfied. Iteratively perform gradient calculations, parameter updates, and constraint projections until the objective function converges or the maximum number of iterations is reached. The maximum number of iterations is set to 10 to 20 to control computation time. Local optimization converges quickly, typically within a few iterations, because it starts with initial parameters close to the optimal solution. After optimization, finely optimized noise reduction curve parameters are obtained. These parameters are adjusted for the current precise ear canal transfer function and wearing status, resulting in noise reduction performance superior to the initial parameters.
[0033] S34. Based on the quantitative value of leakage rate, the compensation parameters are retrieved from the leakage compensation parameter library, and the parameter superposition method is used to obtain the noise reduction curve parameters after leakage compensation. The digital signal processor module retrieves matching compensation parameters from the leakage compensation parameter library based on the quantitative value of the leakage rate obtained from S2. The leakage compensation parameter library is pre-established based on the optimal compensation strategy for different leakage rates. Leakage mainly affects the noise reduction effect in the low-frequency band; the leakage path forms an acoustic short circuit, allowing low-frequency noise to bypass the noise reduction system and directly enter the ear canal. The compensation strategy compensates for the performance loss caused by leakage by increasing the noise reduction gain in the low-frequency band. Leakage compensation parameters include frequency band gain adjustment coefficients and frequency equalization coefficients. The frequency band gain adjustment coefficient scales the filter coefficients for different frequency bands, amplifying the low-frequency coefficients while maintaining or slightly reducing the mid-to-high frequency coefficients. The frequency equalization coefficient is a frequency-dependent gain curve that applies an additional gain boost to the low-frequency band. The compensation parameter library is indexed by the leakage rate, which is discretized into multiple levels, each corresponding to a set of compensation parameters. A leakage rate of 0 to 0.2 indicates no leakage or slight leakage, and the compensation parameters are unit values or small adjustments. A leakage rate of 0.2 to 0.5 indicates moderate leakage, and the compensation parameters increase the low-frequency band gain by 1.5 to 2 times. A leakage rate of 0.5 or higher is considered severe leakage, and the compensation parameters improve the low-frequency gain by 2 to 3 times. The corresponding compensation parameters are retrieved based on the current leakage rate. These compensation parameters are then applied to the optimized noise reduction curve parameters obtained from S33. The application method is parameter superposition or parameter multiplication. For the frequency band gain adjustment coefficient, coefficients are multiplied point-by-point, multiplying each tap coefficient of the filter by the corresponding frequency band adjustment coefficient to achieve selective gain adjustment. For the frequency equalization coefficient, the equalization coefficient is converted into a filter form and cascaded with the original filter, equivalent to frequency domain multiplication. The cascaded filter improves the low-frequency gain, compensating for leakage loss. During the compensation process, care must be taken to avoid overcompensation, which could lead to system instability or sound quality degradation. The compensated filter parameters are checked to ensure they meet stability and sound quality constraints; if these constraints are violated, the compensation amplitude is reduced or a conservative compensation strategy is adopted. The noise reduction curve parameters after leakage compensation are obtained. These parameters are specifically adjusted for leakage conditions based on the original optimized parameters, maintaining noise reduction performance even under poor sealing conditions.
[0034] S35, based on the measurement confidence distribution, conservatively adjusts the noise reduction parameters of the low confidence frequency band, and adopts a parameter attenuation strategy to obtain noise reduction curve parameters with enhanced reliability; The digital signal processor module extracts measurement confidence distribution information from the ear canal transfer function model obtained from S1. The confidence distribution indicates the reliability of transfer function measurements at each frequency band; low-confidence bands have large measurement errors. Noise reduction parameters designed based on transfer functions with large errors have low reliability, potentially leading to poor noise reduction or even introducing noise. A conservative adjustment strategy is adopted for low-confidence bands to reduce the noise reduction gain in these bands, avoiding negative impacts caused by inaccurate parameters. Frequency bands with confidence levels below a threshold are identified, with the threshold set to 0.7 to 0.8. Attenuation coefficients are applied to the noise reduction curve parameters of these bands. The attenuation coefficient is calculated based on the confidence level; the lower the confidence level, the smaller the attenuation coefficient. The formula for calculating the attenuation coefficient is the confidence value, or a power of the confidence value, with the power set to 2 to 3 to enhance the attenuation effect. The attenuation coefficient is applied to the filter coefficients of the corresponding frequency band through multiplication. The attenuated filter coefficients reduce the gain of the corresponding frequency band, decreasing the noise reduction depth, but avoiding noise reduction failure or noise introduction due to parameter errors. For high-confidence frequency bands, the attenuation coefficient is close to 1, and the parameters remain unchanged. This conservative adjustment strategy sacrifices noise reduction depth in some frequency bands but improves the overall reliability and stability of noise reduction performance, avoiding the uneven phenomenon of noise reduction failure in certain frequency bands. This yields noise reduction curve parameters with enhanced reliability, which comprehensively consider both noise reduction performance and measurement reliability.
[0035] S36, based on the comparison between the noise reduction curve parameters enhanced by reliability and the current parameters, the parameter update trigger flag is obtained by using difference evaluation and threshold judgment; The digital signal processor module extracts the noise reduction curve parameters currently used by the system, storing these parameters in a working register or cache. It calculates the difference between the new noise reduction curve parameters obtained from S35 and the current parameters. The difference calculation uses the parameter vector norm. The feedforward filter coefficients, feedback filter coefficients, and hybrid gain coefficients are combined into a parameter vector, denoted as Pnew, and the current parameter vector as Pcurrent. The difference vector is calculated as Pnew minus Pcurrent, where each component represents the change in the corresponding parameter. The 2-norm of the difference vector is calculated; the 2-norm is equal to the square root of the sum of the squares of the components of the difference vector, reflecting the overall magnitude of parameter change. A parameter update threshold is set, determined based on the system's sensitivity to parameter changes and stability requirements. A threshold that is too low will lead to frequent parameter updates, system instability, and a heavy computational burden. A threshold that is too high will result in delayed parameter updates, failing to respond promptly to state changes. The threshold is typically set to 5% to 10% of the parameter vector norm. The calculated difference norm is compared to the threshold. If the difference norm is greater than the threshold, it indicates a significant difference between the new and current parameters, requiring parameter updates to adapt to state changes, and the parameter update trigger flag is set to true. If the difference norm is less than or equal to the threshold, it indicates that the new parameters are not significantly different from the current parameters, the current parameters are still applicable, and no update is needed; therefore, the parameter update trigger flag is set to false. Simultaneously, a parameter update suppression mechanism is set to limit the update frequency within a short time window. The time window is set to 1 to 5 seconds; even if the update condition is triggered within the window, no update is performed to avoid frequent parameter fluctuations. The update suppression mechanism records the timestamp of the last parameter update; when the interval between the current time and the last update time is less than the time window, the update trigger flag is forcibly set to false. The parameter update trigger flag and the new noise reduction curve parameters are output to provide a basis and data for subsequent parameter update steps.
[0036] S4: Receive the noise reduction curve parameters and parameter update trigger flag, and use an adaptive transition window and smooth interpolation method to obtain the noise reduction curve parameters after smooth transition; S41, determine whether to start the parameter update process based on the parameter update trigger flag, calculate the parameter change magnitude based on the parameter difference vector, and obtain the update process control signal; The digital signal processor module detects the parameter update trigger flag output by S3. It reads the flag value; a true flag indicates a parameter update is needed, while a false flag indicates no update is needed, and the current state is maintained. When the flag is true, the noise reduction curve parameter update process is initiated, and subsequent transition processing steps are executed. When the flag is false, the update process is skipped, and the system continues to use the current parameters for noise reduction. A parameter difference vector is calculated, which is the new noise reduction curve parameter vector minus the current parameter vector. The difference vector includes three parts: feedforward filter coefficient difference, feedback filter coefficient difference, and hybrid gain difference. The parameter change magnitude index is calculated to quantify the overall degree of change. The change magnitude uses the infinite norm or 2-norm of the difference vector. The infinite norm is the maximum absolute value of each component of the difference vector, reflecting the largest single change. The 2-norm is the square root of the sum of squares of each component of the difference vector, reflecting the overall change energy. A large parameter change magnitude indicates a significant difference between the new and current parameters, requiring a longer transition time to ensure smoothness. A small change magnitude indicates a small difference, allowing for a shorter transition time to complete the update quickly. Obtain update process control signals, including update start flags and parameter change magnitude values, to control subsequent transition window settings and interpolation processing.
[0037] S42, based on the parameter change amplitude and the wearing status change rate, adopts an adaptive window length calculation algorithm to obtain the transition window length parameter; The digital signal processor module calculates the rate of change of wearing status based on the parameter change amplitude obtained from S41 and the wearing status evaluation result output from S2. The rate of change of wearing status is obtained by calculating the time derivative of the comprehensive wearing status score over consecutive time steps. The time derivative uses a difference approximation: the score at the current moment is subtracted from the score at the previous moment, and then divided by the time interval. A large rate of change indicates a rapid change in wearing status, such as when the user is adjusting the headphones or exercising, requiring a rapid system response. A small rate of change indicates a stable wearing status, allowing for a longer transition time to ensure smoothness. A transition window length calculation model is established, with parameter change amplitude and state change rate as inputs and transition window length as output. The model uses a piecewise linear function or a lookup table. When the parameter change amplitude is large and the state change rate is small, a longer transition window is set, with a window length of 150 to 200 milliseconds, corresponding to a signal processing cycle of 75 to 100 frames. The longer transition window ensures a smooth parameter transition and avoids introducing transient noise due to large changes. When parameter changes are small or state changes are rapid, a shorter transition window is set, with a window length of 20 to 50 milliseconds, corresponding to a processing cycle of 10 to 25 frames. A shorter transition window improves response speed and timely tracking of state changes. When both parameter changes and state changes are at a moderate level, a medium-length transition window is set, with a window length of 70 to 100 milliseconds. The calculated parameter change magnitude and state change rate are input into the window length calculation model to obtain the adaptive transition window length parameter. The adaptive window length comprehensively considers parameter change characteristics and application scenario requirements, achieving a dynamic balance between smoothness and responsiveness.
[0038] S43, Generate parameter transition sequence based on transition window length parameter, and use cosine interpolation method to achieve smooth transition, and obtain transition parameter sequence for each frame; The digital signal processor module calculates the number of frames in the transition sequence based on the transition window length obtained from S42. The number of transition frames equals the transition window length divided by the single-frame processing period, which is typically 2 milliseconds. For example, if the transition window length is 100 milliseconds and the single-frame period is 2 milliseconds, the number of transition frames is 50. A parameter transition sequence is generated, containing intermediate transition values from the current parameter to the new parameter. Cosine interpolation is used to calculate the transition parameters for each frame. Compared to linear interpolation, cosine interpolation has zero velocity at the start and end points, resulting in a smoother transition. The formula for calculating the transition parameters of the k-th frame is: the transition parameter equals the current parameter plus the parameter difference vector multiplied by the interpolation weight. The interpolation weight is calculated using a cosine function, where the weight equals 1 minus the cosine value divided by 2. The independent variable of the cosine function is the normalized time multiplied by pi, where the normalized time equals the current frame number k divided by the total number of frames N. When k equals 0, the normalized time is 0, the interpolation weight is 0, and the transition parameter equals the current parameter. When k equals N, the normalization time is 1, the interpolation weight is 1, and the transition parameter is equal to the new parameter. The interpolation weight of the intermediate frame changes smoothly between 0 and 1, with an S-shaped change curve. The rate of change is zero at the start and end points, and the rate of change is the largest in the middle segment. The interpolation formula is applied to each component of the parameter vector to generate the transition values of the feedforward filter coefficients, feedback filter coefficients, and hybrid gain for each frame. The transition parameters of each frame are organized into a transition sequence, with a sequence length equal to the number of transition frames, and the sequence is arranged in chronological order. The transition sequence is stored in a buffer for subsequent frame-by-frame denoising processing.
[0039] S44, based on the transition parameter sequence of each frame, is applied frame by frame in the noise reduction process, while monitoring the output signal quality to obtain the noise reduction curve parameter application status after smooth transition is completed; In each signal frame of the noise reduction process, the digital signal processor module reads the transition parameters for the corresponding frame from the transition sequence generated by S43. The first frame reads the first set of parameters in the sequence, the second frame reads the second set, and so on. The read transition parameters are configured into the noise reduction filter: the feedforward filter is loaded with transition feedforward coefficients, the feedback filter is loaded with transition feedback coefficients, and the mixing module is loaded with transition gain coefficients. Noise reduction processing for the current frame is performed using the configured transition parameters, including feedforward filtering, feedback filtering, and signal mixing. As the frame number increases, the transition parameters gradually change from the current parameters to the new parameters, achieving a smooth transition in the noise reduction curve. The output signal quality is monitored in real time during the transition process to evaluate the transition effect. Quality monitoring includes smoothness metrics and noise metrics. The smoothness metric calculates the continuity of the output signal envelope, evaluated by calculating the rate of change of signal energy between adjacent frames. A small rate of energy change indicates smooth signal, while a large rate of change indicates abrupt changes or transient noise. The smoothness threshold is set based on the acceptable level of signal fluctuation. The noise metric calculates the high-frequency energy or total harmonic distortion of the output signal to detect whether additional noise has been introduced. When the smoothness index exceeds the threshold or the noise index increases abnormally, a transition adjustment mechanism is triggered. This mechanism extends the transition window length, increases the number of remaining unexecuted transition frames, and reduces the parameter change rate. Alternatively, it modifies the interpolation curve, employing a smoother, higher-order interpolation method. After adjustment, the transition sequence continues execution. Once all frames in the transition sequence have been executed, the parameters are updated to the new noise reduction curve parameters, and a parameter update completion flag is set. The timestamp and parameter change information of this update are recorded and stored in the history for reference in subsequent updates and system optimization. The system enters a stable operating mode, using the new parameters for noise reduction processing until the next parameter update is triggered.
[0040] S45 determines whether to activate emergency response based on the result of sudden change in wearing status detection, and uses a fast transition channel to achieve rapid parameter switching, so as to obtain a noise reduction curve that adapts quickly in emergency scenarios. The digital signal processor module continuously monitors for abrupt changes in the wearing status assessment results. Abrupt change detection is achieved by calculating the magnitude of jumps in the overall wearing status score. A change is defined as a drop in score exceeding a threshold within a single update cycle. The abrupt change threshold is set to 20 to 30 points, corresponding to a significant deterioration in wearing status from good to poor. Abrupt changes include emergency scenarios such as loose earphones, severe leakage, and earphones falling out. In emergency scenarios, noise cancellation performance drops sharply, requiring the system to quickly adjust parameters to restore or optimize the noise cancellation effect. When an abrupt change is detected, an emergency response mechanism is activated. The emergency response skips the regular smooth transition process and uses a fast transition channel. The fast transition shortens the transition window length to 5 to 20 milliseconds, corresponding to a processing cycle of 3 to 10 frames. In some extreme cases, the transition can be skipped, and parameters can be switched directly, with the new parameters immediately applied to the noise cancellation filter. While the fast response may introduce brief transient noise, it can promptly address unexpected situations, preventing prolonged noise cancellation failure or a deterioration in user experience. The emergency response mechanism also triggers system prompts, reminding the user to adjust the wearing status via voice or indicator lights. After the user makes adjustments, the system reassesses the wearing status. If the status recovers well, it switches back to normal noise cancellation parameters through a standard transition process. This emergency response mechanism enhances the system's adaptability to unexpected situations and improves the user experience.
[0041] S5, obtains the noise reduction curve parameters after smooth transition, and uses hybrid active noise reduction processing and audio equalization to obtain a low noise environment in the ear canal and high-fidelity audio output. S51, based on the feedforward filter coefficients in the current noise reduction curve parameters, the environmental noise signal collected by the feedforward microphone is filtered to obtain the feedforward anti-noise signal; The digital signal processor module reads ambient noise signal sampling data from the feedforward microphone module. The sampling data is a digital signal with a sampling rate of 48000Hz, containing 96 sampling points per frame, corresponding to a duration of 2 milliseconds. Preprocessing of the noise signal involves first removing the DC component by subtracting the signal mean, thus eliminating sensor bias and low-frequency drift. Next, bandpass filtering is performed, with the passband set to 20Hz to 20000Hz and the stopband to below 20Hz and above 20000Hz, removing frequency components insensitive to the human ear and reducing processing overhead. The bandpass filter uses an infinite impulse response filter with an order of 4th to 8th, and the cutoff frequency is set at the passband boundary. Gain normalization is then performed to normalize the signal amplitude to a standard range, preventing numerical overflow or underflow in subsequent processing. Normalization is achieved by dividing by the maximum signal amplitude or the root mean square value. The preprocessed ambient noise signal is then input to the feedforward noise reduction filter. The feedforward filter uses the current feedforward filter coefficients output by S4. These coefficients are the tap weights of the finite impulse response filter, and there are 128 coefficients in total. The filtering process employs time-domain convolution, where the current sample point of the output signal equals the inner product of the current and historical sample points of the input signal and the filter coefficients. Specifically, for each tap of the filter, the corresponding historical input sample point is multiplied by the tap coefficient, and all multiplications are summed to obtain the output sample point. The convolution operation requires buffering the historical data of the input signal, with a buffer length equal to the filter length. The convolution operation is repeated for each sample point of the current frame to generate the output frame. The frequency response of the filter is designed based on the ear canal transfer function and the noise reduction target, ensuring that the spectrum and phase of the output signal are inversely matched to the signal after the environmental noise has passed through the ear canal. The output feedforward noise-resistant signal cancels out the noise when superimposed in subsequent steps, achieving noise reduction.
[0042] S52, based on the feedback filter coefficients in the current noise reduction curve parameters, filters the in-ear noise signal collected by the feedback microphone to obtain the feedback anti-noise signal; The digital signal processor module reads sampled data of the in-ear noise signal from the feedback microphone module. The in-ear noise signal includes residual noise from the ambient noise after feedforward denoising and feedback from the speaker. The in-ear noise signal undergoes the same preprocessing as the S51, including DC component removal, bandpass filtering, and gain normalization. The preprocessed signal is then input to the feedback denoising filter. The feedback filter uses the current feedback filter coefficients, with a total of 64 coefficients. The feedback filter is implemented through time-domain convolution or recursive operations. For the finite impulse response feedback filter, the same convolution operation as the feedforward filter is used. For the infinite impulse response feedback filter, a difference equation recursive operation is used, where the current output depends not only on the input history but also on the output history. The recursive formula is that the current output equals the inner product of the input and the feedforward coefficients minus the inner product of the output history and the feedback coefficients. The feedback filter design ensures a stable feedback loop, with all poles located inside the unit circle. The feedback filter can track and suppress residual noise that feedforward denoising could not completely eliminate, especially low-frequency steady-state noise. The output feedback noise immunity signal and the feedforward noise immunity signal together constitute the noise immunity output of the hybrid noise reduction system.
[0043] S53, based on the hybrid gain coefficient in the current noise reduction curve parameters, weighted mix of feedforward and feedback noise immunity signals to obtain hybrid noise immunity signal; The digital signal processor module weighted mixes the feedforward noise immunity signal obtained in S51 and the feedback noise immunity signal obtained in S52. The mixing gain coefficient is read from the parameters of the current noise reduction curve, and the gain coefficient includes the feedforward path gain and the feedback path gain. The gain coefficient can be a frequency-independent scalar or a frequency-dependent vector. For scalar gain, each sampling point of the mixed signal is equal to the feedforward signal multiplied by the feedforward gain plus the feedback signal multiplied by the feedback gain. The sum of the feedforward gain and the feedback gain is usually normalized to 1 to represent energy conservation. For frequency-dependent vector gain, the feedforward and feedback signals are first converted to the frequency domain using a fast Fourier transform, and each frequency component is multiplied by the corresponding gain coefficient in the frequency domain. Then, the signals are converted back to the time domain using an inverse Fourier transform. Frequency-dependent gain can optimize the weights of feedforward and feedback for different frequency bands. The feedback weight is usually larger in the low-frequency band because the feedback is effective against low-frequency steady-state noise, while the feedforward weight is larger in the high-frequency band because the feedforward responds quickly to high-frequency transient noise. After weighted mixing, a hybrid noise-resistant signal is obtained, which combines the advantages of both feedforward and feedback noise reduction mechanisms, enabling efficient noise reduction over a wide frequency band.
[0044] S54, based on the secondary channel transfer function, performs pre-compensation filtering on the mixed anti-noise signal to obtain the compensated anti-noise signal; The digital signal processor module performs secondary channel compensation filtering on the mixed noise-resistant signal obtained from the S53. The secondary channel refers to the acoustic transmission path from the speaker to the in-ear microphone, encompassing the combined transmission characteristics of the digital-to-analog converter, power amplifier, speaker, acoustic cavity, and ear canal space. The secondary channel alters the amplitude and phase response of the signal, causing a deviation between the actual sound wave played into the ear canal and the designed noise-resistant signal. To ensure that the actual sound wave in the ear canal is precisely out of phase with the noise, pre-compensation of the noise-resistant signal is necessary, restoring the signal to its design value after passing through the secondary channel. The secondary channel transfer function is obtained through offline measurement or online identification. Offline measurement occurs during product calibration, where a known test signal is played through the speaker, the in-ear microphone collects the response signal, and the transfer function is calculated. Online identification occurs during user operation, using the played audio signal as a reference, and an adaptive algorithm estimates the transfer function. The transfer function of the secondary channel compensation filter is designed to be the inverse of the secondary channel transfer function, resulting in a flat frequency response and zero phase delay after cascading. The inverse transfer function is calculated using the reciprocal in the frequency domain or a least-squares inverse filtering algorithm. The compensation filter is implemented as a finite impulse response filter with 32 to 128 coefficients. It performs compensation filtering on the mixed noise-reducing signal using time-domain convolution. After digital-to-analog conversion and speaker playback, the compensated noise-reducing signal exhibits the designed spectrum and phase characteristics within the ear canal, precisely out of phase with the ambient noise, achieving optimal noise reduction.
[0045] S55 performs personalized equalization processing on the audio source signal based on the ear canal transfer function model to obtain the equalized audio signal. The digital signal processor (DSP) module acquires audio source signals from music players, call modules, or other audio applications. The audio signal sampling rate is consistent with the noise reduction processing sampling rate, both at 48000Hz. Based on the ear canal transfer function (TVF) model obtained from S1, the influence of the ear canal on the frequency response of the audio signal is analyzed. The TVF has high gain in some frequency bands, resulting in excessive audio energy in these bands; conversely, it has low gain in other frequency bands, resulting in insufficient audio energy. This unbalanced frequency response affects sound quality, leading to timbre shift or loss of detail. A personalized equalization filter is designed to compensate for the influence of the ear canal frequency response. The frequency response of the equalization filter is the reciprocal of the amplitude-frequency response of the TVF, ensuring a flat overall frequency response after the audio signal passes through the equalization filter and ear canal. The equalization filter is implemented using either a parametric equalizer or a graphic equalizer. The parametric equalizer offers high flexibility by adjusting several parametric equalization bands, each with its own center frequency, gain, and quality factor. The graphic equalizer divides the spectrum into multiple fixed frequency bands, allowing adjustment of the gain of each band, making it intuitive and easy to use. The equalization filter coefficients are calculated in real-time based on the TVF or retrieved from a preset configuration library. The audio source signal is subjected to equalization filtering, which is achieved using time-domain convolution or frequency-domain multiplication. The equalized audio signal presents a balanced frequency response to the user's ears, ensuring sound quality fidelity and listening comfort.
[0046] S56 mixes and superimposes the compensated anti-noise signal with the equalized audio signal, and then plays it through digital-to-analog conversion and speakers to obtain a low-noise environment and high-fidelity audio effect in the ear canal. The digital signal processor module performs time-domain superposition of the compensated noise-resistant signal obtained from S54 and the equalized audio signal obtained from S55. Superposition is performed by adding samples one by one; each sample point of the mixed signal equals the sum of the corresponding sample points of the noise-resistant signal and the corresponding sample points of the audio signal. Before superposition, the amplitudes of the two signals need to be level-matched to ensure that the dynamic ranges of the noise-resistant and audio signals are coordinated, preventing one from overpowering the other or causing clipping distortion. Level matching is achieved through gain adjustment, calculated and adjusted based on the root mean square or peak value of each signal. The mixed signal is converted into an analog signal by a digital-to-analog converter (DAC). The DAC sampling rate is set to 48000Hz, and the bit depth is set to 16-bit or 24-bit to ensure audio quality. 16-bit corresponds to a 96dB dynamic range, suitable for general applications; 24-bit corresponds to a 144dB dynamic range, suitable for high-fidelity audio. The analog mixed signal is amplified to a suitable power level by a power amplifier to drive the speaker. The speaker converts the electrical signal into sound waves, which propagate within the headphone's acoustic cavity and enter the user's ear canal. The played noise-canceling signal spatially superimposes with the ambient noise within the ear canal. Because the two signals have equal amplitudes but opposite phases, phase cancellation occurs, canceling out the ambient noise and creating a low-noise acoustic environment. Residual noise energy is significantly reduced in this low-noise environment, with noise reduction depths reaching 40-55 dB in the low-frequency range and 25-35 dB in the mid-frequency range. The played audio signal undergoes personalized equalization, delivering high-fidelity sound quality to the user's ears, with balanced frequency response, rich detail, and a natural listening experience. Users enjoy an immersive listening experience in this low-noise environment, while avoiding noise interference and ear pressure discomfort.
[0047] like Figure 2 As shown, the adaptive noise reduction curve adjustment system for headphones of the present invention includes a feedforward microphone module, a feedback microphone module, an in-ear microphone module, a pressure sensor array module, an accelerometer module, a digital signal processor module, a speaker module, and a memory module. The feedforward microphone module is deployed on the outside of the headphones for collecting ambient noise signals. The feedback microphone module and the in-ear microphone module are deployed on the inside of the headphones near the ear canal for collecting sound signals within the ear canal. The pressure sensor array module is deployed at the contact point between the earbud and the ear canal for measuring the contact pressure distribution. The accelerometer module is deployed on the headphone body for detecting the headphone's motion state. The digital signal processor module serves as the core computing unit, executing signal processing, parameter optimization, and noise reduction control algorithms. The speaker module is used to play anti-noise signals and audio signals. The memory module stores a noise reduction curve parameter library, an ear canal transfer function model, and algorithm programs.
[0048] This invention focuses on the application of active noise-canceling headphones in urban commuting scenarios. The following specific data examples illustrate the practical application effects of this invention.
[0049] A user commutes by subway during the morning rush hour, wearing the adaptive noise-canceling headphones of this invention. After the system starts up, it performs an ear canal transfer function measurement to obtain the user's individual ear canal acoustic characteristic data, as shown in Table 1.
[0050] Table 1 Measurement data of characteristic parameters of user ear canal transfer function
[0051] Table 1 shows the characteristic parameters of the ear canal transfer function obtained from five repeated measurements. The data shows that the average low-frequency gain of the user's ear canal is about 14 dB, the main formant frequency is in the range of 2780 Hz to 2920 Hz, and the measurement confidence level is above 0.89, indicating that the measurement results are reliable.
[0052] During the commute, the system continuously monitors the user's wearing status and obtains real-time evaluation data, as shown in Table 2.
[0053] Table 2. Wearing status assessment data at different times
[0054] Table 2 shows the evaluation results of the wearing status at different times during the commute. The data shows that the sealing and fit stability decreased and the leakage rate increased in the walking scenario. The system can identify the status changes in a timely manner and adjust the noise reduction curve parameters.
[0055] The system dynamically optimizes noise reduction curve parameters based on measured ear canal transfer function and real-time wearing status to achieve personalized noise reduction effects. Compared with traditional solutions using fixed noise reduction curves, this invention provides more stable noise reduction depth in the low-frequency range, maintaining good noise reduction performance even when wearing status changes. Users experience stable, comfortable, and efficient noise reduction throughout their commute, with high audio playback fidelity, good wearing comfort, and no noticeable ear pressure discomfort.
[0056] The adaptive noise reduction curve adjustment method of the present invention automatically optimizes noise reduction parameters by sensing individual differences and dynamic wearing changes in real time, effectively solving the limitations of traditional fixed parameter schemes, and providing users with a personalized and intelligent noise reduction experience. It has significant technical advantages and application value.
[0057] The embodiments of the present invention have been described above. However, the embodiments are not limited to the specific implementation methods described above. The specific implementation methods described above are merely illustrative and not restrictive. Those skilled in the art can make more equivalent embodiments under the guidance of the present embodiments, and all of them are within the protection scope of the present embodiments.
Claims
1. A method for adjusting the adaptive noise reduction curve of headphones, characterized in that, Includes the following steps: S1. Based on environmental noise perception and multi-stage signal-to-noise ratio enhancement, an individual ear canal transfer function model is obtained by using adaptive test signal generation and coherent averaging processing. S2, collect sensor data and obtain the individual ear canal transfer function model, and use hierarchical scene recognition and adaptive weight fusion method to obtain real-time wearing status evaluation results; S3 receives the individual ear canal transfer function model and real-time wearing status evaluation results, and uses parameter library indexing and local optimization methods to obtain the noise reduction curve parameters that are quickly and adaptively adjusted. S4: Receive the noise reduction curve parameters and parameter update trigger flag, and use an adaptive transition window and smooth interpolation method to obtain the noise reduction curve parameters after smooth transition; S5 acquires the noise reduction curve parameters after a smooth transition, and uses hybrid active noise reduction processing and audio equalization to obtain a low-noise environment in the ear canal and high-fidelity audio output.
2. The headphone adaptive noise reduction curve adjustment method according to claim 1, characterized in that, S1 includes: Environmental noise samples were collected using a feedforward microphone, and the noise power spectral density distribution was analyzed using fast Fourier transform to obtain the noise energy characteristics of each frequency band. Based on noise energy characteristics, low-noise and high-noise frequency bands are identified. A spectrum notch detection algorithm is used to mark the preferred frequency points of the test signal, resulting in an adaptive test frequency point distribution scheme. Based on the adaptive test frequency point distribution scheme, a multi-tone test signal is generated. The test signal is emitted by a loudspeaker while the in-ear microphone and feedback microphone simultaneously collect the response signal, resulting in a noisy response signal. Based on the noisy response signal, coherent averaging technique is used to repeatedly measure multiple times, and adaptive noise cancellation and frequency domain selective enhancement are employed to obtain a clean response signal with high signal-to-noise ratio. Based on a high signal-to-noise ratio pure response signal and a known test signal, the transfer function at each test frequency point is calculated using the frequency domain ratio method. Conformal interpolation is then used to extend it into a full-band transfer function model, resulting in an ear canal transfer function model that includes the amplitude frequency response curve, phase frequency response curve, and measurement confidence level.
3. The headphone adaptive noise reduction curve adjustment method according to claim 1, characterized in that, S2 includes: Low-frequency gain features are extracted based on the ear canal transfer function model, and acoustic sealing score is calculated using a gain mapping model to obtain a quantitative index of sealing quality. Based on the pressure sensor array, the contact pressure distribution is measured, and the pressure uniformity and total pressure are calculated by statistical analysis to obtain the physical bonding stability index. Based on the measurement of headphone motion signals using a triaxial accelerometer, time-frequency feature extraction and pattern recognition are employed to obtain the usage scenario type identifier; Based on the energy difference of noise signals between the feedforward microphone and the in-ear microphone, the energy ratio method is used to quantify the leakage degree and obtain a quantitative estimate of the leakage rate. Based on scene type identification and sensor data reliability analysis, a hierarchical weight configuration and dynamic adjustment strategy is adopted to obtain scene-adaptive sensor fusion weights; based on sealing score, fit stability score and leakage rate, scene-adaptive weights are used for weighted fusion to obtain a comprehensive wearing status evaluation result.
4. The headphone adaptive noise reduction curve adjustment method according to claim 1, characterized in that, S3 includes: Feature parameters are extracted based on the ear canal transfer function model, and state parameters are extracted based on the wearing state evaluation results. These are combined to form a parameter library index key. Based on the index key of the parameter library, matching entries are retrieved in the noise reduction curve parameter library, and the nearest neighbor search algorithm is used to obtain the initial noise reduction curve parameters; Based on the initial noise reduction curve parameters and the ear canal transfer function model, a local gradient optimization algorithm is used to obtain finely optimized noise reduction curve parameters. Based on the quantitative value of leakage rate, compensation parameters are retrieved from the leakage compensation parameter library, and the parameter superposition method is used to obtain the noise reduction curve parameters after leakage compensation. Based on the measurement confidence distribution, the noise reduction parameters in the low confidence band are conservatively adjusted, and a parameter attenuation strategy is adopted to obtain noise reduction curve parameters with enhanced reliability. Based on the comparison between the noise reduction curve parameters enhanced by reliability and the currently used parameters, the parameter update trigger flag is obtained by using difference evaluation and threshold judgment.
5. The headphone adaptive noise reduction curve adjustment method according to claim 1, characterized in that, S4 includes: The parameter update process is initiated based on the parameter update trigger flag, and the parameter change magnitude is calculated based on the parameter difference vector to obtain the update process control signal. Based on the parameter change amplitude and the wearing status change rate, an adaptive window length calculation algorithm is used to obtain the transition window length parameter; A parameter transition sequence is generated based on the transition window length parameter, and a smooth transition is achieved by using the cosine interpolation method to obtain the transition parameter sequence for each frame. The transition parameter sequence of each frame is applied frame by frame in the noise reduction process, and the output signal quality is monitored at the same time to obtain the application status of the noise reduction curve parameters after smooth transition is completed. Based on the detection results of sudden changes in wearing status, it is determined whether to activate the emergency response. A fast transition channel is used to achieve rapid parameter switching, so as to obtain a noise reduction curve that adapts quickly in emergency scenarios.
6. The headphone adaptive noise reduction curve adjustment method according to claim 1, characterized in that, S5 includes: Based on the feedforward filter coefficients in the current noise reduction curve parameters, the environmental noise signal collected by the feedforward microphone is filtered to obtain the feedforward anti-noise signal. Based on the feedback filter coefficients in the current noise reduction curve parameters, the in-ear noise signal collected by the feedback microphone is filtered to obtain the feedback anti-noise signal. Based on the hybrid gain coefficient in the current noise reduction curve parameters, the feedforward and feedback noise immunity signals are weighted and mixed to obtain a hybrid noise immunity signal. The mixed noise-resistant signal is pre-compensated and filtered based on the secondary channel transfer function to obtain the compensated noise-resistant signal; Personalized equalization processing of audio source signals is performed based on the ear canal transfer function model to obtain equalized audio signals. The compensated noise-resistant signal is mixed and superimposed with the equalized audio signal, and then played through a digital-to-analog converter and a speaker to obtain a low-noise environment and high-fidelity audio effect in the ear canal.
7. The headphone adaptive noise reduction curve adjustment method according to claim 2, characterized in that, The process of identifying low-noise and high-noise frequency bands based on noise energy characteristics, using a spectral notch detection algorithm to mark preferred frequency points of the test signal, and obtaining an adaptive test frequency point distribution scheme includes: The average noise energy across the entire frequency band is calculated as a benchmark. The noise energy of each frequency band is compared with the benchmark value. Frequency bands with noise energy lower than the benchmark value by a preset first percentage are marked as low noise frequency bands, and frequency bands with noise energy higher than the benchmark value by a preset second percentage are marked as high noise frequency bands. The local minimum points of the power spectral density curve are calculated using a spectral depression detection algorithm, and the detected spectral depression locations are used as the preferred frequency points of the test signal. Generate a complete test frequency distribution scheme, which includes preferred frequency points in the low-noise frequency band and necessary frequency points in the high-noise frequency band. The total number of test frequency points is set to a preset first quantity range, covering a preset frequency range. The test signal amplitude is assigned to each test frequency point. The standard amplitude is used in the low noise frequency band, and the boosted amplitude is used in the high noise frequency band. The amplitude boost ratio is calculated based on the noise energy and the target signal-to-noise ratio.
8. The headphone adaptive noise reduction curve adjustment method according to claim 3, characterized in that, The scene-adaptive sensor fusion weights, based on scene type identification and sensor data reliability analysis, employ a hierarchical weight configuration and dynamic adjustment strategy, including: Based on the scene type identifier, the corresponding sensor fusion weight configuration is retrieved from the preset scene parameter library. The scene parameter library contains the basic weight values of acoustic sensors, pressure sensors and acceleration sensors under various scene types. The consistency and quality indicators of the data from each sensor are analyzed. Consistency is measured by the correlation of evaluation results from different sensors, and quality indicators are measured by the signal-to-noise ratio or confidence level of the sensor signals. Increase the weight of sensors with high consistency and good quality, and decrease the weight of sensors with conflicting indications or poor quality. After weight adjustment, normalization is performed to ensure that the sum of all sensor weights is a preset value, thus obtaining scene-adaptive sensor fusion weights.
9. The headphone adaptive noise reduction curve adjustment method according to claim 4, characterized in that, The method, based on the initial noise reduction curve parameters and the ear canal transfer function model, employs a local gradient optimization algorithm to obtain finely optimized noise reduction curve parameters, including: A noise reduction performance evaluation model is established. The input of the model is the noise reduction curve parameters and the ear canal transfer function. The output is the noise reduction depth evaluation value. The noise reduction depth is obtained by simulating the residual noise energy in the ear canal. Establish an optimization objective function, where the objective function is the negative noise reduction depth, and the optimization objective is to minimize the objective function. Establish constraints, including system stability constraints, intraocular sound pressure level constraints, and frequency response flatness constraints; Constrained gradient descent algorithm is used for local optimization. Gradient descent calculates the gradient of the objective function with respect to each parameter and updates the parameters along the negative gradient direction to reduce the value of the objective function. Iteratively perform gradient calculations, parameter updates, and constraint projections until the objective function converges or the preset maximum number of iterations is reached, to obtain finely optimized noise reduction curve parameters.
10. A headphone adaptive noise cancellation curve adjustment system, used to perform the steps in the headphone adaptive noise cancellation curve adjustment method as described in any one of claims 1-9, characterized in that, include: Feedforward microphone module, feedback microphone module, in-ear microphone module, pressure sensor array module, accelerometer module, digital signal processor module, speaker module, and memory module; The feedforward microphone module is deployed on the outside of the earphone to collect ambient noise signals; The feedback microphone module and the in-ear microphone module are deployed inside the earphone near the ear canal to collect sound signals from inside the ear canal; A pressure sensor array module is deployed at the contact point between the earbud and the ear canal to measure the contact pressure distribution. An accelerometer module is deployed on the main body of the earphone to detect the earphone's motion. The digital signal processor module serves as the core computing unit, executing signal processing, parameter optimization, and noise reduction control algorithms. The speaker module is used to play noise-resistant signals and audio signals; The memory module is used to store the noise reduction curve parameter library, ear canal transfer function model, and algorithm program.
