A text-driven virtual human micro-expression expression method

Through the text-driven virtual human micro-expression expression method, the multi-resolution LPC method and the Blendshape model are used to solve the problem of insufficient synchronization performance of Chinese text expression and voice animation, and achieve natural and accurate virtual human micro-expression expression.

CN113838169BActive Publication Date: 2024-10-11NORTHWESTERN POLYTECHNICAL UNIV
View PDF 10 Cites 0 Cited by

Patent Information

Application Number
CN202110770714.0
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2021-07-07
Publication Date
2024-10-11
Estimated Expiration
2041-07-07

AI Technical Summary

Technical Problem

Existing virtual human micro-expression expression methods are mainly based on English text, and there are few researches on Chinese text expression methods. Moreover, text-driven methods have shortcomings in the synchronization performance of speech and animation and emotional expression, and the coordination and synchronization of mouth shape and expression are poor. , the animation effect is stiff.

Method used

Adopt a text-driven virtual human micro-expression expression method, synthesize speech through text and extract emotional labels, use the multi-resolution LPC method to extract vowel phonemes, and combine mouth shapes and facial expression animation with the Blendshape model to achieve natural virtual human micro-expression expressions .

Benefits of technology

It improves the speech and animation synchronization performance of Chinese text-driven virtual human micro-expression expression, enhances the naturalness of emotional expression and the accuracy of animation, reduces the mechanical feeling, and achieves more realistic virtual human micro-expression performance.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN113838169B_ABST
    Figure CN113838169B_ABST
Patent Text Reader

Abstract

The present invention discloses a method for expressing micro-expressions of a virtual person based on text drive, and the method comprises: step 1, synthesizing speech according to input text, and obtaining an emotion label according to the text; step 2, extracting vowel phonemes from the synthesized speech; step 3, obtaining animation according to the emotion label and the vowel phonemes based on a Blendshape model. When extracting the formant in the synthesized speech, the present invention proposes an improved multi-resolution LPC method to analyze the formant information in the speech in view of the problem that the local analysis ability of the LPC method is poor, and combines the characteristics of multi-band decomposition of wavelet transform, acquisition of local features, and simultaneous positioning of frequency domain and time domain with the LPC analysis method.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The invention belongs to the technical field of virtual reality and digital signal processing, and in particular relates to a method for expressing micro-expressions of a virtual human based on text drive. Background Art

[0002] With the continuous progress of society and the continuous development of science and technology, people's communication is not only limited to real life, but more from virtual space. The virtual human micro-expression expression method is mainly used in virtual human face animation technology. Virtual face animation and its display have been popularized in all walks of life, such as virtual anchors, virtual tour guides, movies and television. Nowadays, in people's daily chat methods, the dominant one is the online text chat using WeChat, QQ and other software as tools. People are more eager to establish a "face-to-face" chat in the virtual world like in the real world. Under this demand, the virtual human micro-expression expression method has become a research hotspot in recent years.

[0003] The virtual human micro-expression expression method includes both the mouth shape change method and the expression change method, and it must be synchronized with the voice output, so that most of the information that the user wants to express can be transmitted. This technology contains multiple disciplines, including three-dimensional face reconstruction research, research on the movement rules of mouth shape and expression changes, discovery of natural coordination rules of facial colors, and research on the coordination of mouth shape, expression and voice. In terms of application value, the virtual human micro-expression expression method has a wide range of applications in entertainment, service industry, business and education, and with the development of this technology, its application areas will continue to expand.

[0004] In the human-computer interaction system, good visual experience is the primary factor to attract users. The so-called virtual human micro-expression expression method, in essence, is to control the movement of the face in a certain way based on the computer-synthesized three-dimensional face model. The existing virtual human micro-expression expression method has the following problems:

[0005] 1) Most of the existing virtual human micro-expression expressions are based on English text, and there are few studies on expression methods based on Chinese text;

[0006] 2) The current text-driven micro-expression expression method is to convert text into pinyin and analyze phonemes from the pinyin to obtain animation frames, obtain speech frames from a pre-built Chinese pronunciation library, and then splice the animation frames and speech frames to obtain animation. In this way, each word of the speech obtained has the same pronunciation time, does not contain emotions, is relatively mechanical, and has poor synchronization performance between speech and animation;

[0007] 3) Endpoint detection can be performed from speech and phonemes can be extracted using resonance peaks, which can be used in lip expression methods. In general, the resonance peak parameters can be correctly extracted for short-term stable signals using the LPC (Linear Predictive Coding) method. However, the LPC method assumes the vocal tract transfer function to be a full-pole model and performs the same analysis on all frequency models on a linear scale. However, the human ear does not have the same sensitivity to all frequencies, and the sensitivity of the human ear to frequency is close to a logarithmic form. The LPC analysis system sometimes places poles at high frequencies to which the ear is not sensitive, and ignores closely spaced resonance peaks at low frequencies to which the ear is more sensitive, i.e., the resolution at local low frequencies is low;

[0008] 4) Among the existing virtual human expression methods, most of them only focus on the coordination and synchronization of voice and lip shape. There are few methods that can simultaneously match lip shape and expression and express them. In addition, most of them use parameter models to generate animations by adjusting parameters, which has a poor effect on the realization of micro-expressions and the output animation is relatively stiff.

[0009] Therefore, how to directly obtain phonemes from text information to make the expression output more mechanical has become an urgent problem to be solved. Summary of the invention

[0010] In order to solve the above problems existing in the prior art, the present invention provides a method for expressing micro-expressions of virtual humans based on text-driven. The technical problem to be solved by the present invention is achieved through the following technical solutions:

[0011] A method for expressing micro-expressions of a virtual human based on text drive, comprising:

[0012] Step 1: synthesize speech according to the input text, and obtain an emotion label according to the text;

[0013] Step 2, extracting vowel phonemes from the synthesized speech;

[0014] Step 3: Based on the Blendshape model, an animation is obtained according to the emotion label and the vowel phoneme.

[0015] In one embodiment of the present invention, synthesizing speech according to input text includes:

[0016] Create a text-to-speech synthesis application and obtain the API Key and Secret Key for speech synthesis. Obtain the Access Token based on the API Key and Secret Key of the applied speech synthesis project to obtain the request credential. Send a text request for speech synthesis based on the obtained Access Token of the speech synthesis project to synthesize the input text into speech.

[0017] In one embodiment of the present invention, obtaining a sentiment tag according to the text includes:

[0018] Create a text sentiment analysis application and obtain the API Key and Secret Key for text sentiment analysis. Obtain the Access Token based on the API Key and Secret Key of the applied text sentiment analysis project to obtain the request credential. Send a text request based on the obtained Access Token of the text sentiment analysis project to analyze the text sentiment and obtain the sentiment label.

[0019] In one embodiment of the present invention, step 2 comprises:

[0020] Step 2.1, performing frame processing on the speech by using a frame windowing method to obtain a plurality of first sub-speech;

[0021] Step 2.2: performing endpoint detection on the first sub-speech using a short-time average energy method to obtain the short-time average energy of the first sub-speech;

[0022] Step 2.3, obtaining a second sub-speech according to the short-time average energy of the first sub-speech and a threshold ε, wherein the second sub-speech is a speech containing sound;

[0023] Step 2.4, obtaining formants and formant frequencies according to the second sub-speech based on a multi-resolution LPC method;

[0024] Step 2.5: Compare the formant frequency of the formant with the resonance frequencies of different vowels to obtain vowel phonemes in the speech from the formant.

[0025] In one embodiment of the present invention, step 2.4 comprises:

[0026] Step 2.41, discretizing the scaling factor and the time shift factor to obtain the discretized scaling factor and the time shift factor;

[0027] Step 2.42: Based on the discretized scaling factor and the time shift factor, use DWT to perform equal-band decomposition on the second sub-speech according to different frequency bands to obtain a third sub-speech;

[0028] Step 2.43: Process the third sub-speech using a multi-resolution LPC method to obtain the formant, and use a peak detection method to analyze the formant frequency of the formant based on the LPC spectrum.

[0029] In one embodiment of the present invention, the peak detection method is used to analyze the formant frequency of the formant according to the LPC spectrum, including:

[0030] Obtaining a prediction coefficient according to the third sub-speech and an approximation of the third sub-speech;

[0031] Based on an all-pole model of vocal tract transmission, obtaining frequency characteristics of the all-pole model according to the prediction coefficients;

[0032] Taking the power spectrum modulus of the frequency characteristic to obtain an LPC spectrum;

[0033] The peak value of the LPC spectrum is detected by a peak detection method to obtain the resonance peak frequency of the resonance peak.

[0034] In one embodiment of the present invention, obtaining a prediction coefficient according to the third sub-speech and the approximation of the third sub-speech comprises:

[0035] Linearly combining the first p third sub-speech sounds to obtain an approximate value of the nth third sub-speech sound;

[0036] Obtaining a prediction error according to a difference between the third sub-speech and the approximation;

[0037] Based on the minimum mean square error criterion, a mean square error value is obtained according to the prediction error;

[0038] The prediction coefficient is obtained by partially differentiating the prediction coefficient using the mean square error value and making the partial differentiation result 0.

[0039] In one embodiment of the present invention, step 3 comprises:

[0040] Step 3.1, make a Blendshape model based on six basic lip models and two basic expression models;

[0041] Step 3.2: Based on the Blendshape model, according to the emotion label, the vowel phoneme and the start and end time of the vowel phoneme, the corresponding basic lip shape model and basic expression model are fused to obtain the animation.

[0042] In one embodiment of the present invention, step 3.2 comprises:

[0043] Step 3.21, mapping the vowel phonemes to the basic mouth shapes in the Blendshape model, and mapping the emotion labels to the basic expressions in the Blendshape model;

[0044] Step 3.22: According to the emotion label, the vowel phoneme and the start and end time of the vowel phoneme, the corresponding basic lip shape model and basic expression model are merged to obtain the animation.

[0045] In one embodiment of the present invention, after step 3, the method further includes:

[0046] Step 4: Use linear interpolation algorithm to smooth the animation.

[0047] Beneficial effects of the present invention:

[0048] In order to solve the problem of poor local analysis ability of LPC method when extracting resonance peaks in synthesized speech, the present invention proposes an improved multi-resolution LPC method to analyze resonance peak information in speech, and combines the characteristics of multi-band decomposition of wavelet transform, acquisition of local features, and simultaneous positioning of frequency domain and time domain with LPC analysis method. The improved multi-resolution LPC method has higher frequency resolution at low frequencies, and the extracted resonance peaks at low frequencies have higher accuracy, making vowel extraction results more accurate and virtual mouth shape animation more accurate. The present invention first synthesizes emotional speech, and then uses multi-resolution LPC to extract mouth shape phonemes from the synthesized speech to facilitate subsequent virtual mouth shape expression, thereby reducing the problem of directly synthesizing speech and phonemes from text to make animation expression mechanical; the Blendshape method is used to naturally and effectively integrate virtual mouth shape and facial expression, achieving the good effect of "sound and emotion".

[0049] The present invention will be further described in detail below with reference to the accompanying drawings and embodiments. BRIEF DESCRIPTION OF THE DRAWINGS

[0050] Figure 1 It is a flowchart of a method for expressing micro-expressions of a virtual human based on text-driven according to an embodiment of the present invention;

[0051] Figure 2 It is a flowchart of another method for expressing micro-expressions of a virtual human based on text-driven according to an embodiment of the present invention;

[0052] Figure 3 It is a flowchart of a text-to-speech synthesis provided by an embodiment of the present invention;

[0053] Figure 4 is a schematic diagram of a method for obtaining an Access token provided by an embodiment of the present invention;

[0054] Figure 5 This is a flow chart of a method of sending an HTTP request for synthesized speech using a GET method provided by an embodiment of the present invention;

[0055] Figure 6 It is a time domain waveform diagram of the output speech after inputting "Northwestern Polytechnical University is a key university" provided by an embodiment of the present invention;

[0056] Figure 7 is an amplitude-frequency characteristic curve of a Hamming window provided in an embodiment of the present invention;

[0057] Figure 8 It is a schematic diagram of performing equal-band decomposition of a signal using DWT provided by an embodiment of the present invention;

[0058] Fig. 9 It is a flow chart of the improved multi-resolution LPC formant analysis method;

[0059] Fig.10 It is a schematic diagram comparing an improved multi-resolution LPC method provided by an embodiment of the present invention and a traditional LPC method. DETAILED DESCRIPTION

[0060] The present invention is further described in detail below with reference to specific embodiments, but the embodiments of the present invention are not limited thereto.

[0061] Embodiment 1

[0062] See also Figure 1 and Figure 2 , Figure 1 is a flowchart of a method for expressing micro-expressions of a virtual human based on text-driven expression provided by an embodiment of the present invention. Figure 2 1 is a flowchart of another method for expressing micro-expressions of a virtual human based on text-driven expression provided by an embodiment of the present invention. An embodiment of the present invention provides a method for expressing micro-expressions of a virtual human based on text-driven expression, the method for expressing micro-expressions of a virtual human comprising steps 1 to 4, wherein:

[0063] Step 1: Synthesize speech based on the input text and obtain emotion labels based on the text.

[0064] In this embodiment, the text-driven expression method first realizes text-to-speech synthesis, analyzes the text to obtain the emotion tags required for the animation, and then realizes the corresponding lip shape and expression animation.

[0065] In a specific embodiment, synthesizing speech according to input text includes:

[0066] Create a text-to-speech synthesis application and obtain the API Key (project account) and Secret Key (project password) for speech synthesis. Obtain the Access Token (success token) based on the API Key and Secret Key of the applied speech synthesis project to obtain the request credential. Send a text request for speech synthesis based on the obtained Access Token of the speech synthesis project to synthesize the input text into speech.

[0067] Specifically, see Figure 3 ,The specific implementation steps of text-to-speech synthesis include:

[0068] A1. Baidu AI (Artificial Intelligence) Open Platform includes multiple technical capabilities, solutions and integrated hardware and software components. Create a text-to-speech synthesis application on Baidu AI Open Platform and obtain resources, including APPID (project number), APIKey and SecretKey. API Key and Secret Key are used for subsequent Access tokens to complete the call and configuration of related interfaces.

[0069] A2. Obtain Access Token based on the APIKey and SecretKey of the project you applied for to obtain the request credentials. Figure 3 , Figure 3 This is the process of obtaining the Access token. First, define the token status and send an HTTP (Hypertext Transfer Protocol) request to obtain the Access Token. Define the current token status as Fetching (connecting), then concatenate the URL (uniform resource locator) and send the request using the GET method; then parse the response, and after Baidu responds, a Json formatted data will be returned. Use the JsonUtility.FromJson method to convert the obtained Json data into a TokenResponse custom object. When the Json data is parsed, the "access_token" field is the authentication information required to request the REST (Representational State Transfer) API (Application Programming Interface).

[0070] A3. Send text request for speech synthesis and analysis based on the obtained Access Token. Please refer to Figure 5, use the GET method to send an HTTP request to synthesize speech. If the token is successfully obtained, use the GET method to send an HTTP request with input text (the input text is the text to be synthesized into speech). Use the dictionary form to splice the URL, use the GET form HTTP request to send a request, and wait for Baidu's response. After the server returns the response, you need to check the returned header file Content-Type (content type) to determine whether it is successfully obtained. If the header file contains the "audio" field, it is successfully obtained, and then use the DownloadHandlerAudioClip.GetContent method to obtain the audio clip in it and place it in the clip path, and copy the audio segment to AudioSouse in Unity for playback. See Figure 6 , is the time domain waveform of the synthesized speech after the input text "Northwestern Polytechnical University is a key university", in which the vertical lines correspond to the start and end nodes of each word. In the synthesized speech, the duration of each word is not equal, but long and short, which also indirectly shows that the synthesized speech is emotional. After verification, the speech synthesized from the input text is highly accurate and similar to daily speech, full of emotion and not mechanical.

[0071] In this embodiment, the input text is not only subjected to text-to-speech synthesis, but also subjected to analysis to obtain the emotional tags contained in the text, i.e., text sentiment analysis. Automatic emotional tendency analysis of the input subjective information text, including positive, negative and neutral.

[0072] In a specific embodiment, obtaining a sentiment tag according to the text includes:

[0073] Create a text sentiment analysis application and obtain the API Key and Secret Key for text sentiment analysis. Obtain the Access Token based on the API Key and Secret Key of the applied text sentiment analysis project to obtain the request credential. Send a text request based on the obtained Access Token of the text sentiment analysis project to analyze the text sentiment and obtain the sentiment label.

[0074] Specifically, the specific implementation steps for obtaining emotion labels include:

[0075] B1. Create a text sentiment analysis application on Baidu AI Open Platform and obtain resources, including APPID, APIKey and SecretKey.

[0076] B2. Obtain the Access Token according to the APIKey and SecretKey of the applied project to obtain the request credentials. First, define the token status and send an HTTP request to obtain the Access Token. Define the current token status as Fetching, then concatenate the URL (uniform resource locator) and send the request using the POST method. When constructing a POST request, you need to add the header file Header: "Content-Type", "application / json", and build a Body function to store the text that needs to be analyzed. When calling using the POST method, you need to use a Json format structure to describe the request content, so you need to convert the body content using the JsonMapper.ToJson method. Baidu's response returns data in the same Json format. Reference the LitJson.dll plug-in to convert the json data into a custom object, obtain the response return parameters, and get the corresponding emotional label. The return parameters and descriptions are shown in Table 1.

[0077] Table 1 Sentiment analysis return parameters and their descriptions

[0078]

[0079]

[0080] As shown in Table 2, Table 2 shows the information returned after the input text is "Northwestern Polytechnical University is a key university". It can be seen that the sentiment tendency is positive.

[0081] Table 2 Information returned after inputting the text "Northwestern Polytechnical University is a key university"

[0082]

[0083] In order to accurately realize text-to-speech synthesis and text-to-sentiment analysis, this embodiment connects the Baidu API interface to the system based on the GET and POST methods in HTTP requests to realize the speech synthesis function and text-to-sentiment analysis function respectively. Baidu's text-to-speech system mainly uses deep learning methods and applies deep learning to the entire process. Its training set is composed of human reading recordings, which makes the generated speech results more realistic; Baidu's sentiment analysis system is based on Baidu's deep learning framework PaddlePaddle Fluid. It converts high-quality online data into labeled data according to the label propagation algorithm, making the sentiment analysis more accurate.

[0084] Step 2: Extract vowel phonemes from the synthesized speech.

[0085] In a specific embodiment, step 2 may specifically include steps 2.1 to 2.5, wherein:

[0086] Step 2.1: Frame the speech using a frame-by-frame windowing method to obtain a plurality of first sub-speech.

[0087] There are some silent segments in the speech audio. In order to reduce the amount of spectrum analysis calculation, the signal needs to be preprocessed before the spectrum analysis of the speech signal, so as to remove the silent segments or the low-energy clear sound and noise parts. The preprocessing process includes frame windowing and endpoint detection.

[0088] Specifically, speech signals vary with time and are non-stationary processes. Only within a relatively short period of 10 to 30 ms will speech signals be relatively stable. Therefore, the processing of speech signals is based on "short-term". Therefore, it is necessary to divide a long speech into several small parts for analysis, that is, frame division. By using a window function moving on the time axis to segment the speech signal, multiple small segments of speech (i.e., the first sub-speech) are obtained. Assuming that the sampled signal in the discrete time domain is: x(n), n = 0, 1, 2, ..., N, where N is the sampling time index, the discrete process can be expressed by the following formula:

[0089] Q n =T[x(m)w(nm)]

[0090] Wherein, x(m) is the input speech signal, w(n) is the window function of the transformation of the short-time continuous signal, and T[·] is a certain transformation. Commonly used window functions include Hamming window, Hanning window, Blackman window, rectangular window, triangular window, etc., and the most commonly used are rectangular window and Hamming window. Since the subsequent speech analysis focuses on frequency analysis rather than time domain analysis, the present embodiment uses the Hamming window, and its mathematical expression is shown in the following formula:

[0091]

[0092] Where n is the sampling time index and N is the window length.

[0093] See also Figure 7 , Figure 7 The amplitude-frequency characteristic curve of the Hamming window. The Hamming window has the following characteristics: The Hamming window is an improved raised cosine window, and the energy is more concentrated in the main lobe. The frequency resolution is high, that is, the main lobe is narrow and sharp; through convolution, the frequency leakage generated by other frequency components is small, that is, the side lobe attenuation is large.

[0094] Step 2.2: Perform endpoint detection on the first sub-speech using a short-time average energy method to obtain the short-time average energy of the first sub-speech.

[0095] Specifically, in a speech audio, the discrete time segments with sound are limited. In order to reduce the amount of calculation in the frequency domain analysis, it is necessary to perform endpoint detection on the audio segment containing speech to distinguish the sound segment and locate its starting and ending positions to reduce the amount of calculation in the frequency domain analysis. The short-time average energy method is used to perform endpoint detection on the first sub-speech. The short-time average energy E of the first sub-speech after windowing in the nth frame is n The definition is as follows:

[0096]

[0097] Wherein, N is the frame length of the audio signal.

[0098] Step 2.3: Obtain a second sub-speech according to the short-time average energy of the first sub-speech and the threshold ε, where the second sub-speech is a speech containing sound.

[0099] Specifically, it can be seen from the above formula in step 2.3 that the values ​​in the data frame are summed to obtain the short-time average energy, and a threshold ε (Amplitude Threshold) is set to determine whether the current time period contains sound. If the short-time average energy of the first sub-speech is less than the threshold ε, it is considered that this frame has no sound and is not processed in the subsequent process to save unnecessary analysis process. If the short-time average energy of the first sub-speech is greater than the threshold ε, it is considered that this frame has sound, and the frame is the second sub-speech. Among them, the threshold ε depends on the noise level in the audio signal. Ideally, ε should be 0. In this embodiment, the threshold ε is, for example, 1.8.

[0100] Step 2.4: Based on the multi-resolution LPC method, the formant and the formant frequency are obtained according to the second sub-speech.

[0101] In speech signal analysis, formants and fundamental frequencies are the two most basic parameters that characterize signals. Formants are defined as vocal tract impulse responses. Formants refer to areas where energy is relatively concentrated in the audio spectrum. They not only reflect the physical characteristics of the vocal tract, but also determine the sound quality. They represent the direct source of speech information and are important parameters for distinguishing vowels. The improved multi-resolution LPC (Linear Predictive Coding) method is used to analyze the formant information in speech.

[0102] In a specific embodiment, step 2.4 may specifically include steps 2.41 to 2.43, wherein:

[0103] Step 2.41, discretize the scaling factor and the time-shift factor to obtain discretized scaling factor and time-shift factor.

[0104] The signal is decomposed into equal frequency bands according to different frequency bands using DWT (Discrete Wavelet Transform), i.e. multi-resolution analysis, so that the local frequency domain information of each frequency domain sub-segment of the signal can be obtained and the time can be located. Discrete wavelet transform is obtained on the basis of continuous wavelet transform (Continuous Wavelet Transform, CWT), and the mathematical expression of CWT is as follows:

[0105]

[0106] Among them, ψ(t) is the wavelet function, t is time, a is the expansion factor, which reflects the change of the amplitude and width of ψ(t), and b is the time shift factor, which indicates its translation position in the time domain. for is the conjugate complex number of , f(t) is the input function or input signal.

[0107] In order to reduce numerical analysis, reduce the time and resources consumed by computational redundancy, and ensure that both the time domain and the frequency domain are discrete after wavelet transform, it is necessary to discretize the scaling factor a and the time shift factor b at the same time to complete the discretization of the wavelet transform and obtain a discrete wavelet transform.

[0108] Usually, the scaling factor a is discretized using a binary method, and the time-shift factor b is discretized using a binary integer multiple, which can obtain a binary wavelet and a binary wavelet transform.

[0109] Step 2.42: Based on the discretized scaling factor and time shift factor, use DWT to perform equal-band decomposition on the second sub-speech according to different frequency bands to obtain the third sub-speech.

[0110] Specifically, the discretized scaling factor and time shift factor obtained in step 2.41 are substituted into the CWT mathematical expression of step 2.41, so as to use DWT to perform equal-band decomposition of the second sub-speech according to different frequency bands, and a binary wavelet and DWT transformation can be obtained. The DWT transformation mathematical expression is as follows:

[0111]

[0112] Where j = 0, ±, ±2... From the above formula, we can see that the binary wavelet transform has both orthogonality and time-shift invariance, which enables the wavelet transform to perform multi-resolution analysis. Figure 8 ,Depend on Figure 8 It can be seen that after continuous decomposition, the signal x(n) becomes multiple sub-band signals with different frequency bands. If DFT (Discrete Fourier Transform) is performed on the sub-signals, since its sampling frequency is decreasing and N remains unchanged, its frequency resolution is constantly increasing, fs / Nf s / 2N-f s / 4N-…So this method is called multi-resolution analysis. Therefore, the second sub-speech is decomposed into equal frequency bands according to different frequency bands using DWT, that is, multi-resolution analysis, which can not only obtain the local frequency domain information of each frequency domain sub-segment of the signal, but also locate the time.

[0113] Step 2.43: Process the third sub-speech using a multi-resolution LPC method to obtain formants, and use a peak detection method to analyze the formant frequencies of the formants based on the LPC spectrum.

[0114] Specifically, LPC is performed on the low-frequency part of the signal that has undergone DWT transformation in the first step to extract the resonance peak, and the resonance peak frequency is analyzed based on the LPC spectrum using a peak detection method.

[0115] In a specific embodiment, see Fig. 9 According to the LPC spectrum analysis, the resonance peak frequencies of the resonance peaks include C1 to C4, where:

[0116] C1. Obtain a prediction coefficient based on the third sub-speech and the approximate value of the third sub-speech.

[0117] Specifically, C1 may include C1.1 to C1.4, wherein:

[0118] C1.1. Linearly combine the first p third sub-speech sounds to obtain an approximate value of the nth third sub-speech sound.

[0119] Specifically, in the LPC method, the first p third sub-speech are linearly combined to obtain the approximate value of the nth third sub-speech Right now:

[0120]

[0121] Among them, a j , (j=1,2,…,p) is the prediction coefficient. Then the basic problem of LPC can be summarized as follows: the speech signal determines a set of prediction coefficients a j , so that the sum of squares of the difference between the linear prediction approximation and the actual value is minimized.

[0122] C1.2. Obtain prediction error based on the difference between the third sub-speech and the approximation, where prediction error e n for:

[0123]

[0124] C1.3, based on the least mean square error (LMSE) criterion, the mean square error value is obtained according to the prediction error, then the mean square error value E[e 2 The calculation method of (n)] is expressed as:

[0125]

[0126] C1.4. Partially differentiate the prediction coefficient by the mean square error value and make the partial differentiation result equal to 0 to obtain the prediction coefficient.

[0127] In order to minimize the mean square error value E, the mean square error value E is partially differentiated from the prediction coefficient and made zero, that is:

[0128]

[0129] Then we can get:

[0130]

[0131] Solving the above formula, we can get the prediction coefficient.

[0132] C2. Based on the full-pole model of vocal tract transmission, the frequency characteristics of the full-pole model are obtained according to the prediction coefficients.

[0133] In LPC, the vocal tract can be approximated as a p-order all-pole filter, and the all-pole model (AR model) of its transfer function is as follows:

[0134]

[0135] Among them, G is the gain, A(z) is the inverse filter, p is the LPC prediction order, a j is the prediction coefficient.

[0136] The resonance peak information is contained in the spectrum envelope, and the frequency at the maximum peak is the resonance peak frequency. The LPC spectrum can better represent the power spectrum. The LPC spectrum corresponding to the system function is obtained according to the LPC prediction coefficient, and the resonance peak frequency is analyzed using the peak detection method. The LPC prediction coefficient is the coefficient of the denominator polynomial of the system function. -1 The delay operator represents the single sampling time T of the signal. The complex frequency can be used to convert z -1 Represented as e -jwT , according to the sampling theorem, the sampling frequency f s =1 / 2T, w=2πf, w is the angular frequency, f is the frequency, so Substituting into the full-pole model H(z), we can get the frequency characteristics of the model. The mathematical expression of the frequency characteristics is as follows:

[0137]

[0138] Among them, H(f) is the frequency characteristic.

[0139] C3. Take the power spectrum modulus of the frequency characteristics to obtain the LPC spectrum.

[0140] Specifically, the power spectrum modulus value of the frequency characteristic is the LPC spectrum of the signal, and the mathematical expression is as follows:

[0141]

[0142] Where P(f) is the LPC spectrum of the signal.

[0143] C4. Detect the peak value of the LPC spectrum using the peak detection method to obtain the resonance peak frequency of the resonance peak.

[0144] Specifically, the frequency corresponding to the peak value in the LPC spectrum obtained in step C3 is the resonance peak frequency.

[0145] In Chinese pronunciation, the pronunciation of vowels occupies most of the time, so the improved formant is used to extract the vowel phonemes in the speech, laying the foundation for the subsequent realization of lip animation. First, the synthesized speech is preprocessed to remove silent or low-energy speech segments, including frame windowing and endpoint detection; then the preprocessed voiced frames are transformed using the improved LPC analysis method to obtain the formant information in the speech. Among them, the improved multi-resolution LPC improves the traditional LPC analysis method. First, the speech frame is discrete wavelet transformed to perform multi-resolution analysis, that is, to separate the low-frequency part from the high-frequency part, and then the low-frequency signal is subjected to LPC formant analysis, and the LPC spectrum is peak detected to extract the formant. Formant refers to the area where the energy is relatively concentrated in the audio spectrum. It not only reflects the physical characteristics of the vocal tract, but also determines the sound quality. It represents the direct source of speech information and is an important parameter for distinguishing vowels. See Fig.10 ,exist Fig.10In the figure, the thin line is the short-time power spectrum obtained by short-time Fourier transform, and the thick line is the LPC spectrum after LPC analysis. In the left figure, the frequency range is 0-6000Hz, and the LPC spectrum is basically similar to the short-time power spectrum envelope, but it can be clearly seen that the frequency resolution is low in the low frequency band. The right figure is the short-time power spectrum and LPC spectrum of the improved algorithm. After sub-band decomposition, the signal frequency is 0-1000Hz, and this interval is the frequency interval corresponding to the first resonance peak. It can be seen from the figure that it can be clearly seen that the frequency resolution in the low frequency band is significantly improved, and the LPC detail spectrum in the low frequency band can be clearly seen. It can also be clearly determined that the first resonance peak is the frequency corresponding to the first peak in the figure. After comparison, it can be seen that the improved multi-resolution LPC method has a higher frequency resolution at low frequencies, and the extracted resonance peaks at low frequencies have a higher accuracy, which is conducive to the subsequent extraction of lip animation phonemes.

[0146] Step 2.5: Obtain vowel phonemes according to the formant frequency and the vowel resonance frequency.

[0147] Specifically, the frequency corresponding to the peak value in the LPC spectrum obtained in step 2.4 is the formant frequency. In Chinese pronunciation, vowels occupy most of the entire pronunciation process. Since the physiological positions of human pronunciation organs are different when different vowels are pronounced, the resonance frequencies corresponding to different vowel pronunciations are different. By comparing the frequency corresponding to the peak value of the LPC spectrum with the resonance frequencies of different vowels, the vowel phonemes in the speech can be obtained from the formant.

[0148] In vowel representation, the most important are the first three formants, namely F1, F2, and F3. The first formant F1 is mainly distributed in the frequency range of 290Hz to 1kHz; the second formant F2 is mainly distributed in the frequency range of 500Hz to 2.9kHz; the third formant F3 is mainly distributed in the frequency range of 2.9kHz to 5kHz. The first formant F1 and the second formant F2 are used to extract vowels, and the frequency information of the first formant is mainly used. The sampling frequency f of the speech signal s Take 16KHz, and after three layers of discrete wavelet transform, the signal becomes sub-bands with different bandwidths. According to the different frequency ranges of different sub-bands, the sub-bands can be matched with the resonance peaks, as shown in Table 3:

[0149] Table 3 Correspondence between sub-bands and resonance peaks

[0150]

[0151] Since the position of the vocal organs of humans is different when they pronounce different sounds, the resonance frequencies of different vowels are different. By comparing the frequency corresponding to the peak of the LPC spectrum with the resonance frequencies of different vowels, the vowel phonemes in the speech can be obtained from the resonance peaks. As shown in Table 4, it is the statistical average of the two resonance peak frequencies of the six vowels of Mandarin obtained after sampling some people.

[0152] Table 4 Formant frequencies of the six vowels in Chinese

[0153]

[0154] Step 3: Based on the Blendshape model (shape fusion model), animation is obtained according to the emotion label and vowel phonemes.

[0155] In a specific embodiment, step 3 may specifically include steps 3.1 to 3.2, wherein:

[0156] Step 3.1: Create a Blendshape model based on six basic lip shape models and two basic expression models.

[0157] Specifically, in Maya software, first import the basic deformation model (i.e., neutral expressionless face model), six basic lip models (lip shapes a, o, e, i, u, ü) and two basic expression models (positive and negative expressions), select the key deformation model a (i.e., basic lip model a), then hold down the SHIFT key to select the basic deformation model, select Deformation Creation-Blended Deformation in the window bar, open Window-Animation Editor-Deformation Editor, and you can see the neutral model with fused expression a, and so on, get the Blendshape three-dimensional face model with six key lip shapes and two key expressions. Make a Blendshape model with six basic lip shapes and two basic expressions in Maya software; in the Blendshape model, each key model corresponds to a weight bar, and drag the weight bar to get animation from neutral expression to any lip shape or expression. The facial states corresponding to different weights are also different, and the weights of multiple key models can be set together. Among them, if the weight is 0, it is the basic deformation model, that is, the neutral model; if the weight is 100, it is displayed as the key deformation model; if the weight is an intermediate value, it is the intermediate effect after linear interpolation.

[0158] Step 3.2: Based on the Blendshape model, according to the emotion label, vowel phonemes and the start and end times of the vowel phonemes, the corresponding basic lip shape model and the basic expression model are fused to obtain the animation.

[0159] In a specific embodiment, step 3.2 may specifically include steps 3.21 to 3.22, wherein:

[0160] Step 3.21: Map vowel phonemes to basic mouth shapes in the Blendshape model, and map emotion labels to basic expressions in the Blendshape model.

[0161] Specifically, the Blendshape model is imported into the Unity software, the vowel phonemes extracted from the speech are mapped to the basic mouth shapes in the Blendshape model, and the emotional labels obtained from the text are mapped to the basic expressions in the Blendshape model. The mouth shapes a, o, e, i, u, ü correspond to mapping characters 0-5, and positive and negative expressions correspond to mapping characters 6-7. Table 5 shows the basic model and its mapping relationship.

[0162] Table 5 Mapping relationship between phonemes, expressions and control words

[0163]

[0164] Step 3.22: According to the emotion label, vowel phonemes and the start and end times of vowel phonemes, the corresponding basic lip shape model and basic expression model are fused to obtain the animation.

[0165] Combining the emotional labels obtained from text sentiment analysis with the extracted vowel phonemes and their start and end times, the corresponding basic lip shape model and basic expression model are fused to obtain the animation. The mathematical expression of shape fusion is:

[0166]

[0167]

[0168] Among them, E represents any expression model, E0 represents a neutral expression model, and E i represents the shape basis model, x i Represents the base model E i The weight, N BS Represents the number of shape basis models, N V Indicates the number of vertices of the 3D face model, E i,q (q=1,2....N V ) means E i Different vertices on .

[0169] Step 4: Use linear interpolation algorithm to smooth the animation.

[0170] For the key lip shape frames obtained, an interpolation algorithm needs to be used to smoothly transition to obtain transition frames to make the expression effect smoother and more realistic. This embodiment uses a linear interpolation algorithm to smooth the animation, and the mathematical expression is:

[0171] V′=(1-α)·V f1 +α·V f2

[0172] Among them, V′ is the transition interpolation viseme (the viseme is the mouth shape position during pronunciation), α is the interpolation parameter, and V f1 , V f2 The interpolation algorithm is only used for lip animation. In terms of facial expression animation, since the same expression is maintained throughout the sentence, there is no need to transition between expressions.

[0173] In order to solve the problem of poor local analysis ability of LPC method when extracting resonance peaks in synthesized speech, the present invention proposes an improved multi-resolution LPC method to analyze resonance peak information in speech, and combines the characteristics of multi-band decomposition of wavelet transform, acquisition of local features, and simultaneous positioning of frequency domain and time domain with LPC analysis method. The improved multi-resolution LPC method has higher frequency resolution at low frequencies, and the extracted resonance peaks at low frequencies have higher accuracy, making vowel extraction results more accurate and virtual mouth shape animation more accurate. The present invention first synthesizes emotional speech, and then uses multi-resolution LPC to extract mouth shape phonemes from the synthesized speech to facilitate subsequent virtual mouth shape expression, thereby reducing the problem of directly synthesizing speech and phonemes from text to make animation expression mechanical; the Blendshape method is used to naturally and effectively integrate virtual mouth shape and facial expression, achieving the good effect of "sound and emotion".

[0174] In the description of this specification, the description with reference to the terms "one embodiment", "some embodiments", "example", "specific example", or "some examples" etc. means that the specific features, structures, materials or characteristics described in conjunction with the embodiment or example are included in at least one embodiment or example of the present invention. In this specification, the schematic representations of the above terms do not necessarily refer to the same embodiment or example. Moreover, the specific features, structures, materials or characteristics described may be combined in any one or more embodiments or examples in a suitable manner. In addition, those skilled in the art may combine and combine different embodiments or examples described in this specification.

[0175] Although the present application is described herein in conjunction with various embodiments, in the process of implementing the claimed application, those skilled in the art may understand and implement other variations of the disclosed embodiments by viewing the drawings, the disclosure, and the appended claims. In the claims, the word "comprising" does not exclude other components or steps, and "one" or "an" does not exclude multiple situations. A single processor or other unit may implement several functions listed in a claim. Certain measures are recorded in different dependent claims, but this does not mean that these measures cannot be combined to produce good results.

[0176] The above contents are further detailed descriptions of the present invention in combination with specific preferred embodiments, and it cannot be determined that the specific implementation of the present invention is limited to these descriptions. For ordinary technicians in the technical field to which the present invention belongs, several simple deductions or substitutions can be made without departing from the concept of the present invention, which should be regarded as falling within the protection scope of the present invention.

Claims

1. A text-driven virtual human micro-expression expression method, It is characterized in that include: Step 1: synthesize speech according to the input text, and obtain an emotion label according to the text; Step 2, extracting vowel phonemes from the synthesized speech; Step 3: Based on the Blendshape model, an animation is obtained according to the emotion label and the vowel phoneme; The step 2 comprises: Step 2.1, performing frame processing on the speech by using a frame windowing method to obtain a plurality of first sub-speech; Step 2.2: performing endpoint detection on the first sub-speech by using a short-time average energy method to obtain the short-time average energy of the first sub-speech; Step 2.3, obtaining a second sub-speech according to the short-time average energy of the first sub-speech and a threshold ε, wherein the second sub-speech is a speech containing sound; Step 2.4, obtaining formants and formant frequencies according to the second sub-speech based on a multi-resolution LPC method; Step 2.5, comparing the formant frequency of the formant with the resonant frequencies of different vowels to obtain vowel phonemes in the speech from the formant, The step 2.4 comprises: Step 2.41, discretizing the scaling factor and the time shift factor to obtain the discretized scaling factor and the time shift factor; Step 2.42: Based on the discretized scaling factor and the time shift factor, use DWT to perform equal-band decomposition on the second sub-speech according to different frequency bands to obtain a third sub-speech; Step 2.43: Process the third sub-speech by using a multi-resolution LPC method to obtain the formant, and use a peak detection method to analyze the formant frequency of the formant based on the LPC spectrum.

2. The method for expressing micro-expressions of a virtual human based on text-driven expression according to claim 1, It is characterized in that Synthesize speech based on input text, including: Create a text-to-speech synthesis application and obtain the API Key and Secret Key for speech synthesis. Obtain the Access Token based on the API Key and Secret Key of the applied speech synthesis project to obtain the request credential. Send a text request for speech synthesis based on the obtained Access Token of the speech synthesis project to synthesize the input text into speech.

3. The method for expressing micro-expressions of a virtual human based on text-driven expression according to claim 1, It is characterized in that Obtaining a sentiment label according to the text includes: Create a text sentiment analysis application and obtain the API Key and Secret Key for text sentiment analysis. Obtain the Access Token based on the API Key and Secret Key of the applied text sentiment analysis project to obtain the request credential. Send a text request based on the obtained Access Token of the text sentiment analysis project to analyze the text sentiment and obtain the sentiment label.

4. The method for expressing micro-expressions of a virtual human based on text-driven method according to claim 3, It is characterized in that The peak detection method is used to analyze the formant frequency of the formant according to the LPC spectrum, including: Obtaining a prediction coefficient according to the third sub-speech and an approximation of the third sub-speech; Based on an all-pole model of vocal tract transmission, obtaining frequency characteristics of the all-pole model according to the prediction coefficients; Taking the power spectrum modulus of the frequency characteristic to obtain an LPC spectrum; The peak value of the LPC spectrum is detected by a peak detection method to obtain the resonance peak frequency of the resonance peak.

5. The method for expressing micro-expressions of a virtual human based on text-driven method according to claim 4, It is characterized in that Obtaining a prediction coefficient according to the third sub-speech and the approximate value of the third sub-speech, comprising: Linearly combining the first p third sub-speech sounds to obtain an approximate value of the nth third sub-speech sound; Obtaining a prediction error according to a difference between the third sub-speech and the approximation; Based on the minimum mean square error criterion, a mean square error value is obtained according to the prediction error; The prediction coefficient is obtained by partially differentiating the prediction coefficient using the mean square error value and making the partial differentiation result 0.

6. The method for expressing micro-expressions of a virtual human based on text-driven expression according to claim 1, It is characterized in that The step 3 comprises: Step 3.1, make a Blendshape model based on six basic lip models and two basic expression models; Step 3.2: Based on the Blendshape model, according to the emotion label, the vowel phoneme and the start and end time of the vowel phoneme, the corresponding basic lip shape model and basic expression model are fused to obtain the animation.

7. The method for expressing micro-expressions of a virtual human based on text-driven method according to claim 6, It is characterized in that The step 3.2 comprises: Step 3.21, mapping the vowel phonemes to the basic mouth shapes in the Blendshape model, and mapping the emotion labels to the basic expressions in the Blendshape model; Step 3.22: According to the emotion label, the vowel phoneme and the start and end time of the vowel phoneme, the corresponding basic lip shape model and basic expression model are merged to obtain the animation.

8. The method for expressing micro-expressions of a virtual human based on text-driven method according to claim 1, It is characterized in that After step 3, the method further includes: Step 4: Use linear interpolation algorithm to smooth the animation.

Citation Information

Patent Citations

  • Intelligent emotional interaction method for service robot

    CN103413113A

  • Speech processing device and method

    CN104240696A

  • Intelligent automated assistant for media exploration

    CN107480161A

  • Mouth shape expression animation generation method and device based on formant, and storage medium

    CN112700520A

  • Multi-speech feature fusion depression detection method under spectral subtraction noise reduction

    CN113012720A