Video generation method and electronic device

By decoupling the acquisition of motion data and image information, asynchronously acquiring motion data and generating motion videos using video templates, the reliance on advanced acquisition equipment in existing technologies is eliminated, enabling the generation of fun motion videos in various motion scenarios.

CN115690272BActive Publication Date: 2026-06-05PETAL CLOUD TECH CO LTD

Patent Information

Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
PETAL CLOUD TECH CO LTD
Filing Date
2021-07-31
Publication Date
2026-06-05

AI Technical Summary

Technical Problem

Existing technologies require advanced acquisition devices such as cameras and dedicated motion capture equipment in motion scenarios, resulting in high complexity in generating motion videos.

Method used

By decoupling the acquisition process of motion data and image information, motion data and image information are acquired asynchronously, and motion videos are generated using video templates, reducing reliance on dedicated equipment.

Benefits of technology

It generates motion videos without the need for specialized equipment, reducing the complexity of data collection and increasing the fun and interactivity of motion videos, making it suitable for a variety of sports scenarios.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN115690272B_ABST
    Figure CN115690272B_ABST
Patent Text Reader

Abstract

The application provides a video generation method and an electronic device, relates to the technical field of communication, and can generate a motion video in a scene without the aid of a professional data acquisition device, thereby reducing the complexity of the video generation process. The method comprises the following steps: acquiring data of a video template, collecting motion data of one or more users, and generating a motion video of the one or more users according to the motion data and the data of the video template. The motion data comprises any one or more of the following data: speed, amplitude, frequency and trajectory.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This application relates to the field of electronic technology, and in particular to video generation methods and electronic devices. Background Technology

[0002] Currently, in some sports scenarios such as fitness training and gaming, the system or terminal software can collect the user's video images in real time and capture motion data synchronized with the video images to generate simulated videos of the user. Figure 1 This paper illustrates a solution for synthesizing motion-based videos in current gaming scenarios. In this solution, software installed on a smart screen (such as Dance Center or Just Dance) can capture real-time images of the user using the screen's camera, and then generate a corresponding dance video based on the captured images, simulating the user's movements. Users can then watch their own real-time dance video online on the smart screen.

[0003] This solution requires the acquisition of a large number of images, so it typically requires acquisition equipment such as cameras and dedicated motion capture devices, which places high demands on the types of acquisition equipment. Summary of the Invention

[0004] The video generation method and electronic device provided in this application can generate motion videos in scenarios without the aid of professional data acquisition equipment, thereby reducing the complexity of the video generation process.

[0005] To achieve the above objectives, this application adopts the following technical solution:

[0006] Firstly, this application provides a video generation method, which includes: acquiring video template data, collecting motion data from one or more users, and generating motion videos for one or more users based on the motion data and the video template data. The motion data includes any one or more of the following: speed, amplitude, frequency, and trajectory. Through the technical solution of this application's embodiments, motion data and image information are decoupled, meaning the acquisition processes of image information and motion data can be separated. This allows for asynchronous acquisition of image information and motion data, thereby reducing the implementation complexity of the data acquisition device. Even without the need for dedicated auxiliary equipment (such as a camera) or dedicated personnel to assist in data acquisition (such as dedicated personnel to capture images), motion videos can still be generated based on motion data and video templates.

[0007] In one possible design, the video template data is either data from a person's movement video or data from a scene video.

[0008] In one possible design, the video template can be preset or user-input.

[0009] Optionally, the video of a person's movement can be, but is not limited to, a video of a celebrity, friend, or other person's movement. Optionally, the video of a person's movement can be a video synthesized using the video generation method of this application embodiment, or it can be a regular video, i.e., a video not synthesized using the video generation method of this application embodiment.

[0010] In one possible design, the motion data has a corresponding first motion type, and the motion data corresponding to the first motion type includes a trajectory;

[0011] Based on motion data and video template data, generate motion videos for one or more users, including:

[0012] Based on the trajectory in the motion data corresponding to the first motion type and the data of the video template, generate motion videos for one or more users.

[0013] In this way, motion videos of one or more users moving along corresponding trajectories can be generated, increasing the fun of the motion videos.

[0014] In one possible design, the motion data has a corresponding second motion type; the video template data includes route data;

[0015] Based on motion data and video template data, generate motion videos for one or more users, including:

[0016] Based on the motion data and route data corresponding to the second motion type, generate one or more motion videos of users moving along routes indicated by the route data.

[0017] This solution enables the generation of motion data for one or more users along routes indicated by a video template, in scenarios where motion tracks are not readily available (such as running on a treadmill), or where motion tracks are difficult to obtain, or in other situations. This increases the engagement and enjoyment of the workout videos. Furthermore, when the workout video involves multiple users, each user can observe their own and others' workout progress, thus providing guidance for their own fitness efforts.

[0018] Optionally, the route data can be selected by the user or set by the system default.

[0019] In one possible design, motion data from one or more users is collected, including from a target software module or a target hardware module. This solution can interface with hardware modules (such as assistive devices) or software modules (such as assistive software) from different manufacturers and models, collecting motion data in various formats. Therefore, because it is compatible with different manufacturers and models of software or hardware, no additional specialized equipment is required to complete motion data collection.

[0020] In one possible design, motion data from one or more users is collected, including receiving motion data input from one or more users.

[0021] The method further includes: acquiring image information from one or more users; wherein the image information is preset image information, or the image information from one or more users is image information input by one or more users. In this embodiment, the user's image information can be preset by the system or uploaded by the user. It is not necessary to synchronously acquire the user's image information when collecting motion data. Therefore, it is applicable to more sports scenarios, such as those where it is inconvenient to take fitness photos while exercising.

[0022] In one possible design, for any one of one or more users, information about the user's image and motion data are acquired asynchronously.

[0023] In one possible design, the image information of one or more users includes any combination of one or more of the following: images of one or more users, text describing the characteristics of one or more users, and videos of one or more users. In this embodiment, the image information of users is no longer limited to real-time video of users, but can be any information used to describe user characteristics or user profiles. Because the scope of image information is broadened, there can be multiple ways to acquire image information, no longer limited to synchronous acquisition with motion data, nor limited to real-time acquisition of image information via a camera.

[0024] In one possible design, the motion video of one or more users includes multiple image frames. The Xth image frame is obtained by inserting the image of one or more users at a target time into the Xth image frame of the video template. The target time is the time corresponding to the Xth image frame. X is a positive integer.

[0025] In one possible design, motion data from multiple users is acquired synchronously.

[0026] In one possible design, motion data from multiple users is acquired asynchronously. This method allows multiple users to exercise separately at different times and locations, meaning users don't need to exercise simultaneously; each user can exercise at a convenient time and place. The system can then synthesize multiple motion videos from different users at different times and locations into a single video of a team exercising together, providing convenience for users to utilize the composite motion video function.

[0027] In one possible design, the motion data may also include one or more of the following: heart rate, blood pressure, blood oxygen, and body temperature.

[0028] Secondly, this application provides a video generation system, comprising:

[0029] The video template processing module is used to acquire video template data;

[0030] The motion data acquisition adapter module is used to collect motion data from one or more users;

[0031] The motion video generation module is used to generate motion videos for one or more users based on motion data and video template data. Motion data includes one or more of the following: speed, amplitude, frequency, and trajectory.

[0032] In one possible design, the video template data is either data from a person's movement video or data from a scene video.

[0033] In one possible design, the motion data has a corresponding first motion type, and the motion data corresponding to the first motion type includes a trajectory;

[0034] The motion video generation module is used to generate motion videos for one or more users based on motion data and video template data, including:

[0035] The motion video generation module is used to generate motion videos for one or more users based on the trajectory in the motion data corresponding to the first motion type and the data of the video template.

[0036] In one possible design, the motion data has a corresponding second motion type; the video template data includes route data;

[0037] The motion video generation module is used to generate motion videos for one or more users based on motion data and video template data, including:

[0038] Based on the motion data and route data corresponding to the second motion type, generate one or more motion videos of users moving along routes indicated by the route data.

[0039] In one possible design, a motion data acquisition adapter module is used to acquire motion data from one or more users, including: acquiring motion data from one or more users from a target software module or a target hardware module.

[0040] In one possible design, the motion data acquisition adapter module is used to acquire motion data from one or more users, including receiving motion data input by one or more users.

[0041] The system includes: an image data processing module for acquiring image information from one or more users; wherein the image information is preset image information, or the image information from one or more users is image information input by one or more users.

[0042] In one possible design, for any one of one or more users, the user's image information and the user's motion data are acquired asynchronously.

[0043] In one possible design, the information of one or more users' images includes any one or more of the following: images of one or more users, text describing the characteristics of one or more users, and videos of one or more users.

[0044] In one possible design, the motion video of one or more users includes multiple image frames. The Xth image frame is obtained by inserting the image of one or more users at a target time into the Xth image frame of the video template. The target time is the time corresponding to the Xth image frame. X is a positive integer.

[0045] In one possible design, motion data from multiple users is acquired synchronously. In another possible design, motion data from multiple users is acquired asynchronously.

[0046] In one possible design, the motion data may also include one or more of the following: heart rate, blood pressure, blood oxygen, and body temperature.

[0047] Thirdly, this application provides an electronic device that has the function of implementing the video generation method as described in the first aspect and any of its possible implementations. This function can be implemented in hardware or by hardware executing corresponding software. The hardware or software includes one or more modules corresponding to the above-described function.

[0048] Fourthly, this application provides a computer-readable storage medium including computer instructions that, when executed on an electronic device, cause the electronic device to perform a video generation method as described in the first aspect and any of its possible implementations.

[0049] Fifthly, this application provides a computer program product that, when run on an electronic device, causes the electronic device to execute a video generation method as described in the first aspect and any of its possible implementations.

[0050] In a sixth aspect, a circuit system is provided, the circuit system including processing circuitry configured to perform the video generation method as described in the first aspect and any possible implementation thereof.

[0051] In a seventh aspect, embodiments of this application provide a chip system including at least one processor and at least one interface circuit. The at least one interface circuit is used to perform transceiver functions and send instructions to the at least one processor. When the at least one processor executes the instructions, the at least one processor executes the video generation method as described in the first aspect above and any possible implementation thereof. Attached Figure Description

[0052] Figure 1 A flowchart for generating motion videos in existing technologies;

[0053] Figure 2 This is a schematic diagram of the architecture of the motion video synthesis system provided in the embodiments of this application;

[0054] Figure 3A This is a schematic diagram of the structure of the electronic device provided in the embodiments of this application;

[0055] Figure 3B A schematic diagram of the software architecture of the electronic device provided in the embodiments of this application;

[0056] Figure 4 Another structural schematic diagram of the electronic device provided in the embodiments of this application;

[0057] Figure 5 A set of interface schematic diagrams provided for embodiments of this application;

[0058] Figure 6 A flowchart illustrating the video generation method provided in this application embodiment;

[0059] Figures 7-9B This is a schematic diagram of the interface provided for an embodiment of this application;

[0060] Figure 10 A flowchart illustrating the video generation method provided in this application embodiment;

[0061] Figure 11 A schematic diagram of the motion data model provided in the embodiments of this application;

[0062] Figures 12-14B A flowchart illustrating the video generation method provided in this application embodiment;

[0063] Figures 15-17 A flowchart illustrating the video generation method provided in this application embodiment;

[0064] Figures 18A-18B This is a schematic diagram of the interface provided for an embodiment of this application;

[0065] Figure 19 A flowchart illustrating the video generation method provided in this application embodiment;

[0066] Figure 20A , Figure 20B , Figure 21A , Figure 21B This is a schematic diagram of the interface provided for an embodiment of this application;

[0067] Figure 22 This is a schematic diagram of the interface provided for an embodiment of this application;

[0068] Figure 23 A flowchart illustrating the video generation method provided in this application embodiment;

[0069] Figure 24 This is a schematic diagram of the interface provided for an embodiment of this application;

[0070] Figure 25 , Figure 26 A flowchart illustrating the video generation method provided in this application embodiment;

[0071] Figure 27 A schematic diagram of the apparatus provided in the embodiments of this application;

[0072] Figure 28 This is a schematic diagram of a chip system provided in an embodiment of this application. Detailed Implementation

[0073] This application provides a video generation method that can acquire video template data, collect motion data from one or more users, and generate motion videos for the one or more users based on the motion data and the video template data. The motion data includes one or more of the following: speed, amplitude, frequency, and trajectory. Compared to existing technologies where image information and motion data of a person are acquired synchronously, which is difficult, the video generation method of this application decouples motion data from image information; that is, the acquisition processes of image information and motion data can be separated. This allows for asynchronous acquisition of image information and motion data, thereby reducing the implementation complexity of data acquisition equipment. Even without the need for dedicated auxiliary equipment (such as cameras) or dedicated personnel to assist in data acquisition (such as dedicated personnel to capture images), motion videos can still be generated based on motion data and video templates.

[0074] The video generation method and electronic device provided in the embodiments of this application will be described in detail below with reference to the accompanying drawings.

[0075] The video generation method provided in this application can be applied to motion video synthesis systems. Figure 2 An exemplary architecture of a motion video synthesis system is illustrated. The system includes a data acquisition subsystem and a video synthesis subsystem. The data acquisition subsystem includes a motion data acquisition and adaptation module. The video synthesis subsystem includes a video template processing module, an information database (which may include a video template library, a template scene library, a character model library, and a motion database), a virtual character (also known as a character model) motion image generation module, and a motion video generation module.

[0076] The sports data acquisition and adaptation module is used to collect user sports data. Based on the collected data, this module can build corresponding models for different sports types (e.g., running, swimming, rowing). For a specific type of sports data, the sports data model may include one or more of the following: the summarized sports data for that sports type, and the time-sliced ​​data obtained from dividing the sports data. For example... Figure 11 This illustrates a sports data model for the running exercise type. The running data includes time-sliced ​​data 1 through slice n. The running duration corresponding to different time slices can be the same or different. Taking one hour of running data as an example, this hour's worth of data can be divided into 5 time slices, each corresponding to a running duration of 12 minutes.

[0077] The motion data acquisition and adaptation module can be implemented in software, hardware, or a combination of both. For example, taking a motion data acquisition and adaptation module within a mobile phone as an example, the module can include a software module and sensors. The software module can use drivers to call the sensors to collect the user's motion data. Afterward, the software module can perform processing on the motion data, such as formatting, and build a model from the motion data.

[0078] In some embodiments, the motion data acquisition adapter module can receive motion data input by the user. For example, motion data uploaded by the user can be detected through fitness software.

[0079] In some other embodiments, the motion video synthesis system of this application may optionally include third-party motion software and / or third-party assistive devices. The motion data acquisition and adaptation module can acquire user motion data from the third-party motion software or third-party assistive devices. The motion software may be, but is not limited to, system-level applications or user-level applications. System-level applications may refer to applications pre-installed on the terminal, such as sports and health applications. User-level applications may refer to applications subsequently installed by the user, such as motion applications downloaded and installed through an app store. Assistive devices include, but are not limited to, fitness trackers, watches, and exercise equipment (such as treadmills, rowing machines, elliptical trainers, and exercise bikes). The motion data acquisition and adaptation module can perform processing such as format conversion on the motion data acquired from the aforementioned third-party motion software or third-party assistive devices to obtain motion data models for the corresponding motion types, so that motion data of different formats can be adapted to subsequent processing flows.

[0080] In this embodiment, by expanding the functionality of the motion data acquisition adapter module, it can adapt to the interfaces of various software modules or hardware modules (motion assistive devices), and collect motion data from these modules, thereby broadening the range of motion data sources. In some solutions, user motion data can be collected not only in indoor scenarios but also in outdoor scenarios.

[0081] In this embodiment, the user's exercise scenarios include, but are not limited to, running, walking, cycling, swimming, soccer, rowing, basketball, yoga, etc. Within these exercise scenarios, the exercise data acquisition and adaptation module collects user exercise data including, but not limited to, exercise type, distance, steps, duration, intensity, trajectory, posture, and physiological parameters. Physiological parameters include, but are not limited to, heart rate, blood pressure, blood oxygen, body temperature, respiratory rate, and bioelectrical impedance. Exercise types include, but are not limited to, running, walking, cycling, and fitness.

[0082] It should be noted that the motion data acquisition and adaptation module collects the user's motion data, which can be motion data authorized by the user. After formatting the motion data and constructing a motion data model, the module can write the relevant information of the motion data model into an information database. This information can then be used as a source for generating motion images of virtual characters.

[0083] Video template processing module: Used to acquire video templates and process them to obtain video template data. Optionally, the video template can be a video format or other formats, such as image formats. This application embodiment mainly uses video format templates as an example, but this does not constitute a limitation on the format of the video template. For example, a video template is a sequence of template image frames. The video template can be, but is not limited to, sports competition videos or background venue videos. The video template can be used as follows. As a possible example, when finally synthesizing a motion video, the video template is used as a template or background, and the user's image at the same time (i.e., the target time) and under the same scene model is inserted into the x-th image frame of the video template to form the user's motion video, where x is a positive integer.

[0084] Processing video templates can involve acquiring information about scene models and character models. Optionally, it can also acquire motion data of the character models in the video template (such as stride length and cadence). The video template processing module can store the extracted video template data in a database for use in video compositing.

[0085] The scene model information is obtained by digitizing the scene of each frame of the video template, including but not limited to scene perspective, scene size, track slope, and other information.

[0086] As one possible implementation, the information base can include one or more sub-bases. Different sub-bases store different information. For example, the information base could include a video template library, a template scene library, a character model library, and a motion database. The video template library stores video templates. The scene library stores scene information within the templates. The motion database stores character motion data. The character model library stores information related to character models, such as character portrait information and character model information. Character model information includes character model information from the video templates and character model information of the user whose motion video needs to be synthesized.

[0087] In this embodiment of the application, the video templates are sourced from, but are not limited to, the following sources:

[0088] 1. System Presets: The system can collect authorized sports videos (such as celebrity sports videos) from the network, process the videos to obtain relevant information (such as scene model information, motion data information, and character model information), and write it into the information database. The system can also collect authorized sports data from the network and generate corresponding video templates based on the sports data.

[0089] 2. User-uploaded video templates: Users upload their own exercise videos (optional, they can also upload exercise data), and the system processes them and writes various information into the database.

[0090] 3. Calculated from user-uploaded exercise data: Users upload their own exercise data, and the system automatically generates video templates based on the exercise data. The system can also process the video templates and write various types of information into the information database.

[0091] Image data processing module: This module acquires user profile data (or image data), processes it to obtain a persona model representing the user's appearance. The persona model can be, but is not limited to, a 3D model. User profile data includes, but is not limited to, data that characterizes the user's physical features. The format of the profile data can be, but is not limited to, text, images of the user from various angles, video, etc. In some embodiments, the image data processed by the image data processing module (or user profile data) can be image data uploaded / selected / input by the user. Alternatively, the image data processed by the image data processing module can be system-preset image data.

[0092] Virtual Character Motion Image Generation Module: This module uses artificial intelligence (AI) technology to generate motion images of virtual characters (or character models) at corresponding time points and in corresponding scene models, based on user profile information (which can be input by the user or defaulted to by the system), motion data, and scene 3D models. Finally, it synthesizes motion videos of virtual characters with video templates as backgrounds.

[0093] The motion video generation module can insert the motion images of the virtual character generated by the virtual character motion image generation module into the corresponding template image frames of the video template. In other words, the video template serves as the background for the virtual character's motion. This allows for the creation of a synthesized motion video.

[0094] In some implementation frames, such as Figure 2 As shown, optionally, the motion video compositing system may also include a video service module and a video playback and download module. The video service module, which may be located on the cloud side (e.g., the server side), is used to store the synthesized motion video and its segments, providing functions such as online playback, download, and sharing. The video playback and download module, which may be located on the device side (e.g., the mobile phone side), is used to download, play, or stream videos online.

[0095] In the motion video synthesis system of this application embodiment, some modules may be located in the edge device and some modules may be located in the cloud device. The edge device may be, but is not limited to, mobile phones, tablets, wearable devices, in-vehicle devices, augmented reality (AR) / virtual reality (VR) devices, laptops, ultra-mobile personal computers (UMPCs), netbooks, personal digital assistants (PDAs), etc. This application embodiment does not impose any restrictions on the specific type of edge device.

[0096] Taking a mobile phone as an example, for instance, Figure 3A A schematic diagram of one structure of the end-side device 100 is shown. The end-side device 100 may include a processor 110, an external memory interface 120, an internal memory 121, a universal serial bus (USB) interface 130, a charging management module 140, a power management module 141, a battery 142, antenna 1, antenna 2, a mobile communication module 150, a wireless communication module 160, an audio module 170, a speaker 170A, a receiver 170B, a microphone 170C, a headphone jack 170D, a sensor module 180, buttons 190, a motor 191, an indicator 192, a camera 193, a display screen 194, and a subscriber identification module (SIM) card interface 195, etc.

[0097] Processor 110 may include one or more processing units, such as: application processor (AP), modem processor, graphics processing unit (GPU), image signal processor (ISP), controller, memory, video codec, digital signal processor (DSP), baseband processor, and / or neural network processing unit (NPU), etc. Different processing units may be independent devices or integrated into one or more processors.

[0098] The controller can serve as the central nervous system and command center of the end-side device 100. The controller can generate operation control signals based on the instruction opcode and timing signals to control the fetching and execution of instructions.

[0099] The processor 110 may also include a memory for storing instructions and data. In some embodiments, the memory in the processor 110 is a cache memory. This memory can store instructions or data that the processor 110 has just used or that are used repeatedly. If the processor 110 needs to use the instruction or data again, it can retrieve it directly from the memory. This avoids repeated accesses, reduces the waiting time of the processor 110, and thus improves the efficiency of the system.

[0100] In some embodiments of this application, the processor 110 can be used to acquire the user's motion data and acquire the user's motion video based on the motion data.

[0101] The charging management module 140 is used to receive charging input from the charger.

[0102] The power management module 141 is used to connect the battery 142, the charging management module 140, and the processor 110. The power management module 141 receives input from the battery 142 and / or the charging management module 140 to power the processor 110, the display 194, the camera 193, etc.

[0103] The wireless communication function of the end-side device 100 can be implemented through antenna 1, antenna 2, mobile communication module 150, wireless communication module 160, modem processor, and baseband processor.

[0104] Mobile communication module 150 can provide wireless communication solutions including 2G / 3G / 4G / 5G for use on end-side device 100. Wireless communication module 160 can provide wireless communication solutions including wireless local area networks (WLAN) (such as wireless fidelity (Wi-Fi) networks) and Bluetooth (BT) for use on end-side device 100.

[0105] The edge device 100 implements display functions through a GPU, a display screen 194, and an application processor. The GPU is a microprocessor for image processing, connecting the display screen 194 and the application processor. The GPU is used to perform mathematical and geometric calculations for graphics rendering. The processor 110 may include one or more GPUs, which execute program instructions to generate or modify display information.

[0106] Display screen 194 is used to display images, videos, etc. Display screen 194 includes a display panel. In some embodiments, end-side device 100 may include one or N displays screens 194, where N is a positive integer greater than 1.

[0107] The edge device 100 can perform shooting functions through an ISP, camera 193, video codec, GPU, display 194, and application processor.

[0108] The ISP (Image Signal Processor) is used to process data fed back from the camera 193. For example, when taking a picture, the shutter is opened, and light is transmitted through the lens to the camera's photosensitive element. The light signal is converted into an electrical signal, and the photosensitive element transmits the electrical signal to the ISP for processing, transforming it into an image visible to the naked eye. The ISP can also perform algorithmic optimization of image noise, brightness, and skin tone. The ISP can also optimize parameters such as exposure and color temperature of the shooting scene. In some embodiments, the ISP can be set within the camera 193. For example, the ISP can control the photosensitive element for exposure and image capture based on shooting parameters.

[0109] Camera 193 is used to capture still images or videos. An object passes through the lens, generating an optical image that is projected onto a photosensitive element. This photosensitive element can be a charge-coupled device (CCD) or a complementary metal-oxide-semiconductor (CMOS) phototransistor. The photosensitive element converts the light signal into an electrical signal, which is then passed to an ISP (Image Signal Processor) for conversion into a digital image signal. The ISP outputs the digital image signal to a DSP (Digital Signal Processor) for further processing. The DSP converts the digital image signal into standard RGB, YUV, or other image formats.

[0110] In some embodiments, the edge device 100 may include one or N cameras 193, where N is a positive integer greater than 1. The cameras 193 may be located in the edge area of ​​the electronic device and may be under-display cameras, pop-up cameras, or punch-hole cameras. The cameras 193 may include rear cameras and front cameras. This application does not limit the specific location and shape of the cameras 193.

[0111] A digital signal processor (DSP) is used to process digital signals. Besides digital image signals, it can also process other digital signals. For example, when the end-side device 100 selects a frequency, the DSP can perform Fourier transforms on the frequency energy.

[0112] Video codecs are used to compress or decompress digital video. The end-side device 100 may support one or more video codecs. Thus, the end-side device 100 can play or record video in various encoding formats, such as Moving Picture Experts Group (MPEG) 1, MPEG 2, MPEG 3, MPEG 4, etc.

[0113] An NPU (Neural Processing Unit) is a computational processor for neural networks (NNs). By borrowing the structure of biological neural networks, such as the transmission patterns between neurons in the human brain, it can rapidly process input information and continuously learn on its own. NPUs can enable intelligent cognitive applications on edge devices, such as image recognition, facial recognition, speech recognition, and text understanding.

[0114] The external storage interface 120 can be used to connect an external storage card, such as a Micro SD card, to expand the storage capacity of the terminal device 100. The external storage card communicates with the processor 110 through the external storage interface 120 to perform data storage functions. For example, music, video, and other files can be saved on the external storage card.

[0115] Internal memory 121 can be used to store computer executable program code, which includes instructions. Processor 110 executes various functional applications and data processing of the edge device 100 by running instructions stored in internal memory 121 and / or instructions stored in memory disposed in the processor.

[0116] The end-side device 100 can implement audio functions, such as music playback and recording, through an audio module 170, a speaker 170A, a receiver 170B, a microphone 170C, a headphone jack 170D, and an application processor.

[0117] The audio module 170 is used to convert digital audio data into analog audio electrical signals for output, and also to convert analog audio electrical signals into digital audio data for input. The audio module 170 may include an analog-to-digital converter and a digital-to-analog converter. For example, the audio module 170 is used to convert the analog audio electrical signals output from the microphone 170C into digital audio data. The audio module 170 can also be used to encode and decode audio data. In some embodiments, the audio module 170 may be located in the processor 110, or some functional modules of the audio module 170 may be located in the processor 110.

[0118] The speaker 170A, also known as a "loudspeaker," is used to convert analog audio electrical signals into sound signals. The end-side device 100 can listen to music or make hands-free calls through the speaker 170A.

[0119] The receiver 170B, also known as the "earpiece," is used to convert analog audio electrical signals into sound signals. When the end device 100 answers a telephone call or voice message, it can listen to the voice by bringing the receiver 170B close to the ear.

[0120] Microphone 170C, also known as a "microphone" or "voice transducer," is used to convert sound signals into analog audio electrical signals. When making a phone call or sending a voice message, the user can speak by bringing their mouth close to microphone 170C, inputting the sound signal into microphone 170C. Microphone 170C can be a built-in component of end-side device 100 or an external accessory of end-side device 100.

[0121] In some embodiments, the end-side device 100 may include one or more microphones 170C, wherein each or multiple microphones cooperate to acquire sound signals from various directions and convert the acquired sound signals into analog audio electrical signals, and may also perform noise reduction, sound source identification, or directional recording functions, etc.

[0122] The sensor module 180 may include a pressure sensor 180A, a gyroscope sensor 180B, a barometric pressure sensor 180C, a magnetic sensor 180D, an accelerometer sensor 180E, a distance sensor 180F, a proximity sensor 180G, a fingerprint sensor 180H, a temperature sensor 180J, a touch sensor 180K, an ambient light sensor 180L, a bone conduction sensor 180M, etc.

[0123] The gyroscope sensor 180B can be used to determine the motion posture of the end-side device 100. In some embodiments, the gyroscope sensor 180B can determine the angular velocity of the end-side device 100 around three axes (i.e., the x, y, and z axes). The gyroscope sensor 180B can be used for image stabilization. For example, when the shutter is pressed, the gyroscope sensor 180B detects the angle of the shake of the end-side device 100, calculates the distance that the lens module needs to compensate based on the angle, and allows the lens to counteract the shake of the end-side device 100 through reverse movement, thus achieving image stabilization. The gyroscope sensor 180B can also be used in navigation and motion-sensing game scenarios.

[0124] A distance sensor 180F is used to measure distance. The edge device 100 can measure distance via infrared or laser. In some embodiments, during a shooting scenario, the edge device 100 can utilize the distance sensor 180F for distance measurement to achieve fast focusing.

[0125] Touch sensor 180K, also known as a "touch panel". Touch sensor 180K can be set on display screen 194. Touch sensor 180K and display screen 194 together form a touch screen, also known as a "touch screen". Touch sensor 180K is used to detect touch operations on or near it.

[0126] It is understood that the structures illustrated in the embodiments of this application do not constitute a specific limitation on the end-side device 100. In other embodiments of this application, the end-side device 100 may include more or fewer components than illustrated, or combine some components, or split some components, or have different component arrangements. The illustrated components may be implemented in hardware, software, or a combination of software and hardware.

[0127] The software system of the edge device 100 can adopt a layered architecture, event-driven architecture, microkernel architecture, microservice architecture, or cloud architecture. This embodiment of the invention uses a layered Android system as an example to exemplify the software structure of the edge device 100.

[0128] Figure 3B This is a software structure block diagram of the end-side device 100 according to an embodiment of the present invention.

[0129] A layered architecture divides software into several layers, each with a clear role and function. Layers communicate with each other through software interfaces. In some embodiments, the operating system of an electronic device (such as the Android system) is divided into four layers, from bottom to top: the kernel layer, the hardware abstraction layer (HAL), the application framework layer, and the application layer.

[0130] The kernel layer is the layer between hardware and software. The kernel layer includes at least camera drivers, audio drivers, display drivers, and sensor drivers. Sensor drivers include, but are not limited to, image sensor drivers and acoustic sensor drivers.

[0131] In some embodiments, such as in a motion scenario, kernel-level components such as sensor drivers are invoked to activate the corresponding sensors to complete motion data acquisition.

[0132] The Hardware Abstraction Layer (HAL) sits between the kernel layer and the application framework layer. It defines the interface for the hardware implementation of driver applications, translating the values ​​from the hardware implementation into software implementation programming languages. For example, it identifies values ​​from a camera driver, translates them into software programming languages, uploads them to the application framework layer, and then enables the invocation of corresponding functions.

[0133] In some embodiments, HAL can upload motion data collected by sensors to the application framework layer for further processing.

[0134] The application framework layer provides an application programming interface (API) and programming framework for applications in the application layer. The application framework layer obtains raw input events from the kernel layer via the HAL and identifies the controls corresponding to those input events. The application framework layer includes some predefined functions.

[0135] like Figure 3B As shown, the application framework layer may include a view system, a phone manager, a resource manager, a notification manager, a window manager, etc.

[0136] In some embodiments, the application framework layer includes a first module. The first module can be used to acquire the user's motion data and, based on the motion data, acquire the user's motion video.

[0137] Optionally, the first module can be located in other layers, and it can also be divided into more sub-modules. Each sub-module is used to perform a corresponding function.

[0138] A view system includes visual controls, such as controls for displaying text and controls for displaying images. View systems can be used to build applications. A display interface can consist of one or more views. For example, a display interface including a text notification icon could include views for displaying text and views for displaying images.

[0139] The phone manager is used to provide communication functions for the end-side device 100. For example, it manages call status (including connection, hang-up, etc.).

[0140] The file explorer provides applications with various resources, such as localized strings, icons, images, layout files, video files, and more.

[0141] The notification manager allows applications to display notifications in the status bar. These notifications can be used to deliver informational messages and can disappear automatically after a short pause, requiring no user interaction. For example, the notification manager can be used to notify users of completed downloads or message alerts. The notification manager can also display notifications as icons or scrolling text in the top status bar, such as notifications from background applications, or as dialog boxes on the screen. Examples include displaying text messages in the status bar, emitting sounds, vibrating electronic devices, and flashing indicator lights.

[0142] The window manager is used to manage windowed applications. It can retrieve screen size, determine the presence of a status bar, lock the screen, and capture screenshots, among other things.

[0143] The application layer can include a series of application packages.

[0144] like Figure 3B As shown, the application package may include applications such as camera, video, call, WLAN, music, SMS, Bluetooth, map, calendar, gallery, and navigation.

[0145] The application layer and application framework layer run in a virtual machine. The virtual machine executes the Java files of the application layer and application framework layer as binary files. The virtual machine is used to perform functions such as object lifecycle management, stack management, thread management, security and exception management, and garbage collection.

[0146] It should be noted that the structure of the cloud-side device 300 can also be referenced. Figure 3A The structure of the end-side device 100 and the cloud-side device 300 can have a structure that is more advanced than that of the end-side device 100. Figure 3A The structures shown may have more or fewer components, or combine some components, or separate some components, or have different component arrangements. The components shown can be implemented in hardware, software, or a combination of software and hardware.

[0147] For example, taking cloud-side devices as servers, such as Figure 4 As shown, the cloud-side device 300 may include a processor 401 (optionally, including a processor 408), a memory 403, a transceiver 404, etc.

[0148] The aforementioned components may include a pathway for transmitting information between them.

[0149] The transceiver 404 is used to communicate with other devices or communication networks using protocols such as Ethernet and WLAN.

[0150] For detailed information on the processor and memory, please refer to [link / reference needed]. Figure 3A The description of the relevant structures in the mobile phone is omitted here.

[0151] The technical solutions of this application can be applied to sports scenarios, including but not limited to running, walking, rowing, and swimming. After a user engages in exercise, based on the user's exercise data, the user's movement trajectory at different times can be obtained, and the image of the moving user can be inserted into a video template. The video template includes scenes (such as buildings, trees, etc.). In this way, a video of the user exercising within the scene of the video template can be obtained. In some embodiments, if the video template also includes moving figures, then inserting the moving user into the video template can obtain a video of that user exercising together with other moving figures.

[0152] Taking running as an example, users can collect their exercise data during a run using devices such as fitness trackers. This exercise data can then be accessed by a target application. As one possible implementation, the target application can be configured by the user. For instance, a user can authorize fitness apps like Health and Fitness to access their exercise data. If the target application includes a fitness app, the user can then use the fitness app to synthesize the exercise data into a workout video.

[0153] like Figure 5 As shown, fitness apps can access motion data collected by sensors in devices such as fitness trackers and record the collected data in the app's corresponding storage space. For example... Figure 5 As shown in (a), the exercise data records include: exercise data from running on May 11, exercise data from running on April 21, etc.

[0154] Next, as Figure 5 As shown in (a), in interface 601, the user selects the exercise data for May 11th by clicking on it. In response to the user's selection of exercise data, the phone displays something like... Figure 5 Interface 602 is shown in (b). Optionally, through this interface 602, users can visually observe their running route.

[0155] In this embodiment, interface 602 may include control 603. When a user's preset operation on control 603 is detected, the mobile phone can generate a motion video corresponding to the motion data according to a motion video generation algorithm. Alternatively, the mobile phone sends a request or notification to the server to generate a motion video, and the server generates the motion video corresponding to the motion data according to the motion video generation algorithm. Alternatively, the mobile phone itself performs some steps of generating the motion video, while the server performs other parts of the motion video generation operation. That is to say, motion video synthesis can be completed on a terminal such as a mobile phone on the device side, or on a server on the cloud side, or the motion video synthesis process can be completed through collaboration between the device and the cloud.

[0156] Taking mobile phone-generated motion videos as an example, for each frame of the motion video, the phone calculates information such as the user's movements and position based on motion data at the corresponding time, scene model information, and image information, generating a motion image of the user, and inserting the user's motion image into the corresponding frame in the video template. For example, to calculate the user's position based on motion data, the phone can initialize the user's position in the first frame and calculate the user's position in subsequent frames based on motion data such as stride length, cadence, and running speed.

[0157] The image information does not necessarily need to be collected synchronously with the motion data. For example, the image information can be uploaded / selected by the user, or it can be preset by the system. Alternatively, there are other ways to collect image information, which are not limited in this embodiment.

[0158] For example, such as Figure 6 As shown, the phone initializes the position of the person in the first frame of the video template. Subsequently, the phone can calculate the position of the person in the Xth frame of the video template based on the initial position, running speed in the motion data, and scene model information in the video template, and insert the person into the Xth frame of the video template to obtain the Xth frame of the motion-synthesized video. Similarly, the phone can calculate the position of the person in the Yth frame of the video template based on the initial position and running speed in the motion data, and insert the person into the Yth frame of the video template to obtain the Yth frame of the synthesized motion video.

[0159] After generating the workout video, users can view it through a fitness app. For example, users can view the video through... Figure 5 The interface 604 shown in (c) displays the generated motion video 605. Interface 604 includes a video playback control 606, which allows the user to control the playback, pause, fast forward, and rewind of the motion video 605.

[0160] The technical solution of this application eliminates the need to simultaneously collect user image information and motion data. Instead, it allows for the synthesis of user motion videos based on the acquired motion data. Compared to existing technologies that require simultaneous collection of image information and motion data, this application's implementation complexity is lower, and users can more conveniently utilize the motion video synthesis function. Furthermore, since it is no longer limited to acquiring real-time image information using devices such as cameras, it can be applied to various sports scenarios. For example, the solution of this application can be applied outdoors without the assistance of a camera operator, allowing for the synthesis of user motion videos after acquiring motion data.

[0161] As another example, in such Figure 1 In the scenario shown, if the video synthesis scheme of this application embodiment is used, it is not necessary to collect the user's video image information in real time through the smart screen's camera, nor is it necessary for the smart screen to process multiple frames of video images, which not only reduces the difficulty of data collection, but also reduces the complexity of data processing.

[0162] Optional, Figure 5The interface 602 shown may also include other controls. For example, it may include a trajectory animation generation control for generating a "trajectory animation". When a user's preset operation on the trajectory animation generation control is detected, the mobile phone can generate a trajectory animation (or trajectory video) corresponding to the user's motion data based on the user's motion data. In the trajectory animation, a 3D character model can move along a certain motion trajectory. The 3D character model can be a character model built based on the user's image data (which can be system default or user-uploaded / selected). Figure 7 This demonstrates a trajectory animation generated from motion data.

[0163] and Figure 5 Unlike synthetic motion videos, Figure 7 The synthesized trajectory video can be generated without the use of a video template.

[0164] As one possible implementation, mobile phones can recommend things to users such as... Figure 7 The trajectory shown is suitable for various locations along the way. For example, via locations such as... Figure 7 The interface shown in (a) or (b) recommends to the user.

[0165] As one possible implementation, mobile phones could provide users with an entry point for editing trajectory animations. For example, ... Figure 7 As shown, users can move the position of the 3D character model on the trajectory by dragging and other operations.

[0166] exist Figure 5 In the scenario shown, the user's fitness software and / or wearable devices (such as fitness trackers) correspond to... Figure 2 The motion data acquisition adapter module is shown. In some examples, the mobile phone may include... Figure 2 The example includes modules such as a video template processing module and a motion video generation module, and the mobile phone synthesizes the motion video based on the collected motion data. In other examples, the server may include... Figure 2 The system includes modules such as a video template processing module and a motion video generation module, with the motion video synthesis being completed by the server. In other examples, the server may include some modules of the video synthesis subsystem, and the mobile phone may include other modules of the video synthesis subsystem, with the motion video synthesis being completed jointly by the device side (e.g., the mobile phone) and the cloud side (e.g., the server).

[0167] The motion video generation method of this application embodiment does not require the simultaneous collection of motion data and image data. Therefore, when a user is exercising, it is not necessary to carry dedicated equipment such as a camera, or to require a dedicated person to assist in real-time image capture. This lowers the threshold for using the synthetic motion video function and greatly expands the applicable scenarios of the motion video generation technology solution.

[0168] In some embodiments, the video template library (a portion of the information database) may include one or more video templates. Video templates can be different types of sports videos, including but not limited to videos of running, swimming, rowing, and other sports. Video templates in the video template library can be added and updated automatically by the system or by the user.

[0169] For example, Figure 8 This illustrates the process of a user adding a video template to the video template library. For example... Figure 8 As shown in (a), the motion application may include a video template library interface, which may include control 801. When a user's preset operation on control 801 (such as a click operation) is detected, the mobile phone may display... Figure 8 Interface 802 is shown in (b). In some designs, interface 802 can be a preview interface for a local photo album, meaning that users can select locally stored videos as video templates through interface 802. In other designs, interface 802 can select videos from the internet (not locally stored) as video templates. For example, through interface 802, users can select or enter the URL of a celebrity's running video. www.xxx.com Then, the phone adds the running video from that URL to the video template library.

[0170] Assuming Figure 8 As shown in (b), the user selected the first locally stored video as the video template. Therefore, after detecting the user's selection of the video (e.g., clicking on the video), the phone can optionally display the following: Figure 8 Interface 803 is shown in (c). Interface 803 includes the video selected by the user. Optionally, interface 803 also includes a clipping control 804 corresponding to the video selected by the user. The user can drag the clipping control 804 to clip the selected video to extract a certain length of video as a video template.

[0171] Optionally, interface 803 may also include other controls, such as... Figure 8 The control 805 for editing background music is shown in (c). Users can select or upload background music (BGM) by manipulating the control 805. The phone can also provide various BGM settings options. For example, it provides playback mode options so that users can choose how the BGM is played (single loop or multi-track playback), and provides sound effect options, etc.

[0172] like Figure 8 As shown in (c), when a user's action, such as clicking the "Confirm Add" control, is detected, the phone adds the user-selected video to the video template library and can display, for example, Figure 8Interface 804 is shown in (d). Interface 804 includes the newly added video template 4 by the user.

[0173] In some examples, optionally, users can input motion data for a video template into the video template library when uploading or adding it. For example, with a running video template, users can input the stride length, cadence, and duration of the person running in the video template.

[0174] In other examples, the system can analyze and calculate motion data of people in a video template based on motion video analysis algorithms. Subsequently, the motion data of the people in the video template can be compared with the motion data of other users. The system can also display the motion data of each person to the user in the synthesized motion video.

[0175] In some embodiments, users can select video templates from a video template library. Thus, when a user instructs the generation of a motion-based composite video, the system can insert a moving figure into the user-selected video template. The figure's movement is simulated based on motion data. For example, such as... Figure 9A As shown in (a), when a user's action, such as clicking control 603, is detected, the phone can image as follows: Figure 9A The interface shown in (b) includes control 903. When a user's preset action (such as a click) on control 903 is detected, the phone can display the following... Figure 9A The interface 901 is shown in (c). Interface 901 may include control 902. When a user's action, such as clicking on video template 4, is detected, and when a user's action, such as clicking on control 902, is detected, the mobile phone can determine that the user has selected video template 4 as the video template to be used for this video synthesis.

[0176] In some examples, optionally, after the user selects the video template to be used in this video synthesis, the mobile phone can be... Figure 9A The interface shown in (c) 901 will automatically redirect back. Figure 9A Interface 908 is shown in (b). Alternatively, a control X can be set in interface 901 to jump back to interface 908. When a user's action such as clicking on control X is detected, the phone jumps back to interface 908. When a user's action such as clicking on the "OK" button on interface 908 is detected, the phone inserts the moving figure into video template 4, compositing it as shown in (b). Figure 9B The motion video shown can be used to illustrate the movement of the person inserted into the video. For example, the stride length and cadence of the person running in the video can be obtained from the collected motion data.

[0177] In some examples, optionally, the phone is rendered. Figure 9AAfter interface 908 as shown in (b), if no user click on control 903 is detected, and the user directly clicks the "OK" button, the phone will use the default video template as the video template required for this synthesized motion video, or the phone will use the video template used in the previous synthesized motion video, or the phone will use the recommended video template based on the user profile that can be authorized to use it. Alternatively, the phone can automatically select the video template required for this synthesized motion video for the user based on other strategies.

[0178] In some examples, optionally, interface 901 may also include control 905, which is used by the user to add a new video template. The added new video template can be a local video on the mobile phone or a non-local network video.

[0179] In some embodiments, after a user selects a video template, the selected template can be edited based on the user's actions. For example, the user's selected video template can be edited according to the user's instructions. Figure 9A Edit the video template 4 shown in (c) and insert the moving figure into the edited video template 4.

[0180] In other embodiments, a default video template can be set by the system or the user. This allows the system to insert moving figures into the default video template when the user instructs the generation of a motion-based composite video.

[0181] The following section details the technical implementation of synthesized motion video. Figure 10 As shown in the embodiments of this application, the method for synthesizing motion videos mainly includes collecting user motion data, and inserting the moving user into the video template based on the motion data, video template, and user image information. The collection of user motion data can be achieved by a motion data acquisition and adaptation module collecting motion data from the user, or by the motion data acquisition and adaptation module obtaining user motion data from third-party software and / or third-party motion assistive devices.

[0182] The collection of user exercise data can be achieved using devices, modules, or equipment that interact with the user. For example, user exercise data can be collected through sensors installed on the user's wearable devices, mobile phone, or fitness equipment. It can also be collected through applications installed on the user's mobile phone or other devices. This application does not limit the method of collecting exercise data; user exercise data can be collected in various possible ways.

[0183] In some embodiments, the motion data collected by different modules may have different formats. Even when the same module collects motion data, the data for different types of motion may have different formats due to differences in the type of motion. Types of motion include, but are not limited to, running, rowing, cycling, and mountain climbing. To adapt to various types of motion data, the data acquisition subsystem of this application embodiment may include a motion data acquisition adaptation module. This module can process different types of motion data and construct a unified motion data model for various types of motion data. For example, Figure 11 An example of a motion data model is shown.

[0184] Optionally, after acquiring the user's motion data, a persona model of the user can be constructed. This persona model represents the user, and inserting it into a video template can generate a motion video of the user based on that motion data. Optionally, the persona model can be a 3D model or other types of models.

[0185] As one possible implementation, users can upload profile information (or image information) that reveals their characteristics. The motion video synthesis system then constructs a character model based on this profile information. The user's profile information can be in various forms, such as text, images, and videos. Text representing user characteristics includes, but is not limited to, facial features, height, weight, age, and clothing. The system can employ any character modeling algorithm to construct the character model based on the profile information; this application does not impose any limitations on this approach.

[0186] It should be noted that user profile information is optional. Users can also choose not to upload profile information. In this case, the system will specify a default profile for the user and build a default character model.

[0187] For example, such as Figure 9A As shown in (a), when a user's preset action on control 603 (such as a click) is detected, the phone displays something like... Figure 9A As shown in (b), interface 908 includes control 904. When a user action such as clicking on control 904 is detected, the phone can display... Figure 9AThe interface shown in (d) may include one or more image data (e.g., image 1, image 2). Taking the user selecting image 1 as image data as an example, when the phone detects a user's click operation on image 1 and a click operation on control 906, the phone determines that the user has selected image 1 as the image data required for this video synthesis. The phone can automatically jump back to interface 908, or, after detecting the user's instruction to jump to interface 908 on interface 909, the phone jumps to interface 908. When the phone detects a user's click operation on the "OK" button on interface 908, the phone can insert the character model corresponding to image 1 into the video template used for this video synthesis, thereby obtaining, for example... Figure 9B The user's workout video is shown.

[0188] In some examples, optionally, the interface 909 shown in 9A(d) may also include a control 907 for the user to add new image data.

[0189] As another possible implementation, after obtaining the user's authorization, the system can automatically collect the user's profile information and construct a virtual avatar model of the user based on the profile information.

[0190] As another possible implementation, the system can also use a default user persona to represent users. In some examples, the default user persona is the same for different users. In other examples, the default user persona can be different for different users. Optionally, the system can automatically recommend different user personas based on the user profiles that different users can authorize. For example, the system recommends a male user persona for male users and a female user persona for female users.

[0191] Optionally, the system can store information related to the character model in a database. This information includes, but is not limited to, image data and information about the constructed character model.

[0192] For example, Figure 12 This illustrates the interactions between the user (or system administrator) and various modules, and between modules, during the process of adding character modeling information to the video template library.

[0193] As described in the above embodiments, the video templates used for synthesizing motion videos can be automatically added to the video template library by the system; in other words, the video templates can be preset by the system. For example, the system can collect user profiles that can be authorized to use and determine the video templates that the user may use based on the user profiles. Alternatively, the system can obtain network information and recommend or add other frequently used video templates to the user's video template library. The system can also combine the user profiles that can be authorized to use with the recommendation of video templates to the user.

[0194] In other embodiments, optionally, the video templates can be added to the video template library by the user or system administrator. For example, Figure 8 This illustrates a set of interfaces used by users when adding video templates to a video template library. For example, Figure 15 This illustrates the interactions between the user (or system administrator) and various modules, and between these modules, during the process of a user (or system administrator) adding video templates to the video template library. The user (or system administrator) can interact through methods such as... Figure 8 The user interface and other operations add video templates to the video template library. After detecting this user action, the video template processing module processes the template and obtains its relevant information. For example, it can extract information about one or more video templates from the scene, characters, and motion data. The module can also store this information in an information database.

[0195] After acquiring the user's image data (e.g., user-uploaded or system default), motion data, and video templates, a motion image of a person model can be generated based on the image data, motion data, and scene model information in the video template. The background of this motion image of the person model can be transparent. For example, Figure 13 This diagram illustrates the interaction between various modules during the generation of a motion video of a character model (or virtual character). Specifically, when collecting motion data, the motion data acquisition and adaptation module (such as a sports application, sensor, or other assistive device) can collect motion data from the user. Alternatively, the motion data acquisition and adaptation module can collect the user's motion data from third-party sports software or third-party sports assistive devices. The motion data acquisition and adaptation module can perform processing such as formatting on the motion data and construct a unified motion data model. The virtual character motion image generation module can obtain the processed motion data from the motion data acquisition and adaptation module, retrieve information about the character model and video templates (such as scene model information) from a database, and generate motion images of the virtual character based on the motion data, character model information, and video template information. For example... Figure 14AAs shown, motion data is primarily used to calculate the movements and positions of characters in each frame of a motion video. Character model information is mainly used to simulate characters in the motion video. Information related to the video template (such as scene model information) can be used to calculate the viewpoint, character position, and character size in each frame of the motion video. For example,... Figure 14B The diagram illustrates how the perspective, character size, and position change across frames with different scene models. It shows that when the size of the scene model (such as trees or roads) differs, the character size also differs. When the scene perspective changes, the frame's perspective also changes, and the character model's display perspective changes accordingly.

[0196] For example, Figure 6 The image shows the first, Xth, and Yth frames of the virtual character generated by the system, with a transparent background for each frame.

[0197] After acquiring the motion image of the virtual character (with a transparent background), the system can insert the image of the virtual character into the corresponding image frame of the video template. In other words, the video template can be used as the background for the virtual character's motion. For example, Figure 16 The interaction between the modules during the synthesis of motion video is shown.

[0198] The above description uses a single-person motion video as an example to illustrate the motion video synthesis method of this application. In this application, motion videos involving multiple people can also be synthesized. Specifically, based on a user's motion data, the user's motion can be synthesized into the motion videos (video templates) of other people, forming a video of the user exercising together with other people. Optionally, the motion type of the user is the same as the motion type of the people in the video template. For example, if the user's motion type is running, the motion type of the people in the video template is also running. One or more users can be inserted into the video template. When multiple users are inserted into the video template, they can be sequentially synthesized into one video template in a certain order to form a video of multiple users exercising together.

[0199] For example, such as Figure 17 As shown, the system can collect the user's motion data and generate frame-by-frame motion images of the virtual character based on the motion data. Figure 17 (Only one frame is shown as an example) The motion images of each frame of the virtual character are inserted into the corresponding template image frames of video template A to obtain a motion video of the user moving with other characters.

[0200] Video template A can be a celebrity's workout video or a workout video of other people (such as friends). The method for adding video template A to the video template library can be found in the aforementioned embodiment, and will not be repeated here.

[0201] The following examples illustrate several scenarios for synthesizing motion videos involving multiple people (which can be referred to as multi-person motion videos).

[0202] Scenario 1: The synthesized exercise video could be a video of the user exercising with a celebrity. In this implementation, the video template can be a celebrity's exercise video. The user can select a celebrity's exercise video, and the system can insert the user's exercise video into the celebrity's exercise video to synthesize an exercise video of the user exercising (e.g., competing) with the celebrity. For example... Figure 18A (a)-(d) Figure 18B Some interfaces are shown in the video synthesis process. Figure 19 This example demonstrates editing and synthesizing motion videos within a video editing application. The specific implementation of each interface and the corresponding user operations, as well as the phone's response, can be found in the above embodiments and will not be repeated here. For example,... Figure 19 The video demonstrates the interactions between various modules during the creation of a video showing a user exercising alongside a celebrity.

[0203] It should be noted that the celebrity's workout videos can be uploaded to the system by the celebrity themselves, such as by uploading them to the server through an editing application. Alternatively, they can be authorized workout videos obtained by the server in this embodiment from other servers.

[0204] Scenario 2: The synthesized sports video can be a video of a user exercising with a friend. Taking user B as the video template, user B can complete the input of sports data and image information in the system according to the method described in the above embodiment. The input of image information is an optional step. User A can select user B's sports video as the video template, and the system can insert user A's sports video into user B's sports video to synthesize a sports video of user A and user B competing. For example, as shown... Figure 20A , Figure 20B The diagram shows some interfaces during the process of the system synthesizing the competition video between user A and user B.

[0205] Scenario 3: The synthesized motion video is a team motion video.

[0206] The asynchronous nature of the team workout video synthesis in this application embodiment means that users are not required to exercise while the video is being synthesized, or that motion data is not collected and synthesized simultaneously, or that motion data from multiple users is acquired asynchronously. Users can exercise first, and then upload their motion data so that the system can synthesize a workout video based on the motion data. For example, the mobile phone displays... Figure 21A The clip application interface shown in (a) is used, and if a user's click action on control 1901 is detected, then the phone can display something like... Figure 21A The interface shown in (b) includes controls 2101 and 2102. Control 2101 is used to set information related to synthesizing team sports videos, and control 2102 is used to set information related to synthesizing individual sports videos (e.g.,...). Figure 5 The relevant information for the single-person exercise video shown in (c). Figure 21A The interface shown in (b) may also include other controls or remove certain controls.

[0207] When a user's interaction with control 2101, such as clicking, is detected, the phone can display... Figure 21A Interface 2108 is shown in (c). Interface 2108 includes controls 2104-2107. Controls 2104 and 2105 are described in the relevant descriptions of controls 903 and 904 in the above embodiments. Control 2106 can be used to set parameters such as the number of team members. Control 2107 can be used to set the movement route of the team. Optionally, interface 2108 may also include other controls for setting other parameters of the team movement video. When a user click operation is detected on control 2106, the mobile phone can display... Figure 21A The interface shown in (d) is as follows.

[0208] pass Figure 21A The interface shown in (d) allows you to select a team. Optionally, you can also set the number of team members and the maximum number of team members through this interface. If a maximum number of team members is set, the system will not allow other users to join the team once the maximum number of people has been reached.

[0209] Optional, via Figure 21A The interface shown in (d) also allows you to set the type of team activity, such as setting it to a running race. Optionally, you can also use this interface to invite friends to participate in recording the team's activity video. Optionally, you can also use this interface to set other team-related parameters.

[0210] In some examples, optionally, users can select teams and view the authorized personal information of team members. This allows users to choose their preferred team based on member information and have their workout videos generated by the system. For instance, users can join a team composed of top-ranked users and have their workout videos generated by the system to enhance the fun of exercise and encourage users to exercise.

[0211] Taking user A as an example, assuming user A chooses to join a team that includes users B and C, user A can also choose the video template used to create the team's workout video (or use the system's default video template). For example, user A can... Figure 21A The control 2104 shown in (c) allows selection of a video template. User A can also set their own image data in the team sports video. For example, User A can... Figure 21A The control 2105 shown in (c) uploads the user's own image data (or can use the system's default image data). User A can also set their own motion data. For example, the user can... Figure 21A The control 2109 shown in (c) can upload its own motion data, or authorize the acquisition of motion data stored in the mobile phone through the control 2109.

[0212] Similarly, Users B and C can choose their desired video templates (or use the default video template). Users B and C can also set their respective image data for the team sports video. Users B and C can also set their individual movement data.

[0213] It should be noted that team members can upload their own exercise data individually, and there are no restrictions on the upload time or exercise location between them. They can complete the exercise at different times and locations, or complete the exercise at the same time and location, and upload the exercise data offline.

[0214] When creating a team's motion video, the system generates individual motion videos based on the motion and image data of users A, B, and C, and then inserts these three videos into a video template to obtain the team's motion video. For example, Figure 22 The process of synthesizing team motion videos is illustrated. Optionally, for the motion images of virtual characters corresponding to multiple users, the motion images of multiple virtual characters can be synthesized into the corresponding template image frames of the video template in a certain order.

[0215] It should be noted that users A, B, and C can choose the same video template or different video templates. For example, suppose user A chooses video template 1, and users B and C choose video template 2. Figure 21BThe image shows team sports videos displayed on phones A and B, respectively. The backgrounds of the team sports videos displayed on phones A and B are different: phone A displays video template 1, while phone B displays video template 2.

[0216] It's important to note that when creating multi-person workout videos, the team organizer can create a task and specify certain parameters, such as video templates, exercise types, and duration requirements. In this case, the workout videos created by the system for different users are usually consistent. For example, the backgrounds of workout videos created for different team members might all be the same. Alternatively, the team organizer can specify some parameters, while team members specify others. For instance, the team organizer might specify the exercise type as running and the duration as one hour, while team members specify their own video templates and upload their individual workout data. In this case, the backgrounds of the workout videos created by the system for different members might differ.

[0217] For example, such as Figure 23 The diagram illustrates the interactions between various modules during the synthesis of a team movement video. It should be noted that, due to size limitations in the attached diagram, [the following text is incomplete and requires further context]. Figure 23 The technical details of the motion data acquisition adapter module collecting motion data from users through third-party software or motion assistive devices are shown only by way of example, and the technical details of the motion data acquisition adapter module directly collecting motion data from users are not shown.

[0218] This method allows multiple users to exercise asynchronously, at different times and locations. In other words, users don't need to exercise at the same time; any user can exercise at a convenient time and place. The system can then combine multiple exercise videos from different users at different times and locations into a single video of a team exercising together, providing convenience for users to utilize the composite exercise video function.

[0219] Scenario 4: The synthesized motion video is a team motion video.

[0220] Unlike Scenario 3, in Scenario 4, team members choose a unified exercise route. For example, based on a map, they select a unified map trajectory. For instance, they might choose the outer edge of XX Park in Beijing as the unified exercise route. The system collects each user's exercise data along this route and can generate individual exercise videos based on the data. These individual videos are then inserted into a video template to obtain the team's exercise video.

[0221] In this application, various synthesized sports videos can be uploaded and shared with user authorization. Team sports videos, in particular, can be viewed within the team or uploaded or shared online with the authorization of team members.

[0222] Scenario 5: Synthesizing online team sports videos

[0223] Unlike scenarios three and four, in scenario five, team members need to exercise within the same time period or exercise synchronously, and their exercise data is acquired synchronously. The system can acquire each user's exercise data, generate exercise videos for each user, and insert each user's exercise data into a video template to synthesize a team's sports competition video.

[0224] For example, users can... Figure 24 Select the synthesized motion video in the interface shown in (a). For example, as... Figure 24 As shown in (b), when a user instruction to select a composite team sports video is detected, such as when the user clicks control 2101, the phone can display something like... Figure 24 The interface shown in (c) includes an online mode control 2401 and an offline mode control 2402. After detecting a user's selection of online mode, the phone can display something like... Figure 24 Interface 2404 is shown in (d). Users can set options related to synthesizing motion videos using the controls in interface 2404. For example, they can select image information using control 2105 and select a video template using control 2104. Users can also turn on the motion data acquisition switch 2403, so that the mobile phone can report the user's motion data in real time during the motion data acquisition process. Based on the user's motion data, the system can generate motion images of virtual characters in real time and merge the motion images of virtual characters into the corresponding template image frames of the video template in real time.

[0225] In this online motion video generation solution, for example, taking the server-side motion video synthesis step as an example, the server can distribute the synthesized team motion video to the terminal via streaming media. Users can then use the video playback and download module on their terminal (e.g., a mobile phone) to pull the latest motion video stream in real time. Users can then watch the synthesized motion video on their terminal. Optionally, the server can store segments of the real-time generated motion video.

[0226] As can be seen, this online motion video synthesis scheme allows the system to simultaneously acquire motion data from multiple users and synthesize motion videos from multiple users. Optionally, the system synthesizes a user's motion video based on motion data during the user's movement. Alternatively, the system synthesizes the user's motion video at other possible times; this application embodiment does not limit the timing of motion video generation.

[0227] As one possible implementation, in the optional online mode of Scenario 5, the community organizer can create tasks, specifying video templates and one or more parameters such as exercise type, duration, and start time. Each community member can open the exercise app at the designated time and perform the same exercise pattern at different locations. Each member's exercise app will automatically collect their exercise data, and the system can then synthesize the exercise video based on this data.

[0228] Compared to existing video compositing solutions, the technical solution of this application embodiment can support the collection of user motion data from various software and / or hardware through a motion data acquisition adapter module, and can complete video compositing without the need for proprietary equipment, thereby reducing the technical threshold for compositing motion videos.

[0229] It should be noted that in scenario five, multiple users can move around in different locations. In other words, people moving in different locations can be combined into a single exercise video, increasing the video's entertainment value.

[0230] Through the aforementioned embodiments, users can set relevant options for synthesized motion videos on terminals such as mobile phones. For example, through such... Figure 24 The interface shown allows users to select video templates, upload profile data, etc. Users can also choose to display the synthesized exercise video in real-time on the screen of devices with displays, such as treadmills. For example,... Figure 25 As shown, a user is running on a treadmill. The user can choose to display a synthesized exercise video on the treadmill screen via a terminal such as a mobile phone. In this way, the user can watch the running status of teammates while exercising, which increases the fun of exercise.

[0231] Optionally, fitness equipment such as treadmills can also simulate road conditions seen in workout videos. For example, if a steep incline appears in a workout video, the treadmill can create a bumpy feeling through vibration. The treadmill can also warn the user before the vibration begins, allowing them to prepare accordingly.

[0232] In the above embodiments of this application, the technical solution for generating motion videos is mainly described using sports applications and editing applications as examples. It can be understood that other applications that can edit and generate motion videos can also apply the technical solution for generating motion videos in the embodiments of this application.

[0233] In addition to scenarios such as sports and fitness, the technical solutions of this application embodiment can also be applied to scenarios such as variety shows and singing.

[0234] In some embodiments, optionally, the user's motion data can be tagged into the synthesized motion video. For example, such as... Figure 21BAs shown, the synthesized team motion video is labeled with the motion data of each team member. This motion data can characterize the user's motion status.

[0235] Optionally, motion data of a template character can also be tagged into the synthesized motion video. The template character is the person in the video template. For example, such as... Figure 18B As shown, the motion data of a template person, i.e., a celebrity, can be labeled in the synthesized motion video. Optionally, the motion data of a user (i.e., a black-clad human model) can also be labeled in the synthesized motion video.

[0236] Optional, such as Figure 2 The motion video synthesis system may also include more or fewer modules, or combine some modules, or split some modules. Alternatively, some modules may be replaced with other modules with similar functions. This application does not limit the specific architecture of the system.

[0237] As described above, video templates and user profile data can be system default settings or user-selected or uploaded. Furthermore, this application does not limit the timing of uploading or selecting video templates or user profile data. For example, users can select / upload video templates when they need to synthesize motion videos, or select / upload video templates in advance.

[0238] In some embodiments of this application, optionally, a corresponding exercise type can be determined for the exercise data. For exercise data corresponding to a first exercise type, the exercise data corresponding to the first exercise type includes a trajectory. For exercise data corresponding to a second exercise type, the exercise data corresponding to the second exercise type does not include a trajectory. For example, the first exercise type includes, but is not limited to, outdoor running, swimming, walking, cycling, and soccer. Exercises of the first exercise type can generally form a movement trajectory. The second exercise type includes, but is not limited to, running on a treadmill. The second exercise type generally does not involve a change in physical position, or the change in physical position is small, and is considered not to have formed a movement trajectory.

[0239] For the first motion type, generating motion videos for the one or more users based on the motion data and the video template data can be implemented as follows: generating motion videos for the one or more users based on the trajectory in the motion data corresponding to the first motion type and the video template data. For example, suppose... Figure 5 The motion data shown in (b) is the user's running motion data along xx park. The system can generate a motion video based on the motion trajectory in the motion data and the data of the video template.

[0240] For the second motion type, generating motion videos for the one or more users based on the motion data and the video template data can be implemented as follows: generating motion videos of the one or more users moving along the route indicated by the route data, based on the motion data corresponding to the second motion type and the route data. For example, as shown... Figure 25 As shown, when a user runs on a treadmill, the system can generate a route indicated by the user's route data based on the route data in the video template (e.g., ...). Figure 25 A moving video template of a road.

[0241] like Figure 26 An exemplary flow of a video generation method according to an embodiment of this application is shown. The method includes:

[0242] S2601. Obtain the video template data.

[0243] Optionally, the data could be either video footage of a person's movement or video footage of a scene. Video footage of a person's movement could be, for example,, but is not limited to, videos of celebrities or other individuals moving. For instance, video footage of a person's movement could be... Figure 21B The video shown. For example, a scene video could be... Figure 6 The video template shown.

[0244] Optionally, the motion video can be a motion video synthesized using the video generation method of the present application embodiment, or a regular motion video, i.e., a motion video not synthesized using the video generation method of the present application embodiment.

[0245] For example, the phone selects from the video template library. Figure 9A The video template shown in (c) is used as a template.

[0246] In this embodiment of the application, steps S2601-S2603 can be performed by... Figure 2 The motion video synthesis system shown performs this operation. Modules in this system can be terminal devices (such as mobile phones) or modules within terminal devices. They can also be cloud-based (such as servers) or cloud-based modules. For example, step S2601 is performed by… Figure 2 The video template processing module shown is executed.

[0247] S2602. Collect motion data from one or more users.

[0248] The exercise data includes one or more of the following: speed, amplitude, frequency, and trajectory. Optionally, the exercise data may also include one or more of the following: heart rate, blood pressure, blood oxygen saturation, and body temperature. Taking running as an example, amplitude can refer to stride length, and frequency can refer to cadence.

[0249] For example, the mobile phone collects data such as... Figure 9A The motion data is shown in (a).

[0250] For example, step S2602 is performed by Figure 2 One or more modules are executed in combination: motion data acquisition and adaptation module, motion software module, and auxiliary motion equipment (hardware module).

[0251] S2603. Generate motion videos for one or more users based on motion data and video template data.

[0252] For example, the system according to Figure 9A The motion data shown in (a) and Figure 9A Video template 4 shown in (c) is generated. Figure 9B The user's motion video is shown.

[0253] For example, step S2603 is performed by Figure 2 The motion video generation module of the video synthesis subsystem shown is executed. It can be understood that the motion video generation module, based on motion data and video template data, can generate a user's motion video using the video template data and the motion image of a person generated by the virtual person motion image generation module.

[0254] Other embodiments of this application provide an apparatus, which can be the aforementioned electronic device (such as a foldable screen phone). The apparatus may include a display screen, a memory, and one or more processors. The display screen, memory, and processors are coupled. The memory stores computer program code, which includes computer instructions. When the processor executes the computer instructions, the electronic device can perform various functions or steps performed by the mobile phone in the above method embodiments. The structure of the electronic device can be referred to... Figure 3A or Figure 4 The electronic device shown.

[0255] The core structure of this electronic device can be represented as follows: Figure 27 The structure shown may include: a processing module 1301, an input module 1302, a storage module 1303, and a display module 1304.

[0256] The processing module 1301 may include at least one of a central processing unit (CPU), an application processor (AP), or a communication processor (CP). The processing module 1301 can perform operations or data processing related to control and / or communication with at least one of other components of the user electronic device. Specifically, the processing module 1301 can be used to control the content displayed on the main screen according to certain trigger conditions, or to determine the content displayed on the screen according to preset rules. The processing module 1301 is also used to process input instructions or data and determine the display style based on the processed data. As one possible implementation, the processing module 1301 may have the above-described features. Figure 2 The system shown includes the functions of one or more modules such as a motion video generation module, a video template processing module, an image data processing module, and a motion data acquisition video module.

[0257] Input module 1302 is used to acquire user-inputted instructions or data and transmit the acquired instructions or data to other modules of the electronic device. Specifically, the input method of input module 1302 may include touch, gesture, proximity to the screen, or voice input. For example, the input module may be the screen of the electronic device, acquiring user input operations and generating input signals based on the acquired input operations, and transmitting the input signals to processing module 1301. In this embodiment, the input module can be used to receive user-inputted image data, motion data, etc., and / or perform other steps.

[0258] The storage module 1303 may include volatile memory and / or non-volatile memory. The storage module is used to store at least one related instruction or data from other modules of the user terminal device; specifically, the storage module may record the location of the UI element on the terminal interface.

[0259] The display module 1304 may include, for example, a liquid crystal display (LCD), a light-emitting diode (LED) display, an organic light-emitting diode (OLED) display, a microelectromechanical system (MEMS) display, or an electronic paper display. It is used to display content that can be viewed by the user (e.g., text, images, videos, icons, symbols, etc.). In embodiments of this application, the display module may be implemented as a display screen, such as a first screen and / or a second screen.

[0260] Optional, Figure 27The illustrated structure may also include a communication module 1305 for supporting communication between the electronic device and other electronic devices. For example, the communication module may be connected to a network via wireless or wired communication to communicate with other personal terminals or network servers. Wireless communication may employ at least one of the following cellular communication protocols: Long Term Evolution (LTE), LTE-A Advanced, Code Division Multiple Access (CDMA), Wideband Code Division Multiple Access (WCDMA), Universal Mobile Telecommunications System (UMTS), Wi-Fi, or Global System for Mobile Communications (GSM). Wireless communication may include, for example, short-range communication. Short-range communication may include at least one of Wi-Fi, Bluetooth, Near Field Communication (NFC), Magnetic Stripe Transmission (MST), or GNSS.

[0261] This application also provides a chip system, such as... Figure 28 As shown, the chip system includes at least one processor 1401 and at least one interface circuit 1402. The processor 1401 and the interface circuit 1402 are interconnected via lines. For example, the interface circuit 1402 can be used to receive signals from other devices (e.g., the memory of an electronic device). As another example, the interface circuit 1402 can be used to send signals to other devices (e.g., the processor 1401). Exemplarily, the interface circuit 1402 can read instructions stored in the memory and send those instructions to the processor 1401. When the instructions are executed by the processor 1401, the electronic device can perform the steps in the above embodiments. Of course, the chip system may also include other discrete devices, and this application embodiment does not specifically limit this.

[0262] This application also provides a computer storage medium that includes computer instructions. When the computer instructions are executed on the electronic device, the electronic device causes the electronic device to perform various functions or steps performed by the mobile phone in the above method embodiment.

[0263] This application also provides a computer program product that, when run on a computer, causes the computer to perform the various functions or steps performed by the mobile phone in the above method embodiments.

[0264] Through the above description of the embodiments, those skilled in the art can clearly understand that, for the sake of convenience and brevity, only the division of the above functional modules is used as an example. In actual applications, the above functions can be assigned to different functional modules as needed, that is, the internal structure of the device can be divided into different functional modules to complete all or part of the functions described above.

[0265] In the several embodiments provided in this application, it should be understood that the disclosed apparatus and methods can be implemented in other ways. For example, the apparatus embodiments described above are merely illustrative. For instance, the division of modules or units is only a logical functional division, and in actual implementation, there may be other division methods. For example, multiple units or components may be combined or integrated into another device, or some features may be ignored or not executed. Furthermore, the coupling or direct coupling or communication connection shown or discussed may be through some interfaces; the indirect coupling or communication connection between devices or units may be electrical, mechanical, or other forms.

[0266] The units described as separate components may or may not be physically separate. A component shown as a unit can be one or more physical units; that is, it can be located in one place or distributed in multiple different locations. Some or all of the units can be selected to achieve the purpose of this embodiment according to actual needs.

[0267] Furthermore, the functional units in the various embodiments of this application can be integrated into one processing unit, or each unit can exist physically separately, or two or more units can be integrated into one unit. The integrated unit can be implemented in hardware or as a software functional unit.

[0268] If the integrated unit is implemented as a software functional unit and sold or used as an independent product, it can be stored in a readable storage medium. Based on this understanding, the technical solutions of the embodiments of this application, essentially or in other words, the parts that contribute to the prior art, or all or part of the technical solutions, can be embodied in the form of a software product. This software product is stored in a storage medium and includes several instructions to cause a device (which may be a microcontroller, chip, etc.) or processor to execute all or part of the steps of the methods described in the various embodiments of this application. The aforementioned storage medium includes various media capable of storing program code, such as USB flash drives, portable hard drives, read-only memory (ROM), random access memory (RAM), magnetic disks, or optical disks.

[0269] The above description is merely a specific embodiment of this application, but the scope of protection of this application is not limited thereto. Any variations or substitutions within the technical scope disclosed in this application should be included within the scope of protection of this application. Therefore, the scope of protection of this application should be determined by the scope of the claims.

Claims

1. A video generation method, characterized in that, The method includes: Acquire data from a video template, wherein the video template includes multiple image frames, and the data of the video template is data from a person's movement video or data from a scene video; Collect motion data from one or more users; the motion data includes any one or more of the following: speed, amplitude, frequency, and trajectory; When the motion data corresponds to a first motion type, motion videos of the one or more users are generated based on the trajectory in the motion data corresponding to the first motion type and the data of the video template. The motion videos of the one or more users include multiple image frames. The Xth image frame of the multiple image frames is obtained by inserting the image of the one or more users at a target time into the Xth image frame of the video template. The target time is the time corresponding to the Xth image frame. X is a positive integer. The motion data corresponding to the first motion type includes a trajectory.

2. The method according to claim 1, characterized in that, The video template data includes route data; the method further includes: If the motion data corresponds to a second motion type, a motion video of the one or more users moving along the route indicated by the route data is generated based on the motion data corresponding to the second motion type and the route data.

3. The method according to claim 1 or 2, characterized in that, Collecting motion data from one or more users includes: collecting motion data from one or more users from a target software module or a target hardware module; Alternatively, it may receive motion data input by one or more users.

4. The method according to claim 1 or 2, characterized in that, The method further includes: Obtain information about the images of the one or more users; wherein the information about the images is information about a preset image, or the information about the images of the one or more users is information about an image input by the one or more users.

5. The method according to claim 4, characterized in that, For any one of the one or more users, asynchronously acquire the user's image information and the user's motion data.

6. The method according to claim 4, characterized in that, The information of the images of the one or more users includes any one or more of the following: images of the one or more users, text describing the characteristics of the one or more users, and videos of the one or more users.

7. The method according to claim 1 or 2, characterized in that, The motion data of the multiple users are acquired synchronously, or the motion data of the multiple users are acquired asynchronously.

8. The method according to claim 1 or 2, characterized in that, The exercise data also includes one or more of the following: heart rate, blood pressure, blood oxygen, and body temperature.

9. An electronic device, characterized in that, include: A processor, a memory coupled to the processor, the memory for storing computer program code including computer instructions, wherein when the processor reads the computer instructions from the memory, the electronic device causes the electronic device to perform the video generation method as described in any one of claims 1-8.

10. A computer-readable storage medium storing instructions, characterized in that, When the instructions are executed on an electronic device, the electronic device causes the electronic device to perform the video generation method as described in any one of claims 1-8.

11. A computer program product containing instructions, characterized in that, When the computer program product is run on an electronic device, the electronic device performs the video generation method as described in any one of claims 1-8.