Animation generation method and device, equipment and storage medium

By training the network model to extract skeletal animation information from two-dimensional images taken from multiple angles, the problem of manually determining skeletal animation information in the conversion of two-dimensional animation to three-dimensional model is solved, and more efficient animation matching and consistency is achieved.

CN119295614APending Publication Date: 2025-01-10BEIJING PERFECT WORLD SOFTWARE TECH DEV CO LTD
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN202311766045.5
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2023-12-20
Publication Date
2025-01-10

AI Technical Summary

Technical Problem

When the designer converts action animations in two-dimensional animations into three-dimensional models, the process of manually determining the skeleton animation information is cumbersome and inefficient, resulting in low matching.

Method used

By obtaining sample two-dimensional images taken from multiple angles and corresponding skeleton animation information, the network model is trained to predict the initial animation information, generate more accurate skeleton animation information, and redirect it to the target 3D model to achieve automatic matching of animations .

Benefits of technology

It improves the accuracy and matching of skeletal animation information, simplifies the animation conversion process, and improves the performance consistency of three-dimensional animations.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN119295614A_ABST
    Figure CN119295614A_ABST
Patent Text Reader

Abstract

The embodiment of the invention provides an animation generation method and device, equipment and a storage medium, and the method comprises the steps: obtaining a sample data set, the sample data set comprises a plurality of groups of sample two-dimensional images shot from a plurality of different angles in the process of executing the preset action instruction by the preset standard model, and sample skeleton animation information corresponding to each group of sample two-dimensional images; based on the sample data set, training the initial network model, so that the trained network model can predict corresponding skeleton animation information from the input initial animation information; obtaining initial animation information used for generating a three-dimensional animation; and generating a target three-dimensional animation according to the initial animation information and the trained network model. According to the scheme, the initial animation information is input into the network model, more accurate and more real skeleton animation information is obtained, and the matching degree of the target three-dimensional animation generated based on the skeleton animation information and the initial animation information is higher.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present invention relates to the field of image processing technology, and in particular to an animation generation method, device, equipment and storage medium. Background Art

[0002] With the increase in entertainment demand, people pay more and more attention to the performance of entertainment content, and content providers are willing to invest more costs in the design of animation characters, including the design of the image of animation characters and the design of the action animation of animation characters, etc. Commonly, designers can design the action animation of animation characters and make it into animation, which can be a two-dimensional animation. If other designers want to refer to the action animation in the animation and want the three-dimensional model to have the same action as the animation character in the animation, these designers can only refer to the action animation in the animation to manually determine the skeletal animation information of the three-dimensional model, so that the three-dimensional model can have the same action performance as the animation character in the animation. The process of manually determining the skeletal animation information is extremely cumbersome and complicated, which leads to low efficiency in obtaining skeletal animation information. Summary of the invention

[0003] The embodiments of the present invention provide an animation generation method, apparatus, device and storage medium for automatically acquiring skeletal animation information with a higher matching degree to generate corresponding three-dimensional animation.

[0004] In a first aspect, an embodiment of the present invention provides a method for generating an animation, the method comprising:

[0005] Acquire a sample data set, wherein the sample data set includes a plurality of groups of sample two-dimensional images taken from a plurality of different angles during the process of a preset standard model executing a preset action instruction, and sample skeleton animation information corresponding to each group of sample two-dimensional images;

[0006] Based on the sample data set, the initial network model is trained so that the trained network model can predict the corresponding skeletal animation information from the input initial animation information;

[0007] Acquire initial animation information for generating three-dimensional animation;

[0008] A target three-dimensional animation is generated according to the initial animation information and the trained network model.

[0009] Optionally, the initial animation information is first skeletal animation information extracted from an animation video according to a preset extraction method;

[0010] Generating a target three-dimensional animation according to the initial animation information and the trained network model includes:

[0011] Inputting the first skeletal animation information into the trained network model to obtain optimized skeletal animation information;

[0012] The optimized skeletal animation information is redirected to a target model to generate a target three-dimensional animation corresponding to the target model.

[0013] Optionally, the sample skeletal animation information is annotated with a sample action description tag;

[0014] The training of the initial network model based on the sample data set includes:

[0015] Based on the sample data set, the initial network model is trained so that the trained network model can output matching skeletal animation information based on the input action description label.

[0016] Optionally, the initial animation information is text description information;

[0017] The obtaining of initial animation information for generating a three-dimensional animation comprises:

[0018] Receive first text description information input by a user;

[0019] Generating a target three-dimensional animation according to the initial animation information and the trained network model includes:

[0020] Inputting the first text description information into the trained network model to obtain second skeletal animation information matching the first text description information;

[0021] The second skeletal animation information is redirected to a target model to generate a target three-dimensional animation corresponding to the target model.

[0022] Optionally, the method further comprises:

[0023] In response to the user's replacement operation on the target frame sequence in the target three-dimensional animation, acquiring second text description information input by the user;

[0024] Inputting the second text description information into the trained network model to obtain third skeletal animation information matching the second text description information;

[0025] Replace the portion of the second skeletal animation information corresponding to the target frame sequence with the third skeletal animation information;

[0026] Redirecting the replaced second skeletal animation information to the target model.

[0027] Optionally, the initial animation information is an initial three-dimensional animation and modification description information for modifying a character action in the initial three-dimensional animation;

[0028] Generating a target three-dimensional animation according to the initial animation information and the trained network model includes:

[0029] Inputting the initial three-dimensional animation and the modification description information into the trained network model to obtain fourth skeletal animation information;

[0030] The fourth skeletal animation information is redirected to the target model to generate a target three-dimensional animation corresponding to the target model.

[0031] Optionally, the modification description information includes description information on the animation playback mode, description information on specific action elements in the animation, and / or description information on action effects in the animation.

[0032] In a second aspect, an embodiment of the present invention provides an animation generation device, comprising:

[0033] An acquisition module is used to acquire a sample data set, wherein the sample data set includes a plurality of groups of sample two-dimensional images taken from a plurality of different angles during the process of a preset standard model executing a preset action instruction, and sample skeleton animation information corresponding to each group of sample two-dimensional images;

[0034] A training module, used for training the initial network model based on the sample data set, so that the trained network model can predict the corresponding skeletal animation information from the input initial animation information;

[0035] The acquisition module is used to acquire initial animation information for generating three-dimensional animation;

[0036] A generation module is used to generate a target three-dimensional animation according to the initial animation information and the trained network model.

[0037] Optionally, the initial animation information is first skeletal animation information extracted from an animation video according to a preset extraction method;

[0038] The generating module is used for:

[0039] Inputting the first skeletal animation information into the trained network model to obtain optimized skeletal animation information;

[0040] The optimized skeletal animation information is redirected to a target model to generate a target three-dimensional animation corresponding to the target model.

[0041] Optionally, the sample skeletal animation information is annotated with a sample action description tag;

[0042] The training module is used to:

[0043] Based on the sample data set, the initial network model is trained so that the trained network model can output matching skeletal animation information based on the input action description label.

[0044] Optionally, the initial animation information is text description information;

[0045] The acquisition module is used to receive first text description information input by a user;

[0046] The generation module is used to input the first text description information into the trained network model to obtain second skeletal animation information matching the first text description information; and redirect the second skeletal animation information to the target model to generate a target three-dimensional animation corresponding to the target model.

[0047] Optionally, the device further comprises a modification module, wherein the modification module is configured to:

[0048] In response to the user's replacement operation on the target frame sequence in the target three-dimensional animation, acquiring second text description information input by the user;

[0049] Inputting the second text description information into the trained network model to obtain third skeletal animation information matching the second text description information;

[0050] Replace the portion of the second skeletal animation information corresponding to the target frame sequence with the third skeletal animation information;

[0051] Redirecting the replaced second skeletal animation information to the target model.

[0052] Optionally, the initial animation information is an initial three-dimensional animation and modification description information for modifying a character action in the initial three-dimensional animation;

[0053] The generating module is used for:

[0054] Inputting the initial three-dimensional animation and the modification description information into the trained network model to obtain fourth skeletal animation information;

[0055] The fourth skeletal animation information is redirected to the target model to generate a target three-dimensional animation corresponding to the target model.

[0056] Optionally, the modification description information includes description information on the animation playback mode, description information on specific action elements in the animation, and / or description information on action effects in the animation.

[0057] In a third aspect, an embodiment of the present invention provides an electronic device, comprising a processor and a memory, wherein the memory stores executable code, and when the executable code is executed by the processor, the processor can at least implement the animation generation method in the first aspect.

[0058] In a fourth aspect, an embodiment of the present invention provides a non-transitory machine-readable storage medium having executable code stored thereon. When the executable code is executed by a processor of an electronic device, the processor can at least implement the animation generation method in the first aspect.

[0059] By adopting the present invention, the initial network model can be trained, and by reasonably setting the sample data set, the network model can learn and deeply understand the two-dimensional picture performance of the standard model when executing different preset action instructions at different shooting angles, and has the ability to deduce from the two-dimensional picture to the three-dimensional animation. In this way, when the initial animation information is input into the trained network model, the trained network model can output more accurate and more realistic skeletal animation information, and the target three-dimensional animation generated based on the skeletal animation information has a higher matching degree with the initial animation information. BRIEF DESCRIPTION OF THE DRAWINGS

[0060] In order to more clearly illustrate the technical solutions in the embodiments of the present invention, the following briefly introduces the drawings required for use in the description of the embodiments. Obviously, the drawings described below are some embodiments of the present invention. For ordinary technicians in this field, other drawings can be obtained based on these drawings without creative work.

[0061] Figure 1 A schematic diagram of a flow chart of a method for generating an animation provided by an embodiment of the present invention;

[0062] Figure 2 A schematic diagram of a process for generating a target three-dimensional animation provided by an embodiment of the present invention;

[0063] Figure 3 A schematic diagram of another process of generating a target three-dimensional animation provided by an embodiment of the present invention;

[0064] Figure 4 A schematic diagram of another process of generating a target three-dimensional animation provided by an embodiment of the present invention;

[0065] Figure 5 A schematic diagram of the structure of an animation generation device provided by an embodiment of the present invention;

[0066] Figure 6A schematic diagram of the structure of an electronic device provided by an embodiment of the present invention. DETAILED DESCRIPTION

[0067] In order to make the purpose, technical solution and advantages of the embodiments of the present invention clearer, the technical solution in the embodiments of the present invention will be clearly and completely described below in conjunction with the drawings in the embodiments of the present invention. Obviously, the described embodiments are part of the embodiments of the present invention, not all of the embodiments. Based on the embodiments of the present invention, all other embodiments obtained by ordinary technicians in this field without creative work are within the scope of protection of the present invention.

[0068] The terms used in the embodiments of the present invention are only for the purpose of describing specific embodiments, and are not intended to limit the present invention. The singular forms "a", "said" and "the" used in the embodiments of the present invention and the appended claims are also intended to include plural forms, unless the context clearly indicates other meanings, and "multiple" generally includes at least two.

[0069] As used herein, the words "if" and "if" may be interpreted as "at the time of" or "when" or "in response to determining" or "in response to detecting", depending on the context. Similarly, the phrases "if it is determined" or "if (stated condition or event) is detected" may be interpreted as "when it is determined" or "in response to determining" or "when detecting (stated condition or event)" or "in response to detecting (stated condition or event)", depending on the context.

[0070] In addition, the step sequence in the following method embodiments is only an example and not a strict limitation.

[0071] Figure 1 A flowchart of a method for generating an animation provided in an embodiment of the present invention is provided. The method can be applied to an electronic device, wherein the electronic device can be a terminal, a server, etc. with a certain computing power.

[0072] like Figure 1 As shown, the method comprises the following steps:

[0073] 101. Obtain a sample data set, where the sample data set includes a plurality of groups of sample two-dimensional images captured from a plurality of different angles during a process in which a preset standard model executes a preset action instruction, and sample skeletal animation information corresponding to each group of sample two-dimensional images.

[0074] 102. Based on the sample data set, the initial network model is trained so that the trained network model can predict corresponding skeletal animation information from the input initial animation information.

[0075] 103. Obtain initial animation information for generating three-dimensional animation.

[0076] 104. Generate target three-dimensional animation according to the initial animation information and the trained network model.

[0077] In practical applications, a sample data set can be set, and the initial network model can be trained through the sample data set, so that the trained network model can predict the corresponding skeletal animation information based on the input initial animation information. The following will introduce the training method of the network model.

[0078] It is understandable that in the above method, a preset standard model can be set first, and the size and structure of the standard model are default values. The standard model can be a humanoid model or a non-humanoid model. Then the standard model can be controlled to execute preset action instructions, such as charging, rushing, jabbing, hooking, swinging, swinging, jumping, chopping, backswinging, and looping.

[0079] In the process of the standard model executing the preset action instruction, the camera can be used to shoot the process of the standard model executing a preset action instruction at a certain angle, so that a set of sample two-dimensional images can be obtained. It can be understood that the sample two-dimensional images can also constitute a sample two-dimensional video. Referring to the above method, adjust the shooting angle of the camera, control the standard model to execute the above preset action instruction again, and let the camera shoot the process of the standard model executing the preset action instruction, so that a set of sample two-dimensional images shot at other angles can be obtained. Repeat the above method, by constantly adjusting the shooting angle or letting the standard model execute different preset action instructions, it is finally possible to obtain multiple sets of sample two-dimensional images shot from multiple different shooting angles when the standard model executes different preset action instructions. In another embodiment, cameras with multiple shooting angles can also be set at the same time to shoot the same action process, and the required multiple sets of sample two-dimensional images can also be obtained.

[0080] In addition to the above-mentioned multiple groups of sample two-dimensional images, sample skeleton animation information corresponding to each group of sample two-dimensional images can also be obtained, and multiple groups of sample two-dimensional images and sample skeleton animation information corresponding to each group of sample two-dimensional images are used as training content in the sample data set. It can be understood that when the standard model executes a preset action instruction, it is actually the bones in the standard model that move according to a certain rule to drive the standard model to complete the action. The movement of these bones can be expressed and recorded through the sample skeleton animation information. Therefore, not only can the sample two-dimensional images be obtained, but also the corresponding sample skeleton animation information can be obtained, and the two can be stored correspondingly as training content in the sample data set.

[0081] After obtaining enough training content in the sample data set, the initial network model can be trained through the sample data set. Among them, the network model can select a convolutional neural network model (Convolutional Neural Networks, abbreviated as CNN) or other types of models. Among them, the network model can also be called an artificial intelligence (Artificial Intelligence, abbreviated as AI) model. During the training process, any set of sample two-dimensional images can be input into the network model, and the network model outputs the predicted skeletal animation information, and then the predicted skeletal animation information and the sample skeletal animation information corresponding to the input sample two-dimensional image can be substituted into the loss function to calculate the loss value, and then the weights in the network model can be adjusted based on the loss value until the number of training times reaches the preset threshold or the loss value meets the requirements. After the training is completed, a network model that can predict the corresponding skeletal animation information from the input initial animation information can be obtained.

[0082] It should be noted that through the training process, the network model can fully understand the two-dimensional image performance of the standard model when executing different preset action instructions at different shooting angles, and has the ability to deduce from two-dimensional images to three-dimensional animations.

[0083] After obtaining the trained network model, the initial animation information for generating the three-dimensional animation can be obtained, and then the target three-dimensional animation can be generated according to the initial animation information and the trained network model. It should be noted that the target three-dimensional animation can be an animation generated by the target model executing a preset action instruction, that is, the process of executing the preset action instruction from the standard model is transferred to the process of executing the preset action instruction by the target model to generate a new three-dimensional animation.

[0084] The following uses several different application scenarios to illustrate the above method of generating a target three-dimensional animation.

[0085] like Figure 2 FIG. 1 is a flow chart of generating a target three-dimensional animation according to an embodiment of the present invention. The initial animation information may be first skeletal animation information extracted from an animation video according to a preset extraction method. Accordingly, the method may include the following steps:

[0086] 201. Input the first skeletal animation information into the trained network model to obtain optimized skeletal animation information.

[0087] 202. Redirect the optimized skeletal animation information to the target model to generate a target three-dimensional animation corresponding to the target model.

[0088] In practical applications, an animation video can be obtained, which can be a two-dimensional animation video, which contains a two-dimensional picture performance of other models when performing a certain action. The traditional skeletal animation extraction method can be used to extract the skeletal movement lines of other models from the two-dimensional animation video, that is, the first skeletal animation information. However, when the traditional skeletal animation extraction method is used to extract the first skeletal animation information, the requirements for the animation video are relatively high. For example, other models cannot be blocked, and it is best to shoot the process of other models performing actions from a front angle, etc. If the animation video is not shot under ideal conditions, it will cause great interference to the extraction of the first skeletal animation information, resulting in inaccurate extraction of the first skeletal animation.

[0089] Since the network model in the embodiment of the present invention has fully learned and understood the two-dimensional image performance of the standard model when executing different preset action instructions at different shooting angles, and has the ability to deduce from the two-dimensional image to the three-dimensional animation, even if the animation video is shot under non-ideal conditions, it can still deduce the obscured parts, etc., and can predict more accurate skeletal movement lines of other models, and output more accurate optimized skeletal animation information.

[0090] Based on this, the first skeleton animation information can be input into the trained network model to obtain optimized skeleton animation information. Alternatively, in some optional embodiments, the first skeleton animation information and the animation video can also be input into the trained network model to obtain optimized skeleton animation information.

[0091] It is understandable that in order to obtain the above network model, when setting the sample data set, the skeleton animation information can be extracted from multiple sample animation videos by the traditional skeleton animation extraction method, and the reference skeleton animation information corresponding to each animation video can be obtained at the same time. The reference skeleton animation information can be the skeleton animation information actually used by the standard model when performing the action, or it can also be the skeleton animation information manually marked. Then, the above-mentioned extracted skeleton animation information and the corresponding sample animation video can be input into the network model to obtain the skeleton animation information predicted by the network model. Then, the predicted skeleton animation information and the reference skeleton animation information can be substituted into the loss function to calculate the loss value, and the weight in the network model can be adjusted by the loss value. In this way, after the training is completed, the network model has the ability to optimize the first skeleton animation information based on the first skeleton animation information extracted by the traditional method and the corresponding animation video, so as to output the optimized skeleton animation information, and the optimized skeleton animation information should be more accurate than the first skeleton animation information and more in line with the real skeleton dynamic line. Among them, the following contents of the animation video can be optimized: strengthening the extraction of skeleton animation information under different working conditions such as lens changes, space changes, and character displacements.

[0092] After obtaining the optimized skeletal animation information output by the network model, the skeletal animation information can be redirected to the target model so that the target model can complete similar or identical actions with other models, and then the target three-dimensional animation generated in the process of the target model performing the above actions can be generated.

[0093] For example, assuming that character model A performs an uppercut and generates a corresponding animation video, the first skeletal animation information can be extracted in a traditional way, and the first skeletal animation information depicts the skeletal motion line of the uppercut. The first skeletal animation information and the above-mentioned animation video can be input into the trained network model, and the trained network model can output optimized skeletal animation information, and the optimized skeletal animation information depicts a more accurate skeletal motion line of the uppercut. The optimized skeletal animation information can be redirected to character model B, so that character model B can perform the uppercut action, and generate the corresponding target three-dimensional animation based on the process of character model B performing the uppercut.

[0094] In another optional embodiment, the sample skeletal animation information may be annotated with a sample action description label. For example, the sample skeletal animation information corresponding to the hook punch action performed by the standard model is annotated with the sample action description label of "hook punch". By analogy, the sample skeletal animation information corresponding to the actions of charging, charging, jabbing, swinging, swinging, jumping, chopping, and backswinging may be annotated with the sample action description labels of "charging", "charging", "jabbing", "swinging", "swinging", "jumping", "chopping", and "backswinging" in turn.

[0095] In some optional embodiments, the sample action description labels may be further classified. For example, take-off-left, take-off-right, and take-off-both feet. By dividing the take-off into more detailed sample action description labels with different action performances, the network model may be able to perform more detailed classification of the take-offs with different action performances.

[0096] It is understandable that the sample action description labels can be used as training content in the sample data set to train the network model, so that the trained network model can not only deduce to three-dimensional animation based on two-dimensional images, but also understand the elements and types of different actions. Based on this, optionally, the process of training the initial network model based on the sample data set can be implemented as follows: based on the sample data set, the initial network model is trained so that the trained network model can output matching skeletal animation information based on the input action description labels.

[0097] Based on the above network model, Figure 3FIG. 1 is another flow chart of generating a target three-dimensional animation according to an embodiment of the present invention. The initial animation information may be text description information. Accordingly, the method may include the following steps:

[0098] 301. Receive first text description information input by a user.

[0099] 302. Input the first text description information into the trained network model to obtain second skeletal animation information matching the first text description information.

[0100] 303. Redirect the second skeletal animation information to the target model to generate a target three-dimensional animation corresponding to the target model.

[0101] In actual applications, the user can input the first text description information corresponding to the target action performed by the target model in the target three-dimensional animation that he wants to generate. For example, the user can input: After a short period of accumulation, rush forward and swing the right fist. Accordingly, "After a short period of accumulation, rush forward and swing the right fist" can be determined as the first text description information, and the first text description information can be input into the trained network model. According to the action description label obtained by processing the first text description information, the second skeletal animation information that can express the action of "rush forward and swing the right fist after a short period of accumulation" can be obtained. Then, the second skeletal animation information can be redirected to the target model, so that the target three-dimensional animation corresponding to the action performed by the target model that matches the first text description information input by the user can be generated.

[0102] Alternatively, if the trained network model has the ability to recognize multiple action elements, the user is allowed to input more detailed first text description information, such as: charging (1.2 seconds), charging (3 meters), throwing a right punch (jab / hook / swing punch). The action elements may be, for example, the duration of a certain action, the moving distance of a certain action, a deeper classification of a certain action, etc.

[0103] In some optional embodiments, the target three-dimensional animation can also be displayed to the user. After watching the target three-dimensional animation, if the user is not satisfied with some parts of it, the user can adjust the target three-dimensional animation. Based on this, optionally, the method provided by the embodiment of the present invention can also include: in response to the user's replacement operation on the target frame sequence in the target three-dimensional animation, obtaining the second text description information input by the user; inputting the second text description information into the trained network model to obtain the third skeletal animation information matching the second text description information; replacing the part of the second skeletal animation information corresponding to the target frame sequence with the third skeletal animation information; redirecting the replaced second skeletal animation information to the target model.

[0104] For example, suppose that a target three-dimensional animation corresponding to a short-term accumulation of power and a forward rush and a hook punch is generated. After watching the target three-dimensional animation, the user wants to replace the action of throwing a hook punch with the action of throwing a jab. First, the user can select the target frame sequence corresponding to the hook punch in the target three-dimensional animation and check the target frame sequence. In response to the user's replacement operation on the target frame sequence, a second text description information input by the user can be received, and the second text description information is used to describe the need to replace the checked target frame sequence with a frame sequence with other style actions. For example, after checking the target frame sequence corresponding to the hook punch, the user can enter: jab. In this way, the jab can be set as the second text description information, and then the second text description information can be input into the trained network model to obtain the third skeletal animation information matching the second text description information. In this way, the trained network model can output the third skeletal animation information corresponding to the jab action. Then, the part corresponding to the hook punch can be determined in the second skeletal animation information, and then the determined part can be replaced with the third skeletal animation information. Finally, the replaced second skeleton animation information can be redirected to the target model, so that the target model can perform the action of rushing forward and throwing a jab after a short accumulation of power.

[0105] like Figure 4 FIG. 1 is another flow chart of generating a target three-dimensional animation provided by an embodiment of the present invention. The initial animation information may be the initial three-dimensional animation and modification description information for modifying the character action in the initial three-dimensional animation. Accordingly, the method may include the following steps:

[0106] 401. Input the initial 3D animation and the modified description information into the trained network model to obtain fourth skeletal animation information.

[0107] 402. Redirect the fourth skeletal animation information to the target model to generate a target three-dimensional animation corresponding to the target model.

[0108] Optionally, the modified description information may include, but is not limited to, description information on the animation playback mode, description information on specific action elements in the animation, and / or description information on action effects in the animation.

[0109] The initial three-dimensional animation may be captured during the process of the character model A performing action S1. Assuming that the user is not satisfied with some details in action S1, the user can input modification description information. For example, the initial three-dimensional animation is an attack animation, and the user can input: the pre-swing time is lengthened, and the sense of attack force is enhanced. Then, "the pre-swing time is lengthened, and the sense of attack force is enhanced" can be determined as the modification description information, and then the attack animation and the modification description information are input into the trained network model. The trained network model can adjust the attack animation to lengthen the pre-swing time and enhance the sense of attack force, thereby meeting the user's expectations. Then, after obtaining the fourth skeletal animation information output by the trained network model, the fourth skeletal animation information can be redirected to the target model to generate a target three-dimensional animation corresponding to the target model.

[0110] Alternatively, the user can also adjust the animation playback mode. For example, in an attack animation, the beginning of the animation is a backswing action. The user can enter: add 1 second of backswing to make it a looping animation. In this way, another 1 second of backswing will be added to the end of the attack animation, and the first and last frames of the modified attack animation will be the same, turning it into a looping animation.

[0111] Alternatively, the user may also adjust specific action elements in the animation. For example, the user may input: generate a continuous subsequent attack animation. In this way, the first frame and the last frame of the modified animation are the same.

[0112] By adopting the present invention, it is no longer necessary for technicians to manually input skeletal animation information. The initial network model can be trained, and by reasonably setting the sample data set, the network model can learn and deeply understand the two-dimensional picture performance of the standard model when executing different preset action instructions at different shooting angles, and has the ability to deduce from the two-dimensional picture to the three-dimensional animation. In this way, when the initial animation information is input into the trained network model, the trained network model can output more accurate and more realistic skeletal animation information, and the target three-dimensional animation generated based on the skeletal animation information has a higher degree of conformity with the initial animation information.

[0113] The following will describe in detail the animation generation device of one or more embodiments of the present invention. Those skilled in the art will appreciate that these animation generation devices can be configured using commercially available hardware components through the steps taught in this solution.

[0114] Figure 5 A schematic diagram of the structure of an animation generation device provided by an embodiment of the present invention, such as Figure 5 As shown, the device comprises:

[0115] An acquisition module 51 is used to acquire a sample data set, wherein the sample data set includes a plurality of groups of sample two-dimensional images taken from a plurality of different angles during the process of a preset standard model executing a preset action instruction, and sample skeleton animation information corresponding to each group of sample two-dimensional images;

[0116] A training module 52, used for training the initial network model based on the sample data set, so that the trained network model can predict the corresponding skeletal animation information from the input initial animation information;

[0117] The acquisition module 51 is used to acquire initial animation information for generating a three-dimensional animation;

[0118] The generating module 53 is used to generate a target three-dimensional animation according to the initial animation information and the trained network model.

[0119] Optionally, the initial animation information is first skeletal animation information extracted from an animation video according to a preset extraction method;

[0120] The generating module 53 is used for:

[0121] Inputting the first skeletal animation information into the trained network model to obtain optimized skeletal animation information;

[0122] The optimized skeletal animation information is redirected to a target model to generate a target three-dimensional animation corresponding to the target model.

[0123] Optionally, the sample skeletal animation information is annotated with a sample action description tag;

[0124] The training module 52 is used to:

[0125] Based on the sample data set, the initial network model is trained so that the trained network model can output matching skeletal animation information based on the input action description label.

[0126] Optionally, the initial animation information is text description information;

[0127] The acquisition module 51 is used to receive first text description information input by a user;

[0128] The generation module 53 is used to input the first text description information into the trained network model to obtain second skeletal animation information matching the first text description information; and redirect the second skeletal animation information to the target model to generate a target three-dimensional animation corresponding to the target model.

[0129] Optionally, the device further comprises a modification module, wherein the modification module is configured to:

[0130] In response to the user's replacement operation on the target frame sequence in the target three-dimensional animation, acquiring second text description information input by the user;

[0131] Inputting the second text description information into the trained network model to obtain third skeletal animation information matching the second text description information;

[0132] Replace the portion of the second skeletal animation information corresponding to the target frame sequence with the third skeletal animation information;

[0133] Redirecting the replaced second skeletal animation information to the target model.

[0134] Optionally, the initial animation information is an initial three-dimensional animation and modification description information for modifying a character action in the initial three-dimensional animation;

[0135] The generating module 53 is used for:

[0136] Inputting the initial three-dimensional animation and the modification description information into the trained network model to obtain fourth skeletal animation information;

[0137] The fourth skeletal animation information is redirected to the target model to generate a target three-dimensional animation corresponding to the target model.

[0138] Optionally, the modification description information includes description information on the animation playback mode, description information on specific action elements in the animation, and / or description information on action effects in the animation.

[0139] Figure 5 The device shown can perform the aforementioned Figures 1 to 4 The animation generation method provided in the illustrated embodiment, the detailed execution process and technical effects are described in the aforementioned embodiment and will not be repeated here.

[0140] In one possible design, the above Figure 5 The structure of the animation generating device shown can be realized as an electronic device, such as Figure 6 As shown, the electronic device may include: a processor 91 and a memory 92. The memory 92 stores executable code, and when the executable code is executed by the processor 91, the processor 91 can at least implement the above-mentioned Figures 1 to 4 The animation generation method provided in the illustrated embodiment.

[0141] Optionally, the electronic device may further include a communication interface 93 for communicating with other devices.

[0142] In addition, an embodiment of the present invention provides a non-transitory machine-readable storage medium, wherein an executable code is stored on the non-transitory machine-readable storage medium. When the executable code is executed by a processor of an electronic device, the processor can at least implement the above-mentioned Figures 1 to 4 The animation generation method provided in the illustrated embodiment.

[0143] The device embodiments described above are merely illustrative, wherein the units described as separate components may or may not be physically separated. Some or all of the modules may be selected according to actual needs to achieve the purpose of the present embodiment. Those of ordinary skill in the art may understand and implement the present invention without creative effort.

[0144] Through the description of the above embodiments, those skilled in the art can clearly understand that each embodiment can be implemented by adding a necessary general hardware platform, and of course can also be implemented by combining hardware and software. Based on such an understanding, the above technical solution is essentially or the part that contributes to the prior art can be embodied in the form of a computer product, and the present invention can be in the form of a computer program product implemented on one or more computer-usable storage media (including but not limited to disk storage, CD-ROM, optical storage, etc.) containing computer-usable program codes.

[0145] The animation generation method provided in the embodiment of the present invention can be executed by a certain program / software, and the program / software can be provided by the network side. The electronic device mentioned in the above embodiment can download the program / software to a local non-volatile storage medium, and when it needs to execute the above animation generation method, the program / software is read into the memory by the CPU, and then the CPU executes the program / software to implement the animation generation method provided in the above embodiment. The execution process can refer to the above Figures 1 to 4 Instructions in .

[0146] Finally, it should be noted that the above embodiments are only used to illustrate the technical solutions of the present invention, rather than to limit it. Although the present invention has been described in detail with reference to the aforementioned embodiments, those skilled in the art should understand that they can still modify the technical solutions described in the aforementioned embodiments, or make equivalent replacements for some of the technical features therein. However, these modifications or replacements do not deviate the essence of the corresponding technical solutions from the spirit and scope of the technical solutions of the embodiments of the present invention.

Claims

1. A method for generating an animation, characterized in that: include: Acquire a sample data set, wherein the sample data set includes a plurality of groups of sample two-dimensional images taken from a plurality of different angles during the process of a preset standard model executing a preset action instruction, and sample skeleton animation information corresponding to each group of sample two-dimensional images; Based on the sample data set, the initial network model is trained so that the trained network model can predict the corresponding skeletal animation information from the input initial animation information; Acquire initial animation information for generating three-dimensional animation; A target three-dimensional animation is generated according to the initial animation information and the trained network model.

2. The method according to claim 1, characterized in that The initial animation information is first skeletal animation information extracted from the animation video according to a preset extraction method; Generating a target three-dimensional animation according to the initial animation information and the trained network model includes: Inputting the first skeletal animation information into the trained network model to obtain optimized skeletal animation information; The optimized skeletal animation information is redirected to a target model to generate a target three-dimensional animation corresponding to the target model.

3. The method according to claim 1, characterized in that The sample skeletal animation information is annotated with a sample action description label; The training of the initial network model based on the sample data set includes: Based on the sample data set, the initial network model is trained so that the trained network model can output matching skeletal animation information based on the input action description label.

4. The method according to claim 3, characterized in that: The initial animation information is text description information; The obtaining of initial animation information for generating a three-dimensional animation comprises: Receive first text description information input by a user; Generating a target three-dimensional animation according to the initial animation information and the trained network model includes: Inputting the first text description information into the trained network model to obtain second skeletal animation information matching the first text description information; The second skeletal animation information is redirected to a target model to generate a target three-dimensional animation corresponding to the target model.

5. The method according to claim 4, characterized in that The method further comprises: In response to the user's replacement operation on the target frame sequence in the target three-dimensional animation, acquiring second text description information input by the user; Inputting the second text description information into the trained network model to obtain third skeletal animation information matching the second text description information; Replace the portion of the second skeletal animation information corresponding to the target frame sequence with the third skeletal animation information; Redirecting the replaced second skeletal animation information to the target model.

6. The method according to claim 1, characterized in that The initial animation information is an initial three-dimensional animation and modification description information for modifying a character action in the initial three-dimensional animation; Generating a target three-dimensional animation according to the initial animation information and the trained network model includes: Inputting the initial three-dimensional animation and the modification description information into the trained network model to obtain fourth skeletal animation information; The fourth skeletal animation information is redirected to the target model to generate a target three-dimensional animation corresponding to the target model.

7. The method according to claim 6, characterized in that The modification description information includes description information of the animation playing mode, description information of specific action elements in the animation, and / or description information of the action effects in the animation.

8. An animation generating device, characterized in that: include: An acquisition module is used to acquire a sample data set, wherein the sample data set includes a plurality of groups of sample two-dimensional images taken from a plurality of different angles during the process of a preset standard model executing a preset action instruction, and sample skeleton animation information corresponding to each group of sample two-dimensional images; A training module, used for training the initial network model based on the sample data set, so that the trained network model can predict the corresponding skeletal animation information from the input initial animation information; The acquisition module is used to acquire initial animation information for generating three-dimensional animation; A generation module is used to generate a target three-dimensional animation according to the initial animation information and the trained network model.

9. An electronic device, characterized in that: include: A memory and a processor; wherein the memory stores executable codes, and when the executable codes are executed by the processor, the processor executes the animation generation method according to any one of claims 1 to 7.

10. A non-transitory machine-readable storage medium, characterized in that: The non-transitory machine-readable storage medium stores executable codes, and when the executable codes are executed by a processor of an electronic device, the processor is caused to execute the animation generation method according to any one of claims 1 to 7.