Audio multi-scene noise adding processing method, device, equipment and medium

Through the audio multi-scenario noise processing method, the latent diffusion model is used to generate a variety of noise audio samples, which solves the problems of time-consuming and labor-intensive scenario-based noise processing and application scenario limitations in the existing technology, and improves the model's performance in various acoustics. Training accuracy and robustness under scenarios.

CN118737119AActive Publication Date: 2024-10-01GUANGDONG UNIV OF TECH

Patent Information

Application Number
CN202410931675.1
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2024-07-12
Publication Date
2024-10-01
Estimated Expiration
2044-07-12

AI Technical Summary

Technical Problem

In the existing technology, actually building audio scene-based noise processing requires a lot of human resources and time, and the application scenarios are limited to known or foreseeable scenarios, making it difficult to effectively train the model in a variety of acoustic scenarios.

Method used

Using the audio multi-scene noise processing method, noise audio samples are generated through the latent diffusion model, combined with Gaussian noise distribution and text embedding, to gradually generate a variety of noise audio samples, and copy and synthesize them according to the preset volume multiple threshold, adapting to a variety of Acoustic scene.

Benefits of technology

It significantly improves the training accuracy and robustness of the model in a variety of acoustic scenarios, simplifies the processing process of adding noise to audio, and improves processing efficiency.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN118737119A_ABST
    Figure CN118737119A_ABST
Patent Text Reader

Abstract

The invention relates to an audio multi-scenario noise adding processing method, device and equipment and a medium. The method comprises the steps that an audio service system obtains a noise type in a target acoustic scene and an original audio needing to be subjected to audio multi-scenario noise adding processing; the audio service system uses each noise type as a text to be embedded and transmitted to a potential diffusion model in the noise generation system, Gaussian noise distribution and text embedding are used as starting points in the potential diffusion model, and noise audio samples are generated step by step; copying each noise audio sample according to a plurality of preset volume multiple threshold values to determine noise audio samples corresponding to the plurality of preset volume multiple threshold values; and randomly selecting one or more noise audio samples corresponding to a preset volume multiple threshold value from each noise type, and synthesizing the noise audio samples with the original audio needing to be subjected to audio multi-scene noise addition processing to obtain noise addition audio. According to the method, the model can better adapt to the actual environment, and the robustness is improved.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present application relates to the field of audio processing, and in particular to an audio multi-scenario noise processing method, a corresponding device, an electronic device and a computer-readable storage medium. Background Art

[0002] With the continuous development of the market, various audio task models have emerged one after another, providing services such as voice wake-up and speech recognition. However, most training data sets directly process audio signals, which can only play a role in data enhancement and cannot ensure the effect in specific application scenarios. Therefore, there is an urgent need for an audio scenario method that can target specific application scenarios. Audio scenario needs to add scene noise to the audio signal to simulate the real acoustic environment. This is the audio noise addition method in audio signal processing.

[0003] After production and market entry, most audio task models are affected by scenario factors in actual applications and gradually tend to meet the needs of different noise environments. While the content remains unchanged, the acoustic scenario has evolved, resulting in a deviation between the actual execution effect of the model and the expected effect, and the user experience cannot be guaranteed.

[0004] With the rapid development of hardware computing power, scenario-based noise addition technology has also made great progress. Scenario-based noise addition methods are mainly divided into two categories: one is to record sound by actually building a scene, and the other is to simulate the acoustic scene through software simulation. Since the actual construction requires a lot of human resources and time, more and more researchers tend to further explore software simulation. Since the scenario-based noise addition method is based on the actual noise recorded and is constructed or simulated according to the existing scene information, it is also called a non-generative scenario-based noise addition method. Although the non-generative method can specifically improve the effect of the model in the target acoustic scene, its application scenarios are limited to known or foreseeable scenarios. In practical applications, replicating acoustic scenes is time-consuming and labor-intensive, and it is difficult for researchers to collect enough scenario-based audio to train the model.

[0005] To sum up, the actual construction of existing technologies requires a lot of human resources and time, and the application scenarios are limited to known or foreseeable scenarios. In actual applications, replicating acoustic scenes is time-consuming and labor-intensive, and it is difficult for researchers to collect enough scenario-based audio to train models. The applicant has made corresponding explorations to solve this problem. Summary of the invention

[0006] The purpose of the present application is to solve the above-mentioned problems and to provide an audio multi-scenario noise processing method, a corresponding device, an electronic device and a computer-readable storage medium.

[0007] In order to meet the various objectives of this application, this application adopts the following technical solutions:

[0008] An audio multi-scenario noise processing method proposed to meet one of the purposes of this application includes:

[0009] In response to the audio multi-scenario noise processing instruction, the audio service system obtains the noise type in the target acoustic scene and the original audio that needs to be processed with the audio multi-scenario noise.

[0010] The audio service system transmits each noise type as a text embedding to a latent diffusion model in the noise generation system, wherein the latent diffusion model uses Gaussian noise distribution and the text embedding as a starting point to gradually generate noise audio samples;

[0011] The audio service system copies each noise audio sample according to a plurality of preset volume multiple thresholds to determine the noise audio samples corresponding to the plurality of preset volume multiple thresholds;

[0012] The audio service system randomly selects one or more noise audio samples corresponding to a preset volume multiple threshold in each noise type, and synthesizes them with the original audio that needs to be subjected to audio multi-scenario noise addition processing to obtain the noisy audio.

[0013] Optionally, the audio service system transmits each noise type as a text embedding to a potential diffusion model in a noise generation system, and uses Gaussian noise distribution and the text embedding as a starting point in the potential diffusion model to gradually generate noise audio samples, including:

[0014] generating an audio prior based on contrastive text audio pre-training in the latent diffusion model;

[0015] A variational autoencoder is used as a decoder, and a Mel-spectrogram is reconstructed according to the audio prior;

[0016] A preset adversarial generative network is used as a vocoder to generate high-quality noise audio samples according to the Mel-spectrogram.

[0017] Optionally, the audio service system transmits each noise type as a text embedding to a potential diffusion model in a noise generation system, and uses Gaussian noise distribution and the text embedding as a starting point in the potential diffusion model to gradually generate noise audio samples, including:

[0018] The potential diffusion model includes a diffusion process and a reverse diffusion process;

[0019] In the diffusion process, the text is embedded in each time step n∈[1,...,N], and the transition probability is given by the following formula:

[0020]

[0021] Among them, β n is a predefined noise scale and satisfies 0<β 1 <···<β n <...<β N <1,α n is 1-β n The reparameterization of represents the noise level at each step, represents the injected standard Gaussian distribution noise, at the last time step N, Has a standard isotropic Gaussian distribution;

[0022] For model optimization, a reweighted noise estimation training objective is used:

[0023]

[0024] Among them, θ is the current parameter situation, Represents the calculation of ∈ and ∈ θ (z n ,n,E y ), ∈ is the injected noise, ∈ θ (z n ,n,E y ) is the prediction noise, z n is the Gaussian distribution of the prediction noise, n is the time step, E x It is compared with the pre-trained audio encoder f in text audio pre-training audio (·) Embedding of the generated audio waveform x;

[0025] In the reverse diffusion process, from the Gaussian noise distribution and text embedding E y Start by embedding E with the text y The denoising process is conditioned on the condition that the audio prior z is gradually generated through the following process 0 ,include:

[0026]

[0027] The mean and variance are parameterized as:

[0028]

[0029] Among them, ∈ θ (z n ,n,E y ) is the prediction noise, In the training phase, the audio embedding E of the audio sample x is x Learning to generate audio prior z 0, in the prediction phase, providing text embedding E y To predict the noise ∈ θ (z n ,n,E y ).

[0030] Optionally, the audio service system transmits each noise type as a text embedding to a potential diffusion model in a noise generation system, and uses Gaussian noise distribution and the text embedding as a starting point in the potential diffusion model to gradually generate noise audio samples, including:

[0031] In contrastive text-audio pre-training, the noisy audio sample is represented as x and the text description is represented as y, which uses the text encoder f text (·) and the audio encoder f audio (·) Extract text embedding E respectively y and audio embed x .

[0032] Optionally, the audio service system transmits each noise type as a text embedding to a potential diffusion model in a noise generation system, and uses Gaussian noise distribution and the text embedding as a starting point in the potential diffusion model to gradually generate noise audio samples, including:

[0033] In a variational autoencoder, the variational autoencoder consists of an encoder and a decoder with stacked convolutional modules;

[0034] The encoder compresses the mel-spectrogram X into a latent space Where r represents the compression ratio;

[0035] The decoder generates an audio prior representation from the latent diffusion model Constructing Mel-spectrogram The preset adversarial generation network is used as the vocoder to obtain the mel spectrum map Noise audio samples

[0036] Optionally, the step of the audio service system randomly selecting one or more noise audio samples corresponding to a preset volume multiple threshold in each noise type, and synthesizing them with the original audio that needs to be subjected to audio multi-scenario noise processing includes:

[0037] The audio service system opens and reads each audio file and converts it into a NumPy array;

[0038] Determine the maximum length of all audio data and fill the insufficient length data with zeros;

[0039] Stack all audio data into a two-dimensional array by column, and then flatten it into a one-dimensional array;

[0040] Create a new WAV audio file and write the flattened audio data to it.

[0041] Optionally, the basic network architecture of the generative adversarial network is a HiFi-GAN generative adversarial network.

[0042] An audio multi-scenario noise processing device provided to meet another purpose of the present application includes:

[0043] An audio acquisition module, configured to respond to an audio multi-scenario noise processing instruction, wherein the audio service system acquires the noise type in the target acoustic scene and the original audio that needs to be processed with audio multi-scenario noise;

[0044] A noise audio generation module, configured such that the audio service system transmits each noise type as a text embedding to a potential diffusion model in a noise generation system, wherein the Gaussian noise distribution and the text embedding are used as starting points in the potential diffusion model to gradually generate noise audio samples;

[0045] An audio sample copying module, configured to cause the audio service system to copy each noise audio sample according to a plurality of preset volume multiple thresholds, so as to determine noise audio samples corresponding to the plurality of preset volume multiple thresholds;

[0046] The audio synthesis module is configured so that the audio service system randomly selects one or more noise audio samples corresponding to a preset volume multiple threshold in each noise type, and synthesizes them with the original audio that needs to be processed with multi-scenario audio noise to obtain the noisy audio.

[0047] An electronic device provided to meet another purpose of the present application includes a central processing unit and a memory, wherein the central processing unit is used to call and run a computer program stored in the memory to execute the steps of the audio multi-scenario noise addition processing method described in the present application.

[0048] A computer-readable storage medium is provided to meet another purpose of the present application, which stores a computer program implemented according to the audio multi-scenario noise processing method in the form of computer-readable instructions. When the computer program is called and executed by a computer, the steps included in the corresponding method are executed.

[0049] Compared with the prior art, this application aims to solve the problems that the actual construction of the prior art requires a lot of human resources and time, and the application scenarios are limited to known or foreseeable scenarios. In actual applications, it is time-consuming and labor-intensive to replicate acoustic scenes, and it is difficult for researchers to collect enough scenario-based audio to train models. This application includes but is not limited to the following beneficial effects:

[0050] The audio multi-scenario noise processing method of the present application can greatly improve model training and learning and improve the accuracy of the model in a variety of acoustic scenarios through audio multi-scenario noise processing. It can significantly improve the robustness of the model and evaluate the performance of the model. By adding various noises in the real world to the training data, the model can better adapt to the actual environment and improve its robustness. By adding noise to the test data, the performance of the model in practical applications can be evaluated.

[0051] Furthermore, the audio multi-scenario noise processing method of the present application can add different types of noise at the same time, is simple to operate, takes less time, and significantly improves the processing efficiency of audio noise addition. BRIEF DESCRIPTION OF THE DRAWINGS

[0052] The above and / or additional aspects and advantages of the present application will become apparent and easily understood from the following description of the embodiments in conjunction with the accompanying drawings, in which:

[0053] Figure 1 This is a flowchart of the audio multi-scenario noise processing method in an embodiment of the present application;

[0054] Figure 2 This is a schematic diagram of a noise generation system in an embodiment of the present application performing multi-scenario audio noise addition processing;

[0055] Figure 3 is a schematic diagram of the structure of a noise generation system based on a potential diffusion model in an embodiment of the present application;

[0056] Figure 4 A flowchart of an audio classification model trained in an embodiment of the present application;

[0057] Figure 5 This is a principle block diagram of the audio multi-scenario noise processing device in an embodiment of the present application;

[0058] Figure 6 It is a schematic diagram of the structure of the computer device in the embodiment of the present application. DETAILED DESCRIPTION

[0059] The embodiments of the present application are described in detail below, and examples of the embodiments are shown in the accompanying drawings, wherein the same or similar reference numerals throughout represent the same or similar elements or elements having the same or similar functions. The embodiments described below with reference to the accompanying drawings are exemplary and are only used to explain the present application, and cannot be interpreted as limiting the present application.

[0060] It will be understood by those skilled in the art that, unless expressly stated, the singular forms "one", "said", and "the" used herein may also include plural forms. It should be further understood that the term "comprising" used in the specification of the present application refers to the presence of the features, integers, steps, operations, elements and / or components, but does not exclude the presence or addition of one or more other features, integers, steps, operations, elements, components and / or groups thereof. It should be understood that when we refer to an element as being "connected" or "coupled" to another element, it may be directly connected or coupled to the other element, or there may be an intermediate element. In addition, the "connection" or "coupling" used herein may include wireless connection or wireless coupling. The term "and / or" used herein includes all or any unit and all combinations of one or more associated listed items.

[0061] It will be understood by those skilled in the art that, unless otherwise defined, all terms (including technical and scientific terms) used herein have the same meaning as those generally understood by those skilled in the art to which this application belongs. It should also be understood that terms such as those defined in general dictionaries should be understood to have meanings consistent with those in the context of the prior art, and will not be interpreted with idealized or overly formal meanings unless specifically defined as here.

[0062] It will be understood by those skilled in the art that the "client", "terminal" and "terminal device" used herein include both devices with wireless signal receivers, which are devices with only wireless signal receivers without transmission capabilities, and devices with receiving and transmitting hardware, which are devices with receiving and transmitting hardware capable of two-way communication on a two-way communication link. Such devices may include: cellular or other communication devices such as personal computers, tablet computers, which have single-line displays or multi-line displays or cellular or other communication devices without multi-line displays; PCS (Personal Communications Service, personal communication system), which can combine voice, data processing, fax and / or data communication capabilities; PDA (Personal Digital Assistant, personal digital assistant), which may include a radio frequency receiver, pager, Internet / intranet access, web browser, notepad, calendar and / or GPS (Global Positioning System, global positioning system) receiver; conventional laptop and / or palmtop computers or other devices, which have and / or include a conventional laptop and / or palmtop computer or other device with and / or including a radio frequency receiver. The "client", "terminal" and "terminal device" used herein may be portable, transportable, installed in a vehicle (air, sea and / or land), or suitable for and / or configured to run locally, and / or in a distributed form, at any other location on the earth and / or in space. The "client", "terminal" and "terminal device" used herein may also be a communication terminal, an Internet terminal, a music / video playing terminal, for example, a PDA, a MID (Mobile Internet Device) and / or a mobile phone with a music / video playing function, or a smart TV, a set-top box and other devices.

[0063] The hardware referred to by the names such as "server", "client", and "service node" in this application is essentially an electronic device with the equivalent capabilities of a personal computer. It is a hardware device with the necessary components revealed by the von Neumann principle, such as a central processing unit (including an arithmetic unit and a controller), a memory, an input device, and an output device. The computer program is stored in its memory, and the central processing unit calls the program stored in the external memory into the internal memory for execution, executes the instructions in the program, and interacts with the input and output devices to complete specific functions.

[0064] It should be pointed out that the concept of "server" referred to in this application can also be extended to the case of server clusters. According to the network deployment principle understood by those skilled in the art, the servers should be logically divided. In physical space, these servers can be independent of each other but can be called through interfaces, or integrated into a physical computer or a set of computer clusters. Those skilled in the art should understand this flexibility, and should not use it to restrict the implementation of the network deployment method of this application.

[0065] Unless expressly specified, one or more technical features of the present application can be deployed on a server for implementation and accessed by a client through a remote call to obtain an online service interface provided by the server, or can be directly deployed and run on a client for access.

[0066] The neural network models referenced or may be referenced in this application, unless expressly specified, can be deployed on a remote server and remotely called on the client, or can be deployed and directly called on a client with sufficient device capabilities. In some embodiments, when it runs on the client, its corresponding intelligence can be obtained through transfer learning to reduce the requirements for the client's hardware operating resources and avoid excessive occupation of the client's hardware operating resources.

[0067] Unless explicitly specified, the various data involved in this application can be stored remotely on a server or on a local terminal device, as long as it is suitable for being called by the technical solution of this application.

[0068] Those skilled in the art should be aware that, although the various methods of the present application are described based on the same concept and thus present commonality to each other, unless otherwise specified, these methods can be independently executed. Similarly, for each embodiment disclosed in the present application, they are all proposed based on the same inventive concept, therefore, concepts with the same expression, and concepts that are appropriately changed for convenience despite different expressions, should be understood as equivalent.

[0069] Unless the mutually exclusive relationship between the embodiments to be disclosed in this application is explicitly stated, the relevant technical features involved in each embodiment can be cross-combined to flexibly construct a new embodiment, as long as such combination does not deviate from the creative spirit of this application and can meet the needs of the prior art or solve certain deficiencies in the prior art. Those skilled in the art should be aware of this flexibility.

[0070] See also Figure 1 as well as Figure 2 In one embodiment, the audio multi-scenario noise processing method of the present application includes:

[0071] Step S10: In response to the audio multi-scenario noise adding processing instruction, the audio service system obtains the noise type in the target acoustic scene and the original audio that needs to be processed with the audio multi-scenario noise adding processing;

[0072] The audio service system can respond to an audio multi-scenario noise processing instruction. The audio service system can obtain the noise type in the target acoustic scene and the original audio that needs to be processed with audio multi-scenario noise. The noise type in the target acoustic scene can be the hawking of street vendors, the crying of babies, the singing of birds outside the window, etc. All of the above can be used as the noise type in the target acoustic scene and used to generate noise audio samples. The noise audio samples can be used as a training set for an audio classification model for training the audio classification model.

[0073] In some embodiments, the audio classification model may be a convolutional neural network (CNN), a recurrent neural network (RNN) and its variants, a hybrid model (CNN+RNN), a self-attention model (Transformer), etc.

[0074] In some embodiments, convolutional neural networks (CNNs) are widely used in audio classification. Usually, audio data is converted into spectrograms or mel-spectrograms and then input into CNNs for processing and classification. CNNs can effectively capture the temporal relationship between local features and spectra and are suitable for many audio classification tasks, such as speech recognition, environmental sound classification, etc.

[0075] In some embodiments, recurrent neural networks (RNNs) and their variants: RNNs and their variants (such as long short-term memory networks LSTMs, gated recurrent units GRUs, etc.) have good adaptability for processing sequence data (such as audio waveforms). They can model the dynamic changes of audio data in time, and therefore perform well in audio classification tasks that need to consider timing information, such as sentiment analysis, speech emotion recognition, etc.

[0076] In some embodiments, hybrid models (CNN+RNN), in many practical applications, CNN and RNN are combined to take advantage of their respective strengths. For example, CNN can be used to extract spectral features and generate high-level feature representations, and then these feature sequences are input into RNN for classification. This method is often used in speech recognition and long audio segment classification.

[0077] Step S20: the audio service system transmits each noise type as a text embedding to a potential diffusion model in a noise generation system, and uses Gaussian noise distribution and the text embedding as a starting point in the potential diffusion model to gradually generate noise audio samples;

[0078] After the audio service system obtains the noise type in the target acoustic scene and the original audio that needs to be processed with multi-scenario audio noise, the audio service system transmits each noise type as a text embedding to the latent diffusion model in the noise generation system, and uses Gaussian noise distribution and the text embedding as a starting point in the latent diffusion model to gradually generate noise audio samples, and the text embedding is a prompt text;

[0079] Further, the audio service system transmits each noise type as a text embedding to a potential diffusion model in the noise generation system, and uses Gaussian noise distribution and the text embedding as a starting point in the potential diffusion model to gradually generate noise audio samples, including:

[0080] Step S201, generating an audio prior based on comparative text audio pre-training in the latent diffusion model;

[0081] Step S203: using a variational autoencoder as a decoder, and reconstructing a Mel-spectrogram according to the audio prior;

[0082] Step S205: Use a preset generative adversarial network as a vocoder to generate high-quality noise audio samples according to the mel-spectrogram.

[0083] Specifically, see Figure 3 , the basic network architecture of the adversarial generative network is the Hi Fi-GAN adversarial generative network, and the potential diffusion model includes a diffusion process and a reverse diffusion process;

[0084] In the diffusion process, the text is embedded in each time step n∈[1,...,N], and the transition probability is given by the following formula:

[0085]

[0086]

[0087] Among them, β n is a predefined noise scale and satisfies 0<β 1 <···<β n <...<β N <1,α n is 1-β n The reparameterization of represents the noise level at each step, represents the injected standard Gaussian distribution noise, at the last time step N, Has a standard isotropic Gaussian distribution;

[0088] For model optimization, a reweighted noise estimation training objective is used:

[0089]

[0090] Among them, θ is the current parameter situation (i.e. various matrices and weights), Represents the calculation of ∈ and ∈ θ (z n ,n,E y ), ∈ is the injected noise, ∈ θ (z n ,n,E y ) is the prediction noise, z n is the Gaussian distribution of the prediction noise, n is the time step, E x It is compared with the pre-trained audio encoder f in text audio pre-training audio (·) Embedding of the generated audio waveform x;

[0091] In the reverse diffusion process, from the Gaussian noise distribution and text embedding E y Start by embedding E with the text y The denoising process is conditioned on the condition that the audio prior z is gradually generated through the following process 0 ,include:

[0092]

[0093] The mean and variance are parameterized as:

[0094]

[0095] Among them, ∈ θ (z n ,n,E y ) is the prediction noise, In the training phase, the audio embedding E of the audio sample x is x Learning to generate audio prior z 0 , in the prediction phase, providing text embedding E y To predict the noise ∈ θ (z n ,n,E y ).

[0096] In some embodiments, in contrastive text-audio pre-training, the noisy audio sample is denoted as x and the text description is denoted as y, which is trained using a text encoder f text (·) and the audio encoder f audio (·) Extract text embedding E respectively y and audio embed x .

[0097] Furthermore, the audio service system transmits each noise type as a text embedding to a potential diffusion model in the noise generation system, and uses Gaussian noise distribution and the text embedding as a starting point in the potential diffusion model to gradually generate noise audio samples, including:

[0098] Step S2001, in a variational autoencoder, the variational autoencoder consists of an encoder and a decoder with a stacked convolution module;

[0099] Step S2003: The encoder compresses the Mel-spectrogram X into a latent space Where r represents the compression ratio;

[0100] Step S2005: The decoder generates an audio prior representation from the potential diffusion model. Constructing Mel-spectrogram The preset adversarial generation network is used as the vocoder to obtain the mel spectrum map Noise audio samples

[0101] Step S30: the audio service system copies each noise audio sample according to a plurality of preset volume multiple thresholds to determine the noise audio samples corresponding to the plurality of preset volume multiple thresholds;

[0102] In the latent diffusion model, Gaussian noise distribution and the text embedding are used as starting points to gradually generate noise audio samples. The audio service system then copies each noise audio sample according to a plurality of preset volume multiple thresholds to determine the noise audio samples corresponding to the plurality of preset volume multiple thresholds. The plurality of preset volume multiple thresholds may be 0%, 25%, 50%, 75%, 100%, and the like.

[0103] Step S40: The audio service system randomly selects one or more noise audio samples corresponding to a preset volume multiple threshold in each noise type, and synthesizes them with the original audio that needs to be subjected to audio multi-scenario noise processing to obtain the noisy audio.

[0104] After determining the noise audio samples corresponding to the multiple preset volume multiple thresholds, the audio service system randomly selects one or more noise audio samples corresponding to the preset volume multiple thresholds in each noise type, and synthesizes them with the original audio that needs to be processed for multi-scenario audio noise to obtain the noisy audio.

[0105] In some embodiments, the user inputs the noise type NoiseType in the target acoustic scene to the audio service system. 1 ,nt 2 ,…,ntm ] and original audio A;

[0106] The audio service system will each noise type nt i As prompt text E y The incoming noise generation system is derived from a Gaussian noise distribution and text embedding E y Start by gradually generating noisy audio samples

[0107] The audio service system copies each noise audio into five corresponding audios at five volume multiples of 0%, 25%, 50%, 75%, and 100%.

[0108] For each noise type nt i Randomly select a volume multiple And synthesize it with the original audio into multi-channel audio, that is, the noise-added frequency A′.

[0109] In some embodiments, the audio service system randomly selects one or more noise audio samples corresponding to a preset volume multiple threshold in each noise type, and synthesizes them with the original audio that needs to be processed with multi-scenario audio noise, including:

[0110] Step S401: the audio service system opens and reads each audio file and converts it into a NumPy array;

[0111] Step S403, determining the maximum length of all audio data, and filling the data with insufficient length with zeros;

[0112] Step S405: stack all audio data into a two-dimensional array by column, and then flatten it into a one-dimensional array;

[0113] Step S407: create a new WAV audio file and write the flattened audio data into it.

[0114] Specifically, open the audio file, use the readframes method in the standard audio processing library in Python to read all the audio data in the audio file, and convert the audio data into an array, that is, the audio file noise_type_0.wav is represented as [a 1 ,a 2 ,…,a i ]; the audio file noise_type_1.wav is represented by [b 1 ,b 2 ,…,b j ]; the audio file noise_type_2.wav is represented by [c 1 ,c2 ,…,c k ; The audio file original_audio.wav is represented as [d 1 ,d 2 ,…,d l .

[0115] Find the maximum length among all the audio data, and then pad the shorter audio data. That is, when i < j < l < k, noise_type_0.wav is represented as [a 1 ,a 2 ,…,a i ,a i+1 ,…,a k , where a i+1 to a k are all 0; noise_type_1.wav is represented as [b 1 ,b 2 ,…,b j ,b j+1 ,…,b k , where b j+1 to b k are all 0; original_audio.wav is represented as [d 1 ,d 2 ,…,d l ,d l+1 ,…,d k , where d l+1 to d k are all 0; noise_type_2.wav remains unchanged;

[0116] Stack multiple single-channel audio data column by column to form a two-dimensional array, and then flatten it into a one-dimensional array, i.e., [a 1 ,b 1 ,c 1 ,d 1 ,a 2 ,b 2 ,c 2 ,d 2 ,…,a k ,b k ,c k ,d k ;

[0117] Create a new audio file, and then use the writeframes method in the standard audio processing library in Python to write the merged audio data into the file.

[0118] In some embodiments, various noises existing in real scenes are investigated, and corresponding noises are generated according to the noise types. These generated noises are added to the training data so that the model can better adapt to the real-world environment, thereby improving the robustness of the model.

[0119] Please refer to Figure 4 , Figure 4 This is a flow chart of the implementation case of the present invention. The process mainly includes the following steps:

[0120] Step S4001, generating noise audio: after specifying the target scene, investigating various noises existing in the scene, and traversing each noise type, inputting the noise type as a prompt text into the noise generation system, and generating noise audio corresponding to each noise type according to the method of the present invention.

[0121] Step S4003, copy multiple volumes: use torchaudio or other methods to sample the audio, and multiply the sampled values ​​by 0, 0.25, 0.5, 0.75 and 1 respectively to generate multiple groups of audio with different volumes, and save them as multiple audio records.

[0122] Step S4005, synthesize the noisy data set: use random and other methods to mix the data, traverse each original audio in the original data set, randomly select three noise types, extract the noise audio after adjusting the volume, use wave and other methods to perform multi-channel audio synthesis, and generate a noisy data set.

[0123] Step S4007, training model: using the noisy data set as a training set to train a more robust audio task model.

[0124] In some embodiments, the audio multi-scenario noise processing method of the present application is suitable for evaluating the performance of existing models in actual application scenarios by adding noise to test data. For example, a guide robot is deployed in a street environment, and after the voice wake-up and voice recognition models are trained, the street noise generated by the audio multi-scenario noise processing method of the present application is added to the test data set to form a street data set, thereby testing the performance of the voice model on the street data set to evaluate its performance in actual applications.

[0125] It can be seen from the above embodiments that, compared with the prior art, the present application addresses the problems that the actual construction in the prior art requires a lot of human resources and time, and the application scenarios are limited to known or foreseeable scenarios. In actual applications, it is time-consuming and labor-intensive to replicate acoustic scenes, and it is difficult for researchers to collect enough scenario-based audio to train models. The present application includes but is not limited to the following beneficial effects:

[0126] Compared with the prior art, this application aims to solve the problems that the actual construction of the prior art requires a lot of human resources and time, and the application scenarios are limited to known or foreseeable scenarios. In actual applications, it is time-consuming and labor-intensive to replicate acoustic scenes, and it is difficult for researchers to collect enough scenario-based audio to train models. This application includes but is not limited to the following beneficial effects:

[0127] The audio multi-scenario noise processing method of the present application can greatly improve model training and learning and improve the accuracy of the model in a variety of acoustic scenarios through audio multi-scenario noise processing. It can significantly improve the robustness of the model and evaluate the performance of the model. By adding various noises in the real world to the training data, the model can better adapt to the actual environment and improve its robustness. By adding noise to the test data, the performance of the model in practical applications can be evaluated.

[0128] Furthermore, the audio multi-scenario noise processing method of the present application can add different types of noise at the same time, is simple to operate, takes less time, and significantly improves the processing efficiency of audio noise addition.

[0129] See also Figure 5 An audio multi-scenario noise processing device provided to meet one of the purposes of the present application includes an audio acquisition module 1100, a noise audio generation module 1200, an audio sample replication module 1300 and an audio synthesis module 1400. Among them, the audio acquisition module 1100 is configured to respond to the audio multi-scenario noise processing instruction, and the audio service system obtains the noise type in the target acoustic scene and the original audio that needs to be processed for audio multi-scenario noise addition; the noise audio generation module 1200 is configured so that the audio service system transmits each noise type as a text embedding to the potential diffusion model in the noise generation system, and uses Gaussian noise distribution and the text embedding as a starting point in the potential diffusion model to gradually generate noise audio samples; the audio sample replication module 1300 is configured so that the audio service system replicates each noise audio sample according to multiple preset volume multiple thresholds to determine the noise audio samples corresponding to the multiple preset volume multiple thresholds; the audio synthesis module 1400 is configured so that the audio service system randomly selects one or more noise audio samples corresponding to the preset volume multiple thresholds in each noise type, and synthesizes them with the original audio that needs to be processed for audio multi-scenario noise addition to obtain the noise audio.

[0130] Based on any embodiment of this application, please refer to Figure 6 Another embodiment of the present application further provides an electronic device, which can be implemented by a computer device, such as Figure 6As shown, a schematic diagram of the internal structure of a computer device. The computer device includes a processor, a computer-readable storage medium, a memory, and a network interface connected via a system bus. Among them, the computer-readable storage medium of the computer device stores an operating system, a database, and computer-readable instructions. The database may store a control information sequence. When the computer-readable instructions are executed by the processor, the processor can implement an audio multi-scenario noise processing method. The processor of the computer device is used to provide computing and control capabilities to support the operation of the entire computer device. The memory of the computer device may store computer-readable instructions. When the computer-readable instructions are executed by the processor, the processor can execute the audio multi-scenario noise processing method of the present application. The network interface of the computer device is used to connect and communicate with a terminal. Those skilled in the art will understand that Figure 6 The structure shown in the figure is only a block diagram of a part of the structure related to the solution of the present application, and does not constitute a limitation on the computer device to which the solution of the present application is applied. The specific computer device may include more or fewer components than those shown in the figure, or combine certain components, or have a different arrangement of components.

[0131] In this embodiment, the processor is used to execute Figure 5 The memory stores the program code and various data required to execute the above modules or submodules. The network interface is used to transmit data between user terminals or servers. The memory in this embodiment stores the program code and data required to execute all modules / submodules in the audio multi-scenario noise processing device of the present application, and the server can call the program code and data of the server to execute the functions of all submodules.

[0132] The present application also provides a storage medium storing computer-readable instructions. When the computer-readable instructions are executed by one or more processors, the one or more processors execute the steps of the audio multi-scenario noise processing method described in any embodiment of the present application.

[0133] The present application also provides a computer program product, including a computer program / instruction, which, when executed by one or more processors, implements the steps of the audio multi-scenario noise processing method described in any embodiment of the present application.

[0134] Those skilled in the art can understand that all or part of the processes in the above-mentioned embodiments of the present application can be implemented by instructing the relevant hardware through a computer program, and the computer program can be stored in a computer-readable storage medium. When the program is executed, it can include the processes of the embodiments of the above-mentioned methods. Among them, the aforementioned storage medium can be a computer-readable storage medium such as a disk, an optical disk, a read-only memory (ROM), or a random access memory (RAM).

[0135] The above description is only a partial implementation method of the present application. It should be pointed out that for ordinary technicians in this technical field, several improvements and modifications can be made without departing from the principles of the present application. These improvements and modifications should also be regarded as the scope of protection of the present application.

[0136] To sum up, the audio multi-scenario noise processing method of the present application can improve the accuracy of the model through model training and learning in various acoustic scenarios, can significantly improve the model robustness and evaluate the model performance, and by adding various noises in the real world to the training data, the model can better adapt to the actual environment and improve its robustness. By adding noise to the test data, the performance of the model in practical applications can be greatly enhanced.

Claims

1. A method for multi-scenario audio noise processing, It is characterized in that include: In response to the audio multi-scenario noise processing instruction, the audio service system obtains the noise type in the target acoustic scene and the original audio that needs to be processed with the audio multi-scenario noise. The audio service system transmits each noise type as a text embedding to a latent diffusion model in the noise generation system, wherein the latent diffusion model uses Gaussian noise distribution and the text embedding as a starting point to gradually generate noise audio samples; The audio service system copies each noise audio sample according to a plurality of preset volume multiple thresholds to determine the noise audio samples corresponding to the plurality of preset volume multiple thresholds; The audio service system randomly selects one or more noise audio samples corresponding to a preset volume multiple threshold in each noise type, and synthesizes them with the original audio that needs to be subjected to audio multi-scenario noise addition processing to obtain the noisy audio.

2. The audio multi-scenario noise processing method according to claim 1, It is characterized in that The audio service system transmits each noise type as a text embedding to a potential diffusion model in a noise generation system, and uses Gaussian noise distribution and the text embedding as a starting point in the potential diffusion model to gradually generate noise audio samples, including: generating an audio prior based on contrastive text audio pre-training in the latent diffusion model; A variational autoencoder is used as a decoder, and a Mel-spectrogram is reconstructed according to the audio prior; A preset adversarial generative network is used as a vocoder to generate high-quality noise audio samples according to the Mel-spectrogram.

3. The audio multi-scenario noise processing method according to claim 2, It is characterized in that The audio service system transmits each noise type as a text embedding to a potential diffusion model in a noise generation system, and uses Gaussian noise distribution and the text embedding as a starting point in the potential diffusion model to gradually generate noise audio samples, including: The potential diffusion model includes a diffusion process and a reverse diffusion process; In the diffusion process, the text is embedded in each time step n∈[1,...,N], and the transition probability is given by the following formula: Among them, β n is a predefined noise scale and satisfies 0<β 1 <···<β n <...<β N <1,α n is 1-β n The reparameterization of represents the noise level at each step, represents the injected standard Gaussian distribution noise, at the last time step N, Has a standard isotropic Gaussian distribution; For model optimization, a reweighted noise estimation training objective is used: Among them, θ is the current parameter situation, Represents the calculation of ∈ and ∈ θ (z n ,n,E y ), ∈ is the injected noise, ∈ θ (z n ,n,E y ) is the prediction noise, z n is the Gaussian distribution of the prediction noise, n is the time step, E x It is compared with the pre-trained audio encoder f in text audio pre-training audio (·) Embedding of the generated audio waveform x; In the reverse diffusion process, from the Gaussian noise distribution and text embedding E y Start by embedding E with the text y The denoising process is conditioned on the condition that the audio prior z is gradually generated through the following process 0 ,include: The mean and variance are parameterized as: Among them, ∈ θ (z n ,n,E y ) is the prediction noise, In the training phase, the audio embedding E of the audio sample x is x Learning to generate audio prior z 0 , in the prediction phase, providing text embedding E y To predict the noise ∈ θ (z n ,n,E y ).

4. The audio multi-scenario noise processing method according to claim 3, It is characterized in that The audio service system transmits each noise type as a text embedding to a potential diffusion model in a noise generation system, and uses Gaussian noise distribution and the text embedding as a starting point in the potential diffusion model to gradually generate noise audio samples, including: In contrastive text-audio pre-training, the noisy audio sample is represented as x and the text description is represented as y, which uses the text encoder f text (·) and the audio encoder f audio (·) Extract text embedding E respectively y and audio embed x .

5. The audio multi-scenario noise processing method according to claim 2, It is characterized in that The audio service system transmits each noise type as a text embedding to a potential diffusion model in a noise generation system, and uses Gaussian noise distribution and the text embedding as a starting point in the potential diffusion model to gradually generate noise audio samples, including: In a variational autoencoder, the variational autoencoder consists of an encoder and a decoder with stacked convolutional modules; The encoder compresses the mel-spectrogram X into a latent space Where r represents the compression ratio; The decoder generates an audio prior representation from the latent diffusion model Constructing Mel-spectrogram The preset adversarial generation network is used as the vocoder to obtain the mel spectrum map Noise audio samples 6. The audio multi-scenario noise processing method according to claim 1, It is characterized in that The step of the audio service system randomly selecting one or more noise audio samples corresponding to a preset volume multiple threshold in each noise type and synthesizing them with the original audio that needs to be subjected to audio multi-scenario noise processing includes: The audio service system opens and reads each audio file and converts it into a NumPy array; Determine the maximum length of all audio data and fill the insufficient length data with zeros; Stack all audio data into a two-dimensional array by column, and then flatten it into a one-dimensional array; Create a new WAV audio file and write the flattened audio data to it.

7. The audio multi-scenario noise processing method according to any one of claims 1 to 6, It is characterized in that The basic network architecture of the generative adversarial network is the HiFi-GAN generative adversarial network.

8. An audio multi-scenario noise processing device, It is characterized in that include: An audio acquisition module, configured to respond to an audio multi-scenario noise processing instruction, wherein the audio service system acquires the noise type in the target acoustic scene and the original audio that needs to be processed with audio multi-scenario noise; A noise audio generation module, configured such that the audio service system transmits each noise type as a text embedding to a potential diffusion model in a noise generation system, wherein the Gaussian noise distribution and the text embedding are used as starting points in the potential diffusion model to gradually generate noise audio samples; An audio sample copying module, configured to cause the audio service system to copy each noise audio sample according to a plurality of preset volume multiple thresholds, so as to determine noise audio samples corresponding to the plurality of preset volume multiple thresholds; The audio synthesis module is configured so that the audio service system randomly selects one or more noise audio samples corresponding to a preset volume multiple threshold in each noise type, and synthesizes them with the original audio that needs to be processed with multi-scenario audio noise to obtain the noisy audio.

9. An electronic device comprising a central processing unit and a memory, It is characterized in that The central processing unit is used to call and run the computer program stored in the memory to execute the steps of the method according to any one of claims 1 to 7.

10. A computer-readable storage medium, It is characterized in that It stores a computer program implemented according to the method described in any one of claims 1 to 7 in the form of computer-readable instructions, and when the computer program is called and executed by a computer, the steps included in the corresponding method are executed.

Citation Information

Patent Citations

  • Voice noise method and system for data enhancement

    CN110211575A

  • Voice noise reduction method and device based on model fusion and storage medium

    CN117789744A

  • Motion video generation method, diffusion model training method and equipment

    CN118245820A

  • End-to-end general audio synthesis with generative networks

    WO2024086012A1

Cited By

  • Adaptive audio equipment audio data processing system and method

    CN119645340A

  • Concrete filled steel tube void knocking acoustic detection method suitable for low signal-to-noise ratio environment

    CN119988901A

  • Sound equipment audio signal processing method based on artificial intelligence

    CN120412615A

  • Audio separation method and related equipment

    CN120431956A

  • Audio rendering method and device based on speech synthesis, equipment and storage medium

    CN121617383A