Internet bicycle renting user preference type prediction method, system and device based on order data and storage medium
By building a user preference type prediction database and using multiple Logit (MNL) models, combining HDBSCAN clustering algorithm, identifying the common places of users and analyzing the factors influencing preference types, the problem of how to accurately predict the user preference types of Internet rental bicycles is solved, and the problem of achieving the goal of achieving the Optimize the effect of shared bicycles and electric bicycles.
Patent Information
- Application Number
- CN202411454599.6
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2024-10-17
- Publication Date
- 2025-02-18
- Estimated Expiration
- 2044-10-17
AI Technical Summary
How to accurately predict the preference types of Internet bicycle rental users to optimize the delivery and management of shared bicycles and shared electric bicycles.
By building a user preference type prediction database, using order data, built environment data and electronic fence data, combined with HDBSCAN clustering algorithm and multiple Logit (MNL) models, we can identify the commonly used places of users and analyze the factors influencing preference type, and then predict the user preference type .
Accurate prediction of user preference types is achieved, helping to optimize the delivery strategies of shared bicycles and shared electric motorcycles, improve resource allocation efficiency, and improve user experience.
Smart Images

Figure CN119477491A_ABST
Abstract
Description
Technical Field
[0001] The present invention relates to the technical field of Internet rental user behavior analysis, and in particular to a method, system, device and storage medium for predicting user preference types of Internet rental bicycles based on order data. Background Art
[0002] With the rapid development of the sharing economy, Internet rental bicycles, as a green and environmentally friendly way of travel, provide convenient rental services, enabling users to flexibly travel short distances in the city and meet their daily travel needs without owning a vehicle. Users can easily find nearby shared vehicles through smartphone applications and quickly complete the rental and return process, which greatly improves the convenience and efficiency of urban travel and effectively alleviates urban traffic pressure. However, with the increasing number of shared bicycles and shared electric motorcycles, users show obvious preference differences when choosing shared travel tools. How to accurately predict the user's preference type and then optimize the deployment and management of shared bicycles and shared electric motorcycles has become an important issue in current transportation planning and market operations. Summary of the invention
[0003] In order to solve the problems existing in the prior art, the present invention provides a method, system, device and storage medium for predicting the user preference type of Internet rental bicycles based on order data. The method uses the order data, built environment data and electronic fence data of shared bicycles and shared electric motorcycles to construct a classification prediction model, comprehensively considers the influencing factors of the built environment characteristics and shared infrastructure, explores the behavioral characteristics of users when using shared travel tools, and analyzes and predicts the user's preference type, thereby solving the problems mentioned in the above background technology.
[0004] To achieve the above object, the present invention provides the following technical solution: a method for predicting user preference types of Internet rental bicycles based on order data, comprising the following steps:
[0005] S1. Build a user preference type prediction database, including the order data of the two main vehicle types of Internet rental bicycles, namely shared bicycles and shared electric motorcycles, as well as built environment data and electronic fence data;
[0006] S2. Data preprocessing: Clean the shared bicycle and shared electric motorcycle data in the database of step S1 to remove invalid and abnormal data;
[0007] S3. Identification of the same user in shared riding: Based on the user ID, the travel records of all shared bicycles and shared electric motorcycles with the same ID number are identified. The number of times and days each user uses shared bicycles and shared electric motorcycles are calculated according to the vehicle type and borrowing time, and the frequency distribution of users using shared bicycles and shared electric motorcycles is statistically analyzed;
[0008] S4. Classification of user preference types: Based on the frequency distribution of users using shared bicycles and shared electric motorcycles, users are divided into three categories: shared bicycle dominant type, balanced type, and shared electric motorcycle dominant type;
[0009] S5. Identification of user-frequently used locations: using the HDBSCAN clustering algorithm to identify user-frequently used locations, i.e., locations where users frequently borrow and return vehicles;
[0010] S6. Extraction of factors influencing user preference types: Based on the frequently used places of users identified in step S5, a buffer zone is established to extract the surrounding built environment characteristics, including the number of various POIs in the city, slope, road network density, distances between the frequently used places and the nearest public transportation and the nearest CBD, and shared infrastructure attributes;
[0011] S7. Construction and prediction of user preference type prediction model: Construct a multinomial Logit (MNL) model as a user preference type prediction model and train it. Input the test data and use the trained model to predict the user's preference type, and output the prediction result.
[0012] Preferably, the built environment data in step S1 includes: digital elevation model DEM data, road network data, public transportation data and facility network data; wherein the facility network data includes multiple categories of points of interest POIs such as shopping, leisure and entertainment, and commercial services, including geographical location and facility type information, and is processed through ArcGIS; the electronic fence data includes: fence name, center point address, area, and latitude and longitude coordinates of the center point and area vertices.
[0013] Preferably, in step S2, the following is specifically included:
[0014] S21. Eliminate incomplete records of shared bicycle and shared electric motorcycle order data; wherein a complete order data includes information of user ID, vehicle ID, vehicle type, borrowing date, borrowing time, borrowing longitude, borrowing latitude, return date, return time, return longitude, and return latitude;
[0015] S22. Eliminate the data where the geographical locations of shared bicycles and shared electric motorcycles borrowed and parked deviate from the predicted range;
[0016] S23, eliminating records with a travel duration of less than 1 minute and greater than 2 hours, wherein the travel duration is obtained by subtracting the borrowing time from the return time in the same order;
[0017] S24. Eliminate records in which the travel distance is less than 100 meters, where the travel distance is obtained by calculating the longitude and latitude of the borrowed vehicle and the longitude and latitude of the returned vehicle in the same order.
[0018] Preferably, in step S4, the following is specifically included:
[0019] Calculate the proportion of shared bicycle trips of users. The proportion of shared bicycle trips is obtained by dividing the number of shared bicycle trips by the total number of trips. According to the proportion of shared bicycle trips, users are divided into three types in equal proportion. The specific divisions include:
[0020] The proportion of shared bicycle use is high, that is, users who use shared bicycles for ≥ 2 / 3 of their trips are classified as "shared bicycle dominant";
[0021] The proportion of shared bicycles and shared electric motorcycles is relatively balanced, that is, users with 1 / 3 < 2 / 3 of the shared bicycle trips are classified as "balanced";
[0022] The proportion of shared bicycle usage is relatively low, that is, users whose shared bicycle trips account for ≤1 / 3 are classified as "shared electric motorcycle-dominated".
[0023] Preferably, in step S5, the method of using HDBSCAN clustering to identify the user's frequently used locations specifically includes:
[0024] S51. Input data set: input the longitude and latitude of all shared bike users’ borrowing and returning bikes;
[0025] S52, coordinate system conversion: converting the longitude and latitude of the user's borrowing and returning the vehicle from the geographic coordinate system to the projection coordinate system;
[0026] S53, grouping the user's travel records into different clusters according to the user ID;
[0027] S54, setting parameters: defining the minimum number of sample points (min_cluster_size) required to form a cluster according to the user travel frequency interval;
[0028] S55. Calculate core distance and density estimation: Calculate the core distance of each user's borrowing and returning point, and define the core distance c k (x) = d(x, N k (x)), which is the distance from the current point x to the kth closest point N k (x), the mutual reachable distance d between two points k The expression of (a, b) is:
[0029] d k (a, b) = max{c k (a), c k (b), d(a, b)}
[0030] Among them, d(a, b) is the original distance between points a and b;
[0031] S56. Construct a density adjacency graph: Based on the mutual reachability distance, construct a weighted adjacency graph, where the weight of the edge is the mutual reachability distance between the point pairs;
[0032] S57, Generate minimum spanning tree: The algorithm uses Prim algorithm internally, taking sample points as original points and the mutual reachable distances between other points and the original points as weights to construct the minimum spanning tree;
[0033] S58, Establish cluster hierarchy: The algorithm uses the mutual reachability distance as the weight, traverses and reorders the edges of the minimum spanning tree, and classifies each edge into a new cluster;
[0034] S59, extract stable clusters: extract the most stable cluster as the final result according to the persistence analysis and the min_cluster_size parameter;
[0035] S510, determining frequently used locations: The clustering result may result in more than one cluster, each cluster representing a location where the user frequently borrows and returns a vehicle. The cluster with the largest number of borrowing and returning points, i.e., the most representative cluster, is selected as the frequently used location of the user.
[0036] Preferably, in step S6, the following is specifically included:
[0037] S61, establishing a buffer zone: based on the user's frequently used locations obtained in step S5, using ArcGIS software to establish a buffer zone for extracting influencing factors;
[0038] S62, extracting the number of various POIs: extracting the number of public service facilities, leisure service facilities, commercial service facilities, residential facilities and office facilities in the buffer zone;
[0039] S63, slope: extracting the average slope value within the buffer zone around the user's frequently used area;
[0040] S64, road network density: extract the road length within the buffer zone, and the ratio of the road length to the buffer zone area is the road network density;
[0041] S65. Calculate the nearest distance: Calculate the distance between the frequently used place and the nearest bus stop, subway station and the nearest CBD;
[0042] S66, extracting shared infrastructure attributes: including the supply of vehicles in the buffer zone and the number of electronic fences; the extraction of the supply of vehicles in the buffer zone includes: randomly selecting a typical working day as a representative from the data pre-processed in step S2, calculating the distances between the borrowing point and the return point of all orders on that day and the user's usual place, screening out the order records in the buffer zone and numbering them;
[0043] Then divide the day into several time periods, and count the number of shared bicycles and shared electric motorcycles borrowed in each buffer zone in each time period according to the borrowing time and number;
[0044] For the same buffer zone, the number of borrowed vehicles in the next time period is the number of available vehicles in the previous time period; by calculating the average number of borrowed vehicles in all time periods of the day, the average supply of shared bicycles and shared electric motorcycles can be obtained.
[0045] Preferably, in step S7, the following is specifically included:
[0046] S71, constructing a model: taking the user preference type, i.e., shared bicycle dominant type, balanced type, and shared electric motorcycle dominant type as the dependent variable, and taking the built environment characteristics and shared infrastructure attributes in step S6 as the explanatory variables, a multinomial logit (MNL) model is established;
[0047] S72, training model: determining the relationship between the explanatory variables and the user preference type through learning, and estimating the parameters of the MNL model using the maximum likelihood estimation method;
[0048] S73, model prediction: based on the estimated model parameters, input new built environment characteristics and shared infrastructure attribute data to predict the user's preference type;
[0049] S74. Output prediction results: Calculate the probability that the user belongs to each preference type through the fitted MNL model, and select the preference type with the highest probability as the final prediction result.
[0050] On the other hand, to achieve the above purpose, the present invention also provides the following technical solution: a system for predicting user preference types of Internet rental bicycles based on order data, the system comprising the following modules:
[0051] Database construction module, building a user preference type prediction database, including the order data of the two main vehicle types of Internet rental bicycles, namely shared bicycles and shared electric motorcycles, as well as built environment data and electronic fence data;
[0052] The data preprocessing module cleans the shared bicycle and shared electric motorcycle data in the database and removes invalid and abnormal data;
[0053] The user identification module identifies the travel records of all shared bicycles and shared electric motorcycles under the same ID number based on the user ID, calculates the number of times and days each user uses shared bicycles and shared electric motorcycles according to the vehicle type and borrowing time, and statistically analyzes the frequency distribution of users using shared bicycles and shared electric motorcycles;
[0054] The user preference type classification module divides users into three categories: shared bicycle dominant type, balanced type, and shared motorcycle dominant type according to the frequency distribution of users using shared bicycles and shared electric motorcycles;
[0055] The user's frequently used location identification module uses the HDBSCAN clustering algorithm to identify the user's frequently used locations, i.e. the places where the user frequently borrows and returns the car;
[0056] The influencing factor extraction module establishes a buffer zone based on the user-frequently used sites identified, and extracts the surrounding built environment characteristics, including the number of various POIs in the city, slope, road network density, distance between the frequently used sites and the nearest public transportation and the nearest CBD, and shared infrastructure attributes;
[0057] Prediction model construction and prediction module, build a multi-logit (MNL) model as a user preference type prediction model and train it, input the test data to use the trained model to predict the user's preference type, and output the prediction result.
[0058] On the other hand, to achieve the above-mentioned purpose, the present invention also provides the following technical solution: an electronic device, the electronic device comprising: a processor; and a memory for storing one or more programs;
[0059] When the one or more programs are executed by the processor, the processor executes the method for predicting the user preference type of Internet rental bicycles based on order data.
[0060] On the other hand, to achieve the above-mentioned purpose, the present invention also provides the following technical solution: a computer-readable storage medium having a computer program stored thereon, which, when executed by a processor, implements the method for predicting user preference types of Internet rental bicycles based on order data.
[0061] The beneficial effects of the present invention are:
[0062] 1) The present invention constructs a complete user preference type prediction database, comprehensively considers multi-dimensional data sources, and ensures the accuracy and comprehensiveness of the prediction;
[0063] 2) The present invention uses the HDBSCAN clustering algorithm to identify the locations where users frequently borrow and return cars, and based on this, analyzes the factors affecting the user's preference type;
[0064] 3) The present invention constructs an MNL model to analyze and predict user preference types. The model fully considers the relationship between user behavior characteristics and environmental factors, realizes accurate prediction and effective management of user behavior, and ensures that the delivery strategy is highly consistent with user needs. BRIEF DESCRIPTION OF THE DRAWINGS
[0065] Figure 1 A schematic flow chart of the steps of a method for predicting user preference types of Internet rental bicycles based on order data of the present invention;
[0066] Figure 2 This is a schematic diagram of the HDBSCAN clustering process;
[0067] Figure 3 This is a schematic diagram of a module of a system for predicting user preference types of Internet bicycle rentals based on order data of the present invention;
[0068] Figure 4 This is a schematic diagram of the structure of an electronic device in an embodiment of the present invention;
[0069] In the figure, 110-database construction module; 120-data preprocessing module; 130-user identification module; 140-user preference type classification module; 150-user frequently used place identification module; 160-influence factor extraction module; 170-prediction model construction and prediction module; 210-processor; 220-storage. DETAILED DESCRIPTION
[0070] The following will be combined with the drawings in the embodiments of the present invention to clearly and completely describe the technical solutions in the embodiments of the present invention. Obviously, the described embodiments are only part of the embodiments of the present invention, not all of the embodiments. Based on the embodiments of the present invention, all other embodiments obtained by ordinary technicians in this field without creative work are within the scope of protection of the present invention.
[0071] See also Figure 1 The present invention provides a technical solution: a method for predicting user preference types of Internet rental bicycles based on order data, comprising the following steps:
[0072] S1. Build a user preference type prediction database, including the order data of the two main vehicle types of Internet rental bicycles, namely shared bicycles and shared electric motorcycles, as well as built environment data and electronic fence data.
[0073] The built environment data includes: digital elevation model DEM data, road network data, public transportation data and facility network data; the facility network data includes multiple categories of points of interest POIs such as shopping, leisure and entertainment, and commercial services, which contain information on geographical location and facility types, and are processed through ArcGIS; the electronic fence data includes: fence name, center point address, area, and latitude and longitude coordinates of the center point and area vertices.
[0074] This embodiment operates the present invention in combination with the actual shared bicycle and shared electric motorcycle order data in Kunming. Using the shared bicycle and shared electric motorcycle order data of Kunming for 31 days from April 20 to May 20, 2022, a total of 3.051 million 1,459 items were collected, including 2.701 million 1,280 shared electric motorcycle order data. Covering five main urban areas including Guandu District, Wuhua District, Panlong District, Xishan District and Chenggong District, these areas gather a variety of land use functions such as residential, work areas, schools, large commercial areas, and transportation hubs. The number of shared riding users is large, indicating that the data is representative. Up to now, the area has 125,000 shared bicycles and shared electric motorcycles, and 15,000 non-motor vehicle parking spaces. These measures make shared riding a convenient, environmentally friendly and healthy travel option, which helps to reduce traffic congestion and air pollution, while promoting the sustainable development of the city.
[0075] The shared bike user preference type prediction database includes Kunming’s shared bike and shared electric bike order data, built environment data, and electronic fence data. The built environment data mainly includes road network data, public transportation data, and various types of facility network data. The facility network data comes from the shopping, leisure and entertainment, commercial services, and other multi-category points of interest (POI) of the Amap open map platform, including geographic location, facility type, and other information, and is processed through ArcGIS. The road network data comes from the OSM database, and the road network is corrected using ArcGIS software combined with the prediction range. Public transportation data includes bus stop information. The specific content of the electronic fence data is shown in Table 1. Specifically, the electronic fence data includes: fence name, center point address, area, and latitude and longitude coordinates of the center point and area vertices.
[0076] Table 1 Electronic fence information (partial)
[0077]
[0078]
[0079] S2. Data preprocessing: Clean the shared bicycle and shared electric motorcycle data in the database of step S1 to remove invalid and abnormal data.
[0080] The details include:
[0081] S21. Eliminate incomplete records of shared bicycle and shared electric motorcycle order data; wherein a complete order data includes information of user ID, vehicle ID, vehicle type, borrowing date, borrowing time, borrowing longitude, borrowing latitude, return date, return time, return longitude, and return latitude;
[0082] S22. Eliminate the data where the geographical locations of shared bicycles and shared electric motorcycles borrowed and parked deviate from the predicted range;
[0083] S23, eliminating records with a travel duration of less than 1 minute and greater than 2 hours, wherein the travel duration is obtained by subtracting the borrowing time from the return time in the same order;
[0084] S24. Eliminate records in which the travel distance is less than 100 meters, where the travel distance is obtained by calculating the longitude and latitude of the borrowed vehicle and the longitude and latitude of the returned vehicle in the same order.
[0085] After cleaning the shared bicycle and shared electric motorcycle order data, 2,303,289 records remain, accounting for about 75.48% of the total data. Table 2 shows some examples of shared bicycle and shared electric motorcycle travel records.
[0086] Table 2 Shared bicycle and shared electric motorcycle travel data record table (partial)
[0087]
[0088] Table 2 Shared bicycle and shared electric motorcycle travel data record table (part) (continued)
[0089]
[0090]
[0091] S3. Identification of the same user in shared riding: Based on the user ID, the travel records of all shared bicycles and shared electric motorcycles with the same ID number are identified, and the number of times and days each user uses shared bicycles and shared electric motorcycles are calculated according to the vehicle type and borrowing time. In order to ensure that the users of shared bicycles and shared electric motorcycles are frequent and long-term users, the travel data of users with fewer travel times and travel days are deleted. Statistical analysis of the frequency distribution of users using shared bicycles and shared electric motorcycles.
[0092] In this embodiment, in order to ensure that the users of shared bicycles and shared electric motorcycles are frequent and long-term users, the travel data of users with a total number of rides less than 12 times and a total number of days less than 3 days are deleted. After screening according to the above screening conditions, 8,609 identical users were identified, with a total of 175,16 travel records, of which 114,626 were shared electric motorcycle travel records, accounting for 67.22%.
[0093] S4. Classification of user preference types: Based on the frequency distribution of users using shared bicycles and shared electric motorcycles, users are divided into three categories: shared bicycle-dominated type, balanced type, and shared electric motorcycle-dominated type.
[0094] The details include:
[0095] Calculate the proportion of shared bicycle trips of users. The proportion of shared bicycle trips is obtained by dividing the number of shared bicycle trips by the total number of trips. According to the proportion of shared bicycle trips, users are divided into three types in equal proportion. The specific divisions include:
[0096] The proportion of shared bicycle use is high, that is, users who use shared bicycles for ≥ 2 / 3 of their trips are classified as "shared bicycle dominant";
[0097] The proportion of shared bicycles and shared electric motorcycles is relatively balanced, that is, users with 1 / 3 < 2 / 3 of the shared bicycle trips are classified as "balanced";
[0098] The proportion of shared bicycle usage is relatively low, that is, users whose shared bicycle trips account for ≤1 / 3 are classified as "shared electric motorcycle-dominated".
[0099] In this embodiment, users whose travel times account for the range of (0.66-1.0) are recorded as the shared bicycle dominant type, with a total of 2052 users, accounting for 23.84% of the total users; users whose travel times account for the range of (0.33-0.66) are recorded as the balanced type, with a total of 1449 users, accounting for 16.83% of the total users; users whose travel times account for the range of (0-0.33) are recorded as the shared electric motorcycle dominant type, with a total of 5108 users, accounting for 59.33% of the total users.
[0100] S5. Identification of user-frequently used locations: HDBSCAN clustering algorithm is used to identify user-frequently used locations, i.e., locations where users frequently borrow and return bicycles.
[0101] The HDBSCAN clustering method is used to identify the user's frequently used locations, such as Figure 2 As shown, specifically including:
[0102] S51. Input data set: input the longitude and latitude of all shared bike users’ borrowing and returning bikes;
[0103] S52, coordinate system conversion: converting the longitude and latitude of the user's borrowing and returning the vehicle from the geographic coordinate system to the projection coordinate system;
[0104] S53, grouping the user's travel records into different clusters according to the user ID;
[0105] S54, setting parameters: defining the minimum number of sample points (min_cluster_size) required to form a cluster according to the user travel frequency interval;
[0106] S55. Calculate core distance and density estimation: Calculate the core distance of each user's borrowing and returning point, and define the core distance c k (x) = d(x, N k (x)), which is the distance from the current point x to the kth closest point N k (x), the mutual reachable distance d between two points k The expression of (a, b) is:
[0107] d k (a, b) = max{c k (a), c k (b), d(a, b)}
[0108] Among them, d(a, b) is the original distance between points a and b;
[0109] S56. Construct a density adjacency graph: Based on the mutual reachability distance, construct a weighted adjacency graph, where the weight of the edge is the mutual reachability distance between the point pairs;
[0110] S57, Generate minimum spanning tree: The algorithm uses Prim algorithm internally, taking sample points as original points and the mutual reachable distances between other points and the original points as weights to construct the minimum spanning tree;
[0111] S58, Establish cluster hierarchy: The algorithm uses the mutual reachability distance as the weight, traverses and reorders the edges of the minimum spanning tree, and classifies each edge into a new cluster;
[0112] S59, extract stable clusters: extract the most stable cluster as the final result according to the persistence analysis and the min_cluster_size parameter;
[0113] S510, determining frequently used locations: The clustering result may result in more than one cluster, each cluster representing a location where the user frequently borrows and returns a vehicle. The cluster with the largest number of borrowing and returning points, i.e., the most representative cluster, is selected as the frequently used location of the user.
[0114] Specifically, we divide the travel frequency interval into 6 intervals: less than 24 times, 24 to 48 times, 48 to 96 times, 96 to 192 times, 192 to 384 times, and greater than or equal to 384 times, and the corresponding minimum cluster size values are 3, 4, 6, 8, 10 and 12 respectively.
[0115] S6. Extraction of factors influencing user preference types: Based on the frequently used places identified in step S5, a buffer zone is established to extract the surrounding built environment characteristics, including the number of various POIs in the city, slope, road network density, the distance between the frequently used places and the nearest public transportation and the nearest CBD, and shared infrastructure attributes.
[0116] The details include:
[0117] S61, establishing a buffer zone: based on the user's frequently used areas obtained in step S5, using ArcGIS software to establish a 500-meter buffer zone for extracting influencing factors;
[0118] S62, extracting the number of various POIs: extracting the number of public service facilities, leisure service facilities, commercial service facilities, residential facilities and office facilities in the buffer zone;
[0119] S63, slope: extracting the average slope value within the buffer zone around the user's frequently used area;
[0120] S64, road network density: extract the road length within the buffer zone, and the ratio of the road length to the buffer zone area is the road network density;
[0121] S65. Calculate the nearest distance: Calculate the distance between the frequently used place and the nearest bus stop, subway station and the nearest CBD;
[0122] S66, extracting shared infrastructure attributes: including the supply of vehicles in the buffer zone and the number of electronic fences; the extraction of the supply of vehicles in the buffer zone includes: randomly selecting a typical working day as a representative from the data pre-processed in step S2, calculating the distance between the borrowing point and the return point of all orders from 00:00 to 23:59 on that day and the user's usual place, screening out the order records in the buffer zone and numbering them, such as retaining the order records less than 500 meters and numbering them;
[0123] Then divide the day into several time periods, such as 124 intervals with 10-minute intervals. According to the borrowing time and number, count the number of shared bicycles and shared electric motorcycles borrowed in each buffer zone in each time period;
[0124] For the same buffer zone, the number of vehicles borrowed in the next time period is the number of vehicles available in the previous time period; by calculating the average number of vehicles borrowed in all time periods of the day, the average supply of shared bicycles and shared electric motorcycles is obtained. This allows the impact of vehicle supply on user choice to be analyzed. In addition, the number of electronic fences around commonly used areas is also considered.
[0125] S7. Construction and prediction of user preference type prediction model: Construct a multinomial Logit (MNL) model as a user preference type prediction model and train it. Input the test data and use the trained model to predict the user's preference type, and output the prediction result.
[0126] The details include:
[0127] S71. Build a model: Take the user preference type (bike-sharing dominant, balanced, and electric bike-sharing dominant) as the dependent variable, and the built environment characteristics and shared infrastructure attributes in step S6 as explanatory variables to build a multinomial logit (MNL) model;
[0128] When building the model, "balanced" users were selected as the control group. First, the entire data set was divided, 80% of the data was used as the training set to build the model, and 20% of the data was used as the test set to evaluate the model performance. Next, a multicollinearity test was performed on each explanatory variable in the training set. The results showed that the variance inflation factor (VIF) of all explanatory variables was less than 7.5, indicating that there was no serious multicollinearity problem between the variables and the model analysis could continue.
[0129] S72, training model: determining the relationship between the explanatory variables and the user preference type through learning, and estimating the parameters of the MNL model using the maximum likelihood estimation method;
[0130] On the training set, the model parameters were estimated by the maximum likelihood estimation method. Table 3 shows the final MNL model results. The goodness of fit of the model was evaluated by the pseudo R 2 The indicators were evaluated on the training set, and the results showed that the overall fit of the model was good, and it could effectively capture the relationship between user travel preferences and their influencing factors. In addition, in order to verify the robustness and generalization ability of the model, the model prediction was verified on the training set and the test set, respectively. Table 4 shows the prediction accuracy of the two. The results show that the generalization performance of the model is good and the prediction effect is stable, which further proves the prediction ability of the model on unseen data.
[0131] Table 3 Model results
[0132]
[0133]
[0134] Table 4 Prediction accuracy of training set and test set
[0135]
[0136] S73, Model prediction: According to the estimated model parameters (fitted MNL model parameters), input new built environment characteristics and shared infrastructure attribute data to predict the user's preferred type; among them, the built environment characteristic data is extracted through the urban geographic information system (GIS), covering road network data, public transportation data and various types of facility network data, etc. The data can be obtained from the urban planning department or open GIS platform; for the deployment planning of Internet rental bicycles in new areas, the shared infrastructure attribute data can come from shared travel service providers or government departments, covering information such as the expected total deployment and the planned number of electronic fences. These multi-source data provide a solid data foundation for model prediction, thereby effectively predicting whether users prefer shared bicycles, shared electric motorcycles, or a balanced use of both.
[0137] S74. Output prediction results: Calculate the probability that the user belongs to each preference type through the fitted MNL model, and select the preference type with the highest probability as the final prediction result.
[0138] This prediction method based on multi-source data can help understand user needs more accurately and provide support for subsequent traffic planning and market operation strategies.
[0139] Through the above steps, the method of the present invention has shown strong practicality, accuracy and scalability in predicting the travel preference types of Internet rental bicycle users. This not only helps to gain a deeper understanding of users' travel habits and needs, and helps operators optimize the placement and quantity of shared bicycles and shared electric motorcycles, but also provides scientific decision-making support for urban traffic planning, improves resource allocation efficiency, and further improves user experience.
[0140] Based on the same inventive concept as the above method embodiment, the present application embodiment also provides an Internet rental bicycle user preference type prediction system based on order data, which can implement the functions provided by the above method embodiment, such as Figure 3 As shown, the system includes the following modules:
[0141] The database construction module 110 constructs a user preference type prediction database, including order data of two main types of Internet rental bicycles, namely, shared bicycles and shared electric motorcycles, as well as built environment data and electronic fence data;
[0142] The data preprocessing module 120 cleans the shared bicycle and shared electric motorcycle data in the database and removes invalid data and abnormal data;
[0143] The user identification module 130 identifies the travel records of all shared bicycles and shared electric motorcycles under the same ID number based on the user ID, calculates the number of times and days each user uses the shared bicycle and shared electric motorcycle according to the vehicle type and borrowing time, and statistically analyzes the frequency distribution of users using shared bicycles and shared electric motorcycles;
[0144] The user preference type classification module 140 divides the users into three types: shared bicycle dominant type, balanced type and shared motorcycle dominant type according to the frequency distribution of users using shared bicycles and shared motorcycles;
[0145] The user frequently used location identification module 150 uses the HDBSCAN clustering algorithm to identify the user frequently used locations, i.e. the user frequently uses the location to borrow and return the car;
[0146] The influencing factor extraction module 160 establishes a buffer zone based on the identified user-frequently used places, and extracts the surrounding built environment characteristics, including the number of various POIs in the city, slope, road network density, distances between the frequently used places and the nearest public transportation and the nearest CBD, and shared infrastructure attributes;
[0147] The prediction model construction and prediction module 170 constructs a multinomial Logit (MNL) model as a user preference type prediction model and trains it, inputs the test data, uses the trained model to predict the user's preference type, and outputs the prediction result.
[0148] Based on the same inventive concept as the above method embodiment, the present application embodiment also provides an electronic device, such as Figure 4 As shown, the device includes: a processor 210; and a memory 220, for storing one or more programs;
[0149] When the one or more programs are executed by the processor 210, the processor executes the method for predicting the user preference type of Internet rental bicycles based on order data.
[0150] The method for predicting the user preference type of Internet rental bicycles based on order data specifically includes the following steps:
[0151] Build a user preference type prediction database, including order data of two main types of Internet rental bicycles, namely shared bicycles and shared electric motorcycles, as well as built environment data and electronic fence data;
[0152] Data preprocessing: Clean the shared bicycle and shared electric motorcycle data in the database and remove invalid and abnormal data;
[0153] Identification of the same user in shared riding: Based on the user ID, the travel records of all shared bicycles and shared electric motorcycles with the same ID number are identified. The number of times and days each user used shared bicycles and shared electric motorcycles are calculated according to the vehicle type and borrowing time, and the frequency distribution of users' use of shared bicycles and shared electric motorcycles is statistically analyzed;
[0154] Classification of user preference types: Based on the frequency distribution of users using shared bicycles and shared electric motorcycles, users are divided into three categories: shared bicycle dominant, balanced, and shared electric motorcycle dominant;
[0155] Identification of user-frequented locations: HDBSCAN clustering algorithm is used to identify user-frequented locations, i.e., the locations where users frequently borrow and return bicycles;
[0156] Extraction of factors influencing user preference types: Based on the identified user-frequently used locations, a buffer zone is established to extract the surrounding built environment characteristics, including the number of various POIs in the city, slope, road network density, the distance between the frequently used locations and the nearest public transportation and the nearest CBD, and shared infrastructure attributes;
[0157] Construction and prediction of user preference type prediction model: Construct a multinomial Logit (MNL) model as a user preference type prediction model and train it. Input the test data and use the trained model to predict the user's preference type, and output the prediction results.
[0158] Based on the same inventive concept as the above-mentioned method embodiment, the embodiment of the present application also provides a computer-readable storage medium on which a computer program is stored. When the computer program is executed by the processor 210, the method for predicting the user preference type of Internet rental bicycles based on order data is implemented.
[0159] The method for predicting the user preference type of Internet rental bicycles based on order data specifically includes the following steps:
[0160] Build a user preference type prediction database, including order data of two main types of Internet rental bicycles, namely shared bicycles and shared electric motorcycles, as well as built environment data and electronic fence data;
[0161] Data preprocessing: Clean the shared bicycle and shared electric motorcycle data in the database and remove invalid and abnormal data;
[0162] Identification of the same user in shared riding: Based on the user ID, the travel records of all shared bicycles and shared electric motorcycles with the same ID number are identified. The number of times and days each user used shared bicycles and shared electric motorcycles are calculated according to the vehicle type and borrowing time, and the frequency distribution of users' use of shared bicycles and shared electric motorcycles is statistically analyzed;
[0163] Classification of user preference types: Based on the frequency distribution of users using shared bicycles and shared electric motorcycles, users are divided into three categories: shared bicycle dominant, balanced, and shared electric motorcycle dominant;
[0164] Identification of user-frequented locations: HDBSCAN clustering algorithm is used to identify user-frequented locations, i.e., the locations where users frequently borrow and return bicycles;
[0165] Extraction of factors influencing user preference types: Based on the identified user-frequently used locations, a buffer zone is established to extract the surrounding built environment characteristics, including the number of various POIs in the city, slope, road network density, the distance between the frequently used locations and the nearest public transportation and the nearest CBD, and shared infrastructure attributes;
[0166] Construction and prediction of user preference type prediction model: Construct a multinomial Logit (MNL) model as a user preference type prediction model and train it. Input the test data and use the trained model to predict the user's preference type, and output the prediction results.
[0167] In several embodiments provided in the embodiments of the present invention, it should be understood that the disclosed apparatus and method can also be implemented in other ways. The apparatus and method embodiments described above are merely schematic. For example, the flowcharts and block diagrams in the accompanying drawings show the possible architecture, functions and operations of the apparatus, method and computer program product according to multiple embodiments of the present invention. In this regard, each box in the flowchart or block diagram can represent a module, a program segment or a part of a code, and the module, program segment or a part of the code contains one or more executable instructions for implementing the specified logical function. It should also be noted that in some alternative implementations, the functions marked in the box can also occur in a different order from the order marked in the accompanying drawings. For example, two consecutive boxes can actually be executed substantially in parallel, and they can sometimes be executed in the opposite order, depending on the functions involved. It should also be noted that each box in the block diagram and / or flowchart, and the combination of boxes in the block diagram and / or flowchart can be implemented with a dedicated hardware-based system that performs a specified function or action, or can be implemented with a combination of dedicated hardware and computer instructions.
[0168] In addition, the functional modules in the various embodiments of the present invention may be integrated together to form an independent part, or each module may exist independently, or two or more modules may be integrated to form an independent part.
[0169] If the functions are implemented in the form of software function modules and sold or used as independent products, they can be stored in a computer-readable storage medium. Based on such an understanding, the technical solution of the present invention is essentially or partly contributed to the prior art or part of the technical solution can be embodied in the form of a software product, which is stored in a storage medium and includes several instructions to enable a computer device (which can be a personal computer, an electronic device, or a network device, etc.) to perform all or part of the steps of the methods described in various embodiments of the present invention. The aforementioned storage medium includes: various media that can store program codes, such as a USB flash drive, a mobile hard disk, a read-only memory (ROM), a random access memory (RAM), a magnetic disk or an optical disk. It should be noted that, in this article, the terms "include", "comprise" or any other variant thereof are intended to cover non-exclusive inclusion, so that a process, method, article or device including a series of elements includes not only those elements, but also other elements that are not explicitly listed, or also includes elements inherent to such a process, method, article or device. Without more constraints, an element defined by the phrase "comprising a..." does not exclude the existence of other identical elements in the process, method, article or apparatus comprising the element.
[0170] The terms used in the embodiments of the present invention are only for the purpose of describing specific embodiments, and are not intended to limit the present invention. The singular forms "a", "said" and "the" used in the embodiments of the present invention and the appended claims are also intended to include plural forms, unless the context clearly indicates other meanings.
[0171] It should be understood that the term "and / or" used in this article is only a description of the association relationship of associated objects, indicating that there can be three relationships. For example, A and / or B can represent: A exists alone, A and B exist at the same time, and B exists alone. In addition, the character " / " in this article generally indicates that the associated objects before and after are in an "or" relationship.
[0172] The word "if" as used herein may be interpreted as "at the time of" or "when" or "in response to determining" or "in response to detecting", depending on the context. Similarly, the phrases "if it is determined" or "if (stated condition or event) is detected" may be interpreted as "when it is determined" or "in response to determining" or "when detecting (stated condition or event)" or "in response to detecting (stated condition or event)", depending on the context.
[0173] The "first\second" mentioned in the embodiments is only to distinguish similar objects, and does not represent a specific order for the objects. It is understandable that the "first\second" can be interchanged with the specific order or sequence where permitted. It should be understood that the objects distinguished by "first\second" can be interchanged where appropriate, so that the embodiments described herein can be implemented in an order other than those illustrated or described herein.
[0174] Although the present invention has been described in detail with reference to the aforementioned embodiments, it is still possible for those skilled in the art to modify the technical solutions described in the aforementioned embodiments, or to make equivalent substitutions for some of the technical features therein. Any modifications, equivalent substitutions, improvements, etc. made within the spirit and principles of the present invention should be included in the protection scope of the present invention.
Claims
1. A method for predicting user preference types of Internet rental bicycles based on order data, characterized in that: The steps include: S1. Build a user preference type prediction database, including the order data of the two main vehicle types of Internet rental bicycles, namely shared bicycles and shared electric motorcycles, as well as built environment data and electronic fence data; S2. Data preprocessing: Clean the shared bicycle and shared electric motorcycle data in the database of step S1 to remove invalid and abnormal data; S3. Identification of the same user in shared riding: Based on the user ID, the travel records of all shared bicycles and shared electric motorcycles with the same ID number are identified. The number of times and days each user uses shared bicycles and shared electric motorcycles are calculated according to the vehicle type and borrowing time, and the frequency distribution of users using shared bicycles and shared electric motorcycles is statistically analyzed; S4. Classification of user preference types: Based on the frequency distribution of users using shared bicycles and shared electric motorcycles, users are divided into three categories: shared bicycle dominant type, balanced type, and shared electric motorcycle dominant type; S5. Identification of user-frequently used locations: using the HDBSCAN clustering algorithm to identify user-frequently used locations, i.e., locations where users frequently borrow and return vehicles; S6. Extraction of factors influencing user preference types: Based on the frequently used places of users identified in step S5, a buffer zone is established to extract the surrounding built environment characteristics, including the number of various POIs in the city, slope, road network density, distances between the frequently used places and the nearest public transportation and the nearest CBD, and shared infrastructure attributes; S7. Construction and prediction of user preference type prediction model: Construct a multinomial Logit (MNL) model as a user preference type prediction model and train it. Input the test data and use the trained model to predict the user's preference type, and output the prediction result.
2. The method for predicting user preference types of Internet bicycle rentals based on order data according to claim 1 is characterized by: The built environment data in step S1 includes: digital elevation model DEM data, road network data, public transportation data and facility network data; the facility network data includes multiple categories of points of interest POIs such as shopping, leisure and entertainment, and commercial services, including geographical location and facility type information, and is processed through ArcGIS; the electronic fence data includes: fence name, center point address, area, and latitude and longitude coordinates of the center point and area vertices.
3. The method for predicting user preference types of Internet bicycle rentals based on order data according to claim 1 is characterized by: In step S2, the specific steps include: S21. Eliminate incomplete records of shared bicycle and shared electric motorcycle order data; wherein a complete order data includes information of user ID, vehicle ID, vehicle type, borrowing date, borrowing time, borrowing longitude, borrowing latitude, return date, return time, return longitude, and return latitude; S22. Eliminate the data where the geographical locations of shared bicycles and shared electric motorcycles borrowed and parked deviate from the predicted range; S23, eliminating records with a travel duration of less than 1 minute and greater than 2 hours, wherein the travel duration is obtained by subtracting the borrowing time from the return time in the same order; S24. Eliminate records in which the travel distance is less than 100 meters, where the travel distance is obtained by calculating the longitude and latitude of the borrowed vehicle and the longitude and latitude of the returned vehicle in the same order.
4. The method for predicting user preference types of Internet bicycle rentals based on order data according to claim 1 is characterized by: In step S4, the specific steps include: Calculate the proportion of shared bicycle trips of users. The proportion of shared bicycle trips is obtained by dividing the number of shared bicycle trips by the total number of trips. According to the proportion of shared bicycle trips, users are divided into three types in equal proportion. The specific divisions include: The proportion of shared bicycle use is high, that is, users who use shared bicycles account for ≥ 2 / 3 of the trips are classified as "shared bicycle dominant"; The proportion of shared bicycles and shared electric motorcycles is relatively balanced, that is, users with 1 / 3 < 2 / 3 of the shared bicycle trips are classified as "balanced"; The proportion of shared bicycle usage is relatively low, that is, users whose shared bicycle trips account for ≤1 / 3 are classified as "shared electric motorcycle-dominated".
5. The method for predicting user preference types of Internet bicycle rental based on order data according to claim 1 is characterized by: In step S5, the method of using HDBSCAN clustering to identify the user's frequently used locations specifically includes: S51. Input data set: input the longitude and latitude of all shared bike users’ borrowing and returning bikes; S52, coordinate system conversion: converting the longitude and latitude of the user's borrowing and returning the vehicle from the geographic coordinate system to the projection coordinate system; S53, grouping the user's travel records into different clusters according to the user ID; S54, setting parameters: defining the minimum number of sample points (min_cluster_size) required to form a cluster according to the user travel frequency interval; S55. Calculate core distance and density estimation: Calculate the core distance of each user's borrowing and returning point, and define the core distance c k (x) = d(x, N k (x)), which is the distance from the current point x to the kth closest point N k (c) The distance between two points is the distance d that can be reached from each other. k The expression of (a,b) is: d k (a,b)=max{c k (a),c k (b),d(a,b)} Among them, d(a,b) is the original distance between points a and b; S56. Construct a density adjacency graph: Based on the mutual reachability distance, construct a weighted adjacency graph, where the weight of the edge is the mutual reachability distance between the point pairs; S57, Generate minimum spanning tree: The algorithm uses Prim algorithm internally, taking sample points as original points and the mutual reachable distances between other points and the original points as weights to construct the minimum spanning tree; S58, Establish cluster hierarchy: The algorithm uses the mutual reachability distance as the weight, traverses and reorders the edges of the minimum spanning tree, and classifies each edge into a new cluster; S59, extract stable clusters: extract the most stable cluster as the final result according to the persistence analysis and the min_cluster_size parameter; S510, determining frequently used locations: The clustering result may result in more than one cluster, each cluster representing a location where the user frequently borrows and returns a vehicle. The cluster with the largest number of borrowing and returning points, i.e., the most representative cluster, is selected as the frequently used location of the user.
6. The method for predicting user preference types of Internet bicycle rental based on order data according to claim 1 is characterized by: In step S6, the specific steps include: S61, establishing a buffer zone: based on the user's frequently used locations obtained in step S5, using ArcGIS software to establish a buffer zone for extracting influencing factors; S62, extracting the number of various POIs: extracting the number of public service facilities, leisure service facilities, commercial service facilities, residential facilities and office facilities in the buffer zone; S63, slope: extracting the average slope value within the buffer zone around the user's frequently used area; S64, road network density: extract the road length within the buffer zone, and the ratio of the road length to the buffer zone area is the road network density; S65. Calculate the nearest distance: Calculate the distance between the frequently used place and the nearest bus stop, subway station and the nearest CBD; S66. Extraction of shared infrastructure attributes: including the supply of vehicles in the buffer zone and the number of electronic fences; The extraction of vehicle supply in the buffer zone includes: randomly selecting a typical working day as a representative from the data pre-processed in step S2, calculating the distances between the borrowing point and the return point of all orders on that day and the user's usual place, and filtering out the order records in the buffer zone and numbering them; Then divide the day into several time periods, and count the number of shared bicycles and shared electric motorcycles borrowed in each buffer zone in each time period according to the borrowing time and number; For the same buffer zone, the number of borrowed vehicles in the next time period is the number of available vehicles in the previous time period; by calculating the average number of borrowed vehicles in all time periods of the day, the average supply of shared bicycles and shared electric motorcycles can be obtained.
7. The method for predicting user preference types of Internet bicycle rental based on order data according to claim 1 is characterized by: In step S7, the specific steps include: S71, constructing a model: taking the user preference type, i.e., shared bicycle dominant type, balanced type, and shared electric motorcycle dominant type as the dependent variable, and taking the built environment characteristics and shared infrastructure attributes in step S6 as the explanatory variables, a multinomial logit (MNL) model is established; S72, training model: determining the relationship between the explanatory variables and the user preference type through learning, and estimating the parameters of the MNL model using the maximum likelihood estimation method; S73, model prediction: based on the estimated model parameters, input new built environment characteristics and shared infrastructure attribute data to predict the user's preference type; S74. Output prediction results: Calculate the probability that the user belongs to each preference type through the fitted MNL model, and select the preference type with the highest probability as the final prediction result.
8. A prediction system for predicting user preference types of Internet rental bicycles based on order data according to any one of claims 1 to 7, characterized in that: The system includes the following modules: A database construction module (110) constructs a user preference type prediction database, including order data of two main types of Internet rental bicycles, namely shared bicycles and shared electric motorcycles, as well as built environment data and electronic fence data; A data preprocessing module (120) cleans the shared bicycle and shared electric motorcycle data in the database to remove invalid data and abnormal data; A user identification module (130) identifies the travel records of all shared bicycles and shared electric motorcycles under the same ID number based on the user ID, calculates the number of times and days each user uses the shared bicycle and shared electric motorcycle according to the vehicle type and borrowing time, and statistically analyzes the frequency distribution of users using shared bicycles and shared electric motorcycles; A user preference type classification module (140) is used to classify users into three types: shared bicycle dominant type, balanced type and shared motorcycle dominant type according to the frequency distribution of users using shared bicycles and shared motorcycles; A user frequently used location identification module (150) adopts the HDBSCAN clustering algorithm to identify the user frequently used locations, i.e. the user frequently uses the location to borrow and return the car; The influencing factor extraction module (160) establishes a buffer zone based on the identified user-frequently used places, and extracts the surrounding built environment characteristics, including the number of various POIs in the city, slope, road network density, distances between the frequently used places and the nearest public transportation and the nearest CBD, and shared infrastructure attributes; The prediction model construction and prediction module (170) constructs a multi-logit (MNL) model as a user preference type prediction model and trains it, inputs the test data, uses the trained model to predict the user's preference type, and outputs the prediction result.
9. An electronic device, characterized in that: The electronic device comprises: a processor (210); and a memory (220) for storing one or more programs; When the one or more programs are executed by the processor (210), the processor executes the method for predicting user preference types of Internet rental bicycles based on order data as described in any one of claims 1 to 7.
10. A computer-readable storage medium, characterized in that: A computer program is stored thereon, and when the computer program is executed by the processor (210), the method for predicting user preference types of Internet rental bicycles based on order data as described in any one of claims 1 to 7 is implemented.
Citation Information
Patent Citations
Shared bicycle management and decision-making method
CN108596727A
Method and device for predicting travel mode and constructing predictive model
CN108629457A
Urban travel user portrait system construction method for elastic public transportation system
CN112508425A
System and method for predicting vehicle renting preference of customer
CN115439134A
Method for analyzing threshold effect of influence of built environment on travel volume of shared bicycles
CN115859766A
Cited By
Intercity multi-region short-term demand prediction method based on hot spot region division and MT-STALGCN
CN120975838A
Intercity multi-region short-term demand prediction method based on hotspot area division and MT-STALGCN
CN120975838B