Model training methods, devices and electronic equipment

By dividing the noise reduction task into multiple sub-tasks and gradually optimizing the model weight parameters, the problem of balancing noise suppression and speech quality in AI noise reduction models is solved, improving audio processing performance and shortening convergence time.

CN116304658BActive Publication Date: 2026-01-30VIVO MOBILE COMM CO LTD
View PDF 2 Cites 0 Cited by

Patent Information

Application Number
CN202211090650.0
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2022-09-07
Publication Date
2026-01-30
Estimated Expiration
2042-09-07

AI Technical Summary

Technical Problem

Existing AI noise reduction models struggle to achieve an ideal balance between noise suppression and speech quality when processing audio, resulting in poor audio processing performance.

Method used

The noise reduction task is divided into multiple sub-tasks, and each sub-task is trained as a stage. By using different loss functions and learning rates, the model weight parameters are gradually optimized to retain the training effect of the previous stage and set an appropriate loss function, so as to finally obtain a better noise reduction effect.

Benefits of technology

It achieves a good balance between noise suppression and speech quality, improves the overall audio processing effect of the noise reduction model, shortens the convergence time, and maintains speech quality.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN116304658B_ABST
    Figure CN116304658B_ABST
Patent Text Reader

Abstract

This application discloses a model training method, apparatus, and electronic device, belonging to the field of signal processing technology. The method includes: acquiring initial training information, wherein the initial training information includes a first subtask, a first loss function, and a training model; performing first task training on the first subtask based on the training model to obtain first model weight parameters of the training model, wherein the loss function for the first task training is the first loss function; performing second task training on a second subtask based on the training model and the first model weight parameters to obtain second model weight parameters of the training model, wherein the second subtask is different from the first subtask, the loss function for the second task training is the second loss function, and the second loss function is different from the first loss function; and obtaining target model weight parameters of the training model based on the second model weight parameters.
Need to check novelty before this filing date? Find Prior Art

Description

TECHNICAL FIELD

[0001] The present application belongs to the technical field of signal processing, and particularly relates to a model training method and device and electronic equipment. BACKGROUND

[0002] When a voice call is made, the user on the receiving end may not be able to clearly hear the speaking content of the opposite party due to noise interference from the surrounding environment, and thus the electronic device of the user on the receiving end needs to perform noise reduction processing on the audio, for example, suppress the noise of the surrounding environment in the audio signal and retain the human voice to improve the acceptability of the voice.

[0003] At present, the existing noise reduction method is to perform noise reduction processing on the audio signal through artificial intelligence (AI) neural network technology, that is, to perform weighted summation by using multiple loss functions with different tendencies and to train the AI noise reduction model by using the obtained total loss value, so that the electronic device can process the audio signal through the trained AI noise reduction model to obtain the noise-reduced audio signal.

[0004] However, in the above method, in the process of performing weighted summation by using multiple loss functions with different tendencies, if there is a large difference between the dimensions of the multiple loss functions, the electronic device is difficult to make the trained AI noise reduction model achieve a relatively ideal balance between noise suppression and voice quality when performing weight distribution, thereby causing poor audio processing effect of the AI noise reduction model. SUMMARY

[0005] The purpose of the embodiments of the present application is to provide a model training method, device and electronic equipment, which can solve the problem of poor audio processing effect of the AI noise reduction model.

[0006] In a first aspect, the embodiments of the present application provide a model training method, which comprises: obtaining initial training information, wherein the initial training information comprises a first subtask, a first loss function and a training model; performing first task training on the first subtask based on the training model to obtain first model weight parameters of the training model, wherein the loss function of the first task training is the first loss function; performing second task training on a second subtask based on the training model and the first model weight parameters to obtain second model weight parameters of the training model, wherein the second subtask is different from the first subtask, the loss function of the second task training is a second loss function, and the second loss function is different from the first loss function; and obtaining target model weight parameters of the training model based on the second model weight parameters.

[0007] In a second aspect, an embodiment of the present application provides a model training apparatus, which comprises an acquisition module and a processing module. The acquisition module is configured to acquire initial training information, wherein the initial training information comprises a first subtask, a first loss function and a training model. The processing module is configured to perform first task training on the first subtask based on the training model acquired by the acquisition module to obtain first model weight parameters of the training model, wherein the loss function of the first task training is the first loss function; perform second task training on a second subtask based on the training model and the first model weight parameters to obtain second model weight parameters of the training model, wherein the second subtask is different from the first subtask, the loss function of the second task training is a second loss function, and the second loss function is different from the first loss function; and obtain target model weight parameters of the training model based on the second model weight parameters obtained by the training module.

[0008] In a third aspect, an embodiment of the present application provides an electronic device, which comprises a processor and a memory. The memory stores programs or instructions executable on the processor. When the programs or instructions are executed by the processor, the steps of the method according to the first aspect are implemented.

[0009] In a fourth aspect, an embodiment of the present application provides a readable storage medium, which stores programs or instructions. When the programs or instructions are executed by a processor, the steps of the method according to the first aspect are implemented.

[0010] In a fifth aspect, an embodiment of the present application provides a chip, which comprises a processor and a communication interface. The communication interface is coupled to the processor. The processor is configured to execute programs or instructions to implement the method according to the first aspect.

[0011] In a sixth aspect, an embodiment of the present application provides a computer program product stored in a storage medium. The program product is executed by at least one processor to implement the method according to the first aspect.

[0012] In the embodiments of the present application, the electronic device can train the first subtask based on the acquired initial training information to obtain the first model weight parameters, and train the second subtask according to the first model weight parameters, so as to obtain the target model weight parameters based on the obtained second model weight parameters, so that the electronic device can perform noise reduction processing on the audio signal by using the training model. In the present scheme, the noise reduction task is divided into several subtasks, each subtask is trained as a stage, the model weight parameters with good training effect in the current stage can be used as the initial weight of the next subtask, and the learning rate of the next subtask is decayed, so that the model can retain the training effect of the previous stage, and different loss functions are set to finally obtain a better noise reduction effect. BRIEF DESCRIPTION OF DRAWINGS

[0013] Figure 1 is one of flowcharts of a model training method provided by an embodiment of the present application;

[0014] Figure 2 is another flowchart of a model training method provided by an embodiment of the present application;

[0015] Figure 3 is a flowchart of a training process of an AI denoising model on a subtask provided by an embodiment of the present application;

[0016] Figure 4 is a schematic diagram of a SI-SNR loss function curve provided by an embodiment of the present application;

[0017] Figure 5 is a flowchart of a training process of model weights of N subtasks provided by an embodiment of the present application;

[0018] Figure 6 is a third flowchart of a model training method provided by an embodiment of the present application;

[0019] Figure 7 is one of comparison schematic diagrams of results of an audio signal respectively processed by two kinds of denoising and the original audio signal provided by an embodiment of the present application;

[0020] Figure 8 is another comparison schematic diagram of results of an audio signal respectively processed by two kinds of denoising and the original audio signal provided by an embodiment of the present application;

[0021] Figure 9 is a third comparison schematic diagram of results of an audio signal respectively processed by two kinds of denoising and the original audio signal provided by an embodiment of the present application;

[0022] Figure 10 is a fourth comparison schematic diagram of results of an audio signal respectively processed by two kinds of denoising and the original audio signal provided by an embodiment of the present application;

[0023] Figure 11 is a fifth comparison schematic diagram of results of an audio signal respectively processed by two kinds of denoising and the original audio signal provided by an embodiment of the present application;

[0024] Figure 12 is a structural schematic diagram of a model training device provided by an embodiment of the present application;

[0025] Figure 13 is one of hardware structural schematic diagrams of an electronic device provided by an embodiment of the present application;

[0026] Figure 14Fig. 2 is a schematic diagram of a hardware structure of an electronic device according to an embodiment of the present application. DETAILED DESCRIPTION

[0027] The technical solutions in the embodiments of the present application will be clearly and completely described below with reference to the drawings in the embodiments of the present application. Obviously, the described embodiments are some of the embodiments of the present application, rather than all the embodiments of the present application. Based on the embodiments in the present application, all other embodiments obtained by those of ordinary skill in the art without creative work fall within the scope of protection of the present application.

[0028] The terms "first", "second", and the like in the specification and claims of the present application are used to distinguish similar objects, and are not used to describe a specific order or sequence. It should be understood that the data used in this way can be interchanged under appropriate circumstances, so that the embodiments of the present application can be implemented in an order other than those illustrated or described herein, and the objects distinguished by "first", "second", etc. are generally a category and do not limit the number of objects, for example, the first object can be one or more. In addition, "and / or" in the specification and claims indicates at least one of the connected objects, and the character " / ", generally indicates that the front and rear associated objects are in an "or" relationship.

[0029] The model training method provided by the embodiments of the present application will be described in detail below with reference to the drawings, through specific embodiments and their application scenarios.

[0030] When a user makes a voice call, the user will be affected by the noise in the surrounding environment, resulting in the inability to clearly hear the speaking content of the opposite party. At this time, the electronic device of the receiving user will perform noise reduction processing on the received audio signal. In the existing scheme, the electronic device weights and sums multiple loss functions with different tendencies by using an AI noise reduction model, and trains the AI noise reduction model by using the obtained loss value to process the audio signal. However, in the process of weighting and summing multiple loss functions, due to the difference in the dimensions of multiple loss functions, the AI noise reduction model cannot achieve a relatively ideal balance between noise suppression and voice quality, thereby resulting in poor audio processing effect of the AI noise reduction model.

[0031] The embodiment of the application provides a model training method, and an electronic device can train a first subtask based on obtained initial training information, obtain a first model weight parameter, and train a second subtask according to the first model weight parameter, so as to obtain a target model weight parameter based on a second model weight parameter, so that the electronic device can perform noise reduction processing on an audio signal through the training model. In the scheme, the noise reduction task is divided into several subtasks, each subtask is trained as a stage, the model weight parameter with good training effect in the current stage can be used as the initial weight of the next subtask, and different loss functions are set for the next subtask, so that the model can retain the training effect of the last stage, and finally a better noise reduction effect is obtained.

[0032] The embodiment of the application provides a model training method, Figure 1 A flowchart of a model training method provided by the embodiment of the application is shown. As shown in the figure, Figure 1 The model training method provided by the embodiment of the application can include the following steps 201 to 204.

[0033] Step 201, an electronic device obtains initial training information.

[0034] In the embodiment of the application, the initial training information includes a first subtask, a first loss function and a training model.

[0035] Optionally, in the embodiment of the application, the first loss function is a loss function corresponding to the first subtask.

[0036] It should be noted that the loss function corresponding to a subtask determines the inclination of the subtask, for example, a part of the loss function inclines to the quality of speech, and another part of the loss function inclines to the noise reduction capability, so it can be understood that selecting different loss functions for the subtask can make the task preference of the subtask for noise reduction processing different. For example, if the loss function corresponding to the subtask 1 inclines to the quality of speech, the preference of the subtask 1 for noise reduction processing is the quality of speech, so the noise reduction model obtained after training the subtask 1 can better retain the quality of speech; or, if the loss function corresponding to the subtask 1 inclines to the noise reduction capability, the preference of the subtask 1 for noise reduction processing is the noise reduction capability, so the noise reduction model obtained after training the subtask 1 can better perform noise reduction processing on the audio signal.

[0037] Optionally, in the embodiment of the application, the first loss function is combined with Figure 1 As shown in the figure, Figure 2 The step 201 can be implemented by the following steps 201a and 201b.

[0038] Step 201a, an electronic device obtains a first subtask and a training model.

[0039] Exemplarily, taking the training model as an AI noise reduction model for example, the electronic device can implement call noise reduction on the 16k wideband audio through the AI noise reduction model (for example, an AI neural network noise reduction model). As shown in Table 1, the parameters used when the AI noise reduction model trains the subtasks are shown, including the number of training times (Batch), the duration of each corpus, the frame length, the frame shift, the window function, the Fast Fourier Transform (FFT) length, the initial learning rate, and the model structure.

[0040] Table 1

[0041]

[0042] The AI noise reduction model is deployed in the electronic device, and there are constraints on the size and complexity of the model, so the selected model structure is relatively simple. As shown in Table 1, the model structure of the AI noise reduction model is composed of two GRU (Gated Recurrent Units) layers and one FC (Fully Connected Layers). Figure 3 For the process of training each subtask of the electronic device, the electronic device can input the noisy time domain signal into the AI noise reduction model according to the set model learning rate Lr and the initial weight value of the subtask 1. First, the AI noise reduction model can frame the noisy time domain signal and increase the analysis window, and after the short-time discrete Fourier transform processing, the frequency domain bin point amplitude is calculated through two gated recurrent unit layers and one fully connected layer to obtain the amplitude spectrum mask, so as to combine the bin point original phase, add the synthesis window and frame after the inverse short-time discrete Fourier transform, to calculate the loss value of the loss function corresponding to the subtask.

[0043] Step 201b, in the case that the first subtask is an audio noise reduction task, the electronic device determines the SI-SNR loss function as the first loss function.

[0044] Optionally, in the embodiments of the present application, the first loss function can be other loss function with better noise reduction effect.

[0045] Optionally, in the embodiments of the present application, the electronic device can use formula one of the Scale invariant Signal-to-Noise Ratio (SISNR) loss function to determine the SI-SNR loss function value according to the included angle value between the predicted audio signal of the training model and the label audio signal corresponding to the first subtask.

[0046]

[0047] wherein, L sisnr is the SI-SNR loss function, and θ is the predicted audio signal of the training model and the angle value between the label audio signal s corresponding to the first subtask,

[0048] Optionally, in the embodiments of the present application, the electronic device can use Formula Two to Formula Four to determine the angle value between the predicted audio signal of the training model and the label audio signal corresponding to the first subtask.

[0049]

[0050]

[0051]

[0052] wherein, is the predicted audio signal of the training model, s is the label audio signal corresponding to the first subtask, and s target is the projection of the predicted audio signal on the label audio signal, and e noise is the difference between the predicted audio signal and the projection of the predicted audio signal on the label audio signal, i.e., the noise component contained in the predicted audio signal.

[0053] It should be noted that the electronic device can deduce the bias of the loss function through the expression of the loss function (e.g., the expression of L sisnr ) and the bias is consistent with the actual training result.

[0054] Exemplarily, as shown in Figure 4 , a curve graph of the SI-SNR loss function provided by the embodiments of the present application is shown. From the curve graph of the loss function, it can be obtained that when the angle value between the predicted audio signal and the label audio signal is less than or equal to the first threshold value, i.e., the correlation degree between the two audio signals is larger, the corresponding SI-SNR loss function value is smaller; when the angle value between the predicted audio signal and the label audio signal is greater than or equal to the second threshold value, i.e., the correlation degree between the two audio signals is smaller, the corresponding SI-SNR loss function value is larger, which means that there will be a larger penalty in this case; when the angle value between the predicted audio signal and the label audio signal is greater than the first threshold value and less than the second threshold value, the SI-SNR function image is relatively flat.

[0055] wherein, Figure 4 The first threshold value in Formula Five is about 0.1, and the second threshold value is about 1.5. The specific numerical value is not limited in the embodiments of the present application.

[0056] It can be understood that, combined with the actual training result, it can be obtained that: case 1, the SI-SNR loss function is biased to the noise reduction of the non-speech segment. The predicted audio signal obtained by the AI noise reduction model at the non-speech segment only includes noise, while the label audio signal can include a noise audio signal with a small signal strength (for example, less than or equal to a threshold) or not contain any audio signal, that is, in a mute state, at this time, the correlation degree of the two audio signals is small (for example, less than or equal to a preset degree), and thus the loss value obtained is greater than a threshold. Case 2, for audio signals with low signal-to-noise ratio or few harmonic structures (for example, harmonics only exist below 1k), in these two scenarios, because the proportion of noise audio signals is large, the correlation degree of the original input noise audio and the label audio signal is small, and thus the loss value obtained is large, the AI noise reduction model is prone to misjudgment when predicting, and transition suppression occurs, resulting in damage to the speech.

[0057] In the embodiment of the application, the electronic device obtains the first subtask and the training model, and determines the first loss function based on the noise reduction task, so as to train the training model through the first loss function, thereby enabling the electronic device to better perform noise reduction processing on the noise in the audio signal.

[0058] In step 202, the electronic device performs first task training on the first subtask based on the training model to obtain the first model weight parameter of the training model.

[0059] In the embodiment of the application, the loss function of the first task training is the first loss function.

[0060] Optionally, in the embodiment of the application, the electronic device can train the first subtask according to the first loss function and a preset first learning rate Lr1 of model training = a1 mu, then select a set of model weight values with the best noise reduction effect from the multiple sets of model weight values saved from each round of training, and thereby obtain the first model weight parameter of the training model. Wherein, 0 < mu < 1, a1 = 1.

[0061] Optionally, in the embodiment of the application, the step 202 can be implemented through the following steps 202a and 202b.

[0062] In step 202a, the electronic device iteratively updates the initial weight value of the first subtask according to the first loss function by using a back propagation algorithm until convergence is obtained, to obtain at least one set of first weight values.

[0063] In the embodiment of the application, each set of first weight values in the at least one set of first weight values corresponds to a first loss function value of the first loss function;

[0064] Optionally, in the embodiments of the present application, the electronic device can perform optimization processing on the initial weight value through the gradient based on the preset first learning rate Lr1 (for example, the first learning rate is 10 -3 ), to train the first subtask and update the model weight value of the first subtask. During the training process, the learning rate can be reduced for each round of training, thereby reducing the step size during each weight update, and adjusting the training model.

[0065] It should be noted that the above iterative update until convergence can be understood as that, during the iterative update of the electronic device using the back propagation algorithm, the change of at least one updated weight value is small, that is, the difference between at least one weight value obtained continuously is less than a threshold value, then the iterative update of the initial weight value can be considered as converging.

[0066] Step 202b, the electronic device determines the first target weight value in the at least one group of first weight values as the first model weight parameter.

[0067] In the embodiments of the present application, the above first target weight value is a group of first weight values corresponding to the minimum loss function value in the first loss function value.

[0068] Optionally, in the embodiments of the present application, during the training of the first subtask, the electronic device can select the weight value with the best noise reduction effect from the at least one group of first weight values obtained from at least one round of training as the first target weight value, that is, select a group of first weight values corresponding to a small loss function value during training or a small loss function value on the validation set as the first target weight value, to obtain the model weight corresponding to the first subtask.

[0069] In the embodiments of the present application, the electronic device iteratively updates the initial weight value of the first subtask based on the first loss function to obtain the first model weight parameter, thereby training the training model in the noise reduction direction corresponding to the first subtask, to better reduce the noise in the audio signal.

[0070] Step 203, the electronic device performs second task training on the second subtask based on the training model and the first model weight parameter, to obtain the second model weight parameter of the training model.

[0071] In the embodiments of the present application, the above second subtask is different from the first subtask, and the loss function of the above second task training is a second loss function, which is different from the first loss function.

[0072] Optionally, in the embodiments of the present application, the electronic device can take the first model weight parameter as an initial weight value of the second sub-task, replace the loss function with a second loss function, and attenuate the second learning rate Lr2, so as to perform second task training on the second sub-task, and select a model weight value that meets the requirements of the second sub-task and has the best performance effect from at least one model weight value saved after at least one round of training, as a second target model weight parameter.

[0073] Optionally, in the embodiments of the present application, the step 203 can be implemented by the following steps 203a to 203c.

[0074] Step 203a, in the case where the second sub-task is a residual noise suppression task, the electronic device determines the magnitude spectrum MSE loss function as the second loss function.

[0075] Optionally, in the embodiments of the present application, the electronic device can use formula five of the magnitude spectrum mean square error (MSE) loss function to determine the loss function value corresponding to the second loss function according to the predicted audio signal of the training model and the label audio signal corresponding to the second sub-task.

[0076]

[0077] wherein, L mag_mse is the second loss function, is the magnitude spectrum of the predicted audio signal of the training model at the t th frame and the f th bin point, X t,f is the magnitude spectrum of the label audio signal corresponding to the second sub-task at the t th frame and the f th bin point, T is the total number of frames of the audio signal, and F is the total number of bin points of each frame of the audio signal.

[0078] Step 203b, the electronic device iteratively updates the first model weight parameter until convergence using the back propagation algorithm according to the second loss function, to obtain at least one group of second weight values.

[0079] In the embodiments of the present application, each group of second weight values in the at least one group of second weight values corresponds to a second loss function value of the second loss function.

[0080] Optionally, in the embodiments of the present application, the second learning rate Lr2 can be attenuated based on the first learning rate Lr1, so as to obtain the corresponding second learning rate Lr2=α2·Lr1 (for example, Lr2=5×10 -4 ), wherein 0<α2<1.

[0081] Optionally, in the embodiment of the present application, the electronic device can optimize the first model weight parameter by gradient reverse based on the second loss function value and the preset second learning rate Lr2, to perform second task training on the second subtask, to obtain at least one second weight value, and thus obtain the second model weight parameter.

[0082] In step 203c, the electronic device determines a second target weight value in the at least one set of second weight values as the second model weight parameter.

[0083] In the embodiment of the present application, the second target weight value is a set of second weight values corresponding to the minimum loss function value in the second loss function value.

[0084] Optionally, in the embodiment of the present application, during the training of the second subtask, the electronic device can select the weight value with the best residual noise suppression effect from the at least one set of second weight values obtained after at least one round of training as the second target weight value, and thus obtain the second model weight parameter.

[0085] In the embodiment of the present application, when the second subtask is a residual noise suppression task, the electronic device determines the second loss function, and determines the second model weight parameter by using the obtained at least one second weight value, so as to train the training model in the direction corresponding to the second subtask, to better suppress the residual noise in the audio signal.

[0086] In step 204, the electronic device obtains the target model weight parameter of the training model based on the second model weight parameter.

[0087] Optionally, in the embodiment of the present application, the electronic device can divide the noise reduction task into N subtasks, so that the electronic device can use the model weight parameter corresponding to the i-1th subtask as the initial weight of the ith subtask, replace the loss function with the loss function of the ith subtask, attenuate the learning rate corresponding to the ith subtask, so as to start training the ith subtask, and select one model weight parameter meeting the requirements of the ith subtask and having the best performance effect from the at least one model weight parameter saved after each round of training, as the model weight parameter corresponding to the ith subtask, and determine the model weight parameter of the Nth subtask as the target model weight parameter.

[0088] For example, as shown in FIG. 6, the electronic device can divide the noise reduction task into three subtasks, and perform training on the three subtasks in sequence. Figure 5As shown, when the electronic device divides the noise reduction task into subtask 1, subtask 2, …, and subtask n, the electronic device inputs the initial weight of the initialized AI noise reduction model and the learning rate as the model input parameters of the model weight parameters of subtask 1 into the AI noise reduction model, performs at least one training through the AI noise reduction model and the loss function lossfunction_1 of subtask 1, obtains at least one weight value of subtask 1, and selects a weight value that meets subtask 1 and has the best performance from the at least one weight value as the model weight parameter of subtask 1; the model weight parameters of subtask 1 and the decayed learning rate are input into the AI noise reduction model as the model input parameters of the model weight parameters of subtask 2, at least one training is performed through the AI noise reduction model and the loss function lossfunction_2 of subtask 2, at least one weight value of subtask 2 is obtained, and a weight value that meets subtask 2 and has the best performance is selected from the at least one weight value as the model weight parameter of subtask 2; and the like, until the model weight parameters of subtask n are obtained, and the model weight parameters of subtask n are determined as the target model weight parameters, so that the noise reduction model can process the audio signal based on the target model weight parameters.

[0089] Optionally, in the embodiments of the present application, the step 204 can be implemented through the following steps 204a and 204b.

[0090] In step 204a, the electronic device performs third task training on the third subtask based on the training model and the second model weight parameters, to obtain third model weight parameters of the training model.

[0091] In the embodiments of the present application, the third subtask is different from the first subtask and the second subtask, the loss function of the third task training is a third loss function, and the third loss function is different from the first loss function and the second loss function.

[0092] Optionally, before the step 204a, the model training method provided in the embodiments of the present application further includes steps 301 to 304.

[0093] In step 301, in the case that the third subtask is a speech repair task, the electronic device determines the first audio signal based on the labeled audio signal corresponding to the third subtask.

[0094] In the embodiments of the present application, the signal energy of the first audio signal is less than a preset threshold.

[0095] Optionally, in the embodiment of the present application, the electronic device adopts a voice activity detection (VAD) algorithm of Formula Six to mark the speech frames in the labeled audio signal as 1 and mark the non-speech frames as 0. The average energy E of the pure speech segment is calculated by using Formula Seven mean .

[0096]

[0097]

[0098] Optionally, in the embodiment of the present application, the electronic device determines the speech frames in the labeled audio signal corresponding to the third subtask that satisfy ∑ f |X t,f | 2 ≥E mean as the first audio signal, where ∑ f |X t,f | 2 is the sum of all bin points in the current speech frame, that is, the energy of the current speech frame.

[0099] Step 302, the electronic device determines the second audio signal based on the predicted audio signal of the training model and the labeled audio signal corresponding to the third subtask.

[0100] Optionally, in the embodiment of the present application, the second audio signal described above can be an audio signal with speech quality impairment.

[0101] Optionally, in the embodiment of the present application, the electronic device determines the speech frames in the labeled audio signal corresponding to the third subtask that satisfy as the second audio signal, where β is an arbitrary constant greater than 0 and less than 1, and the specific value of the constant is not limited in the embodiment of the present application.

[0102] Step 303, the electronic device determines the first update weight corresponding to the first audio signal and the second update weight corresponding to the second audio signal.

[0103] Optionally, in the embodiment of the present application, the electronic device determines the first update weight corresponding to the first audio signal by using Formula Eight, and determines the second update weight corresponding to the second audio signal by using Formula Nine.

[0104]

[0105]

[0106] where p is the first weight parameter and h is the second weight parameter, and p and h are both weight values greater than 1 and less than a preset threshold, where the preset threshold can be set to 10, for example, p = h = 5.

[0107] Step 304, the electronic device obtains a third loss function based on the second loss function, the first updated weight and the second updated weight.

[0108] Optionally, in the embodiments of the present application, the electronic device obtains the third loss function, i.e., the improved magnitude spectrum MSE loss function L based on the second loss function, the first updated weight and the second updated weight by using Formula Ten. mag_mse_modify .

[0109] L mag_mse_modify = L mag_mse + P t,vad * L mag_mse + H t,vad * L mag_mse Formula Ten

[0110] In the case where the third subtask is a speech repair task, the electronic device can determine the first audio signal and the second audio signal based on the label audio signal and the predicted audio signal corresponding to the third subtask, and assign a weight value to the first audio signal and the second audio signal to obtain the third loss function, so that when the third subtask is trained, the electronic device can enhance the attention to the first audio signal and the second audio signal, so that the electronic device can repair the speech frames corresponding to the audio signal with a signal intensity less than or equal to a preset threshold and the audio signal with speech quality damage, so as to improve the quality of the audio signal after the audio signal is processed by the trained model.

[0111] Step 204b, the electronic device obtains the target model weight parameter of the trained model based on the third model weight parameter.

[0112] In the embodiments of the present application, the electronic device can perform third task training on the third subtask based on the trained model and the second model weight parameter, obtain the third model weight parameter, and determine the target model parameter of the trained model, so that the electronic device can process the audio signal through the trained model to improve the audio processing effect of the trained model.

[0113] The embodiment of the present application provides a model training method, and the electronic device can train a first subtask based on the obtained initial training information, obtain a first model weight parameter, and train a second subtask according to the first model weight parameter, so as to obtain a target model weight parameter based on the obtained second model weight parameter, so that the electronic device can perform noise reduction processing on the audio signal through the training model. In the scheme, the noise reduction task is divided into several subtasks, each subtask is trained as a stage, the model weight parameter with good training effect in the current stage can be used as the initial weight of the next subtask, and the learning rate of the next subtask is decayed, so that the model can retain the training effect of the last stage, and different loss functions are set, and finally a better noise reduction effect is obtained.

[0114] Optionally, in the embodiment of the present application, in combination with Figure 1 As shown in the above step 204, the model training method provided by the embodiment of the present application further includes step 205. Figure 6

[0115] Step 205, the electronic device performs noise reduction processing on the audio signal to be processed through the training model based on the target model weight parameter of the training model, and obtains a target audio signal.

[0116] In the embodiment of the present application, after the audio signal to be processed is input in the electronic device, the electronic device can frame the audio signal to be processed, and sample and process each frame of the audio signal to be processed based on the target model weight parameter of the training model, so as to obtain the audio signal after noise reduction.

[0117] Example 1: as shown in the above step 204, the model training method provided by the embodiment of the present application further includes step 205. Figure 7 As shown in the above step 204, the model training method provided by the embodiment of the present application further includes step 205. Figure 7 In the 1st position in the above step 204, the voice audio segment corresponding to the 1st position can be compared, and it can be seen that the noise suppression effect of the scheme of the present application on the voice is the best, and the residual noise is the least, while the residual noise of the existing loss function weighting scheme is relatively more. In the 2nd position in the above step 204, the stationary noise audio segment corresponding to the 2nd position can be compared, and it can be seen that the scheme of the present application can strongly suppress the noise, so that the audio segment has no residual noise, while the audio segment corresponding to the existing loss function weighting scheme has residual bottom noise. Figure 7

[0118] Example 2: as shown in the above step 204, the model training method provided by the embodiment of the present application further includes step 205. Figure 8 ​​The diagram illustrates the noise reduction effect of noisy frequencies in a public scene. The first row represents the processing result of the model trained using the solution provided in this application; the second row represents the processing result of the model trained using an existing loss function weighting scheme; and the third row represents the original noisy frequencies. (Comparison) Figure 8 The stable noise audio segment corresponding to position 1 in the image shows that the solution provided in this application can strongly suppress noise, leaving no noise residue in the audio segment, while the audio segment corresponding to the existing loss function weighting scheme retains some background noise. (Comparison) Figure 8 The audio segment corresponding to position 2 in the diagram shows that the solution provided in this application has the best noise suppression effect in speech and the least residual noise, while the existing loss function weighting scheme has more residual noise.

[0119] Example 3: such as Figure 9 The diagram illustrates the noise reduction effect of noisy frequencies in an automotive scenario. The first row represents the processing result of the model trained using the solution provided in this application; the second row represents the processing result of the model trained using an existing loss function weighting scheme; and the third row represents the original noisy frequencies. (Comparison) Figure 7 Position 1 shows that when the audio segment transitions from silence to noise, the solution provided in this application can suppress noise most quickly, with a short convergence time or even no convergence time required, while existing loss function weighting schemes require a longer convergence time. (Comparison) Figure 9 Position 2 shows that the scheme provided in this application has a better effect on suppressing noise between harmonics in speech than the existing loss function weighting scheme.

[0120] Example 4: Figure 10 The diagram illustrates the noise reduction effect on noisy frequencies in a train scene. The first row represents the processing result of the model trained using the scheme provided in this application; the second row represents the processing result of the model trained using an existing loss function weighting scheme; and the third row represents the original noisy frequencies. (Comparison) Figure 10 Position 1 shows that when there are special noises in the scene, such as high-frequency noise from the friction between the wheels and rails of a train, the solution provided in this application has the best suppression effect.

[0121] Example 5: such as Figure 11 The diagram illustrates the noise reduction effect on noisy frequencies in a coffee shop setting. The first row represents the processing result of the model trained using the solution provided in this application; the second row represents the processing result of the model trained using an existing loss function weighting scheme; and the third row represents the original noisy frequencies. (Comparison) Figure 11The main noise audio corresponding to the first, second and third positions in the table can be the non-stationary and impact noise audio generated when cleaning tableware, and it is found that the scheme provided in the application has the best suppression effect.

[0122] In the embodiment of the application, the electronic device performs noise reduction processing on the audio signal to be processed by the training model based on the target model weight parameter of the training model, to obtain the audio signal after noise reduction. The training model finally obtained has a significant improvement in noise reduction capability, the convergence time required in the noise suppression process is shortened, and the quality of the processed speech obtained does not decrease, achieving a relatively ideal balance in noise suppression and speech quality.

[0123] The model training method provided in the embodiment of the application can be executed by a model training device. In the embodiment of the application, the model training method executed by the model training device is taken as an example to illustrate the model training device provided in the embodiment of the application.

[0124] Figure 12 A possible structural schematic diagram of the model training device involved in the embodiment of the application is shown. As shown in the figure, Figure 12 The model training device 70 can include an acquisition module 71 and a processing module 72.

[0125] The acquisition module 71 is configured to acquire initial training information, wherein the initial training information includes a first subtask, a first loss function and a training model. The processing module 72 is configured to perform first task training on the first subtask based on the training model acquired by the acquisition module 71, to obtain a first model weight parameter of the training model, wherein the loss function of the first task training is the first loss function; perform second task training on a second subtask based on the training model and the first model weight parameter, to obtain a second model weight parameter of the training model, wherein the second subtask is different from the first subtask, the loss function of the second task training is a second loss function, and the second loss function is different from the first loss function; and obtain a target model weight parameter of the training model based on the second model weight parameter obtained by the training module.

[0126] The model training device provided in the embodiment of the application divides the noise reduction task into several subtasks, each subtask is trained as a stage, the model weight parameter with good training effect in the current stage can be used as the initial weight of the next subtask, and the learning rate of the next subtask is decayed, so that the model can retain the training effect of the previous stage, and different loss functions are set, so that a better noise reduction effect is finally obtained.

[0127] In a possible implementation, the processing module 72 is specifically configured to perform third task training on the third subtask based on the training model and the second model weight parameter, to obtain a third model weight parameter of the training model, where the third subtask is different from the first subtask and the second subtask, a loss function of the third task training is a third loss function, and the third loss function is different from the first loss function and the second loss function; and based on the third model weight parameter, the target model weight parameter of the training model is obtained.

[0128] In a possible implementation, the processing module 72 is further configured to, before the training module performs the third task training on the third subtask based on the training model and the second model weight parameter, to obtain the third model weight parameter of the training model, in a case where the third subtask is a speech repair task, determine a first audio signal based on a label audio signal corresponding to the third subtask, where a signal energy of the first audio signal is less than a preset threshold; and determine a second audio signal based on a predicted audio signal of the training model and the label audio signal corresponding to the third subtask; determine a first update weight corresponding to the first audio signal and a second update weight corresponding to the second audio signal; and obtain the third loss function based on the second loss function, the first update weight, and the second update weight.

[0129] In a possible implementation, the obtaining module 71 is specifically configured to obtain the first subtask and the training model; and the processing module 72 is specifically configured to, in a case where the first subtask is an audio noise reduction task, determine a SI-SNR loss function as the first loss function.

[0130] In a possible implementation, the processing module 72 is specifically configured to, according to the first loss function, perform iterative updating on an initial weight value of the first subtask by using a back propagation algorithm until convergence is reached, to obtain at least one group of first weight values, each group of first weight values corresponding to a first loss function value of the first loss function; and determine a first target weight value in the at least one group of first weight values as the first model weight parameter, the first target weight value being a group of first weight values corresponding to a minimum loss function value in the first loss function values.

[0131] In a possible implementation, the processing module 72 is specifically configured to, in a case where the second subtask is a residual noise suppression task, determine an amplitude spectrum MSE loss function as the second loss function; and according to the second loss function, perform iterative updating on the first model weight parameter by using the back propagation algorithm until convergence is reached, to obtain at least one group of second weight values, each group of second weight values corresponding to a second loss function value of the second loss function; and determine a second target weight value in the at least one group of second weight values as the second model weight parameter, the second target weight value being a group of second weight values corresponding to a minimum loss function value in the second loss function values.

[0132] In a possible implementation, the processing module 72 is further configured to, after obtaining the target model weight parameter of the training model based on the second model weight parameter, perform noise reduction processing on the audio signal to be processed based on the target model weight parameter of the training model to obtain a target audio signal.

[0133] The model training apparatus in the embodiments of the present application can be an apparatus, or a component, an integrated circuit, or a chip in an electronic device. The apparatus can be a mobile electronic device or a non-mobile electronic device. Illustratively, the mobile electronic device can be a mobile phone, a tablet computer, a notebook computer, a palm computer, a vehicle-mounted electronic device, a Mobile Internet Device (MID), an augmented reality (AR) / virtual reality (VR) device, a robot, a wearable device, an ultra-mobile personal computer (UMPC), a netbook, or a personal digital assistant (PDA), etc. The apparatus can also be a server, a Network Attached Storage (NAS), a personal computer (PC), a television (TV), a teller machine, or a self-service machine, etc. The embodiments of the present application are not limited in this regard.

[0134] The model training apparatus in the embodiments of the present application can be an apparatus with an operating system. The operating system can be an Android operating system, an ios operating system, or other possible operating systems. The embodiments of the present application are not limited in this regard.

[0135] The model training apparatus provided in the embodiments of the present application can implement each process achieved by the method embodiments, and achieve the same technical effects. To avoid repetition, details are not described herein.

[0136] Optionally, as shown in Figure 13 The embodiments of the present application also provide an electronic device 90, which includes a processor 91 and a memory 92. The memory 92 has a program or instructions stored thereon, which can be run on the processor 91. The program or instructions are executed by the processor 91 to implement each step of the above model training method embodiments and achieve the same technical effects. To avoid repetition, details are not described herein.

[0137] It should be noted that the electronic device in the embodiments of the present application includes the above-mentioned mobile electronic device and non-mobile electronic device.

[0138] Figure 14 A hardware structure schematic diagram of an electronic device is provided to implement an embodiment of the present application.

[0139] The electronic device 100 includes, but is not limited to, a radio frequency unit 101, a network module 102, an audio output unit 103, an input unit 104, a sensor 105, a display unit 106, a user input unit 107, an interface unit 108, a memory 109, and a processor 110, and the like.

[0140] Those skilled in the art can understand that the electronic device 100 can also include a power supply (such as a battery) for powering various components, and the power supply can be logically connected to the processor 110 through a power management system, so as to realize functions such as management of charging, discharging, and power consumption management through the power management system. Figure 14 The electronic device structure shown in the figure does not constitute a limitation on the electronic device, and the electronic device can include more or fewer components than the figure, or combine certain components, or different component arrangements, which are not described here.

[0141] The processor 110 is configured to obtain initial training information, wherein the initial training information includes a first subtask, a first loss function, and a training model; perform first task training on the first subtask based on the training model to obtain first model weight parameters of the training model, wherein the loss function of the first task training is the first loss function; perform second task training on a second subtask based on the training model and the first model weight parameters to obtain second model weight parameters of the training model, wherein the second subtask is different from the first subtask, the loss function of the second task training is a second loss function, and the second loss function is different from the first loss function; and obtain target model weight parameters of the training model based on the second model weight parameters.

[0142] The embodiments of the present application provide an electronic device, which divides a noise reduction task into several subtasks, trains each subtask as a stage, can take the model weight parameters with good training effect in the current stage as the initial weight of the next subtask, and attenuates the learning rate of the next subtask, so that the model can retain the training effect of the last stage, and different loss functions are set to finally obtain a better noise reduction effect.

[0143] Optionally, the processor 110 is specifically configured to perform third task training on a third subtask based on the training model and the second model weight parameters to obtain third model weight parameters of the training model, wherein the third subtask is different from the first subtask and the second subtask, the loss function of the third task training is a third loss function, and the third loss function is different from the first loss function and the second loss function; and obtain target model weight parameters of the training model based on the third model weight parameters.

[0144] Optionally, the processor 110 is further configured to, before obtaining the third model weight parameter of the training model based on the second model weight parameter, in a case where the third subtask is a speech repair task, determine a first audio signal based on a label audio signal corresponding to the third subtask, where a signal energy of the first audio signal is less than a preset threshold; determine a second audio signal based on a predicted audio signal of the training model and the label audio signal corresponding to the third subtask; determine a first update weight corresponding to the first audio signal and a second update weight corresponding to the second audio signal; and obtain a third loss function based on the second loss function, the first update weight, and the second update weight.

[0145] Optionally, the processor 110 is specifically configured to obtain the first subtask and the training model; and in a case where the first subtask is an audio noise reduction task, determine the SI-SNR loss function as the first loss function.

[0146] Optionally, the processor 110 is specifically configured to, according to the first loss function, perform iterative updating on an initial weight value of the first subtask by using a back propagation algorithm until convergence is reached, to obtain at least one group of first weight values, each group of first weight values corresponding to a first loss function value of the first loss function; and determine a first target weight value in the at least one group of first weight values as the first model weight parameter, the first target weight value being a group of first weight values corresponding to a minimum loss function value in the first loss function values.

[0147] Optionally, the processor 110 is specifically configured to, in a case where the second subtask is a residual noise suppression task, determine the amplitude spectrum MSE loss function as the second loss function; and according to the second loss function, perform iterative updating on the first model weight parameter by using the back propagation algorithm until convergence is reached, to obtain at least one group of second weight values, each group of second weight values corresponding to a second loss function value of the second loss function; and determine a second target weight value in the at least one group of second weight values as the second model weight parameter, the second target weight value being a group of second weight values corresponding to a minimum loss function value in the second loss function values.

[0148] Optionally, the processor 110 is further configured to, after obtaining the target model weight parameter of the training model based on the second model weight parameter, perform noise reduction processing on a to-be-processed audio signal by using the training model based on the target model weight parameter of the training model, to obtain a target audio signal.

[0149] The electronic device provided in the embodiments of the present application can implement each process implemented by the method embodiments described above, and achieve the same technical effects. To avoid repetition, details are not described herein.

[0150] The beneficial effects of the various implementations in this embodiment can refer to the beneficial effects of the corresponding implementations in the method embodiments described above. To avoid repetition, the details are not described here.

[0151] It should be understood that in the embodiments of the present application, the input unit 104 can include a graphics processor (GPU) 1041 and a microphone 1042. The graphics processor 1041 processes image data of a still picture or a video obtained by an image capture device (such as a camera) in a video capture mode or an image capture mode. The display unit 106 can include a display panel 1061, which can be configured in the form of a liquid crystal display, an organic light-emitting diode, etc. The user input unit 107 includes at least one of a touch panel 1071 and other input devices 1072. The touch panel 1071 is also called a touch screen. The touch panel 1071 can include two parts of a touch detection device and a touch controller. The other input devices 1072 can include, but are not limited to, a physical keyboard, function keys (such as volume control keys, on-off keys, etc.), trackballs, mice, joysticks, etc., which will not be described here.

[0152] The memory 109 can be used to store software programs and various data. The memory 109 can mainly include a first storage area storing programs or instructions and a second storage area storing data, wherein the first storage area can store an operating system, application programs or instructions required by at least one function (such as a sound playing function, an image playing function, etc.), and the like. In addition, the memory 109 can include a volatile memory or a non-volatile memory, or the memory 109 can include both a volatile memory and a non-volatile memory. The non-volatile memory can be a Read-Only Memory (ROM), a Programmable ROM (PROM), an Erasable PROM (EPROM), an Electrically EPROM (EEPROM), or a flash memory. The volatile memory can be a Random Access Memory (RAM), a Static RAM (SRAM), a Dynamic RAM (DRAM), a Synchronous DRAM (SDRAM), a Double Data Rate SDRAM (DDR SDRAM), an Enhanced SDRAM (ESDRAM), a Synch link DRAM (SLDRAM), and a Direct Rambus RAM (DRRAM). The memory 109 in the embodiments of the present application includes but is not limited to these and any other suitable types of memory.

[0153] The processor 110 can include one or more processing units; optionally, the processor 110 integrates an application processor and a modem processor, wherein the application processor mainly processes operations related to an operating system, a user interface, and an application program, and the modem processor mainly processes wireless communication signals, such as a baseband processor. It can be understood that the above-mentioned modem processor can also not be integrated into the processor 110.

[0154] The embodiments of the present application also provide a readable storage medium, the readable storage medium stores programs or instructions, the programs or instructions are executed by a processor to realize various processes of the above-mentioned method embodiments and achieve the same technical effects. To avoid repetition, details are not described here.

[0155] The processor is the processor in the electronic device described in the above embodiments. The readable storage medium includes a computer readable storage medium, such as a computer readable only memory (ROM), a random access memory (RAM), a magnetic disk or an optical disk, etc.

[0156] The embodiment of the present application further provides a chip, which comprises a processor and a communication interface, the communication interface is coupled with the processor, the processor is used for running programs or instructions to realize various processes of the above method embodiments and achieve the same technical effects. To avoid repetition, details are not described here.

[0157] It should be understood that the chip mentioned in the embodiment of the present application can also be referred to as a system chip, a system chip, a chip system or a system on chip, etc.

[0158] The embodiment of the present application provides a computer program product, which is stored in a storage medium, and the program product is executed by at least one processor to realize various processes of the above model training method embodiments and achieve the same technical effects. To avoid repetition, details are not described here.

[0159] It should be noted that in this paper, the term "includes", "contains" or any other variant thereof is intended to cover non-exclusive inclusion, so that the process, method, article or device including a series of elements not only includes those elements, but also includes other elements not explicitly listed or inherent to such process, method, article or device. Without more limitations, the element defined by the statement "includes a" does not exclude the presence of other identical elements in the process, method, article or device including the element. In addition, it should be pointed out that the scope of the method and device in the embodiment of the present application is not limited to the order of the functions shown or discussed, but can also include the functions performed in a substantially simultaneous manner or in the opposite order according to the functions involved, for example, the described method can be performed in an order different from the described order, and various steps can also be added, omitted or combined. In addition, the features described with reference to some examples can be combined in other examples.

[0160] Through the above description of the embodiments, those skilled in the art can clearly understand that the above-mentioned example methods can be realized by means of software and a necessary general hardware platform, and of course, can also be realized by hardware, but in many cases, the former is a better embodiment. Based on such understanding, the technical solutions of the present application can be embodied in the form of a computer software product in essence or in the form of a part that contributes to the prior art, which is stored in a storage medium (such as a ROM / RAM, a magnetic disc, an optical disc), and includes a plurality of instructions for causing a terminal (which can be a mobile phone, a computer, a server, or a network device, etc.) to execute the methods described in the various embodiments of the present application.

[0161] The embodiments of the present application are described above in combination with the drawings, but the present application is not limited to the above-mentioned specific embodiments, and the above-mentioned specific embodiments are only illustrative and not restrictive. Those skilled in the art can make many forms under the inspiration of the present application without departing from the scope of the present application and the scope protected by the claims.

Claims

1. A model training method, characterized in that, The method comprises: obtaining initial training information, wherein the initial training information comprises a first subtask, a first loss function and a training model; based on the training model, using the first loss function corresponding to the first subtask to perform first task training on the first subtask to obtain first model weight parameters of the training model, wherein the first subtask is an audio noise reduction task; based on the training model, using the second loss function corresponding to the second subtask to perform second task training on the second subtask, and obtaining second model weight parameters of the training model, wherein the second subtask is a residual noise suppression task, and the second loss function is different from the first loss function; in the case that the third subtask is a speech repair task, determining a first audio signal based on a labeled audio signal corresponding to the third subtask, wherein the signal energy of the first audio signal is less than a preset threshold; determining a second audio signal based on a predicted audio signal of the training model and the labeled audio signal corresponding to the third subtask; determining a first update weight corresponding to the first audio signal and a second update weight corresponding to the second audio signal; obtaining a third loss function based on the second loss function, the first update weight and the second update weight; based on the training model, using the third loss function corresponding to the third subtask to perform third task training on the third subtask, and obtaining third model weight parameters of the training model, wherein the third subtask is different from the first subtask and the second subtask, and the third loss function is different from the first loss function and the second loss function; based on the third model weight parameters, obtaining target model weight parameters of the training model, wherein the training model is used for noise reduction processing on a to-be-processed audio signal to obtain a target audio signal.

2. The method of claim 1, wherein, The method comprises: obtaining the first subtask and the training model; determining the first loss function as a scale-invariant signal-to-noise ratio (SI-SNR) loss function.

3. The method according to claim 1 or 2, characterized in that, The method comprises: based on the training model, using the first loss function corresponding to the first subtask to perform first task training on the first subtask to obtain first model weight parameters of the training model, wherein the first subtask is an audio noise reduction task; based on the training model, using the second loss function corresponding to the second subtask to perform second task training on the second subtask, and obtaining second model weight parameters of the training model, wherein the second subtask is a residual noise suppression task, and the second loss function is different from the first loss function; in the case that the third subtask is a speech repair task, determining a first audio signal based on a labeled audio signal corresponding to the third subtask, wherein the signal energy of the first audio signal is less than a preset threshold; determining a second audio signal based on a predicted audio signal of the training model and the labeled audio signal corresponding to the third subtask; determining a first update weight corresponding to the first audio signal and a second update weight corresponding to the second audio signal; obtaining a third loss function based on the second loss function, the first update weight and the second update weight; based on the training model, using the third loss function corresponding to the third subtask to perform third task training on the third subtask, and obtaining third model weight parameters of the training model, wherein the third subtask is different from the first subtask and the second subtask, and the third loss function is different from the first loss function and the second loss function; based on the third model weight parameters, obtaining target model weight parameters of the training model, wherein the training model is used for noise reduction processing on a to-be-processed audio signal to obtain a target audio signal. The method comprises: obtaining the first subtask and the training model; determining the first loss function as a scale-invariant signal-to-noise ratio (SI-SNR) loss function. The method comprises: based on the training model, using the first loss function corresponding to the first subtask to perform first task training on the first subtask to obtain first model weight parameters of the training model, wherein the first subtask is an audio noise reduction task; based on the training model, using the second loss function corresponding to the second subtask to perform second task training on the second subtask, and obtaining second model weight parameters of the training model, wherein the second subtask is a residual noise suppression task, and the second loss function is different from the first loss function; in the case that the third subtask is a speech repair task, determining a first audio signal based on a labeled audio signal corresponding to the third subtask, wherein the signal energy of the first audio signal is less than a preset threshold; determining a second audio signal based on a predicted audio signal of the training model and the labeled audio signal corresponding to the third subtask; determining a first update weight corresponding to the first audio signal and a second update weight corresponding to the second audio signal; obtaining a third loss function based on the second loss function, the first update weight and the second update weight; based on the training model, using the third loss function corresponding to the third subtask to perform third task training on the third subtask, and obtaining third model weight parameters of the training model, wherein the third subtask is different from the first subtask and the second subtask, and the third loss function is different from the first loss function and the second loss function; based on the third model weight parameters, obtaining target model weight parameters of the training model, wherein the training model is used for noise reduction processing on a to-be-processed audio signal to obtain a target audio signal.

4. The method of claim 1, wherein, The second model weight parameter of the training model is obtained by using the first model weight parameter as an initial weight of a second subtask, using a second loss function corresponding to the second subtask to perform second task training on the second subtask, and including: The second loss function is determined by a magnitude spectrum mean square error (MSE) loss function; According to the second loss function, the first model weight parameter is iteratively updated until convergence by using a back propagation algorithm, and at least one set of second weight values is obtained, each set of second weight values corresponding to a second loss function value of the second loss function; The second target weight value in the at least one set of second weight values is determined as the second model weight parameter, and the second target weight value is a set of second weight values corresponding to the minimum loss function value in the second loss function value.

5. A model training apparatus characterized by comprising: The model training device includes an acquisition module and a processing module. The acquisition module is configured to acquire initial training information, wherein the initial training information includes a first subtask, a first loss function, and a training model. The processing module is configured to use the first loss function corresponding to the first subtask to perform first task training on the first subtask based on the training model acquired by the acquisition module, obtain a first model weight parameter of the training model, wherein the first subtask is an audio noise reduction task; use the first model weight parameter as an initial weight of a second subtask, use a second loss function corresponding to the second subtask to perform second task training on the second subtask, and obtain a second model weight parameter of the training model, wherein the second subtask is a residual noise suppression task, the second loss function is different from the first loss function; in the case that a third subtask is a speech repair task, determine a first audio signal based on a label audio signal corresponding to the third subtask, wherein the signal energy of the first audio signal is less than a preset threshold; determine a second audio signal based on a predicted audio signal of the training model and the label audio signal corresponding to the third subtask; determine a first update weight corresponding to the first audio signal and a second update weight corresponding to the second audio signal; obtain a third loss function based on the second loss function, the first update weight, and the second update weight; use the second model weight parameter as an initial weight of the third subtask based on the training model, use a third loss function corresponding to the third subtask to perform third task training on the third subtask, and obtain a third model weight parameter of the training model, wherein the third subtask is different from the first subtask and the second subtask, and the third loss function is different from the first loss function and the second loss function; and obtain a target model weight parameter of the training model based on the third model weight parameter obtained by the training model, wherein the training model is used to perform noise reduction processing on a to-be-processed audio signal to obtain a target audio signal.

6. An electronic device, comprising: The computer device comprises a processor, a memory, and a program or instructions stored on the memory and executable on the processor, and the program or instructions are executed by the processor to implement the steps of the model training method according to any one of claims 1 to 4.

Citation Information

Patent Citations

  • Model training method and device, image feature extraction method and device and electronic equipment

    CN111274422A

  • Voice processing method and device, electronic equipment and storage medium

    CN114155852A