Expression information recognition method, device, equipment, readable storage medium and product
By fusing the facial features of the current frame image, historical images and subsequent images, the jitter problem in virtual character expression simulation is solved, the accuracy and continuity of expression information is improved, and a more realistic facial expression performance is achieved.
Patent Information
- Application Number
- CN202310096499.X
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2023-01-20
- Publication Date
- 2024-08-30
- Estimated Expiration
- 2043-01-20
AI Technical Summary
In computer animation, virtual characters' expressions jitter when simulated, resulting in incoherent expressions.
By acquiring the current frame image, historical images and subsequent images, and fusing their respective facial image features to determine the target facial image features, the accuracy and continuity of expression information are improved.
It effectively reduces the jitter between virtual characters' expressions, improves the accuracy and continuity of expression information, and makes the facial expressions of virtual characters more realistic and coherent.
Smart Images

Figure CN115984944B
Abstract
Description
Technical Field
[0001] The embodiments of the present disclosure relate to the field of image processing technology, and in particular, to a method, device, equipment, readable storage medium and product for identifying facial expression information. Background Art
[0002] In the field of computer animation, in order to enable virtual characters to better express emotions, the expressions of virtual characters can be made to simulate human facial expressions.
[0003] In order to facilitate the simulation of human facial expressions by virtual characters, human facial expressions are represented as multi-dimensional vectors. Each expression can correspond to a multi-dimensional vector. Applying the multi-dimensional vector to the face of the virtual character makes the virtual character's expression simulate human facial expression.
[0004] In some application scenarios, the user's continuous multi-frame expressions can be simulated, for example, the facial expressions in the image frame sequence corresponding to the video stream can be simulated. Specifically, the facial expression information corresponding to the multiple frames of images can be extracted, and then the facial expression information can be applied to the virtual character. Currently, when the expression information of multiple frames of facial images is applied to the virtual character, there is a jitter phenomenon. Summary of the invention
[0005] The embodiments of the present disclosure provide a method, device, equipment, readable storage medium and product for identifying facial expression information, so as to overcome the problem of jitter when applying facial expression information in multiple consecutive frames of facial images to the facial expressions of animated characters in the related art.
[0006] In a first aspect, an embodiment of the present disclosure provides a method for recognizing facial expression information, comprising: acquiring a current frame image, historical images of the current frame image, and subsequent images, wherein the images include a facial image of a target object; determining target facial image features of the current frame image based on the current frame image, historical images, and subsequent images; and determining the facial expression information of the target object in the current frame image based on the target facial image features.
[0007] In a second aspect, an embodiment of the present disclosure provides an expression information recognition device, comprising: an acquisition unit, used to acquire a current frame image, historical images of the current frame image, and subsequent images, wherein the image includes a facial image of a target object; a prediction unit, used to determine target facial image features of the current frame image based on the current frame image, historical images, and subsequent images; and determine the expression information of the target object in the current frame image based on the target facial image features.
[0008] In a third aspect, an embodiment of the present disclosure provides an electronic device, comprising: a processor and a memory; the memory stores computer execution instructions; the processor executes the computer execution instructions stored in the memory, so that the at least one processor executes the expression information recognition method described in the first aspect and various possible designs of the first aspect.
[0009] In a fourth aspect, an embodiment of the present disclosure provides a computer-readable storage medium, in which computer execution instructions are stored. When a processor executes the computer execution instructions, the expression information recognition method described in the first aspect and various possible designs of the first aspect is implemented.
[0010] In a fifth aspect, an embodiment of the present disclosure provides a computer program product, including a computer program, which, when executed by a processor, implements the expression information recognition method described in the first aspect and various possible designs of the first aspect.
[0011] The expression information recognition method, device, equipment, readable storage medium and product provided in this embodiment first obtain the current frame image, the historical image of the current frame image and the subsequent image, wherein the image includes the facial image of the target object; then determine the target facial image feature of the current frame image according to the current frame image, the historical image and the subsequent image; and determine the expression information of the target object in the current frame image based on the target facial image feature. The above scheme fuses the facial image features of the historical image, the current frame image and the subsequent image as the target facial image feature of the current frame image, so that the facial image features of the historical image and the facial image features of the subsequent image are added to the target facial image feature, which is equivalent to adding the constraints of the facial image features of the historical image and the facial image features of the subsequent image when determining the target facial image feature corresponding to the current frame image, so that a more accurate target facial image feature of the current frame image can be determined, which is conducive to improving the accuracy of the expression information determined by the target facial image feature, and can also improve the continuity of the expression information corresponding to the determined consecutive frame images. It is conducive to improving the jitter phenomenon of the expression information between consecutive frames of the virtual object when the expression information of multiple consecutive frames of facial images is applied to the virtual object. BRIEF DESCRIPTION OF THE DRAWINGS
[0012] In order to more clearly illustrate the embodiments of the present disclosure or the technical solutions in the prior art, the drawings required for use in the embodiments or the description of the prior art will be briefly introduced below. Obviously, the drawings described below are some embodiments of the present disclosure. For ordinary technicians in this field, other drawings can be obtained based on these drawings without paying creative labor.
[0013] Figure 1A schematic diagram of a process for determining expression information of a target object in an image in the related art;
[0014] Figure 2 Schematic diagram of the expression information recognition method provided in the embodiment of the present disclosure Figure 1 ;
[0015] Figure 3 Schematic diagram of the expression information recognition method provided in the embodiment of the present disclosure Figure 2 ;
[0016] Figure 4 for Figure 3 A schematic diagram of the correction process of the expression generation model in the illustrated embodiment;
[0017] Figure 5 A schematic diagram of the correction process of the expression model in the related art;
[0018] Figure 6 A schematic diagram for determining expression information corresponding to multiple frames of images in an image sequence;
[0019] Figure 7 A calculation diagram of a fully connected network used in an expression model in the related art, an expression information recognition device;
[0020] Fig. 8A and Figure 8B for Figure 3 A schematic diagram of one-dimensional convolutional network calculation in the expression generation model in the illustrated embodiment;
[0021] Fig. 9 A structural block diagram of an expression information recognition device provided in an embodiment of the present disclosure;
[0022] Fig.10 A schematic diagram of the hardware structure of the facial expression information recognition device provided in an embodiment of the present disclosure. DETAILED DESCRIPTION
[0023] In order to make the purpose, technical solution and advantages of the embodiments of the present disclosure clearer, the technical solution in the embodiments of the present disclosure will be clearly and completely described below in conjunction with the drawings in the embodiments of the present disclosure. Obviously, the described embodiments are part of the embodiments of the present disclosure, not all of the embodiments. Based on the embodiments in the present disclosure, all other embodiments obtained by ordinary technicians in this field without creative work are within the scope of protection of the present disclosure.
[0024] In order to make the expression of the virtual character simulate the expression of the real person, the facial expression information of each frame of the continuous multi-frame facial image can be extracted, and the expression information of each frame of the extracted facial image can be applied to the face of the virtual character. This scheme is to perform facial expression recognition on a single frame image, but when performing facial expression recognition on continuous multi-frame facial images, the correlation between the expression information of each frame of the recognized facial image is poor. When the expression information corresponding to the continuous multi-frame facial images is applied to the virtual character, the expression of the virtual character in the picture will appear incoherent, that is, the jitter phenomenon.
[0025] In order to improve the above-mentioned jitter phenomenon, in some other related technologies, for consecutive frames of facial images, the facial expression information of the previous frame of historical images or the previous two frames of historical images is fused into the facial expression information of the current frame of images at a certain ratio as the facial expression information of the current image. The facial expression information of the current frame of images fused with the facial expression information of the historical images is applied to the virtual character. The inventors found that when the facial expression information obtained by the above scheme is applied to the virtual character, jitter still occurs.
[0026] In order to determine the facial expression information, the facial muscles can be divided into multiple action units, and the combination of multiple action units can represent multiple facial expressions. Assuming that the number of facial action units is N, for each expression, the position and shape characteristics corresponding to the N action units under the expression can be quantized according to a preset quantization rule, and the quantization results of each action unit are arranged in a preset order to form an expression vector of the expression of the object in the facial image, thereby determining the expression information of the object in the facial image.
[0027] Please refer to Figure 1 , which shows a schematic flow chart of extracting facial expression information in the related art. Figure 1 As shown, in the related art, the facial expression predictions corresponding to the first two frames of the current frame image are respectively used to merge the facial expression predictions of the current frame image as the final facial expression prediction corresponding to the current frame image. Specifically,
[0028] When predicting the facial expression of the i-th frame image, the image features f corresponding to the i-th frame image, the i-1-th frame image, and the i-2-th frame image can be extracted respectively. i 、f i-1 、f i-2 , and according to the image features f corresponding to the i-th frame image, the i-1-th frame image, and the i-2-th frame image respectively i 、f i-1 、f i-2 Predict the facial expressions p corresponding to the i-th frame image, the i-1-th frame image, and the i-2-th frame image respectively i 、pi-1 、p i-2 Then the above facial expression p i 、p i-1 、p i-2 Fusion is performed to determine the p of the i-th frame image i '.
[0029] In the above process, although multiple frames of images are used to determine the facial expression in the current frame of image, there are the following problems:
[0030] The facial expression of the current frame image only incorporates the facial expression of the historical image, but not the facial expression in the subsequent image. Since the facial expression in the subsequent image is not referenced, the facial expression of the current frame image determined by the facial expressions in the historical image and the current frame image lacks the information of the facial expression of the subsequent image. On the one hand, this may make the predicted facial expression of the current frame image inaccurate, and on the other hand, it may cause the facial expressions of multiple consecutive frames determined by the above scheme to be incoherent.
[0031] The above-mentioned related technologies only fuse the expression information prediction results of the facial expressions corresponding to several consecutive frames of images, without involving the image features. If there are problems with the image feature extraction itself, it is impossible to correct the problems that occurred during the image feature extraction, and thus it is impossible to improve the above-mentioned jitter phenomenon.
[0032] refer to Figure 2 , Figure 2 Schematic diagram of the process of the expression information recognition method provided in the embodiment of the present disclosure Figure 1 The method of this embodiment can be applied in a terminal device or a server. The facial expression information recognition method includes:
[0033] S201: Acquire a current frame image, a historical image of the current frame image, and a subsequent image, wherein the image includes a facial image of a target object.
[0034] The target object here may be a person, or an animal or other target object. In some application scenarios, the target object may also be a virtual object.
[0035] The current frame image, historical image and subsequent image here can be extracted from a sequence of continuously acquired images. The above historical image can be one or more frames of images acquired before the acquisition time of the current frame image. The above subsequent image can be one or more frames of images acquired after the acquisition time of the current frame image. The number of historical images and subsequent images can be different. It should be noted that the number of historical images and subsequent images can be unlimited.
[0036] In some application scenarios, the historical image of the current frame image may include a frame image before the current frame image. The subsequent image of the current frame image may include a frame image after the current frame image.
[0037] In these application scenarios, the previous frame image of the current frame image and the subsequent frame image of the current frame image have a strong correlation with the current frame. The previous frame image, the subsequent frame image and the current frame image are used to comprehensively determine the expression information of the target object of the current frame image. On the one hand, when determining the expression information of the current frame image, the image information of historical images and the image information of subsequent images can be referred to. On the other hand, the amount of calculation when determining the expression information corresponding to the current frame image can be reduced.
[0038] In some application scenarios, the current frame image, historical image and subsequent image are obtained by preprocessing the original current frame image, original historical image and original subsequent image. The preprocessing includes but is not limited to image enhancement, face positioning, cropping, alignment and other operations. After the preprocessing, the facial parts of the target object in different images are in a relatively fixed position, which is convenient for subsequent processing.
[0039] S202: Determine target facial image features of the current frame image according to the current frame image, historical images and subsequent images; and determine expression information of the target object in the current frame image based on the target facial image features.
[0040] In this embodiment, the current frame image, historical images, and subsequent images may be analyzed and processed in various ways to determine the target facial image features of the current frame image.
[0041] For example, the current frame image, historical images and subsequent images may be superimposed, and then the pixel values of the superimposed images may be averaged to obtain averaged image data, and image features may be extracted from the averaged image data to obtain target facial image features of the current frame image.
[0042] As an implementation manner, the above step S202 may include the following steps:
[0043] First, the facial image features of the current frame image, the historical image, and the subsequent image are determined respectively.
[0044] Secondly, the facial image features of the current frame image, historical images and subsequent images are fused to obtain the target facial image features of the current frame image.
[0045] Specifically, facial image features of the current frame image, the historical image, and the subsequent image can be extracted respectively according to various image feature extraction algorithms.
[0046] The above-mentioned image feature extraction algorithms include but are not limited to: Gabor wavelet algorithm, principal component analysis algorithm, block local binary pattern algorithm, etc.
[0047] In some application scenarios, the facial image features are global facial features of the current frame image.
[0048] In some other application scenarios, the facial image features may include local features corresponding to multiple parts of the motion unit.
[0049] When fusing the above facial image features, the fusion ratios corresponding to the current frame image, historical images and subsequent images can be pre-set, and the facial image features of the current frame image, historical images and subsequent images can be fused according to the above fusion ratios to obtain the target facial image features of the current frame image.
[0050] The following uses the historical image including the previous frame image of the current frame image and the subsequent image including the subsequent frame image of the current frame image to illustrate the feature fusion of the historical image, the current frame image and the subsequent image. Assume that the facial image feature of the previous frame image is S i-1 , the facial image feature of the current frame image is S i , the facial image feature of the next frame is S i+1 . If the preset fusion ratios of the previous frame image, the current frame image and the next frame image are respectively: k i-1 , K i , k i+1 , then the target facial image features of the current frame image can be represented by the following formula:
[0051] S i '=k i-1 ×S i-1 +k i ×S i +k i+1 ×S i+1 (1);
[0052] The fusion ratio of the above images can be set according to the specific application scenario and is not limited here. As an implementation method, the fusion ratio of the current frame image can be, for example, 0.7, the fusion ratio of the historical image can be, for example, 0.15, and the fusion ratio of the subsequent image can be, for example, 0.15.
[0053] In some embodiments, for any image frame, the number of historical image frames included in the historical image and the number of subsequent image frames included in the subsequent image can be preset, and then the number of frames of the image involved in the target facial image feature of the image frame can be determined. Assuming that the number of historical image frames included in the historical image is t1, and the number of subsequent image frames included in the subsequent image is t2, the target facial image feature of the image frame can be determined by the facial image feature of the target object in the t1+t2+1 frame image. The length of the preset queue can be determined according to the above number of frames. For example, the length of the preset queue can be t1+t2+1. The facial image features corresponding to the continuous multiple frames of the target object can be input into the preset queue in sequence according to the order in which the frames correspond to each other. Each facial image feature input into the preset queue can be regarded as an element of the preset queue. When the preset queue is filled once, the facial image features corresponding to each frame image in the preset queue are fused once to obtain the target facial image feature of an image in the preset queue. After calculating the target facial image features of an image in the preset queue, the first element in the preset queue can be dequeued, and then the facial image features of the target object of the next frame image corresponding to the end of the original preset queue are input at the end of the preset queue.
[0054] For example, for the kth frame of the continuous image frames, the target facial image features of the kth frame need to be integrated with the image features of the t1th historical image frame, the facial image features of the t2th subsequent image frame, and the facial image features of the kth frame itself. Then, the facial image features corresponding to the (k-t1)th frame to the target image features corresponding to the (k+t2)th frame can be sequentially input into the preset queue in the order of the frames. After the preset queue is filled, the elements in the queue can be integrated to obtain the target facial image features of the target object corresponding to the kth frame. After the target facial image features of the kth frame are obtained, the facial image features corresponding to the (k-t1)th frame can be dequeued, and the elements stored in the preset queue are each moved forward one position. Then, the facial image features corresponding to the (k+1+t2)th frame are input to the end of the preset queue. Then, the target facial image features of the (k+1)th frame are calculated. Here, t1 is an integer greater than or equal to 1 and less than k. t2 is an integer greater than or equal to 1. k is an integer greater than 1. If the preset queue is not full, the elements in the preset queue will not be merged.
[0055] By fusing the facial image features of the historical image, the current frame image, and the subsequent image, the facial image features of the current image include the image information of the historical image and the subsequent image, so that the facial image features corresponding to the previous and subsequent images are correlated with each other, and the phenomenon that the facial image features of different images are independent of each other is weakened. If there is a deviation in the extraction of image features of one frame in adjacent images, the deviation can also be corrected by the image features of the adjacent frame images. This is conducive to achieving the continuity between the extracted image features of adjacent frame images, and then to the continuity of the determined adjacent corresponding expression information, and improving the jitter phenomenon that occurs when each expression information is applied to animation.
[0056] The expression information corresponding to the current frame image can be determined according to the features of the key points on different motion units in the face target part image features.
[0057] The above-mentioned motion units may include, for example: left eye, right eye, left eyebrow, right eyebrow, upper lip, lower lip, left cheek, right cheek, etc.
[0058] In some application scenarios, the target facial image feature is a global facial image feature. After the global facial image feature of the current frame image is determined, the features of each of the multiple facial motion units can be determined based on the global facial image feature.
[0059] The characteristics of the motion unit may include but are not limited to: shape characteristics, position characteristics, geometric relationships between different motion units, local texture characteristics of the motion unit
[0060] Specifically, features of multiple key points may be extracted from the global facial image features. The multiple key points may include key points located at preset positions of different motion units, where the preset positions may include, for example, the contour and center of the motion unit.
[0061] The shape characteristics and position characteristics of the motion unit can be determined based on the position characteristics of the key points of the motion unit; the relative geometric relationship characteristics between different motion units can also be determined based on the position characteristics of the key points of different motion units. In addition, the texture characteristics of different motion units can be determined based on the texture characteristics in the global facial features.
[0062] After the characteristics of each motion unit are determined, the motion unit characteristics of each motion unit are quantized according to a preset quantization rule to obtain a quantization value corresponding to the motion unit, that is, an expression parameter corresponding to the motion unit.
[0063] As an implementation method, for each motion unit, a first reference feature corresponding to the maximum expression parameter (e.g., 1) of the motion unit and a second reference feature corresponding to the minimum expression parameter (e.g., 0) of the motion unit can be determined. The actual feature of the motion unit can be compared with the first reference feature and the second reference feature to determine the expression parameter corresponding to the motion unit. Take the parameterization of the degree of eye opening as an example for explanation. The opening feature corresponding to the maximum eye opening is the first reference feature, and the opening parameter can be set to 1. The opening feature corresponding to the closed eye is the second reference feature, and the opening parameter is set to 0. For different facial images, the eye opening feature of the current frame image obtained from the target facial image feature can be compared with the opening feature corresponding to the maximum eye opening and the opening feature corresponding to the minimum eye opening. If it is between the two, the eye opening parameter corresponding to the current frame image can be determined according to the proportional relationship between the eye opening feature of the current frame image and the first reference feature.
[0064] Through the above scheme, the features of different motion units in the facial image can be parameterized to obtain the expression parameters corresponding to the different motion units.
[0065] In some parameterized rules, the order of facial motion units is determined. According to the order of the above motion units provided by the parameterized rules, the expression parameters of the motion units of the target image are sorted to obtain a multi-dimensional expression vector corresponding to the current frame image. Each dimensional expression vector corresponds to the expression parameter of a motion unit. The expression information in the present disclosure may include a multi-dimensional expression vector.
[0066] If only the facial image features of the current frame image are used to determine the expression information of the target object, since there is no image information of the previous and next images as a constraint, the expression information determined only based on the facial image features of the current frame image may have expression information prediction errors.
[0067] For example, when a person laughs, the process may include calmness, slight smile, smile, laugh, and big laugh. The above process may correspond to 5 consecutive frames of images. Assuming that the current frame image is an image of slight smile, if the expression information of the current frame image is determined only based on the facial image features of the image of slight smile, or based on the facial image features of two frames of images corresponding to calmness and slight smile, respectively, the expression information of slight smile in the current frame image may be wrongly predicted as the expression information corresponding to smile or laugh.
[0068] Similarly, if the expression information of the target object corresponding to the current frame image is determined only based on the facial image features that are a fusion of the facial image features corresponding to the image corresponding to a slight smile (current frame image) and the image corresponding to a smile (subsequent image), the expression information corresponding to the current frame image may be mistakenly represented as the expression information corresponding to calmness.
[0069] By fusing the facial image features of the historical image, the current frame image and the subsequent image as the target facial image features of the current frame image, the facial image features of the historical image and the facial image features of the subsequent image are added to the target facial image features, which is equivalent to adding the constraints of the facial image features of the historical image and the facial image features of the subsequent image when determining the target facial image features corresponding to the current frame image. Therefore, a more accurate target facial image feature of the current frame image can be determined, which is beneficial to improving the accuracy of the expression information determined by the target facial image features and the continuity of the expression information corresponding to consecutive frame images.
[0070] The expression information recognition method provided in the present embodiment first obtains the current frame image, the historical images of the current frame image and the subsequent images, wherein the images include the facial image of the target object; then, the facial image features of the current frame image are determined according to the current frame image, the historical images and the subsequent images; finally, the expression information of the target object in the current frame image is determined based on the facial image features, thereby realizing the fusion of the image features of the previous and subsequent frames including the current frame into the target facial image features of the current frame image, and determining the expression information of the current frame image according to the target facial image features of the current frame image after the fusion. Compared with the related art, in which the expression information predicted for each image frame is fused, this solution fuses the facial image features of the historical image, the current frame image, and the subsequent image as the target facial image features of the current frame image, so that the facial image features of the historical image and the facial image features of the subsequent image are added to the target facial image features, which is equivalent to adding the constraints of the facial image features of the historical image and the facial image features of the subsequent image when determining the target facial image features corresponding to the current frame image, thereby determining a more accurate target facial image feature of the current frame image, which is beneficial to improving the accuracy of the expression information determined by the target facial image features, and can also improve the continuity of the expression information corresponding to the determined consecutive frame images. It is beneficial to improve the jitter phenomenon of the expression information of the virtual object in the consecutive frame images when the expression information of multiple consecutive frames of facial images is applied to the virtual object.
[0071] Please refer to Figure 3 , Figure 3 Schematic diagram of the expression information recognition method provided in the embodiment of the present disclosure Figure 2The method of this embodiment can be applied in a terminal device or a server. The expression information recognition method includes:
[0072] S301: Acquire a current frame image, a historical image of the current frame image, and a subsequent image, wherein the image includes a facial image of a target object.
[0073] S302: Input the current frame image, historical images and subsequent images into the expression generation model, and the expression generation model determines the target facial image features of the current frame image based on the current frame image, historical images and subsequent images, and determines the expression information of the target object based on the target facial image features.
[0074] The above-mentioned expression generation model can be various machine learning models, such as a model based on an artificial neural network, a model based on a convolutional neural network, etc.
[0075] In this embodiment, the expression generation model is used to determine and output the expression information of the target object in the current frame image based on the input historical image, current frame image and subsequent image. Specifically, the expression generation model can extract the facial image features corresponding to the historical image, current frame image and subsequent image respectively; then the facial image features corresponding to the historical image, current frame image and subsequent image are fused to obtain the target facial image features of the current frame image. Then, the expression information of the target object in the current frame image is predicted based on the target facial image features.
[0076] The expression generation model may be a model pre-trained using training data. The training data here includes multiple sets of training data. Each set of training data includes multiple frames of images and expression information annotations corresponding to one of the multiple frames of images.
[0077] As an implementation method, the above expression generation model includes a feature extraction network, a feature fusion network and a prediction network; wherein,
[0078] The feature extraction network is used to extract facial image features of the input historical image, current frame image and subsequent image respectively;
[0079] The feature fusion network is used to fuse the above facial image features to obtain the target facial image features corresponding to the current frame image;
[0080] The prediction network is used to predict the expression information of the target object in the current frame image based on the target facial image features.
[0081] The feature extraction network, feature fusion network and prediction network can be trained simultaneously through training data.
[0082] In some optional implementations, the method for identifying facial expression information further includes a step of correcting the facial expression generation model, and the correction step includes:
[0083] First, training data is obtained, and the training data includes multiple groups of training data, wherein each group of training data includes m frames of continuous images and target expression information annotations corresponding to the image of the nth frame in the m frames of continuous images, wherein n and m are both integers, and n is greater than 1 and less than m;
[0084] Secondly, the m frames of continuous images in each set of training data are used as the input of the expression generation model, and the target expression information annotation of the nth frame image in the set of training data is used as the target output. The expression generation model is corrected to obtain a corrected expression generation model.
[0085] In these optional implementations, multiple sets of training data can be used to calibrate the expression generation model, so that the calibrated expression generation model is more stable and accurate. In addition, compared with the correction process of the expression model used in the solution in the related art in which the expression model predicts the expression information of each image and then fuses the expression information prediction results of each image, the above correction process omits the step of calculating the loss of the predicted expression information corresponding to each training sample image, thereby reducing the amount of calculation in the model training process.
[0086] Please refer to Figure 4 and Figure 5 , Figure 4 It is a schematic diagram of the correction process of the above-mentioned expression generation model in this embodiment. Figure 5 Schematic diagram of the correction process of the expression model in the related art.
[0087] like Figure 5 As shown, the expression model in the related art includes a feature extraction network, a prediction network and an expression information fusion network. The feature extraction network can extract facial image features from each input frame image respectively, and the prediction network predicts the predicted expression information results corresponding to each frame image according to the facial image features of each frame image. The expression information fusion network fuses the predicted expression information results corresponding to each frame image to obtain the fused predicted expression information.
[0088] The training data of the expression model may include a plurality of training data. Each set of training data may include a current frame image and a historical image of the current frame image, and expression information annotations corresponding to the current frame image and the historical image, respectively.
[0089] When training the expression model, the expression model can be trained using various training data. The images in each group of training data can be, for example, image i-2, image i-1, and image i. Each frame of the group can be used as input, and the expression information annotation corresponding to the frame can be used as the target output. For the predicted expression information of each frame and the expression information annotation corresponding to the frame, the loss is calculated using a loss function, and the loss is fed back to each level of the expression model network from back to front step by step to adjust the network parameters of each level of the network. For example Figure 5 In the figure, images i-2, i-1 and i are used as training images, and images i-2, i-1 and i correspond to expression information annotations b respectively. i-2 , Expression information annotationb i-1 and expression information annotation b i When training the expression model, image i-2 can be used as input, and the facial image features f of image i-2 can be extracted through the feature extraction network. i-2 . Facial image features f i-2 Input to the prediction network to get the predicted expression information z of image i-2 i-2 , according to the predicted expression information z i-2 , Expression information annotationb i-2 The loss value is calculated by the preset loss function, and the network parameters of each level of the network are adjusted according to the loss value. Similarly, the image i-1 is taken as input, and the facial image feature f of the image i-1 is extracted through the feature extraction network. i-1 . Facial image features f i-1 Input to the prediction network to get the predicted expression information z of image i-1 i-1 , according to the predicted expression information z i-1 , Expression information annotationb i-1 The loss value is calculated with the preset loss function, and the network parameters of each level of the network are adjusted according to the loss value. Take image i as input, and extract the facial image feature f of image i through the feature extraction network. i . Facial image features f i Input into the prediction network to obtain the predicted expression information z of image i i , according to the predicted expression information z i , Expression information annotationb i The loss value is calculated by the preset loss function, and the network parameters of each level of the network are adjusted according to the loss value. Based on the model preliminarily trained with each frame of images, the above image i-2, image i-1 and image i are used as input to fuse the predicted expression information z of each frame of images. i-2 、z i-1 and z i The obtained z i ’As the re-predicted expression information corresponding to image i, then based on the re-predicted expression information z of image i i ’ , the facial expression information annotation b corresponding to image i i The loss is calculated using the preset loss function, and then the parameters of each level of the network are adjusted according to the loss. It can be seen that the training process of the expression model involves two steps of loss calculation and adjustment of network parameters according to the losses of the two steps, so the amount of calculation in the training process of the expression model is relatively large.
[0090] Please refer to Figure 4 The expression generation model provided by the present disclosure includes a feature extraction network, a feature fusion network and a prediction network. The training data may include multiple sets of training data. Each set of training data may include, for example, image i-1, image i and image i+1 arranged in chronological order according to the acquisition time, and the expression information annotations of the images. Image i-1, image i and image i+1 correspond to the expression information annotations b respectively. i-1 , Expression information annotationb i and expression information annotation b i+1 When training the expression generation model, image i-1 can be used as input to obtain the facial image feature f of image i-1. i-1 ; Take image i as input and get the facial image feature f of image i i ; Take image i+1 as input and get the facial image feature f of image i+1 i+1 The feature fusion network fuses the above facial image feature i-1, facial image feature i and facial image feature i+1 to obtain the target facial expression image f of image i i '. Using the target facial image features f i 'Determine the predicted expression information z of the target object in image i i . Based on the predicted expression information z i and the facial expression information annotation b of image i i The loss is calculated by the loss function, and the network parameters of each level of the network are adjusted step by step from back to front according to the loss.
[0091] The above training process disclosed herein calculates the loss in only one step, and adjusts the network parameters of each level of the expression generation model according to the loss of this step.
[0092] contrast Figure 5 and Figure 4 The training process, Figure 4 It is shown that one step of loss calculation is reduced during the training process of the expression generation model, thereby reducing the amount of calculation during the training process of the expression generation model.
[0093] In some optional implementations, the target expression information annotation corresponding to the n-th frame image can be obtained by the following steps:
[0094] The initial expression information annotations corresponding to the m frames of continuous images are low-pass filtered to obtain the target expression information annotations corresponding to the n-th frame of the filtered image.
[0095] The above-mentioned low-pass filtering may include, but is not limited to: performing low-pass filtering by discrete cosine transform or discrete Fourier transform.
[0096] Taking the filtering of m frames of continuous images by discrete cosine transform as an example, each frame of image can correspond to one initial expression information annotation. The initial expression information annotation can be an N-dimensional vector. In the N-dimensional vectors corresponding to the m frames of image, vectors of the same dimension correspond to the same facial motion unit. For any one-dimensional vector, m vectors of this dimension can be arranged in the order of each frame of image to form a data sequence of the vector of this dimension. The low-pass filtering process is explained below using discrete cosine transform as an example. The m data sequences of the vector of this dimension are subjected to discrete cosine transform to obtain the frequency spectrum corresponding to the m data sequences. The last dimension in the frequency spectrum is discarded. The frequency spectrum of the m data sequences with the last dimension spectrum discarded is inversely transformed, and the inverse transformation result is used as the target expression information annotation corresponding to the vector of this dimension of the nth frame of image.
[0097] Repeat the above low-pass filtering process of the m data sequences corresponding to each dimensional vector to obtain the target expression information labeling after low-pass filtering corresponding to each dimensional vector. Arrange the target expression information labeling corresponding to each dimensional vector according to the preset order of each dimensional vector to obtain the target expression information labeling of the nth frame image.
[0098] By performing low-pass filtering on the initial expression information annotations corresponding to the m frames of training images, anomalies in the initial expression information annotations can be filtered out, which can reduce the adverse effects of abnormal annotations in the training data caused by manual initial expression information annotations on facial images during the expression generation model training process, and is conducive to improving the efficiency of expression generation model training.
[0099] Please refer to Figure 6, which shows a schematic diagram of determining the expression information corresponding to multiple frames of an image sequence. The image sequence may include, for example, image 1, image 2, image 3, image 4, and image 5. Image 1, image 2, and image 3; image 2, image 3, and image 4; image 3, image 4, and image 5 may be respectively input into the expression generation model as a group. The feature extraction network in the expression generation model extracts the target image features corresponding to image 1, image 2, image 3, image 4, and image 5 respectively: feature 1, feature 2, feature 3, feature 4, and feature 5. Feature 1, feature 2, and feature 3 are fused through a feature fusion network to obtain target image feature feature 2' of image 2. Feature 2, feature 3, and feature 4 are fused through a feature fusion network to obtain target image feature feature 3' of image 3. Feature 3, feature 4, and feature 5 are fused through a feature fusion network to obtain target image feature feature 4' of image 4. The target image feature feature 2' may be predicted by using a prediction network to obtain predicted expression information 2' corresponding to image 2. The target image feature feature 3' is predicted by using a prediction network to obtain predicted expression information 3' corresponding to image 3. The prediction network is used to predict along with the target image feature 4' to obtain the predicted expression information 4' of the image feature 4. The predicted expression information of the images 2, 3, and 4 obtained in the above manner has good continuity. When the above expression information is applied to the virtual object, the continuity of the expression information between the consecutive frames of the virtual object is also good.
[0100] In some embodiments, for any image frame, the number of historical image frames included in the historical image and the number of subsequent image frames included in the subsequent image can be preset, and then the number of image frames involved in determining the target facial image feature of the image frame can be determined. Assuming that the number of historical image frames included in the historical image is t1, and the number of subsequent image frames included in the subsequent image is t2, the target facial image feature of the image frame can be determined by the facial image feature of the target object in the t1+t2+1 frame image. The length of the preset queue can be determined according to the above number of frames. For example, the length of the above preset queue can be t1+t2+1. Construct a preset queue with a length of t1+t2+1. The continuous multiple frames of the target object can be sequentially input into the above feature extraction network to obtain the facial image features corresponding to each frame image. The facial image features corresponding to each frame image are sequentially input into the above preset queue in the order in which each frame image corresponds. Each facial image feature input into the preset queue can be regarded as an element of the preset queue. For the kth image frame in the continuous image frames, the target facial image features of the kth image frame need to be integrated with the image features of the t1th historical image frame, the facial image features of the t2th subsequent image frame and the facial image features of the kth image frame itself. Then, the facial image features corresponding to the (k-t1)th image frame to the target image features corresponding to the (k+t2)th image frame can be sequentially input into the preset queue in the order of the frames. After the preset queue is filled, the elements in the queue can be fused to obtain the target facial image features of the target object corresponding to the kth image frame. After the target facial image features of the kth image frame are obtained, the facial image features corresponding to the (k-t1)th image frame can be dequeued. Then, the facial image features corresponding to the (k+1+t2)th image frame are input to the end of the preset queue. The target facial image features of the (k+1)th image frame are calculated. Here, t1 is an integer greater than or equal to 1 and less than k. t2 is an integer greater than or equal to 1. k is an integer greater than 1. If the preset queue is not filled, the elements in the preset queue are not fused.
[0101] and Figure 2 Compared with the expression information recognition method provided by the illustrated embodiment, the method provided in this embodiment uses an expression generation model to determine the target facial image features of the current frame image that integrates the image features of historical images, the current frame image, and subsequent images, and predicts the expression information of the target object of the current frame image from the target facial image features, which can simplify the complexity of determining the expression information of the target object in the current frame image.
[0102] In some optional implementations, the feature fusion network is a one-dimensional convolutional network.
[0103] The expression information fusion network in the related art is a fully connected network. Figure 5The expression information fusion network in the expression model shown is a fully connected network. Since the data dimension of facial image features is higher than the dimension of predicted expression information, if the feature fusion network of facial image features uses a fully connected network like the expression information fusion network, it will result in a large number of parameters and calculations. Figure 7 As shown, Figure 7 Schematic diagram of the calculation of the fully connected network.
[0104] Fig. 8A and Figure 8B Schematic diagram of one-dimensional convolutional network calculation.
[0105] When using the fully connected layer for dimensionality reduction calculation, the target facial image features need to be organized into a one-dimensional vector, such as Figure 7 As shown, the target facial image features are organized into a one-dimensional vector f1 i-1 、f2 i-1 …f m i-1 、f1 i 、f2 i …f m i 、f1 i+1 、f2 i+1 …f m i +1 The output of the fully connected layer can be the predicted expression information z1 corresponding to the m frames of images i 、z2 i …z m i When the predicted expression information corresponding to the m frames of images is determined by the one-dimensional vector, for the predicted expression information corresponding to each frame of image, each component vector in the one-dimensional vector participates in the calculation.
[0106] In order to simplify the calculation, the feature fusion network can be set as a one-dimensional convolutional network. Fig. 8A As shown, the target facial image features can be organized into a matrix form, such as an m×3 target facial image feature matrix. The m×3 matrix is passed through a one-dimensional convolutional network to obtain the predicted expression information z1 corresponding to the m frames of images. i 、z2 i …z m i .
[0107] Figure 8B It converts the operation of the target facial image feature matrix and the one-dimensional convolution matrix into another display method for easy comparison and Figure 7 The number of computations for the fully connected network shown. Figure 8BAs shown, for the predicted expression information corresponding to each frame image, only the previous frame image corresponding to the frame image, the frame image, and the frame image after the frame image participate in the calculation. For the predicted expression information corresponding to each frame image, it is only necessary to perform convolution calculation with the one-dimensional convolutional network through the image features of multiple frames related to the frame image. Figure 7 Compared with using a fully connected network to fuse features, using a one-dimensional convolutional network to fuse image features reduces a large number of connections between neurons, and reduces the amount of bias parameters and calculations.
[0108] Fig. 8A The bias parameter in the one-dimensional convolutional network shown can be W. If the bias parameter in the convolutional layer is ignored and the one-dimensional convolutional network is used to determine the predicted expression information for the target facial image features, the amount of calculation can be reduced to about 1 / C of the original amount compared to the fully connected network, where C is the feature dimension of the target image.
[0109] After obtaining the above expression information corresponding to the multiple frames of images, each of the above expression information can be applied to the virtual object, thereby obtaining a facial expression with good coherence of the virtual object. Specifically, each dimensional expression vector in the expression information composed of the multi-dimensional expression vector corresponds to a motion unit. Referring to the motion unit division of the target object image, the face of the virtual object can also be divided into multiple motion units, and the motion parameters corresponding to each motion unit are set according to the expression information, so that the facial expression of the virtual object can be generated.
[0110] Corresponding to the expression information recognition method in the above embodiment, Fig. 9 This is a structural block diagram of the facial expression information recognition device provided by the embodiment of the present disclosure. For the convenience of explanation, only the parts related to the embodiment of the present disclosure are shown. Fig. 9 , the device 90 includes: an acquisition unit 901 and a prediction unit 902. Among them,
[0111] An acquisition unit 901 is used to acquire a current frame image, a historical image of the current frame image, and a subsequent image, wherein the image includes a facial image of a target object;
[0112] The prediction unit 902 is used to determine the target facial image features of the current frame image according to the current frame image, historical images and subsequent images; and determine the expression information of the target object in the current frame image based on the target facial image features.
[0113] In one embodiment of the present disclosure, the prediction unit 902 is specifically used to: respectively determine the facial image features of the current frame image, the historical image, and the subsequent image; and fuse the facial image features of the current frame image, the historical image, and the subsequent image to obtain the target facial image features of the current frame image.
[0114] In one embodiment of the present disclosure, the prediction unit 902 is specifically configured to:
[0115] Determine motion unit features corresponding to each of the plurality of facial motion units according to the facial image features;
[0116] The expression information of the target object in the current frame image is determined according to the multiple motion unit features.
[0117] In one embodiment of the present disclosure, the prediction unit 902 is specifically configured to:
[0118] The current frame image, historical images and subsequent images are input into the expression generation model, which determines the target facial image features of the current frame image based on the current frame image, historical images and subsequent images, and determines the expression information of the target object based on the target facial image features.
[0119] In one embodiment of the present disclosure, the expression generation model includes a feature extraction network, a feature fusion network and a prediction network; wherein
[0120] The feature extraction network is used to extract facial image features of the input historical image, current frame image and subsequent image respectively;
[0121] The feature fusion network is used to fuse the facial image features extracted by the image feature network to obtain the target facial image features corresponding to the current frame image;
[0122] The prediction network is used to predict the expression information of the target object in the current frame image based on the target facial image features.
[0123] In one embodiment of the present disclosure, the feature fusion network is a one-dimensional convolutional network.
[0124] In one embodiment of the present disclosure, the facial expression information recognition device further includes a correction unit (not shown in the figure). The training unit is used to:
[0125] Acquire training data, the training data includes multiple groups of training data, wherein each group of training data includes m frames of continuous images and target expression information annotations corresponding to an image of an nth frame in the m frames of continuous images, wherein n and m are both integers, and n is greater than 1 and less than m;
[0126] The m frames of continuous images in each set of training data are used as the input of the expression generation model, the target expression information annotation of the nth frame image in the set of training data is used as the target output, the expression generation model is corrected, and a corrected expression generation model is obtained.
[0127] In one embodiment of the present disclosure, the correction unit is specifically used to determine the target expression information label corresponding to the n-th frame image based on the following steps:
[0128] The initial expression information annotations corresponding to the m frames of continuous images are low-pass filtered to obtain the target expression information annotations corresponding to the n-th frame of the filtered image.
[0129] In one embodiment of the present disclosure, the historical image includes a frame image previous to the current frame image, and the subsequent image includes a frame image subsequent to the current frame image.
[0130] In order to implement the above embodiment, the embodiment of the present disclosure also provides an electronic device.
[0131] refer to Fig.10 , which shows a schematic diagram of the structure of an electronic device 1000 suitable for implementing the embodiment of the present disclosure, and the electronic device 1000 may be an extended reality device or a terminal device. The terminal device may include but is not limited to mobile terminals such as mobile phones, laptop computers, digital broadcast receivers, personal digital assistants (PDAs), tablet computers (Portable Android Devices, PADs), portable multimedia players (PMPs), vehicle terminals (such as vehicle navigation terminals), etc., and fixed terminals such as digital TVs, desktop computers, etc. Fig.10 The electronic device shown is only an example and should not bring any limitation to the functions and scope of use of the embodiments of the present disclosure.
[0132] like Fig.10 As shown, the electronic device 1000 may include a processing device (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 to a random access memory (RAM) 1003. Various programs and data required for the operation of the electronic device 1000 are also stored in the RAM 1003. The processing device 1001, the ROM 1002, and the RAM 1003 are connected to each other via a bus 1004. An input / output (I / O) interface 1005 is also connected to the bus 1004.
[0133] Typically, the following devices may be connected to the I / O interface 1005: input devices 1006 including, for example, a touch screen, a touch pad, a keyboard, a mouse, a camera, a microphone, an accelerometer, a gyroscope, etc.; output devices 1007 including, for example, a liquid crystal display (LCD), a speaker, a vibrator, etc.; storage devices 1008 including, for example, a magnetic tape, a hard disk, etc.; and communication devices 1009. The communication device 1009 may allow the electronic device 1000 to communicate with other devices wirelessly or by wire to exchange data. Although Fig.10 The electronic device 1000 is shown with various devices, but it should be understood that it is not required to implement or possess all the devices shown. More or fewer devices may be implemented or possessed instead.
[0134] In particular, according to an embodiment of the present disclosure, the process described above with reference to the flowchart can be implemented as a computer software program. For example, an embodiment of the present disclosure includes a computer program product, which includes a computer program carried on a computer-readable medium, and the computer program contains program code for executing the method shown in the flowchart. In such an embodiment, the computer program can be downloaded and installed from a network through a communication device 1009, or installed from a storage device 1008, or installed from a ROM 1002. When the computer program is executed by the processing device 1001, the above-mentioned functions defined in the method of the embodiment of the present disclosure are executed.
[0135] It should be noted that the computer-readable medium disclosed above may be a computer-readable signal medium or a computer-readable storage medium or any combination of the above two. The computer-readable storage medium may be, for example, but not limited to, an electrical, magnetic, optical, electromagnetic, infrared, or semiconductor system, device or device, or any combination of the above. More specific examples of computer-readable storage media may include, but are not limited to: an electrical connection with one or more wires, a portable computer disk, a hard disk, a random access memory (RAM), a read-only memory (ROM), an erasable programmable read-only memory (EPROM or flash memory), an optical fiber, a portable compact disk read-only memory (CD-ROM), an optical storage device, a magnetic storage device, or any suitable combination of the above. In the present disclosure, a computer-readable storage medium may be any tangible medium containing or storing a program that may be used by or in combination with an instruction execution system, device or device. In the present disclosure, a computer-readable signal medium may include a data signal propagated in a baseband or as part of a carrier wave, in which a computer-readable program code is carried. This propagated data signal may take a variety of forms, including but not limited to an electromagnetic signal, an optical signal, or any suitable combination of the above. The computer readable signal medium may also be any computer readable medium other than a computer readable storage medium, which may send, propagate or transmit a program for use by or in conjunction with an instruction execution system, apparatus or device. The program code contained on the computer readable medium may be transmitted using any suitable medium, including but not limited to: wires, optical cables, RF (radio frequency), etc., or any suitable combination of the above.
[0136] The computer-readable medium may be included in the electronic device, or may exist independently without being incorporated into the electronic device.
[0137] The computer-readable medium carries one or more programs. When the one or more programs are executed by the electronic device, the electronic device executes the method shown in the above embodiment.
[0138] Computer program code for performing the operations of the present disclosure may be written in one or more programming languages or a combination thereof, including object-oriented programming languages, such as Java, Smalltalk, C++, and conventional procedural programming languages, such as "C" or similar programming languages. The program code may be executed entirely on the user's computer, partially on the user's computer, as an independent software package, partially on the user's computer and partially on a remote computer, or entirely on a remote computer or server. In the case of a remote computer, the remote computer may 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 may be connected to an external computer (e.g., via the Internet using an Internet service provider).
[0139] The flow chart and block diagram in the accompanying drawings illustrate the possible architecture, function and operation of the system, method and computer program product according to various embodiments of the present disclosure. In this regard, each square box in the flow chart or block diagram can represent a module, a program segment or a part of a code, and the module, the program segment or a part of the code contains one or more executable instructions for realizing the specified logical function. It should also be noted that in some implementations as replacements, the functions marked in the square box can also occur in a sequence different from that marked in the accompanying drawings. For example, two square boxes represented in succession can actually be executed substantially in parallel, and they can sometimes be executed in the opposite order, depending on the functions involved. It should also be noted that each square box in the block diagram and / or flow chart, and the combination of the square boxes in the block diagram and / or flow chart can be implemented with a dedicated hardware-based system that performs a specified function or operation, or can be implemented with a combination of dedicated hardware and computer instructions.
[0140] The units involved in the embodiments described in the present disclosure may be implemented by software or hardware. The name of a unit does not limit the unit itself in some cases. For example, an acquisition unit may also be described as a "unit for acquiring a current frame image, a historical image of the current frame image, and a subsequent image".
[0141] The functions described above herein may be performed at least in part by one or more hardware logic components. For example, without limitation, exemplary types of hardware logic components that may be used include: field programmable gate arrays (FPGAs), application specific integrated circuits (ASICs), application specific standard products (ASSPs), systems on chips (SOCs), complex programmable logic devices (CPLDs), and the like.
[0142] In the context of the present disclosure, a machine-readable medium may be a tangible medium that may contain or store a program for use by or in conjunction with an instruction execution system, device, or equipment. A machine-readable medium may be a machine-readable signal medium or a machine-readable storage medium. A machine-readable medium may include, but is not limited to, an electronic, magnetic, optical, electromagnetic, infrared, or semiconductor system, device, or equipment, or any suitable combination of the foregoing. A more specific example of a machine-readable storage medium may include an electrical connection based on one or more lines, a portable computer disk, a hard disk, a random access memory (RAM), a read-only memory (ROM), an erasable programmable read-only memory (EPROM or flash memory), an optical fiber, a portable compact disk read-only memory (CD-ROM), an optical storage device, a magnetic storage device, or any suitable combination of the foregoing.
[0143] In a first aspect, according to one or more embodiments of the present disclosure, a method for identifying facial expression information is provided, comprising:
[0144] Acquire a current frame image, a historical image of the current frame image, and a subsequent image, wherein the image includes a facial image of a target object;
[0145] According to the current frame image, historical images and subsequent images, target facial image features of the current frame image are determined; and based on the target facial image features, expression information of the target object in the current frame image is determined.
[0146] According to one or more embodiments of the present disclosure, determining target facial image features of a current frame image according to a current frame image, historical images, and subsequent images includes:
[0147] Determine facial image features of a current frame image, a historical image, and a subsequent image respectively;
[0148] The facial image features of the current frame image, historical images and subsequent images are fused to obtain the target facial image features of the current frame image.
[0149] According to one or more embodiments of the present disclosure, determining the expression information of the target object in the current frame image based on the target facial image features includes:
[0150] Determine motion unit features corresponding to each of the plurality of facial motion units according to the facial image features;
[0151] The expression information of the target object in the current frame image is determined according to the multiple motion unit features.
[0152] According to one or more embodiments of the present disclosure, target facial image features of the current frame image are determined based on the current frame image, historical images and subsequent images; and expression information of the target object in the current frame image is determined based on the target facial image features, including: inputting the current frame image, historical images and subsequent images into an expression generation model, and the expression generation model determines the target facial image features of the current frame image based on the current frame image, historical images and subsequent images, and determines the expression information of the target object based on the target facial image features.
[0153] According to one or more embodiments of the present disclosure, the expression generation model includes a feature extraction network, a feature fusion network and a prediction network; wherein
[0154] The feature extraction network is used to extract facial image features of the input historical image, current frame image and subsequent image respectively;
[0155] The feature fusion network is used to fuse the features of each facial image to obtain the target facial image features corresponding to the current frame image;
[0156] The prediction network is used to predict the expression information of the target object in the current frame image based on the target facial image features.
[0157] According to one or more embodiments of the present disclosure, the feature fusion network includes a one-dimensional convolutional network.
[0158] According to one or more embodiments of the present disclosure, the expression information recognition method further includes:
[0159] Acquire training data, the training data includes multiple groups of training data, wherein each group of training data includes m frames of continuous images and target expression information annotations corresponding to an image of an nth frame in the m frames of continuous images, wherein n and m are both integers, and n is greater than 1 and less than m;
[0160] The m frames of continuous images in each set of training data are used as the input of the expression generation model, the target expression information annotation of the nth frame image in the set of training data is used as the target output, the expression generation model is corrected, and a corrected expression generation model is obtained.
[0161] According to one or more embodiments of the present disclosure, the target expression information annotation corresponding to the nth frame image is obtained by the following steps:
[0162] The initial expression information annotations corresponding to the m frames of continuous images are low-pass filtered to obtain the target expression information annotations corresponding to the n-th frame of the filtered image.
[0163] According to one or more embodiments of the present disclosure, the historical image includes a previous frame image of the current frame image, and the subsequent image includes a subsequent frame image of the current frame image.
[0164] In a second aspect, according to one or more embodiments of the present disclosure, there is provided an expression information recognition device, comprising:
[0165] An acquisition unit, used to acquire a current frame image, a historical image of the current frame image, and a subsequent image, wherein the image includes a facial image of a target object;
[0166] The prediction unit is used to determine the target facial image features of the current frame image according to the current frame image, historical images and subsequent images; and determine the expression information of the target object in the current frame image based on the target facial image features.
[0167] According to one or more embodiments of the present disclosure, the prediction unit is specifically used to: respectively determine the facial image features of the current frame image, the historical image, and the subsequent image; and fuse the facial image features of the current frame image, the historical image, and the subsequent image to obtain the target facial image features of the current frame image.
[0168] According to one or more embodiments of the present disclosure, the prediction unit is specifically configured to:
[0169] Determine motion unit features corresponding to each of the plurality of facial motion units according to the facial image features;
[0170] The expression information of the target object in the current frame image is determined according to the multiple motion unit features.
[0171] According to one or more embodiments of the present disclosure, the prediction unit is specifically configured to:
[0172] The current frame image, historical images and subsequent images are input into the expression generation model, which determines the target facial image features of the current frame image based on the current frame image, historical images and subsequent images, and determines the expression information of the target object based on the target facial image features.
[0173] According to one or more embodiments of the present disclosure, the expression generation model includes a feature extraction network, a feature fusion network and a prediction network; wherein
[0174] The feature extraction network is used to extract facial image features of the input historical image, current frame image and subsequent image respectively;
[0175] The feature fusion network is used to fuse the features of each facial image to obtain the target facial image features corresponding to the current frame image;
[0176] The prediction network is used to predict the expression information of the target object in the current frame image based on the target facial image features.
[0177] According to one or more embodiments of the present disclosure, the feature fusion network includes a one-dimensional convolutional network.
[0178] According to one or more embodiments of the present disclosure, the facial expression information recognition apparatus further includes a correction unit.
[0179] The calibration unit is used to:
[0180] Acquire training data, the training data includes multiple groups of training data, wherein each group of training data includes m frames of continuous images and target expression information annotations corresponding to an image of an nth frame in the m frames of continuous images, wherein n and m are both integers, and n is greater than 1 and less than m;
[0181] The m frames of continuous images in each set of training data are used as the input of the expression generation model, the target expression information annotation of the nth frame image in the set of training data is used as the target output, the expression generation model is corrected, and a corrected expression generation model is obtained.
[0182] According to one or more embodiments of the present disclosure, the correction unit is specifically used to determine the target expression information annotation corresponding to the n-th frame image based on the following steps:
[0183] The initial expression information annotations corresponding to the m frames of continuous images are low-pass filtered to obtain the target expression information annotations corresponding to the n-th frame of the filtered image.
[0184] According to one or more embodiments of the present disclosure, the historical image includes a previous frame image of the current frame image, and the subsequent image includes a subsequent frame image of the current frame image.
[0185] In a third aspect, according to one or more embodiments of the present disclosure, there is provided an electronic device, comprising: at least one processor and a memory;
[0186] Memory stores computer-executable instructions;
[0187] At least one processor executes the computer-executable instructions stored in the memory, so that the at least one processor executes the expression information recognition method as described in the first aspect and various possible designs of the first aspect.
[0188] In a fourth aspect, according to one or more embodiments of the present disclosure, a computer-readable storage medium is provided, in which computer execution instructions are stored. When a processor executes the computer execution instructions, the expression information recognition method as described in the first aspect and various possible designs of the first aspect are implemented.
[0189] In a fifth aspect, according to one or more embodiments of the present disclosure, a computer program product is provided, including a computer program, which, when executed by a processor, implements the expression information recognition method of the first aspect and various possible designs of the first aspect.
[0190] The above description is only a preferred embodiment of the present disclosure and an explanation of the technical principles used. Those skilled in the art should understand that the scope of disclosure involved in the present disclosure is not limited to the technical solutions formed by a specific combination of the above technical features, but should also cover other technical solutions formed by any combination of the above technical features or their equivalent features without departing from the above disclosed concept. For example, the above features are replaced with the technical features with similar functions disclosed in the present disclosure (but not limited to) by each other to form a technical solution.
[0191] In addition, although each operation is described in a specific order, this should not be understood as requiring these operations to be performed in the specific order shown or in a sequential order. Under certain circumstances, multitasking and parallel processing may be advantageous. Similarly, although some specific implementation details are included in the above discussion, these should not be interpreted as limiting the scope of the present disclosure. Some features described in the context of a separate embodiment can also be implemented in a single embodiment in combination. On the contrary, the various features described in the context of a single embodiment can also be implemented in multiple embodiments individually or in any suitable sub-combination mode.
[0192] Although the subject matter has been described in language specific to structural features and / or methodological logical actions, 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. On the contrary, the specific features and actions described above are merely example forms of implementing the claims.
Claims
1. A method for identifying facial expression information, the method being applied to a virtual object facial expression simulation scene, comprising: Acquire a current frame image, a historical image of the current frame image, and a subsequent image, wherein the image includes a facial image of a target object; Determine the target facial image features of the current frame image according to the current frame image, the historical images and the subsequent images; and determine the expression information of the target object in the current frame image based on the target facial image features; For any frame image in the continuous image frames, determining the target facial image features of the current frame image according to the current frame image, the historical images and the subsequent images includes: Based on the number of historical image frames included in the preset historical image and the number of subsequent image frames included in the subsequent image, determining the number of image frames involved in the target facial image feature of the current image frame; Determining the length of the preset queue according to the number of frames of the image involved in the target facial image feature of the current image frame; Inputting facial image features corresponding to adjacent continuous frames of images of the target object into a feature extraction network in order of corresponding frames, obtaining facial image features corresponding to each frame, and the image features of adjacent frames are used to correct deviations that occur when extracting image features from images; Inputting facial image features corresponding to each frame image into the preset queue in sequence according to the order in which each frame image corresponds to each other; If the preset queue is full, the facial image features corresponding to each frame image in the preset queue are fused through a feature fusion network to obtain the target facial image features of the current frame image; the feature fusion network is a one-dimensional convolutional network; The first element in the preset queue is dequeued, and the facial image features of the target object of the next frame image corresponding to the end of the original preset queue are inputted into the end of the preset queue, and it is determined whether the new preset queue is full; if so, based on the new preset queue length, the step of fusing the facial image features corresponding to each frame image in the new preset queue is performed; If the preset queue is not full, the elements in the preset queue are not merged.
2. The method according to claim 1, characterized in that The step of determining the expression information of the target object in the current frame image based on the target facial image features includes: Determining motion unit features corresponding to each of the plurality of facial motion units according to the facial image features; The expression information of the target object in the current frame image is determined according to the multiple motion unit features.
3. The method according to claim 1, characterized in that The step of determining target facial image features of the current frame image according to the current frame image, historical images, and subsequent images; and determining expression information of a target object in the current frame image based on the target facial image features includes: The current frame image, historical images and subsequent images are input into an expression generation model, and the expression generation model determines the target facial image features of the current frame image based on the current frame image, historical images and subsequent images, and determines the expression information of the target object based on the target facial image features.
4. The method according to claim 3, characterized in that The expression generation model includes a feature extraction network, a feature fusion network and a prediction network; wherein The feature extraction network is used to extract facial image features of the input historical image, the current frame image and the subsequent image respectively; The feature fusion network is used to fuse the facial image features extracted by the image feature network to obtain the target facial image features corresponding to the current frame image; The prediction network is used to predict the expression information of the target object in the current frame image according to the target facial image features.
5. The method according to claim 3, characterized in that: The method further comprises: Acquire training data, wherein the training data includes multiple groups of training data, wherein each group of training data includes m frames of continuous images and target expression information annotations corresponding to an image of an nth frame in the m frames of continuous images, wherein n and m are both integers, and n is greater than 1 and less than m; The m frames of continuous images in each set of training data are used as the input of the expression generation model, the target expression information annotation of the nth frame image in the set of training data is used as the target output, the expression generation model is corrected, and a corrected expression generation model is obtained.
6. The method according to claim 5, characterized in that The target expression information annotation corresponding to the nth frame image is obtained by the following steps: The initial expression information annotations corresponding to the m frames of continuous images are low-pass filtered to obtain the target expression information annotations corresponding to the n-th frame of the filtered image.
7. The method according to any one of claims 1 to 6, characterized in that The historical image includes a frame image before the current frame image, and the subsequent image includes a frame image after the current frame image.
8. An expression information recognition device, the device being applied to a virtual object expression simulation scene, comprising: An acquisition unit, used to acquire a current frame image, a historical image of the current frame image, and a subsequent image, wherein the image includes a facial image of a target object; A prediction unit, configured to determine target facial image features of the current frame image according to the current frame image, historical images, and subsequent images; and determine expression information of a target object in the current frame image based on the target facial image features; For any frame image in the continuous image frames, the prediction unit is specifically used to: The step of determining target facial image features of the current frame image according to the current frame image, the historical images, and the subsequent images includes: Based on the number of historical image frames included in the preset historical image and the number of subsequent image frames included in the subsequent image, determining the number of image frames involved in the target facial image feature of the current image frame; Determining the length of the preset queue according to the number of frames of the image involved in the target facial image feature of the current image frame; Inputting facial image features corresponding to adjacent continuous frames of images of the target object into a feature extraction network in order of corresponding frames, obtaining facial image features corresponding to each frame, and the image features of adjacent frames are used to correct deviations that occur when extracting image features from images; Inputting facial image features corresponding to each frame image into the preset queue in sequence according to the order in which each frame image corresponds to each other; If the preset queue is full, the facial image features corresponding to each frame image in the preset queue are fused through a feature fusion network to obtain the target facial image features of the current frame image; the feature fusion network is a one-dimensional convolutional network; The first element in the preset queue is dequeued, and the facial image features of the target object of the next frame image corresponding to the end of the original preset queue are inputted into the end of the preset queue, and it is determined whether the new preset queue is full; if so, based on the new preset queue length, the step of fusing the facial image features corresponding to each frame image in the new preset queue is performed; If the preset queue is not full, the elements in the preset queue are not merged.
9. An electronic device, characterized in that: include: Processor and memory; The memory stores computer-executable instructions; The processor executes the computer-executable instructions stored in the memory, so that the processor executes the expression information recognition method as described in any one of claims 1 to 7.
10. A computer-readable storage medium, characterized in that: The computer-readable storage medium stores computer-executable instructions. When the processor executes the computer-executable instructions, the expression information recognition method according to any one of claims 1 to 7 is implemented.
Citation Information
Patent Citations
Driver road rage real-time identification and warning method based on facial features
CN105740767A
Emotion intensity estimation method and system based on deep learning
CN110188610A
Multi-domain fusion micro-expression detection method based on motion unit
CN111582212A
Positioning method and device, automatic driving vehicle, electronic equipment and storage medium
CN111649739A
Behavior analysis method of target in video stream, terminal equipment and medium
CN112381071A
Cited By
Expression information identification method and apparatus, device, readable storage medium, and product
EP4654160A1
Expression information identification method and apparatus, device, readable storage medium, and product
WO2024152723A1
