Energy supply site recommendation method and device, electronic equipment and storage medium

By making two-scoring predictions for energy recharge sites, the problem of low accuracy of single-scoring in the prior art is solved, and a more accurate and reliable recommendation of energy recharge sites is achieved.

CN119940634APending Publication Date: 2025-05-06CHONGQING JINKANG NEW ENERGY VEHICLE CO LTD
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN202510029800.4
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2025-01-08
Publication Date
2025-05-06

AI Technical Summary

Technical Problem

The existing energy supply site recommendation method only performs a single rating, which is not very accurate, and is prone to recommendation errors, which cannot meet the driving users' needs for accurate recommendations.

Method used

By obtaining data from the current vehicle and energy recharge site, feature extraction and two scoring predictions are performed. The first scoring prediction is based on feature data, and the second scoring prediction is based on the feature matrix generated by the first scoring prediction results to improve the accuracy of the recommendation.

Benefits of technology

Through the two-scoring prediction method, the applicability of each energy recharge station to the current vehicle can be more accurately evaluated, the accuracy and robustness of recommendations can be improved, and the occurrence of recommendation errors can be reduced.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN119940634A_ABST
    Figure CN119940634A_ABST
Patent Text Reader

Abstract

The invention provides an energy supply station recommendation method and device, electronic equipment and a storage medium, and the method comprises the steps: obtaining the vehicle data of a current vehicle and the station data of a plurality of current energy supply stations, carrying out the feature extraction of each current energy supply station according to the vehicle data and the station data, and carrying out the feature extraction of each current energy supply station; based on the extracted feature data of each current energy supply station, performing first-time score prediction on each current energy supply station, generating a feature matrix based on the first-time score prediction result of each current energy supply station, and performing second-time score prediction on each current energy supply station based on the feature matrix, determining a to-be-recommended energy supply site according to the second score prediction result of each current energy supply site; the second scoring prediction can correct the deviation of the first scoring prediction to a certain extent, the applicability of each current energy supply station to the current vehicle can be evaluated more accurately, and recommendation errors caused by inaccurate single scoring prediction are reduced.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present application relates to the field of vehicle service technology, and in particular to an energy supply station recommendation method, device, electronic device and storage medium. Background Art

[0002] With the popularity of new energy vehicles and the continued existence of fuel vehicles, gas stations, charging stations and other energy supply stations play a vital role in ensuring the normal operation of vehicles. However, with the increase in the number of energy supply stations, drivers often fall into a dilemma when choosing a suitable station. This autonomous selection method not only easily consumes the driver's energy and causes driving distraction, but also highly relies on the driver's personal experience or geographical proximity, lacking accuracy. Therefore, how to quickly and accurately recommend suitable energy supply stations to drivers has become an important issue that needs to be solved.

[0003] In recent years, despite the rapid development of big data and artificial intelligence technologies, which have made it possible to recommend energy refueling stations through data analysis, the existing recommendation methods still have many shortcomings. Among them, the most prominent problem is that most recommendation methods only score energy refueling stations once, which is not accurate and prone to recommendation errors, and cannot meet the needs of driving users for accurate recommendations. Summary of the invention

[0004] In view of the shortcomings of the prior art mentioned above, the present application provides an energy refueling station recommendation method, device, electronic device and storage medium to solve the technical problem that most of the above-mentioned existing recommendation methods only perform a single score prediction for the energy refueling station, the accuracy is not high, recommendation errors are prone to occur, and the driving users' needs for accurate recommendations cannot be met.

[0005] The present application provides a method for recommending energy refueling stations, the method comprising: obtaining vehicle data of a current vehicle and station data of multiple current energy refueling stations; performing feature extraction on each current energy refueling station based on the vehicle data of the current vehicle and the station data of each current energy refueling station, and performing a first score prediction on each current energy refueling station based on the extracted feature data of each current energy refueling station to obtain a first score prediction result of each current energy refueling station; generating a feature matrix based on the first score prediction result of each current energy refueling station, and performing a second score prediction on each current energy refueling station based on the feature matrix, so as to determine an energy refueling station to be recommended from all current energy refueling stations according to the second score prediction result of each current energy refueling station.

[0006] In one embodiment of the present application, before performing a first score prediction for each current energy supply station, the method includes: acquiring multiple groups of historical data, each group of historical data including vehicle data of a historical vehicle and site data of multiple historical energy supply stations; performing feature extraction on each historical energy supply station based on the vehicle data of the historical vehicle and the site data of multiple historical energy supply stations in a group of historical data, and using the extracted feature data of each historical energy supply station as a training sample to obtain multiple training samples; forming a training data set from the multiple training samples, and training a base model based on the training data set to perform a first score prediction for each current energy supply station through the trained base model.

[0007] In one embodiment of the present application, the base model is trained based on the training data set to perform a first score prediction for each current energy supply station through the trained base model, including: training the first base model and the second base model based on the training data set respectively to obtain a trained first base model and a trained second base model; inputting the characteristic data of each current energy supply station into the trained first base model and the trained second base model respectively to obtain the score prediction results of the trained first base model for each current energy supply station and the score prediction results of the trained second base model for each current energy supply station as the first score prediction results of each current energy supply station.

[0008] In one embodiment of the present application, training a first base model based on the training data set includes: setting parameters for a random forest base model, including at least the number of trees, the maximum tree depth and the random state of the random forest base model, the first base model being the random forest base model; iterating according to the training data set and the set parameters to construct multiple decision trees until the number of decision trees reaches the number of trees, and obtaining a trained random forest base model as the trained first base model, wherein the step of constructing the decision tree includes randomly sampling training samples in the training data set according to the random state of the random forest base model, constructing the decision tree based on the sampling results, and selecting the optimal splitting point and the optimal splitting feature at each node of the decision tree to construct the structure of the decision tree until the depth of the decision tree reaches the maximum tree depth.

[0009] In one embodiment of the present application, the second base model is trained based on the training data set, including: setting parameters for the logistic regression base model, including at least the random state of the logistic regression base model, the second base model being the logistic regression base model; initializing the weights of the logistic regression base model according to the random state of the logistic regression base model, and selecting the type of the loss function of the logistic regression base model; for each training sample in the training data set, calculating the gradient of the loss function relative to the weight, and updating the weight of the logistic regression base model according to the calculated gradient until the loss function of the logistic regression base model is less than or equal to a preset threshold, thereby obtaining a trained logistic regression base model as the trained second base model.

[0010] In one embodiment of the present application, before performing a second score prediction on each current energy supply site, the method includes: performing score prediction based on the training data set by the trained first base model and the trained second base model, respectively, to obtain the score prediction result of the trained first base model for the training data set and the score prediction result of the trained second base model for the training data set; generating a feature matrix sample based on the score prediction result of a training sample in the training data set by the trained first base model and the score prediction result of the trained second base model for the same training sample in the training data set to obtain multiple feature matrix samples; forming a secondary training data set with the multiple feature matrix samples, and training a secondary model based on the secondary training data set to perform a second score prediction on each current energy supply site through the trained secondary model.

[0011] In one embodiment of the present application, based on the vehicle data of the current vehicle and the site data of each current energy recharge site, feature extraction is performed on each current energy recharge site, including: based on the vehicle position of the current vehicle and the site position of each current energy recharge site, calculating the distance between the current vehicle and each current energy recharge site as the site distance of each current energy recharge site, the vehicle data includes the vehicle position, and the site data includes the site position; calculating the energy efficiency ratio of each current energy recharge site based on the remaining energy of the current vehicle and the site distance of each current energy recharge site, and the vehicle data also includes the remaining energy; calculating the cost-effectiveness of each current energy recharge site based on the site distance and energy price of each current energy recharge site, and the site data also includes the energy price; using the site distance, cost-effectiveness, energy price, site score, and energy efficiency ratio of the same current energy recharge site as feature data of the same current energy recharge site to obtain feature data of each current energy recharge site, and the site data also includes the site score.

[0012] In one embodiment of the present application, an energy refueling station recommendation device is also provided, the device comprising: a data acquisition module, used to obtain vehicle data of a current vehicle and site data of multiple current energy refueling stations; an information processing module, used to extract features of each current energy refueling station based on the vehicle data of the current vehicle and the site data of each current energy refueling station, and based on the extracted feature data of each current energy refueling station, perform a first score prediction on each current energy refueling station to obtain a first score prediction result of each current energy refueling station; generate a feature matrix based on the first score prediction result of each current energy refueling station, and perform a second score prediction on each current energy refueling station based on the feature matrix, so as to determine the energy refueling station to be recommended from all current energy refueling stations according to the second score prediction result of each current energy refueling station.

[0013] In one embodiment of the present application, an electronic device is also provided, comprising: one or more processors; a storage device for storing one or more programs, and when the one or more programs are executed by the one or more processors, the electronic device implements the energy supply site recommendation method as described above.

[0014] In one embodiment of the present application, a computer-readable storage medium is further provided, on which a computer program is stored. When the computer program is executed by a processor of a computer, the computer executes the energy replenishment site recommendation method as described above.

[0015] Beneficial effects of the present application: The present application provides an energy supply station recommendation method, device, electronic device and storage medium, which can more accurately evaluate the applicability of each current energy supply station to the current vehicle through two scoring predictions. The first scoring prediction based on the characteristic data of each current energy supply station can provide a basic score for subsequent scoring, and the second scoring prediction based on the feature matrix generated by the first scoring prediction result can further refine and optimize the score, thereby improving the accuracy of the overall recommendation. In addition, the second scoring prediction can correct the deviation of the first scoring prediction to a certain extent, reduce recommendation errors caused by inaccurate single scoring predictions, and thus maintain high robustness and accuracy.

[0016] It should be understood that the foregoing general description and the following detailed description are exemplary and explanatory only and are not restrictive of the present application. BRIEF DESCRIPTION OF THE DRAWINGS

[0017] Figure 1 is a schematic diagram of an implementation environment of an energy supply station recommendation method shown in an exemplary embodiment of the present application;

[0018] Figure 2is a flow chart of a method for recommending energy supply sites shown in an exemplary embodiment of the present application;

[0019] Figure 3 is a flowchart of energy supply station recommendation shown in a specific embodiment of the present application;

[0020] Figure 4 is a block diagram of an energy supply site recommendation device shown in an exemplary embodiment of the present application;

[0021] Figure 5 It is a structural schematic diagram of an electronic device shown in an exemplary embodiment of the present application. DETAILED DESCRIPTION

[0022] The following describes the embodiments of the present application through specific examples, and those skilled in the art can easily understand other advantages and effects of the present application from the contents disclosed in this specification. The present application can also be implemented or applied through other different specific embodiments, and the details in this specification can also be modified or changed in various ways based on different viewpoints and applications without departing from the spirit of the present application. It should be noted that the following embodiments and features in the embodiments can be combined with each other without conflict.

[0023] It should be noted that the illustrations provided in the following embodiments are only schematic illustrations of the basic concept of the present application, and thus the drawings only show components related to the present application rather than being drawn according to the number, shape and size of components in actual implementation. In actual implementation, the type, quantity and proportion of each component may be changed at will, and the component layout may also be more complicated.

[0024] It should be noted that in this application, "first", "second", etc. are only used to distinguish similar objects, and are not used to limit the order or precedence of similar objects. The variations of "including", "having", etc. described above indicate that the scope covered by the subject of the word is not exclusive except for the examples shown by the word.

[0025] It is understood that the various numbers, step numbers, etc. recorded in this application are distinguished for the convenience of description and are not used to limit the scope of this application. The size of the numbers in this application does not mean the order of execution. The execution order of each process should be determined by its function and internal logic.

[0026] In the following description, a large number of details are discussed to provide a more thorough explanation of the embodiments of the present application. However, it is obvious to those skilled in the art that the embodiments of the present application can be implemented without these specific details. In other embodiments, well-known structures and devices are shown in the form of block diagrams rather than in detail to avoid making the embodiments of the present application difficult to understand.

[0027] The embodiments of the present application respectively propose an energy replenishment site recommendation method, an energy replenishment site recommendation device, an electronic device, a computer-readable storage medium, and a computer program product, which will be described in detail below.

[0028] See also Figure 1 , Figure 1 It is a schematic diagram of an implementation environment of an energy replenishment site recommendation method shown as an exemplary embodiment of the present application.

[0029] like Figure 1 As shown, the implementation environment may include a vehicle side 110 and a cloud side 120, wherein the cloud side 120 may be a cloud server that provides basic cloud computing services such as cloud services, cloud databases, cloud computing, cloud functions, cloud storage, network services, cloud communications, middleware services, domain name services, security services, CDN (Content Delivery Network), and big data and artificial intelligence platforms, and is not limited here. The vehicle of the vehicle side 110 itself may be a pure electric vehicle, a fuel vehicle, or a hybrid vehicle, and is not limited here. The cloud side 120 may be used to collect site data of each energy replenishment site. When the vehicle side 110 has energy replenishment needs such as refueling or charging, the vehicle data of the current vehicle may be collected through its own sensors, and an energy replenishment site recommendation request may be initiated to the cloud side 120 and the vehicle data of the current vehicle may be uploaded, so that the cloud side 120 may determine the site data of multiple current energy replenishment sites from the site data of multiple energy replenishment sites, so as to perform scoring prediction based on the vehicle data of the current vehicle and the site data of each current energy replenishment site, determine the energy replenishment site to be recommended, and send it to the vehicle side 110. Of course, when the vehicle side 110 has energy replenishment needs such as refueling or charging, it can also request the cloud 120 to obtain the site data of multiple current energy supply sites, so as to make scoring predictions based on the vehicle data of the current vehicle collected by its own sensors and the site data of multiple current energy supply sites sent by the cloud 120, and determine the energy supply site to be recommended.

[0030] Schematically, the vehicle end 110 or the cloud end 120 obtains the vehicle data of the current vehicle and the site data of multiple current energy supply stations; according to the vehicle data of the current vehicle and the site data of each current energy supply station, the feature extraction is performed on each current energy supply station, and based on the extracted feature data of each current energy supply station, the first score prediction is performed on each current energy supply station to obtain the first score prediction result of each current energy supply station; based on the first score prediction result of each current energy supply station, a feature matrix is ​​generated, and based on the feature matrix, a second score prediction is performed on each current energy supply station, so as to determine the energy supply station to be recommended from all current energy supply stations according to the second score prediction result of each current energy supply station. It can be seen that the technical solution of the embodiment of the present application can more accurately evaluate the applicability of each current energy supply station to the current vehicle through two score predictions. The first score prediction is performed according to the feature data of each current energy supply station, which can provide a basic score for subsequent scoring, and the second score prediction is performed using the feature matrix formed by the first score prediction result, which can further refine and optimize the score, thereby improving the accuracy of the overall recommendation. Moreover, the second rating prediction can correct the deviation of the first rating prediction to a certain extent and reduce the recommendation errors caused by inaccurate single rating prediction, thereby maintaining high robustness and accuracy.

[0031] It should be noted that the energy replenishment site recommendation method provided in the embodiment of the present application can be specifically executed by the vehicle end 110 or the cloud end 120 , and accordingly, the energy replenishment site recommendation device can be set in the vehicle end 110 or the cloud end 120 .

[0032] See also Figure 2 , Figure 2 is a flowchart of an energy replenishment site recommendation method shown in an exemplary embodiment of the present application. The energy replenishment site recommendation method can be applied to Figure 1 The implementation environment shown is specifically executed by the vehicle end 110 or the cloud end 120 in the implementation environment. It should be understood that the energy supply station recommendation method can also be applied to other exemplary implementation environments and be specifically executed by devices in other implementation environments. This embodiment does not limit the implementation environment to which the energy supply station recommendation method is applicable.

[0033] like Figure 2 As shown, in an exemplary embodiment, the energy supply site recommendation method includes at least steps S210 to S230, which are described in detail as follows:

[0034] Step S210, obtaining vehicle data of the current vehicle and site data of multiple current energy supply sites.

[0035] In one embodiment of the present application, the current vehicle refers to a vehicle that currently has an energy replenishment demand; the vehicle data includes at least one of the vehicle location, the remaining energy amount, etc., wherein the remaining energy amount may be the remaining fuel amount, the remaining power amount, or the remaining energy amount of other vehicles. That is, the vehicle data of the current vehicle includes at least one of the current vehicle location, the remaining fuel amount, the remaining power amount, etc. The current energy replenishment site refers to the energy replenishment site within the current drivable range of the current vehicle, wherein the energy replenishment site includes at least one of a gas station, a charging station, etc., which can be referred to as a site; the site data includes at least one of the site location, the site type (such as a gas station or a charging station), the energy price (such as an oil price or an electricity price), and the user's rating of the site. That is, the site data of the current energy replenishment site includes at least one of the site location, the site type, the current energy price, the site rating (i.e., the user's rating of the site), etc. of the current energy replenishment site.

[0036] The energy supply station recommendation method can be executed on the vehicle side or on the cloud side. For the vehicle side, the vehicle data of the current vehicle can be collected through the vehicle's own sensors, and the station data can be obtained by requesting the cloud side and uploading the vehicle position of the current vehicle, so that the cloud side can determine the station data of multiple current energy supply stations from the station data of multiple energy supply stations according to the vehicle position in the vehicle data and send them down. For the cloud side, the vehicle data of the current vehicle uploaded by the vehicle side can be obtained, and the station data of multiple current energy supply stations can be determined from the station data of multiple energy supply stations according to the vehicle position in the vehicle data.

[0037] Among them, the cloud can collect the site data of multiple energy refueling sites in advance and update them in real time or periodically. The method of determining the site data of multiple current energy refueling sites from the site data of multiple energy refueling sites according to the vehicle position in the vehicle data can include matching the vehicle position of the current vehicle and the site positions of multiple energy refueling sites, determining the energy refueling site within the current drivable range of the current vehicle as the current energy refueling site, and obtaining multiple current energy refueling sites and the site data of each current energy refueling site.

[0038] Step S220, based on the vehicle data of the current vehicle and the site data of each current energy supply site, feature extraction is performed on each current energy supply site, and based on the extracted feature data of each current energy supply site, a first score prediction is performed on each current energy supply site to obtain the first score prediction result of each current energy supply site.

[0039] In one embodiment of the present application, the characteristic data may include at least the site distance, the energy price and the site score. Taking the current energy supply site A as an example, according to the vehicle data of the current vehicle and the site data of the current energy supply site A, the feature extraction of the current energy supply site A is performed. Specifically, the distance from the current vehicle to the current energy supply site A can be calculated according to the vehicle position in the vehicle data of the current vehicle and the site position in the site data of the current energy supply site A, as the site distance of the current energy supply site A, so as to use the site distance of the current energy supply site A and the energy price and site score in the site data of the current energy supply site A as the characteristic data of the current energy supply site A. By analogy, the characteristic data of each current energy supply site is obtained. Then, according to the weights of the site distance, energy price and site score and the extracted characteristic data of each current energy supply site, the score prediction of each current energy supply site can be performed, and the initial score of each current energy supply site can be obtained as the first score prediction result, wherein the weights of the site distance, energy price and site score can be preset or dynamically determined. Schematically, the weights of the site distance, energy price and site score of different current energy supply sites can be dynamically adjusted according to the specific values ​​of their site distance, energy price and site score. For example, the weight corresponding to the site score of each current energy supply site can decrease as the specific values ​​of its site distance and / or energy price increase.

[0040] In one embodiment of the present application, feature extraction is performed on each current energy recharge station based on vehicle data of the current vehicle and site data of each current energy recharge station, including: calculating the distance between the current vehicle and each current energy recharge station as the site distance of each current energy recharge station based on the vehicle position of the current vehicle and the site position of each current energy recharge station, the vehicle data includes the vehicle position, and the site data includes the site position; calculating the energy efficiency ratio of each current energy recharge station based on the remaining energy of the current vehicle and the site distance of each current energy recharge station, the vehicle data also includes the remaining energy; calculating the cost-effectiveness of each current energy recharge station based on the site distance and energy price of each current energy recharge station, the site data also includes the energy price; using the site distance, cost-effectiveness, energy price, site score, and energy efficiency ratio of the same current energy recharge station as feature data of the same current energy recharge station to obtain feature data of each current energy recharge station, the site data also includes the site score.

[0041] In this embodiment, the vehicle location may include the longitude and latitude of the vehicle, and the site location may include the longitude and latitude of the energy supply site. The characteristic data may include at least site distance, cost performance, energy price, site score, and energy efficiency ratio. Exemplarily, the site distance is calculated as follows:

[0042]

[0043] Among them, d is the site distance, R is the radius of the earth, which is about 6371 kilometers, φ1 is the latitude of the vehicle in the vehicle position, φ2 is the latitude of the energy supply site in the site position, Δφ is the latitude difference between the vehicle position and the site position, which can be expressed in radians, and Δλ is the longitude difference between the vehicle position and the site position, which can be expressed in radians.

[0044] The energy efficiency ratio refers to the ratio of the remaining energy such as the remaining fuel or remaining electricity to the distance from the station. It is calculated as follows:

[0045] Energy efficiency ratio = energy surplus / d Formula (2)

[0046] Where d is the site distance.

[0047] Energy price refers to the charging price or fuel price at the energy supply station, and the station rating refers to the user's rating of the energy supply station, that is, the user rating of the station.

[0048] Cost-effectiveness is the product of site distance and energy price, calculated as follows:

[0049] Cost performance = d × energy price (3)

[0050] Where d is the site distance.

[0051] This embodiment uses station distance, cost-effectiveness, energy price, station score and energy efficiency ratio as characteristic data of energy supply stations to achieve a comprehensive evaluation of energy supply stations from multiple dimensions, and then more comprehensively evaluates the applicability of each current energy supply station to the current vehicle, which can effectively improve the accuracy of the first score prediction.

[0052] In one embodiment of the present application, before performing a first rating prediction on each current energy supply station, the method includes: acquiring multiple groups of historical data, each group of historical data including vehicle data of a historical vehicle and site data of multiple historical energy supply stations; performing feature extraction on each historical energy supply station based on the vehicle data of the historical vehicle and the site data of the multiple historical energy supply stations in a group of historical data, and using the extracted feature data of each historical energy supply station as a training sample to obtain multiple training samples; forming a training data set from the multiple training samples, and training a base model based on the training data set to perform a first rating prediction on each current energy supply station through the trained base model.

[0053] In this embodiment, the historical vehicle refers to a vehicle that had energy replenishment needs in the past, and the vehicle data of the historical vehicle includes at least one of the vehicle position, remaining fuel, remaining power, etc. of the historical vehicle at the historical moment when energy replenishment was needed. Correspondingly, the historical energy replenishment station refers to the energy replenishment station within the drivable range of the historical vehicle at the historical moment, and the station data of the historical energy replenishment station includes at least one of the station location, station type, energy price at the historical moment, station score, etc. of the historical energy replenishment station.

[0054] Taking a group of historical data as an example, according to the method described in the above embodiment, based on the vehicle position of the historical vehicle in the group of historical data and the site data of a historical energy supply site, the feature extraction of the historical energy supply site is performed to obtain the feature data of the historical energy supply site, including the site distance, cost performance, energy price, site score and energy efficiency ratio of the historical energy supply site, and then the feature data of multiple historical energy supply sites obtained based on the group of historical data are used as a training sample. By analogy, multiple training samples are obtained to train the base model as a training data set. Schematically, the base model includes at least one of a random forest base model, a logistic regression base model, etc.

[0055] This embodiment uses the characteristic data of each current energy supply site as the model input of the trained base model, and performs the first score prediction on each current energy supply site through the trained base model. The weights of various features in the characteristic data, such as site distance, cost-effectiveness, energy price, site score and energy efficiency ratio, are automatically learned through a machine learning algorithm. There is no need to rely on manual setting of weights, which can effectively improve the objectivity and accuracy of site recommendations.

[0056] In one embodiment of the present application, a base model is trained based on a training data set to perform a first score prediction for each current energy supply site through the trained base model, including: training the first base model and the second base model based on the training data set respectively to obtain a trained first base model and a trained second base model; inputting the characteristic data of each current energy supply site into the trained first base model and the trained second base model respectively to obtain a score prediction result for each current energy supply site by the trained first base model and a score prediction result for each current energy supply site by the trained second base model as the first score prediction result for each current energy supply site.

[0057] In this embodiment, the base model includes a first base model and a second base model, and correspondingly, the trained base model includes a trained first base model and a trained second base model. The first base model and the second base model may be base models of the same type, for example, both may be random forest base models or logistic regression base models, and the first base model and the second base model may also be base models of different types, for example, both may be random forest base models and logistic regression base models, respectively.

[0058] This embodiment uses two different base models to perform the first scoring prediction on each current energy supply site, which can combine the advantages of the two base models, reduce the deviations and errors that may be caused by a single base model, further improve the accuracy and robustness of the first scoring prediction, and provide richer basic data for the subsequent second scoring prediction.

[0059] In one embodiment of the present application, a first base model is trained based on a training data set, including: setting parameters for a random forest base model, including at least the number of trees, a maximum tree depth, and a random state of the random forest base model, the first base model being a random forest base model; iterating according to the training data set and the set parameters to construct multiple decision trees until the number of decision trees reaches the number of trees, and obtaining a trained random forest base model as the trained first base model, wherein the step of constructing a decision tree includes randomly sampling training samples in the training data set according to the random state of the random forest base model, constructing a decision tree based on the sampling results, and selecting an optimal splitting point and an optimal splitting feature at each node of the decision tree to construct a structure of the decision tree until the depth of the decision tree reaches the maximum tree depth.

[0060] In this embodiment, the training steps of the random forest base model are as follows:

[0061] 1. Data preparation: Convert the training dataset into a format suitable for random forest base model input;

[0062] 2. Set model parameters: Set the model parameters of the random forest base model, including n_estimators (number of trees), max_depth (maximum tree depth), random_state (random state), etc.

[0063] 3. Model training: Use the training data set and the set model parameters to train the model. The specific training process includes building multiple decision trees, each of which uses a different sample subset and feature subset. The core steps of model training include sample and feature sampling, node splitting, and tree fusion. For sample and feature sampling, in each round of iteration, randomly sample training samples and features to build a decision tree; for node splitting, select the optimal split point and split feature at each node to build the structure of the decision tree; for tree fusion, average the prediction results of multiple decision trees to get the final prediction result.

[0064] Among them, the sample subset refers to a set formed by multiple training samples obtained by randomly sampling the training sample set, the feature subset refers to a feature subset formed by multiple features obtained by randomly sampling each training sample in the sample subset, and the feature refers to feature data of types such as site score, site distance, and energy efficiency ratio. Each decision tree uses different sample subsets and feature subsets, which means that the types of training samples in the training sample subset randomly sampled in each iteration and the types of features in each feature subset are not exactly the same. In addition, the loss function can be calculated by the prediction score of the decision tree and the site score in the training sample, and the optimal split point and split feature can be selected according to the calculated loss function.

[0065] In one embodiment of the present application, training a second base model based on a training data set includes: setting parameters for a logistic regression base model, including at least a random state of the logistic regression base model, wherein the second base model is a logistic regression base model; initializing the weights of the logistic regression base model according to the random state of the logistic regression base model, and selecting a type of loss function for the logistic regression base model; for each training sample in the training data set, calculating the gradient of the loss function relative to the weight, and updating the weight of the logistic regression base model according to the calculated gradient until the loss function of the logistic regression base model is less than or equal to a preset threshold, thereby obtaining a trained logistic regression base model as the trained second base model.

[0066] In this embodiment, the training steps of the logistic regression base model are as follows:

[0067] 1. Data preparation: Convert the training dataset into a format suitable for input into the logistic regression base model;

[0068] 2. Set model parameters: Set the model parameters of the logistic regression base model, including the random state, which is used to control the seed of the random number generator. Of course, other model parameters can also be included, such as the maximum number of iterations, regularization related parameters, etc.

[0069] 3. Model training: Use the training data set and the set model parameters to train the model. The specific training process includes using the gradient descent algorithm to optimize the loss function of logistic regression. The core steps of model training include calculating gradients and updating weights. For calculating gradients, for each training sample, calculate the gradient of the loss function relative to the weight; for updating weights, update the weights of the logistic regression base model according to the gradient to minimize the loss function until the loss function of the logistic regression base model reaches the preset threshold.

[0070] Among them, the loss function of the logistic regression base model can be calculated by the predicted score of the logistic regression base model and the site score in the training sample.

[0071] Step S230, generating a feature matrix based on the first score prediction results of each current energy supply station, and performing a second score prediction on each current energy supply station based on the feature matrix, so as to determine the energy supply station to be recommended from all current energy supply stations according to the second score prediction results of each current energy supply station.

[0072] In one embodiment of the present application, since the first scoring prediction results may show inaccurate scoring of some current energy supply stations, a feature matrix can be generated based on the initial score of each current energy supply station in the first scoring prediction results, and a second scoring prediction can be performed on each current energy supply station based on the feature matrix. Then, the final score of each current energy supply station in the second scoring prediction results is sorted, and a preset number of current energy supply stations are selected from them in order of the final score from high to low as the energy supply stations to be recommended to the driving user on the vehicle side, which can effectively reduce the occurrence of recommendation errors.

[0073] In one embodiment of the present application, a feature matrix is ​​generated based on the first scoring prediction results of each current energy supply station, and a second scoring prediction is performed on each current energy supply station based on the feature matrix, including: the initial score of each current energy supply station and the site score of each current energy supply station in the first scoring prediction results are spliced ​​into a feature matrix, and a score prediction is performed on each current energy supply station based on the feature matrix and the initial score and the site score of each current energy supply station, to obtain a final score of each current energy supply station as the second scoring prediction result, wherein the weights of the initial score and the site score can be pre-set or dynamically determined.

[0074] In another embodiment of the present application, a feature matrix is ​​generated based on the first score prediction results of each current energy supply station, and a second score prediction is performed on each current energy supply station based on the feature matrix, including: the score prediction results of the trained first base model for each current energy supply station and the score prediction results of the trained second base model for each current energy supply station are spliced ​​into a feature matrix, and a score prediction is performed on each current energy supply station according to the feature matrix and the respective weights of the trained first base model and the trained second base model to obtain a final score of each current energy supply station as the second score prediction result, wherein the first score prediction result includes the score prediction results of the trained first base model for each current energy supply station and the score prediction results of the trained second base model for each current energy supply station, and the respective weights of the trained first base model and the trained second base model can be pre-set or dynamically determined.

[0075] In one embodiment of the present application, before performing a second score prediction on each current energy supply site, the method includes: performing score prediction based on the training data set by using the trained first base model and the trained second base model, respectively, to obtain the score prediction results of the trained first base model for the training data set and the score prediction results of the trained second base model for the training data set; generating a feature matrix sample according to the score prediction results of a training sample in the training data set by the trained first base model and the score prediction results of the trained second base model for the same training sample in the training data set to obtain multiple feature matrix samples; forming a secondary training data set with the multiple feature matrix samples, and training a secondary model based on the secondary training data set to perform a second score prediction on each current energy supply site through the trained secondary model.

[0076] In this embodiment, the training data set is predicted using the trained random forest base model to generate prediction results, and the training data set is predicted using the trained logistic regression base model to generate prediction results, the score prediction result columns for the same training sample in the two prediction results are spliced ​​into a feature matrix sample, and a secondary training data set is constructed based on the spliced ​​multiple feature matrix samples, and the secondary model is trained as the input of the secondary model, so that the feature matrix formed by the prediction results of each current energy replenishment site by the two base models is input into the trained secondary model, and the second score prediction is performed on each current energy replenishment site through the trained secondary model. Schematically, the secondary model can be XGBoost, and its model parameters include objective function, maximum tree depth, learning rate, subsampling ratio, and feature sampling ratio. This embodiment adopts ensemble learning, combined with a variety of machine learning models, which can effectively capture the complex nonlinear relationship between features and improve the recognition ability of complex data patterns.

[0077] See also Figure 3 , Figure 3 FIG. 1 is a flowchart of energy supply station recommendation shown in a specific embodiment of the present application. Figure 3 As shown, the recommended process for energy supply stations is as follows:

[0078] 1. Obtain vehicle data and station data, and perform feature extraction to form a training data set;

[0079] 2. Initialize the random forest model (random forest base model) and the logistic regression model (logistic regression base model) respectively, and use the training data set to train the random forest model and the logistic regression model respectively to obtain the trained random forest model and the trained logistic regression model;

[0080] 3. The prediction results of the trained random forest model and the trained logistic regression model on the training data set are respectively used to form a secondary training data set, and the secondary model XGBoost is trained using the secondary training data set to obtain a trained secondary model;

[0081] 4. Use the trained random forest model, the trained logistic regression model and the trained secondary model to predict the energy supply station score and obtain the final score of charging stations or gas stations, including obtaining the current location of the vehicle, the remaining fuel or remaining power and other energy remaining amount and the station data of charging stations or gas stations within the current drivable range of the vehicle in real time; calculate the characteristic data of each station based on the above real-time data, including station distance, energy efficiency ratio, energy price, station score, and cost performance; use the trained random forest model to predict based on the characteristic data to obtain the initial score of each station, and use the trained logistic regression model to predict based on the characteristic data to obtain the initial score of each station; splice the prediction result columns of the above two base models into a feature matrix as the input of the secondary model, use the trained secondary model to predict based on the feature matrix, and generate the final prediction result, that is, the final score of each station; sort all stations according to the final score, and select the highest-scoring stations to recommend to the vehicle driver, such as the first 5 stations.

[0082] For the detailed process of the specific embodiments of the present application, please refer to the records in the aforementioned embodiments, which will not be repeated here. The energy replenishment site recommendation method provided in the specific embodiments of the present application does not need to rely on manually set weights. The weights of features are automatically learned through a machine learning algorithm, which can improve the objectivity and accuracy of site recommendations. And by adopting ensemble learning and combining multiple machine learning models, it can effectively capture the complex nonlinear relationships between features and improve the ability to recognize complex data patterns. In addition, the model can be dynamically adjusted according to the vehicle data and site data obtained in real time to maintain the real-time and accuracy of site recommendations, thereby adapting to changes in the environment and user needs.

[0083] See also Figure 4 , Figure 4 is a block diagram of an energy supply site recommendation device shown in an exemplary embodiment of the present application. The device can be applied to Figure 1 The implementation environment shown is specifically configured in the vehicle end 110 or the cloud 120. The device can also be applied to other exemplary implementation environments and specifically configured in other devices. This embodiment does not limit the implementation environment to which the device is applicable.

[0084] like Figure 4 As shown, the exemplary energy refueling station recommendation device includes: a data acquisition module 410, which is used to obtain vehicle data of the current vehicle and site data of multiple current energy refueling stations; an information processing module 420, which is used to extract features of each current energy refueling station based on the vehicle data of the current vehicle and the site data of each current energy refueling station, and based on the extracted feature data of each current energy refueling station, perform a first score prediction on each current energy refueling station to obtain a first score prediction result of each current energy refueling station; generate a feature matrix based on the first score prediction result of each current energy refueling station, and perform a second score prediction on each current energy refueling station based on the feature matrix, so as to determine the energy refueling station to be recommended from all current energy refueling stations according to the second score prediction result of each current energy refueling station.

[0085] In one embodiment of the present application, the energy supply site recommendation device is configured on the vehicle side, wherein the data acquisition module 410 may include various sensors of the vehicle and vehicle-mounted communication equipment such as T-Box. The data acquisition module 410 may also be a hardware device for collecting data from sensors and vehicle-mounted communication equipment such as T-box. The information processing module 420 may be a microprocessor or chip such as MCU (Microcontroller Unit) or ECU (Electronic Control Unit), which is not limited here.

[0086] In another embodiment of the present application, the energy supply site recommendation device is configured in the cloud, wherein the data acquisition module 410 can be a data transceiver server such as a mail server, a file transfer server or a message server, and the information processing module 420 can be a data processing server, an application server or a data analysis server, etc., which is not limited here.

[0087] It should be noted that the energy replenishment site recommendation device provided in the above embodiment and the energy replenishment site recommendation method provided in the above embodiment belong to the same concept, wherein the specific manner in which each module and unit performs the operation has been described in detail in the method embodiment, and will not be repeated here. In actual application, the energy replenishment site recommendation device provided in the above embodiment can allocate the above functions to different functional modules as needed, that is, divide the internal structure of the device into different functional modules to complete all or part of the functions described above, and this is not limited here.

[0088] This embodiment also provides an electronic device, including: one or more processors; a storage device for storing one or more programs, when the one or more programs are executed by the one or more processors, the electronic device implements the energy supply site recommendation method provided in the above-mentioned embodiments.

[0089] See also Figure 5 , Figure 5 is a schematic diagram of a structure of an electronic device shown in an exemplary embodiment of the present application. It should be noted that: Figure 5 The electronic device 500 shown is only an example and should not bring any limitation to the functions and scope of use of the embodiments of the present application.

[0090] like Figure 5 As shown, the electronic device 500 includes a processor 501, a memory 502 and a communication bus 503; the communication bus 503 is used to connect the processor 501 and the memory 502; the processor 501 is used to execute the computer program stored in the memory 502 to implement one or more methods in the above embodiments.

[0091] This embodiment also provides a computer-readable storage medium, on which a computer program is stored. When the computer program is executed by a processor of a computer, the computer executes the energy replenishment site recommendation method as described above. The computer-readable storage medium may be included in the electronic device described in the above embodiment, or may exist independently without being assembled into the electronic device.

[0092] This embodiment also provides a computer program product or a computer program, which includes computer instructions stored in a computer-readable storage medium. A processor of a computer device reads the computer instructions from the computer-readable storage medium, and the processor executes the computer instructions, so that the computer device executes the energy replenishment site recommendation method provided in each of the above embodiments.

[0093] The electronic device provided in this embodiment includes a processor, a memory, a transceiver and a communication interface. The memory and the communication interface are connected to the processor and the transceiver and complete communication with each other. The memory is used to store computer programs, the communication interface is used to communicate, and the processor and the transceiver are used to run the computer program so that the electronic device executes each step of the above method.

[0094] In this embodiment, the memory may include a random access memory (RAM), and may also include a non-volatile memory (non-volatile memory), such as at least one disk memory.

[0095] The above-mentioned processor can be a general-purpose processor, including a central processing unit (CPU), a network processor (NP), etc.; it can also be a digital signal processor (DSP), an application specific integrated circuit (ASIC), a field programmable gate array (FPGA) or other programmable logic devices, discrete gate or transistor logic devices, discrete hardware components.

[0096] The computer-readable storage medium in this embodiment can be understood by ordinary technicians in this field: all or part of the steps of implementing the above-mentioned method embodiments can be completed by hardware related to the computer program. The aforementioned computer program can be stored in a computer-readable storage medium. When the program is executed, the execution includes the steps of the above-mentioned method embodiments; and the aforementioned storage medium includes: ROM (read-only memory), RAM (random access memory), magnetic disk or optical disk and other media that can store program codes.

[0097] The above embodiments are merely illustrative of the principles and effects of the present application, and are not intended to limit the present application. Anyone familiar with the technology may modify or change the above embodiments without violating the spirit and scope of the present application. Therefore, all equivalent modifications or changes made by a person of ordinary skill in the art without departing from the spirit and technical ideas disclosed in the present application shall still be covered by the claims of the present application.

Claims

1. A method for recommending energy supply sites, characterized in that: The method comprises: Acquire vehicle data of a current vehicle and site data of a plurality of current energy supply sites; According to the vehicle data of the current vehicle and the site data of each current energy supply site, feature extraction is performed on each current energy supply site, and based on the extracted feature data of each current energy supply site, a first score prediction is performed on each current energy supply site to obtain a first score prediction result of each current energy supply site; A feature matrix is ​​generated based on the first score prediction results of each current energy supply site, and a second score prediction is performed on each current energy supply site based on the feature matrix, so as to determine the energy supply site to be recommended from all current energy supply sites according to the second score prediction results of each current energy supply site.

2. The energy supply site recommendation method according to claim 1, characterized in that: Before performing the first score prediction for each current energy supply site, the method includes: Acquire multiple sets of historical data, each set of historical data includes vehicle data of a historical vehicle and site data of multiple historical energy supply sites; According to the vehicle data of the historical vehicles in a set of historical data and the site data of the multiple historical energy supply sites, feature extraction is performed on each historical energy supply site, and the extracted feature data of each historical energy supply site is used as a training sample to obtain multiple training samples; A plurality of training samples are formed into a training data set, and a base model is trained based on the training data set, so as to perform a first score prediction for each current energy supply site through the trained base model.

3. The energy supply site recommendation method according to claim 2, characterized in that: The base model is trained based on the training data set to perform a first score prediction for each current energy supply site through the trained base model, including: Based on the training data set, the first base model and the second base model are trained respectively to obtain a trained first base model and a trained second base model; The characteristic data of each current energy supply station are respectively input into the trained first base model and the trained second base model to obtain the score prediction results of each current energy supply station by the trained first base model and the score prediction results of each current energy supply station by the trained second base model as the first score prediction results of each current energy supply station.

4. The energy supply site recommendation method according to claim 3, characterized in that: Training the first base model based on the training data set includes: Setting parameters for a random forest base model, including at least the number of trees, the maximum tree depth, and the random state of the random forest base model, wherein the first base model is the random forest base model; Iterate according to the training data set and the set parameters to construct multiple decision trees until the number of decision trees reaches the number of trees, and obtain a trained random forest base model as the trained first base model, wherein the step of constructing the decision tree includes: The training samples in the training data set are randomly sampled according to the random state of the random forest base model, the decision tree is constructed based on the sampling results, and the optimal splitting point and the optimal splitting feature are selected at each node of the decision tree to construct the structure of the decision tree until the depth of the decision tree reaches the maximum tree depth.

5. The energy supply site recommendation method according to claim 3, characterized in that: Training the second base model based on the training data set includes: Setting parameters for a logistic regression base model, including at least a random state of the logistic regression base model, wherein the second base model is the logistic regression base model; Initializing the weights of the logistic regression base model according to the random state of the logistic regression base model, and selecting the type of the loss function of the logistic regression base model; For each training sample in the training data set, the gradient of the loss function relative to the weight is calculated, and the weight of the logistic regression base model is updated according to the calculated gradient until the loss function of the logistic regression base model is less than or equal to a preset threshold, thereby obtaining a trained logistic regression base model as the trained second base model.

6. The energy supply site recommendation method according to claim 3, characterized in that: Before performing a second score prediction for each current energy supply site, the method includes: Using the trained first base model and the trained second base model to perform score prediction based on the training data set, respectively, to obtain a score prediction result of the trained first base model for the training data set and a score prediction result of the trained second base model for the training data set; Generate a feature matrix sample according to the score prediction result of the trained first base model for a training sample in the training data set and the score prediction result of the trained second base model for the same training sample in the training data set, so as to obtain a plurality of feature matrix samples; A plurality of feature matrix samples are formed into a secondary training data set, and a secondary model is trained based on the secondary training data set, so as to perform a second scoring prediction on each current energy supply site through the trained secondary model.

7. The energy supply site recommendation method according to any one of claims 1 to 6, characterized in that: According to the vehicle data of the current vehicle and the site data of each current energy supply site, feature extraction is performed on each current energy supply site, including: According to the vehicle position of the current vehicle and the site position of each current energy supply site, the distance between the current vehicle and each current energy supply site is calculated as the site distance of each current energy supply site, the vehicle data includes the vehicle position, and the site data includes the site position; Calculating the energy efficiency ratio of each current energy supply station according to the current remaining energy of the vehicle and the station distance of each current energy supply station, wherein the vehicle data also includes the remaining energy; Calculate the cost performance of each current energy supply site according to the site distance and energy price of each current energy supply site, wherein the site data also includes the energy price; The site distance, cost performance, energy price, site score, and energy efficiency ratio of the same current energy supply site are used as characteristic data of the same current energy supply site to obtain characteristic data of each current energy supply site, and the site data also includes the site score.

8. An energy supply site recommendation device, characterized in that: The device comprises: A data acquisition module, used to obtain vehicle data of a current vehicle and site data of a plurality of current energy supply sites; An information processing module is used to extract features of each current energy supply station based on the vehicle data of the current vehicle and the station data of each current energy supply station, and perform a first score prediction on each current energy supply station based on the extracted feature data of each current energy supply station to obtain a first score prediction result of each current energy supply station; generate a feature matrix based on the first score prediction result of each current energy supply station, and perform a second score prediction on each current energy supply station based on the feature matrix, so as to determine the energy supply station to be recommended from all the current energy supply stations according to the second score prediction result of each current energy supply station.

9. An electronic device, characterized in that: The electronic device comprises: one or more processors; A storage device for storing one or more programs, which, when executed by the one or more processors, enables the electronic device to implement the energy replenishment site recommendation method as described in any one of claims 1-7.

10. A computer-readable storage medium, characterized in that: A computer program is stored thereon, and when the computer program is executed by a processor of a computer, the computer is caused to execute the energy replenishment site recommendation method as described in any one of claims 1-7.