Bioacoustic background estimation model training method, signal denoising method and system, device, medium
By constructing a bioacoustic background estimation model, and using the same background waveform superimposed with different event segments to construct paired observations, and setting transient suppression loss and time-frequency correlation dynamic subtraction coefficients, the event leakage problem in the training of the background estimation model is solved, achieving background suppression and sparse event preservation, and improving the signal denoising effect.
Patent Information
- Application Number
- CN202611654427.2
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2026-10-26
- Publication Date
- 2026-11-24
AI Technical Summary
Existing technologies struggle to effectively train background estimation models when there is a lack of clear event references that are strictly aligned with noisy records. This results in event-related transient responses being included in the predicted background, and fixed subtraction coefficients are insufficient to balance background suppression and sparse event preservation.
By constructing a bioacoustic background estimation model, paired observations are constructed by superimposing different event segments on the same background waveform. Transient suppression loss and time-frequency correlation dynamic subtraction coefficients are set, and the model is trained in conjunction with a multi-scale U-Net network to achieve background estimation and signal denoising.
Without requiring strict alignment with clear event references, it effectively suppresses event leakage into the background while preserving normal background fluctuations, improving the event-background dynamic range and regional signal-to-noise ratio, and adapting to different environmental conditions.
Smart Images

Figure CN123161584A_ABST
Abstract
Description
Technical Field
[0001] This invention relates to the fields of audio signal processing and bioacoustic monitoring technology, and in particular to a bioacoustic background estimation model training method, signal denoising method and system, device and medium. Background Technology
[0002] Bioacoustic recordings typically consist of environmental background and sparsely occurring biological vocalizations. Target events such as bird calls, marine mammal vocalizations, and primate calls may be short in duration, low in energy, and occupy only a small number of time-frequency units; in-situ acquisitions also struggle to obtain clear event signals that are strictly aligned with the noisy recordings.
[0003] Learning-based denoising methods that use the target signal as the regression object typically rely on a clear reference or utilize global reconstruction error to constrain the model output. When the background occupies most time-frequency cells while the target event is distributed in only a few time-frequency cells, weak events contribute limitedly to the global loss, and the model may smooth or attenuate the event structure while suppressing the background.
[0004] Another approach is to first estimate the background and then perform spectral subtraction. When using a fixed subtraction coefficient, each time-frequency unit uses the same background subtraction intensity: if the coefficient is too large, it may subtract event-related components along with the background, while if the coefficient is too small, it may leave more residual background in background-dominant regions.
[0005] Therefore, there is a need for a technique that does not rely on strict alignment for clear event references, can learn the background from coarse-grained segmentation, and can adjust the background subtraction intensity based on the difference between the input components of each time-frequency unit and the background estimate. Summary of the Invention
[0006] The technical problem to be solved by the present invention is to provide a training method for a background estimation model in bioacoustics, which can effectively solve the problem of training a background estimation model when there is a lack of clear event references that are strictly aligned with noisy records, and suppress the entry of event-related transient responses into the predicted background, thereby taking into account both background suppression and sparse event preservation during the background subtraction process.
[0007] Another technical problem to be solved by the present invention is to provide a method and system for signal denoising using a model trained by the above-mentioned bioacoustic background estimation model training method.
[0008] The technical problem to be solved by this invention is achieved through the following technical solution. This invention is a method for training a bioacoustic background estimation model, which includes the following steps:
[0009] (1) Obtain background fragments from the background fragment pool, and obtain a first event-containing fragment and a second event-containing fragment that are different from each other from the event-containing fragment pool;
[0010] (2) The same background waveform corresponding to the background segment is superimposed in the waveform domain with the first event segment after the first transformation and the second event segment after the second transformation to obtain the first paired observation and the second paired observation that share the same background waveform and contain different event components;
[0011] (3) Convert the first paired observation and the second paired observation into a first time-frequency representation and a second time-frequency representation, respectively. Determine the input time-frequency representation and the pairing target from the first time-frequency representation and the second time-frequency representation. Input the input time-frequency representation into the background estimation model to obtain the predicted background representation. Determine the pairing regression loss based on the predicted background representation and the pairing target.
[0012] (4) Determine the transient response time weight of each time frame based on the one-sided positive difference of the input time-frequency representation relative to the paired target;
[0013] (5) Determine the local time baseline of the predicted background representation, calculate the excess of the predicted background representation relative to the sum of the local time baseline and the allowable fluctuation, take the positive part of the excess and calculate the square, and use the transient response time weight to weight the obtained square value to determine the transient suppression loss.
[0014] (6) Update the parameters of the background estimation model based on the paired regression loss and the transient suppression loss.
[0015] Furthermore, constructing the background fragment pool and the event-containing fragment pool includes: extracting fragments from the bioacoustic training records, removing the mean, and resampling.
[0016] The segments are divided according to whether they contain the target bioacoustic event. Segments that do not contain the target bioacoustic event or mainly contain background components are designated as background segments, and segments that contain the target bioacoustic event are designated as event-containing segments. The background segment pool is formed from the background segments, and the event-containing segment pool is formed from the event-containing segments.
[0017] Furthermore, the first transformation and the second transformation respectively include amplitude scaling and time position adjustment; for the i-th event segment, the background dominance ratio is determined according to the following formula, and the corresponding amplitude scaling amount is adjusted according to the preset background dominance ratio:
[0018] (1)
[0019] Where i∈{1,2}, P(·) represents the average power of the waveform, n represents the background waveform corresponding to the background segment, and s i Let 𝒯 represent the i-th event segment.i (s i ) represents the i-th event segment after transformation.
[0020] Furthermore, for each group of the first time-frequency representation and the second time-frequency representation, a one-way regression direction from the first time-frequency representation to the second time-frequency representation or from the second time-frequency representation to the first time-frequency representation is randomly selected, and the forward propagation of the background estimation model is performed once for the selected one-way regression direction.
[0021] Furthermore, when the time-frequency representation of term a is used as the input time-frequency representation and the time-frequency representation of term b is used as the pairing target, the paired regression loss is determined according to the following formula:
[0022] (2)
[0023] Where a, b∈{1,2} and a≠b, Y a Y represents the input time-frequency representation. b f represents the pairing target. θ (Y a ) represents the predicted background representation, F represents the number of frequency points, and T represents the number of time frames;
[0024] When the time-frequency representation of term a is used as the input time-frequency representation and the time-frequency representation of term b is used as the pairing target, the one-sided positive difference is determined according to the following formula:
[0025] (3)
[0026] Where a, b∈{1,2} and a≠b, Y a Y represents the input time-frequency representation. b Let f represent the pairing target, t represent the frequency index, and [·] represent the time index. + Indicates taking the positive part;
[0027] For each time frame, select the K largest difference values (K=⌈ρF⌉) from the frequency point difference values of the single-sided positive difference and calculate the arithmetic mean to obtain the frame-level difference score, where 0<ρ≤1; normalize the frame-level difference score according to the lower and upper quantile values of the frame-level difference score in the time dimension, and crop the normalization result to [0,1] to obtain the soft time gate as the transient response time weight;
[0028] A window of length k is used to perform average pooling along the time dimension of the predicted background representation to obtain the local time baseline. The excess of the predicted background representation relative to the sum of the local time baseline and the allowable fluctuation m is determined. The positive part of the excess is taken and squared. The squared value is weighted using the soft time gate to obtain the transient suppression loss. The paired regression loss is denoted as ℒ. pair a→b The transient suppression loss is denoted as ℒ tr a→b The total training loss is:
[0029] (4)
[0030] Where, λ tr This represents the weight of the transient suppression loss.
[0031] Furthermore, the background estimation model includes a multi-scale U-shaped network, which includes an encoder, a decoder, a bidirectional gated loop unit bottleneck set between the encoder and the decoder, a channel recalibration unit, and a residual fusion unit.
[0032] Furthermore, a bioacoustic signal denoising method is provided, which uses a background estimation model trained using any of the training methods described above. The steps of this method are as follows:
[0033] (1) Obtain the input time-frequency representation of the bioacoustic record to be denoised and the pre-trained background estimation model, wherein the background estimation model is obtained by superimposing the same background waveform with two different event segments in the waveform domain to form paired observations that share the same background waveform, and by using one of the time-frequency representations of the two paired observations as input and the other as the pairing target for paired regression training;
[0034] (2) Input the input time-frequency representation into the background estimation model to obtain the background estimation time-frequency representation;
[0035] (3) Convert the input time-frequency representation and the background estimation time-frequency representation to the linear amplitude domain to obtain the input amplitude spectrum and the background estimation amplitude spectrum;
[0036] (4) For each time-frequency unit, the absolute difference between the input amplitude spectrum and the background estimated amplitude spectrum at that time-frequency unit is normalized according to the preset normalization rule to obtain the normalized time-frequency difference with values in [0, 1].
[0037] (5) The normalized time-frequency difference is directly mapped to the time-frequency correlation subtraction coefficient of the corresponding time-frequency unit, wherein the time-frequency correlation subtraction coefficient decreases as the normalized time-frequency difference increases, and the product of the time-frequency correlation subtraction coefficient and the background estimated amplitude spectrum is subtracted from the input amplitude spectrum to obtain the enhanced amplitude spectrum;
[0038] The time-frequency correlation subtraction coefficient is determined according to the following formula:
[0039] (5)
[0040] Where D(t, f) represents the normalized time-frequency difference, α(t, f) represents the time-frequency correlation subtraction coefficient, and α min =0, α max =1.5;
[0041] The enhanced amplitude spectrum is determined according to the following formula:
[0042] (6)
[0043] Among them, M y (t, f) represents the input amplitude spectrum, M̂ n (t, f) represents the estimated amplitude spectrum of the background, and β represents the pre-set fixed spectral base coefficient.
[0044] Furthermore, a bioacoustic signal denoising system is provided for performing the bioacoustic signal denoising method described above. The system includes:
[0045] The time-frequency representation acquisition module is configured to acquire the input time-frequency representation of the bioacoustic record to be denoised;
[0046] The model storage and background estimation module is configured to store a pre-trained background estimation model and input the input time-frequency representation into the background estimation model to obtain a background estimation time-frequency representation. The background estimation model is obtained by superimposing the same background waveform with two different event segments in the waveform domain to form two paired observations that share the same background waveform, and by performing paired regression training with one of the time-frequency representations of the two paired observations as input and the other as the paired target.
[0047] A linear amplitude conversion module is configured to convert the input time-frequency representation and the background estimated time-frequency representation into an input amplitude spectrum and a background estimated amplitude spectrum;
[0048] The difference and coefficient determination module is configured to normalize the absolute difference between the input amplitude spectrum and the background estimated amplitude spectrum at each time-frequency unit according to a preset normalization rule, so as to obtain a normalized time-frequency difference with a value in [0, 1], and directly map the normalized time-frequency difference to the time-frequency correlation subtraction coefficient of the corresponding time-frequency unit, wherein the time-frequency correlation subtraction coefficient decreases as the normalized time-frequency difference increases;
[0049] The background subtraction module is configured to subtract the product of the time-frequency correlation subtraction coefficient and the estimated background amplitude spectrum from the input amplitude spectrum to obtain the enhanced amplitude spectrum.
[0050] Furthermore, an electronic device includes at least one processor and a memory communicatively connected to the at least one processor, the memory storing a computer program executable by the at least one processor, the computer program, when executed, causing the electronic device to perform the method described above.
[0051] Furthermore, a non-transitory computer-readable storage medium stores a computer program thereon, which, when executed by at least one processor, implements the methods described above.
[0052] Compared with the prior art, the beneficial effects of the present invention are as follows:
[0053] 1. This invention constructs paired observations by superimposing different event fragments on the same background waveform. It only requires coarse segmentation at the fragment level and does not require strictly aligned clear event references, making it suitable for actual data conditions of bioacoustics in the field.
[0054] 2. This invention sets a transient suppression loss and relies on a soft time gate to penalize the excess response of events in the predicted background, thereby suppressing the leakage of biological events into the background while preserving normal background fluctuations.
[0055] 3. This invention employs time-frequency correlated dynamic subtraction coefficients, strong noise reduction in the background region, and reduced subtraction intensity in the event region, combined with spectral bottom constraints, to solve the problem that fixed spectrum subtraction is prone to leaving noise or erasing weak events.
[0056] 4. The multi-scale U-Net fusion of temporal and frequency domain features of the present invention can improve the event-background dynamic range and regional signal-to-noise ratio in bird, marine mammal, and primate data, and completely preserve the temporal and frequency profiles of biological vocalizations.
[0057] 5. The key parameters of this invention are configurable, and it can be retrained and adapted for new environments; it can be implemented as a system, electronic device and storage medium to serve downstream tasks such as species identification and behavior analysis. Attached Figure Description
[0058] Figure 1This is a schematic diagram illustrating the overall process of background consistency pairing construction, background estimation model training, and adaptive background subtraction in this invention.
[0059] Figure 2 This is a schematic diagram comparing the target signal recovery pairing approach with the learning approach in the background of this invention;
[0060] Figure 3 A comparison of the spectrograms of the original input, the basic scheme, the scheme of this invention, and the corresponding background estimation output in the Ocean recording example;
[0061] Figure 4 A comparison of spectrograms for HSN natural recording examples;
[0062] Figure 5 A comparison of spectrograms for SNE natural recording examples;
[0063] Figure 6 Spectrogram comparison of controlled reference examples formed by the marmoset incident reference and the HSN background;
[0064] Figure 7 A comparison of spectrograms of controlled reference examples formed by the marmoset incident and the SNE background. Detailed Implementation
[0065] To make the objectives, technical solutions, and advantages of the embodiments of the present invention clearer, the technical solutions of the embodiments of the present invention will be clearly and completely described below with reference to the accompanying drawings. Obviously, the described embodiments are only some embodiments of the present invention, not all embodiments. Based on the embodiments of the present invention, all other embodiments obtained by those skilled in the art without creative effort are within the scope of protection of the present invention.
[0066] Figure 1 The complete data stream for training and inference is shown; the background fragment pool B and the event fragment pool S provide background fragments and event fragments respectively; "background dominance ratio scaling" indicates the amplitude adjustment according to the background dominance ratio; the lowercase y1 and y2 at the arrows after the short-time Fourier transform are abbreviated as shown in the figure, and the corresponding time-frequency representations are uniformly written as uppercase Y1 and Y2 in the text. Figure 2 This is used to illustrate the technical concept of shifting from recovery pairing of a class of target signals to background learning. Figures 3 to 7 This is used to illustrate the output format under different recording and controlled reference conditions. The following embodiments are used to illustrate the technical solution of the present invention and are not intended to limit the scope of protection of the claims.
[0067] In this specification, "event-containing segment" refers to a recording segment containing the target bioacoustic event. An event-containing segment is not required to be an isolated, clear event separated from the background; it may also contain shared background or other acoustic components. "Background segment" refers to a recording segment in which no target bioacoustic event was detected or which primarily contains background components. "Predicted background representation" is the background-dominant shared representation output by the background estimation model and is not required to be identical point-by-point to the background waveform used in constructing paired observations.
[0068] Example 1: Training Segment Preparation
[0069] See Figure 1 The original bioacoustic training records are segmented, mean-removed, and resampled. Candidate segments are obtained through automatic screening and then manually reviewed and corrected. Segments that do not detect the target bioacoustic event or mainly contain background components are classified as background segments, and segments that contain the target bioacoustic event are classified as event-containing segments. Background segments form a background segment pool B, and event-containing segments form an event-containing segment pool S.
[0070] The segments used for training, validation, and testing are obtained from different source recordings, and background segments are not reused between different data partitions. This partitioning method is used to reduce the occurrence of background features from the same source recording appearing in both the training and testing data.
[0071] Example 2: Background Consistency Pairing Construction
[0072] See Figure 1 Background segments are obtained from background segment pool B, and the waveform of the background segment is denoted as n. First event-containing segment s1 and second event-containing segment s2, which are different from each other, are obtained from event-containing segment pool S. Amplitude scaling and time position adjustment are performed on s1 and s2 respectively, denoted as the first transformation. The second transformation, 𝒯2, is then applied. The transformed event segments are superimposed onto the same background waveform to obtain:
[0073] (7)
[0074] The first paired observation y1 and the second paired observation y2 share the same background waveform n, but contain different event components. Equation (7) is performed in the waveform domain; after converting the paired observations into time-frequency representations, it is not assumed that the resulting time-frequency representation is equal to the linear sum of the background time-frequency representation and the time-frequency representation containing the event segments.
[0075] The magnitude of the inserted component is controlled by the background dominance ratio. Figure 1The term "background dominance ratio scaling" refers to this intensity adjustment step; in this embodiment, scaling is performed according to the background dominance ratio defined by the following formula, which differs from the traditional isolated event signal-to-noise ratio. For the i-th event segment, the background dominance ratio is:
[0076] (8)
[0077] In equation (8), P(·) represents the average power of the waveform. The background dominance ratio represents the power relationship between the shared background waveform and the complete transformed event segment, and is not equivalent to the signal-to-noise ratio between an isolated clear event and pure noise. The transform is adjusted according to the preset background dominance ratio. i The scaling factor.
[0078] After pre-emphasis or high-pass filtering of the first and second paired observations, a short-time Fourier transform is performed, and the power spectrum is converted to the decibel domain to obtain the first time-frequency representation Y1 and the second time-frequency representation Y2, which are used for training the background estimation model.
[0079] In one set of embodiments of bird and marmoset recordings, the audio sampling rate was 32 kHz, the short-time Fourier transform window length was 1024 samples, the frame shift was 256 samples, and the frequency band from 400 Hz to 16 kHz was preserved.
[0080] In one set of embodiments of marine mammal recording, the audio sampling rate is 128 kHz, the short-time Fourier transform window length is 1024 sampling points, the frame shift is 512 sampling points, and the frequency band from 200 Hz to 64 kHz is preserved.
[0081] Example 3: Training the Background Estimation Model
[0082] For each pair of Y1 and Y2, either Y1→Y2 or Y2→Y1 is randomly selected as the unidirectional regression direction. The first term of the selected direction is used as the input time-frequency representation, and the second term is used as the paired target. For each pair of observations, a model forward propagation is performed once for the selected direction.
[0083] The background estimation model is expressed as:
[0084] (9)
[0085] In equation (9), Y represents the input time-frequency representation. Let be the background estimation model with parameter θ, and N̂ be the predicted background representation. For the chosen a→b regression direction, the paired regression loss is:
[0086] (10)
[0087] In equation (10), a, b ∈ {1, 2} and a ≠ b, F is the number of frequency points, T is the number of time frames, and ||·|| F This represents the Frobenius norm.
[0088] In one embodiment, the background estimation model employs Figure 1 The ST-UNet shown is a multi-scale U-shaped network, which includes an encoder, a decoder, a bidirectional gated recurrent unit bottleneck between the encoder and decoder, a channel recalibration unit in the encoder and decoder, and a residual fusion unit.
[0089] Example 4: Transient Suppression Loss
[0090] For the selected a→b regression direction, first calculate the one-sided positive difference of the input time-frequency representation relative to the paired target:
[0091] (11)
[0092] In equation (11), [x] + =max(x, 0), where f is the frequency index and t is the time index. For each time frame, select the K = ⌈ρF⌉ largest difference values from the frequency differences of the single-sided differences and calculate their arithmetic mean:
[0093] (12)
[0094] In equation (12), This represents a vector consisting of one-sided positive difference values at all frequency points in the t-th time frame, where the colon indicates all frequency points; This represents the set of frequency indices corresponding to the K largest differences in the vector; ρ is the proportion of frequency points selected, 0 < ρ ≤ 1; The frame-level difference score is the arithmetic mean of the selected K difference values.
[0095] Calculate the lower quantile Q of the frame-level difference score for all time frames. l and upper quantile Q h This yields the soft time gate:
[0096] (13)
[0097] In equation (13), and represents the lower and upper quantile values of the frame-level difference scores for all time frames, serving as the lower and upper bounds for normalization; clip(·,0,1) clips the normalized result to [0,1]; ε is a positive number set to avoid a zero denominator. Calculate the predicted background representation and its local temporal baseline:
[0098] (14)
[0099] In equation (14), This indicates that the input time-frequency representation will be used. The predicted background representation obtained from the input background estimation model; Indicates its local time baseline; This indicates that an average pooling operation with a window length of k is performed along the time dimension t, where k is the time window length.
[0100] The transient suppression loss is:
[0101] (15)
[0102] In equation (15), Indicates input time-frequency representation The corresponding predicted background is represented by the values at the frequency index f and the time index t; This represents the local time baseline value at that time-frequency location; m is the allowable local background fluctuation. Only when the predicted background representation is higher than the sum of the local time baseline and m, the positive part of the corresponding excess is squared, and the squared value is weighted using a soft time gate. The total training loss is:
[0103] (16)
[0104] In equation (16), λ tr λ represents the weights for the transient suppression loss. In a series of ocean recording experiments, λ was used as the weights for each loss. tr The values were set to 0, 0.05, 0.1, 0.2, 0.5, 1, and 2 for testing; in the training implementation using the same parameters, λ... tr Take 0.5.
[0105] In one set of training examples, the Adam optimizer was trained for 20 epochs with a learning rate of 10. -4 The weight decays to 10. -5 .
[0106] Example 5: Adaptive Background Subtraction
[0107] See Figure 1 The inference process involves converting the bioacoustic recording to be denoised into an input time-frequency representation, which is then input into a pre-trained background estimation model to obtain a background estimation time-frequency representation. Both the input time-frequency representation and the background estimation time-frequency representation are then transformed into the linear amplitude domain to obtain the input amplitude spectrum M. y (t, f) and background estimation amplitude spectrum M̂ n (t, f).
[0108] Perform a preset normalization operation on the nonnegative difference map between the input amplitude spectrum and the estimated background amplitude spectrum, so that the normalization result is between 0 and 1, to obtain:
[0109] (17)
[0110] In equation (17), 𝒩(·) represents the normalization operation performed on the difference plot, and D(t, f) represents the normalized time-frequency difference. The time-frequency correlation subtraction coefficient is:
[0111] (18)
[0112] In one embodiment, α min =0, α max =1.5. The smaller D(t,f), the closer α(t,f) is to α. max As D(t,f) increases, α(t,f) decreases according to equation (18).
[0113] The enhanced amplitude spectrum is as follows:
[0114] (19)
[0115] In equation (19), β is a pre-set fixed spectral base coefficient, βM y (t, f) is used to limit the spectral valley depth of the enhanced amplitude spectrum. The time-frequency correlation subtraction coefficients are calculated by equations (17) and (18) without having to perform the background estimation model again.
[0116] Example 6: Systems, Electronic Devices, and Storage Media
[0117] The bioacoustic signal denoising system includes a time-frequency representation acquisition module, a model storage and background estimation module, a linear amplitude conversion module, a difference and coefficient determination module, and a background subtraction module. Each module can be implemented by a program executing on one or more processors, or by hardware circuits with corresponding computing functions.
[0118] The time-frequency representation acquisition module obtains the input time-frequency representation of the bioacoustic record to be denoised. The model storage and background estimation module stores the background estimation model trained through background consistency paired observations and outputs the background estimated time-frequency representation based on the input time-frequency representation. The linear amplitude transformation module converts the input time-frequency representation and the background estimated time-frequency representation into the input amplitude spectrum and the background estimated amplitude spectrum, respectively.
[0119] The difference and coefficient determination module calculates the normalized time-frequency difference between the input amplitude spectrum and the estimated background amplitude spectrum, and determines the time-frequency correlation subtraction coefficient based on this difference. The background subtraction module subtracts the product of the time-frequency correlation subtraction coefficient and the estimated background amplitude spectrum from the input amplitude spectrum, and limits the minimum value of the enhanced amplitude spectrum according to the fixed spectral base coefficient.
[0120] The electronic device includes at least one processor and a memory communicatively connected to the processor. The memory stores a computer program executable by the processor; when executed, the program causes the electronic device to perform the background estimation model training method described in Examples 1 to 4, or the bioacoustic signal denoising method described in Example 5. The electronic device may also include a communication interface for acquiring audio recordings or outputting enhanced amplitude spectra.
[0121] The non-transitory computer-readable storage medium may be a magnetic storage medium, an optical storage medium, or a semiconductor storage medium, and the computer program stored thereon, when executed by at least one processor, implements the above-mentioned training method or denoising method.
[0122] Example 7: Experimental Case
[0123] To evaluate the enhancement results, in the event region Ω s and background area Ω n Calculate the dynamic range DR (Ω) and the dynamic range difference diff, respectively. db and regional signal-to-noise ratio (SNR) roi The dynamic range is the difference between the 0.99th and 0.01st quantiles of the power decibel spectrum within the region; diff db =DR(Ω s )-DR(Ω n For the power-to-density spectrum M, let P = 10. M / 10 and according to SNR roi =10log 10 ((mean(P Ω_s )+ε roi ) / (mean(P Ω_n )+ε roi )) Calculate the regional signal-to-noise ratio, where ε roi =10 -12 Used for numerical stability. Among them, Indicates the event area The arithmetic mean of the linear power P of all time-frequency units within the range. Indicates background area The arithmetic mean of the linear power P of all time-frequency units within the diff. For enhanced output, diff db and SNR roi The larger the value of , the higher the contrast between the event region and the background region; for the background estimation output, the lower the value of , the lower the degree to which the event-related components enter the background estimation.
[0124] Figures 3 to 5Example test recordings are provided. In each figure, "Noisy Input" represents the original noisy spectrogram; "Basic Scheme" represents the output of the basic scheme using only background consistency paired regression and fixed subtraction; "This Example" represents the output of the example using both transient suppression loss and time-frequency correlation subtraction. The "Enhanced Output" row represents the enhancement result, and the "Background Estimation Output" row represents the corresponding background estimation output. In the example shown, the event time-frequency contours in the enhanced output are more easily identifiable than the input, and the background estimation output mainly presents a background-dominated structure. The visual difference between the basic scheme and this example represents the output difference after the combined application of the two improvements, and is not attributed to either improvement alone. The corresponding test metrics are shown in the table below, with values in descending order of diff. db / snr roi .
[0125] Table 1 Comparison of Enhancement Result Metrics for Natural Recording Examples
[0126] Dataset Input records This embodiment SNE Bird Recordings 13.74 / 12.59 28.85 / 31.91 HSN Bird Recordings 7.86 / 7.10 23.44 / 20.12 Ocean Whistle 4.85 / 3.44 22.52 / 10.82 Ocean Click Sound -1.40 / -3.30 11.57 / 3.00
[0127] Figure 6 and Figure 7 A controlled reference example is given, where "noisy input" represents the controlled mixed input, "basic scheme," "this embodiment," "enhanced output," and "background estimation output" retain their aforementioned meanings, and "event reference" represents an approximately clear marmoset event reference used only for evaluation and not as a paired training target for the background estimation model. After mixing the event reference with either the HSN background or the SNE background at a 10dB background dominance ratio, in the example shown, the main event trajectory of the enhanced output of this embodiment corresponds to the event reference in time-frequency position, and no identical complete event contour is seen in the corresponding background estimation output. The metrics of the mixed input and the enhancement results of this embodiment are shown in the table below.
[0128] Table 2 Comparison of Enhancement Result Metrics for Controlled Reference Examples
[0129] Experimental combination Mixed input This embodiment IMV-SNE 26.09 / 20.07 63.56 / 47.71 IMV-HSN 19.64 / 13.72 59.08 / 45.07
[0130] To compare the fixed subtraction coefficient and the time-frequency correlation subtraction coefficient, experiments were conducted on Ocean data under the same background estimation and the same fixed spectral base coefficient. The fixed subtraction coefficient was set to 1, and the time-frequency correlation subtraction coefficient varied between 0 and 1.5 according to equation (18). The results are shown in the table below. This comparison table retains the original listing accuracy of the corresponding experimental table. Therefore, the regional signal-to-noise ratio of Ocean click sound is 3.01, which differs from the 3.00 in the aforementioned natural recording summary table due to rounding.
[0131] Table 3 Comparison of experimental results between fixed subtraction coefficient and time-frequency correlation subtraction coefficient
[0132] Subtraction method Ocean Whistle Ocean Click Sound Fixed subtraction coefficient 19.31 / 10.25 8.76 / 2.49 Adaptive subtraction coefficient 22.52 / 10.82 11.57 / 3.01
[0133] Under the same network structure and optimization settings, different pairing construction methods and output methods were compared. The background consistency pairing method resulted in enhanced output metrics of 22.52 / 10.82 and 11.57 / 3.01 for Ocean whistle and Ocean click sounds, respectively; the corresponding values for direct background regression were 5.86 / 3.87 and -2.06 / -3.14; and the corresponding values for non-shared background pairing were 8.77 / 5.82 and -0.06 / -0.99. All groups used the same network structure and optimization settings, but differed in pairing construction methods or output methods.
[0134] The background dominance ratio was tested at 0dB, 5dB, 10dB, 15dB, and 20dB. Under the Ocean experimental conditions, when the background dominance ratio was 10dB, the whistle enhancement index was 22.52 / 10.82, and the click enhancement index was 11.57 / 3.01. When the background dominance ratio was 15dB or 20dB, both enhancement indices were lower than those corresponding to 10dB. In one set of embodiments, the background dominance ratio was set to 10dB.
[0135] Figures 3 to 7 The three experimental tables mentioned above only correspond to the dataset, data partitioning, and parameter settings, and do not constitute a limitation on performance values in any acoustic environment. When the target event is completely masked by the background, this method cannot recover non-existent event information from the observations; when the background distribution of the recording to be processed is different from that of the training recording, the background segment and the event-containing segment can be re-obtained from the recording of the target acoustic environment, and the paired observation can be constructed and the background estimation model trained according to Example 2.
Claims
1. A method for training a background estimation model in bioacoustics, characterized in that: The method includes the following steps: (1) Obtain background fragments from the background fragment pool, and obtain a first event-containing fragment and a second event-containing fragment that are different from each other from the event-containing fragment pool; (2) The same background waveform corresponding to the background segment is superimposed in the waveform domain with the first event segment after the first transformation and the second event segment after the second transformation to obtain the first paired observation and the second paired observation that share the same background waveform and contain different event components; (3) Convert the first paired observation and the second paired observation into a first time-frequency representation and a second time-frequency representation, respectively. Determine the input time-frequency representation and the pairing target from the first time-frequency representation and the second time-frequency representation. Input the input time-frequency representation into the background estimation model to obtain the predicted background representation. Determine the pairing regression loss based on the predicted background representation and the pairing target. (4) Determine the transient response time weight of each time frame based on the one-sided positive difference of the input time-frequency representation relative to the paired target; (5) Determine the local time baseline of the predicted background representation, calculate the excess of the predicted background representation relative to the sum of the local time baseline and the allowable fluctuation, take the positive part of the excess and calculate the square, and use the transient response time weight to weight the obtained square value to determine the transient suppression loss. (6) Update the parameters of the background estimation model based on the paired regression loss and the transient suppression loss.
2. The method for training a background estimation model for bioacoustics according to claim 1, characterized in that: Constructing the background fragment pool and the event-containing fragment pool includes: extracting fragments from the bioacoustic training records, removing the mean, and resampling; The segments are divided according to whether they contain the target bioacoustic event. Segments that do not contain the target bioacoustic event or mainly contain background components are designated as background segments, and segments that contain the target bioacoustic event are designated as event-containing segments. The background segment pool is formed from the background segments, and the event-containing segment pool is formed from the event-containing segments.
3. The method for training a background estimation model for bioacoustics according to claim 1, characterized in that: The first transformation and the second transformation respectively include amplitude scaling and time position adjustment; for the i-th event segment, the background dominance ratio is determined according to the following formula, and the corresponding amplitude scaling amount is adjusted according to the preset background dominance ratio: (1) Where i∈{1,2}, P(·) represents the average power of the waveform, n represents the background waveform corresponding to the background segment, and s i Let 𝒯 represent the i-th event segment. i (s i ) represents the i-th event segment after transformation.
4. The method for training a background estimation model for bioacoustics according to claim 1, characterized in that: For each group of the first time-frequency representation and the second time-frequency representation, a one-way regression direction from the first time-frequency representation to the second time-frequency representation or from the second time-frequency representation to the first time-frequency representation is randomly selected, and the forward propagation of the background estimation model is performed once for the selected one-way regression direction.
5. The method for training a background estimation model for bioacoustics according to claim 1, characterized in that: When the time-frequency representation of term a is used as the input time-frequency representation and the time-frequency representation of term b is used as the pairing target, the paired regression loss is determined according to the following formula: (2) Where a, b∈{1,2} and a≠b, Y a Y represents the input time-frequency representation. b f represents the pairing target. θ (Y a ) represents the predicted background representation, F represents the number of frequency points, and T represents the number of time frames; When the time-frequency representation of term a is used as the input time-frequency representation and the time-frequency representation of term b is used as the pairing target, the one-sided positive difference is determined according to the following formula: (3) Where a, b∈{1,2} and a≠b, Y a Y represents the input time-frequency representation. b Let f represent the pairing target, t represent the frequency index, and [·] represent the time index. + Indicates taking the positive part; For each time frame, select the K largest difference values (K=⌈ρF⌉) from the frequency point difference values of the single-sided positive difference and calculate the arithmetic mean to obtain the frame-level difference score, where 0<ρ≤1; normalize the frame-level difference score according to the lower and upper quantile values of the frame-level difference score in the time dimension, and crop the normalization result to [0,1] to obtain the soft time gate as the transient response time weight; A local time baseline is obtained by performing average pooling with a window length of k along the time dimension on the predicted background representation. The excess of the predicted background representation relative to the sum of the local time baseline and the allowable fluctuation m is determined. The positive part of the excess is taken and squared. The squared value is weighted using a soft time gate to obtain the transient suppression loss. The paired regression loss is denoted as ℒ. pair a→b Let the transient suppression loss be denoted as ℒ tr a→b The total training loss is: (4) Where, λ tr This represents the weight of the transient suppression loss.
6. The method for training a background estimation model for bioacoustics according to claim 1, characterized in that: The background estimation model includes a multi-scale U-shaped network, which includes an encoder, a decoder, a bidirectional gated loop unit bottleneck set between the encoder and the decoder, a channel recalibration unit, and a residual fusion unit.
7. A method for denoising bioacoustic signals, characterized in that: This method uses a background estimation model trained by the bioacoustic background estimation model training method described in any one of claims 1-6. The steps of this method are as follows: (1) Obtain the input time-frequency representation of the bioacoustic record to be denoised and the pre-trained background estimation model, wherein the background estimation model is obtained by superimposing the same background waveform with two different event segments in the waveform domain to form paired observations that share the same background waveform, and by using one of the time-frequency representations of the two paired observations as input and the other as the pairing target for paired regression training; (2) Input the input time-frequency representation into the background estimation model to obtain the background estimation time-frequency representation; (3) Transform the input time-frequency representation and the background estimated time-frequency representation to the linear amplitude domain to obtain the input amplitude spectrum and the background estimated amplitude spectrum; (4) For each time-frequency unit, the absolute difference between the input amplitude spectrum and the estimated amplitude spectrum of the background is normalized according to the preset normalization rule to obtain the normalized time-frequency difference with values in [0, 1]. (5) The normalized time-frequency difference is directly mapped to the time-frequency correlation subtraction coefficient of the corresponding time-frequency unit, wherein the time-frequency correlation subtraction coefficient decreases as the normalized time-frequency difference increases. The product of the time-frequency correlation subtraction coefficient and the background estimated amplitude spectrum is subtracted from the input amplitude spectrum to obtain the enhanced amplitude spectrum. The time-frequency correlation subtraction coefficient is determined according to the following formula: (5) Where D(t,f) represents the normalized time-frequency difference, α(t,f) represents the time-frequency correlation subtraction coefficient, and α min =0, α max =1.5; The enhancement amplitude spectrum is determined according to the following formula: (6) Among them, M y (t, f) represents the input amplitude spectrum, M̂ n (t, f) represents the background estimated amplitude spectrum, and β represents the pre-set fixed spectral base coefficient.
8. A bioacoustic signal denoising system, characterized in that: This system is used to perform the bioacoustic signal denoising method according to claim 7, and the system comprises: The time-frequency representation acquisition module is configured to acquire the input time-frequency representation of the bioacoustic record to be denoised; The model storage and background estimation module is configured to store a pre-trained background estimation model and input the input time-frequency representation into the background estimation model to obtain a background estimation time-frequency representation. The background estimation model is obtained by superimposing the same background waveform with two different event segments in the waveform domain to form two paired observations that share the same background waveform, and by performing paired regression training with one of the time-frequency representations of the two paired observations as input and the other as the paired target. A linear amplitude conversion module is configured to convert the input time-frequency representation and the background estimated time-frequency representation into an input amplitude spectrum and a background estimated amplitude spectrum; The difference and coefficient determination module is configured to normalize the absolute difference between the input amplitude spectrum and the background estimated amplitude spectrum at each time-frequency unit according to a preset normalization rule, so as to obtain a normalized time-frequency difference with a value in [0, 1], and directly map the normalized time-frequency difference to the time-frequency correlation subtraction coefficient of the corresponding time-frequency unit, wherein the time-frequency correlation subtraction coefficient decreases as the normalized time-frequency difference increases; The background subtraction module is configured to subtract the product of the time-frequency correlation subtraction coefficient and the estimated background amplitude spectrum from the input amplitude spectrum to obtain the enhanced amplitude spectrum.
9. An electronic device comprising at least one processor and a memory communicatively connected to said at least one processor, said memory storing a computer program executable by said at least one processor, characterized in that: When the computer program is executed, it causes the electronic device to perform the method described in any one of claims 1-7.
10. A non-transitory computer-readable storage medium having a computer program stored thereon, characterized in that, When the computer program is executed by at least one processor, it implements the method described in any one of claims 1-7.
