Real-time voice conversion method, device and electronic equipment
By acquiring and processing phonemes, audio details, and pitch variation features of streaming audio, and using a real-time speech conversion model to generate target audio, the problem of insufficient timbre conversion accuracy in existing technologies is solved, achieving higher model training accuracy and timbre conversion effect.
Patent Information
- Application Number
- CN202210864130.4
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2022-07-20
- Publication Date
- 2026-11-20
- Estimated Expiration
- 2042-07-20
AI Technical Summary
Existing real-time speech conversion models have poor timbre conversion accuracy because phonemes contain relatively little real-time audio information.
By acquiring the first user's streaming audio and the target timbre's identifier, a real-time speech conversion model is used to learn phonemes, audio details, and pitch variation features, generate the target audio, and play it. The real-time speech conversion model is trained based on the sample audio features of the sample streaming audio and the timbre features of the target timbre.
It improves the training accuracy and timbre conversion accuracy of the real-time speech conversion model, ensuring that the generated audio retains vocal details and pitch variations.
Smart Images

Figure CN117475984B_ABST
Abstract
Description
Technical Field
[0001] This disclosure relates to the field of audio processing technology, and in particular to a real-time speech conversion method, apparatus, and electronic device. Background Technology
[0002] Real-time audio conversion can transform the timbre of received audio into another timbre. It can be performed on real-time audio using a trained audio conversion model.
[0003] Currently, audio conversion models can be trained using phonemes from real-time audio (streaming audio). This allows the trained model to convert the timbre of real-time audio based on those phonemes. For example, by inputting phonemes from real-time speech and identifiers of the timbre to be converted into a speech conversion model, the model can output speech containing the desired timbre. However, phonemes contain limited information about the real-time audio, making it difficult for audio conversion models to accurately learn the audio information within the real-time audio, resulting in poor accuracy in timbre conversion of real-time speech. Summary of the Invention
[0004] This disclosure provides a real-time speech conversion method, apparatus, and electronic device to solve the technical problem of poor accuracy in real-time speech timbre conversion in the prior art.
[0005] In a first aspect, this disclosure provides a real-time speech conversion method, the method comprising:
[0006] Obtain the first audio and the identifier of the target timbre of the first user, wherein the first audio is processed in a streaming manner and the timbre of the first audio is different from the target timbre;
[0007] Based on the real-time speech conversion model, the first audio, and the identifier of the target timbre, the target audio is determined, and the timbre of the target audio is the target timbre. The real-time speech conversion model is trained based on the sample audio features of the sample streaming audio and the timbre features of the target timbre. The sample audio features indicate the phoneme features, audio detail features, and pitch variation features of the sample streaming audio.
[0008] Play the target audio.
[0009] Secondly, this disclosure provides a real-time speech conversion device, which includes an acquisition module, a first determination module, and a playback module, wherein:
[0010] The acquisition module is used to acquire the first audio and the identifier of the target timbre of the first user, wherein the first audio is processed in a streaming manner and the timbre of the first audio is different from the target timbre;
[0011] The first determining module is used to determine the target audio based on the real-time speech conversion model, the first audio, and the identifier of the target timbre. The timbre of the target audio is the target timbre. The real-time speech conversion model is trained based on the sample audio features of the sample streaming audio and the timbre features of the target timbre. The sample audio features indicate the phoneme features, audio detail features, and pitch variation features of the sample streaming audio.
[0012] The playback module is used to play the target audio.
[0013] Thirdly, embodiments of this disclosure provide an electronic device, including: a processor and a memory;
[0014] The memory stores computer-executed instructions;
[0015] The processor executes computer execution instructions stored in the memory, causing the at least one processor to perform the real-time speech conversion method described in the first aspect above and various possible aspects of the first aspect.
[0016] Fourthly, embodiments of this disclosure provide a computer-readable storage medium storing computer-executable instructions, which, when executed by a processor, implement the real-time speech conversion method described in the first aspect above and various possible aspects of the first aspect.
[0017] Fifthly, embodiments of this disclosure provide a computer program product, including a computer program that, when executed by a processor, implements the real-time speech conversion method described in the first aspect above and various possible aspects of the first aspect.
[0018] This disclosure provides a real-time speech conversion method, apparatus, and electronic device. It obtains a first user's first audio and a target timbre identifier. The first audio is processed in a streaming manner, and its timbre differs from the target timbre. Based on a real-time speech conversion model, the first audio, and the target timbre identifier, a target audio is determined, and its timbre is identified as the target timbre. The real-time speech conversion model is trained based on sample audio features from the sample streaming audio and the timbre features of the target timbre. The sample audio features indicate the phoneme features, audio detail features, and pitch variation features of the sample streaming audio. The target audio is then played. In this method, since the audio features include the phoneme features, audio detail features, and pitch variation features of the sample streaming audio, the real-time speech conversion model can learn more audio information from the sample streaming audio, thereby improving the accuracy and effectiveness of model training and enhancing the accuracy of real-time speech timbre conversion. Attached Figure Description
[0019] To more clearly illustrate the technical solutions in the embodiments of this disclosure or the prior art, the drawings used in the description of the embodiments or the prior art will be briefly introduced below. Obviously, the drawings described below are some embodiments of this disclosure. For those skilled in the art, other drawings can be obtained based on these drawings without creative effort.
[0020] Figure 1 This is a schematic diagram of an application scenario provided by an embodiment of the present disclosure;
[0021] Figure 2 A flowchart illustrating a real-time speech conversion method provided in an embodiment of this disclosure;
[0022] Figure 3 This is a schematic diagram illustrating a process for acquiring target audio according to an embodiment of the present disclosure;
[0023] Figure 4 A schematic diagram illustrating a method for obtaining a real-time speech conversion model provided in an embodiment of this disclosure;
[0024] Figure 5 A schematic diagram of a speech recognition model provided in an embodiment of this disclosure;
[0025] Figure 6 A schematic diagram illustrating a process for acquiring audio features according to an embodiment of this disclosure;
[0026] Figure 7 A schematic diagram illustrating the acquisition process of a real-time speech conversion model provided in an embodiment of this disclosure;
[0027] Figure 8 This is a schematic diagram of the structure of a real-time speech conversion device provided in an embodiment of the present disclosure;
[0028] Figure 9 A schematic diagram of another real-time speech conversion device provided in this disclosure embodiment; and,
[0029] Figure 10 This is a schematic diagram of the structure of an electronic device provided in an embodiment of this disclosure. Detailed Implementation
[0030] Exemplary embodiments will now be described in detail, examples of which are illustrated in the accompanying drawings. When the following description relates to the drawings, unless otherwise indicated, the same numerals in different drawings denote the same or similar elements. The embodiments described in the following exemplary embodiments do not represent all embodiments consistent with this disclosure. Rather, they are merely examples of apparatuses and methods consistent with some aspects of this disclosure as detailed in the appended claims.
[0031] For ease of understanding, the concepts involved in the embodiments of this disclosure will be explained below.
[0032] Electronic device: A device with wireless transceiver capabilities. Electronic devices can be deployed on land, including indoors or outdoors, handheld, wearable, or vehicle-mounted; they can also be deployed on water (such as on ships). These electronic devices can be mobile phones, tablets, computers with wireless transceiver capabilities, virtual reality (VR) electronic devices, augmented reality (AR) electronic devices, wireless terminals in industrial control, vehicle-mounted electronic devices, wireless terminals in self-driving vehicles, wireless electronic devices in remote medical care, wireless electronic devices in smart grids, wireless electronic devices in transportation safety, wireless electronic devices in smart cities, wireless electronic devices in smart homes, wearable electronic devices, etc. The electronic devices involved in the embodiments of this disclosure can also be referred to as terminals, user equipment (UE), access electronic devices, vehicle-mounted terminals, industrial control terminals, UE units, UE stations, mobile stations, mobile stations, remote stations, remote electronic devices, mobile devices, UE electronic devices, wireless communication devices, UE agents, or UE devices, etc. Electronic devices can be fixed or mobile.
[0033] Streaming audio: Audio transmitted via streaming technology. Streaming involves splitting multimedia files, such as video or audio, into multiple compressed packets using a preset compression method, and then transmitting these compressed packets to electronic devices in real-time or continuously via a server. For example, if an audio clip is 30 seconds long, the server can compress and process the 3-second clip each time it receives it (e.g., send, convert audio, etc.).
[0034] Non-streaming audio: Audio transmitted using non-streaming transmission technologies. For example, non-streaming audio is a complete audio file. For instance, when a server receives voice data, if the voice duration is 30 seconds, the server will generate an audio file associated with that 30-second voice data after fully receiving it, and then process that audio file (e.g., send it, change its timbre, etc.).
[0035] Spectrum: The spectrum of audio can be a spectrogram associated with the audio. For example, the spectrum of audio can be a Mel spectrogram. For instance, by obtaining the audio-associated spectrogram and inputting it into a Mel-scale filter bank, the Mel-scale filter bank can output the Mel spectrogram associated with that audio segment.
[0036] Phoneme: A phoneme is the smallest unit or the smallest segment of speech that makes up a syllable. For example, a phoneme can include vowels and consonants, and each pronunciation has an associated phoneme. For instance, after a server receives a piece of audio, it can determine all the phonemes associated with that piece of audio by analyzing its pronunciation.
[0037] Audio details: Audio details refer to the noise or sounds produced. For example, a user's speech may include the user's voice as well as the user's accent (e.g., breathing sounds, coughing sounds, etc.). Phonemes cannot describe the audio details in speech.
[0038] Pitch: Pitch refers to the highness or lowness of a sound. It is determined by the frequency and intensity of the sound. For example, the faster an object vibrates, the higher the pitch of the sound; the slower the object vibrates, the lower the pitch. Similarly, the higher the intensity of the sound, the higher the pitch, and the lower the intensity, the lower the pitch. Optionally, pitch variation features can indicate the rhythm of an audio file. For example, pitch variation features can indicate the location of accents, the speed of pitch change, and other information about pitch.
[0039] Timbre: Timbre refers to the different characteristics of the waveforms associated with different sounds. For example, different objects vibrate with different characteristics; musical instruments with different structures, such as pianos and violins, vibrate with different characteristics, and therefore, their timbres are also different. Similarly, the timbres of the voices produced by different people are also different.
[0040] In related technologies, audio conversion models can acquire phoneme features of audio in real time and convert the timbre of the audio in real time using these phoneme features. Therefore, the training samples of current audio conversion models are all phoneme features of audio. For example, the training samples of an audio conversion model can include the phoneme features of sample audio and the Mel spectrogram of the sample audio with the replaced timbre associated with each sample audio. The audio conversion model is trained using these training samples so that it can replace the timbre of the audio using phoneme features. However, in real-time audio conversion scenarios, phonemes contain relatively little information about the real-time audio, making it difficult for the audio conversion model to accurately learn the audio information in the real-time audio. For example, the speech with the replaced timbre generated by the audio conversion model will not include the accent or pitch of the original speech. This results in poor training accuracy of the model, and consequently, poor accuracy in real-time speech timbre conversion.
[0041] To address the problems in related technologies, this disclosure provides a real-time speech conversion method. The method involves obtaining a first user's first audio and a target timbre identifier. The first audio is processed in a streaming manner, and the timbre of the first audio differs from the target timbre. Audio features associated with the first audio are obtained, indicating the phoneme features, audio detail features, and pitch variation features of the first audio. Based on the target timbre identifier, the timbre features of the target timbre are obtained. Based on a real-time speech conversion model, the audio features, and the timbre features, a first spectrogram associated with the first audio is obtained. The timbre indicated by the first spectrogram is the target timbre. The real-time speech conversion model is trained based on sample audio features of sample streaming audio and the timbre features of the target timbre. The sample audio features indicate the phoneme features, audio detail features, and pitch variation features of the sample streaming audio. Based on the first spectrogram, the target audio is determined and played. In the above method, since the audio features of the sample streaming audio include not only phoneme features, but also more fine-grained audio detail features and pitch variation features, the real-time speech conversion model can learn more vocal details and vocal rhythm, resulting in higher model training effect and model training accuracy, thereby improving the timbre conversion effect and timbre conversion accuracy of real-time speech.
[0042] Below, in conjunction with Figure 1 The application scenarios of this disclosure are explained.
[0043] Figure 1 This is a schematic diagram illustrating an application scenario provided by an embodiment of this disclosure. Please refer to [link / reference]. Figure 1 This includes servers and electronic devices. The electronic devices can send real-time speech with timbre A to the server in real time. The server can acquire the audio features of the real-time speech and process these features along with the timbre features of timbre B using a real-time speech conversion model to obtain a Mel spectrogram of the real-time speech, where the Mel spectrogram indicates timbre B. The server then uses a vocoder to reconstruct the real-time speech from the Mel spectrogram, obtaining real-time speech with timbre B, and sends this timbre B real-time speech to the electronic devices. In this way, because the real-time speech conversion model can learn more vocal details and prosody, the real-time speech generated by the server after timbre replacement also includes the vocal details and prosody of the input real-time speech, thus improving the audio timbre conversion effect. It should be noted that... Figure 1 This disclosure is merely an example illustrating the application scenarios of the embodiments. The embodiments of this disclosure also include other scenarios. For example, the real-time voice timbre conversion process can also be performed in an electronic device without interaction with a server. The embodiments of this disclosure do not limit the application scenarios.
[0044] The technical solutions of this disclosure and how they solve the aforementioned technical problems will be described in detail below with specific embodiments. These specific embodiments can be combined with each other, and the same or similar concepts or processes may not be repeated in some embodiments. The embodiments of this disclosure will now be described with reference to the accompanying drawings.
[0045] Figure 2 This is a flowchart illustrating a real-time speech conversion method provided in an embodiment of this disclosure. Please refer to [link / reference]. Figure 2 The method may include:
[0046] S201, Obtain the first audio and target timbre identifier of the first user.
[0047] The execution subject of this disclosure can be an electronic device or a real-time speech conversion device installed in an electronic device. The real-time speech conversion device can be implemented through software, or it can be implemented through a combination of software and hardware.
[0048] The first audio file can be real-time streaming audio, processed in a streaming manner. For example, in a real-time timbre conversion scenario, the electronic device can acquire the user's voice in real time and process it using a streaming method. Optionally, the timbre of the first audio file may differ from the target timbre.
[0049] Optionally, the electronic device can acquire the first user's first audio and the target silver identifier according to the following feasible implementation: displaying a tone conversion page. Optionally, the tone conversion page includes a target tone control and an audio acquisition control. In response to a trigger operation on the target tone control, the identifier of the target tone is determined. For example, the tone conversion page includes controls for tone A, tone B, and tone C; when the user clicks the control for tone A, the identifier of the target tone is the identifier of tone A.
[0050] In response to a triggering operation on the audio acquisition control, the first audio from the first user is acquired. For example, when a user clicks the audio acquisition control on the tone conversion page, the electronic device can acquire the first user's voice in real time and obtain the first audio.
[0051] S202. Based on the real-time speech conversion model, the first audio, and the identifier of the target timbre, determine the target audio.
[0052] Optionally, the timbre of the target audio is the target timbre. For example, if the timbre of the streaming audio acquired by the electronic device is timbre A and the target timbre is timbre B, then the audio content of the target audio generated by the electronic device is the same as the audio content of the streaming audio, and the timbre of the target audio is timbre B.
[0053] Optionally, the target audio can be determined by acquiring audio features associated with the first audio. Optionally, the audio features indicate phoneme features, audio detail features, and pitch variation features of the streaming audio. It should be noted that the process of acquiring the audio features associated with the first audio is described in step S401 below.
[0054] Based on a real-time speech conversion model, audio features, and timbre features, a first spectrogram associated with the first audio is obtained. The real-time speech conversion model is trained based on sample audio features from the sample streaming audio and the timbre features of the target timbre. The sample audio features indicate the phoneme features, audio detail features, and pitch variation features of the sample streaming audio. For example, after the real-time speech conversion model is trained, inputting the audio features of the streaming audio and the timbre features of the target timbre into the real-time speech conversion model will allow it to output a first spectrogram associated with the audio features.
[0055] Optionally, the timbre indicated by the first spectrogram is the target timbre. For example, the audio content indicated by the first spectrogram is the same as the audio content of the streaming audio, and the timbre indicated by the first spectrogram is the same as the target timbre.
[0056] Based on the first spectrogram, the target audio is determined. Optionally, the first spectrogram can be processed by a vocoder to obtain the target audio. For example, the vocoder can be a pre-trained streaming vocoder, which can restore the first spectrogram generated by the real-time speech conversion model to a waveform, thereby obtaining the target audio.
[0057] Below, in conjunction with Figure 3 The process of acquiring the target audio is explained.
[0058] Figure 3 This is a schematic diagram illustrating a process for acquiring target audio according to an embodiment of this disclosure. Please refer to [link / reference]. Figure 3 The audio stream includes three audio streams: Streaming Audio A, Streaming Audio B, and Streaming Audio C. Streaming Audio A and Streaming Audio B are past audio streams, while Streaming Audio C is the currently acquired real-time audio stream, and its timbre is that of timbre A. Streaming Audio C is input into the encoder, which processes it to obtain its audio features. These features indicate the phoneme characteristics, audio detail characteristics, and pitch variation characteristics of Streaming Audio C.
[0059] Please see Figure 3The encoder inputs the audio features of streaming audio C into the real-time speech conversion model. The real-time speech conversion model determines the target timbre as timbre B. The model processes the audio features to obtain a Mel spectrogram associated with streaming audio C, where the timbre indicated by the Mel spectrogram is timbre B. The real-time speech conversion model sends the Mel spectrogram to the vocoder, which reconstructs the Mel spectrogram to obtain streaming audio C with timbre B (the same audio content as streaming audio C, but with a different timbre). Thus, since the audio features include phoneme features, audio detail features, and pitch variation features of streaming audio C, the streaming audio C with timbre B after timbre replacement can also retain the vocal details and tonal rhythm of the original streaming audio C, thereby improving the timbre conversion effect.
[0060] S203, Play the target audio.
[0061] This disclosure provides a real-time speech conversion method. It acquires streaming audio and its associated audio features, as well as the timbre features of a target timbre. Based on a real-time speech conversion model, the audio features, and the timbre features, a first spectrogram associated with the streaming audio is obtained. The timbre indicated by the first spectrogram is the target timbre. The real-time speech conversion model is trained based on sample audio features of the sample streaming audio and the timbre features of the target timbre. The sample audio features indicate the phoneme features, audio detail features, and pitch variation features of the sample streaming audio. Based on the first spectrogram, the target audio is determined and played. In this method, since the spectrogram output by the real-time speech conversion model includes vocal details and pitch variations, in a real-time timbre conversion scenario, the real-time speech conversion model can output a Mel spectrogram associated with the streaming audio in real time. The Mel spectrogram is then reconstructed to obtain audio with replaced timbre. This audio can include vocal details and pitch variations of the input audio, thereby improving the accuracy and effect of timbre conversion.
[0062] exist Figure 2 Based on the illustrated embodiment, the above real-time speech conversion method further includes a process for obtaining a real-time speech conversion model. The following will describe this process in conjunction with... Figure 4 The process of acquiring the real-time speech conversion model is explained.
[0063] Figure 4 This diagram illustrates a method for obtaining a real-time speech conversion model according to an embodiment of this disclosure. Please refer to [link / reference]. Figure 4 The method process includes:
[0064] S401. Obtain the audio features of the sample streaming audio and the timbre features of the target timbre.
[0065] Sample streaming audio can be an audio file containing multiple audio segments. For example, sample streaming audio can be a compressed package containing multiple audio segments. In practical applications, electronic devices can divide the audio received in real time into audio files of a preset length to obtain streaming audio.
[0066] Optionally, the electronic device can process multiple audio files according to a preset streaming processing method to obtain sample streaming audio. For example, the electronic device can obtain multiple complete audio files from a database and split the multiple complete audio files into multiple sample streaming audio files according to a duration of 3 seconds. It should be noted that the electronic device can also directly obtain multiple sample streaming audio files sent by other devices, and this embodiment of the present disclosure does not limit this.
[0067] Optionally, the audio features indicate the phoneme features, audio detail features, and pitch variation features of the sample streaming audio. For example, the audio features of the sample streaming audio may include phoneme information, audio detail information, and pitch variation information of the sample streaming audio.
[0068] Optionally, the electronic device can acquire the audio features of the sample streaming audio through the following feasible implementation: determining the audio features of the sample streaming audio based on a subset of the convolutional layers in a speech recognition model. Optionally, the speech recognition model is used to convert speech information into text information. For example, the speech recognition model includes Automatic Speech Recognition (ASR) technology, which can recognize speech information. For instance, if an audio segment is input into an ASR model, the ASR model can output the text associated with the speech in that audio segment.
[0069] Optionally, the speech recognition model includes multiple convolutional layers, and the model parameters are the convolutional parameters of these layers. For example, if the speech recognition model includes 18 convolutional layers, the model parameters are the convolutional parameters of those 18 layers. It should be noted that the speech recognition model is a pre-trained model. This model can convert audio into text. In practical applications, the output of the penultimate convolutional layer is the phoneme feature associated with each phoneme of the audio. By setting the last layer to a fully connected layer, the posterior probability of each phoneme associated with the audio can be obtained.
[0070] Below, in conjunction with Figure 5 The speech recognition model will be explained.
[0071] Figure 5 This is a schematic diagram of a speech recognition model provided in an embodiment of this disclosure. Please refer to [link / reference]. Figure 5This includes a speech recognition model. The speech recognition model comprises 18 convolutional layers. When the audio "The weather is nice today" is input into the speech recognition model, the model processes the input audio through the 18 convolutional layers and outputs the text "The weather is nice today". The parameters of each convolutional layer in the speech recognition model (e.g., kernel size, stride) are adjusted during the model's training; in actual use, the parameters of each convolutional layer are fixed values.
[0072] Optionally, some convolutional layers may be the first M convolutional layers out of a set of convolutional layers, where M is an integer greater than or equal to 1, and M is less than the number of convolutional layers in the speech recognition model. For example, if the speech recognition model includes 18 convolutional layers and M is 10, the electronic device can obtain the parameters of the first 10 convolutional layers in the speech recognition model; if the speech recognition model includes 20 convolutional layers and M is 12, the electronic device can obtain the parameters of the first 12 convolutional layers in the speech recognition model.
[0073] Below, we will explain how to obtain partial convolutional layers using specific examples.
[0074] A portion of the convolutional layers in the content encoder of a speech recognition model pre-trained on a large scale is obtained, and shallow bottleneck features are acquired through these partial convolutional layers. For example, in this embodiment, a pre-trained content encoder based on 18 convolutional layers is used. For an input audio chunk of length T, a short-time Fourier transform and a Mel filter are used to convert it into a Mel spectrum of shape [T / 240, 80], which is then input into the content encoder. Each layer of the content encoder outputs features of shape [T / 960, 768], and the last layer is connected to a fully connected network for phoneme classification to obtain a phoneme posterior probability distribution of shape [T / 960, D], where D is the number of phoneme categories.
[0075] In this embodiment, audio features output from the intermediate layer of the content encoder are used as input to the predictive conversion model. Since the audio features output from the intermediate layer include not only finer-grained vocal details than phonemes, but also more pitch and prosodic information, the training effect of the real-time speech conversion model can be improved.
[0076] Based on a subset of convolutional layers in a speech recognition model, the audio features of a sample streaming audio are determined. Specifically, the sample streaming audio is processed by convolutional operations using the parameters of a subset of convolutional layers to obtain the corresponding audio features. For example, if the speech recognition model includes 18 convolutional layers and M is 10, the electronic device can process the sample streaming audio using the first 10 convolutional layers of the speech recognition model to obtain the corresponding audio features. For instance, if the speech recognition model includes 18 convolutional layers and M is 10, the sample streaming audio is processed by the speech recognition model, and the feature map output by the 10th convolutional layer (shallow bottleneck feature) is determined as the audio feature corresponding to the sample streaming audio.
[0077] Below, in conjunction with Figure 6 The process of acquiring audio features from sample streaming audio is explained.
[0078] Figure 6 This is a schematic diagram illustrating a process for acquiring audio features according to an embodiment of this disclosure. Please refer to [link / reference]. Figure 6 This includes a speech recognition model. The speech recognition model comprises eight convolutional layers, each with fixed convolutional parameters. The first four convolutional layers of the speech recognition model are extracted to form an encoder, which includes convolutional layers 1, 2, 3, and 4. The parameters of each convolutional layer are the same as those in the speech recognition model. Sample streaming audio is input into the encoder, which processes the sample streaming audio to obtain a feature map. This feature map includes phoneme features, audio detail features, and pitch variation features of the sample streaming audio.
[0079] Optionally, the target timbre can be a timbre associated with the requirement. For example, if the real-time speech conversion model needs to generate speech with timbre A, then the target timbre is timbre A; if the real-time speech conversion model needs to generate speech with timbre B, then the target timbre is timbre B. For example, by processing the audio features of sample streaming audio through the real-time speech conversion model, the model can replace the timbre of the sample streaming audio with the target timbre and generate an associated Mel spectrogram.
[0080] S402. The audio features and timbre features are processed by a real-time speech conversion model to obtain the predicted spectrogram of the sample streaming audio.
[0081] Optionally, the real-time speech conversion model is used to convert the timbre of the sample streaming audio. For example, if the timbre of the sample streaming audio is the voice of user A, the real-time speech conversion model can replace the timbre of the sample streaming audio with the voice of user B. Optionally, the predicted spectrogram can be a Melp plot. For example, the real-time speech conversion model processes the audio features of the sample streaming audio and the timbre features of the target timbre to obtain a Melp plot of the sample streaming audio after timbre conversion.
[0082] S403. Obtain the target spectrogram of the sample streaming audio.
[0083] Optionally, the timbre indicated by the target spectrogram is the target timbre. For example, if the timbre indicated by the predicted spectrogram generated by the real-time speech conversion model is timbre A, then the timbre indicated by the target spectrogram is also timbre A; if the timbre indicated by the predicted spectrogram is timbre B, then the timbre indicated by the target spectrogram is also timbre B.
[0084] Optionally, the electronic device can obtain the target spectrogram of the sample streaming audio through a trained timbre conversion model. For example, the sample streaming audio can be processed by a trained timbre conversion model (a model that converts the timbre of the audio into the target timbre) to obtain the target spectrogram of the sample streaming audio.
[0085] Optionally, the electronic device can obtain the target spectrogram associated with the sample streaming audio through the following feasible implementation: processing the sample streaming audio using a non-streaming timbre conversion model to obtain the target spectrogram associated with the sample streaming audio. The non-streaming timbre conversion model is learned from multiple sets of samples, including the sample non-streaming audio, the timbre features of the target timbre, and the sample spectrogram associated with the sample non-streaming audio and the timbre features. The timbre indicated by the sample spectrogram is the target timbre. For example, for sample non-streaming audio 1 and the timbre features of the target timbre, the sample spectrogram associated with the timbre features of sample non-streaming audio 1 and the target timbre is obtained. Figure 1 A set of samples was obtained, which included sample non-stream audio 1, the timbre characteristics of the target timbre, and the sample spectrum. Figure 1 Using this method, multiple sets of samples can be obtained. For example, multiple sets of samples can be shown in Table 1:
[0086] Table 1
[0087] Multiple samples Sample non-streaming audio Tonal characteristics Sample spectrum First group of samples Sample non-streaming audio 1 Tonal characteristics Sample spectrum Figure 1 Second group of samples Sample non-streaming audio 2 Tonal characteristics Sample spectrum Figure 2 Third group of samples Sample non-streaming audio 3 Tonal characteristics Sample spectrum Figure 3 …… …… …… ……
[0088] It should be noted that Table 1 is only an example to illustrate multiple sets of samples and is not a limitation on multiple sets of samples. The timbre features in Table 1 can also be the timbre features of other target timbres. This disclosure does not limit this.
[0089] For example, if the sample streaming audio in the input non-streaming timbre conversion model is the same as sample non-streaming audio 1, then the target spectrogram associated with the sample streaming audio output by the non-streaming timbre conversion model is the sample spectrum. Figure 1 If the sample streaming audio in the input non-streaming timbre conversion model is the same as sample non-streaming audio 2, then the target spectrogram associated with the sample streaming audio output by the non-streaming timbre conversion model is the sample spectrum. Figure 2 If the sample streaming audio in the input non-streaming timbre conversion model is the same as sample non-streaming audio 3, then the target spectrogram associated with the sample streaming audio output by the non-streaming timbre conversion model is the sample spectrum. Figure 3 .
[0090] Thus, since the training samples in the non-streaming timbre conversion model are non-streaming audio, the receptive field of the non-streaming timbre conversion model is larger (because non-streaming audio does not require real-time conversion and can have a longer delay, thus having a larger receptive field). The non-streaming timbre conversion model can learn more vocal details and pitch variations from non-streaming audio, so that the output spectrogram of the non-streaming timbre conversion model includes vocal details and pitch variations from the input audio, thereby improving the accuracy of the target spectrogram.
[0091] It should be noted that since electronic devices obtain audio features (shallow bottleneck features) of sample streaming audio through some convolutional layers in the speech recognition model, the timbre features of the original audio will still remain in the audio features. In this embodiment, the non-streaming timbre conversion model can be the teacher model of the real-time speech conversion model. When training the real-time speech conversion model, the sample streaming audio is processed through the non-streaming timbre conversion model, thereby obtaining the labels (target spectrograms) in the training samples of the real-time speech conversion model. Since the non-streaming timbre conversion model is trained through non-streaming audio, the labels will also include vocal details and pitch changes, thereby improving the label accuracy of the real-time speech conversion model and improving the training accuracy and training effect of the real-time speech conversion model.
[0092] S404. Update the real-time speech conversion model based on the predicted spectrogram and the target spectrogram.
[0093] Electronic devices can update real-time speech conversion models using the following feasible implementation: Based on the predicted and target spectrograms, determine the prediction error of the real-time speech conversion model; and update the model parameters based on the prediction error. For example, by using the predicted and target spectrograms, the difference between the reconstructed predicted spectrogram and the target spectrogram can be determined. This difference can then be used to adjust the model parameters so that the predicted spectrogram output by the real-time speech conversion model is the same as or similar to the target spectrogram, thereby completing the training of the real-time speech conversion model.
[0094] This disclosure provides a real-time speech conversion method. The method processes sample streaming audio using the model parameters of the first M convolutional layers in a speech recognition model to obtain audio features corresponding to the sample streaming audio, acquires the timbre features of the target timbre, and processes the audio features and timbre features using a real-time speech conversion model to obtain a predicted spectrogram of the sample streaming audio. A pre-trained non-streaming timbre conversion model is then used to process the sample streaming audio to obtain a target spectrogram of the sample streaming audio. The non-streaming timbre conversion model is a model trained on non-streaming audio. Based on the predicted spectrogram and the target spectrogram, the model parameters of the real-time speech conversion model are updated. In the above method, since the model parameters of the first M convolutional layers in the speech recognition model are relatively shallowly convolved, the audio features of the sample streaming audio not only include phoneme features, but also finer-grained vocal features and pitch variation features. This allows the model to learn more vocal details and rhythm, improving the model training effect. Furthermore, since the non-streaming timbre conversion model is a model trained on non-streaming audio, it can include vocal details and pitch variations. The accuracy of the label (target spectrogram) of the real-time speech conversion model obtained by processing the sample streaming audio through the non-streaming timbre conversion model is high, thereby improving the accuracy of the real-time speech conversion model training.
[0095] Based on any of the above embodiments, the following, in conjunction with Figure 7 The process of acquiring the above real-time speech conversion model will be explained.
[0096] Figure 7 This diagram illustrates the process of acquiring a real-time speech conversion model according to an embodiment of this disclosure. Please refer to [link / reference]. Figure 7 This includes: sample streaming audio, a real-time speech conversion model, and a non-streaming timbre conversion model. Audio features associated with the sample streaming audio and timbre features of the target timbre are obtained and input into the real-time speech conversion model. The real-time speech conversion model processes the audio features and timbre features to obtain a predicted spectrogram, where the timbre indicated by the predicted spectrogram is the target timbre.
[0097] Please see Figure 7 A sample streaming audio and timbre features are input into a non-streaming timbre conversion model. The model processes the sample streaming audio to obtain a target spectrogram. The timbre indicated by the target spectrogram is the target timbre. The prediction error of real-time speech conversion is obtained by comparing the prediction spectrogram and the target spectrogram, and the model parameters of the real-time speech conversion model are updated based on the prediction error. Since the non-streaming timbre conversion model is trained on non-streaming audio, the target spectrogram output by the model can include vocal details and pitch variation features from the sample streaming audio. Using the target spectrogram as a label for the sample streaming audio can improve the accuracy and effectiveness of training the real-time speech conversion model.
[0098] Figure 8 This is a schematic diagram of a real-time speech conversion device provided in an embodiment of this disclosure. Please refer to... Figure 8 The real-time speech conversion device 80 includes an acquisition module 81, a first determination module 82, and a playback module 83, wherein:
[0099] The acquisition module 81 is used to acquire the first audio and the identifier of the target timbre of the first user, wherein the first audio is processed in a streaming manner and the timbre of the first audio is different from the target timbre;
[0100] The first determining module 82 is used to determine the target audio based on the real-time speech conversion model, the first audio, and the identifier of the target timbre. The timbre of the target audio is the target timbre. The real-time speech conversion model is trained based on the sample audio features of the sample streaming audio and the timbre features of the target timbre. The sample audio features indicate the phoneme features, audio detail features, and pitch variation features of the sample streaming audio.
[0101] The playback module 83 is used to play the target audio.
[0102] In one possible implementation, the first determining module 82 is specifically used for:
[0103] Obtain the audio features associated with the first audio, wherein the audio features indicate the phoneme features, audio detail features, and pitch variation features of the first audio;
[0104] Based on the identifier of the target timbre, the timbre characteristics of the target timbre are obtained;
[0105] Based on the real-time speech conversion model, the audio features, and the timbre features, a first spectrogram associated with the first audio is obtained, and the timbre indicated by the first spectrogram is the target timbre;
[0106] The target audio is determined based on the first spectrogram.
[0107] In one possible implementation, the acquisition module 81 is specifically used for:
[0108] Display a timbre conversion page, which includes a target timbre control and an audio acquisition control;
[0109] In response to a trigger operation on the target timbre control, the identifier of the target timbre is determined;
[0110] In response to a trigger operation on the audio acquisition control, the first audio of the first user is acquired.
[0111] The real-time speech conversion device provided in this embodiment can be used to execute the technical solutions of the above method embodiments. Its implementation principle and technical effect are similar, and will not be described again here.
[0112] Figure 9 This is a schematic diagram of another real-time speech conversion device provided in an embodiment of this disclosure. Figure 8 Based on the illustrated embodiments, please refer to Figure 9 The real-time speech conversion device 80 further includes a second determining module 84, which is used for:
[0113] Acquire the audio features of the sample streaming audio and the timbre features of the target timbre, wherein the audio features indicate the phoneme features, audio detail features, and pitch variation features of the sample streaming audio;
[0114] The audio features and timbre features are processed by a real-time speech conversion model to obtain a predicted spectrogram of the sample streaming audio.
[0115] Obtain the target spectrogram of the sample streaming audio, wherein the timbre indicated by the target spectrogram is the target timbre;
[0116] The real-time speech conversion model is updated based on the predicted spectrogram and the target spectrogram.
[0117] In one possible implementation, the second determining module 84 is specifically used for:
[0118] Based on a portion of the multiple convolutional layers in a speech recognition model, the audio features of the sample streaming audio are determined, and the speech recognition model is used to convert speech information into text information.
[0119] In one possible implementation, the partial convolutional layers are the first M convolutional layers among the plurality of convolutional layers, where M is an integer greater than or equal to 1, and M is less than the number of convolutional layers in the speech recognition model.
[0120] In one possible implementation, the second determining module 84 is specifically used for:
[0121] The sample streaming audio is processed using a non-streaming timbre conversion model to obtain the target spectrogram of the sample streaming audio.
[0122] The non-streaming timbre conversion model is obtained by learning from multiple sets of samples, including sample non-streaming audio, timbre features of the target timbre, sample non-streaming audio, and a sample spectrogram associated with the timbre features. The timbre indicated by the sample spectrogram is the target timbre.
[0123] In one possible implementation, the second determining module 84 is specifically used for:
[0124] The prediction error of the real-time speech conversion model is determined based on the predicted spectrogram and the target spectrogram.
[0125] The real-time speech conversion model is updated based on the prediction error.
[0126] The real-time speech conversion device provided in this embodiment can be used to execute the technical solutions of the above method embodiments. Its implementation principle and technical effect are similar, and will not be described again here.
[0127] Figure 10 This is a schematic diagram of the structure of an electronic device provided in an embodiment of this disclosure. Please refer to [link / reference]. Figure 10 The diagram illustrates a structural schematic of an electronic device 1000 suitable for implementing embodiments of the present disclosure. The electronic device 1000 can be a terminal device or an electronic device. The terminal device can include, but is not limited to, mobile terminals such as mobile phones, laptops, digital radio receivers, personal digital assistants (PDAs), portable Android devices (PADs), portable media players (PMPs), and in-vehicle terminals (e.g., in-vehicle navigation terminals), as well as fixed terminals such as digital TVs and desktop computers. Figure 10 The electronic device shown is merely an example and should not be construed as limiting the functionality and scope of the embodiments disclosed herein.
[0128] like Figure 10As shown, the electronic device 1000 may include a processing unit (e.g., a central processing unit, a graphics processing unit, etc.) 1001, which can perform various appropriate actions and processes according to a program stored in a read-only memory (ROM) 1002 or a program loaded from a storage device 1008 into a random access memory (RAM) 1003. The RAM 1003 also stores various programs and data required for the operation of the electronic device 1000. The processing unit 1001, ROM 1002, and RAM 1003 are interconnected via a bus 1004. An input / output (I / O) interface 1005 is also connected to the bus 1004.
[0129] Typically, the following devices can be connected to the I / O interface 1005: input devices 1006 including, for example, a touchscreen, touchpad, keyboard, mouse, camera, microphone, accelerometer, gyroscope, etc.; output devices 1007 including, for example, a liquid crystal display (LCD), speaker, vibrator, etc.; storage devices 1008 including, for example, magnetic tape, hard disk, etc.; and communication devices 1009. Communication device 1009 allows electronic device 1000 to exchange data via wireless or wired communication with other devices. Although Figure 10 An electronic device 1000 with various devices is shown; however, it should be understood that it is not required to implement or possess all of the devices shown. More or fewer devices may be implemented or possessed alternatively.
[0130] In particular, according to embodiments of this disclosure, the processes described above with reference to the flowcharts can be implemented as computer software programs. For example, embodiments of this disclosure include a computer program product comprising a computer program carried on a computer-readable medium, the computer program containing program code for performing the methods shown in the flowcharts. In such embodiments, the computer program can be downloaded and installed from a network via communication device 1009, or installed from storage device 1008, or installed from ROM 1002. When the computer program is executed by processing device 1001, it performs the functions defined in the methods of embodiments of this disclosure.
[0131] It should be noted that the computer-readable medium described in this disclosure can be a computer-readable signal medium or a computer-readable storage medium, or any combination thereof. A computer-readable storage medium can be, for example,—but not limited to—an electrical, magnetic, optical, electromagnetic, infrared, or semiconductor system, apparatus, or device, or any combination thereof. More specific examples of a computer-readable storage medium may include, but are not limited to: an electrical connection having one or more wires, a portable computer disk, a hard disk, random access memory (RAM), read-only memory (ROM), erasable programmable read-only memory (EPROM or flash memory), optical fiber, portable compact disk read-only memory (CD-ROM), optical storage device, magnetic storage device, or any suitable combination thereof. In this disclosure, a computer-readable storage medium can be any tangible medium containing or storing a program that can be used by or in connection with an instruction execution system, apparatus, or device. In this disclosure, a computer-readable signal medium can include a data signal propagated in baseband or as part of a carrier wave, carrying computer-readable program code. Such propagated data signals can take various forms, including but not limited to electromagnetic signals, optical signals, or any suitable combination thereof. A computer-readable signal medium can be any computer-readable medium other than a computer-readable storage medium, which can send, propagate, or transmit a program for use by or in connection with an instruction execution system, apparatus, or device. The program code contained on the computer-readable medium can be transmitted using any suitable medium, including but not limited to: wires, optical fibers, RF (radio frequency), etc., or any suitable combination thereof.
[0132] The aforementioned computer-readable medium may be included in the aforementioned electronic device; or it may exist independently and not assembled into the electronic device.
[0133] The aforementioned computer-readable medium carries one or more programs, which, when executed by the electronic device, cause the electronic device to perform the methods shown in the above embodiments.
[0134] Computer program code for performing the operations of this disclosure can be written in one or more programming languages or a combination thereof, including object-oriented programming languages such as Java, Smalltalk, and C++, and conventional procedural programming languages such as the "C" language or similar programming languages. The program code can be executed entirely on the user's computer, partially on the user's computer, as a standalone software package, partially on the user's computer and partially on a remote computer, or entirely on a remote computer or server. In cases involving remote computers, the remote computer can be connected to the user's computer via any type of network—including a Local Area Network (LAN) or a Wide Area Network (WAN)—or can be connected to an external computer (e.g., via the Internet using an Internet service provider).
[0135] The flowcharts and block diagrams in the accompanying drawings illustrate the architecture, functionality, and operation of possible implementations of systems, methods, and computer program products according to various embodiments of this disclosure. In this regard, each block in a flowchart or block diagram may represent a module, segment, or portion of code containing one or more executable instructions for implementing a specified logical function. It should also be noted that in some alternative implementations, the functions indicated in the blocks may occur in a different order than those indicated in the drawings. For example, two consecutively indicated blocks may actually be executed substantially in parallel, and they may sometimes be executed in reverse order, depending on the functions involved. It should also be noted that each block in the block diagrams and / or flowcharts, and combinations of blocks in the block diagrams and / or flowcharts, can be implemented using a dedicated hardware-based system that performs the specified function or operation, or using a combination of dedicated hardware and computer instructions.
[0136] The units described in the embodiments of this disclosure can be implemented in software or in hardware. The name of a unit does not necessarily limit the unit itself; for example, the first acquisition unit can also be described as "a unit that acquires at least two Internet Protocol addresses".
[0137] The functions described above in this document can be performed, at least in part, by one or more hardware logic components. For example, exemplary types of hardware logic components that can be used, without limitation, include: Field Programmable Gate Arrays (FPGAs), Application-Specific Integrated Circuits (ASICs), Application Standard Products (ASSPs), System-on-Chip (SoCs), Complex Programmable Logic Devices (CPLDs), and so on.
[0138] In the context of this disclosure, a machine-readable medium can be a tangible medium that may contain or store a program for use by or in conjunction with an instruction execution system, apparatus, or device. A machine-readable medium can be a machine-readable signal medium or a machine-readable storage medium. A machine-readable medium can be, but is not limited to, electronic, magnetic, optical, electromagnetic, infrared, or semiconductor systems, apparatus, or devices, or any suitable combination of the foregoing. More specific examples of machine-readable storage media include electrical connections based on one or more wires, portable computer disks, hard disks, random access memory (RAM), read-only memory (ROM), erasable programmable read-only memory (EPROM or flash memory), optical fiber, portable compact disk read-only memory (CD-ROM), optical storage devices, magnetic storage devices, or any suitable combination of the foregoing.
[0139] It should be noted that the terms "a" and "a plurality of" used in this disclosure are illustrative rather than restrictive, and those skilled in the art should understand that, unless otherwise expressly indicated in the context, they should be understood as "one or more".
[0140] The names of messages or information exchanged between multiple devices in the embodiments of this disclosure are for illustrative purposes only and are not intended to limit the scope of such messages or information.
[0141] It is understood that before using the technical solutions disclosed in the various embodiments of this disclosure, users should be informed of the types, scope of use, and usage scenarios of the personal information involved in this disclosure in an appropriate manner in accordance with relevant laws and regulations, and user authorization should be obtained.
[0142] 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 disclosed technical solution, based on the prompt message.
[0143] 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.
[0144] 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 disclosure. Other methods that comply with relevant laws and regulations may also be applied to the implementation of this disclosure.
[0145] It is understood that the data involved in this technical solution (including but not limited to the data itself, its acquisition, or its use) shall comply with the requirements of relevant laws, regulations, and provisions. Data may include information, parameters, and messages, such as flow control instructions.
[0146] The above description is merely a preferred embodiment of this disclosure and an explanation of the technical principles employed. Those skilled in the art should understand that the scope of this disclosure is not limited to technical solutions formed by specific combinations of the above-described technical features, but should also cover other technical solutions formed by arbitrary combinations of the above-described technical features or their equivalents without departing from the above-described concept. For example, technical solutions formed by substituting the above features with (but not limited to) technical features disclosed in this disclosure that have similar functions.
[0147] Furthermore, while the operations are described in a specific order, this should not be construed as requiring these operations to be performed in the specific order shown or in a sequential order. In certain environments, multitasking and parallel processing may be advantageous. Similarly, while several specific implementation details are included in the above discussion, these should not be construed as limiting the scope of this disclosure. Certain features described in the context of individual embodiments may also be implemented in combination in a single embodiment. Conversely, various features described in the context of a single embodiment may also be implemented individually or in any suitable sub-combination in multiple embodiments.
[0148] Although the subject matter has been described using language specific to structural features and / or methodological logic, it should be understood that the subject matter defined in the appended claims is not necessarily limited to the specific features or actions described above. Rather, the specific features and actions described above are merely illustrative examples of implementing the claims.
Claims
1. A real-time speech conversion method, characterized in that, include: Obtain the first audio and the identifier of the target timbre of the first user, wherein the first audio is processed in a streaming manner and the timbre of the first audio is different from the target timbre; Based on the real-time speech conversion model, the first audio, and the identifier of the target timbre, the target audio is determined, and the timbre of the target audio is the target timbre. The real-time speech conversion model is trained based on the sample audio features of the sample streaming audio and the timbre features of the target timbre. The sample audio features indicate the phoneme features, audio detail features, and pitch variation features of the sample streaming audio. The sample audio features of the sample streaming audio are determined based on a portion of the convolutional layers in the multiple convolutional layers of the speech recognition model. The portion of the convolutional layers are the first M convolutional layers in the multiple convolutional layers. The model parameters of the first M convolutional layers in the speech recognition model are shallowly convolved. M is an integer greater than or equal to 1, and M is less than the number of convolutional layers in the speech recognition model. Play the target audio.
2. The method according to claim 1, characterized in that, The determination of the target audio based on the real-time speech conversion model, the first audio, and the identifier of the target timbre includes: Obtain the audio features associated with the first audio, wherein the audio features indicate the phoneme features, audio detail features, and pitch variation features of the first audio; Based on the identifier of the target timbre, the timbre characteristics of the target timbre are obtained; Based on the real-time speech conversion model, the audio features, and the timbre features, a first spectrogram associated with the first audio is obtained, and the timbre indicated by the first spectrogram is the target timbre; The target audio is determined based on the first spectrogram.
3. The method according to claim 1 or 2, characterized in that, The acquisition of the first user's first audio and the identifier of the target timbre includes: Display a timbre conversion page, which includes a target timbre control and an audio acquisition control; In response to a trigger operation on the target timbre control, the identifier of the target timbre is determined; In response to a trigger operation on the audio acquisition control, the first audio of the first user is acquired.
4. The method according to claim 1 or 2, characterized in that, The real-time speech conversion model is determined through the following steps: Acquire the audio features of the sample streaming audio and the timbre features of the target timbre, wherein the audio features indicate the phoneme features, audio detail features, and pitch variation features of the sample streaming audio; The audio features and timbre features are processed by a real-time speech conversion model to obtain a predicted spectrogram of the sample streaming audio. Obtain the target spectrogram of the sample streaming audio, wherein the timbre indicated by the target spectrogram is the target timbre; The real-time speech conversion model is updated based on the predicted spectrogram and the target spectrogram.
5. The method according to claim 4, characterized in that, The acquisition of audio features from sample streaming audio includes: Based on a portion of the multiple convolutional layers in a speech recognition model, the audio features of the sample streaming audio are determined, and the speech recognition model is used to convert speech information into text information.
6. The method according to claim 5, characterized in that, The process of obtaining the target spectrogram of the sample streaming audio includes: The sample streaming audio is processed using a non-streaming timbre conversion model to obtain the target spectrogram of the sample streaming audio. The non-streaming timbre conversion model is obtained by learning from multiple sets of samples, including sample non-streaming audio, timbre features of the target timbre, sample non-streaming audio, and a sample spectrogram associated with the timbre features. The timbre indicated by the sample spectrogram is the target timbre.
7. The method according to claim 5, characterized in that, The step of updating the real-time speech conversion model based on the predicted spectrogram and the target spectrogram includes: The prediction error of the real-time speech conversion model is determined based on the predicted spectrogram and the target spectrogram. The real-time speech conversion model is updated based on the prediction error.
8. A real-time speech conversion device, characterized in that, It includes an acquisition module, a first determination module, and a playback module, wherein: The acquisition module is used to acquire the first audio and the identifier of the target timbre of the first user, wherein the first audio is processed in a streaming manner and the timbre of the first audio is different from the target timbre; The first determining module is used to determine the target audio based on the real-time speech conversion model, the first audio, and the identifier of the target timbre. The timbre of the target audio is the target timbre. The real-time speech conversion model is trained based on the sample audio features of the sample streaming audio and the timbre features of the target timbre. The sample audio features indicate the phoneme features, audio detail features, and pitch variation features of the sample streaming audio. The sample audio features of the sample streaming audio are determined based on a portion of the convolutional layers in the multiple convolutional layers of the speech recognition model. The portion of the convolutional layers are the first M convolutional layers in the multiple convolutional layers. The model parameters of the first M convolutional layers in the speech recognition model are shallowly convolved. M is an integer greater than or equal to 1 and M is less than the number of convolutional layers in the speech recognition model. The playback module is used to play the target audio.
9. An electronic device, characterized in that, include: Processor and memory; The memory stores computer-executed instructions; The processor executes computer execution instructions stored in the memory, causing the processor to perform the real-time speech conversion method as described in any one of claims 1-7.
10. A computer-readable storage medium, characterized in that, The computer-readable storage medium stores computer-executable instructions, which, when executed by the processor, implement the real-time speech conversion method as described in any one of claims 1-7.
11. A computer program product, comprising a computer program, characterized in that, When the computer program is executed by the processor, it implements the real-time speech conversion method as described in any one of claims 1-7.
Citation Information
Patent Citations
Tone based audio conversion method and device
CN107767879A
Audio generation method and device, storage medium and electronic equipment
CN113205793A
