Method and device for determining fitness course, storage medium and electronic device
By using sequence models and a fitness course graph database to optimize fitness course arrangement, the problem of insufficient scientific rigor in existing fitness courses is solved, achieving scientific and reasonable exercise effects and personalized training.
Patent Information
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2021-07-15
- Publication Date
- 2026-03-03
AI Technical Summary
Existing technologies that determine fitness courses based on users' historical training behavior cannot guarantee scientific and reasonable exercise results.
By determining the training objectives and user characteristics of the target users, and combining historical training data, a sequence model (such as the Seq2Seq model) with both encoder and decoder ends is used to process the user characteristics and training data, generating a list of fitness courses for the predicted time period. The course arrangement is then optimized by combining a fitness course graph database and user preferences.
It achieves a scientific and reasonable arrangement of fitness courses, ensuring the scientific and personalized nature of exercise effects and meeting users' individual training needs.
Smart Images

Figure CN115630939B_ABST
Abstract
Description
Technical Field
[0001] This application relates to the field of fitness course determination technology, and more specifically, to a method, apparatus, storage medium, and electronic device for determining fitness courses. Background Technology
[0002] In the field of sports and fitness, some users who want to exercise lack the corresponding fitness knowledge and are therefore unable to arrange daily training plans to ensure fitness results.
[0003] To help users plan their daily training sessions, related technologies typically provide a plan from a coach for the user to follow. However, this approach lacks personalization and fails to meet users' individual training needs. To further cater to these needs, some technologies recommend courses based on a user's historical training behavior. However, this historical behavior is influenced by the user's exercise preferences, making it difficult to guarantee scientifically sound and effective training results.
[0004] There is currently no effective solution to the problem that fitness courses determined based on users' historical training behavior in related technologies cannot guarantee scientific and reasonable exercise effects. Summary of the Invention
[0005] This application provides a method, apparatus, storage medium, and electronic device for determining fitness courses, in order to solve the problem in related technologies that fitness courses determined based on a user's historical training behavior are difficult to guarantee scientific and reasonable exercise effects.
[0006] According to one aspect of this application, a method for determining fitness courses is provided. The method includes: determining the training goals of a target user and obtaining the user characteristics and historical training data of the target user; inputting the target user's training goals, user characteristics, and historical training data into a first target model for processing to obtain a list of fitness courses within a predicted time period, wherein the first target model is trained from multiple sets of sample data, each set of sample data including user characteristics, training goals, historical training data, and a list of fitness courses within a preset time period for a user sample, wherein the predicted time period and the preset time period are of equal length, the user sample includes real users and preset type users, the user characteristics and historical training characteristics of the preset type users are determined by the characteristics of the user group corresponding to the preset training goals, and the list of fitness courses within the preset time period for the preset type users is determined by fitness courses in a fitness course graph database.
[0007] Optionally, the first target model is a sequence model containing an encoder and a decoder. The training objectives, user features, and historical training data of the target user are input into the first target model for processing to obtain the list of fitness courses within the predicted time period. This includes: inputting the user features, training objectives, and historical training data of the target user into the encoder of the first target model to obtain an encoding vector; and inputting the encoding vector into the decoder of the first target model for decoding to obtain the list of fitness courses within the predicted time period.
[0008] Optionally, before inputting the user characteristics, training objectives, and historical training data of the target user into the first target model for processing to obtain the fitness course list within the predicted time period, the method further includes: obtaining the user characteristics, training objectives, historical training data, and fitness course list within a preset time period of multiple real users to obtain multiple first user sample data; obtaining the user group corresponding to the preset training objective, determining the user characteristics of the preset type of user based on the user characteristics of the user group, determining the historical training data of the preset type of user based on the historical training frequency of the user group, and determining the fitness course list within a preset time period of the preset type of user based on the fitness course graph database; constructing multiple second user sample data from the user characteristics, training objectives, historical training data, and fitness course list within a preset time period of multiple different preset type users; constructing multiple sets of sample data from the multiple first user sample data and the multiple second user sample data, and training a preset sequence model based on the multiple sets of sample data to obtain the first target model.
[0009] Optionally, determining the list of fitness courses for a preset type of user within a preset time period based on a fitness course graph database includes: determining a starting node in the fitness course graph database according to the set training goals, wherein the fitness course graph database consists of multiple nodes, each node representing a fitness course, and the connecting edges between the nodes represent the association between fitness courses; determining the nodes after the starting node in sequence according to the connection relationships between the nodes in the fitness course graph database, resulting in multiple nodes containing sequential relationships; and constructing the list of fitness courses for the preset type of user within a preset time period from the fitness courses corresponding to the multiple nodes containing sequential relationships.
[0010] Optionally, after inputting the target user's training objectives, user characteristics, and historical training data into the first target model for processing to obtain a list of fitness courses within the predicted time period, the method further includes: matching each fitness course in the fitness course list within the predicted time period with fitness courses in the target fitness course database to obtain a fitness course matched for each fitness course, wherein the target fitness course database is a database composed of fitness courses preferred by the target user; and replacing each corresponding fitness course in the fitness course list within the predicted time period with the matched fitness courses to obtain a target fitness course list preferred by the target user.
[0011] Optionally, before matching each fitness course in the fitness course list within the predicted time period with fitness courses in the target fitness course database to obtain the matching fitness course for each fitness course, the method further includes: obtaining a preset number of fitness courses from the fitness course database based on the user characteristics of the target user; inputting the user characteristics of the target user and the course characteristics of the fitness courses in the preset number of fitness courses into a second target model for processing to obtain the target user's preference score for the fitness courses in the preset number of fitness courses, wherein the second target model is trained from multiple sets of sample data, each set of sample data including course characteristics, user characteristics, and user preference tags for fitness courses; determining the fitness courses preferred by the target user from the preset number of fitness courses based on the preference scores, and constructing the target fitness course database from the fitness courses preferred by the target user.
[0012] According to another aspect of this application, a fitness course determination apparatus is provided. The apparatus includes: a determination unit, configured to determine the training objectives of a target user and acquire the user characteristics and historical training data of the target user; and a processing unit, configured to input the target user's training objectives, user characteristics, and historical training data into a first target model for processing to obtain a list of fitness courses within a predicted time period. The first target model is trained using multiple sets of sample data, each set including user characteristics, training objectives, historical training data, and a list of fitness courses within a preset time period. The predicted time period and the preset time period are of equal length. The user samples include real users and users of a preset type. The user characteristics and historical training characteristics of the preset type users are determined by the characteristics of the user group corresponding to the preset training objectives. The list of fitness courses for the preset type users within the preset time period is determined by fitness courses in a fitness course graph database.
[0013] Optionally, the first target model is a sequence model containing an encoder and a decoder. The processing unit includes: an encoding module, used to input the user characteristics of the target user, the training objective, and historical training data into the encoding end of the first target model to obtain an encoding vector; and a decoding module, used to input the encoding vector into the decoding end of the first target model for decoding to obtain a list of fitness courses within the predicted time period.
[0014] According to another aspect of the present invention, a non-volatile storage medium is also provided, the non-volatile storage medium including a stored program, wherein the program, when running, controls the device where the non-volatile storage medium is located to execute a method for determining a fitness course.
[0015] According to another aspect of the present invention, an electronic device is also provided, comprising a processor and a memory; the memory stores computer-readable instructions, and the processor is configured to execute the computer-readable instructions, wherein the computer-readable instructions, when executed, perform a method for determining a fitness course.
[0016] This application employs the following steps: determining the training objectives of the target user and obtaining the user characteristics and historical training data of the target user; inputting the target user's training objectives, user characteristics, and historical training data into a first target model for processing to obtain a list of fitness courses within a predicted time period. The first target model is trained using multiple sets of sample data. Each set of sample data includes the user characteristics, training objectives, historical training data, and a list of fitness courses within a preset time period for the user sample. The predicted time period and the preset time period are of equal length. The user sample includes real users and preset-type users. The user characteristics and historical training characteristics of the preset-type users are determined by the characteristics of the user group corresponding to the preset training objectives. The list of fitness courses within the preset time period for the preset-type users is determined by fitness courses in a fitness course graph database. This solves the problem in related technologies where fitness courses determined based on users' historical training behavior cannot guarantee scientifically sound exercise effects. By training the first target model with the characteristics of real users and preset-type users, and processing the target user's characteristics using the first target model, a list of fitness courses within the predicted time period is obtained, thus ensuring that the designed fitness courses guarantee scientifically sound exercise effects. Attached Figure Description
[0017] The accompanying drawings, which form part of this application, are used to provide a further understanding of this application. The illustrative embodiments and descriptions of this application are used to explain this application and do not constitute an undue limitation of this application. In the drawings:
[0018] Figure 1 This is a flowchart of a method for determining a fitness course according to an embodiment of this application;
[0019] Figure 2 This is a flowchart of an optional fitness course determination method provided according to an embodiment of this application;
[0020] Figure 3 This is a schematic diagram of a fitness course determination device provided according to an embodiment of this application. Detailed Implementation
[0021] It should be noted that, unless otherwise specified, the embodiments and features described in this application can be combined with each other. This application will now be described in detail with reference to the accompanying drawings and embodiments.
[0022] To enable those skilled in the art to better understand the present application, the technical solutions in the embodiments of the present application will be clearly and completely described below with reference to the accompanying drawings. Obviously, the described embodiments are only some embodiments of the present application, and not all embodiments. Based on the embodiments in the present application, all other embodiments obtained by those of ordinary skill in the art without creative effort should fall within the scope of protection of the present application.
[0023] It should be noted that the terms "first," "second," etc., in the specification, claims, and accompanying drawings of this application are used to distinguish similar objects and are not necessarily used to describe a specific order or sequence. It should be understood that such data can be interchanged where appropriate for the embodiments of this application described herein. Furthermore, the terms "comprising" and "having," and any variations thereof, are intended to cover non-exclusive inclusion; for example, a process, method, system, product, or apparatus that comprises a series of steps or units is not necessarily limited to those steps or units explicitly listed, but may include other steps or units not explicitly listed or inherent to such processes, methods, products, or apparatus.
[0024] According to an embodiment of this application, a method for determining fitness courses is provided.
[0025] Figure 1 This is a flowchart of a method for determining a fitness course according to an embodiment of this application. Figure 1 As shown, the method includes the following steps:
[0026] Step S102: Determine the training objective for the target user and obtain the user characteristics and historical training data of the target user.
[0027] Among them, the training goals of the target users can be the goals set by the target users for training specific body parts within a certain period of time. For example, it can be abdominal fat loss in 30 days, back shaping in 15 days, or weight loss in 60 days.
[0028] The user characteristics of the target user may include features such as gender, age, height, and weight. The historical training data of the target user can be the training data of the target user over a period of time in the past, such as the training data recorded when training through fitness apps in the past week.
[0029] Step S104: Input the training objective, user characteristics, and historical training data of the target user into the first target model for processing to obtain a list of fitness courses within the predicted time period. The first target model is trained from multiple sets of sample data. Each set of sample data includes the user characteristics, training objective, historical training data, and a list of fitness courses within a preset time period. The predicted time period and the preset time period are of equal length. The user samples include real users and preset type users. The user characteristics and historical training characteristics of the preset type users are determined by the characteristics of the user group corresponding to the preset training objective. The list of fitness courses for the preset type users within the preset time period is determined by the fitness courses in the fitness course graph database.
[0030] Specifically, the first target model is used to determine the list of fitness courses for future periods based on the target user's user characteristics, training goals, and historical training data. For example, the list of fitness courses for the next month can be determined based on the target user's training data from the past week.
[0031] It should be noted that when training the first target model, not only the list of fitness courses completed by real users was considered, but also knowledge of the sports domain was taken into account. Specifically, the sample data for training the model included not only the user characteristics, training objectives, historical training data, and the list of fitness courses completed within a preset time period for real users, but also the user characteristics, training objectives, historical training data, and the list of fitness courses completed within a preset time period for preset type users (virtual users). The list of fitness courses completed within a preset time period for virtual users was determined by the fitness courses in the fitness course graph database.
[0032] Through the embodiments of this application, knowledge in the field of sports is integrated into a knowledge graph, namely a fitness course graph database, and a fitness course list is generated based on the fitness course graph database. A first target model is used to combine the fitness course list generated by the fitness course graph database with the fitness course list completed by the user. Finally, a fitness course list for a predicted time period is generated through the first target model. The arrangement of this fitness course list takes into account human exercise and health knowledge, which can ensure the user's training effect.
[0033] Optionally, in the method for determining fitness courses provided in this application embodiment, the first target model is a sequence model including an encoding end and a decoding end. Inputting the target user's training objectives, user characteristics, and historical training data into the first target model for processing to obtain a list of fitness courses within the predicted time period includes: inputting the target user's user characteristics, training objectives, and historical training data into the encoding end of the first target model to obtain an encoding vector; and inputting the encoding vector into the decoding end of the first target model for decoding to obtain a list of fitness courses within the predicted time period.
[0034] Specifically, the sequence model can be a Seq2Seq model. The encoder generates a fully connected structure based on the user characteristics of the target user, the training objective, and historical training data, and encodes an X-dimensional vector as the input to the decoder.
[0035] Furthermore, the decoding end determines the list of fitness courses within the predicted time period based on the X-dimensional vector, the list of fitness courses completed by real users, and the list of fitness courses determined by the graph database. Specifically, the first fitness course is determined as the initial value of the decoding end, and then the next fitness courses are determined in sequence until a preset number of fitness courses are determined, thus obtaining the list of fitness courses within the predicted time period.
[0036] The method for determining fitness courses provided in this application embodiment determines the training goals of target users and obtains their user characteristics and historical training data. The training goals, user characteristics, and historical training data are then input into a first target model for processing to obtain a list of fitness courses within a predicted time period. The first target model is trained using multiple sets of sample data. Each set of sample data includes user characteristics, training goals, historical training data, and a list of fitness courses within a preset time period. The predicted time period and the preset time period are of equal length. The user samples include real users and preset-type users. The user characteristics and historical training characteristics of the preset-type users are determined by the characteristics of the user group corresponding to the preset training goals. The list of fitness courses within the preset time period for the preset-type users is determined by fitness courses in a fitness course graph database. This method solves the problem in related technologies where fitness courses determined based on users' historical training behavior cannot guarantee scientifically sound exercise effects. By training the first target model with the characteristics of real users and preset-type users, and processing the target user's characteristics using the first target model, a list of fitness courses within the predicted time period is obtained, thus ensuring that the designed fitness courses guarantee scientifically sound exercise effects.
[0037] Before making predictions using the first target model, model training is required. Optionally, in the method for determining fitness courses provided in this application embodiment, before inputting the user characteristics, training objectives, and historical training data of the target user into the first target model for processing to obtain a list of fitness courses within the prediction time period, the method further includes: obtaining the user characteristics, training objectives, historical training data, and a list of fitness courses within a preset time period for multiple real users to obtain multiple first user sample data; obtaining the user group corresponding to the preset training objective, determining the user characteristics of a preset type of user based on the user characteristics of the user group, determining the historical training data of the preset type of user based on the historical training frequency of the user group, and determining the list of fitness courses within a preset time period for the preset type of user based on the fitness course graph database; constituting multiple second user sample data from the user characteristics, training objectives, historical training data, and list of fitness courses within a preset time period for multiple different preset type users; constituting multiple sets of sample data from the multiple first user sample data and the multiple second user sample data, and training a preset sequence model based on the multiple sets of sample data to obtain the first target model.
[0038] Specifically, the input data in the sample data used to train the first target model includes two parts: one part is the user characteristics, training target, and historical training data of real users, and the other part is the user characteristics, training target, and historical training data of preset type users. For example, if the training target is women's weight loss, the preset type users are the virtual users corresponding to the female weight loss user group. The user characteristics and historical training data of the group (which can be the two lessons with the most training) are used to determine the user characteristics and historical training data of the virtual users.
[0039] Correspondingly, the output data in the sample data used to train the first target model also includes two parts. One part is a list of fitness courses that real users have completed, specifically a list of fitness courses that users have continuously trained within a preset time period in the past. The other part is a list of fitness courses determined based on the relationships between courses in the fitness course graph database. Specifically, courses can be randomly selected from the fitness course graph database, and a random walk can be performed on the relationships between the courses to obtain the sequence as the fitness course list.
[0040] Through the embodiments of this application, a preset model is trained by combining the user characteristics of real users, past short-term training data, and a list of completed fitness courses, as well as the user characteristics of preset types of users, past short-term training data, and a list of fitness courses obtained from a graph database, to obtain a first target model. By inputting the user's characteristics and recent training data into the first target model, a fitness course sequence for a preset time period in the future can be output, thus achieving the purpose of predicting a long-term fitness course list in the future using past short-term training data.
[0041] Optionally, in the method for determining fitness courses provided in this application embodiment, determining the list of fitness courses for a preset type of user within a preset time period based on a fitness course graph database includes: determining a starting node in the fitness course graph database according to a set training goal, wherein the fitness course graph database consists of multiple nodes, each node representing a fitness course, and the connecting edges between the nodes representing the association relationship between the fitness courses; determining the nodes after the starting node in sequence according to the connection relationship between the nodes in the fitness course graph database, thereby obtaining multiple nodes containing sequential relationships; and constructing the list of fitness courses for a preset type of user within a preset time period by the fitness courses corresponding to the multiple nodes containing sequential relationships.
[0042] Specifically, the fitness course graph database is created by abstracting training combinations between body parts based on knowledge from the sports domain and storing them in a graph database. For example, if knowledge from the sports domain suggests that training the glutes and legs should be performed alternately to improve training effectiveness, then connections are established between nodes corresponding to glutes courses and nodes corresponding to legs courses in the graph database.
[0043] Furthermore, the nodes in the obtained fitness course graph database are fitness courses, and the edges between the nodes are the relationships between the fitness courses. By performing a random walk starting from a node, a sequence of nodes is obtained, and the fitness courses corresponding to the node sequence constitute a fitness course list.
[0044] To ensure that the fitness course list within the predicted time period is favored by users, optionally, in the fitness course determination method provided in this application embodiment, after inputting the target user's training goals, user characteristics, and historical training data into the first target model for processing to obtain the fitness course list within the predicted time period, the method further includes: matching each fitness course in the fitness course list within the predicted time period with fitness courses in a target fitness course database to obtain a fitness course matched for each fitness course, wherein the target fitness course database is a database composed of fitness courses preferred by the target user; and replacing each corresponding fitness course in the fitness course list within the predicted time period with the matched fitness courses to obtain a target fitness course list preferred by the target user.
[0045] Specifically, multiple fitness courses preferred by the target user can be determined based on the user characteristics and historical training data of the target user. The preferred fitness courses form a target fitness course database. After obtaining the list of fitness courses for the predicted time period, each course in the fitness course list is replaced with the fitness courses preferred by the target user, thereby obtaining the target fitness course list preferred by the target user.
[0046] The fitness courses preferred by the target user can be predicted by a pre-trained model. Optionally, in the method for determining fitness courses provided in this application embodiment, before matching each fitness course in the fitness course list within the prediction time period with fitness courses in the target fitness course database to obtain the fitness course matched by each fitness course, the method further includes: obtaining a preset number of fitness courses from the fitness course database based on the user characteristics of the target user; inputting the user characteristics of the target user and the course characteristics of the fitness courses in the preset number of fitness courses into a second target model for processing to obtain the target user's preference score for the fitness courses in the preset number of fitness courses, wherein the second target model is trained by multiple sets of sample data, each set of sample data including course characteristics, user characteristics, and user preference tags for fitness courses; determining the fitness courses preferred by the target user from the preset number of fitness courses based on the preference scores, and constructing the target fitness course database from the fitness courses preferred by the target user.
[0047] In one optional implementation, the fitness course database contains 5,000 fitness courses. First, 500 courses are extracted from the 5,000 fitness courses based on the user characteristics of the target user. Then, the preference scores of these 500 courses are determined by a second target model, and the 50 fitness courses with the highest preference scores are selected as the fitness courses preferred by the target user, thus forming the target fitness course database. This lays the data foundation for determining the list of fitness courses preferred by the user.
[0048] Figure 2 This is a flowchart illustrating an optional method for determining a fitness course according to an embodiment of this application. Figure 2 As shown, the method includes:
[0049] The sequence model was trained offline using multiple sample data sets and stored in a database. The multiple sample data sets included two categories: one category included user characteristics, sequence characteristics (training objectives, historical training data), and course sequences of real users; the other category included preset training objectives, user characteristics of the user group corresponding to the preset training objectives, historical training data, and course sequences determined by a graph database. It should be noted that the graph database was determined by knowledge in the field of sports and health.
[0050] Furthermore, when it is necessary to predict the course schedule corresponding to the target user, an offline trained sequence model is obtained from the database, and the user characteristics and training characteristics data of the target user are input into the sequence model. The core prediction is performed through the sequence model to obtain the course schedule for the preset time period.
[0051] Furthermore, to ensure that the course arrangement for the preset time period is liked by users, each course in the course arrangement can be replaced with courses from the target user's preferred course list, thereby obtaining the course arrangement preferred by the target user. Specifically, multiple fitness courses preferred by the target user can be determined based on the user characteristics and historical training data, and the preferred fitness courses can be used to form a preferred course list.
[0052] Through the embodiments of this application, knowledge in the field of sports is integrated into a graph database, and a course sequence is generated based on the graph database. A sequence model is used to combine the course list generated by the graph database with the course list completed by the user. The sequence model predicts the course arrangement for a future preset time period, and replaces the courses in the course arrangement with courses from the user's favorite course list to obtain the user's preferred course arrangement. This course arrangement takes into account both human sports and health knowledge and user preferences, which can ensure the user's training effect.
[0053] It should be noted that the steps shown in the flowchart in the accompanying drawings can be executed in a computer system such as a set of computer-executable instructions, and although a logical order is shown in the flowchart, in some cases the steps shown or described may be executed in a different order than that shown here.
[0054] This application also provides a device for determining fitness courses. It should be noted that this device can be used to execute the method for determining fitness courses provided in this application. The following describes the device for determining fitness courses provided in this application.
[0055] Figure 3 This is a schematic diagram of a fitness course determination device according to an embodiment of this application. Figure 3 As shown, the device includes a determining unit 10 and a processing unit 20.
[0056] Specifically, the determining unit 10 is used to determine the training objective of the target user and to obtain the user characteristics and historical training data of the target user.
[0057] Processing unit 20 is used to input the training objectives, user characteristics, and historical training data of the target user into the first target model for processing, and obtain a list of fitness courses within the predicted time period. The first target model is trained by multiple sets of sample data. Each set of sample data includes user characteristics, training objectives, historical training data, and a list of fitness courses within a preset time period. The predicted time period and the preset time period are of equal length. The user samples include real users and preset type users. The user characteristics and historical training characteristics of the preset type users are determined by the characteristics of the user group corresponding to the preset training objectives. The list of fitness courses within the preset time period for the preset type users is determined by the fitness courses in the fitness course graph database.
[0058] Optionally, in the fitness course determination device provided in the embodiments of this application, the first target model is a sequence model including an encoding end and a decoding end, and the processing unit 20 includes: an encoding module, used to input the user characteristics of the target user, the training target and historical training data into the encoding end of the first target model to obtain an encoding vector; and a decoding module, used to input the encoding vector into the decoding end of the first target model for decoding to obtain a list of fitness courses within the predicted time period.
[0059] The fitness course determination device provided in this application embodiment includes a determination unit 10 for determining the training goals of a target user and acquiring the user characteristics and historical training data of the target user; and a processing unit 20 for inputting the target user's training goals, user characteristics, and historical training data into a first target model for processing to obtain a list of fitness courses within a predicted time period. The first target model is trained using multiple sets of sample data. Each set of sample data includes the user characteristics, training goals, historical training data, and a list of fitness courses within a preset time period for the user sample. The predicted time period and the preset time period are of equal length. The user sample includes real users and preset type users. The user characteristics and historical training characteristics of the preset type users are determined by the characteristics of the user group corresponding to the preset training goals. The list of fitness courses within the preset time period for the preset type users is determined by fitness courses in a fitness course graph database. This solves the problem in related technologies where fitness courses determined based on users' historical training behavior cannot guarantee scientific and reasonable exercise effects. By training the first target model with the characteristics of real users and preset type users, and processing the target user's characteristics through the first target model, a list of fitness courses within the predicted time period is obtained, thereby achieving the effect that the arranged fitness courses can guarantee scientific and reasonable exercise effects.
[0060] The fitness course determination device includes a processor and a memory. The determination unit 10 and the processing unit 20 are stored in the memory as program units, and the processor executes the program units stored in the memory to realize the corresponding functions.
[0061] The processor contains a kernel, which retrieves the corresponding program units from memory. One or more kernels can be configured, and adjusting kernel parameters can address the problem in related technologies where fitness courses determined based on a user's historical training behavior struggle to guarantee scientifically sound exercise results.
[0062] The memory may include non-permanent memory in computer-readable media, such as random access memory (RAM) and / or non-volatile memory, such as read-only memory (ROM) or flash RAM, and the memory includes at least one memory chip.
[0063] This application also provides a non-volatile storage medium, which includes a stored program, wherein the program, when running, controls the device where the non-volatile storage medium is located to execute a method for determining a fitness course.
[0064] This application also provides an electronic device comprising a processor and a memory; the memory stores computer-readable instructions, and the processor executes the computer-readable instructions, wherein the computer-readable instructions, when executed, perform a method for determining a fitness course. The electronic device described herein may be a server, PC, PAD, mobile phone, etc.
[0065] Those skilled in the art will understand that embodiments of this application can be provided as methods, systems, or computer program products. Therefore, this application can take the form of a completely hardware embodiment, a completely software embodiment, or an embodiment combining software and hardware aspects. Furthermore, this application can take the form of a computer program product embodied on one or more computer-usable storage media (including but not limited to disk storage, CD-ROM, optical storage, etc.) containing computer-usable program code.
[0066] This application is described with reference to flowchart illustrations and / or block diagrams of methods, apparatus (systems), and computer program products according to embodiments of this application. It will be understood that each block of the flowchart illustrations and / or block diagrams, and combinations of blocks in the flowchart illustrations and / or block diagrams, can be implemented by computer program instructions. These computer program instructions can be provided to a processor of a general-purpose computer, special-purpose computer, embedded processor, or other programmable data processing apparatus to produce a machine, such that the instructions, which execute via the processor of the computer or other programmable data processing apparatus, generate instructions for implementing the flowchart... Figure 1 One or more processes and / or boxes Figure 1 A device that provides the functions specified in one or more boxes.
[0067] These computer program instructions may also be stored in a computer-readable storage medium that can direct a computer or other programmable data processing device to function in a particular manner, such that the instructions stored in the computer-readable storage medium produce an article of manufacture including instruction means, which are implemented in a process Figure 1 One or more processes and / or boxes Figure 1 The function specified in one or more boxes.
[0068] These computer program instructions may also be loaded onto a computer or other programmable data processing equipment to cause a series of operational steps to be performed on the computer or other programmable equipment to produce a computer-implemented process, thereby providing instructions that execute on the computer or other programmable equipment for implementing the process. Figure 1 One or more processes and / or boxes Figure 1 The steps of the function specified in one or more boxes.
[0069] In a typical configuration, a computing device includes one or more processors (CPU), input / output interfaces, network interfaces, and memory.
[0070] Memory may include non-persistent memory in computer-readable media, such as random access memory (RAM) and / or non-volatile memory, such as read-only memory (ROM) or flash RAM. Memory is an example of computer-readable media.
[0071] Computer-readable media includes both permanent and non-permanent, removable and non-removable media that can store information using any method or technology. Information can be computer-readable instructions, data structures, modules of programs, or other data. Examples of computer storage media include, but are not limited to, phase-change memory (PRAM), static random access memory (SRAM), dynamic random access memory (DRAM), other types of random access memory (RAM), read-only memory (ROM), electrically erasable programmable read-only memory (EEPROM), flash memory or other memory technologies, CD-ROM, digital versatile optical disc (DVD) or other optical storage, magnetic tape, magnetic magnetic disk storage or other magnetic storage devices, or any other non-transferable medium that can be used to store information accessible by a computing device. As defined herein, computer-readable media does not include transient computer-readable media, such as modulated data signals and carrier waves.
[0072] It should also be noted that the terms "comprising," "including," or any other variations thereof are intended to cover non-exclusive inclusion, such that a process, method, article, or apparatus that comprises a list of elements includes not only those elements but also other elements not expressly listed, or elements inherent to such process, method, article, or apparatus. Unless otherwise specified, an element defined by the phrase "comprising one..." does not exclude the presence of other identical elements in the process, method, article, or apparatus that includes that element.
[0073] Those skilled in the art will understand that embodiments of this application can be provided as methods, systems, or computer program products. Therefore, this application can take the form of a completely hardware embodiment, a completely software embodiment, or an embodiment combining software and hardware aspects. Furthermore, this application can take the form of a computer program product embodied on one or more computer-usable storage media (including, but not limited to, disk storage, CD-ROM, optical storage, etc.) containing computer-usable program code.
[0074] The above are merely embodiments of this application and are not intended to limit the scope of this application. Various modifications and variations can be made to this application by those skilled in the art. Any modifications, equivalent substitutions, improvements, etc., made within the spirit and principles of this application should be included within the scope of the claims of this application.
Claims
1. A method of determining a fitness class, characterized by, The method comprises: determining a training goal of a target user, and obtaining user characteristics and historical training data of the target user; inputting the training goal, the user characteristics and the historical training data of the target user into a first target model for processing to obtain a workout course list in a predicted time period, wherein the first target model is trained by a plurality of sets of sample data, each set of sample data comprising user characteristics, training goals, historical training data and a workout course list in a preset time period of a user sample, wherein the length of the predicted time period is equal to the length of the preset time period, the user sample comprises a real user and a preset type user, the user characteristics and historical training characteristics of the preset type user are determined by the characteristics of a user group corresponding to a preset training goal, the workout course list of the preset type user in the preset time period is determined by a workout course in a workout course graph database, and the workout course graph database is obtained by abstracting knowledge in the field of sports into training combinations between body parts and storing the training combinations in a graph database; determining the workout course list of the preset type user in the preset time period from the workout course in the workout course graph database comprises: determining a starting node in the workout course graph database according to the preset training goal, wherein the workout course graph database is composed of a plurality of nodes, each node representing a workout course, and the connection edges between the nodes represent the association relationship between the workout courses; determining the nodes after the starting node in sequence according to the connection relationship between the nodes in the workout course graph database to obtain a plurality of nodes with sequence relationship; and constructing the workout course list of the preset type user in the preset time period from the workout courses corresponding to the plurality of nodes with sequence relationship.
2. The method of claim 1, wherein, The first target model is a sequence model comprising an encoding end and a decoding end, and the inputting the training goal, the user characteristics and the historical training data of the target user into the first target model for processing to obtain the workout course list in the predicted time period comprises: inputting the user characteristics, the training goal and the historical training data of the target user into the encoding end of the first target model to obtain an encoding vector; inputting the encoding vector into the decoding end of the first target model for decoding to obtain the workout course list in the predicted time period.
3. The method of claim 1, wherein, Before the inputting the training goal, the user characteristics and the historical training data of the target user into the first target model for processing to obtain the workout course list in the predicted time period, the method further comprises: obtaining the user characteristics, the training goal, the historical training data and the workout course list in the preset time period of a plurality of real users to obtain a plurality of first user sample data; obtaining the user group corresponding to the preset training target, determining the user feature of the preset type user based on the user feature of the user group, determining the historical training data of the preset type user based on the historical training frequency of the user group, and determining the fitness course list of the preset type user in the preset time period based on the fitness course graph database; a plurality of second user sample data are formed by the user features, the training targets, the historical training data, and the fitness course lists in the preset time period of a plurality of different preset type users; the plurality of first user sample data and the plurality of second user sample data form the plurality of sample data, and a preset sequence model is trained according to the plurality of sample data to obtain the first target model.
4. The method of claim 1, wherein, After the training target, the user feature, and the historical training data of the target user are input into the first target model for processing to obtain the fitness course list in the predicted time period, the method further comprises: each fitness course in the fitness course list in the predicted time period is matched with a fitness course in a target fitness course database respectively to obtain a fitness course matched with each fitness course, wherein the target fitness course database is a database formed by the preferred fitness courses of the target user; each fitness course in the fitness course list in the predicted time period is replaced by a matched fitness course respectively to obtain a target fitness course list preferred by the target user.
5. The method of claim 4, wherein, Before each fitness course in the fitness course list in the predicted time period is matched with a fitness course in a target fitness course database respectively to obtain a fitness course matched with each fitness course, the method further comprises: a preset number of fitness courses are obtained from a fitness course database according to the user feature of the target user; the user feature of the target user and the course feature of a fitness course in the preset number of fitness courses are input into a second target model for processing to obtain a preference score of the target user for the fitness course in the preset number of fitness courses, wherein the second target model is trained by a plurality of sample data, and each sample data includes a course feature, a user feature, and a user preference label for a fitness course; the preferred fitness course of the target user is determined from the preset number of fitness courses based on the preference score, and the target fitness course database is formed by the preferred fitness course of the target user.
6. An apparatus for determining a fitness class, characterized in that comprises: a determination unit configured to determine a training target of a target user, and obtain a user feature and historical training data of the target user; a processing unit configured to input the training target, the user feature, and the historical training data of the target user into a first target model for processing to obtain a fitness course list in a predicted time period, The first target model is trained by a plurality of sets of sample data, each set of sample data including user characteristics of a user sample, a training target, historical training data, and a list of fitness courses in a preset time period, wherein the length of the prediction time period is equal to the length of the preset time period, the user sample includes a real user and a preset type user, the user characteristics and the historical training characteristics of the preset type user are determined by the characteristics of a user group corresponding to a preset training target, the list of fitness courses in the preset time period of the preset type user is determined by a fitness course in a fitness course graph database, and the fitness course graph database is obtained by abstracting knowledge in the field of sports into training combinations between body parts and storing the training combinations in a graph database. The determination device is further configured to determine the list of fitness courses in the preset time period of the preset type user from the fitness courses in the fitness course graph database, including: determining a starting node in the fitness course graph database according to the preset training target, wherein the fitness course graph database is composed of a plurality of nodes, each node representing a fitness course, and the connection edges between the nodes represent the association relationship between the fitness courses; determining the nodes after the starting node in sequence according to the connection relationship between the nodes in the fitness course graph database to obtain a plurality of nodes with sequence relationship; and constructing the list of fitness courses in the preset time period of the preset type user from the fitness courses corresponding to the plurality of nodes with sequence relationship.
7. The apparatus of claim 6, wherein, The first target model is a sequence model including an encoding end and a decoding end, and the processing unit includes: An encoding module configured to input the user characteristics of the target user, the training target, and the historical training data into the encoding end of the first target model to obtain an encoding vector; A decoding module configured to input the encoding vector into the decoding end of the first target model for decoding to obtain the list of fitness courses in the prediction time period.
8. A non-volatile storage medium, comprising: The non-volatile storage medium includes a stored program, wherein the program controls the device in which the non-volatile storage medium is located to perform the fitness course determination method of any one of claims 1 to 5 when running.
9. An electronic device, comprising: A processor and a memory are included, and the memory stores computer readable instructions, and the processor is configured to run the computer readable instructions, wherein the computer readable instructions perform the fitness course determination method of any one of claims 1 to 5 when running.
Citation Information
Patent Citations
Training plan generating method, device, equipment and storage medium
CN109935299A
Course recommendation method and device, computer equipment and medium
CN112632385A