Audio processing method and device, electronic equipment and storage medium

By deploying lightweight acoustic feature extraction and audio processing models on terminal devices, the problem of audio processing technology relying on network communication is solved, enabling audio processing in offline mode and ensuring that audio data can be used normally without changing the voice content while changing the timbre.

CN117292705BActive Publication Date: 2026-11-24BEIJING YOUZHUJU NETWORK TECH CO LTD
View PDF 1 Cites 0 Cited by

Patent Information

Application Number
CN202210689173.3
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2022-06-16
Publication Date
2026-11-24
Estimated Expiration
2042-06-16

AI Technical Summary

Technical Problem

Existing audio processing technologies rely on network communication services, which leads to latency and instability issues, preventing users from using audio processing services properly when offline.

Method used

Employing a lightweight acoustic feature extraction model and audio processing model, deployed on terminal devices, it can extract and process audio data offline, changing the timbre without altering the speech content.

Benefits of technology

It enables normal, effective, and efficient audio processing in offline mode, solves the latency and instability problems caused by network dependence, and ensures that users can use audio processing services in areas without network coverage.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN117292705B_ABST
    Figure CN117292705B_ABST
Patent Text Reader

Abstract

This application provides an audio processing method, apparatus, electronic device, and storage medium. The audio processing method of this application is based on a pre-trained acoustic feature extraction model and an audio processing model. The acoustic feature extraction model extracts acoustic features from the user's audio data, and by setting the output method, the extracted acoustic features retain certain pronunciation characteristics in addition to speech content, thus enabling the extracted acoustic features to be better used for audio processing. The audio processing model performs audio processing based on the acoustic features extracted by the acoustic feature extraction model, thereby processing the user's voice input audio data into audio data with a target timbre. This application's solution allows users to use audio processing services normally, effectively, and efficiently offline.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This application relates to the field of computer technology, and in particular to an audio processing method, apparatus, electronic device and storage medium. Background Technology

[0002] With the development of multimedia communication technology and artificial intelligence, speech synthesis and speech recognition technologies have become key technologies for human-computer voice communication. In some application scenarios, due to specific application requirements such as confidentiality and personalization, it is necessary to process the user's input speech through audio processing technology.

[0003] In related technologies, the aforementioned audio processing techniques can be implemented using machine learning models. However, these models are often deployed on the network side, requiring users to rely on network communication services to access the audio processing services online. However, network communication services generally suffer from latency and instability, and in some scenarios, users may be unable to use them at all. All of these situations prevent users from effectively using the audio processing services. Summary of the Invention

[0004] In view of this, the purpose of this application is to provide an audio processing method, apparatus, electronic device and storage medium.

[0005] To achieve the above objectives, this application provides an audio processing method, comprising:

[0006] Acquire the audio data to be processed;

[0007] The audio data to be processed is input into a pre-trained acoustic feature extraction model to obtain the acoustic features to be processed corresponding to the audio data to be processed; the acoustic features to be processed include at least some of the pronunciation mode features of the audio data to be processed;

[0008] The acoustic features to be processed are input into a pre-trained audio processing model to obtain processed audio data with the target timbre that corresponds to the audio data to be processed.

[0009] Based on the same technical concept, this application also provides an audio processing apparatus, including:

[0010] The acquisition module is configured to acquire audio data to be processed.

[0011] The extraction module is configured to input the audio data to be processed into a pre-trained acoustic feature extraction model to obtain the acoustic features to be processed corresponding to the audio data to be processed; the acoustic features to be processed include at least some of the pronunciation mode features of the audio data to be processed;

[0012] The processing module is configured to input the acoustic features to be processed into a pre-trained audio processing model to obtain processed audio data with the target timbre that corresponds to the audio data to be processed.

[0013] Based on the same technical concept, this application also provides an electronic device, including a memory, a processor, and a computer program stored in the memory and executable on the processor, wherein the processor executes the program to implement the method described in any of the above.

[0014] Based on the same technical concept, this application also provides a non-transitory computer-readable storage medium that stores computer instructions for causing a computer to perform the methods described in any of the above-mentioned methods.

[0015] As can be seen from the above, the audio processing method, apparatus, electronic device and storage medium provided in this application, for the needs in offline mode, have correspondingly constructed and connected in parallel to obtain a lightweight acoustic feature extraction model and audio processing model, enabling users to use audio processing services normally, effectively and efficiently in offline mode. Attached Figure Description

[0016] To more clearly illustrate the technical solutions in this application or related technologies, the drawings used in the description of the embodiments or related technologies will be briefly introduced below. Obviously, the drawings described below are only embodiments of this application. For those skilled in the art, other drawings can be obtained based on these drawings without creative effort.

[0017] Figure 1 This is a schematic diagram of the audio processing method according to an embodiment of this application;

[0018] Figure 2 This is a schematic diagram of the training method for the acoustic feature extraction model according to an embodiment of this application;

[0019] Figure 3 This is a schematic diagram of the training method for the audio processing model according to an embodiment of this application;

[0020] Figure 4 This is a schematic diagram of the audio processing device structure according to an embodiment of this application;

[0021] Figure 5 This is a schematic diagram of the electronic device structure according to an embodiment of this application. Detailed Implementation

[0022] It is understood that before using the technical solutions disclosed in the various embodiments of this application, users should be informed of the types, scope of use, and usage scenarios of the personal information involved in this application in an appropriate manner in accordance with relevant laws and regulations, and user authorization should be obtained.

[0023] For example, upon receiving a user's active request, a prompt message is sent to the user to explicitly inform them that the requested operation will require the acquisition and use of the user's personal information. This allows the user to independently choose whether to provide personal information to the software or hardware, such as the electronic device, application, server, or storage medium performing the operations of this application's technical solution, based on the prompt message.

[0024] As an optional but non-limiting implementation, in response to a user's active request, sending a prompt message to the user can be done via a pop-up window, where the prompt message can be presented in text format. Furthermore, the pop-up window can also include a selection control allowing the user to choose "agree" or "disagree" to provide personal information to the electronic device.

[0025] It is understood that the above notification and user authorization process are merely illustrative and do not constitute a limitation on the implementation of this application. Other methods that comply with relevant laws and regulations may also be applied to the implementation of this application.

[0026] It is understood that the data involved in this technical solution (including but not limited to the data itself, the acquisition or use of the data) shall comply with the requirements of relevant laws, regulations and related provisions.

[0027] To make the objectives, technical solutions, and advantages of this application clearer, the following detailed description is provided in conjunction with specific embodiments and the accompanying drawings.

[0028] The principles and spirit of this application will now be described with reference to several exemplary embodiments. It should be understood that these embodiments are provided merely to enable those skilled in the art to better understand and implement this application, and are not intended to limit the scope of this application in any way. Rather, these embodiments are provided to make this application more thorough and complete, and to fully convey the scope of this application to those skilled in the art.

[0029] According to embodiments of this application, an audio processing method, apparatus, electronic device, and storage medium are proposed.

[0030] In this article, it is important to understand that any number of elements in the accompanying figures is for illustrative purposes and not for limitation, and any naming is for distinction only and has no limiting meaning.

[0031] The principles and spirit of this application will be explained in detail below with reference to several representative embodiments.

[0032] In related technologies, because the audio processing model is deployed on the network side (usually a cloud-based server), users cannot use the audio processing service normally and effectively in some situations. For example, when the network communication service is delayed or unstable, users cannot receive the processed audio immediately; or, in areas not covered by the network communication service, or if they have not purchased network communication service at all, users cannot use the aforementioned audio processing service at all.

[0033] To address the aforementioned problems, this application provides an audio processing solution. The audio processing method of this application is based on a pre-trained acoustic feature extraction model and an audio processing model. The acoustic feature extraction model is a lightweight improvement of a speech recognition model in related technologies. It can extract acoustic features from the user's audio data, and by setting the output method, the extracted acoustic features retain certain pronunciation characteristics in addition to the speech content. This allows the extracted acoustic features to be better used for audio processing, and the lightweight improved acoustic feature extraction model can meet the deployment and implementation requirements on terminal devices in offline mode. The audio processing model performs audio processing based on the acoustic features extracted by the acoustic feature extraction model, thereby processing the user's voice input audio data into audio data with a target timbre, thus working in conjunction with the acoustic feature extraction model to achieve audio processing in offline mode. This application's solution, addressing the needs in offline mode, provides a lightweight acoustic feature extraction model and an audio processing model, enabling users to use audio processing services normally, effectively, and efficiently offline.

[0034] First, this application provides an audio processing method. This audio processing method is applied to a terminal device, which includes, but is not limited to, desktop computers, mobile phones, mobile computers, tablet computers, media players, smart wearable devices, personal digital assistants (PDAs), or other electronic devices capable of performing the aforementioned functions. In this application embodiment, the terminal device also deploys a pre-trained acoustic feature extraction model and an audio processing model.

[0035] refer to Figure 1 The audio processing method of this embodiment may include the following steps:

[0036] Step S101: Obtain the audio data to be processed.

[0037] In practice, the audio data input by the user is acquired through the audio acquisition component (such as a microphone) of the terminal device. This audio data is referred to as the audio data to be processed in this embodiment of the application. The timbre of the audio data to be processed is the timbre of the current user.

[0038] Step S102: Input the audio data to be processed into a pre-trained acoustic feature extraction model to obtain the acoustic features to be processed corresponding to the audio data to be processed; the acoustic features to be processed include at least some of the pronunciation mode features of the audio data to be processed.

[0039] In specific implementation, the acquired audio data to be processed is input into a pre-trained acoustic feature extraction model to obtain the acoustic features output by the acoustic feature extraction model corresponding to the audio data to be processed. In this embodiment, the acoustic features generated by the acoustic feature extraction model based on the audio data to be processed are referred to as the acoustic features to be processed. Based on the characteristics of the acoustic feature extraction model in this embodiment, the acoustic features to be processed, while including relatively complete features of the speech content of the first audio data, can also include features reflecting pronunciation patterns such as stress and length of vowels. Furthermore, other specific implementations of the acoustic feature extraction model can be found in the embodiments described below.

[0040] Step S103: Input the acoustic features to be processed into a pre-trained audio processing model to obtain processed audio data with the target timbre that corresponds to the audio data to be processed.

[0041] In practice, the acoustic features to be processed are input into a pre-trained audio processing model to obtain audio data output by the audio processing model that corresponds to the audio data to be processed. In this embodiment, the audio data generated by the audio processing model based on the acoustic features to be processed is referred to as the processed audio data. Based on the characteristics of the audio processing model in this embodiment, the speech content of the processed audio data is the same as the speech content of the audio data to be processed, and the timbre of the processed audio data is converted from the current user's own timbre to the target timbre.

[0042] In practice, since both the acoustic feature extraction model and the audio processing model are pre-trained and both are lightweight, they can be adapted to the computing resources of the terminal device. Therefore, the audio processing method in this embodiment can work offline and does not rely on network communication services.

[0043] As an optional implementation, after inputting the audio data to be processed into the acoustic feature extraction model, the audio data can also be deleted. Deleting the audio data immediately after it has been used can save storage space on the terminal device and further reduce the resource consumption of the terminal device when implementing the audio processing method of this application embodiment.

[0044] The audio processing method described in the above embodiments enables users to use audio processing services normally, effectively, and efficiently offline, based on a lightweight acoustic feature extraction model and an audio processing model.

[0045] As an optional implementation, embodiments of this application also include a method for training an acoustic feature extraction model.

[0046] refer to Figure 2 The training method for the acoustic feature extraction model in this embodiment may include the following steps:

[0047] Step S201: Obtain the first audio data.

[0048] In practice, in order to construct a training dataset for training the acoustic feature extraction model, it is necessary to obtain a certain amount of audio data containing human speech. In this embodiment, such audio data is referred to as the first audio data.

[0049] Step S202: Generate a first acoustic feature corresponding to the first audio data according to a predetermined speech recognition model; the first acoustic feature is output by any hidden layer near the output layer in the speech recognition model.

[0050] In specific implementation, any speech recognition model from related technologies can be selected as the predetermined speech recognition model in the embodiments of this application. For example, the speech recognition model can be D-fsmn, tacotron, fastspeech, fastspeech2, fastpitch, etc. The speech recognition model can perform speech recognition on audio data containing human speech to obtain the acoustic features corresponding to the audio data. The type of acoustic feature used can be arbitrarily selected according to the selected speech recognition model or implementation needs. For example, it can be one or more combinations of MFCC (Mel Frequency Cepstrum Coefficients), FBANK (Mel-filterbank energy features), pitch (fundamental frequency), and voiceless (voice flag features), or any other type of acoustic feature.

[0051] In practice, the first audio data obtained in the aforementioned steps is input into the speech recognition model and processed for speech recognition. The acoustic features obtained from the speech recognition model are referred to as the first acoustic features. The speech recognition model generally includes an input layer, an output layer, and hidden layers that are fully connected sequentially between the input and output layers. Each hidden layer contains several neurons used to extract deeper features from the data. The output layer performs regression or classification processing on the feature data output from the hidden layers to obtain the final output acoustic features.

[0052] In specific implementation, this embodiment does not select the output of the final output layer of the speech recognition model as the first acoustic feature. Instead, it uses the output of any hidden layer near the output layer as the first acoustic feature. The design concept behind this is that the output of the final output layer of the speech recognition model often only includes the speech content features of the first audio data, and no longer includes the pronunciation features of the speech in the first audio data. For example, if the first audio data is the speech "hello" uttered by an adult male, then after speech recognition processing by the speech recognition model, the output feature of the output layer of the speech recognition model only includes the feature data of the speech content "hello," and does not include the original adult male's timbre, or the pronunciation features such as stress and vowel length. However, the audio processing service required in this embodiment only needs to change the timbre of the audio data while retaining the speech content and pronunciation. Based on the characteristics of a typical speech recognition model, the output of several hidden layers near the output layer can include both speech content features and pronunciation features. Therefore, in this embodiment, the output of any hidden layer near the output layer of the speech recognition model is selected as the first acoustic feature.

[0053] In specific implementation, the output of any hidden layer near the output layer in the speech recognition model can be selected as the first acoustic feature according to specific implementation needs. The setting of the aforementioned first acoustic feature ensures that the first acoustic feature obtained in this embodiment can include not only relatively complete features of the speech content of the first audio data, but also features reflecting pronunciation patterns such as stress and vowel length. As an optional implementation, considering that the output of the last hidden layer in the speech recognition model, i.e., the hidden layer immediately adjacent to the output layer, can better balance speech content features and pronunciation pattern features, the step of generating the first acoustic feature can be: inputting the first audio data into the speech recognition model, and extracting the output of the hidden layer immediately adjacent to the output layer in the speech recognition model as the first acoustic feature corresponding to the first audio data.

[0054] Step S203: Generate a first training dataset based on the first audio data and the first acoustic features.

[0055] In specific implementation, a training dataset is generated based on the first audio data obtained from the aforementioned steps and the first acoustic feature corresponding to the first audio data. This training dataset is used to train the acoustic feature extraction model subsequently, and is referred to as the first training dataset in this embodiment. The first training dataset includes a certain number of training samples, each containing input data and corresponding label data. In this embodiment, the training samples in the first training dataset use the first audio data as input data and the first acoustic feature as the corresponding label data; that is, the sample format of the first training dataset is constructed as "first audio data ~ first acoustic feature".

[0056] Step S204: Obtain the acoustic feature extraction model; the size of the acoustic feature extraction model is smaller than the size of the speech recognition model.

[0057] In specific implementation, a pre-constructed acoustic feature extraction model is obtained. This acoustic feature extraction model can be obtained by lightweighting the speech recognition model selected in the embodiments of this application. The size of the lightweight acoustic feature extraction model is much smaller than that of the speech recognition model. The purpose is to make the lightweight acoustic feature extraction model compatible with the computing resources of the terminal device, such as memory and processor, so that it can work normally offline using only the computing resources of the terminal device.

[0058] In practical implementation, the main content of the lightweight modification of the acoustic feature extraction model lies in reducing the number of hidden layers and the number of neurons in each hidden layer, while maintaining the overall structural form of the model. The reduction in the number of hidden layers and the number of neurons in each hidden layer can be set according to the computing resource configuration of the terminal device to which the method of this application is applied or other implementation needs. As an optional implementation, considering the adaptation to the computing resource configuration of most current terminal devices, the number of hidden layers in the acoustic feature extraction model can be set to no more than one-fifth of the number of hidden layers in the speech recognition model. On the other hand, for any hidden layer of the acoustic feature extraction model, the number of neurons in that hidden layer can be set to no more than one-quarter of the number of neurons in any hidden layer of the speech recognition model.

[0059] Step S205: Train the acoustic feature extraction model based on the first training dataset.

[0060] In specific implementation, based on the aforementioned constructed first training dataset and the obtained lightweight acoustic feature extraction model, the acoustic feature extraction model is trained using the first training dataset. Specifically, a loss function is constructed, and based on each training sample included in the first training dataset, the acoustic feature extraction model is iteratively trained using a predetermined training algorithm. The model parameters of the acoustic feature extraction model are updated at each iteration, and the trained acoustic feature extraction model is obtained after reaching a predetermined convergence condition (generally, a predetermined number of iterations). The setting of the loss function, the training algorithm used, and the convergence condition can all be implemented using any feasible method from related technologies; this application embodiment does not limit the specific selection of these methods.

[0061] The acoustic feature extraction model training method described in the above embodiments can be used to train an acoustic feature extraction model. This acoustic feature extraction model is a lightweight improvement of the speech recognition model in related technologies. It can extract the acoustic features of the user's audio data. By setting the output mode, the extracted acoustic features retain certain pronunciation features in addition to the speech content, thereby enabling the extracted acoustic features to be better used for audio processing. Furthermore, the lightweight improved acoustic feature extraction model can meet the deployment and implementation requirements of the terminal device in offline mode.

[0062] As an optional implementation, embodiments of this application also include a method for training an audio processing model.

[0063] refer to Figure 3 The training method for the audio processing model in this embodiment may include the following steps:

[0064] Step S301: Obtain second audio data with the target timbre.

[0065] In specific implementation, to construct a training dataset for training the audio processing model, a certain amount of audio data containing human speech needs to be acquired. In this embodiment, this audio data is referred to as second audio data. In this embodiment, all second audio data have the same timbre characteristics, and the timbre shared by all second audio data is called the target timbre. Timbre refers to the unique and distinctive characteristics of different sounds in terms of waveform; that is, timbre can be understood as the uniqueness of the voice of different speakers. The audio processing to be implemented by the methods in various embodiments of this application is to convert the original timbre of the user's speech into another fixed timbre without changing the language content. Therefore, the acquired certain amount of second audio data consists of audio data with the same target timbre but different language content. Furthermore, the specific selection of the target timbre can be set according to specific implementation needs, and is not limited in this embodiment.

[0066] Step S302: Input the second audio data into a pre-trained acoustic feature extraction model to obtain the second acoustic feature corresponding to the second audio data; the acoustic feature extraction model is trained based on the training method of the acoustic feature extraction model of any of the foregoing embodiments.

[0067] In specific implementation, the second audio data is input into the acoustic feature extraction model, which is trained based on the training method of the acoustic feature extraction model in any of the aforementioned embodiments. For any input second audio data, the acoustic feature extraction model can output the corresponding acoustic features. In this embodiment, the acoustic features generated by the acoustic feature extraction model that correspond to the second audio data are referred to as the second acoustic features.

[0068] Step S303: Generate a second training dataset based on the second acoustic features and the second audio data.

[0069] In specific implementation, a training dataset is generated based on the second audio data obtained from the aforementioned steps and the second acoustic features corresponding to the second audio data. This training dataset is used to train the audio processing model subsequently, and is referred to as the second training dataset in this embodiment. The second training dataset includes a certain number of training samples, which include input data and corresponding label data. In this embodiment, the training samples in the second training dataset use the second acoustic features as input data and the second audio data as corresponding label data; that is, the sample format of the second training dataset is constructed as "second acoustic features ~ second audio data".

[0070] Step S304: Obtain the audio processing model and train the audio processing model based on the second training dataset.

[0071] In practice, a pre-built audio processing model is obtained, which can be based on any end-to-end audio processing model in related technologies. This end-to-end audio processing model takes audio data as input, encodes the input audio data using an encoder, and then decodes the encoded result using a decoder to obtain the audio processing result. Subsequently, a vocoder processes the audio processing result output from the decoder to obtain the corresponding waveform data. The waveform data output by the vocoder can then be used to output audio through audio output devices such as speakers.

[0072] As an optional implementation, the size of the audio processing model can be further reduced to make it compatible with the computing resources of the terminal device, thereby ensuring normal operation in offline mode. Specifically, the encoder and vocoder can be modeled jointly, that is, the audio processing model in this embodiment only includes an encoder and a vocoder. The encoder is configured to encode the second acoustic feature of the input to obtain the corresponding encoded feature; the vocoder is directly connected to the encoder and is configured to generate audio data with the target timbre based on the encoded feature output by the encoder. In specific implementations, both the encoder and vocoder can be implemented using any feasible model from related technologies; for example, the encoder can be any of the speech recognition models exemplified in the embodiments of this application, and the vocoder can be Melgan, WaveRNN, WaveGlow, LPCnet, etc.

[0073] In specific implementation, based on the aforementioned constructed second training dataset and the obtained audio processing model, the audio processing model is trained according to the second training dataset. Specifically, a loss function is constructed, and based on each training sample included in the second training dataset, the audio processing model is iteratively trained using a predetermined training algorithm. The model parameters of the audio processing model are updated at each iteration, and the trained audio processing model is obtained after reaching a predetermined convergence condition (generally, a predetermined number of iterations). The setting of the loss function, the training algorithm used, and the convergence condition can all be implemented using any feasible method from related technologies; this application embodiment does not limit the specific selection of these methods.

[0074] As an optional implementation, to further reduce the model size during the training of the audio processing model, parameter sharing can be performed on several hidden layers included in the audio processing model. Specifically, the steps of training the audio processing model can include: determining at least two target hidden layers from the hidden layers included in the audio processing model; and sharing the parameters of the at least two target hidden layers. In specific implementation, the hidden layers to be parameter-shared are referred to as target hidden layers in this embodiment. The number of target hidden layers is at least two. During any one or more iterations of the audio processing model training, when updating the model parameters through a training algorithm (such as gradient descent), the parameters of the determined target hidden layers are shared. This processing can reduce the model size of the audio processing model and simultaneously improve the efficiency of model training. The specific number of target hidden layers can be set according to implementation needs.

[0075] The audio processing model training method described in the above embodiments can train an audio processing model that can generate corresponding audio data with the target timbre by taking the acoustic features obtained from the acoustic feature extraction model as input. Furthermore, by employing methods such as joint modeling of the encoder and vocoder and parameter sharing, the model size of the audio processing model can be further reduced, enabling the audio processing model of this application embodiment to meet the deployment and implementation requirements on terminal devices in an offline state.

[0076] It should be noted that the above description describes some embodiments of this application. Other embodiments are within the scope of the appended claims. In some cases, the actions or steps recorded in the claims can be performed in a different order than that shown in the above embodiments and still achieve the desired result. Furthermore, the processes depicted in the drawings do not necessarily require a specific or sequential order to achieve the desired result. In some embodiments, multitasking and parallel processing are also possible or may be advantageous.

[0077] Based on the same technical concept, embodiments of this application also provide an audio processing apparatus. (See reference...) Figure 4 The audio processing device 400 includes:

[0078] The acquisition module 401 is configured to acquire audio data to be processed.

[0079] Extraction module 402 is configured to input the audio data to be processed into a pre-trained acoustic feature extraction model to obtain the acoustic features to be processed corresponding to the audio data to be processed; the acoustic features to be processed include at least some of the pronunciation mode features of the audio data to be processed;

[0080] The processing module 403 is configured to input the acoustic features to be processed into a pre-trained audio processing model to obtain processed audio data with the target timbre that corresponds to the audio data to be processed.

[0081] In some optional embodiments, the extraction module 402 is further configured to: acquire first audio data; generate a first acoustic feature corresponding to the first audio data according to a predetermined speech recognition model; the first acoustic feature is output by any hidden layer near the output layer in the speech recognition model; generate a first training dataset according to the first audio data and the first acoustic feature; acquire an acoustic feature extraction model; the size of the acoustic feature extraction model is smaller than the size of the speech recognition model; and train the acoustic feature extraction model according to the first training dataset.

[0082] In some optional embodiments, the extraction module 402 is specifically configured to input the first audio data into the speech recognition model and extract the output of a hidden layer adjacent to the output layer in the speech recognition model as the first acoustic feature corresponding to the first audio data.

[0083] In some optional embodiments, the number of hidden layers included in the acoustic feature extraction model does not exceed one-fifth of the number of hidden layers included in the speech recognition model; and for any hidden layer of the acoustic feature extraction model, the number of neurons included in that hidden layer does not exceed one-quarter of the number of neurons included in any hidden layer of the speech recognition model.

[0084] In some optional embodiments, the processing module 403 is further configured to: acquire second audio data having a target timbre; input the second audio data into the acoustic feature extraction model to obtain a second acoustic feature corresponding to the second audio data; generate a second training dataset based on the second acoustic feature and the second audio data; acquire an audio processing model and train the audio processing model based on the second training dataset.

[0085] In some optional embodiments, the audio processing model includes an encoder and a vocoder; wherein the encoder is configured to encode features corresponding to the second acoustic feature; and the vocoder is configured to generate audio data with a target timbre based on the encode features.

[0086] In some alternative embodiments, the processing module 403 is specifically configured to determine at least two target hidden layers from the hidden layers included in the audio processing model; and to share parameters between the at least two target hidden layers.

[0087] In some alternative embodiments, the processing module 403 is also configured to delete the audio data to be processed after inputting it into a pre-trained acoustic feature extraction model.

[0088] For ease of description, the above devices are described in terms of function, divided into various modules. Of course, in implementing this application, the functions of each module can be implemented in one or more software and / or hardware.

[0089] The apparatus of the above embodiments is used to implement the audio processing method of any of the foregoing embodiments, and has the beneficial effects of the corresponding method embodiments, which will not be repeated here.

[0090] Based on the same technical concept, this application also provides an electronic device, including a memory, a processor, and a computer program stored in the memory and executable on the processor. When the processor executes the program, it implements the audio processing method as described in any of the above embodiments.

[0091] Figure 5 This embodiment illustrates a more specific hardware structure of an electronic device, which may include a processor 1010, a memory 1020, an input / output interface 1030, a communication interface 1040, and a bus 1050. The processor 1010, memory 1020, input / output interface 1030, and communication interface 1040 are interconnected internally via the bus 1050.

[0092] The processor 1010 can be implemented using a general-purpose CPU (Central Processing Unit), microprocessor, application-specific integrated circuit (ASIC), or one or more integrated circuits, and is used to execute relevant programs to implement the technical solutions provided in the embodiments of this specification.

[0093] The memory 1020 can be implemented in the form of ROM (Read Only Memory), RAM (Random Access Memory), static storage device, dynamic storage device, etc. The memory 1020 can store the operating system and other applications. When the technical solutions provided in the embodiments of this specification are implemented by software or firmware, the relevant program code is stored in the memory 1020 and is called and executed by the processor 1010.

[0094] The input / output interface 1030 is used to connect input / output modules to realize information input and output. Input / output modules can be configured as components within the device (not shown in the figure) or externally connected to the device to provide corresponding functions. Input devices may include keyboards, mice, touchscreens, microphones, various sensors, etc., while output devices may include displays, speakers, vibrators, indicator lights, etc.

[0095] The communication interface 1040 is used to connect a communication module (not shown in the figure) to enable communication between this device and other devices. The communication module can communicate via wired means (such as USB, Ethernet cable, etc.) or wireless means (such as mobile network, WIFI, Bluetooth, etc.).

[0096] Bus 1050 includes a pathway for transmitting information between various components of the device, such as processor 1010, memory 1020, input / output interface 1030, and communication interface 1040.

[0097] It should be noted that although the above-described device only shows the processor 1010, memory 1020, input / output interface 1030, communication interface 1040, and bus 1050, in specific implementations, the device may also include other components necessary for normal operation. Furthermore, those skilled in the art will understand that the above-described device may only include the components necessary for implementing the embodiments of this specification, and not necessarily all the components shown in the figures.

[0098] The electronic devices described above are used to implement the corresponding audio processing methods in any of the foregoing embodiments and have the beneficial effects of the corresponding method embodiments, which will not be repeated here.

[0099] Based on the same technical concept, embodiments of this application also provide a non-transitory computer-readable storage medium that stores computer instructions for causing the computer to perform the audio processing method as described in any of the above embodiments.

[0100] The computer-readable medium of this embodiment includes permanent and non-permanent, removable and non-removable media, and information storage can be implemented by any method or technology. Information can be computer-readable instructions, data structures, program modules, or other data. Examples of computer storage media include, but are not limited to, phase-change memory (PRAM), static random access memory (SRAM), dynamic random access memory (DRAM), other types of random access memory (RAM), read-only memory (ROM), electrically erasable programmable read-only memory (EEPROM), flash memory or other memory technologies, CD-ROM, digital versatile optical disc (DVD) or other optical storage, magnetic tape, magnetic magnetic disk storage or other magnetic storage devices, or any other non-transfer medium that can be used to store information accessible by a computing device.

[0101] The computer instructions stored in the storage medium of the above embodiments are used to cause the computer to execute the audio processing method as described in any of the above embodiments, and have the beneficial effects of the corresponding method embodiments, which will not be repeated here.

[0102] According to one or more embodiments of this disclosure, Example 1 provides an audio processing method, including:

[0103] Acquire the audio data to be processed;

[0104] The audio data to be processed is input into a pre-trained acoustic feature extraction model to obtain the acoustic features to be processed corresponding to the audio data to be processed; the acoustic features to be processed include at least some of the pronunciation mode features of the audio data to be processed;

[0105] The acoustic features to be processed are input into a pre-trained audio processing model to obtain processed audio data with the target timbre that corresponds to the audio data to be processed.

[0106] According to one or more embodiments of this disclosure, Example 2 provides the method of Example 1, the method further comprising training the acoustic feature extraction model by:

[0107] Obtain the first audio data;

[0108] Based on a predetermined speech recognition model, a first acoustic feature corresponding to the first audio data is generated; the first acoustic feature is output by any hidden layer near the output layer in the speech recognition model.

[0109] A first training dataset is generated based on the first audio data and the first acoustic features;

[0110] Obtain an acoustic feature extraction model; the size of the acoustic feature extraction model is smaller than the size of the speech recognition model;

[0111] The acoustic feature extraction model is trained based on the first training dataset.

[0112] According to one or more embodiments of this disclosure, Example 3 provides the method of Example 2, wherein generating a first acoustic feature corresponding to the first audio data according to a predetermined speech recognition model includes:

[0113] The first audio data is input into the speech recognition model, and the output of a hidden layer adjacent to the output layer in the speech recognition model is extracted as the first acoustic feature corresponding to the first audio data.

[0114] According to one or more embodiments of this disclosure, Example 4 provides the method of Example 2, wherein the number of hidden layers included in the acoustic feature extraction model does not exceed one-fifth of the number of hidden layers included in the speech recognition model; and for any hidden layer of the acoustic feature extraction model, the number of neurons included in the hidden layer does not exceed one-quarter of the number of neurons included in any hidden layer of the speech recognition model.

[0115] According to one or more embodiments of this disclosure, Example 5 provides the method of Example 1, the method further comprising training the audio processing model by:

[0116] Acquire second audio data with the target timbre;

[0117] The second audio data is input into the acoustic feature extraction model to obtain the second acoustic feature corresponding to the second audio data;

[0118] A second training dataset is generated based on the second acoustic features and the second audio data;

[0119] Obtain the audio processing model and train the audio processing model based on the second training dataset.

[0120] According to one or more embodiments of this disclosure, Example 6 provides the method of Example 5, wherein the audio processing model includes: an encoder and a vocoder; wherein the encoder is configured to generate audio data having a target timbre based on an encoding feature corresponding to the second acoustic feature; and the vocoder is configured to generate audio data having a target timbre based on the encoding feature.

[0121] According to one or more embodiments of this disclosure, Example 7 provides the method of Example 6, wherein training the audio processing model includes:

[0122] From the hidden layers included in the audio processing model, at least two target hidden layers are determined;

[0123] The parameters of the at least two target hidden layers are shared.

[0124] According to one or more embodiments of this disclosure, Example 8 provides the method of Example 1, wherein the audio data to be processed is input into a pre-trained acoustic feature extraction model, and then further includes:

[0125] Delete the audio data to be processed.

[0126] According to one or more embodiments of this disclosure, Example 9 provides an audio processing apparatus, characterized in that it includes:

[0127] The acquisition module is configured to acquire audio data to be processed.

[0128] The extraction module is configured to input the audio data to be processed into a pre-trained acoustic feature extraction model to obtain the acoustic features to be processed corresponding to the audio data to be processed; the acoustic features to be processed include at least some of the pronunciation mode features of the audio data to be processed;

[0129] The processing module is configured to input the acoustic features to be processed into a pre-trained audio processing model to obtain processed audio data with the target timbre that corresponds to the audio data to be processed.

[0130] According to one or more embodiments of this disclosure, Example 10 provides the apparatus of Example 9, an extraction module further configured to: acquire first audio data; generate a first acoustic feature corresponding to the first audio data according to a predetermined speech recognition model; the first acoustic feature is output by any hidden layer near the output layer in the speech recognition model; generate a first training dataset according to the first audio data and the first acoustic feature; acquire an acoustic feature extraction model; the size of the acoustic feature extraction model is smaller than the size of the speech recognition model; and train the acoustic feature extraction model according to the first training dataset.

[0131] According to one or more embodiments of this disclosure, Example 11 provides an apparatus of Example 10, an extraction module specifically configured to input the first audio data into the speech recognition model and extract the output of a hidden layer in the speech recognition model that is immediately adjacent to the output layer as a first acoustic feature corresponding to the first audio data.

[0132] According to one or more embodiments of this disclosure, Example 12 provides the apparatus of Example 10, wherein the number of hidden layers included in the acoustic feature extraction model does not exceed one-fifth of the number of hidden layers included in the speech recognition model; and for any hidden layer of the acoustic feature extraction model, the number of neurons included in the hidden layer does not exceed one-quarter of the number of neurons included in any hidden layer of the speech recognition model.

[0133] According to one or more embodiments of this disclosure, Example 13 provides the apparatus of Example 9, a processing module further configured to acquire second audio data having a target timbre; input the second audio data into the acoustic feature extraction model to obtain a second acoustic feature corresponding to the second audio data; generate a second training dataset based on the second acoustic feature and the second audio data; acquire an audio processing model, and train the audio processing model based on the second training dataset.

[0134] According to one or more embodiments of this disclosure, Example 14 provides an apparatus of Example 13, the audio processing model comprising: an encoder and a vocoder; wherein the encoder is configured to generate audio data having a target timbre based on an encoding feature corresponding to the second acoustic feature; and the vocoder is configured to generate audio data having a target timbre based on the encoding feature.

[0135] According to one or more embodiments of this disclosure, Example 15 provides an apparatus of Example 13, a processing module specifically configured to determine at least two target hidden layers from the hidden layers included in the audio processing model; and to share parameters of the at least two target hidden layers.

[0136] According to one or more embodiments of this disclosure, Example 16 provides the apparatus of Example 9, a processing module further configured to delete the audio data to be processed after inputting the audio data to be processed into a pre-trained acoustic feature extraction model.

[0137] According to one or more embodiments of the present disclosure, Example 17 provides an electronic device including a memory, a processor, and a computer program stored on the memory and executable on the processor, wherein the processor, when executing the program, implements the method as described in any one of Examples 1 to 8.

[0138] According to one or more embodiments of the present disclosure, Example 18 provides a non-transitory computer-readable storage medium that stores computer instructions for causing a computer to perform the method as described in any one of Examples 1 to 8.

[0139] It should be noted that, unless otherwise defined, the technical or scientific terms used in the embodiments of this application should have the ordinary meaning understood by one of ordinary skill in the art to which this application pertains. The terms "first," "second," and similar terms used in the embodiments of this application do not indicate any order, quantity, or importance, but are merely used to distinguish different components. Terms such as "comprising" or "including" mean that the element or object preceding the word covers the elements or objects listed after the word and their equivalents, without excluding other elements or objects. Terms such as "connected" or "linked" are not limited to physical or mechanical connections, but can include electrical connections, whether direct or indirect. The article "a" or "an" preceding an element does not exclude the presence of multiple such elements.

[0140] Those skilled in the art should understand that the discussion of any of the above embodiments is merely exemplary and is not intended to imply that the scope of this application (including the claims) is limited to these examples; within the framework of this application, the technical features of the above embodiments or different embodiments can also be combined, the steps can be implemented in any order, and there are many other variations of different aspects of the embodiments of this application as described above, which are not provided in the details for the sake of brevity.

[0141] The embodiments of this application are intended to cover all such substitutions, modifications, and variations that fall within the broad scope of the appended claims. Therefore, any omissions, modifications, equivalent substitutions, improvements, etc., made within the spirit and principles of the embodiments of this application should be included within the protection scope of this application.

Claims

1. An audio processing method, characterized in that, include: Acquire the audio data to be processed; The audio data to be processed is input into a pre-trained acoustic feature extraction model to obtain the acoustic features to be processed corresponding to the audio data to be processed; the acoustic features to be processed include at least some of the pronunciation mode features of the audio data to be processed; the acoustic feature extraction model is obtained by reducing the number of hidden layers and the number of neurons in the hidden layers while keeping the overall structure of the speech recognition model unchanged; the training process of the acoustic feature model includes: acquiring first audio data; generating a first acoustic feature corresponding to the first audio data according to a predetermined speech recognition model; the first acoustic feature is output by any hidden layer near the output layer in the speech recognition model; generating a first training dataset according to the first audio data and the first acoustic feature; acquiring the acoustic feature extraction model; and training the acoustic feature extraction model according to the first training dataset; The acoustic features to be processed are input into a pre-trained audio processing model to obtain processed audio data with the target timbre that corresponds to the audio data to be processed.

2. The method according to claim 1, characterized in that, The step of generating the first acoustic feature corresponding to the first audio data according to the predetermined speech recognition model includes: The first audio data is input into the speech recognition model, and the output of a hidden layer adjacent to the output layer in the speech recognition model is extracted as the first acoustic feature corresponding to the first audio data.

3. The method according to claim 1, characterized in that, The number of hidden layers in the acoustic feature extraction model does not exceed one-fifth of the number of hidden layers in the speech recognition model; for any hidden layer of the acoustic feature extraction model, the number of neurons in that hidden layer does not exceed one-quarter of the number of neurons in any hidden layer of the speech recognition model.

4. The method according to claim 1, characterized in that, The method also includes training the audio processing model using the following method: Acquire second audio data with the target timbre; The second audio data is input into the acoustic feature extraction model to obtain the second acoustic feature corresponding to the second audio data; A second training dataset is generated based on the second acoustic features and the second audio data; Obtain the audio processing model and train the audio processing model based on the second training dataset.

5. The method according to claim 4, characterized in that, The audio processing model includes an encoder and a vocoder; wherein the encoder is configured to generate audio data with a target timbre based on the encoding features corresponding to the second acoustic feature; and the vocoder is configured to generate audio data with a target timbre based on the encoding features.

6. The method according to claim 5, characterized in that, Training the audio processing model includes: From the hidden layers included in the audio processing model, at least two target hidden layers are determined; The parameters of the at least two target hidden layers are shared.

7. The method according to claim 1, characterized in that, The step of inputting the audio data to be processed into a pre-trained acoustic feature extraction model further includes: Delete the audio data to be processed.

8. An audio processing apparatus, characterized in that, include: The acquisition module is configured to acquire audio data to be processed. An extraction module is configured to input the audio data to be processed into a pre-trained acoustic feature extraction model to obtain acoustic features to be processed corresponding to the audio data to be processed; the acoustic features to be processed include at least some of the pronunciation mode features of the audio data to be processed; the acoustic feature extraction model is obtained by reducing the number of hidden layers and the number of neurons in the hidden layers while keeping the overall structure of the speech recognition model unchanged; the process of training the acoustic feature model includes: acquiring first audio data; generating a first acoustic feature corresponding to the first audio data according to a predetermined speech recognition model; the first acoustic feature is output by any hidden layer near the output layer in the speech recognition model; generating a first training dataset according to the first audio data and the first acoustic feature; acquiring the acoustic feature extraction model; and training the acoustic feature extraction model according to the first training dataset. The processing module is configured to input the acoustic features to be processed into a pre-trained audio processing model to obtain processed audio data with the target timbre that corresponds to the audio data to be processed.

9. An electronic device comprising a memory, a processor, and a computer program stored in the memory and executable on the processor, characterized in that, When the processor executes the program, it implements the method as described in any one of claims 1 to 7.

10. A non-transitory computer-readable storage medium storing computer instructions, characterized in that, The computer instructions are used to cause the computer to perform the method as described in any one of claims 1 to 7.

Citation Information

Patent Citations

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

    CN114023342A