A virtual cycling route planning method and system
The method and system for virtual cycling route planning address the lack of individualization in existing platforms by classifying geographical and weather data, using digital twin technology to create personalized routes based on user preferences, enhancing immersion and accuracy.
Patent Information
- Application Number
- CN202411475825.9
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2024-10-22
- Publication Date
- 2025-07-15
- Estimated Expiration
- 2044-10-22
AI Technical Summary
The existing virtual cycling platforms lack personalized and dynamic adjustment capabilities, and cannot fully consider weather changes and user preferences, resulting in the recommended cycling routes not meeting user needs.
By obtaining geographical and weather data of the target area for classification operations, combining digital twin technology to establish a virtual scene, and establishing a cycling route division model based on user preferences to generate a personalized virtual cycling route.
It improves the personalization and accuracy of virtual cycling route planning, enhances the realism and immersion of virtual scenes, and meets the needs of different users for cycling distance, difficulty and scenery levels.
Smart Images

Figure CN119514823B_ABST
Abstract
Description
Technical Field
[0001] The present invention relates to the technical field of virtual cycling route planning, and particularly to a virtual cycling route planning method and system. Background Art
[0002] With the development of virtual reality (VR) technology and digital twin technology, people have started to attempt to move the real-world cycling experience into a virtual environment. Most existing virtual cycling platforms rely on fixed datasets and preset routes, lacking the ability of personalization and dynamic adjustment. Users often can only choose from a limited number of routes, and the design of these routes usually fails to fully consider the influence of factors such as weather changes and user preferences. Therefore, it is particularly important to develop a system that can dynamically plan cycling routes according to users' real-time preferences and environmental data.
[0003] In addition, existing solutions are often not detailed enough in aspects such as road classification and scenery evaluation, resulting in the routes recommended to users may not fully meet their expectations. For example, for cycling enthusiasts who like challenges, a road with beautiful scenery but too flat may not meet their needs; while for users who pursue relaxation, a route with average scenery but full of challenges may not be suitable either. Therefore, a more refined classification method is needed to distinguish different types of cycling roads and provide personalized cycling route planning services based on this. Summary of the Invention
[0004] The purpose of this part is to outline some aspects of the embodiments of the present invention and briefly introduce some preferred embodiments. Some simplifications or omissions may be made in this part, as well as in the abstract and title of the present application, to avoid obscuring the purpose of this part, the abstract, and the title, and such simplifications or omissions cannot be used to limit the scope of the present invention.
[0005] In view of the above existing problems, the present invention is proposed.
[0006] Therefore, the present invention provides a virtual cycling route planning method and system, which can solve the problems mentioned in the background art.
[0007] To solve the above technical problems, the present invention provides the following technical solutions:
[0008] In the first aspect, the present invention provides a virtual cycling route planning method, including:
[0009] Obtaining first geographical data and first weather data within a target area;
[0010] Performing a first classification operation on the first geographical data and the first weather data within the target area;
[0011] Create a virtual scene corresponding to the first classification result by combining the first geographical data and the first weather data after the first classification operation with digital twins;
[0012] Establish a first cycling route division model;
[0013] Obtain the real-time user preferences and complete the virtual cycling route planning according to the first cycling route division model.
[0014] As a preferred solution of the virtual cycling route planning method described in the present invention, wherein: the first classification operation includes:
[0015] The first classification operation includes a first reclassification and a second reclassification;
[0016] The first reclassification is a road difficulty classification, and the first reclassification includes at least four types of road difficulty levels; the second reclassification is a road scenery classification, and the second reclassification includes at least three types of road scenery levels; the second reclassification is based on the result after the first reclassification.
[0017] As a preferred solution of the virtual cycling route planning method described in the present invention, wherein: the first cycling route division model includes:
[0018] The output of the first cycling route division model is a cycling route, which is a combination of the virtual scenes corresponding to the first classification result. The input of the first cycling route division model is user preferences, which include the target cycling route distance, difficulty level, and scenery level.
[0019] As a preferred solution of the virtual cycling route planning method described in the present invention, wherein: the establishment of the first cycling route division model further includes:
[0020] Obtain the virtual scenes corresponding to the first classification result, perform a second classification on the virtual scenes to obtain several virtual scenes, and use the combination of the corresponding virtual scenes as the output of the first cycling route division model;
[0021] The input of the first cycling route division model is user preferences, which include the target cycling route distance, difficulty level, and scenery level. The difficulty level and scenery level are the classification level results after the first classification operation;
[0022] The distance of the target cycling route is a distance parameter set by the user himself.
[0023] As a preferred solution of the virtual cycling route planning method described in the present invention, wherein: the establishment of the first cycling route division model further includes:
[0024] The acquisition of the training samples of the first cycling route division model includes setting a judgment threshold for the distance of the target cycling route, and the judgment threshold includes a first threshold and a second threshold;
[0025] When the distance parameter set by the user is less than the first threshold, the output of the first cycling route division model is a single virtual scene in the first classification result;
[0026] The first threshold is the length of the route within the target area under the difficulty classification corresponding to the difficulty level selected by the user;
[0027] When the distance parameter set by the user is greater than the first threshold and less than the second threshold, the output of the first cycling route division model is a combination of several virtual scenes in the first classification result. If the difficulty level selected by the user is the third-level difficulty or the fourth-level difficulty, the output of the first cycling route division model is a combination of three virtual scenes in the first classification result, and one of the three virtual scenes must be the virtual scene corresponding to the first-level difficulty under the same scenery level selected by the user;
[0028] If the difficulty level selected by the user is the first-level difficulty or the second-level difficulty, the output of the first cycling route division model is a combination of two virtual scenes in the first classification result, and at least one of the two virtual scenes is the virtual scene corresponding to the second-level difficulty under the same scenery level selected by the user;
[0029] The second threshold is half of the sum of the lengths of the routes within the target area under the difficulty classifications corresponding to all difficulty levels;
[0030] When the distance parameter set by the user is greater than the second threshold, the output of the first cycling route division model is a combination of several virtual scenes in the first classification result. If the difficulty level selected by the user is the third-level difficulty or the fourth-level difficulty, the output of the first cycling route division model is a combination of at least five virtual scenes in the first classification result, and one of the virtual scenes must be the virtual scene corresponding to the fourth-level difficulty under the same scenery level selected by the user;
[0031] If the difficulty level selected by the user is the first-level difficulty or the second-level difficulty, the output of the first cycling route division model is a combination of four virtual scenes in the first classification result, and at least two of the four virtual scenes are the virtual scenes corresponding to the second-level difficulty under the same scenery level selected by the user.
[0032] As a preferred solution of the virtual cycling route planning method described in the present invention, it further includes:
[0033] The difficulty levels include level one difficulty, level two difficulty, level three difficulty, and level four difficulty, corresponding to the first road difficulty classification, the second road difficulty classification, the third road difficulty classification, and the fourth road difficulty classification in the difficulty classification respectively;
[0034] The scenic levels include first-level scenery, second-level scenery, and third-level scenery, corresponding to the first road scenery classification, the second road scenery classification, and the third road scenery classification in the scenery classification respectively.
[0035] As a preferred solution of the virtual cycling route planning method described in the present invention, wherein: the training samples of the first cycling route division model further include:
[0036] If the user preference only includes the distance of the target cycling route, several combinations of virtual scenes are randomly generated as the cycling route.
[0037] In a second aspect, the present invention provides a virtual cycling route planning system, including:
[0038] A data acquisition module, configured to acquire first geographical data and first weather data within a target area;
[0039] A data processing module, configured to perform a first classification operation on the first geographical data and the first weather data within the target area;
[0040] A scene establishment module, configured to establish a virtual scene corresponding to the first classification result by combining digital twins with the first geographical data and the first weather data after the first classification operation;
[0041] A model establishment module, configured to establish a first cycling route division model;
[0042] A planning module, configured to acquire real-time user preferences and complete virtual cycling route planning according to the first cycling route division model.
[0043] In a third aspect, the present invention provides a computer device, including a memory and a processor, where the memory stores a computer program, and when the processor executes the computer program, the steps of the method described above are implemented.
[0044] In a fourth aspect, the present invention provides a computer-readable storage medium, on which a computer program is stored, and when the computer program is executed by a processor, the steps of the method described above are implemented.
[0045] Compared with the prior art, the beneficial effects of the present invention are as follows: The present invention provides a virtual cycling route planning method and system, which acquires first geographical data and first weather data within a target area; performs a first classification operation on the first geographical data and the first weather data within the target area; combines digital twins to establish a virtual scene corresponding to the first classification result for the first geographical data and the first weather data after the first classification operation; establishes a first cycling route division model; acquires real-time user preferences, and completes virtual cycling route planning according to the first cycling route division model. This improves the personalization and accuracy of virtual cycling route planning, and can provide customized cycling routes according to the actual needs and preferences of users. By introducing the classification operation of geographical data and weather data, the realism and immersion of the virtual scene are enhanced, enabling users to obtain a more realistic experience during virtual cycling. The generation algorithm of the virtual cycling route is optimized, making the route planning more scientific and reasonable, and meeting the needs of different users for cycling distance, difficulty, and scenery level. BRIEF DESCRIPTION OF THE DRAWINGS
[0046] In order to more clearly illustrate the technical solutions of the embodiments of the present invention, the following will briefly introduce the drawings required for the description of the embodiments. Obviously, the following drawings are only some embodiments of the present invention. For those of ordinary skill in the art, without creative efforts, other drawings can be obtained based on these drawings. Among them:
[0047] Figure 1 It is a flowchart of a method for a virtual cycling route planning method and system provided by an embodiment of the present invention;
[0048] Figure 2 It is an internal structure diagram of a computer device for a virtual cycling route planning method and system provided by an embodiment of the present invention. DETAILED DESCRIPTION OF THE EMBODIMENTS
[0049] In order to make the above objects, features, and advantages of the present invention more obvious and understandable, the following will give a detailed description of the specific embodiments of the present invention with reference to the accompanying drawings of the specification. Obviously, the described embodiments are some embodiments of the present invention, rather than all embodiments. Based on the embodiments of the present invention, all other embodiments obtained by those of ordinary skill in the art without creative efforts shall fall within the scope of protection of the present invention.
[0050] Embodiment 1
[0051] Refer to Figure 1 - Figure 2 , which is the first embodiment of the present invention. This embodiment provides a virtual cycling route planning method and system, including:
[0052] Before introducing the embodiments of the present application in detail, for clarity, some related concepts are first explained.
[0053] Virtual cycling: Virtual cycling refers to the process of simulating a real cycling experience with the help of Virtual Reality (VR) technology. Users can wear a VR headset or other display devices and cooperate with a spinning bike or similar equipment to enjoy the fun of cycling in a virtual environment. This method is not restricted by weather, time, or location, allowing for exercise anytime and anywhere. At the same time, it can also provide a rich visual experience and interactivity.
[0054] Virtual cycling route: A virtual cycling route is a pre-designed cycling path in virtual cycling. This path can be presented in a virtual environment, including different landscapes, terrain changes, etc. The virtual cycling route can be customized according to user needs, such as choosing different difficulty levels, landscape types, etc. The purpose of designing this route is to provide users with a virtual experience as close as possible to the real cycling feeling.
[0055] Virtual cycling route planning: Virtual cycling route planning refers to the process of automatically or semi-automatically designing a virtual cycling route based on user requirements and preferences through algorithms and technical means. During the planning process, various factors are considered, such as cycling distance, road difficulty, landscape level, etc., to generate the most suitable virtual cycling path for users.
[0056] Digital twin: A digital twin refers to the digital mapping of a physical entity or system. It creates a virtual copy of a physical object through data collected by sensors to simulate its behavior and performance. In the application of virtual cycling route planning, a digital twin can be used to simulate a real cycling environment, including details such as weather and road conditions, thereby making the virtual cycling experience more realistic. Digital twin technology helps to improve the realism of virtual cycling routes and user experience.
[0057] In the existing related technologies, there are some technical defects. For example, the personalization and accuracy of virtual cycling routes are insufficient, and the diverse needs of users for cycling experiences cannot be fully met.
[0058] The present application provides a method that can effectively solve the above-mentioned problems. Next, multiple embodiments will be combined to elaborate in detail on how to implement this virtual cycling route planning method;
[0059] Figure 1 The method flow chart of a virtual cycling route planning method and system is shown, including:
[0060] S101, obtaining first geographical data and first weather data within a target area;
[0061] In an alternative embodiment, the target area is a historical area obtained using GIS (Geographic Information System), or can be a randomly selected area location, or can be a target area selected by the user himself, etc.
[0062] In the embodiment of the present application, regardless of the selection method of the target area, the size of the final target area is limited within a fixed range. If it is larger than this fixed range, the time or resources required for the overall process of planning the cycling route or the training process of the first cycling route division model will become uneconomical. This fixed range can be a circular area range, a square area range, or any irregular area range, but the area of the fixed range should be limited, for example, within 5 square kilometers.
[0063] In an alternative embodiment, the first geographical data and the first weather data may include geographical information such as terrain features, road types, traffic conditions, vegetation coverage, etc., and weather information such as temperature, humidity, wind speed, precipitation, etc. These data can be sourced from public geographical information system databases, meteorological station records, satellite remote sensing data, etc.
[0064] It should be noted that the advantage of step S101 is that it can provide detailed geographical and weather background information for virtual cycling route planning. By obtaining these data, it can be ensured that the planned route is not only visually appealing but also as close as possible to simulating real-world cycling conditions in terms of the cycling experience.
[0065] S102, perform a first classification operation on the first geographical data and the first weather data in the target area;
[0066] In the embodiment of the present application, the first classification operation includes:
[0067] The first classification operation includes a first-level classification and a second-level classification;
[0068] The first-level classification is a road difficulty classification, and the first-level classification includes at least four types of road difficulty levels; the second-level classification is a road scenery classification, and the second-level classification includes at least three types of road scenery levels; the second-level classification is based on the result of the first-level classification.
[0069] In the embodiment of the present application, four types of road difficulty levels and three types of road scenery levels are selected, specifically including the first road difficulty classification, the second road difficulty classification, the third road difficulty classification, and the fourth road difficulty classification, the first road scenery classification, the second road scenery classification, and the third road scenery classification.
[0070] In the embodiments of the present application, the first road difficulty classification is a straight road or a curved road on a flat road surface, the second road difficulty classification is a downhill road, the third road difficulty classification is an uphill road, the fourth road difficulty classification is a rough road or a narrow road, the first road scenery classification is sunny, the second road scenery classification is rainy, and the third road scenery classification is snowy.
[0071] In an alternative embodiment, different technicians can select different road surfaces as different classification criteria, and can also adopt more than four classifications, and can also perform more detailed scenery classifications. For example, scenery classifications such as green vegetation, urban landscape, desert landscape, or mountain landscape can be carried out, and more types of scenery classifications can also be selected. The present application is not limited to three scenery classification means.
[0072] It should be noted that structuring the first geographical data and the first weather data in the classified target area helps to improve the efficiency and accuracy of virtual cycling route planning. By classifying the data, it is easier to identify and select routes suitable for different cycling needs. For example, for cyclists who pursue challenges, they can choose routes that include uphill and rough roads; while for cyclists who hope to enjoy the scenery, they can choose routes with beautiful scenery on sunny or rainy days. In addition, the classification operation can also provide clear input parameters for subsequent route planning algorithms, thereby generating a more personalized and diverse cycling experience.
[0073] S103, establish a virtual scene corresponding to the first classification result by combining digital twins with the first geographical data and the first weather data after the first classification operation;
[0074] It should be noted that by combining digital twin technology, a virtual scene corresponding to the target area in the real world can be created. This virtual scene not only includes geographical information such as terrain, roads, and vegetation, but also can simulate weather conditions such as temperature, humidity, wind speed, and precipitation. Through digital twin technology, the virtual scene can reflect the real-time state of the target area in real time, providing a dynamically changing cycling environment for users.
[0075] In the virtual scene, users can experience visual and sensory effects similar to real cycling. For example, when the simulated weather is rainy, the roads in the virtual scene will appear slippery, the vegetation will look greener, and at the same time, users can also feel the raindrops falling on the helmet and clothes. This highly realistic experience makes virtual cycling not just a simple sports simulation, but an all-round sensory enjoyment.
[0076] In addition, digital twin technology can also be used to test and optimize cycling routes. During the planning phase, digital twin scenarios can be utilized to simulate different cycling conditions and evaluate the safety and comfort of the routes. In this way, potential problems can be identified and corrected in advance to ensure that the final cycling route is both safe and challenging, meeting the needs of different cyclists.
[0077] In the embodiments of the present application,
[0078] Data preparation: Obtain the classified geographical data G and weather data W from the classification operation. The geographical data G includes information such as road types and terrain features, while the weather data W includes information such as temperature and humidity.
[0079] Digital twin mapping: Use digital twin technology to map the classified geographical data G and weather data W into a virtual environment. This process involves converting real-world geographical features into parameters in the virtual environment. For example, for a road classified as "uphill", it can be represented as an inclined plane with a specific slope θ in the virtual environment; for "rainy" weather, it can be represented as a precipitation rate R and humidity H in the virtual environment.
[0080] Virtual scene construction: Based on the mapping results, construct a specific virtual scene S. This step includes setting specific parameters in the virtual environment. For example, if the classification result indicates an uphill road, set the slope parameter θ in the virtual scene, and set weather parameters such as rainfall rate R and humidity H according to the weather classification. Specifically, the virtual scene S can be defined as a set of parameter vectors S = (θ, R, H), where θ represents the inclination angle of the road, R represents the rainfall rate, and H represents the humidity.
[0081] Scene combination: According to user preferences, combine multiple virtual scenes S into a complete virtual cycling route. For example, if the user preferences include a difficulty level N and a scenery level F, multiple virtual scenes with different θ, R, and H parameters can be combined to form a diverse cycling experience.
[0082] Personalized adjustment: Finally, make fine-tuning according to the user's real-time preferences. For example, if the user preferences change, such as from rainy to sunny, then the virtual scene needs to re-adjust its parameters S to adapt to the new preferences.
[0083] In summary, the process of constructing a virtual scene can be summarized as the following steps:
[0084] S = T(G, W)
[0085] Among them, T is a mapping function that converts the classified geographical data G and weather data W into a virtual scene S. In specific implementation, each virtual scene can be represented as a vector containing specific geographical and weather parameters, and then a complete virtual cycling route is formed by combining these vectors.
[0086] In the embodiment of the present application, the virtual scenes are twelve different virtual scenes with different road landscapes under different road difficulties. The twelve different virtual scenes in the present application include straight or curved roads under sunny scenery, straight or curved roads under rainy scenery, straight or curved roads under snowy scenery, downhill roads under sunny scenery, downhill roads under rainy scenery, downhill roads under snowy scenery, uphill roads under sunny scenery, uphill roads under rainy scenery, uphill roads under snowy scenery, rough or narrow roads under sunny scenery, rough or narrow roads under rainy scenery, and rough or narrow roads under snowy scenery. These virtual scenes not only provide rich visual experiences for cyclists but also can simulate the cycling feelings under different weather conditions.
[0087] In an alternative embodiment, the virtual scene that has been generated by digital twin can also be sliced, and the sliced virtual scene is used as a new virtual scene to be planned.
[0088] Exemplarily, when the sliced virtual scene is selected as the output of the first cycling route division model, the flexibility and adaptability of virtual cycling route planning can be further improved. Through the slicing technology, a complex virtual scene can be decomposed into multiple smaller and more manageable segments. Each segment contains specific geographical and weather information and can be planned and adjusted independently. For example, if a cyclist hopes to experience a rough mountain road in the rain, the system can select the virtual scene slices related to rainy days and rough roads, and then combine these slices into a complete cycling route. This slicing method not only makes the route planning more accurate but also can be quickly adjusted according to the cyclist's real-time feedback, thus providing a more personalized and dynamic cycling experience.
[0089] S104, establish a first cycling route division model;
[0090] In the embodiment of the present application, the first cycling route division model includes:
[0091] The output of the first cycling route division model is a cycling route, and the cycling route is a combination of virtual scenes corresponding to the first classification result. The input of the first cycling route division model is user preferences, and the user preferences include the target cycling route distance, difficulty level, and scenery level.
[0092] It should be noted that when the user performs virtual cycling operations and inputs preference information, the system can automatically adjust the difficulty and scenery of the cycling route based on this information. The user can set the distance of the target cycling route, select the difficulty level and scenery level through a preset display screen, so as to achieve a personalized cycling experience. For example, if the user hopes to experience a challenging uphill section, the system will select the corresponding uphill virtual scene according to the difficulty level set by the user, and combine it with the scenery level to plan a cycling route that is both visually attractive and meets the user's physical fitness requirements.
[0093] In the embodiment of the present application, establishing the first cycling route division model further includes:
[0094] Obtain the virtual scenes corresponding to the first classification result, perform a second classification on the virtual scenes to obtain a number of virtual scenes, and use the combination of the corresponding virtual scenes as the output of the first cycling route division model;
[0095] The input of the first cycling route division model is the user preference, and the user preference includes the distance of the target cycling route, the difficulty level and the scenery level. The difficulty level and the scenery level are the classification level results after the first classification operation;
[0096] The distance of the target cycling route is a distance parameter set by the user himself.
[0097] In the embodiment of the present application, performing a second classification on the virtual scenes to obtain a number of virtual scenes is the twelve different virtual scenes mentioned above.
[0098] In an alternative embodiment, performing a second classification on the virtual scenes to obtain a number of virtual scenes can also be the sliced virtual scenes.
[0099] In the embodiment of the present application, establishing the first cycling route division model further includes:
[0100] The acquisition of the training samples of the first cycling route division model includes setting a judgment threshold for the distance of the target cycling route. The judgment threshold includes a first threshold and a second threshold;
[0101] When the distance parameter set by the user himself is less than the first threshold, the output of the first cycling route division model is a single virtual scene in the first classification result;
[0102] The first threshold is the line length within the target area corresponding to the difficulty classification of the difficulty level selected by the user;
[0103] It should be noted that in the training samples of the first cycling route division model, the input is the distance of the target cycling route with a line length of 0 - the first threshold, the difficulty level and the scenery level, and the output is a single virtual scene in the first classification result.
[0104] When the distance parameter set by the user is greater than the first threshold and less than the second threshold, the output of the first cycling route division model is a combination of several virtual scenarios in the first classification result. If the difficulty level selected by the user is level three or level four, the output of the first cycling route division model is a combination of three virtual scenarios in the first classification result, and one of the three virtual scenarios must be the virtual scenario corresponding to level one difficulty under the same scenic level selected by the user;
[0105] If the difficulty level selected by the user is level one or level two, the output of the first cycling route division model is a combination of two virtual scenarios in the first classification result, and at least one of the two virtual scenarios is the virtual scenario corresponding to level two difficulty under the same scenic level selected by the user;
[0106] The second threshold is half of the sum of the lengths of the routes within the target area under the difficulty classifications corresponding to all difficulty levels;
[0107] When the distance parameter set by the user is greater than the second threshold, the output of the first cycling route division model is a combination of several virtual scenarios in the first classification result. If the difficulty level selected by the user is level three or level four, the output of the first cycling route division model is a combination of at least five virtual scenarios in the first classification result, and one of the virtual scenarios must be the virtual scenario corresponding to level four difficulty under the same scenic level selected by the user;
[0108] If the difficulty level selected by the user is level one or level two, the output of the first cycling route division model is a combination of four virtual scenarios in the first classification result, and at least two of the four virtual scenarios are the virtual scenarios corresponding to level two difficulty under the same scenic level selected by the user.
[0109] In the embodiments of the present application, the first cycling route division model is trained through a machine learning algorithm. This model can automatically select and combine virtual scenarios according to the target cycling route distance, difficulty level, and scenic level set by the user to generate a cycling route that meets the user's preferences. During the training process, the model will learn how to predict the most suitable combination of virtual scenarios based on different input parameters to provide the best cycling experience.
[0110] In an alternative embodiment, the first riding route division model can also be modeled in other ways. For example, through an expert system or a rule-based method. An expert system can utilize the knowledge and experience of experts in the riding field to build a model, and determine how to select and combine virtual scenes according to user preferences through a series of rules. For example, the system can include a set of rules that recommend specific virtual scene combinations based on the difficulty and scenery level selected by the user, as well as the current weather conditions. The rule-based method may involve simpler logical judgments. If the user prefers sunny days and selects an uphill section, the system will select one from the uphill virtual scenes on sunny days to build the riding route. Although these methods may not be as flexible and accurate as machine learning models, in some cases, they can provide quick and intuitive solutions.
[0111] In the embodiment of the present application, the specific steps for training the first riding route division model through a machine learning algorithm are as follows:
[0112] First, according to the set judgment threshold, determine the number of virtual scenes corresponding to different target riding route distances;
[0113] Secondly, establish a database or mapping relationship diagram regarding the target riding route distance, difficulty level, scenery level, and the finally selected virtual scene or virtual scene combination;
[0114] Thirdly, establish a machine learning algorithm model network architecture for the present application, and perform model training according to the database or mapping relationship in the above steps;
[0115] Finally, verify the first riding route division model after the training is completed until the first riding route division model meets the design requirements for output.
[0116] In the embodiment of the present application, the machine learning algorithm model network architecture for the present application is as follows:
[0117] Input layer: The input dimension is 3 (target riding route distance, difficulty level, scenery level).
[0118] Batch Normalization layer: Add a batch normalization layer after the input layer to help stabilize the training process and accelerate convergence.
[0119] Hidden layer 1: Contains 64 nodes, uses the ReLU activation function to introduce non-linearity.
[0120] Dropout layer: Add a dropout layer to prevent overfitting, and the drop ratio can be set to 0.5.
[0121] Hidden layer 2: It contains 32 nodes and continues to use the ReLU activation function.
[0122] Residual Connection: After hidden layer 2, add the output of hidden layer 1 to the output of hidden layer 2 to form a residual connection, which helps in the training of deep networks.
[0123] Hidden layer 3: It contains 16 nodes and continues to use the ReLU activation function.
[0124] Output layer: The number of nodes in the output layer is equal to the number of all possible virtual scenarios or scenario combinations. Assuming there are 12 different virtual scenario combinations, the output layer should have 12 nodes. Use the Softmax activation function to output the probability distribution of each scenario combination.
[0125] In the embodiments of this application, the loss function used is:
[0126] L = λ·L CE +(1 - λ)·L Rank
[0127] where L CE is the cross-entropy loss, which measures the difference between the predicted probability distribution and the actual labels. L Rank is the ranking loss, which measures the difference between the predicted order and the actual preferences. λ is a balancing factor used to control the weights between the classification loss and the ranking loss.
[0128] It should be noted that in this application, the loss function of the machine learning algorithm model needs to be specifically designed to fit the specific requirements of virtual cycling route planning. Considering that the task of the model in this application is to generate appropriate virtual scenario combinations based on user preferences (such as the target cycling route distance, difficulty level, and scenery level), therefore, the loss function needs to be able to effectively measure the difference between the virtual scenario combinations predicted by the model and the user's actual preferences. A loss function that fits the content of this application can be a composite loss function that combines the classification loss and the ranking loss. The classification loss is used to ensure that the model correctly classifies the virtual scenario combinations suitable for the user's preferences, while the ranking loss is used to ensure that among multiple possible combinations, the model can correctly arrange the priorities of the combinations according to the user's preference degree.
[0129] In the embodiments of this application, the difficulty levels include the first-level difficulty, the second-level difficulty, the third-level difficulty, and the fourth-level difficulty, corresponding to the first road difficulty classification, the second road difficulty classification, the third road difficulty classification, and the fourth road difficulty classification in the difficulty classification respectively;
[0130] The scenery levels include the first-level scenery, the second-level scenery, and the third-level scenery, corresponding to the first road scenery classification, the second road scenery classification, and the third road scenery classification in the scenery classification respectively.
[0131] In the embodiments of the present application, the training samples of the first cycling route division model further include:
[0132] If the user preference only includes the distance of the target cycling route, several combinations of virtual scenarios are randomly generated as cycling routes.
[0133] In an alternative embodiment, during the generation of the training samples, preference factors that the user may not have explicitly specified, such as weather conditions and time periods, can also be considered to ensure that the model can adapt to various cycling environments. In addition, the training samples will also include the user's feedback data on specific virtual scenarios, and these data will be used to adjust the prediction accuracy of the model. For example, if the user gives negative feedback after selecting a certain virtual scenario, the system will record this information and reduce the probability of recommending this scenario in subsequent training. After the model training is completed, a series of tests will be conducted to verify the performance of the model. The tests include but are not limited to: the recommendation accuracy rate of the model under different user preferences, the adaptability of the model to new user preferences, the performance of the model under different combinations of difficulty levels and scenery grades, etc. Through these tests, it can be ensured that the model can provide high-quality cycling route planning services in practical applications. Finally, the first cycling route division model will be integrated into the virtual cycling route planning system, work in cooperation with the user interface and other system components, and provide a personalized cycling experience for users. The system will continuously optimize the recommendation algorithm based on the user's real-time feedback and historical cycling data in order to achieve the best user experience.
[0134] S105, obtain the real-time user preference and complete the virtual cycling route planning according to the first cycling route division model.
[0135] In an alternative embodiment, the planned virtual cycling route can also be displayed to the user through the user interface, and an interaction function is provided to allow the user to adjust according to personal preferences. The real-time feedback of the user during the virtual cycling process can also be collected, including evaluations of the route difficulty, scenery satisfaction, etc. The parameters of the first cycling route division model can also be dynamically adjusted according to the collected user feedback data to optimize future route recommendations. The system can also be maintained and upgraded regularly to ensure that the virtual cycling route planning system can adapt to changes in user needs and provide a more diverse cycling experience. By analyzing the user's cycling data and feedback, continuous learning and improvement can be carried out in order to reach the highest standard of personalized service and make each virtual cycling of the user full of fun and challenges.
[0136] Exemplarily, assume that the user hopes to experience a challenging uphill section through virtual cycling and also hopes to see beautiful scenery. The total cycling distance set by the user is 20 kilometers, the desired difficulty level is level three (uphill road), and the scenery level is level one (sunny day).
[0137] Furthermore, the user inputs their preferences through the interface of the virtual cycling system, including a 20-kilometer cycling distance, level-three difficulty (uphill road), and level-one scenery (sunny day).
[0138] Furthermore, the system obtains geographical data and weather data from the target area and classifies them. For example, the system classifies uphill roads as level-three difficulty and sunny days as level-one scenery.
[0139] Furthermore, combining digital twin technology, the system constructs a virtual scene according to the user's preferences. In this scene, the system simulates an uphill road under sunny weather conditions, where the user can see the scenery under the sun, feel the warm sunlight, and the fresh air.
[0140] Furthermore, based on the user's preferences and the set distance parameter, the system obtains the output from a pre-trained first cycling route division model. Since the distance set by the user is 20 kilometers, which exceeds the first threshold (15 kilometers) but does not reach the second threshold (30 kilometers), the system outputs a combination of three virtual scenes. These scenes include a flat starting section (straight road, level-one difficulty, sunny day), followed by an uphill section (level-three difficulty, sunny day), and finally ending with a downhill section (level-two difficulty, sunny day).
[0141] Furthermore, during the cycling process, if the user's preferences change, such as wanting to add some scenery variations, the system can immediately adjust the virtual scene. For example, the user may decide to change some sections to rainy days, and the system will then adjust the weather parameters accordingly to display the visual effects and sensory experiences of rainy days.
[0142] Furthermore, the user starts cycling in the simulated environment, experiencing the challenges of the uphill and the beautiful scenery of sunny days. As the cycling progresses, the system continuously adjusts the virtual environment based on the user's real-time feedback and preference changes to ensure that the cycling experience is both challenging and enjoyable.
[0143] In summary, the present invention proposes a virtual cycling route planning method and system, which obtains first geographical data and first weather data within a target area; performs a first classification operation on the first geographical data and the first weather data within the target area; combines digital twins to establish a virtual scene corresponding to the first classification result for the first geographical data and the first weather data after the first classification operation; establishes a first cycling route division model; obtains real-time user preferences, and completes virtual cycling route planning according to the first cycling route division model. This improves the personalization and accuracy of virtual cycling route planning, and can provide customized cycling routes according to the actual needs and preferences of users. By introducing the classification operation of geographical data and weather data, the realism and immersion of the virtual scene are enhanced, enabling users to obtain a more realistic experience in virtual cycling. The generation algorithm of the virtual cycling route is optimized, making the route planning more scientific and reasonable, and meeting the needs of different users for cycling distance, difficulty, and scenery level.
[0144] This embodiment also provides a virtual cycling route planning system, including:
[0145] A data acquisition module, configured to acquire first geographical data and first weather data within a target area;
[0146] A data processing module, configured to perform a first classification operation on the first geographical data and the first weather data within the target area;
[0147] A scene establishment module, configured to combine digital twins to establish a virtual scene corresponding to the first classification result for the first geographical data and the first weather data after the first classification operation;
[0148] A model establishment module, configured to establish a first cycling route division model;
[0149] A planning module, configured to obtain real-time user preferences, and complete virtual cycling route planning according to the first cycling route division model.
[0150] The above-mentioned unit modules can be embedded in the processor of a computer device in hardware form or be independent of it, or can be stored in the memory of the computer device in software form, so as to facilitate the processor to call and execute the operations corresponding to the above-mentioned respective modules.
[0151] This embodiment also provides a computer device, which can be a terminal, and its internal structure diagram can be as Figure 2As shown in the figure. The computer device includes a processor, a memory, a communication interface, a display screen, and an input device connected via a system bus. Among them, the processor of the computer device is used to provide computing and control capabilities. The memory of the computer device includes a non-volatile storage medium and an internal memory. The non-volatile storage medium stores an operating system and computer programs. The internal memory provides an environment for the operation of the operating system and computer programs in the non-volatile storage medium. The communication interface of the computer device is used to communicate with external terminals in a wired or wireless manner, and the wireless manner can be achieved through WIFI, carrier network, NFC (Near Field Communication), or other technologies. When the computer program is executed by the processor, it implements a virtual cycling route planning method. The display screen of the computer device can be a liquid crystal display screen or an electronic ink display screen. The input device of the computer device can be a touch layer covering the display screen, or buttons, trackballs, or touchpads provided on the outer shell of the computer device, or an external keyboard, touchpad, or mouse, etc.
[0152] This embodiment also provides a computer-readable storage medium, on which a computer program is stored. When the computer program is executed by the processor, the following steps are implemented:
[0153] Obtain the first geographical data and the first weather data within the target area;
[0154] Perform a first classification operation on the first geographical data and the first weather data within the target area;
[0155] Combine digital twins to establish a virtual scene corresponding to the first classification result for the first geographical data and the first weather data after the first classification operation;
[0156] Establish a first cycling route division model;
[0157] Obtain the real-time user preferences and complete the virtual cycling route planning according to the first cycling route division model.
[0158] It should be noted that the above embodiments are only used to illustrate the technical solutions of the present invention and not to limit them. Although the present invention has been described in detail with reference to the preferred embodiments, those of ordinary skill in the art should understand that the technical solutions of the present invention can be modified or equivalently replaced without departing from the spirit and scope of the technical solutions of the present invention, and they should all be covered within the scope of the claims of the present invention.
[0159] Those skilled in the art should understand that the embodiments of the present application can be provided as a method, a system, or a computer program product. Therefore, the present application can take the form of a complete hardware embodiment, a complete software embodiment, or an embodiment combining software and hardware aspects. Moreover, the present application can take the form of a computer program product implemented on one or more computer-usable storage media (including but not limited to disk storage, CD-ROM, optical storage, etc.) containing computer-usable program code. The solutions in the embodiments of the present application can be implemented in various computer languages. For example, object-oriented programming languages such as Java and interpreted scripting languages such as JavaScript, etc.
[0160] The present application is described with reference to the flowcharts and / or block diagrams of methods, apparatuses (systems), and computer program products according to the embodiments of the present application. It should be understood that each flow and / or block in the flowchart and / or block diagram, as well as the combination of flows and / or blocks in the flowchart and / or block diagram, can be implemented by computer program instructions. These computer program instructions can be provided to the processor of a general-purpose computer, a special-purpose computer, an embedded processor, or other programmable data processing devices to generate a machine, such that the instructions executed by the processor of the computer or other programmable data processing devices generate means for implementing the functions specified in Figure 1 one flow or multiple flows and / or blocks Figure 1 one block or multiple blocks.
[0161] These computer program instructions can also be stored in a computer-readable memory that can direct a computer or other programmable data processing devices to work in a specific manner, such that the instructions stored in the computer-readable memory generate a manufactured article including instruction means, and the instruction means implement the functions specified in Figure 1 one flow or multiple flows and / or blocks Figure 1 one block or multiple blocks.
[0162] These computer program instructions can also be loaded onto a computer or other programmable data processing devices, such that a series of operation steps are executed on the computer or other programmable devices to generate a computer-implemented process. Thus, the instructions executed on the computer or other programmable devices provide steps for implementing the functions specified in Figure 1 one flow or multiple flows and / or blocks Figure 1 one block or multiple blocks.
[0163] Although the preferred embodiments of the present application have been described, those skilled in the art can make additional changes and modifications once they know the basic creative concepts. Therefore, the appended claims are intended to be construed to include the preferred embodiments as well as all changes and modifications falling within the scope of the present application.
[0164] Obviously, those skilled in the art can make various modifications and variations to this application without departing from the spirit and scope of this application. Thus, if these modifications and variations of this application fall within the scope of the claims of this application and their equivalent technologies, this application is also intended to include these modifications and variations.
Claims
1. A virtual cycling route planning method, characterized in that, Including: Obtain the first geographical data and the first weather data within the target area; Perform a first classification operation on the first geographical data and the first weather data within the target area; Combine digital twins to establish a virtual scene corresponding to the first classification result for the first geographical data and the first weather data after the first classification operation; Establish a first cycling route division model; The establishment of the first cycling route division model further includes: Obtain the virtual scene corresponding to the first classification result, perform a second classification on the virtual scene to obtain several virtual scenes, and use the combination of the corresponding virtual scenes as the output of the first cycling route division model; The input of the first cycling route division model is user preferences, and the user preferences include the distance of the target cycling route, the difficulty level, and the scenery level. The difficulty level and the scenery level are the classification level results after the first classification operation; The distance of the target cycling route is a distance parameter set by the user himself; The establishment of the first cycling route division model further includes: The acquisition of the training samples of the first cycling route division model includes setting judgment thresholds for the distance of the target cycling route. The judgment thresholds include a first threshold and a second threshold; When the distance parameter set by the user himself is less than the first threshold, the output of the first cycling route division model is a single virtual scene in the first classification result; The first threshold is the length of the route within the target area corresponding to the difficulty classification of the difficulty level selected by the user; When the distance parameter set by the user himself is greater than the first threshold and less than the second threshold, the output of the first cycling route division model is a combination of several virtual scenes in the first classification result. If the difficulty level selected by the user is level three difficulty or level four difficulty, the output of the first cycling route division model is a combination of three virtual scenes in the first classification result, and one of the three virtual scenes must be the virtual scene corresponding to the first-level difficulty at the same scenery level selected by the user; If the difficulty level selected by the user is level one difficulty or level two difficulty, the output of the first cycling route division model is a combination of two virtual scenes in the first classification result, and at least one of the two virtual scenes includes the virtual scene corresponding to the second-level difficulty at the same scenery level selected by the user; The second threshold is half of the sum of the lengths of the routes within the target area corresponding to all difficulty levels; When the distance parameter set by the user himself is greater than the second threshold, the output of the first cycling route division model is a combination of several virtual scenes in the first classification result. If the difficulty level selected by the user is level three difficulty or level four difficulty, the output of the first cycling route division model is a combination of at least five virtual scenes in the first classification result, and one of the virtual scenes must be the virtual scene corresponding to the fourth-level difficulty at the same scenery level selected by the user; If the difficulty level selected by the user is the first-level difficulty or the second-level difficulty, the output of the first cycling route division model is a combination of four virtual scenarios in the first classification result, and at least two of the four virtual scenarios are the virtual scenarios corresponding to the second-level difficulty at the same scenic level selected by the user; Obtain the real-time user preferences and complete the virtual cycling route planning according to the first cycling route division model.
2. The virtual cycling route planning method according to claim 1, wherein The first classification operation includes: The first classification operation includes the first reclassification and the second reclassification; The first reclassification is the road difficulty classification, and the first reclassification includes at least four types of road difficulty types; the second reclassification is the road scenery classification, and the second reclassification includes at least three types of road scenery types; the second reclassification is based on the result after the first reclassification.
3. The virtual cycling route planning method according to claim 2, wherein, The first cycling route division model includes: The output of the first cycling route division model is a cycling route, which is a combination of virtual scenarios corresponding to the first classification result. The input of the first cycling route division model is user preferences, and the user preferences include the target cycling route distance, difficulty level, and scenic level.
4. The virtual cycling route planning method according to claim 3, wherein, It also includes: The difficulty level includes the first-level difficulty, the second-level difficulty, the third-level difficulty, and the fourth-level difficulty, corresponding to the first road difficulty classification, the second road difficulty classification, the third road difficulty classification, and the fourth road difficulty classification in the difficulty classification respectively; The scenic level includes the first-level scenery, the second-level scenery, and the third-level scenery, corresponding to the first road scenery classification, the second road scenery classification, and the third road scenery classification in the scenery classification respectively.
5. The virtual cycling route planning method according to claim 4, wherein, The training samples of the first cycling route division model also include: If the user preferences only include the target cycling route distance, randomly generate several combinations of virtual scenarios as the cycling route.
6. A virtual cycling route planning system, applying the method as claimed in claim 1, characterized in that, It includes: A data acquisition module for acquiring the first geographical data and the first weather data in the target area; A data processing module for performing the first classification operation on the first geographical data and the first weather data in the target area; A scene establishment module for establishing virtual scenarios corresponding to the first classification result by combining digital twins with the first geographical data and the first weather data after the first classification operation; A model establishment module for establishing the first cycling route division model; A planning module for obtaining the real-time user preferences and completing the virtual cycling route planning according to the first cycling route division model.
7. A computer device, comprising a memory and a processor, the memory storing a computer program, characterized in that, When the processor executes the computer program, it implements the steps of the method described in any one of claims 1 to 5.
8. A computer-readable storage medium having a computer program stored thereon, characterized in that, When the computer program is executed by the processor, it implements the steps of the method described in any one of claims 1 to 5.
Citation Information
Patent Citations
Riding route generation method and device, equipment and storage medium
CN113688274A