Online car-hailing fee scheduling method based on supply and demand prediction and storage medium

Through the differential integration of the moving average autoregressive model to calculate the dynamic price adjustment multiple, the cost adjustment problem of online ride-hailing platforms when supply and demand are imbalanced, accurate cost adjustment and intelligent resource allocation are achieved, and operational efficiency and service quality are improved.

CN119151618APending Publication Date: 2024-12-17BEIJING BAILONG MAYUN TECH CO LTD
View PDF 0 Cites 2 Cited by

Patent Information

Application Number
CN202411166474.3
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2024-08-23
Publication Date
2024-12-17

AI Technical Summary

Technical Problem

During peak hours or in the case of supply and demand imbalance in specific areas, existing online ride-hailing platforms are difficult to adjust their costs in real time, resulting in excessive burden on passengers or uneven distribution of drivers. The traditional price increase strategy is too simple to accurately match the actual situation.

Method used

The differential integrated moving average autoregressive model is adopted, including local space extractor, time evolution extractor and global correlation extractor. Through CNN and dynamic selection regression algorithm, dynamic price adjustment multiples (dynamic adjustment coefficients) are calculated to achieve dynamic cost adjustment. And push information from high-demand areas to drivers through intelligent scheduling systems.

Benefits of technology

Accurate cost adjustments in the case of supply and demand imbalance, improve operational efficiency and service quality, ensure price fairness and passenger acceptance, and reduce passenger waiting time and driver resource waste.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN119151618A_ABST
    Figure CN119151618A_ABST
Patent Text Reader

Abstract

The invention discloses an online car-hailing fee scheduling method based on supply and demand prediction and a storage medium. The invention relates to the technical field of online car hailing. Passenger request data including driver positioning information 1, weather forecast API information w, traffic flow data f and event calendar e are integrated to form a data set D; useful numeric features are screened out from the data set D, and comprise the thermodynamic levels of a departure place and a destination, weather classification codes and time sequence features; and the local space extractor processes geographical distribution data of a departure place and a destination by using a CNN, extracts a feature map in combination with GIS data, and carries out training to obtain local space correlation A of the online car-hailing demand. A model integrating the CNN, a dynamic selection regression model (gradient boosting tree) and global correlation analysis is adopted, and the online car-hailing demand is obtained. Therefore, the supply and demand conditions of online car-hailing can be predicted precisely. According to the method, the influence of local space, a time sequence and global factors on supply and demand can be captured, and the prediction accuracy and adaptability are improved.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present invention relates to the technical field of online car-hailing, and in particular to a dynamic fare scheduling mechanism for online car-hailing, and in particular to an online car-hailing fare scheduling method and storage medium based on supply and demand forecasting. Background Art

[0002] As an emerging mode of transportation, online ride-hailing has rapidly gained popularity around the world due to its convenience, flexibility and relatively economical price, which has greatly changed people's travel habits. This model relies on advanced Internet technology and smartphone applications to directly connect passengers with drivers, effectively reducing the idle rate of the traditional taxi industry and improving transportation efficiency. Online ride-hailing fees usually consist of basic fees, mileage fees, time fees, and possible dynamic adjustment fees (such as peak-time surcharges), aiming to ensure the economy of the service and the income of the driver. The platform estimates the cost of the trip through an algorithm and strives to find a balance between passenger acceptance and driver income.

[0003] Online ride-hailing platforms mostly use static or relatively simple dynamic pricing models, which often set base rates based on historical data and average costs, and fail to fully consider immediate changes in market supply and demand. For example, this mechanism may work well during off-peak hours, but during peak hours or in hot taxi-hailing areas in specific areas, the contradiction between supply and demand intensifies, and the static mechanism seems to be unable to cope with it. At the same time, there is information asymmetry between the platform, drivers and passengers. Especially at times of surging demand, the platform may not be able to obtain the location and status information of all drivers in real time, resulting in inaccurate scheduling decisions.

[0004] In addition, traditional price increase strategies mainly rely on preset rules, such as dynamic price increases with a fixed ratio. Although they can adjust supply and demand to a certain extent, they are often too simple and crude and cannot accurately match the actual situation in each area and at each time point, sometimes resulting in excessive burdens on passengers or uneven distribution of drivers. At the same time, fixed price increase rules can easily force price-sensitive passenger groups to give up using online ride-hailing services during peak hours, thus affecting the popularity of services and market fairness.

[0005] To this end, the present invention proposes an online car-hailing fare scheduling method and storage medium based on supply and demand forecasting. Summary of the invention

[0006] In view of this, the present invention hopes to provide an online car-hailing fare scheduling method and storage medium based on supply and demand forecasting to solve or alleviate the technical problems existing in the prior art, namely: in the case of an imbalance between supply and demand, how can the online car-hailing platform calculate a reasonable recommended price adjustment multiple (dynamic adjustment coefficient) according to the real-time traffic conditions, with upward dynamic adjustment and downward dynamic adjustment; the technical solution of the present invention is implemented as follows:

[0007] 1. Overview:

[0008] The present invention aims to solve the above technical problems. The framework of the differential integrated moving average autoregressive model is used and improved, and is divided into a local space extractor, a time evolution extractor and a global correlation extractor.

[0009] The local space extractor uses CNN to process the departure view and the destination view respectively, analyzes whether the online ride-hailing vehicle is in the hot zone, and obtains the local space correlation A of the online ride-hailing vehicle demand;

[0010] The time evolution extractor integrates the local spatial information, weather information and order sequence correlation information of online car-hailing demand into the dynamic selection regression algorithm, and analyzes the correlation B of the change in the number of empty vehicles in the capacity of online car-hailing demand;

[0011] The global correlation extractor integrates the correlation A and correlation B between all regions, performs dynamic weighted summation and assignment based on the peak and valley periods of the current time features, obtains the global correlation C and maps it into a recommended price adjustment multiple (dynamic adjustment coefficient), which can be upward or downward.

[0012] (II) Technical solution:

[0013] 2.1 Step S1, data acquisition:

[0014] Integrate passenger request data, including driver location information l, weather forecast API information w, traffic flow data f, and event calendar e, to form dataset D.

[0015] Useful numerical features are screened out from dataset D, including thermal levels of the departure and destination, weather classification codes, and time series features (hours, dates, days of the week, and months), and then dataset D is normalized.

[0016] 2.1.1 Step S100, integration:

[0017] D={(p 1 (p1 i ,p2 i ,t i ),l i ,w i ,f i ,e i (h i ,s i ))|i=1,2,...,n};

[0018] Among them: (p 1 (p1 i ,p2 i ,t i ),l i ,w i ,fi ,e i (h i ,s i )) represents the i-th passenger request data, including the departure place p1 i 、Destination p2 i and time t i ; l i is the driver's location information; w i Is the weather forecast API information; i is the traffic flow data; i (h i ,s i ) is event calendar information, including holidays i and social activities information i . n is the number of passengers requesting data.

[0019] At the same time, invalid, duplicate, and erroneous data records in data set D are removed, missing values ​​are processed, and the data format is unified.

[0020] 2.1.2 Step S101, screening and normalization:

[0021] For a numerical eigenvector x i =[x i1 ,x i2 ,...,x im ] T , where m is the number of features; then Min-Max normalization is performed:

[0022]

[0023] in, is any element of any feature vector. And update the data set D:

[0024]

[0025] 2.2 Step S2, perform the difference integrated moving average autoregressive model:

[0026] It includes local space extractor, time evolution extractor and global correlation extractor.

[0027] The local space extractor uses CNN to process the geographic distribution data of the departure and destination, extracts feature maps based on GIS data, and trains to obtain the local spatial correlation A of online ride-hailing demand.

[0028] The time evolution extractor inputs local spatial features, weather characteristics and historical order sequences into the dynamic selection regression model to obtain the correlation B between the change in the number of empty vehicles in the capacity of online car-hailing demand.

[0029] The global correlation extractor integrates the local spatial correlation A and the time evolution correlation B, and dynamically weights them according to the current time characteristics (morning peak, noon peak, evening peak and flat peak) to form the global correlation C.

[0030] The global correlation C is mapped to a dynamic modulation coefficient using a mapping function m(C), distinguishing between upward and downward dynamic modulation.

[0031] 2.2.1 Step S200, activating the local space extractor:

[0032] Retrieve the vector x representing the geographic distribution data of the departure and destination from the dataset D G ; then execute:

[0033] A=CNN(x G ∣GIS features );

[0034] Among them, CNN(·) represents a single-layer convolutional neural network, receiving the additional features GIS provided by GIS data features , output the local spatial correlation A of online car-hailing demand.

[0035] 2.2.1.1 Step S2000, input features to a single-layer convolutional neural network:

[0036] FM l+1 =σ(Conv l (x G ⊕GIS features ∣W l ,b l ));

[0037] Where: ⊕ represents the feature concatenation operation. Conv l represents the convolution operation of layer l, applying filter W l (weight matrix) and bias b l . σ is the activation function, such as ReLU(max(0,x)). FM l+1 Represents the feature map produced by the l+1th layer.

[0038] 2.2.1.2 Step S2001, perform convolution operation:

[0039]

[0040] Where M and N are the width and height of the filter respectively. is an element of the l-th layer filter. is the value of position (i+m-1,j+n-1) in the input feature map; It is the output value of position (i, j) in the feature map of the l+1th layer, that is, the local spatial correlation A.

[0041] 2.2.2 Step S201, activating the time evolution extractor:

[0042] Extract the vector x representing local spatial features, weather features, and historical order sequences from the dataset D L ; then execute:

[0043] B = DR (A, x L );

[0044] Among them, DR represents the dynamically selected regression model, which is a gradient boosting tree model. It integrates the local spatial correlation A to predict the correlation B of the change in the number of empty vehicles in the capacity of online car-hailing demand.

[0045] 2.2.2.1 Step S2010, importing the initial prediction model

[0046] Set the initial prediction model Find a decision tree h in each iteration m m (x) to minimize the residual error (i.e., the difference between the current model prediction and the true value):

[0047]

[0048] Among them, N is the number of samples only in this formula. L is the measure of the difference between the predicted value and the true value y i The loss function of the gap between , such as the mean square error (MSE). m-1 (x i ) is the model in sample x after the first m-1 iterations i The predicted value on h m (x) is the decision tree model to be learned in the mth iteration.

[0049] 2.2.2.2 Step S2011, update decision tree:

[0050] In each iteration, the decision tree h m Instead of adding it directly to the previous round of model, a learning rate η is used to control the growth rate to avoid overfitting:

[0051] F m (x) = F m-1 (x)+ηh m (x);

[0052] 2.2.2.3 Step S2012, overall gradient boosting tree objective function:

[0053] The training objective of the entire gradient boosting tree is informally expressed as minimizing the cumulative loss function:

[0054]

[0055] Among them, M is the number of iterations only in this formula, that is, the number of decision trees in the final integration.

[0056] 2.2.3 Step S202, activating the global association extractor:

[0057] C = WS(A,B|T,W);

[0058] Among them, the WS function represents the dynamic weighting of the local spatial correlation A and the time evolution correlation B according to the current time characteristics T (distinguishing between morning peak, noon peak, evening peak and flat peak).

[0059] The form of the WS function is:

[0060]

[0061] Where: X i represents the eigenvector, where X A =A is the local spatial correlation, X B = B is the time evolution correlation; W i (T) is a piecewise weighted function that depends on the current time period label T. Different weights are set according to different time periods. 1 is the morning peak, 2 is the afternoon peak, 3 is the evening peak, and 0 is the flat peak.

[0062] Among them, w Ai 、w Bi 、w Ci and w Di are the weights of features A and B in the corresponding time period respectively. The weighted sum C comprehensively considers the comprehensive impact of local spatial supply and demand pressure (local spatial correlation A) and time evolution trend (time evolution correlation B) on the current supply and demand situation, forming a global supply and demand correlation indicator.

[0063] 2.2.4 Step S203, executing mapping function m(C):

[0064]

[0065] Among them: when C>0 indicates tight supply and demand, α and β are positive values, which are used to calculate the upward adjustment coefficient, α controls the slope of the adjustment, and β is the base price increase. When C≤0 indicates oversupply, γ and δ are set to values ​​that reduce the dynamic adjustment coefficient, γ<0 promotes cost reduction, and δ is the lower limit of the base price reduction or adjustment. Parameters α, β, γ and δ are pre-set values ​​of the platform strategy.

[0066] 2.3 Step S3, scheduling implementation:

[0067] Forecast supply and demand for future time periods (e.g., next 15 minutes, 30 minutes), and calculate the latest global correlation C and dynamic adjustment coefficient m. Automatically adjust the fare displayed on the passenger side according to the dynamic adjustment coefficient m to achieve dynamic price adjustment upward or downward.

[0068] Based on the fee adjustment results, the intelligent dispatch system pushes information about high-demand areas to nearby drivers, encouraging them to go there to pick up orders or guiding them to areas with high demand during off-peak hours.

[0069] 2.3.1 Step S300, dynamic adjustment of fees:

[0070] Automatically adjust the fare displayed on the passenger terminal according to the dynamic adjustment coefficient m:

[0071] Feead justed =Fee base ×(1+m);

[0072] Among them, Fee base Is the basic fee, Fee adjusted It is the adjusted cost.

[0073] 2.3.2 Step S301, generation and push of scheduling instructions:

[0074] Based on the fee adjustment results, the intelligent dispatch system formulates strategies and pushes instructions to nearby drivers:

[0075] Demand area: If m>0, drivers are encouraged to go to receive orders:

[0076] PushMessage(Driver nearby ,Zone high-demand );

[0077] Off-peak guidance: If m≤0, guide drivers to areas with demand:

[0078] ReallocateDrivers(Driver idle ,Zone moderate-demand );

[0079] Among them, the PushMessage and ReallocateDrivers functions represent the operations of the scheduling system, which are responsible for pushing messages and reallocating idle drivers respectively.

[0080] (III) Mechanism for solving technical problems:

[0081] The present invention builds a supply and demand forecasting model based on big data analysis and machine learning technology, including time series analysis, CNN neural network and dynamic selection regression algorithm, which is used to learn the supply and demand rules in historical data and predict the supply and demand trends in specific time periods and regions.

[0082] The supply-demand ratio is calculated based on the predicted passenger demand and the number of available drivers. This is an indicator that reflects the current degree of supply-demand tension. Based on the supply-demand ratio, a dynamic adjustment rule or function is set that maps the supply-demand ratio to a dynamic adjustment coefficient. When demand is greater than supply (high supply-demand ratio), the dynamic adjustment coefficient is positive, which means that the fee will be increased; conversely, when the supply-demand ratio is low, the dynamic adjustment coefficient is negative or close to zero, indicating that the price can be reduced or maintained at the original price. This rule also takes into account time sensitivity, such as more radical adjustments during peak hours. In addition to the supply-demand ratio, the calculation of the dynamic adjustment coefficient also takes into account other factors, such as current traffic congestion conditions, weather impacts, etc., to ensure that the price adjustment strategy is more accurate and fair.

[0083] Based on the calculated dynamic adjustment coefficient, the system automatically adjusts the fare displayed on the passenger side to achieve dynamic pricing. At the same time, the intelligent dispatching system pushes information to nearby drivers based on the latest fare adjustment, encouraging them to accept orders in high-demand areas, or guiding them to areas with potential demand growth when demand is low, thereby effectively alleviating the problem of supply and demand mismatch.

[0084] Through this series of mechanisms, online ride-hailing platforms can respond quickly to imbalances in supply and demand, balancing the market through dynamic pricing adjustments and optimizing resource allocation through intelligent scheduling, thereby improving overall operational efficiency and service quality.

[0085] Compared with the prior art, the present invention has the following beneficial effects:

[0086] 1. Supply and demand forecasting: This paper uses a model that integrates CNN, dynamic selection regression model (gradient boosting tree) and global association analysis to achieve a precise forecast of the supply and demand of online ride-hailing vehicles. This method can capture the impact of local space, time series and global factors on supply and demand, and improve the accuracy and adaptability of the forecast.

[0087] 2. Fusion of spatiotemporal features: The local space extractor of the present invention uses CNN to identify hot spots of supply and demand, the time evolution extractor captures demand patterns that change with time and weather, and the global correlation extractor dynamically adjusts the importance based on the current time characteristics. This deep fusion of spatiotemporal features enables the model to respond more flexibly to complex market dynamics.

[0088] 3. Dynamic pricing mechanism: The present invention converts the supply and demand forecast into an actual dynamic adjustment coefficient through the mapping function m(C), which not only takes into account the supply and demand tension, but also integrates the platform strategy to ensure that the pricing strategy can both motivate drivers to accept orders and ensure the fairness and acceptability of prices to passengers.

[0089] 4. Instant response and scheduling flexibility: The present invention predicts future supply and demand in real time and adjusts fees quickly, enabling the platform to respond to market changes in real time and effectively alleviate the contradiction between supply and demand. The intelligent scheduling system guides drivers to accept orders based on the dynamic scheduling coefficient, improves service efficiency, and reduces passenger waiting time. By dynamically adjusting fees and intelligent scheduling instructions, driver resources can be allocated more effectively, especially guiding drivers to high-demand areas during peak hours, and optimizing driver distribution during off-peak hours, reducing empty driving, and improving overall operational efficiency. BRIEF DESCRIPTION OF THE DRAWINGS

[0090] In order to more clearly illustrate the embodiments of the present application or the technical solutions in the prior art, the drawings required for use in the embodiments or technical descriptions will be briefly introduced below. Obviously, the drawings described below are only some embodiments of the present application. For ordinary technicians in this field, other drawings can be obtained based on these drawings without paying creative work.

[0091] Figure 1 It is a schematic diagram of the method flow of the present invention;

[0092] Figure 2 Schematic diagram of the method for executing step S1 of the present invention;

[0093] Figure 3 Schematic diagram of the execution method of step S2 of the present invention;

[0094] Figure 4 It is a schematic diagram of the execution method of step S3 of the present invention. DETAILED DESCRIPTION

[0095] In order to make the above-mentioned purposes, features and advantages of the present invention more obvious and easy to understand, the specific implementation methods of the present invention are described in detail below in conjunction with the accompanying drawings. In the following description, many specific details are set forth to facilitate a full understanding of the present invention. However, the present invention can be implemented in many other ways different from those described herein, and those skilled in the art can make similar improvements without violating the connotation of the present invention. Therefore, the present invention is not limited to the specific embodiments disclosed below;

[0096] It should be noted that the various embodiments in this specification are described in a progressive manner, and each embodiment focuses on the differences from other embodiments, and the same or similar parts between the various embodiments can be referred to each other. For the device disclosed in the embodiment, since it corresponds to the method disclosed in the embodiment, the description is relatively simple, and the relevant parts can be referred to the method part description.

[0097] Explanation of relevant terms in this specific implementation method:

[0098] Dynamic adjustment fee: A fee mechanism in which travel platforms balance supply and demand by dynamically adjusting prices during time periods and regions where supply and demand are unbalanced. In the case of an imbalance between supply and demand, the online ride-hailing platform will calculate a reasonable recommended price adjustment multiple (dynamic adjustment coefficient) based on real-time traffic conditions, which can be upward or downward.

[0099] Morning rush hour: 7:00 to 9:00 in the morning. This period is mainly the travel time for office workers and students. Many people need to rush to their workplace or school, so the demand for taxis will be relatively high.

[0100] Lunch rush hour: 11:00 to 14:00. This period is usually the lunch break, and people may need a taxi because of social events or dining out.

[0101] Evening rush hour: 5:00 to 7:00 p.m. This period is the rush hour for getting off work, and many people need to go home or go to other destinations, so the demand for taxis will increase accordingly.

[0102] Off-peak: The time period excluding the peak period.

[0103] Social event information: During holidays or large-scale events, the demand for taxis may remain high at multiple times throughout the day.

[0104] Thermal area / thermal level: refers to the area where the demand for taxis is relatively high and the taxi activities are relatively frequent in a certain period of time. These areas attract a large number of taxi demands due to their high population density, concentrated commercial activities, and the location of transportation hubs (such as factories, schools, parks, commercial buildings, and communities). The thermal level is the weight value divided according to the degree of variables in the above areas.

[0105] Example: Figures 1 to 4 As shown, this embodiment discloses a method for scheduling online car-hailing fares based on supply and demand forecasting, which requires executing the following steps S1 to S3.

[0106] Step S1 (data collection and preprocessing) is the cornerstone of the entire supply and demand forecasting and cost adjustment process. This stage involves integrating multi-source data, screening effective features, data cleaning and normalization, with the goal of building a high-quality data set to provide accurate input information for the subsequent supply and demand forecasting model.

[0107] Data integration (S1.1),First, the platform integrates data from multiple channels, including:

[0108] Passenger request data: including departure point (p1i), destination (p2i) and time (ti).

[0109] Driver location information (l): The driver's current location.

[0110] Weather forecast API information (w): reflects weather conditions and may affect passengers’ travel needs.

[0111] Traffic flow data (f): real-time or predicted traffic conditions that affect travel time.

[0112] Event calendar information (e): includes holidays (hi) and social events (si), which can significantly change travel demand.

[0113] The integrated dataset D contains all this information, with each piece of data representing a passenger request, which is used to analyze and predict demand patterns:

[0114] D={(p 1 (p1 i ,p2 i ,t i ),l i ,w i ,f i ,e i (h i ,s i ))|i=1,2,...,n};

[0115] Among them: (p 1 (p1 i ,p2 i ,t i ),l i ,w i ,f i ,e i (h i ,s i )) represents the i-th passenger request data, including the departure place p1 i 、Destination p2 i and time t i ; l i is the driver's location information; w i Is the weather forecast API information; i is the traffic flow data; i (h i ,s i ) is event calendar information, including holidays i and social activities information i . n is the number of passengers requesting data.

[0116] Feature screening and normalization (S1.2): Select numerical features from the data set that have a direct impact on supply and demand forecasts, such as the heat level of the departure and destination (reflecting popularity), weather classification codes, and time series features (hour, date, day of the week, month), etc. These features help to characterize the spatiotemporal characteristics of demand.

[0117] Normalization: In order to eliminate the differences in feature scales, the selected numerical feature vectors are normalized by Min-Max. i =[x i1 ,x i2 ,...,x im ] T , where m is the number of features; then Min-Max normalization is performed:

[0118] in, is any element of any feature vector. Here xx represents the original feature value, min(x) and max(x) are the minimum and maximum values ​​of the feature in the entire data set. After normalization, all feature values ​​are mapped to the interval [0,1], which is convenient for model training and comparison. And update the data set D:

[0119] It is understandable that by screening features that are closely related to the business and normalizing them, the accuracy of the model's forecast of supply and demand relationships can be significantly improved. This helps the platform more accurately identify which factors have a significant impact on demand, so that it can respond quickly and appropriately when there is an imbalance between supply and demand. Data cleaning and standardization reduce noise, avoid overfitting the model to specific data points, enhance the model's performance on new data, and make the calculation of the dynamic adjustment coefficient more reliable, so that both upward and downward dynamic adjustments can better match the actual market conditions.

[0120] Furthermore, the python execution program of step S1 is as follows:

[0121]

[0122]

[0123]

[0124] Step S200 is the process of activating the local space extractor, the core of which is to use the convolutional neural network (CNN) to analyze the geographical distribution data of the departure and destination, and extract the feature map in combination with the GIS data to train the local spatial correlation A of the online car-hailing demand. This process is to understand the supply and demand pressure in the local area, which in turn affects the global supply and demand balance and the calculation of the dynamic adjustment coefficient.

[0125] First, extract the geographic coordinate data representing the departure and destination from the integrated data set D to form a vector x G At the same time, additional features provided by GIS data, such as road networks, distribution of points of interest, etc., are integrated to help the model better understand the geographic spatial layout.

[0126] Convolutional Neural Network (CNN) Applications:

[0127] Input layer: x G It is then joined with GIS features to form a comprehensive input feature vector.

[0128] Convolutional layer operation: FM l+1 =σ(Conv l (x G ⊕GIS features ∣W l ,b l ));

[0129] Where: ⊕ represents the feature concatenation operation. Conv l represents the convolution operation of layer l, applying filter W l (weight matrix) and bias b l . σ is the activation function, such as ReLU(max(0,x)). FM l+1 Represents the feature map produced by the l+1th layer.

[0130] Perform a convolution operation:

[0131] Where M and N are the width and height of the filter respectively. is an element of the l-th layer filter. is the value of position (i+m-1,j+n-1) in the input feature map; It is the output value of position (i, j) in the feature map of the l+1th layer, that is, the local spatial correlation A.

[0132] Through multiple convolutions, feature maps of online ride-hailing demand are gradually extracted from the original data. The final feature map reflects the demand pattern of online ride-hailing in the local space. Local spatial correlation A output: The output of CNN is the local spatial correlation A, which quantifies the intensity of online ride-hailing demand in a specific area and is an important basis for predicting the tightness or looseness of supply and demand.

[0133] It is understandable that by sliding the convolution kernel over the geographically distributed data, local features such as high-density residential areas and commercial centers can be captured, which may lead to patterns of increased demand for online ride-hailing. Combined with GIS data, the model can understand more complex geospatial relationships, such as the impact of road congestion on demand. The extraction of local spatial correlation A is essentially the conversion of complex geospatial information into quantifiable indicators, allowing the system to identify which areas have a high demand for taxis at specific points in time. This provides an important input for the subsequent time evolution extractor and global correlation extractor, helping the system understand the "spatial" dimension of the supply and demand imbalance.

[0134] The calculation of local spatial correlation A enables the platform to accurately identify demand hotspots in the city, dispatch resources in a timely manner, reduce passenger waiting time, and improve user experience. A is an important component of calculating global correlation C and dynamic adjustment coefficient m. By analyzing the tension of local spatial supply and demand, the platform can more scientifically decide whether to adjust upward (increase fees to attract drivers to accept orders) or downward (reduce fees to stimulate demand), thereby achieving supply and demand balance and optimizing resource allocation. By real-time monitoring of local spatial correlation, the platform can foresee and prevent possible capacity overload in certain areas, dispatch drivers to potential demand areas in advance, and reduce the imbalance between supply and demand between regions.

[0135] Furthermore, the Python execution program of step S200 is as follows:

[0136]

[0137]

[0138]

[0139] When applying the above program, the geographical distribution data (such as longitude and latitude grid data) needs to be converted into a format acceptable to CNN, usually a four-dimensional array, where the first three dimensions are the height, width and number of channels of the image, and the last dimension is the number of samples. The model starts with one or more convolutional layers, using the ReLU activation function, which can identify spatial features in the input data. Next, the multi-dimensional feature map is flattened into a one-dimensional vector through the Flatten layer, and then the features are further extracted through the fully connected layer and the local spatial correlation A is finally predicted. The model is compiled using the Adam optimizer, which is a commonly used gradient descent variant with strong adaptability. The loss function uses the mean square error (MSE), which measures the gap between the model's predicted value and the true value, and is suitable for regression problems. After the model is trained, it can be used for new geographical distribution data and output the predicted local spatial correlation A. This A value will serve as an important input for calculating the global correlation C and the dynamic adjustment coefficient m in the subsequent steps.

[0140] Step S201 is the part that activates the time evolution extractor. Its core is to predict the correlation B of the change in the number of empty vehicles in the demand for online car-hailing by dynamically selecting a regression model (in this case, a gradient boosting tree, GBT). This process integrates local spatial features, weather characteristics, and historical order sequences to predict future changes in supply and demand, and then guide dynamic pricing strategies to achieve supply and demand balance. Data representing local spatial features (such as local spatial correlation A), weather characteristics (such as weather coding), and historical order sequences are extracted from the data set D to form a vector xL. These data reflect the real-time status and recent trends of online car-hailing demand.

[0141] Use the Gradient Boosted Tree (GBT) model, which is an ensemble learning method that gradually adds decision trees to reduce prediction errors. GBT learns a new decision tree in each iteration to minimize the residual, which is the difference between the current model's predicted value and the actual value. Each tree is trained based on the residual of the previous round of predictions, so it can gradually correct the deviation in the prediction.

[0142] Training process:

[0143] Initialization: Set the initial model to a simple prediction (average) Then the iteration process begins. In each round of iteration m, a decision tree h is found. m (x) to minimize the residual error (i.e., the difference between the current model prediction and the true value).

[0144] Iterative update: In each iteration m, find a decision tree hm(x) that minimizes the residual:

[0145] Among them, N is the number of samples only in this formula. L is the measure of the difference between the predicted value and the true value y i The loss function of the gap between , such as the mean square error (MSE). m-1 (x i ) is the model in sample x after the first m-1 iterations i The predicted value on h m (x) is the decision tree model to be learned in the mth iteration.

[0146] Model integration: In each iteration, the decision tree h m Instead of adding it directly to the previous round of models, a learning rate η is used to control the growth rate to avoid overfitting: F m (x) = F m-1 (x)+ηh m (x);

[0147] Objective function: The goal of the entire GBT is to minimize the cumulative loss function, expressed as: The training goal of the entire gradient boosting tree is informally expressed as minimizing the cumulative loss function:

[0148]

[0149] Among them, M is the number of iterations only in this formula, that is, the number of decision trees in the final integration.

[0150] The time evolution extractor predicts future supply and demand trends, especially the changes in the number of empty vehicles, by integrating local spatial features A, weather features, and historical order sequences. This helps the platform respond quickly when supply and demand are tight or loose, and adjusts strategies based on the prediction results. For example, when a surge in demand is predicted during peak hours, the platform can increase prices in advance (upward adjustment) to encourage more drivers to go online and accept orders when it foresees that the capacity may be insufficient. On the contrary, when oversupply is predicted during off-peak hours, the price can be appropriately lowered (downward adjustment) to attract passengers to use the service and balance the supply and demand relationship.

[0151] Through real-time forecasting and dynamic pricing, the platform can more effectively balance supply and demand, reduce passenger waiting time, improve driver order efficiency, and increase overall satisfaction. The dynamic pricing mechanism promotes the effective allocation of resources, avoids waste of capacity during peak hours and insufficient capacity during off-peak hours, and improves the overall operational efficiency of the service. Through accurate supply and demand forecasting, the platform can adjust its pricing strategy in a timely manner, which not only protects the income of the platform and drivers, but also ensures that the price is attractive to passengers, achieving a win-win situation of economic benefits and market stability.

[0152] Furthermore, the Python execution program of step S201 is as follows:

[0153] from sklearn.ensemble import GradientBoostingRegressor

[0154] from sklearn.model_selection import train_test_split

[0155] from sklearn.metrics import mean_squared_error

[0156] import pandas as pd

[0157] import numpy as np

[0158] #Data preprocessing to get feature matrix X and target variable y

[0159] # Among them, X contains information such as local spatial features A, weather features, and historical order sequences

[0160] #y is the actual value of the known correlation B between the number of empty vehicles and capacity

[0161] #Feature matrix X and target variable y

[0162] #X=...

[0163] #y=...

[0164] # Divide into training set and test set

[0165] X_train,X_test,y_train,y_test=train_test_split(X,y,test_size=0.2,random_state=42)

[0166] # Initialize the gradient boosted tree regression model

[0167] gbt_regressor=GradientBoostingRegressor(n_estimators=100, learning_rate=0.1, max_depth=3, random_state=42)

[0168] #Train model

[0169] gbt_regressor.fit(X_train,y_train)

[0170] #predict

[0171] predictions=gbt_regressor.predict(X_test)

[0172] #Evaluate the model

[0173] mse=mean_squared_error(y_test,predictions)

[0174] print(f"Mean Squared Error:{mse}")

[0175] #Use the model to predict new time evolution features B

[0176] #new_data=...#New feature data

[0177] #predicted_B=gbt_regressor.predict(new_data)

[0178] In the above program, the dataset contains all the necessary features, including local spatial correlation A, weather characteristics, and historical order sequences. These features are organized into a feature matrix X, and the target variable y is the known correlation B of the change in the number of empty trucks. The model is initialized using the GradientBoostingRegressor class of Scikit-Learn. Parameters such as n_estimators are set to 100, indicating that 100 trees are built; learning_rate is set to 0.1 to control the contribution of each tree to the prediction results; max_depth is set to 3 to control the depth of the tree to prevent overfitting.

[0179] By calling the fit method, the model learns the relationship between X and y. GBT gradually builds decision trees through an iterative process, and each tree tries to reduce the residual of the prediction result of the previous tree. After the model training is completed, predictions can be made on the test set, and the model performance can be evaluated using indicators such as mean square error (MSE). After that, the model can be used to predict new time evolution features B, and then calculate the global correlation C and dynamic adjustment coefficient m.

[0180] Step S202, i.e. activating the global correlation extractor, is an important part of the online car-hailing fare scheduling method based on supply and demand forecasting. It is responsible for integrating local spatial correlation and time evolution correlation, dynamically adjusting the weights of the two based on the current time characteristics, and forming a global correlation C, which is further mapped into a dynamic adjustment coefficient m to guide the dynamic adjustment of the fare.

[0181] Integrate local spatial correlation A and time evolution correlation B: At this stage, we have obtained the local spatial correlation A through the local spatial extractor (step S200) and the time evolution correlation B through the time evolution extractor (step S201). These two parameters represent the degree of supply and demand tension in the geographical location and the supply and demand trend over time. The mapping function m(C) is used to convert the global correlation C into the dynamic adjustment coefficient m. The principle is to decide whether to adjust the price and the direction and amplitude of the price adjustment according to the degree of supply and demand tension. The logic of the mapping function can be:

[0182]

[0183] Where: X i represents the eigenvector, where X A =A is the local spatial correlation, X B = B is the time evolution correlation; W i (T) is a piecewise weighted function that depends on the current time period label T, and different weights are set according to different time periods. 1 is the morning peak, 2 is the afternoon peak, 3 is the evening peak, and 0 is the flat peak; w Ai 、w Bi 、w Ciand w Di are the weights of features A and B in the corresponding time period respectively. The weighted sum C comprehensively considers the comprehensive impact of local spatial supply and demand pressure (local spatial correlation A) and time evolution trend (time evolution correlation B) on the current supply and demand situation, forming a global supply and demand correlation indicator.

[0184] When C>0 indicates tight supply and demand, α and β are positive values, which are used to calculate the upward adjustment coefficient. α controls the slope of the adjustment, and β is the base price increase. When C≤0 indicates oversupply, γ and δ are set to values ​​that reduce the dynamic adjustment coefficient. γ<0 promotes a decrease in costs, and δ is the lower limit of the base price reduction or adjustment. Parameters α, β, γ, and δ are pre-set values ​​of the platform strategy.

[0185] By calculating the global correlation C in real time, the platform can accurately identify areas and time periods where supply and demand are tight or loose, so as to quickly respond to market changes through dynamic price adjustment, encourage drivers to accept orders in high-demand areas or look for opportunities in low-demand periods, and achieve supply and demand balance. The introduction of the dynamic adjustment coefficient m enables the platform to automatically adjust the fees displayed on the passenger side, reduce passenger waiting time, and at the same time increase the driver's order acceptance rate and income, improve overall service efficiency and user satisfaction. The global correlation extractor ensures the optimal allocation of resources under different time periods and geographical conditions through comprehensive considerations. For example, during peak hours and high-demand areas, upward dynamic adjustments are used to encourage drivers to accept orders and alleviate the problem of difficulty in getting a taxi for passengers; during off-peak hours or low-demand areas, downward dynamic adjustments are used to promote demand and avoid waste of resources.

[0186] Furthermore, the Python execution program of the above method is as follows:

[0187]

[0188]

[0189]

[0190] In the above program:

[0191] Global correlation extractor (S202): This part dynamically adjusts the weights of local spatial correlation A and time evolution correlation B according to the current time characteristics by defining a weight function. For example, during the morning peak period, more emphasis may be placed on the supply and demand pressure of the local space (i.e., A has a higher weight), while during the off-peak period, more emphasis may be placed on historical trends (B has a higher weight). Through this dynamic weighting, a global correlation index C is obtained, which reflects the current comprehensive supply and demand situation.

[0192] Mapping function m(C) (S203): The mapping function determines the value of the dynamic adjustment coefficient m according to the global correlation C, distinguishing between upward and downward dynamic adjustment. When C is greater than 0, it indicates that supply and demand are tight, and the dynamic adjustment coefficient m is calculated by positive α and β to achieve an increase in fees; conversely, when C is less than or equal to 0, it indicates oversupply, and negative γ and δ are used to reduce fees and promote supply and demand balance. The design of the mapping function needs to take into account platform strategy and market acceptance to ensure that the dynamic adjustment strategy is reasonable and effective.

[0193] Step S3 is the real-time prediction and scheduling implementation stage, which is a key link in the online car-hailing fare scheduling method based on supply and demand forecasting. It aims to dynamically adjust the fare and intelligently schedule drivers according to real-time traffic conditions and forecast results to balance supply and demand and improve service efficiency.

[0194] Application of dynamic adjustment coefficient: Based on the global correlation C calculated in step S2, the dynamic adjustment coefficient m is obtained through the mapping function m(C). If C>0, it means that supply and demand are tight, and the dynamic adjustment coefficient m is positive, indicating that the cost is adjusted upward; on the contrary, if C≤0, it means that supply exceeds demand, and the dynamic adjustment coefficient m is negative or close to 0, which promotes a decrease in costs.

[0195] Cost adjustment calculation: The cost displayed on the passenger side is adjusted by the dynamic adjustment coefficient m:

[0196] Feead justed =Fee base ×(1+m); where FeeBase is the basic fee and FeeAdjusted is the adjusted fee.

[0197] The real-time calculation and application of the dynamic adjustment coefficient enables the platform to respond quickly to market changes, guide passenger demand through dynamic adjustment of fees, and at the same time motivate or adjust drivers' order-taking behavior to promote supply and demand balance. During peak hours, moderate price increases can reduce passenger waiting time, while during off-peak hours, price reduction strategies encourage passengers to travel, improve vehicle utilization, and balance passengers' travel costs and convenience.

[0198] When the dynamic dispatch coefficient m>0, it means there are high-demand areas. The intelligent dispatch system identifies these areas through algorithms and pushes messages to nearby idle drivers: "PushMessage(Drivernearby,ZoneHighDemand)". If m≤0, it means that the overall supply and demand are balanced or oversupply, and the system will guide drivers to potential demand areas: "ReallocateDrivers(DriverIdle,ZoneModerateDemand)".

[0199] It is understandable that through intelligent dispatching, the platform can effectively mobilize driver resources to ensure sufficient capacity in high-demand areas, while reducing empty trips in low-demand areas and improving overall operational efficiency. Drivers can receive orders faster and increase their income through dispatch instructions, especially during peak demand periods, which improves job satisfaction and loyalty. Reducing empty trips and ineffective dispatching helps reduce carbon emissions and is in line with the concept of green travel.

[0200] Furthermore, the Python execution program of step S3 is as follows:

[0201]

[0202]

[0203]

[0204] In the above program, the calculate_adjusted_fee function receives the base fee and the dynamic adjustment coefficient as input to calculate the adjusted fee. The dynamic adjustment coefficient (m) represents the degree of tension between supply and demand. A positive number indicates an increase in the fee, while a negative number indicates a decrease in the fee. The dynamic adjustment of the fee is achieved through a simple mathematical operation (1+m) multiplied by the base fee.

[0205] The dispatch_drivers function determines the dispatch strategy based on the positive or negative value of the dynamic adjustment coefficient. If the dynamic adjustment coefficient is greater than 0, it means that there is a tension between supply and demand. At this time, the system will send a message to encourage nearby drivers to go to high-demand areas to accept orders; if the dynamic adjustment coefficient is not greater than 0, it means that there is oversupply or supply and demand are balanced. The system will guide drivers to wait for orders in medium-demand areas to balance the supply and demand relationship.

[0206] All the above embodiments only express the implementation methods of the relevant practical applications of the present invention, and the descriptions thereof are relatively specific and detailed, but they cannot be understood as limiting the scope of the invention patent. It should be pointed out that, for ordinary technicians in this field, several variations and improvements can be made without departing from the concept of the present invention, which all belong to the protection scope of the present invention. Therefore, the protection scope of the patent of the present invention shall be based on the attached claims.

[0207] For those skilled in the art, it can be further appreciated that the units and algorithm steps of each example described in conjunction with the embodiments disclosed herein can be implemented in electronic hardware, computer software, or a combination of the two. In order to clearly illustrate the interchangeability of hardware and software, the composition and steps of each example have been generally described in the above description according to function. Whether these functions are performed in hardware or software depends on the specific application and design constraints of the technical solution. Professional and technical personnel can use different methods to implement the described functions for each specific application, but such implementation should not be considered to be beyond the scope of the present invention.

[0208] At the same time, those skilled in the art can understand that all or part of the processes in all the above-mentioned embodiments can be completed by instructing the relevant hardware through a computer program, and the computer program can be stored in a non-volatile computer-readable storage medium. When the computer program is executed, it can include the processes of the embodiments of the above-mentioned methods. Among them, any reference to memory, storage, database or other media provided in this application and used in the embodiments may include non-volatile and / or volatile memory. Non-volatile memory may include read-only memory (ROM), programmable ROM (PROM), electrically programmable ROM (EPROM), electrically erasable programmable ROM (EEPROM) or flash memory. Volatile memory may include random access memory (RAM) or external cache memory. As an illustration and not limitation, RAM is available in many forms, such as static RAM (SRAM), dynamic RAM (DRAM), synchronous DRAM (SDRAM), double data rate SDRAM (SSRSDRAM), enhanced SDRAM (ESDRAM), synchronous link (Synchlink) DRAM (SLDRAM), memory bus (Rambus) direct RAM (RDRAM), direct memory bus dynamic RAM (DRDRAM), and memory bus dynamic RAM (RDRAM).

Claims

1. Online car-hailing fare scheduling method based on supply and demand forecasting, It is characterized in that The steps include: S1, data collection and preprocessing stage: Integrate passenger request data, including driver location information l, weather forecast API information w, traffic flow data f and event calendar e, form data set D and filter out useful numerical features and update them; S2, performs the differential integrated moving average autoregressive model: including local space extractor, time evolution extractor and global correlation extractor; The local space extractor uses CNN to process the geographic distribution data of the departure and destination, extracts feature maps based on GIS data, and trains to obtain the local spatial correlation A of online car-hailing demand; The time evolution extractor inputs local spatial features, weather features, and historical order sequences into the dynamic selection regression model to obtain the correlation B of the change in the number of empty vehicles in the online car-hailing demand; The global correlation extractor integrates the local spatial correlation A and the temporal evolution correlation B, dynamically weights them according to the current temporal features, and forms the global correlation C; Use the mapping function m(C) to map the global correlation C into a dynamic modulation coefficient, distinguishing between upward and downward dynamic modulation; S3, scheduling implementation: forecast supply and demand for future periods, and calculate the latest global correlation C and dynamic scheduling coefficient m; The fare displayed on the passenger side is automatically adjusted according to the dynamic adjustment coefficient m to achieve dynamic price adjustment upward or downward.

2. The cost scheduling method according to claim 1, Features: In S1, the integration method is: D={(p 1 (p1 i ,p2 i ,t i ),l i ,w i ,f i ,e i (h i ,s i ))∣i=1,2,...,n}; Among them: (p 1 (p1 i ,p2 i ,t i ),l i ,w i ,f i ,e i (h i ,s i )) represents the i-th passenger request data, including the departure place p1 i 、Destination p2 i and time t i ; l i is the driver's location information; w i Is the weather forecast API information; i is the traffic flow data; i (h i ,s i ) is event calendar information, including holidays i and social activities information i ; n is the number of passenger request data.

3. The cost scheduling method according to claim 1, Features: In S1, the screening method is: For a numerical eigenvector x i =[x i1 ,x i2 ,...,x im ] T , where m is the number of features; Then perform Min-Max normalization: in, is any element of any feature vector; and updates the data set D:

4. The cost scheduling method according to claim 1, Features: In S2, the schematic method of the local space extractor is: Retrieve the vector x representing the geographic distribution data of the departure and destination from the dataset D G ; then execute: A=CNN(x G ∣GIS features ); Among them, CNN(·) represents a single-layer convolutional neural network, receiving the additional features GIS provided by GIS data features , output the local spatial correlation A of online car-hailing demand.

5. The cost scheduling method according to claim 4, Features: The execution method of the single-layer convolutional neural network is: FM l+1 =σ(Conv l (x G ⊕GIS features ∣W l ,b l )); Among them: ⊕ represents feature concatenation operation; Conv l represents the convolution operation of layer l, applying filter W l (weight matrix) and bias b l ; σ is the activation function, such as ReLU(max(0,x)); FM l+1 Represents the feature map produced by the l+1th layer; M and N are the width and height of the filter respectively; is an element of the l-th layer filter; is the value of position (i+m-1,j+n-1) in the input feature map; It is the output value of position (i, j) in the feature map of the l+1th layer, that is, the local spatial correlation A.

6. The cost scheduling method according to claim 1, Features: In S2, the execution method of the time evolution extractor is: Extract the vector x representing local spatial features, weather features, and historical order sequences from the dataset D L ; Then execute: B = DR (A, x L ); Among them, DR represents the dynamically selected regression model, which integrates the local spatial correlation A to predict the correlation B of the change in the number of empty vehicles in the capacity of online car-hailing demand.

7. The cost scheduling method according to claim 6, Features: The dynamically selected regression model is the gradient boosted tree model: Set the initial prediction model Find a decision tree h in each iteration m m (x) to minimize the residual error: Among them, N is the number of samples only in this formula; L is the measure of the difference between the predicted value and the true value y i The loss function of the gap between m-1 (x i ) is the model in sample x after the first m-1 iterations i The predicted value on h m (x) is the decision tree model to be learned in the mth iteration; Minimize the cumulative loss function at each iteration: F m (x)=F m-1 (x)+ηh m (x); Among them, M is the number of iterations only in this formula, that is, the number of decision trees in the final integration.

8. The cost scheduling method according to claim 1, Features: In S3, the method for dynamically adjusting the fee is: Automatically adjust the fare displayed on the passenger terminal according to the dynamic adjustment coefficient m: Feead justed =Fee base ×(1+m); Among them, Fee base Is the basic fee, Fee adjusted It is the adjusted cost.

9. The cost scheduling method according to claim 8, Features: In S3, according to the fee adjustment result, the intelligent dispatching system formulates a strategy and pushes instructions to nearby drivers: Demand area: If m>0, drivers are encouraged to go to receive orders: PushMessage(Driver nearby ,Zone high-demand ); Off-peak guidance: If m≤0, guide drivers to areas with demand: ReallocateDrivers(Driver idle ,Zone moderate-demand ); Among them, the PushMessage and ReallocateDrivers functions represent the operations of the scheduling system, which are responsible for pushing messages and reallocating idle drivers respectively.

10. A storage medium, Features: The storage medium stores program instructions that can implement the fee scheduling method as described in any one of claims 1-9.

Citation Information

Cited By

  • Online hailed vehicle scheduling optimization method and device based on end-to-end prediction, and storage medium

    CN119783915A

  • Online car-hailing service degradation method, device and equipment and storage medium

    CN120602543A