Video generation method, electronic equipment, storage medium and computer program product
By analyzing athlete video data and generating competition videos, it displays the animation performance of athletes in different sports, solving the problem of single performance differences in athlete abilities in the existing technology, achieving dynamic display of differences, and improving the user's viewing experience. .
Patent Information
- Application Number
- CN202410823646.3
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2024-06-24
- Publication Date
- 2024-10-25
AI Technical Summary
In terms of displaying the differences in athletes' abilities, the existing technology only expresses the differences in a single form, making it difficult for users to intuitively perceive the differences in abilities between athletes through pure text.
By analyzing athletes' video data, extracting physical information and rendering animations of athletes' digital objects, we can generate game videos, display athletes' game videos in different sports, and provide dynamic and differentiated expressions.
Through animation rendering and video display, users can intuitively perceive the physical differences between multiple athletes, improve the viewing experience, and eliminate the single performance limitation of pure text form.
Smart Images

Figure CN118842973A_ABST
Abstract
Description
Technical Field
[0001] The present disclosure relates to the technical field of artificial intelligence, and in particular to a video generation method, an electronic device, a storage medium, and a computer program product. Background Art
[0002] In sports events, when users are watching live broadcasts or replays, the event screen will display the athletes' corresponding event data under various event judging dimensions. By comparing different event data corresponding to different athletes, users can perceive the ability differences between different athletes.
[0003] But for now, the competition data in pure text format is very abstract, which makes it difficult for users to intuitively perceive the ability differences between different athletes.
[0004] That is to say, in terms of showing the differences in abilities of different athletes, the differences provided by relevant technologies are relatively simple. Summary of the invention
[0005] The purpose of the present disclosure is to provide a video generation method, an electronic device, a storage medium and a computer program product, which are used to solve the technical problem that the related technologies provide a single form of expression of differences in the abilities of different athletes.
[0006] In a first aspect, an embodiment of the present disclosure provides a video generation method, the method comprising:
[0007] Obtain N sports videos of N athletes in M1 first sports events, wherein the N athletes correspond to the N sports videos one by one, N is an integer greater than 1, and M1 is a positive integer less than or equal to N;
[0008] Analyze the sports video of each athlete to obtain physical fitness information of each athlete;
[0009] According to the physical fitness information of each athlete, N athlete digital objects are animated and rendered to obtain game videos of the N athlete digital objects in a second sport. The N athlete digital objects correspond one-to-one to the N athletes, and the first sport and the second sport are different sports.
[0010] In one embodiment, the number of the second sports events is M2, the number of the game videos is M3, M3 is an integer greater than or equal to M2, and M2 is a positive integer.
[0011] In one embodiment, analyzing the sports video of each athlete to obtain the physical fitness information of each athlete includes:
[0012] Traversing the N sports videos to obtain N individual physical fitness information, wherein the N individual physical fitness information corresponds to the N athletes one by one;
[0013] The traversal step of the nth motion video among the N motion videos includes:
[0014] In the nth sports video, collecting sports information corresponding to a preset key action of the nth athlete, wherein the preset key action is used to quantify the sports performance of the athlete in the first sports event, where n is a positive integer less than or equal to N;
[0015] The motion information of the nth athlete corresponding to the preset key action is analyzed to obtain the nth physical fitness information.
[0016] In one embodiment, the time period during which the nth athlete completes the preset key action is the key action period, and the motion information of the nth athlete corresponding to the preset key action includes: the position change of the nth athlete in the key action period, and / or the position change of the first target object associated with the nth athlete in the key action period;
[0017] The analyzing the motion information of the nth athlete corresponding to the preset key action to obtain the nth physical fitness information includes:
[0018] The position change of the nth athlete during the key action period and / or the position change of the first target object associated with the nth athlete during the key action period are analyzed to obtain the nth physical fitness information.
[0019] In one embodiment, the physical fitness information includes at least one of the following:
[0020] First physical fitness data for indicating the horizontal movement ability of the athlete, wherein the first physical fitness data includes a maximum running rate of the corresponding athlete;
[0021] Second physical fitness data for indicating the rotational ability of the athlete, wherein the second physical fitness data includes a maximum turning rate of the corresponding athlete;
[0022] The third physical fitness data for indicating the throwing ability of the athlete, wherein the third physical fitness data includes the longest throwing distance of the athlete throwing an object of unit weight;
[0023] Fourth physical fitness data for indicating the jumping ability of the athlete, the fourth physical fitness data comprising a maximum jumping translation rate of the corresponding athlete;
[0024] The fifth physical fitness data is used to indicate the vertical movement ability of the athlete, and the fifth physical fitness data includes the maximum jumping lift-off rate of the corresponding athlete.
[0025] In one embodiment, the step of performing animation rendering on the N digital objects of athletes according to the physical fitness information of each athlete to obtain a game video of the N digital objects of athletes in a second sport includes:
[0026] According to the physical fitness information of each athlete, in a preset game scene, animation rendering is performed on the N athlete digital objects and a second target object in the preset game scene to obtain the game video, wherein the second target object is an object in the preset game scene whose position changes due to the athlete's action.
[0027] In one embodiment, after performing animation rendering on the N digital objects of athletes according to the physical fitness information of each athlete to obtain a game video of the N digital objects of athletes in a second sport, the method further includes:
[0028] Determining video subtitles according to the physical fitness information of each athlete, the video subtitles including: identity information of the N athletes and competition results of the N athletes in the second sports event;
[0029] The video subtitles are added to the game video of the N athlete digital objects in the second sport.
[0030] In a second aspect, an embodiment of the present disclosure further provides an electronic device, comprising a processor, a memory, and a computer program stored in the memory and executable on the processor, wherein the computer program implements the steps of the above-mentioned video generation method when executed by the processor.
[0031] In a third aspect, an embodiment of the present disclosure further provides a computer-readable storage medium, on which a computer program is stored, and when the computer program is executed by a processor, the steps of the above-mentioned video generation method are implemented.
[0032] In a fourth aspect, an embodiment of the present disclosure further provides a computer program product, comprising computer instructions, which, when executed by a processor, implement the steps of the method described in the first aspect.
[0033] In the disclosed embodiment, sports videos of multiple athletes are analyzed to obtain physical fitness information of each athlete, and the athlete digital object corresponding to each athlete is animated based on the obtained physical fitness information to form a game video. The physical fitness differences between the multiple athletes are dynamically displayed through the differences in competitive levels shown by the digital objects of each athlete in the game video, so as to provide users with a dynamic difference expression form in addition to the pure text form in terms of expressing the ability differences between different athletes, thereby enhancing the user's viewing experience. BRIEF DESCRIPTION OF THE DRAWINGS
[0034] Figure 1 is a flowchart of a video generation method provided by an embodiment of the present disclosure;
[0035] Figure 2 It is a flowchart of a method for generating a video of a digital human athlete participating in a sports competition by using competition data provided by an embodiment of the present disclosure;
[0036] Figure 3 is a structural schematic diagram of a video generating device provided by an embodiment of the present disclosure;
[0037] Figure 4 It is a schematic diagram of an electronic device provided by an embodiment of the present disclosure. DETAILED DESCRIPTION
[0038] The following will be combined with the drawings in the embodiments of the present disclosure to clearly and completely describe the technical solutions in the embodiments of the present disclosure. Obviously, the described embodiments are part of the embodiments of the present disclosure, rather than all of the embodiments. Based on the embodiments in the present disclosure, all other embodiments obtained by ordinary technicians in this field without creative work are within the scope of protection of the present disclosure.
[0039] The present disclosure provides a video generation method. Figure 1 As shown, the video generation method includes:
[0040] Step 101: Obtain N sports videos of N athletes in M1 first sports events.
[0041] There is a one-to-one correspondence between the N athletes and the N sports videos, N is an integer greater than 1, and M1 is a positive integer less than or equal to N.
[0042] The first sports item mentioned above may be any sports item, for example, basketball, football, volleyball, badminton, table tennis, etc.
[0043] Each sports video is a video of an athlete participating in a competition activity of the first sports event. Different sports videos corresponding to different athletes may correspond to the same first sports event or different first sports events.
[0044] For example, the N sports videos may include sports videos of basketball player A and sports videos of football player B, and may also include sports videos of badminton player C and sports videos of badminton player D.
[0045] It should be understood that, when different sports videos corresponding to different athletes correspond to the same first sports event, the different sports videos may be from the same event, for example, the different sports videos are videos of different athletes participating in the same basketball game.
[0046] Of course, the different sports videos may also come from different events, for example, the different sports videos are videos of different athletes participating in different football games.
[0047] Step 102: Analyze the sports video of each athlete to obtain the physical fitness information of each athlete.
[0048] The physical fitness information is used to represent the physical fitness of the corresponding athlete in the corresponding sports video. For example, the physical fitness may include several dimensions such as jumping height, throwing, running, jumping distance, turning, etc.
[0049] Step 103: Perform animation rendering on the N digital objects of athletes according to the physical fitness information of each athlete to obtain a game video of the N digital objects of athletes in a second sport.
[0050] There is a one-to-one correspondence between the N athlete digital objects and the N athletes, and the first sports event and the second sports event are different sports events.
[0051] In the disclosed embodiment, sports videos of multiple athletes are analyzed to obtain physical fitness information of each athlete, and the athlete digital object corresponding to each athlete is animated based on the obtained physical fitness information to form a game video. The physical fitness differences between the multiple athletes are dynamically displayed through the differences in competitive levels shown by the digital objects of each athlete in the game video, so as to provide users with a dynamic difference expression form in addition to the pure text form in terms of expressing the ability differences between different athletes, thereby enhancing the user's viewing experience.
[0052] In one example, when a user watches a recording or live broadcast of a game, through the application of the above method, after the user selects several athletes to participate in the game, several sports videos of the athletes selected by the user in the game can be used as the aforementioned N sports videos. After the aforementioned physical fitness information is acquired and animation rendering is performed, a game video is generated so that the user can intuitively perceive the performance differences of the athletes selected by the user in the game.
[0053] It should be understood that the user may also select several athletes from different competitions as the aforementioned N athletes.
[0054] In some implementations, a corresponding athlete digital object may be generated based on the character features (such as facial features, height, weight, etc.) of each of the N athletes. In this case, the N athlete digital objects are different.
[0055] In some embodiments, the N athlete digital objects may be the same. In this case, each athlete digital object needs to be identified in the game video by a first floating frame including a character portrait of the corresponding athlete and / or a second floating frame including the name of the corresponding athlete. This can simplify the generation process of the at least two athlete digital objects while avoiding interference caused by object differences between different athlete digital objects, so that users can more intuitively perceive the differences in competitive levels between different athlete digital objects.
[0056] It should be noted that the application of the method disclosed in the present invention is implemented on the premise of obtaining the authorization permission of the corresponding athletes.
[0057] In one embodiment, the number of the second sports events is M2, the number of the game videos is M3, M3 is an integer greater than or equal to M2, and M2 is a positive integer.
[0058] In this embodiment, the game video may be one, or may be two or more.
[0059] As mentioned above, the physical fitness information includes corresponding multiple dimensions, and one game video is used to represent the difference between the N athletes in one dimension. When the number of the game videos is two or more, any two different game videos among the two or more game videos can correspond to the same dimension or different dimensions.
[0060] Preferably, the second sports event may be an event that is more effective in accommodating the ability differences of different athletes in a specific physical fitness dimension than the first sports event.
[0061] In one example, any two different competition videos mentioned above may respectively reflect the competition situation of the N athletes in a 30-meter sprint competition and the competition situation of the N athletes in a 100-meter sprint competition.
[0062] In another example, any two different competition videos mentioned above may respectively reflect the competition situation of the N athletes in a 30-meter sprint competition and the competition situation of the N athletes in a shot put competition.
[0063] In one embodiment, analyzing the sports video of each athlete to obtain the physical fitness information of each athlete includes: traversing the N sports videos to obtain N pieces of physical fitness information, wherein the N pieces of physical fitness information correspond one-to-one to the N athletes.
[0064] Among them, the traversal steps of the nth sports video among the N sports videos include: in the nth sports video, collecting the sports information of the nth athlete corresponding to the preset key action, the preset key action is used to quantify the athlete's sports performance in the first sports event, and n is a positive integer less than or equal to N; analyzing the sports information of the nth athlete corresponding to the preset key action to obtain the nth physical fitness information.
[0065] Specifically, the relevant actions used to demonstrate the athlete's technical and tactical performance in the first sports event can be determined as the preset key actions, so as to adapt to the conventional data representation of the athlete's sports performance in the first sports event, making the application of the method described in the present disclosure more flexible.
[0066] Exemplarily, when the first sport is basketball, the above-mentioned preset key actions may be rebounding, assists, steals, blocks, shots, free throws, front and back boards, turnovers and fouls; and when the first sport is volleyball, the above-mentioned preset key actions may be blocking, spiking, serving, passing, and cushioning.
[0067] For example, when the first sports event is basketball, the data collection of preset key actions may include at least one of the following: block data collection, shooting data collection, running data collection, three-step layup data collection, and center rotation data collection.
[0068] Among them, block data collection refers to the situation where, when the opponent shoots, the monitored athlete judges the flight trajectory of the basketball and chooses the appropriate time and position to jump up to grab the basketball back into his own hands. The height of the athlete's jump on the spot and the time to reach the highest point of the jump height are collected, and the aforementioned motion information is formed accordingly.
[0069] Shooting data collection means that when an athlete maintains a standing posture and scores by throwing the basketball into the basket, the shooting position of the basketball, the horizontal distance the basketball moves when it touches the next object, the time the basketball moves, and the angle between the moving position of the basketball and the horizontal plane can be collected during the process of the athlete throwing the basketball, and the aforementioned motion information can be formed based on this.
[0070] Running data collection refers to collecting the distance moved between two points on the court and the moving time during this period without the athlete touching the basketball, and forming the aforementioned motion information based on this.
[0071] The three-step layup data collection refers to when an athlete completes an offensive shooting action within three steps, the data from the athlete's starting position to the landing position of the third step is collected, and the jump distance and the time to complete this jump distance are recorded to form the aforementioned motion information.
[0072] Center rotation data collection refers to collecting the athlete's rotation angle from the start to the end of the rotation and recording the time to complete the entire rotation action when the athlete is defending with the ball and without leaving the ground, and rotating the body with the center of the body as the axis to create a fake move. This forms the aforementioned motion information.
[0073] Exemplarily, when the first sports event is basketball, the trained neural network model can be used to complete the recognition of preset key actions corresponding to the athlete in the sports video, and when the preset key actions corresponding to the athlete are recognized in the video picture, the trained target detection model is used to detect the basketball position, the athlete position, etc. in the video picture, and the above-mentioned sports information collection work is completed in combination with timestamp difference calculation and other methods.
[0074] In one embodiment, the time period during which the nth athlete completes the preset key action is the key action period, and the motion information of the nth athlete corresponding to the preset key action includes: the position change of the nth athlete during the key action period, and / or the position change of the first target object associated with the nth athlete during the key action period.
[0075] The analyzing the motion information of the nth athlete corresponding to the preset key action to obtain the nth individual energy information includes: analyzing the position change of the nth athlete during the key action period, and / or analyzing the position change of the first target object associated with the nth athlete during the key action period to obtain the nth individual energy information.
[0076] Exemplarily, the position change of the athlete in the key action period may include: the horizontal movement distance of the athlete in the key action period, the vertical movement distance of the athlete in the key action period, and the turning angle.
[0077] The first target object associated with the nth athlete may be understood as an object whose position changes due to manipulation by the athlete, such as a volleyball, basketball, badminton, football, etc.
[0078] The position change of the first target object in the key action period may include: a horizontal movement distance of the first target object in the key action period, and a vertical movement distance of the first target object in the key action period.
[0079] In one embodiment, the physical fitness information includes at least one of the following: a first physical fitness data for indicating the athlete's horizontal movement ability; a second physical fitness data for indicating the athlete's rotation ability; a third physical fitness data for indicating the athlete's throwing ability; a fourth physical fitness data for indicating the athlete's jumping ability; and a fifth physical fitness data for indicating the athlete's vertical movement ability.
[0080] In this embodiment, the representation of the physical fitness differences between different athletes is enriched by setting multiple pieces of physical fitness data, and combined with the setting of at least one game video described in the present disclosure, the physical fitness differences between different athletes are fully demonstrated.
[0081] For example, taking a basketball game as an example, when the sports information includes block data, shooting data, running data, three-step layup data, and center rotation data:
[0082] To quantify the horizontal movement ability, the athlete's running movements can be monitored and the ratio of the horizontal movement distance corresponding to the running movement to the time to complete the entire running movement can be calculated. The formula is: g = e / f, where g refers to the horizontal movement ability reflected by the corresponding athlete when completing a running movement, e refers to the horizontal movement distance corresponding to the athlete when completing a running movement, and f refers to the time it takes for the athlete to complete a blocking action.
[0083] The quantitative calculation of rotation ability can monitor the athlete's ball-holding defensive actions and calculate the ratio of the rotation angle to the time to complete the entire rotation action. The formula is: j = h / i, where j refers to the rotation ability reflected by the corresponding athlete when completing a ball-holding defensive action, h refers to the rotation angle of the athlete when completing a ball-holding defensive action, and i refers to the time it takes for the athlete to complete a ball-holding defensive action.
[0084] To quantify the throwing ability, the athlete's shooting action can be monitored, and the ratio of the horizontal distance the basketball moves to the weight of the standard basketball can be calculated. The formula is: m=k / y or m=k / z, where m refers to the throwing ability reflected by the corresponding athlete when completing a shooting action, k refers to the horizontal distance the basketball moves when the athlete completes a shooting action, y indicates the weight of the standard ball for men's basketball games, and z indicates the weight of the standard ball for women's basketball games. Specifically, y=650 is the male basketball ball, and z=550 is the female basketball ball, both in grams.
[0085] Quantitative calculation of jumping ability can be achieved by calculating the ratio of the horizontal distance of the third jump and the time to complete this jump distance when the athlete completes a three-step layup. The formula is: r=p / q, where r refers to the horizontal jumping ability reflected by the corresponding athlete when completing a three-step layup, p refers to the maximum horizontal moving distance of the athlete when completing a three-step layup, and q refers to the time for the athlete to complete the maximum horizontal moving distance in a three-step layup.
[0086] The quantitative calculation of vertical movement ability can be achieved by calculating the ratio of the height of the take-off from the spot and the time to reach the top of the jump height when the athlete completes a block action. The formula is: x=v / w, where x refers to the horizontal movement ability reflected by the corresponding athlete when completing a block action, v refers to the take-off height of the athlete when completing a block action, and w refers to the time for the athlete to reach the top of the jump height when completing a block action.
[0087] In one embodiment, the first physical fitness data includes the maximum running rate of the corresponding athlete; the second physical fitness data includes the maximum turning rate of the corresponding athlete; the third physical fitness data includes the longest throwing distance of the corresponding athlete when throwing an object of unit weight; the fourth physical fitness data includes the maximum jumping translation rate of the corresponding athlete; and the fifth physical fitness data includes the maximum jumping lift-off rate of the corresponding athlete.
[0088] In the first sports event, the sports information collected from the corresponding athletes may include at least two sports data corresponding to the same physical fitness index. The best physical fitness data of the athlete in each physical fitness index is selected by maximum value screening as the data representative of the athlete in each physical fitness index, so as to fully show the differences between different athletes in various physical fitness indicators.
[0089] In one embodiment, the step of performing animation rendering on the N digital objects of athletes according to the physical fitness information of each athlete to obtain a game video of the N digital objects of athletes in a second sport includes:
[0090] According to the physical fitness information of each athlete, in a preset game scene, animation rendering is performed on the N athlete digital objects and a second target object in the preset game scene to obtain the game video, wherein the second target object is an object in the preset game scene whose position changes due to the athlete's action.
[0091] In the preset game scene, while the athlete's corresponding digital object is animated based on the athlete's physical information, the animation rendering of the second target object that is associated with the athlete's digital object is also completed accordingly, so as to enhance the picture performance effect of the game video and provide users with a better event viewing experience.
[0092] The second target object may also be understood as an object in the preset game scene whose position changes due to the influence of the athlete digital object.
[0093] Animation rendering of the athlete's digital object based on physical fitness information can be understood as: animation rendering of the athlete's digital object's running, turning, jumping and other movements based on the running rate, turning rate, jumping translation rate, jumping lift-off rate, etc. indicated by the physical fitness information.
[0094] In the application, the rendering of related auxiliary actions of the athlete's digital object can also be controlled based on physical information and / or preset parameters to further enhance the visual effect of the game video. The related auxiliary actions can be: run-up action, start preparation action, standing action, deceleration action after sprinting, lying down action after high jumping over the pole, etc.
[0095] Among them, the second target object associated with the athlete digital object in the preset competition scene can be: a shot put, a javelin, and a ribbon indicating the finish line of a sprint, etc.; the operation of animation rendering the second target object can be: rendering the flight trajectory, landing point picture, and ruler picture of objects such as a shot put and a javelin, as well as rendering the picture of the ribbon breaking when the athlete sprints to the finish line.
[0096] The above-mentioned preset game scene may include a game background environment, staff digital objects used to refer to game staff, and audience digital objects used to refer to game spectators, so as to better simulate the game environment.
[0097] In one embodiment, after performing animation rendering on the N digital objects of athletes according to the physical fitness information of each athlete to obtain a game video of the N digital objects of athletes in a second sport, the method further includes:
[0098] Determine video subtitles according to the physical fitness information of each athlete, the video subtitles including: identity information of the N athletes and competition results of the N athletes in the second sports event; add the video subtitles to the competition video of the N athlete digital objects in the second sports event.
[0099] The identities of the athletes appearing in the game video and their game results are displayed in the form of video subtitles to simulate the actual game performance and provide users with a better video viewing experience.
[0100] Among them, the above-mentioned identity information may include data such as the athlete's name, nationality, and team; the above-mentioned competition results can be understood as the athlete's competition results in the second sports event corresponding to the competition video, and the competition results can be calculated based on the athlete's physical fitness data. For example, based on the athlete's maximum horizontal moving rate, the time it takes for the athlete to participate in a 100-meter sprint can be calculated. At this time, the calculated time is displayed as the aforementioned competition results in the form of video subtitles.
[0101] For ease of understanding, the following examples are provided:
[0102] Take basketball games as an example. Figure 2 As shown, at the event data collection node, two sets of data are obtained, one of which is the historical event data (that is, the aforementioned sports information), that is, the athlete data that already existed before the live broadcast time point of the ongoing game watched by the user, including rebounds, assists, blocks, shots (that is, the aforementioned preset key actions) and other actions.
[0103] Another set of data is real-time data, which is obtained by monitoring whether rebounds, assists, steals, blocks, shots, running and other preset key actions appear in the live broadcast screen watched by the user, and collecting the athlete data and basketball movement data in the live broadcast screen when the preset key actions are detected. The corresponding data collection process can be found in the aforementioned related instructions for block data collection, shooting data collection, running data collection, three-step layup data collection, and center rotation data collection.
[0104] The collected event data (i.e. the aforementioned sports information) is input into the digital human physical fitness data module for processing to calculate the maximum ability of horizontal movement, rotation, throwing, jumping and vertical movement of the corresponding athlete (i.e. the aforementioned physical fitness information). The calculation process can refer to the relevant instructions for the aforementioned quantitative calculation process of horizontal movement ability, rotation ability, throwing ability, jumping ability and vertical movement ability.
[0105] After calculating the athlete's maximum abilities of horizontal movement, rotation, throwing, jumping, and vertical movement, the event simulation module simulates the motion conditions of a single game for the five abilities listed in Table 1 below, i.e., restores the game conditions of non-basketball sports events based on the performance of each ability in human sports, where L refers to the time it takes for the basketball to move when the athlete completes a shooting action.
[0106]
[0107] Table 1
[0108] In Table 1, the maximum horizontal movement ability is the aforementioned first physical fitness data, the maximum rotation ability is the aforementioned second physical fitness data, the maximum throwing ability is the aforementioned third physical fitness data, the maximum jumping ability is the aforementioned fourth physical fitness data, and the maximum vertical movement ability is the aforementioned fifth physical fitness data.
[0109] The motion status simulation involves multiple simulation schemes, among which simulation scheme one is the simulation calculation of the running time of a fixed length, and the running time is simulated according to three fixed lengths of 15 meters, 20 meters, 50 meters and 100 meters.
[0110] Among them, 15 meters corresponds to the shortest length of the high jump run-up track, and the time for the high jump run-up is 15 / g; 20 meters corresponds to the length of the javelin run-up distance, and the time for the javelin run-up is 20 / g; 50 meters corresponds to the shortest length of the long jump run-up track, and the long jump run-up is 50 / g; 100 meters corresponds to the competition length of the 100-meter sprint, and the time for the 100-meter sprint is 100 / g.
[0111] The second simulation scheme is a simulation calculation of the jump height within a fixed time. The jump height of the athlete within this fixed time is simulated according to the scheme of 0.6 seconds multiplied by x. 0.6 seconds is the maximum air time of the high jump athlete.
[0112] Simulation plan three is the simulation calculation of the throwing distance of objects of different weights. The simulation is performed separately according to male and female genders. When m corresponds to male athletes, the male gender simulates the throwing distance with three fixed weights of 2000 grams, 7260 grams, and 800 grams. 2000 grams corresponds to the weight of men's discus, 7260 grams corresponds to the weight of men's shot put, and 800 grams corresponds to the weight of men's javelin, that is, 2000 times m, 7260 times m, and 800 times m.
[0113] When m corresponds to female athletes, the throwing distance of female gender is simulated with three fixed weights of 1000g, 4000g and 600g. 2000g corresponds to the weight of women's discus, 4000g corresponds to the weight of women's shot put, and 600g corresponds to the weight of women's javelin, that is, 1000 times m, 4000 times m, and 600 times m.
[0114] Simulation scheme 4 is a simulation calculation of the long jump length with a fixed air time. The athlete's jumping height within this fixed time is simulated according to the scheme of 2 seconds multiplied by r, and 2 seconds is the maximum air time of the long jump athlete.
[0115] Simulation plan five is a simulation calculation of the running distance in a fixed time. The running distance is simulated by multiplying the fixed length of 2 seconds by g. The buffer length after the finish line of a 100-meter sprint race is generally enough for athletes to decelerate in 2 seconds.
[0116] Simulation scheme 6 is a simulation calculation of the rotation time at a fixed angle. The time of rotation around the body center is simulated by dividing the fixed values of 45 degrees and 60 degrees by j. 45 degrees is the rotation angle before throwing the shot put. 60 degrees is the rotation angle before throwing the discus.
[0117] The digital human avatar creation node specifically includes animation rendering of various actions of the digital human avatar (i.e. the aforementioned athlete digital object) participating in the competition:
[0118] The digital man stands naturally (marked as "Model A"), the digital man bends down and supports his knees (marked as "Model B"), the digital man squats (marked as "Model C"), the digital man squats with his hands on the ground before starting (marked as "Model D"), the digital man half lies down with his hands behind his back (marked as "Model E"), the digital man lies down with his back touching the ground (marked as "Model F"), the digital man stands and lifts up a javelin (marked as "Model G"), the digital man stands with a discus (marked as "Model S"), and the digital man stands with a shot put (marked as "Model R").
[0119] The process from the starting line to the finish line of an athlete participating in a sprint competition (marked as "Model 1"), the simulated run-up process of a high jump competition (marked as "Model 2"), the movement state of the run-up process in a long jump competition (marked as "Model 3"), the movement state of the run-up process in a javelin competition (marked as "Model 14"), the process from the time when both feet leave the ground to the time when they pass the highest point and then land on the ground when an athlete participates in a high jump competition, the movement process in the air from the time when the athlete takes off from the pedal to the time when both feet touch the ground when an athlete participates in a long jump competition, and the landing scene when they touch the ground (marked as "Model 5"), the distance run by an athlete after reaching the finish line in a sprint competition and the athlete's body movement (marked as "Model 6"), and the body movement of an athlete holding a throwing object and rotating before participating in shot put and discus (marked as "Model 7").
[0120] The game scene creation node specifically includes the settings of the game background environment (such as the track, stadium, etc.), staff digital objects (such as starters, referees, etc.), etc.:
[0121] Among them, the track, on-site environment, starter, and referee of the 100-meter sprint competition (marked as "module 8"); the venue, starter, and referee of the discus, javelin and shot put competitions (marked as "module 13"); the venue, starter, and referee of the high jump competition (marked as "module 9"); the venue, starter, and referee of the long jump competition (marked as "module 10"); the spectators at the competition site (marked as "module 11"); when athletes participate in the three events of discus, shot put, and javelin, the main simulation focus of the throwing distance of the three projectiles is the trajectory of the projectiles flying in the air and the landing point picture and the corresponding scale picture (marked as "module 12").
[0122] When the user enters the client and clicks on the player data page, the rendering of the digital human avatar and scene creation is triggered and the video is generated. Based on the digital human and scene content obtained by the above simulation, independent digital human rendering is performed to generate the above game video.
[0123] The competition video corresponding to the 100-meter sprint: model 8 + model A + model D + model 1 + model 6 + model 11; the competition video corresponding to the high jump: model 9 + model A + model 2 + model 4 + model F + model E + model 11; the competition video corresponding to the long jump: model 10 + model D + model 3 + model 5 + model E + model 11; the competition video corresponding to the discus: model 13 + model S + model 7 + model 12 + model A + model 11; the competition video corresponding to the javelin: model 13 + model G + model 14 + model 12 + model A + model 11; the competition video corresponding to the shot put: model 13 + model N + model 7 + model 12 + model A + model 11.
[0124] It should be noted that after the above-mentioned sports events are created and rendered and the competition video is generated, subtitles for individual competitions (that is, the aforementioned video subtitles) can also be generated in the video, and subtitles can be displayed for athlete identity information (such as name, nationality, etc.) and competition results.
[0125] See also Figure 3 , Figure 3 A video generation device provided by an embodiment of the present disclosure is as follows: Figure 3 As shown, the video generating device 300 includes:
[0126] An acquisition module 301 is used to acquire N sports videos of N athletes in M1 first sports events, wherein the N athletes correspond to the N sports videos one by one, N is an integer greater than 1, and M1 is a positive integer less than or equal to N;
[0127] An analysis module 302 is used to analyze the sports video of each athlete to obtain the physical fitness information of each athlete;
[0128] The video generation module 303 is used to perform animation rendering on the N athlete digital objects according to the physical fitness information of each athlete to obtain a game video of the N athlete digital objects in a second sport, the N athlete digital objects correspond one-to-one to the N athletes, and the first sport and the second sport are different sports.
[0129] In one embodiment, the number of the second sports events is M2, the number of the game videos is M3, M3 is an integer greater than or equal to M2, and M2 is a positive integer.
[0130] In one embodiment, the analysis module 302 includes:
[0131] A video traversal unit, used for traversing the N sports videos to obtain N individual physical fitness information, wherein the N individual physical fitness information corresponds to the N athletes one by one;
[0132] The traversal step of the nth motion video among the N motion videos includes:
[0133] In the nth sports video, collecting sports information corresponding to a preset key action of the nth athlete, wherein the preset key action is used to quantify the sports performance of the athlete in the first sports event, where n is a positive integer less than or equal to N;
[0134] The motion information of the nth athlete corresponding to the preset key action is analyzed to obtain the nth physical fitness information.
[0135] In one embodiment, the time period during which the nth athlete completes the preset key action is the key action period, and the motion information of the nth athlete corresponding to the preset key action includes: the position change of the nth athlete in the key action period, and / or the position change of the first target object associated with the nth athlete in the key action period;
[0136] The video traversal unit is specifically used to analyze the position change of the nth athlete during the key action period and / or the position change of the first target object associated with the nth athlete during the key action period to obtain the nth individual physical fitness information.
[0137] In one embodiment, the physical fitness information includes at least one of the following:
[0138] First physical fitness data for indicating the horizontal movement ability of the athlete, wherein the first physical fitness data includes a maximum running rate of the corresponding athlete;
[0139] Second physical fitness data for indicating the rotational ability of the athlete, wherein the second physical fitness data includes a maximum turning rate of the corresponding athlete;
[0140] The third physical fitness data for indicating the throwing ability of the athlete, wherein the third physical fitness data includes the longest throwing distance of the athlete throwing an object of unit weight;
[0141] Fourth physical fitness data for indicating the jumping ability of the athlete, the fourth physical fitness data comprising a maximum jumping translation rate of the corresponding athlete;
[0142] The fifth physical fitness data is used to indicate the vertical movement ability of the athlete, and the fifth physical fitness data includes the maximum jumping lift-off rate of the corresponding athlete.
[0143] In one embodiment, the video generation module 303 is specifically used for:
[0144] According to the physical fitness information of each athlete, in a preset game scene, animation rendering is performed on the N athlete digital objects and a second target object in the preset game scene to obtain the game video, wherein the second target object is an object in the preset game scene whose position changes due to the athlete's action.
[0145] In one embodiment, the video generating device 300 further includes:
[0146] The subtitle adding module is used to determine the video subtitles according to the physical fitness information of each athlete; and add the video subtitles to the game video of the N athlete digital objects in the second sport, wherein the video subtitles include: the identity information of the N athletes and the game results of the N athletes in the second sport.
[0147] The video generating device 300 provided in the embodiment of the present disclosure can implement each process in the above-mentioned video generating method embodiment, and will not be described again here to avoid repetition.
[0148] According to an embodiment of the present disclosure, the present disclosure also provides an electronic device and a readable storage medium.
[0149] Figure 4 A schematic block diagram of an example electronic device 400 that can be used to implement an embodiment of the present disclosure is shown. The electronic device is intended to represent various forms of digital computers, such as laptop computers, desktop computers, workstations, personal digital assistants, servers, blade servers, mainframe computers, and other suitable computers. The electronic device can also represent various forms of mobile devices, such as personal digital processing, cellular phones, smart phones, wearable devices, and other similar computing devices. The components shown herein, their connections and relationships, and their functions are merely examples and are not intended to limit the implementation of the present disclosure described and / or required herein.
[0150] like Figure 4 As shown, the device 400 includes a computing unit 401, which can perform various appropriate actions and processes according to a computer program stored in a read-only memory (ROM) 402 or a computer program loaded from a storage unit 408 to a random access memory (RAM) 403. In the RAM 403, various programs and data required for the operation of the device 400 can also be stored. The computing unit 401, the ROM 402, and the RAM 403 are connected to each other via a bus 404. An input / output (I / O) interface 405 is also connected to the bus 404.
[0151] A number of components in the device 400 are connected to the I / O interface 405, including: an input unit 406, such as a keyboard, a mouse, etc.; an output unit 407, such as various types of displays, speakers, etc.; a storage unit 408, such as a disk, an optical disk, etc.; and a communication unit 409, such as a network card, a modem, a wireless communication transceiver, etc. The communication unit 409 allows the device 400 to exchange information / data with other devices through a computer network such as the Internet and / or various telecommunication networks.
[0152] The computing unit 401 may be a variety of general and / or special processing components with processing and computing capabilities. Some examples of the computing unit 401 include, but are not limited to, a central processing unit (CPU), a graphics processing unit (GPU), various dedicated artificial intelligence (AI) computing chips, various computing units running machine learning model algorithms, digital signal processors (DSP), and any appropriate processors, controllers, microcontrollers, etc. The computing unit 401 performs the various methods and processes described above, such as a video generation method. For example, in some embodiments, the video generation method may be implemented as a computer software program, which is tangibly included in a machine-readable medium, such as a storage unit 408. In some embodiments, part or all of the computer program may be loaded and / or installed on the device 400 via the ROM 402 and / or the communication unit 409. When the computer program is loaded into the RAM 403 and executed by the computing unit 401, one or more steps of the video generation method described above may be performed. Alternatively, in other embodiments, the computing unit 401 may be configured to execute the video generation method in any other appropriate manner (eg, by means of firmware).
[0153] Various embodiments of the systems and techniques described above herein may be implemented in digital electronic circuit systems, integrated circuit systems, field-programmable gate arrays (FPGAs), application-specific integrated circuits (ASICs), application-specific standard products (ASSPs), systems on chips (SOCs), complex programmable logic devices (CPLDs), computer hardware, firmware, software, and / or combinations thereof. These various embodiments may include: being implemented in one or more computer programs that can be executed and / or interpreted on a programmable system including at least one programmable processor, which may be a dedicated or general-purpose programmable processor that can receive data and instructions from a storage system, at least one input device, and at least one output device, and transmit data and instructions to the storage system, the at least one input device, and the at least one output device.
[0154] The program code for implementing the method of the present disclosure may be written in any combination of one or more programming languages. These program codes may be provided to a processor or controller of a general-purpose computer, a special-purpose computer, or other programmable data processing device, so that the program code, when executed by the processor or controller, enables the functions / operations specified in the flow chart and / or block diagram to be implemented. The program code may be executed entirely on the machine, partially on the machine, partially on the machine and partially on a remote machine as a stand-alone software package, or entirely on a remote machine or server.
[0155] In the context of the present disclosure, a machine-readable medium may be a tangible medium that may contain or store a program for use by or in conjunction with an instruction execution system, device, or equipment. A machine-readable medium may be a machine-readable signal medium or a machine-readable storage medium. A machine-readable medium may include, but is not limited to, an electronic, magnetic, optical, electromagnetic, infrared, or semiconductor system, device, or equipment, or any suitable combination of the foregoing. A more specific example of a machine-readable storage medium may include an electrical connection based on one or more lines, a portable computer disk, a hard disk, a random access memory (RAM), a read-only memory (ROM), an erasable programmable read-only memory (EPROM or flash memory), an optical fiber, a portable compact disk read-only memory (CD-ROM), an optical storage device, a magnetic storage device, or any suitable combination of the foregoing.
[0156] To provide interaction with a user, the systems and techniques described herein can be implemented on a computer having: a display device (e.g., a CRT (cathode ray tube) or LCD (liquid crystal display) monitor) for displaying information to the user; and a keyboard and pointing device (e.g., a mouse or trackball) through which the user can provide input to the computer. Other types of devices can also be used to provide interaction with the user; for example, the feedback provided to the user can be any form of sensory feedback (e.g., visual feedback, auditory feedback, or tactile feedback); and input from the user can be received in any form (including acoustic input, voice input, or tactile input).
[0157] The systems and techniques described herein may be implemented in a computing system that includes back-end components (e.g., as a data server), or a computing system that includes middleware components (e.g., an application server), or a computing system that includes front-end components (e.g., a user computer with a graphical user interface or a web browser through which a user can interact with implementations of the systems and techniques described herein), or a computing system that includes any combination of such back-end components, middleware components, or front-end components. The components of the system may be interconnected by any form or medium of digital data communication (e.g., a communication network). Examples of communication networks include: a local area network (LAN), a wide area network (WAN), and the Internet.
[0158] A computer system may include a client and a server. The client and the server are generally remote from each other and usually interact through a communication network. The relationship of client and server is generated by computer programs running on respective computers and having a client-server relationship with each other. The server may be a cloud server, a server of a distributed system, or a server combined with a blockchain.
[0159] The present application also provides a computer program product, including computer instructions, which, when executed by a processor, implement the above Figure 1 or Figure 2 The various processes of the method embodiment shown can achieve the same technical effect, and will not be described again here to avoid repetition.
[0160] It should be understood that the various forms of processes shown above can be used to reorder, add or delete steps. For example, the steps recorded in this disclosure can be executed in parallel, sequentially or in different orders, as long as the desired results of the technical solutions disclosed in this disclosure can be achieved, and this document does not limit this.
[0161] The above specific implementations do not constitute a limitation on the protection scope of the present disclosure. It should be understood by those skilled in the art that various modifications, combinations, sub-combinations and substitutions can be made according to design requirements and other factors. Any modification, equivalent substitution and improvement made within the spirit and principle of the present disclosure shall be included in the protection scope of the present disclosure.
Claims
1. A video generation method, characterized in that: The method comprises: Obtain N sports videos of N athletes in M1 first sports events, wherein the N athletes correspond to the N sports videos one by one, N is an integer greater than 1, and M1 is a positive integer less than or equal to N; Analyze the sports video of each athlete to obtain physical fitness information of each athlete; According to the physical fitness information of each athlete, N athlete digital objects are animated and rendered to obtain game videos of the N athlete digital objects in a second sport. The N athlete digital objects correspond one-to-one to the N athletes, and the first sport and the second sport are different sports.
2. The method according to claim 1, characterized in that: The number of the second sports events is M2, the number of the game videos is M3, M3 is an integer greater than or equal to M2, and M2 is a positive integer.
3. The method according to claim 1, characterized in that The step of analyzing the sports video of each athlete to obtain the physical fitness information of each athlete includes: Traversing the N sports videos to obtain N individual physical fitness information, wherein the N individual physical fitness information corresponds to the N athletes one by one; The traversal step of the nth motion video among the N motion videos includes: In the nth sports video, collecting sports information corresponding to a preset key action of the nth athlete, wherein the preset key action is used to quantify the sports performance of the athlete in the first sports event, where n is a positive integer less than or equal to N; The motion information of the nth athlete corresponding to the preset key action is analyzed to obtain the nth physical fitness information.
4. The method according to claim 3, characterized in that The time period during which the nth athlete completes the preset key action is the key action period, and the motion information of the nth athlete corresponding to the preset key action includes: the position change of the nth athlete in the key action period, and / or the position change of the first target object associated with the nth athlete in the key action period; The analyzing the motion information of the nth athlete corresponding to the preset key action to obtain the nth physical fitness information includes: The position change of the nth athlete during the key action period and / or the position change of the first target object associated with the nth athlete during the key action period are analyzed to obtain the nth physical fitness information.
5. The method according to claim 4, characterized in that The physical fitness information includes at least one of the following: First physical fitness data for indicating the horizontal movement ability of the athlete, wherein the first physical fitness data includes a maximum running rate of the corresponding athlete; Second physical fitness data for indicating the rotational ability of the athlete, wherein the second physical fitness data includes a maximum turning rate of the corresponding athlete; The third physical fitness data for indicating the throwing ability of the athlete, wherein the third physical fitness data includes the longest throwing distance of the athlete throwing an object of unit weight; Fourth physical fitness data for indicating the jumping ability of the athlete, the fourth physical fitness data comprising a maximum jumping translation rate of the corresponding athlete; The fifth physical fitness data is used to indicate the vertical movement ability of the athlete, and the fifth physical fitness data includes the maximum jumping lift-off rate of the corresponding athlete.
6. The method according to claim 1, characterized in that The step of performing animation rendering on the N digital objects of athletes according to the physical fitness information of each athlete to obtain a game video of the N digital objects of athletes in a second sport event includes: According to the physical fitness information of each athlete, in a preset game scene, animation rendering is performed on the N athlete digital objects and a second target object in the preset game scene to obtain the game video, wherein the second target object is an object in the preset game scene whose position changes due to the athlete's action.
7. The method according to claim 6, characterized in that After performing animation rendering on the N digital objects of athletes according to the physical fitness information of each athlete to obtain a game video of the N digital objects of athletes in a second sport, the method further includes: Determining video subtitles according to the physical fitness information of each athlete, the video subtitles including: identity information of the N athletes and competition results of the N athletes in the second sports event; The video subtitles are added to the game video of the N athlete digital objects in the second sport.
8. An electronic device, characterized in that: The method comprises a processor, a memory, and a computer program stored in the memory and executable on the processor, wherein the computer program implements the steps of the method according to any one of claims 1 to 7 when executed by the processor.
9. A computer-readable storage medium, characterized in that: The computer-readable storage medium stores a computer program, and when the computer program is executed by a processor, the steps of the method according to any one of claims 1 to 7 are implemented.
10. A computer program product, characterized in that The method comprises computer instructions, which, when executed by a processor, implement the steps of the method according to any one of claims 1 to 7.
