Video generation method and device, equipment and medium

By using the trained noise prediction model to capture and restore the target pose and appearance of video frames, the problem of inter-frame feature consistency in video generation is solved and the visual quality of the video is significantly improved.

CN118799460APending Publication Date: 2024-10-18CHINA MOBILE COMM LTD RES INST +1
View PDF 0 Cites 3 Cited by

Patent Information

Application Number
CN202410016562.9
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2024-01-05
Publication Date
2024-10-18

AI Technical Summary

Technical Problem

In the process of generating videos with existing video generation methods, it is difficult to ensure the feature consistency between image frames, resulting in a decrease in the visual quality of the video.

Method used

The trained first noise prediction model and the second noise prediction model are used to generate denoised frame images by capturing the target pose and restoring the target appearance, thereby improving the visual quality of the video.

Benefits of technology

By improving the model's ability to capture texture details and temporal features, the feature consistency and visual quality between video frames are significantly improved.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN118799460A_ABST
    Figure CN118799460A_ABST
Patent Text Reader

Abstract

The invention provides a video generation method and device, equipment and a medium. The method provided by the invention comprises the following steps: for a frame image in a first video, inputting the frame image, a first target appearance image and multiple frames of first dense attitude images into a video generation model to obtain first noise; wherein the first target appearance image is a figure image with a first target appearance, the multiple frames of first dense attitude images comprise continuous multiple frames of figure images related to a first target attitude, and the video generation model comprises a trained first noise prediction model and a trained second noise prediction model; the trained first noise prediction model is used for capturing a target attitude, and the trained second noise prediction model is used for recovering a target appearance; performing denoising processing on the first noise to obtain a denoised frame image; and generating a second video according to the denoised frame image. According to the method, the visual quality of the generated video can be greatly improved.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present invention relates to the field of artificial intelligence technology, and in particular to a video generation method, device, equipment and medium. Background Art

[0002] Given a human-controllable posture description (e.g., a continuous sequence of human posture images) and an appearance description (e.g., a single human foreground and background image) as input, human video generation aims to synthesize a new video with corresponding actions and appearances. This human-controllable high-quality human video synthesis technology has broad application prospects in various fields such as speaker generation, animation creation, and even expanding deep learning datasets.

[0003] According to the data method of introducing the target posture information, the human body video generation methods can be divided into two categories. One is to use the human image with the target posture as a guide to change the posture of the person in the human image with the target appearance. The other method is to directly use the target posture data, such as the key points of the human skeleton, as a guide to change the posture of the person in the human image with the target appearance.

[0004] The above-mentioned human body video generation method often has the following problems: since the process of generating videos is actually a process of generating image frames one by one, the data input into the generation model is inconsistent, which easily leads to differences in features such as details between the generated frames. In other words, it is difficult to ensure the consistency of features between the image frames in the generated video, such as features such as faces, hand details and clothing appearance, which seriously affects the visual quality of the final generated video. Summary of the invention

[0005] The purpose of the present invention is to provide a video generation method, device, equipment and medium to solve the problem that it is difficult to ensure the consistency of features between image frames in a video generated by the existing video generation method, thereby seriously affecting the visual quality of the final generated video.

[0006] In order to achieve the above object, in a first aspect, the present invention provides a video generation method, comprising:

[0007] For a frame image in a first video, the frame image, a first target appearance image and a plurality of first dense posture images are input into a video generation model to obtain a first noise; wherein the first target appearance image is a person image having a first target appearance, the plurality of first dense posture images include a plurality of consecutive frames of person images related to the first target posture, the video generation model includes a trained first noise prediction model and a trained second noise prediction model, the trained first noise prediction model is used to capture the target posture, and the trained second noise prediction model is used to restore the target appearance;

[0008] Performing denoising processing on the first noise to obtain the denoised frame image;

[0009] A second video is generated based on the denoised frame image.

[0010] In some embodiments, the method further comprises:

[0011] Acquire a training data set; wherein the training data set includes a target appearance image, a target posture image, and multiple frames of dense posture images of each target person in the third video;

[0012] Using the training data set, respectively training a first noise prediction model and a second noise prediction model to obtain the trained first noise prediction model and the trained second noise prediction model;

[0013] The trained first noise prediction model and the trained second noise prediction model are set in parallel to obtain the video generation model.

[0014] In some embodiments, obtaining a training data set includes:

[0015] For each target person in the third video, obtaining the target appearance image and the target posture image of the target person in the third video;

[0016] The target posture image and N frames of images before and after the target posture image are determined as the multi-frame dense posture images, where N is a positive integer.

[0017] In some embodiments, the using the training data set to respectively train the first noise prediction model and the second noise prediction model to obtain the trained first noise prediction model and the trained second noise prediction model includes:

[0018] Performing noise processing on the second target posture image to obtain a noisy second target posture image;

[0019] Inputting the noisy second target pose image, a group of multi-frame second dense pose images and multi-frame second target appearance images into the first noise prediction model to obtain predicted second noise, wherein the multi-frame second dense pose images include the second target pose image and M frames of images before and after the second target pose image, where M is a positive integer; the second target pose image and the multi-frame second target appearance images belong to the same target person;

[0020] Inputting the noisy second target posture image, Y groups of multi-frame second dense posture images and a single-frame second target appearance image into the second noise prediction model to obtain a predicted third noise, wherein Y is a positive integer, and the target postures corresponding to each group of multi-frame second dense posture images are different;

[0021] According to a first loss function and a second loss function, training the first noise prediction model to obtain the trained first noise prediction model, wherein the first loss function is determined based on the second noise and the third noise, and the second loss function is determined based on the second noise;

[0022] The second noise prediction model is trained according to the first loss function and the third loss function to obtain the trained second noise prediction model, wherein the third loss function is determined based on the third noise.

[0023] In some embodiments, inputting the noisy second target pose image, a set of multiple frames of second dense pose images, and multiple frames of second target appearance images into the first noise prediction model to obtain the predicted second noise includes:

[0024] Using the feature extraction module in the first noise prediction model, extract features from each frame of the second target appearance image to obtain multi-scale texture features of each frame of the second target appearance image;

[0025] For each frame of the second target appearance image, the multi-scale texture features of the second target appearance image, the noisy second target posture image, and the group of multi-frame second dense posture images are input into the first intermediate network in the first noise prediction model to obtain predicted second noise, wherein the first intermediate network includes multiple intermediate layers, and a texture diffusion module is provided between two adjacent intermediate layers, and the texture diffusion module is used to perform feature fusion on the multi-scale texture features of the second target appearance image and the target posture features outputted from the intermediate layer.

[0026] In some embodiments, inputting the noisy second target pose image, Y groups of multi-frame second dense pose images, and a single-frame second target appearance image into the second noise prediction model to obtain a predicted third noise includes:

[0027] Using the feature extraction module of the second noise prediction model, extracting features from the second target appearance image to obtain multi-scale texture features of the second target appearance image;

[0028] For each group of multiple frames of second dense posture images, the multiple frames of second dense posture images, the noisy second target posture images and the second target appearance images are input into the second intermediate network in the second noise prediction model to obtain predicted third noise, wherein the second intermediate network includes multiple intermediate layers, and a texture diffusion module is provided between two adjacent intermediate layers, and the texture diffusion module is used to perform feature fusion on the multi-scale texture features of the second target appearance image and the target posture features outputted from the intermediate layer.

[0029] In some embodiments, the intermediate layer includes a two-dimensional residual module and a one-dimensional time-domain convolution layer, the two intermediate layers symmetrical about the texture diffusion module have the same feature resolution, and the two asymmetric and adjacent intermediate layers have different feature resolutions.

[0030] In some embodiments, the step of inputting the frame image, the first target appearance image, and the plurality of frames of the first dense posture image into a video generation model to obtain the first noise includes:

[0031] Inputting the frame image, the first target appearance image and multiple frames of first dense posture images into the trained first noise prediction model to obtain fourth noise;

[0032] Inputting the frame image, the first target appearance image and multiple frames of the first dense posture image into the trained second noise prediction model to obtain fifth noise;

[0033] The first noise is obtained by calculation according to the fourth noise and the fifth noise.

[0034] In a second aspect, an embodiment of the present invention further provides a video generating device, including:

[0035] A first acquisition module is used to input the frame image, the first target appearance image and the multiple frames of the first dense posture image into the video generation model for a frame image in the first video to obtain the first noise; wherein the first target appearance image is a person image with the first target appearance, the multiple frames of the first dense posture image include multiple consecutive frames of person images related to the first target posture, and the video generation model includes a trained first noise prediction model and a trained second noise prediction model, the trained first noise prediction model is used to capture the target posture, and the trained second noise prediction model is used to restore the target appearance;

[0036] A first processing module, configured to perform denoising on the first noise to obtain the denoised frame image;

[0037] The video generation module is used to generate a second video based on the denoised frame image.

[0038] In a third aspect, an embodiment of the present invention further provides a video generating device, including a processor and a transceiver, wherein the transceiver receives and sends data under the control of the processor, and the processor is used to perform the following operations:

[0039] For a frame image in a first video, the frame image, a first target appearance image and a plurality of first dense posture images are input into a video generation model to obtain a first noise; wherein the first target appearance image is a person image having a first target appearance, the plurality of first dense posture images include a plurality of consecutive frames of person images related to the first target posture, the video generation model includes a trained first noise prediction model and a trained second noise prediction model, the trained first noise prediction model is used to capture the target posture, and the trained second noise prediction model is used to restore the target appearance;

[0040] Performing denoising processing on the first noise to obtain the denoised frame image;

[0041] A second video is generated based on the denoised frame image.

[0042] In a fourth aspect, an embodiment of the present invention further provides a video generating device, comprising a memory, a processor, and a program stored in the memory and executable on the processor; when the processor executes the program, the video generating method as described in the first aspect above is implemented.

[0043] In a fifth aspect, an embodiment of the present invention further provides a computer-readable storage medium having a computer program stored thereon, which, when executed by a processor, implements the steps in the video generation method described in the first aspect above.

[0044] The above technical solution of the present invention has at least the following beneficial effects:

[0045] In an embodiment of the present invention, for a frame image in a first video, the frame image, a first target appearance image and a plurality of first dense posture images are input into a video generation model to obtain a first noise, wherein the first target appearance image is a person image having a first target appearance, and the plurality of first dense posture images include a plurality of consecutive frames of person images related to the first target posture, and the video generation model includes a trained first noise prediction model and a trained second noise prediction model, wherein the trained first noise prediction model is used to capture the target posture, and the trained second noise prediction model is used to restore the target appearance; the first noise is denoised to obtain the denoised frame image; finally, according to the denoised frame image, a second video is generated, so that the target posture of the frame image in the first video is captured by the trained first noise prediction model in the video generation model, and the target appearance of the frame image in the first video is restored by the trained second noise prediction model, and finally a clear frame image is obtained, and then a second video generated based on this greatly improves the visual quality of the generated video. BRIEF DESCRIPTION OF THE DRAWINGS

[0046] Figure 1 A schematic diagram showing a flow chart of a video generation method according to an embodiment of the present invention;

[0047] Figure 2 A schematic diagram showing the structure of a noise prediction model according to an embodiment of the present invention;

[0048] Figure 3 A schematic diagram showing the structure of a video generation model according to an embodiment of the present invention;

[0049] Figure 4 A second flowchart of the video generation method according to an embodiment of the present invention is shown;

[0050] Figure 5 A schematic diagram showing a module of a video generating device according to an embodiment of the present invention;

[0051] Figure 6 A schematic diagram showing the hardware structure of a video generating device according to an embodiment of the present invention. DETAILED DESCRIPTION

[0052] In order to make the technical problems, technical solutions and advantages to be solved by the present invention more clear, a detailed description will be given below with reference to the accompanying drawings and specific embodiments.

[0053] In order to solve the problem that the feature consistency between the image frames in the video generated by the existing video generation method is difficult to ensure, which seriously affects the visual quality of the final generated video, it is necessary to improve the consistency of the model-generated video from two aspects. First, it is necessary to improve the model's ability to capture the texture detail features in the target appearance image, so that the appearance features can be kept unchanged while the character's posture is transformed. Secondly, it is necessary to introduce time domain features so that the model can learn the relationship between the previous and next frame images in the video, thereby improving the time domain consistency. On the premise that the model can accurately restore the texture details of the image and has time domain features, the consistency of the previous and next frames in the generated video will be greatly improved.

[0054] Most existing technologies only consider one aspect, ignoring the fact that the consistency of generated videos requires improving the model's texture restoration ability and ability to extract time domain features at the same time.

[0055] In order to obtain high-quality generated videos, in addition to good temporal consistency and feature consistency, it is also necessary to solve problems such as model generalization. In the current existing methods, in order to achieve a good generation effect for new target characters, the relevant data of specific characters are usually input into the model that has been trained on a large-scale dataset for further refinement and learning, which indirectly reflects the poor generalization of the model itself. How to improve the generalization ability of the model is of great significance to the practical application of the model.

[0056] Most existing technologies use generative adversarial networks as the model framework. Although generative adversarial networks are a classic generative model and have been widely used in fields such as image generation, they also have the problem of unstable training and require careful hyperparameter adjustment and skills. In addition, the generated content of generative adversarial networks is difficult to control accurately, and it is not easy to add restrictions on generation conditions.

[0057] In order to solve the above problems, the present invention provides a video generation method, device, equipment and medium, wherein the method and the device are based on the same application concept. Since the method and the device solve the problem in a similar manner, the implementation of the device and the method can refer to each other, and the repeated parts will not be repeated.

[0058] like Figure 1 As shown, an embodiment of the present invention provides a video generation method, wherein the method may include:

[0059] Step 101, for a frame image in a first video, input the frame image, a first target appearance image and a plurality of first dense posture images into a video generation model to obtain a first noise; wherein the first target appearance image is a person image having a first target appearance, the plurality of first dense posture images include a plurality of consecutive frames of person images related to the first target posture, the video generation model includes a trained first noise prediction model and a trained second noise prediction model, the trained first noise prediction model is used to capture the target posture, and the trained second noise prediction model is used to restore the target appearance;

[0060] It should be noted that the frame images in the first video are noisy images, the first target appearance image and the multiple frames of first dense posture images are not related to the frame images in the first video, and the first target appearance image and the multiple frames of first dense posture images can be images from the same person or from different persons.

[0061] Specifically, step 101 includes:

[0062] Step 1011, inputting the frame image, the first target appearance image and multiple frames of first dense posture images into the trained first noise prediction model to obtain fourth noise;

[0063] Here, since the trained first noise prediction model is used to capture the target posture, after the frame image, the first target appearance image and multiple frames of first dense posture images are input into the trained first noise prediction model, the fourth noise obtained contains the target posture information of the frame image.

[0064] Step 1012, inputting the frame image, the first target appearance image and multiple frames of first dense posture images into the trained second noise prediction model to obtain fifth noise;

[0065] Since the trained second noise prediction model is used to restore the target appearance, after the frame image, the first target appearance image and multiple frames of first dense posture images are input into the trained second noise prediction model, the fifth noise obtained contains the target appearance information of the frame image.

[0066] Step 1013: Calculate the first noise according to the fourth noise and the fifth noise.

[0067] Specifically, the product value of the first weight coefficient and the fourth noise and the product value of the second weight coefficient and the fifth noise are summed up to obtain the first noise.

[0068] Step 102, denoising the first noise to obtain the denoised frame image;

[0069] Here, the first noise is the noise obtained by combining the output result of the trained first noise prediction model and the output result of the trained second noise prediction model. The first noise contains the target posture information and target appearance information of the frame image. After the first noise is denoised, the denoised frame image is obtained, that is, a clear image with the target appearance and target posture is obtained. Optionally, based on multi-frame posture guidance and DDPM inverse diffusion process (details can be referred to below), the first noise is denoised to obtain the denoised frame image.

[0070] Step 103: Generate a second video based on the denoised frame image.

[0071] Here, the frame images in the first video are processed frame by frame, and finally the denoised frame images are synthesized into the second video. Optionally, the denoised frame images are synthesized into the second video based on FFmpeg. FFmpeg is an open source computer program that can be used to record and convert digital audio and video and convert them into streams.

[0072] The video generation method of the embodiment of the present invention captures the target posture of the frame image in the first video through the trained first noise prediction model in the video generation model, and restores the target appearance of the frame image in the first video through the trained second noise prediction model, and finally obtains a clear frame image, and then generates a second video based on this, which greatly improves the visual quality of the generated video.

[0073] Before implementing the above video generation method, it is necessary to obtain a video generation model in advance, wherein the video generation model is trained as follows:

[0074] In an optional embodiment, the method of the embodiment of the present invention further includes:

[0075] A1) obtaining a training data set; wherein the training data set includes a target appearance image, a target posture image, and multiple frames of dense posture images of each target person in the third video;

[0076] Optionally, the step A1) includes:

[0077] A11) for each target person in the third video, obtaining the target appearance image and the target posture image of the target person in the third video;

[0078] A12) determining the target pose image and N frames of images before and after the target pose image as the multi-frame dense pose image, where N is a positive integer.

[0079] Among them, N action video clips of target persons can be collected, and the human body posture estimation method DensePose is used to estimate the dense posture image corresponding to each frame of the third video.

[0080] Here, the training data set can be expressed as

[0081] in, represents the target appearance image of person n, represents the target pose image of person n, Represents the multi-frame dense pose images corresponding to the target pose image of person n, N represents the total number of target persons included in the training data set, and n represents the corresponding person serial number.

[0082] Each data pair in the training dataset They all come from the same target person, and the video scene and image resolution need to be consistent. To construct a data pair, two frames of images can be randomly selected from the same video (the third video) as the target appearance image x s and the target posture image y0, and then extract the target posture image and the N frames before and after it to obtain a multi-frame dense posture image. For example, extract a dense posture image including the target posture image and the 2 frames before and after it, a total of 5 frames of images, that is: p ={p i-2 ,p i-1 ,p i ,p i+1 ,p i+2}, where p i Indicates the target posture.

[0083] A2) using the training data set to respectively train a first noise prediction model and a second noise prediction model to obtain the trained first noise prediction model and the trained second noise prediction model;

[0084] It should be noted that based on the diffusion process of multi-frame posture guidance and denoising diffusion probability model (DDPM), the training data set and noise prediction model H N (For the model structure diagram, see Figure 2 ) for training. The embodiment of the present invention constructs a dual-model parallel training framework (see the framework structure diagram for details). Figure 3 ), the framework includes two noise prediction models, namely the first noise prediction model H N1 and the second noise prediction model H N2 , obtain the first noise prediction model H after training N1 and the trained second noise prediction model H N2 .

[0085] In some embodiments, step A2) comprises:

[0086] A21) performing noise processing on the second target posture image to obtain a noisy second target posture image;

[0087] It should be noted that the second target posture image, the second target appearance image described below, and one or more sets of multi-frame second dense posture images are all data in the training data set;

[0088] Optionally, based on the multi-frame posture guidance and the diffusion process of DDPM, the second target posture image is subjected to noise processing to obtain the second target posture image after noise. The diffusion process of the model is the process of continuously adding Gaussian noise to the second target posture image y0, and finally generating the second target posture image after noise y T The specific generation formula is as follows:

[0089]

[0090] Among them, α T are the pre-set hyperparameters, ε is Gaussian noise randomly sampled from a normal distribution.

[0091] A22) inputting the noisy second target pose image, a group of multiple frames of second dense pose images and multiple frames of second target appearance images into the first noise prediction model to obtain predicted second noise, wherein the multiple frames of second dense pose images include the second target pose image and M frames of images before and after the second target pose image, M is a positive integer; the second target pose image and the multiple frames of second target appearance images belong to the same target person;

[0092] The first noise prediction model and the second noise prediction model have the same model structure, and the difference lies in the model input data.

[0093] In some embodiments, step A22) includes:

[0094] Using the feature extraction module in the first noise prediction model, extract features from each frame of the second target appearance image to obtain multi-scale texture features of each frame of the second target appearance image;

[0095] For each frame of the second target appearance image, the multi-scale texture features of the second target appearance image, the noisy second target posture image, and the group of multi-frame second dense posture images are input into the first intermediate network in the first noise prediction model to obtain predicted second noise, wherein the first intermediate network includes multiple intermediate layers, and a texture diffusion module is provided between two adjacent intermediate layers, and the texture diffusion module is used to perform feature fusion on the multi-scale texture features of the second target appearance image and the target posture features outputted from the intermediate layer.

[0096] Here, for the training of the first noise prediction model, the fixed target pose x is input p , i.e., a set of multi-frame second dense posture images; multiple second target appearance images x from the same target person are input in sequence s , see Figure 3 , the input x of the first noise prediction model s1 , x s2 , x s3 The same target person has the same appearance and texture details, but there are differences in person posture, shooting angle, etc. With such input settings, the first noise prediction model can better capture the target posture after training.

[0097] A23) inputting the noisy second target posture image, Y groups of multi-frame second dense posture images and a single-frame second target appearance image into the second noise prediction model to obtain a predicted third noise, wherein Y is a positive integer, and the target postures corresponding to each group of multi-frame second dense posture images are different;

[0098] In some embodiments, step A23) includes:

[0099] Using the feature extraction module of the second noise prediction model, extracting features from the second target appearance image to obtain multi-scale texture features of the second target appearance image;

[0100] For each group of multiple frames of second dense posture images, the multiple frames of second dense posture images, the noisy second target posture images and the second target appearance images are input into the second intermediate network in the second noise prediction model to obtain predicted third noise, wherein the second intermediate network includes multiple intermediate layers, and a texture diffusion module is provided between two adjacent intermediate layers, and the texture diffusion module is used to perform feature fusion on the multi-scale texture features of the second target appearance image and the target posture features outputted from the intermediate layer.

[0101] Here, for the training of the second noise prediction model, a fixed second target appearance image x is input s , input different target postures x in turnp , that is, different groups of multi-frame second dense posture images, such as x p1 , x p2 , x p3 Indicates different target postures. With such input settings, the second noise prediction model can have better recovery ability for the target appearance after training.

[0102] See also Figure 2 , noise prediction model H N Including feature extraction module H E and an intermediate network, wherein the intermediate network (here, for the first noise prediction model H N1 , the intermediate network is the first intermediate network; for the second noise prediction model H N2 , the intermediate network is the second intermediate network) includes multiple intermediate layers, and a texture diffusion module TDB is provided between two adjacent intermediate layers. Feature extraction module H E It is used to extract the multi-scale texture features of the target appearance image; based on the cross-attention mechanism of the texture diffusion module TDB, the multi-scale texture features of the target appearance image and the target posture features output in the middle layer are fused. In this way, the model can make full use of the relationship between the multi-scale texture features and the target posture features, obtain better texture restoration and posture transfer quality, and improve the feature consistency of the model.

[0103] Optionally, the feature extraction module H E Including multiple convolutional layers, the multi-scale texture features of the target appearance image are composed of H E It is composed of features from multiple convolutional layers, and has multi-scale information extracted by convolutional layers with different receptive fields.

[0104] Optionally, the intermediate layer includes a two-dimensional residual module and a one-dimensional time-domain convolution layer, the two intermediate layers symmetrical about the texture diffusion module have the same feature resolution, and the two asymmetric and adjacent intermediate layers have different feature resolutions.

[0105] Here, by introducing a one-dimensional time domain convolution layer, convolution is performed in the time domain to obtain better time domain consistency.

[0106] It should be noted that the noise prediction model training process also takes multiple consecutive frames of the second dense posture image as input to smooth the inter-frame motion and reduce the inter-frame flickering problem.

[0107] A24) training the first noise prediction model according to a first loss function and a second loss function to obtain the trained first noise prediction model, wherein the first loss function is determined based on the second noise and the third noise, and the second loss function is determined based on the second noise;

[0108] Here, the loss function includes three parts, namely, the first loss function, the second loss function and the third loss function. It should be understood that the first loss function is the loss function of the dual-model parallel training framework, and optionally, the first loss function is the mean square error MSE loss function. The second loss function is the loss function corresponding to the first noise prediction model, and the third loss function is the loss function corresponding to the second noise prediction model.

[0109] It should be noted that the first noise prediction model itself is an independent model, but it is also part of the dual-model parallel training framework. Therefore, the first loss function and the second loss function are needed to jointly optimize the first noise prediction model H during the training process. N1 The parameter θ.

[0110] A25) training the second noise prediction model according to the first loss function and the third loss function to obtain the trained second noise prediction model, wherein the third loss function is determined based on the third noise.

[0111] It should be noted that the second noise prediction model itself is an independent model, but it is also part of the dual-model parallel training framework. Therefore, the first loss function and the third loss function are needed to jointly optimize the second noise prediction model H in the training process. N2 Parameters

[0112] A3) Setting the trained first noise prediction model and the trained second noise prediction model in parallel to obtain the video generation model.

[0113] In order to understand the solution of the present invention more clearly and conveniently, see Figure 2 ,The specific training details and process of a single noise prediction model are described below, as follows:

[0114] 1. The target appearance image x s Input feature extraction module H E Encode and extract the target appearance image x s Multi-scale texture features F s .

[0115] 2. Perform noise processing on the target posture image y0 to obtain the target posture image y after noise addition t , y t and the target dense pose image x p connected in parallel as the noise prediction model H N Input.

[0116] 3. Texture diffusion module TDB uses the cross-attention mechanism to transform the multi-scale texture features F sAnd the target posture feature F output by the middle layer h Perform feature fusion.

[0117] Here, both K and V in cross-attention use multi-scale texture features F s To calculate, Q uses the target pose feature F h Calculate. Specifically, the calculation formula is as follows:

[0118]

[0119] in, and All of them are convolution layers with a convolution kernel size of 1×1, and l represents the noise prediction model H N The cross-attention feature output is:

[0120]

[0121] Among them, W l is a learnable parameter. The texture diffusion module TDB is inserted between the convolutional layers with feature resolutions of 32×32, 16×16, and 8×8; C is the row dimension of the Q matrix and the K matrix.

[0122] 4. Using the noise prediction model H N Predict Gaussian noise and get ε θ (y t ,t,x p ,x s ).

[0123] The noise prediction model provided by the embodiment of the present invention uses the noisy target posture image and the multi-frame dense posture image in parallel as input, and in order to introduce the target appearance information in the denoising process, the feature extraction module in the noise prediction model is used to extract the multi-scale texture features in the target appearance image. In order to better improve the texture restoration ability from the network level and realize the conversion from the source image feature distribution to the multi-scale texture features in the noise prediction model, a texture diffusion module is introduced in multiple intermediate layers in the noise prediction model. The texture diffusion module realizes feature fusion based on the cross-attention mechanism, so that the model can make full use of the relationship between the multi-scale texture features and the target posture features to obtain better texture restoration and posture migration quality. Since high-quality character videos need to have both accurate texture details and good temporal consistency, in addition to improving the texture restoration ability of the model, the model also introduces a temporal convolution layer to smooth the inter-frame motion and reduce the problem of inter-frame flickering to obtain better temporal consistency.

[0124] In order to understand the solution of the present invention more clearly and conveniently, see Figure 3 , the training steps of the dual-model parallel training framework are described below, as follows:

[0125] 1. In each input batch during training, the first noise prediction model H N1 Input fixed target pose x p , input multiple target appearance images x from the same target person in sequence s , see Figure 3 , the input x of the first noise prediction model s1 , x s2 , x s3 The same target person has the same appearance and texture details, but there are differences in person posture, shooting angle, etc. With such input settings, the first noise prediction model can better capture the target posture after training.

[0126] 2. Second noise prediction model H N2 Input a fixed target appearance image x s , input different target postures x in turn p , such as x p1 , x p2 , x p3 Indicates different target postures. With such input settings, the second noise prediction model can have better recovery ability for the target appearance after training.

[0127] 3. The first noise prediction model H N1 and the second noise prediction model H N2 The output results of are combined according to certain weights to obtain the final output result of the framework. Among them, the final output result of the framework is:

[0128]

[0129] Specifically, for an input data with a batch size of 2, the output of the dual-model parallel training framework is:

[0130] and

[0131]

[0132] 4. Calculate the loss function to optimize the first noise prediction model H N1 The parameters θ and the second noise prediction model H N2 Parameters The loss function consists of three parts.

[0133] First, the MSE loss function L of the overall framework is MSE (First loss function). For a batch size of 2 input data, the loss function is calculated as follows:

[0134]

[0135] Among them, T is the preset total number of diffusion steps, t is the current step number, ε1 and ε2 are randomly sampled Gaussian noises, and λ is a preset hyperparameter.

[0136] Then, based on the prior consistency, two consistency constraint loss functions are proposed:

[0137]

[0138]

[0139] Among them, L cons1 (Second loss function) Optimize H N1 Model, L cons2 (Third loss function) Optimize H N2 Model.

[0140] Finally, the three are combined together to obtain the total loss function, the formula is as follows:

[0141] L=β1L MSE +β2L cons1 +β3L cons2

[0142] Based on this loss function, the geometric posture and texture details in the image can be decoupled. N1 The model focuses on the geometric posture of the image, H N2 The model focuses on the texture details of the image, and finally combines the two together to improve the generalization ability of the model. The hyperparameters β1, β2, and β3 that control the proportion of each loss function in the total loss function L have different proportion settings according to the training data scene, but the value range is within [0-10.0].

[0143] For scenes such as people speaking, the human body occupies a larger proportion of the image and the degree of body movements is relatively small, so the model needs to pay more attention to the preservation of the texture details of the person. In this case, β3 can be set to [5.0-6.0], and β1 and β2 can be set to 1.0. For dance videos, the human body movements are large, so the model needs to pay more attention to the extraction of posture features and temporal consistency, so β2 can be set to [5.0-6.0], β3 to [2.0-3.0], and β1 to 1.0.

[0144] Finally, based on the first noise prediction model H N1 and the second noise prediction model H N2 The output noise is The random noise is gradually denoised to obtain the noise-free y0 (based on the inverse diffusion process of multi-frame attitude guidance and DDPM diffusion model). The specific steps are:

[0145] 1. Randomly sample a Gaussian noise y from a normal distribution T ;

[0146] 2. According to the sampling formula, y T Denoising to get y T-1 , the sampling formula is:

[0147]

[0148] Where z is randomly sampled Gaussian noise.

[0149] 3. Repeat step 2 T times, with iteration number t = T, T-1, ···, 1. After T times of denoising, the final output image y0 with the target appearance and target posture is obtained.

[0150] The dual-model parallel framework proposed in the embodiment of the present invention integrates the output results of two noise prediction models trained in parallel. Then, the consistency of the input data is used to set a consistency loss function to supervise the two models respectively. One of the two models focuses on the learning of geometric posture, and the other focuses on the learning of texture details. It is possible to decouple the geometric posture and texture details in the image, and improve the generalization ability of the model. In addition, weights related to the training scene are set for the three loss functions to artificially increase the model's emphasis on geometric posture or texture details, so that the model can have better adaptability to a variety of scenes.

[0151] See also Figure 4 , the overall process of the method of the present invention is described as follows:

[0152] 1. Establish a diffusion process and noise prediction model H based on multi-frame posture guidance and DDPM N .

[0153] 2. Collect N speaking videos of target persons, and use the human pose estimation method DensePose to estimate the dense pose image corresponding to each frame of the video.

[0154] 3. Construct a dataset P of target appearance image frames and target postures in character videos;

[0155] Where P as the training data set can be expressed as

[0156] in, represents the target appearance image of person n, represents the target pose image of person n, Represents the multi-frame dense pose images corresponding to the target pose image of person n, N represents the total number of target persons included in the training data set, and n represents the corresponding person serial number.

[0157] 4. Diffusion process based on multi-frame pose guidance and DDPM and training dataset P for noise prediction model H N Training. Construct a dual-model parallel training framework, which has two noise prediction models, namely H N1 and H N2 , obtain the trained noise prediction model H N1 and H N2 , that is, the video generation model is obtained.

[0158] 5. The inverse diffusion process based on multi-frame posture guidance and DDPM is used as the inverse process of the video generation model. The target appearance image frame and target posture data pair are input into the inverse process of DDPM to obtain the generated image frame y with the target appearance and target posture L .

[0159] 6. The continuous generated image frames y L FFmpeg is used to synthesize high-quality person videos with target appearance and target posture sequences.

[0160] like Figure 5 As shown, an embodiment of the present invention provides a video generating device, the device comprising:

[0161] A first acquisition module 501 is used to input the frame image in the first video, the first target appearance image and multiple frames of first dense posture images into a video generation model to obtain a first noise; wherein the first target appearance image is a person image with the first target appearance, the multiple frames of first dense posture images include multiple consecutive frames of person images related to the first target posture, and the video generation model includes a trained first noise prediction model and a trained second noise prediction model, the trained first noise prediction model is used to capture the target posture, and the trained second noise prediction model is used to restore the target appearance;

[0162] A first processing module 502 is used to perform denoising on the first noise to obtain the denoised frame image;

[0163] The video generation module 503 is used to generate a second video according to the denoised frame image.

[0164] Optionally, the video generating device in the embodiment of the present invention further includes:

[0165] A second acquisition module is used to acquire a training data set; wherein the training data set includes a target appearance image, a target posture image, and a multi-frame dense posture image of each target person in the third video;

[0166] A model training module, used to use the training data set to train the first noise prediction model and the second noise prediction model respectively, to obtain the trained first noise prediction model and the trained second noise prediction model;

[0167] The second processing module is used to set the trained first noise prediction model and the trained second noise prediction model in parallel to obtain the video generation model.

[0168] Optionally, the second acquisition module includes:

[0169] A first acquisition unit is used to acquire, for each target person in the third video, the target appearance image and the target posture image of the target person in the third video;

[0170] The second acquisition unit is used to determine the target posture image and N frames of images before and after the target posture image as the multi-frame dense posture images, where N is a positive integer.

[0171] Optionally, the model training module includes:

[0172] A first processing unit is used to perform noise processing on the second target posture image to obtain a noisy second target posture image;

[0173] a second processing unit, configured to input the noisy second target posture image, a group of multiple frames of second dense posture images, and multiple frames of second target appearance images into the first noise prediction model to obtain predicted second noise, wherein the multiple frames of second dense posture images include the second target posture image and M frames of images before and after the second target posture image, where M is a positive integer; and the second target posture image and the multiple frames of second target appearance images belong to the same target person;

[0174] a third processing unit, configured to input the noisy second target posture image, Y groups of multi-frame second dense posture images, and a single-frame second target appearance image into the second noise prediction model to obtain a predicted third noise, wherein Y is a positive integer, and the target postures corresponding to each group of multi-frame second dense posture images are different;

[0175] A first training unit is configured to train the first noise prediction model according to a first loss function and a second loss function to obtain the trained first noise prediction model, wherein the first loss function is determined based on the second noise and the third noise, and the second loss function is determined based on the second noise;

[0176] The second training unit is used to train the second noise prediction model according to the first loss function and the third loss function to obtain the trained second noise prediction model, wherein the third loss function is determined based on the third noise.

[0177] Optionally, the second processing unit is specifically configured to:

[0178] Using the feature extraction module in the first noise prediction model, extract features from each frame of the second target appearance image to obtain multi-scale texture features of each frame of the second target appearance image;

[0179] For each frame of the second target appearance image, the multi-scale texture features of the second target appearance image, the noisy second target posture image, and the group of multi-frame second dense posture images are input into the first intermediate network in the first noise prediction model to obtain predicted second noise, wherein the first intermediate network includes multiple intermediate layers, and a texture diffusion module is provided between two adjacent intermediate layers, and the texture diffusion module is used to perform feature fusion on the multi-scale texture features of the second target appearance image and the target posture features outputted from the intermediate layer.

[0180] Optionally, the third processing unit is specifically configured to:

[0181] Using the feature extraction module of the second noise prediction model, extracting features from the second target appearance image to obtain multi-scale texture features of the second target appearance image;

[0182] For each group of multiple frames of second dense posture images, the multiple frames of second dense posture images, the noisy second target posture images and the second target appearance images are input into the second intermediate network in the second noise prediction model to obtain predicted third noise, wherein the second intermediate network includes multiple intermediate layers, and a texture diffusion module is provided between two adjacent intermediate layers, and the texture diffusion module is used to perform feature fusion on the multi-scale texture features of the second target appearance image and the target posture features outputted from the intermediate layer.

[0183] Optionally, the intermediate layer includes a two-dimensional residual module and a one-dimensional time-domain convolution layer, the two intermediate layers symmetrical about the texture diffusion module have the same feature resolution, and the two asymmetric and adjacent intermediate layers have different feature resolutions.

[0184] Optionally, the first acquisition module 501 includes:

[0185] A third acquisition unit is used to input the frame image, the first target appearance image and multiple frames of first dense posture images into the trained first noise prediction model to obtain fourth noise;

[0186] a fourth acquisition unit, configured to input the frame image, the first target appearance image, and a plurality of frames of the first dense posture image into the trained second noise prediction model to obtain fifth noise;

[0187] The fourth processing unit is configured to calculate the first noise according to the fourth noise and the fifth noise.

[0188] The video generation device of the embodiment of the present invention inputs the frame image in the first video, the first target appearance image and multiple frames of first dense posture images into the video generation model to obtain the first noise, wherein the first target appearance image is a person image with the first target appearance, and the multiple frames of first dense posture images include multiple consecutive frames of person images related to the first target posture, and the video generation model includes a trained first noise prediction model and a trained second noise prediction model, the trained first noise prediction model is used to capture the target posture, and the trained second noise prediction model is used to restore the target appearance; the first noise is denoised to obtain the denoised frame image; finally, according to the denoised frame image, a second video is generated, so that the target posture of the frame image in the first video is captured by the trained first noise prediction model in the video generation model, and the target appearance of the frame image in the first video is restored by the trained second noise prediction model, and finally a clear frame image is obtained, and then a second video generated based on this greatly improves the visual quality of the generated video.

[0189] In order to better achieve the above goals, Figure 6 As shown, an embodiment of the present invention further provides a video generating device, including a processor 600 and a transceiver 610, wherein the transceiver 610 receives and sends data under the control of the processor 600, and the processor 600 is used to perform the following process:

[0190] For a frame image in a first video, the frame image, a first target appearance image and a plurality of first dense posture images are input into a video generation model to obtain a first noise; wherein the first target appearance image is a person image having a first target appearance, the plurality of first dense posture images include a plurality of consecutive frames of person images related to the first target posture, the video generation model includes a trained first noise prediction model and a trained second noise prediction model, the trained first noise prediction model is used to capture the target posture, and the trained second noise prediction model is used to restore the target appearance;

[0191] Performing denoising processing on the first noise to obtain the denoised frame image;

[0192] A second video is generated based on the denoised frame image.

[0193] Optionally, the processor 600 is further configured to:

[0194] Acquire a training data set; wherein the training data set includes a target appearance image, a target posture image, and multiple frames of dense posture images of each target person in the third video;

[0195] Using the training data set, respectively training a first noise prediction model and a second noise prediction model to obtain the trained first noise prediction model and the trained second noise prediction model;

[0196] The trained first noise prediction model and the trained second noise prediction model are set in parallel to obtain the video generation model.

[0197] Optionally, the processor 600 is further configured to:

[0198] For each target person in the third video, obtaining the target appearance image and the target posture image of the target person in the third video;

[0199] The target posture image and N frames of images before and after the target posture image are determined as the multi-frame dense posture images, where N is a positive integer.

[0200] Optionally, the processor 600 is further configured to:

[0201] Performing noise processing on the second target posture image to obtain a noisy second target posture image;

[0202] Inputting the noisy second target pose image, a group of multi-frame second dense pose images and multi-frame second target appearance images into the first noise prediction model to obtain predicted second noise, wherein the multi-frame second dense pose images include the second target pose image and M frames of images before and after the second target pose image, where M is a positive integer; the second target pose image and the multi-frame second target appearance images belong to the same target person;

[0203] Inputting the noisy second target posture image, Y groups of multi-frame second dense posture images and a single-frame second target appearance image into the second noise prediction model to obtain a predicted third noise, wherein Y is a positive integer, and the target postures corresponding to each group of multi-frame second dense posture images are different;

[0204] According to a first loss function and a second loss function, training the first noise prediction model to obtain the trained first noise prediction model, wherein the first loss function is determined based on the second noise and the third noise, and the second loss function is determined based on the second noise;

[0205] The second noise prediction model is trained according to the first loss function and the third loss function to obtain the trained second noise prediction model, wherein the third loss function is determined based on the third noise.

[0206] Optionally, the processor 600 is further configured to:

[0207] Using the feature extraction module in the first noise prediction model, extract features from each frame of the second target appearance image to obtain multi-scale texture features of each frame of the second target appearance image;

[0208] For each frame of the second target appearance image, the multi-scale texture features of the second target appearance image, the noisy second target posture image, and the group of multi-frame second dense posture images are input into the first intermediate network in the first noise prediction model to obtain predicted second noise, wherein the first intermediate network includes multiple intermediate layers, and a texture diffusion module is provided between two adjacent intermediate layers, and the texture diffusion module is used to perform feature fusion on the multi-scale texture features of the second target appearance image and the target posture features outputted from the intermediate layer.

[0209] Optionally, the processor 600 is further configured to:

[0210] Using the feature extraction module of the second noise prediction model, extracting features from the second target appearance image to obtain multi-scale texture features of the second target appearance image;

[0211] For each group of multiple frames of second dense posture images, the multiple frames of second dense posture images, the noisy second target posture images and the second target appearance images are input into the second intermediate network in the second noise prediction model to obtain predicted third noise, wherein the second intermediate network includes multiple intermediate layers, and a texture diffusion module is provided between two adjacent intermediate layers, and the texture diffusion module is used to perform feature fusion on the multi-scale texture features of the second target appearance image and the target posture features outputted from the intermediate layer.

[0212] Optionally, the intermediate layer includes a two-dimensional residual module and a one-dimensional time-domain convolution layer, the two intermediate layers symmetrical about the texture diffusion module have the same feature resolution, and the two asymmetric and adjacent intermediate layers have different feature resolutions.

[0213] Optionally, the processor 600 is further configured to:

[0214] Inputting the frame image, the first target appearance image and multiple frames of first dense posture images into the trained first noise prediction model to obtain fourth noise;

[0215] Inputting the frame image, the first target appearance image and multiple frames of the first dense posture image into the trained second noise prediction model to obtain fifth noise;

[0216] The first noise is obtained by calculation according to the fourth noise and the fifth noise.

[0217] The video generation device of the embodiment of the present invention inputs the frame image in the first video, the first target appearance image and the multiple frames of the first dense posture image into the video generation model to obtain the first noise, wherein the first target appearance image is a person image with the first target appearance, and the multiple frames of the first dense posture image include multiple consecutive frames of person images related to the first target posture, and the video generation model includes a trained first noise prediction model and a trained second noise prediction model, the trained first noise prediction model is used to capture the target posture, and the trained second noise prediction model is used to restore the target appearance; the first noise is denoised to obtain the denoised frame image; finally, according to the denoised frame image, a second video is generated, so that the target posture of the frame image in the first video is captured by the trained first noise prediction model in the video generation model, and the target appearance of the frame image in the first video is restored by the trained second noise prediction model, and finally a clear frame image is obtained, and then a second video generated based on this greatly improves the visual quality of the generated video.

[0218] An embodiment of the present invention also provides a video generating device, including a memory, a processor, and a computer program stored in the memory and executable on the processor. When the processor executes the program, each process in the video generating method embodiment described above is implemented, and the same technical effect can be achieved. To avoid repetition, it will not be described here.

[0219] The embodiment of the present invention further provides a computer-readable storage medium on which a computer program is stored. When the program is executed by a processor, each process in the video generation method embodiment described above is implemented, and the same technical effect can be achieved. To avoid repetition, it is not described here. The computer-readable storage medium is, for example, a read-only memory (ROM), a random access memory (RAM), a magnetic disk or an optical disk.

[0220] Those skilled in the art will appreciate that the embodiments of the present application may be provided as methods, systems or computer program products. Therefore, the present application may adopt the form of a complete hardware embodiment, a complete software embodiment or an embodiment combining software and hardware. Moreover, the present application may adopt the form of a computer program product implemented on one or more computer-readable storage media (including but not limited to disk storage and optical storage, etc.) containing computer-usable program code.

[0221] The present application is described with reference to the flowcharts and / or block diagrams of the methods, devices (systems) and computer program products according to the embodiments of the present application. It should be understood that each process and / or box in the flowchart and / or block diagram, as well as the combination of the processes and / or boxes in the flowchart and / or block diagram, can be implemented by computer program instructions. These computer program instructions can be provided to a processor of a general-purpose computer, a special-purpose computer, an embedded processor or other programmable data processing device to generate a machine, so that the instructions executed by the processor of the computer or other programmable data processing device generate instructions for implementing the processes in the flowchart and / or block diagram. Figure 1 A device that specifies functions in one or more processes and / or one or more blocks.

[0222] These computer program instructions may also be stored in a computer-readable storage medium that can direct a computer or other programmable data processing device to work in a specific manner, so that the instructions stored in the computer-readable storage medium produce a paper product including an instruction device, which implements the process Figure 1 A process or multiple processes and / or boxes Figure 1 A function specified in one or more boxes.

[0223] These computer program instructions may also be loaded onto a computer or other programmable data processing device so that the computer or other programmable device executes a series of operating steps to produce a computer-implemented process, thereby providing instructions executed on the computer or other programmable device for implementing the process. Figure 1 A process or multiple processes and / or boxes Figure 1 The steps for the functions specified in one or more boxes.

[0224] The above is a preferred embodiment of the present invention. It should be pointed out that for ordinary technicians in this technical field, several improvements and modifications can be made without departing from the principles of the present invention. These improvements and modifications should also be regarded as the scope of protection of the present invention.

Claims

1. A video generation method, It is characterized in that include: For a frame image in a first video, the frame image, a first target appearance image and a plurality of first dense posture images are input into a video generation model to obtain a first noise; wherein the first target appearance image is a person image having a first target appearance, the plurality of first dense posture images include a plurality of consecutive frames of person images related to the first target posture, the video generation model includes a trained first noise prediction model and a trained second noise prediction model, the trained first noise prediction model is used to capture the target posture, and the trained second noise prediction model is used to restore the target appearance; Performing denoising processing on the first noise to obtain the denoised frame image; A second video is generated based on the denoised frame image.

2. The method according to claim 1, It is characterized in that The method further comprises: Acquire a training data set; wherein the training data set includes a target appearance image, a target posture image, and multiple frames of dense posture images of each target person in the third video; Using the training data set, respectively training a first noise prediction model and a second noise prediction model to obtain the trained first noise prediction model and the trained second noise prediction model; The trained first noise prediction model and the trained second noise prediction model are set in parallel to obtain the video generation model.

3. The method according to claim 2, It is characterized in that The obtaining of the training data set comprises: For each target person in the third video, obtaining the target appearance image and the target posture image of the target person in the third video; The target posture image and N frames of images before and after the target posture image are determined as the multi-frame dense posture images, where N is a positive integer.

4. The method according to claim 2, It is characterized in that The method of using the training data set to respectively train the first noise prediction model and the second noise prediction model to obtain the trained first noise prediction model and the trained second noise prediction model comprises: Performing noise processing on the second target posture image to obtain a noisy second target posture image; Inputting the noisy second target pose image, a group of multi-frame second dense pose images and multi-frame second target appearance images into the first noise prediction model to obtain predicted second noise, wherein the multi-frame second dense pose images include the second target pose image and M frames of images before and after the second target pose image, where M is a positive integer; the second target pose image and the multi-frame second target appearance images belong to the same target person; Inputting the noisy second target posture image, Y groups of multi-frame second dense posture images and a single-frame second target appearance image into the second noise prediction model to obtain a predicted third noise, wherein Y is a positive integer, and the target postures corresponding to each group of multi-frame second dense posture images are different; According to a first loss function and a second loss function, training the first noise prediction model to obtain the trained first noise prediction model, wherein the first loss function is determined based on the second noise and the third noise, and the second loss function is determined based on the second noise; The second noise prediction model is trained according to the first loss function and the third loss function to obtain the trained second noise prediction model, wherein the third loss function is determined based on the third noise.

5. The method according to claim 4, It is characterized in that The step of inputting the noisy second target posture image, a group of multiple frames of second dense posture images, and multiple frames of second target appearance images into the first noise prediction model to obtain predicted second noise includes: Using the feature extraction module in the first noise prediction model, extract features from each frame of the second target appearance image to obtain multi-scale texture features of each frame of the second target appearance image; For each frame of the second target appearance image, the multi-scale texture features of the second target appearance image, the noisy second target posture image, and the group of multi-frame second dense posture images are input into the first intermediate network in the first noise prediction model to obtain predicted second noise, wherein the first intermediate network includes multiple intermediate layers, and a texture diffusion module is provided between two adjacent intermediate layers, and the texture diffusion module is used to perform feature fusion on the multi-scale texture features of the second target appearance image and the target posture features outputted from the intermediate layer.

6. The method according to claim 4, It is characterized in that The step of inputting the noisy second target posture image, Y groups of multi-frame second dense posture images, and a single-frame second target appearance image into the second noise prediction model to obtain a predicted third noise includes: Using the feature extraction module of the second noise prediction model, extracting features from the second target appearance image to obtain multi-scale texture features of the second target appearance image; For each group of multiple frames of second dense posture images, the multiple frames of second dense posture images, the noisy second target posture images and the second target appearance images are input into the second intermediate network in the second noise prediction model to obtain predicted third noise, wherein the second intermediate network includes multiple intermediate layers, and a texture diffusion module is provided between two adjacent intermediate layers, and the texture diffusion module is used to perform feature fusion on the multi-scale texture features of the second target appearance image and the target posture features outputted from the intermediate layer.

7. The method according to claim 5 or 6, It is characterized in that The intermediate layer includes a two-dimensional residual module and a one-dimensional time domain convolution layer. The two intermediate layers symmetrical about the texture diffusion module have the same feature resolution, and the two asymmetric and adjacent intermediate layers have different feature resolutions.

8. The method according to claim 1, It is characterized in that The step of inputting the frame image, the first target appearance image, and multiple frames of first dense posture images into a video generation model to obtain a first noise includes: Inputting the frame image, the first target appearance image and multiple frames of first dense posture images into the trained first noise prediction model to obtain fourth noise; Inputting the frame image, the first target appearance image and multiple frames of the first dense posture image into the trained second noise prediction model to obtain fifth noise; The first noise is obtained by calculation according to the fourth noise and the fifth noise.

9. A video generating device, It is characterized in that include: A first acquisition module is used to input the frame image, the first target appearance image and the multiple frames of the first dense posture image into the video generation model for a frame image in the first video to obtain the first noise; wherein the first target appearance image is a person image with the first target appearance, the multiple frames of the first dense posture image include multiple consecutive frames of person images related to the first target posture, and the video generation model includes a trained first noise prediction model and a trained second noise prediction model, the trained first noise prediction model is used to capture the target posture, and the trained second noise prediction model is used to restore the target appearance; A first processing module, configured to perform denoising on the first noise to obtain the denoised frame image; The video generation module is used to generate a second video based on the denoised frame image.

10. A video generating device comprising a processor and a transceiver, wherein the transceiver receives and sends data under the control of the processor, It is characterized in that The processor is configured to perform the following operations: For a frame image in a first video, the frame image, a first target appearance image and a plurality of first dense posture images are input into a video generation model to obtain a first noise; wherein the first target appearance image is a person image having a first target appearance, the plurality of first dense posture images include a plurality of consecutive frames of person images related to the first target posture, the video generation model includes a trained first noise prediction model and a trained second noise prediction model, the trained first noise prediction model is used to capture the target posture, and the trained second noise prediction model is used to restore the target appearance; Performing denoising processing on the first noise to obtain the denoised frame image; A second video is generated based on the denoised frame image.

11. A video generation device, comprising a memory, a processor, and a program stored in the memory and executable on the processor; It is characterized in that When the processor executes the program, the video generating method according to any one of claims 1 to 8 is implemented.

12. A computer-readable storage medium having a computer program stored thereon, It is characterized in that When the program is executed by a processor, the steps in the video generation method according to any one of claims 1 to 8 are implemented.

Citation Information

Cited By

  • Character video generation method and device, computer equipment and storage medium

    CN119854541A

  • Method, apparatus, computer device, and storage medium for generating a character video

    CN119854541B

  • Video generation method and device, and electronic equipment

    CN119996784A