IA-SVM driving condition recognition method and device based on LSTM speed prediction optimization
The IA-SVM driving condition identification method optimized through LSTM speed prediction, combined with vehicle historical operating data and speed prediction model, solves the problems of fuel economy and online identification accuracy in complex traffic environments, achieving more efficient fuel use and accuracy Driving condition identification.
Patent Information
- Application Number
- CN202111241720.3
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2021-10-25
- Publication Date
- 2024-10-15
- Estimated Expiration
- 2041-10-25
AI Technical Summary
Existing driving condition recognition methods cannot effectively improve fuel economy in complex traffic environments, and the accuracy of online recognition is greatly affected by the inherent errors caused by the recognition cycle and update cycle.
The IA-SVM driving condition identification method based on LSTM speed prediction optimization is used to construct a kinematic segment database by obtaining vehicle historical operating data, train the IA optimized SVM algorithm and LSTM speed prediction model, and combine the future speed sequence to reduce the identification error and improve online identification. Accuracy.
It significantly improves the fuel economy and online recognition accuracy of urban buses, reduces the complexity of adaptive control, and adapts to complex traffic environments.
Smart Images

Figure CN114004993B_ABST
Abstract
Description
Technical Field
[0001] The present invention relates to the field of road driving technology, and in particular to an IA-SVM driving condition recognition method and device based on LSTM speed prediction optimization. Background Art
[0002] Combining the online identification method of driving conditions with specific control strategies can realize adaptive control to adapt to complex traffic conditions and improve the fuel economy of urban buses.
[0003] In order to cope with the complex urban traffic environment and achieve adaptive control, many optimization control strategies have been proposed at home and abroad, which can be mainly divided into the following two categories. The first category is to plan the energy distribution of the whole vehicle by predicting and planning the reference battery state of charge (SOC), combining model predictive control (MPC) and dynamic programming algorithm (DP). However, due to the non-repeatability of driving conditions and the randomness of urban road traffic, the calculation of the optimal reference SOC is large and cannot be fully predicted. The setting of non-optimal reference SOC may deteriorate fuel economy. The second category is to perform online pattern recognition on the operating data, obtain the optimal control quantity through offline data mining, and use the Pontryagin minimum principle (PMP) or equivalent fuel consumption control strategy (ECMS) to calculate the instantaneous optimal solution to achieve adaptive control. The second method avoids the prediction of the reference SOC and adjusts the control parameters by table lookup, which further reduces the complexity of control under the premise of achieving adaptive control. Driving condition recognition is selected as the research object of pattern recognition. At present, the main methods of driving condition recognition are neural network, fuzzy controller and support vector machine recognition. The above methods all focus on different aspects, but none of them consider the inherent errors caused by the existence of the recognition cycle and the update cycle, which makes it impossible for the online recognition accuracy to reach a high level. Since the essence of the online recognition process is to analyze and process historical data to achieve the change of control variables, when the state changes, the recognition state quantity will have a certain delay relative to the real state quantity due to the existence of the recognition cycle and the update cycle. Summary of the invention
[0004] In view of the above-mentioned problems such as how to effectively improve the online recognition effect and improve fuel economy, the purpose of the embodiment of this application is to propose an IA-SVM driving condition recognition method and device based on LSTM speed prediction optimization to solve the technical problems mentioned in the above background technology part.
[0005] In a first aspect, an embodiment of the present application provides an IA-SVM driving condition identification method based on LSTM speed prediction optimization, comprising the following steps:
[0006] S1, obtaining historical vehicle operation data, preprocessing the historical vehicle operation data, and building a kinematic segment database, and obtaining driving condition online recognition training data based on the kinematic segment database;
[0007] S2, establishing a driving condition online recognition model based on the IA optimized SVM algorithm, training the driving condition online recognition model based on the IA optimized SVM algorithm through driving condition online recognition training data, and obtaining the driving condition online recognition model;
[0008] S3, establishing a speed prediction model based on LSTM, using the historical travel of the vehicle as speed prediction training data to train the speed prediction model based on LSTM, and obtaining a speed prediction model;
[0009] S4, obtain the vehicle operation data collected in real time, input it into the speed prediction model to predict the future speed sequence in real time, and splice the future speed sequence with the historical speed sequence to form an identification sequence, input the identification sequence into the driving condition online identification model to identify the vehicle driving condition.
[0010] In some embodiments, step S1 specifically includes:
[0011] S11, using a filtering and noise reduction algorithm to perform filtering and noise reduction processing on the vehicle operation data, and building a kinematic segment database, the kinematic segment database includes characteristic parameters of at least one kinematic segment, and constructing a characteristic parameter matrix based on the maximum driving speed, average driving speed, and idle time ratio of each kinematic segment;
[0012] S12, performing standardization processing on the characteristic parameter matrix to obtain a standardized characteristic parameter matrix;
[0013] S13, performing cluster analysis on the standardized characteristic parameter matrix by using a clustering algorithm to obtain typical driving conditions of different types of vehicles, and forming driving condition online recognition training data with the standardized characteristic parameter matrix and the typical driving conditions of different types of vehicles.
[0014] In some embodiments, the filtering noise reduction algorithm includes a seven-point quadratic filtering algorithm, and the clustering algorithm includes a PSO optimized k-means clustering algorithm.
[0015] In some embodiments, in step S2, during the training process of the online driving condition recognition model based on the IA optimized SVM algorithm, the IA algorithm is used for offline training iterative optimization to obtain the optimal penalty factor C and RBF kernel function width g in the corresponding SVM algorithm under different recognition cycles and update cycles, and the discriminant function is obtained by the Lagrange multiplier method, and the offline recognition accuracy is used as the fitness function.
[0016] In some embodiments, step S2 further includes determining the length of the optimal recognition cycle and update cycle of the driving condition online recognition model.
[0017] In some embodiments, the IA algorithm includes antigen recognition and antibody generation, antibody evaluation and immune evolution, wherein antigen recognition and antibody generation are to determine constraints, antibody evaluation functions and antibody encoding methods, and produce initial antibodies; antibody evaluation is achieved by calculating antibody affinity and concentration; immune evolution includes immune selection, variation, cloning, inhibition and refreshing populations.
[0018] In some embodiments, the LSTM-based speed prediction model in step S3 includes an input layer, a hidden layer, and an output layer. The relationship between the input layer, the hidden layer, and the output layer is refined into the relationship between the input gate, the forget gate, and the output gate:
[0019] f t =σ g (W f x t +U f h t-1 +b f );
[0020] i t =σ g (W i x t +U i h t-1 +b i );
[0021] o t =σ g (W o x t +U o h t-1 +b o );
[0022]
[0023]
[0024] h t =o t *tanh(C t );
[0025] Among them, σ g is the gate activation function, W f , W i , W o , W C is the weight matrix that maps the hidden layer input to the input gate, forget gate, and output gate; U f , U i, U o , U C is the weight matrix connecting the input gate, forget gate and output gate with the input unit state; b f 、b i 、b o 、b C is the deviation vector; C t is the cell input state, C t-1 Output status for the cell.
[0026] In some embodiments, before inputting the recognition sequence into the trained driving condition online recognition model in step S4, the process further includes: preprocessing the recognition sequence and converting it into a feature parameter matrix within an optimal recognition period.
[0027] In a second aspect, an embodiment of the present application provides an IA-SVM driving condition identification device based on LSTM speed prediction optimization, comprising:
[0028] A driving condition online recognition training data acquisition module is configured to acquire historical vehicle operation data, pre-process the historical vehicle operation data, and construct a kinematic segment database, and acquire driving condition online recognition training data based on the kinematic segment database;
[0029] A driving condition online recognition model building module is configured to build a driving condition online recognition model based on the IA optimized SVM algorithm, train the driving condition online recognition model based on the IA optimized SVM algorithm through driving condition online recognition training data, and obtain the driving condition online recognition model;
[0030] The speed prediction model building module is configured to build a speed prediction model based on LSTM, and train the speed prediction model based on LSTM using the historical travel of the vehicle as speed prediction training data to obtain a speed prediction model;
[0031] The vehicle driving condition recognition module is configured to obtain the vehicle operation data collected in real time, input the speed prediction model to predict the future speed sequence in real time, and splice the future speed sequence with the historical speed sequence to form an identification sequence, and input the identification sequence into the driving condition online recognition model to identify the vehicle driving condition.
[0032] In a third aspect, an embodiment of the present application provides a computer-readable storage medium having a computer program stored thereon, which, when executed by a processor, implements the method described in any implementation manner in the first aspect.
[0033] Compared with the prior art, the present invention has the following beneficial effects:
[0034] (1) The present invention uses an immune algorithm (IA) to optimize the support vector machine (SVM) algorithm, trains to obtain the penalty factor C and the RBF kernel function width g, and inputs them into the online recognition model of driving conditions to improve the accuracy of offline recognition. On this basis, in order to solve the problem that the recognition state quantity lags behind the actual state quantity when the mode is switched during the online recognition of the working condition, that is, the inherent error caused by the recognition window and the update window when the working condition type changes, an LSTM speed prediction model is established, and the future speed is added to the recognition sequence, which effectively reduces the inherent error and fully improves the online recognition effect.
[0035] (2) The present invention uses a characteristic parameter matrix composed of three characteristic parameters, namely, maximum driving speed, average driving speed, and idling time ratio, as input parameters of the driving condition online identification method. While fully considering the operating characteristics, the hardware requirements are not high, and the operating characteristics of urban buses are effectively reflected.
[0036] (3) The present invention can realize adaptive control under complex traffic conditions based on the online identification method of driving conditions, thereby improving the fuel economy of urban buses. BRIEF DESCRIPTION OF THE DRAWINGS
[0037] In order to more clearly illustrate the technical solutions in the embodiments of the present invention, the drawings required for use in the description of the embodiments will be briefly introduced below. Obviously, the drawings described below are only some embodiments of the present invention. For ordinary technicians in this field, other drawings can be obtained based on these drawings without paying creative work.
[0038] Figure 1 is an exemplary device architecture diagram to which an embodiment of the present application may be applied;
[0039] Figure 2 A flow chart of an IA-SVM driving condition identification method based on LSTM speed prediction optimization according to an embodiment of the present invention;
[0040] Figure 3 A schematic diagram of an IA-SVM driving condition identification method based on LSTM speed prediction optimization according to an embodiment of the present invention;
[0041] Figure 4 A schematic diagram of the implementation flow of the IA optimized SVM algorithm of the IA-SVM driving condition identification method based on LSTM speed prediction optimization in an embodiment of the present invention;
[0042] Figure 5 A schematic diagram of rolling recognition of the IA-SVM driving condition recognition method based on LSTM speed prediction optimization in an embodiment of the present invention;
[0043] Figure 6A test condition diagram of an update cycle and an identification cycle of an IA-SVM driving condition identification method based on LSTM speed prediction optimization according to an embodiment of the present invention;
[0044] Figure 7 A structural diagram of a speed prediction model based on LSTM of an IA-SVM driving condition identification method based on LSTM speed prediction optimization in an embodiment of the present invention;
[0045] Figure 8 A schematic diagram of splicing historical speed sequences and future speed sequences of the IA-SVM driving condition recognition method based on LSTM speed prediction optimization in an embodiment of the present invention;
[0046] Fig. 9 It is a No. 1 operating condition diagram for verifying the online recognition effect of the IA-SVM driving condition recognition method based on LSTM speed prediction optimization in an embodiment of the present invention;
[0047] Fig.10 It is a No. 2 operating condition diagram for verifying the online recognition effect of the IA-SVM driving condition recognition method based on LSTM speed prediction optimization in an embodiment of the present invention;
[0048] Fig.11 It is a schematic diagram of an IA-SVM driving condition identification device based on LSTM speed prediction optimization according to an embodiment of the present invention. DETAILED DESCRIPTION
[0049] In order to make the purpose, technical scheme and advantages of the present invention clearer, the present invention will be further described in detail below with reference to the accompanying drawings. Obviously, the described embodiments are only part of the embodiments of the present invention, rather than all the embodiments. Based on the embodiments of the present invention, all other embodiments obtained by ordinary technicians in this field without creative work are within the scope of protection of the present invention.
[0050] Figure 1 An exemplary device architecture 100 is shown to which the IA-SVM driving condition identification method based on LSTM speed prediction optimization or the IA-SVM driving condition identification device based on LSTM speed prediction optimization according to the embodiments of the present application can be applied.
[0051] like Figure 1 As shown, the device architecture 100 may include terminal devices 101, 102, 103, a network 104 and a server 105. The network 104 is used to provide a medium for communication links between the terminal devices 101, 102, 103 and the server 105. The network 104 may include various connection types, such as wired, wireless communication links or optical fiber cables, etc.
[0052] Users can use terminal devices 101, 102, 103 to interact with server 105 through network 104 to receive or send messages, etc. Various applications, such as data processing applications, file processing applications, etc., can be installed on terminal devices 101, 102, 103.
[0053] Terminal devices 101, 102, 103 can be hardware or software. When terminal devices 101, 102, 103 are hardware, they can be various electronic devices, including but not limited to smart phones, tablet computers, laptop computers, desktop computers, etc. When terminal devices 101, 102, 103 are software, they can be installed in the electronic devices listed above. They can be implemented as multiple software or software modules (for example, software or software modules for providing distributed services), or they can be implemented as a single software or software module. No specific limitation is made here.
[0054] The server 105 may be a server that provides various services, such as a background data processing server that processes files or data uploaded by the terminal devices 101, 102, and 103. The background data processing server may process the acquired files or data and generate processing results.
[0055] It should be noted that the IA-SVM driving condition identification method based on LSTM speed prediction optimization provided in the embodiment of the present application can be executed by the server 105, or by the terminal devices 101, 102, and 103. Accordingly, the IA-SVM driving condition identification device based on LSTM speed prediction optimization can be set in the server 105, or in the terminal devices 101, 102, and 103.
[0056] It should be understood that Figure 1 The number of terminal devices, networks and servers in the embodiment is only for illustration. Any number of terminal devices, networks and servers may be provided as required. In the case where the processed data does not need to be obtained remotely, the above device architecture may not include a network, but only a server or a terminal device.
[0057] The present invention takes a city bus as an example, and the technical solution of the present invention is specifically explained below.
[0058] Figure 2 An IA-SVM driving condition identification method based on LSTM speed prediction optimization provided by an embodiment of the present application is shown, comprising the following steps:
[0059] S1, obtaining historical vehicle operation data, preprocessing the historical vehicle operation data, and building a kinematic segment database, and obtaining driving condition online recognition training data based on the kinematic segment database.
[0060] In a specific embodiment, step S1 specifically includes:
[0061] S11, using a filtering and noise reduction algorithm to perform filtering and noise reduction processing on the vehicle operation data, and building a kinematic segment database, the kinematic segment database includes characteristic parameters of at least one kinematic segment, and constructing a characteristic parameter matrix based on the maximum driving speed, average driving speed, and idle time ratio of each kinematic segment;
[0062] S12, performing standardization processing on the characteristic parameter matrix to obtain a standardized characteristic parameter matrix;
[0063] S13, performing cluster analysis on the standardized characteristic parameter matrix by using a clustering algorithm to obtain typical driving conditions of different types of vehicles, and forming driving condition online recognition training data with the standardized characteristic parameter matrix and the typical driving conditions of different types of vehicles.
[0064] In a specific embodiment, reference Figure 3 , the historical operation data of the vehicle can be obtained from the Internet of Vehicles platform, and the seven-point quadratic filtering algorithm is used to filter and reduce the noise of the acquired historical operation data of the vehicle, effectively smooth the Internet of Vehicles data, and reduce the influence of noise during data acquisition. A kinematic segment database is built, and a characteristic parameter matrix is constructed with the three characteristic parameters of the maximum driving speed, average driving speed, and idle time ratio of each kinematic segment. In order to unify the dimensions, the characteristic parameter matrix corresponding to each kinematic segment is standardized and used as the training data of the online recognition model of the driving condition. The characteristic parameter matrix corresponding to the kinematic segment database is clustered and analyzed by the PSO optimized k-means clustering algorithm to obtain the three typical driving conditions of urban buses: congested traffic, medium-speed driving, and smooth traffic, and use this as the input parameter of several groups of training samples. In other embodiments, typical driving conditions can also be specifically divided according to actual conditions.
[0065] S2, establishing a driving condition online recognition model based on the IA optimized SVM algorithm, training the driving condition online recognition model based on the IA optimized SVM algorithm through driving condition online recognition training data, and obtaining the driving condition online recognition model.
[0066] In a specific embodiment, reference Figure 4In step S2, during the offline training of the IA optimized SVM algorithm, the optimal penalty factor C and RBF kernel function width g in the corresponding SVM algorithm under different recognition cycles and update cycles are obtained through the offline training iterative optimization process of the IA algorithm. Specifically, 80% of the kinematic segments are randomly selected from the kinematic segment database as training samples, and a driving condition recognition model is established to determine the optimal penalty factor C and RBF kernel function width g, which are 4.94 and 6.12 respectively. 1000 kinematic segments are randomly selected from the remaining 20% as test samples, and the offline recognition accuracy of the driving condition recognition model is 99.7%, which fully verifies the performance of the driving condition recognition model. In addition, the driving condition recognition model obtains the discriminant function through the Lagrange multiplier method, and uses the offline recognition accuracy as the fitness function to determine whether the termination condition of the IA algorithm is met.
[0067] Specifically, see Figure 5 The essence of online recognition of driving conditions is to use historical data as input, scroll through a sliding window, realize online recognition, and convert the state quantity obtained by recognition into control quantity through an update window. Therefore, it is particularly important to select a suitable recognition cycle ΔT and update cycle Δω. Therefore, step S2 also includes determining the length of the optimal recognition cycle and update cycle of the online recognition model of driving conditions.
[0068] In a specific embodiment, the IA algorithm includes antigen recognition and antibody generation, antibody evaluation and immune evolution, wherein antigen recognition and antibody generation are to determine constraints, antibody evaluation functions and antibody encoding methods, and generate initial antibodies; antibody evaluation is achieved by calculating antibody affinity and concentration; immune evolution includes immune selection, mutation, cloning, inhibition and refreshing population. The driving condition online recognition model is an IA-SVM algorithm based on the combination of the IA algorithm and the SVM algorithm. The kinematic fragments in the kinematic fragment database established in step S1 are historical speed sequences as the input of the entire IA-SVM algorithm. First, the IA algorithm parameters are set. The IA algorithm process includes antibody recognition, generating an initial population, immune selection, mutation, cloning, inhibition and refreshing population. The penalty factor C and the RBF kernel function width g can be determined when training the model. The IA algorithm updates the penalty factor C and the RBF kernel function width g. The SVM algorithm is tested using a test sample, the recognition accuracy is calculated, the fitness function and fitness are calculated based on the recognition accuracy, and it is determined whether the termination condition of the IA algorithm is met. If so, the optimal penalty factor C, kernel function parameter g and driving condition online recognition model are output.
[0069] refer to Figure 6, a one-way operating condition of a city bus was selected from the Internet of Vehicles platform as the online recognition test condition for the identification cycle and update cycle. At the same time, the operating condition with verified accuracy was used for offline recognition to obtain the real operating condition type. The sliding window length of 60s, 80s and 100s, and the update window length of 5s, 10s and 15s were selected for cross optimization. The results are shown in Table 1. Comprehensive analysis determined that the sliding window and update window lengths of the IA-SVM driving condition recognition model are 80s and 10s respectively.
[0070] Table 1
[0071]
[0072] S3, establish a speed prediction model based on LSTM, use the historical travel of the vehicle as speed prediction training data to train the speed prediction model based on LSTM, and obtain a speed prediction model.
[0073] In a specific embodiment, the speed prediction time domain length is determined and the training of the LSTM-based speed prediction model is completed.
[0074] In a specific embodiment, Figure 7 As shown, the LSTM-based speed prediction model in step S3 includes an input layer, a hidden layer, and an output layer. The relationship between the input layer, the hidden layer, and the output layer is refined into the relationship between the input gate, the forget gate, and the output gate:
[0075] f t =σ g (W f x t +U f h t-1 +b f );
[0076] i t =σ g (W i x t +U i h t-1 +b i );
[0077] o t =σ g (W o x t +U o h t-1 +b o );
[0078]
[0079]
[0080] h t =o t *tanh(C t );
[0081] Among them, σ g is the gate activation function, W f , W i , W o , W C is the weight matrix that maps the hidden layer input to the input gate, forget gate, and output gate; U f , U i , U o , U C is the weight matrix connecting the input gate, forget gate and output gate with the input unit state; b f 、b i 、b o 、b C is the deviation vector; C t is the cell input state, C t-1 The speed prediction model uses the LSTM algorithm, which takes the historical speed sequence of the vehicle in the historical journey as the input of the LSTM-based speed prediction model training, and outputs the future speed sequence.
[0082] In order to verify the performance of the speed prediction model, Figure 6 The test driving condition shown in the figure is used as the verification condition of the prediction model. The speed data of the past 20 seconds is used as the input data of the prediction model. 10 seconds, 15 seconds and 20 seconds are used as the prediction time domain respectively. The root mean square error (RMSE) is used as the error analysis standard. At the same time, the genetic algorithm optimized BP neural network (BPNN-GA) algorithm is selected as the comparison method. The results are shown in Table 2. According to the actual operation characteristics of urban buses, the speed prediction results are comprehensively analyzed, and the prediction time domain is selected as 15 seconds. Combined with the historical data of 65 seconds, it constitutes an 80-second recognition period.
[0083] Table 2
[0084]
[0085] S4, obtain the vehicle operation data collected in real time, input it into the speed prediction model to predict the future speed sequence in real time, and splice the future speed sequence with the historical speed sequence to form an identification sequence, input the identification sequence into the driving condition online identification model to identify the vehicle driving condition.
[0086] In a specific embodiment, before inputting the recognition sequence into the trained driving condition online recognition model in step S4, the process also includes: preprocessing the recognition sequence and converting it into a feature parameter matrix within the optimal recognition period. Based on the IA-SVM driving condition online recognition model, the future speed sequence is predicted by the LSTM speed prediction model, and the future speed sequence is added to the recognition sequence, such as Figure 8 As shown in the figure, the historical speed sequence is obtained based on the vehicle operation data collected in real time, and the future speed sequence is spliced with the historical speed sequence to reduce the inherent error caused by the recognition window and the update window in the time dimension, effectively improving the online recognition accuracy. Subsequently, it is combined with the optimization control strategy to achieve adaptive control in complex traffic environments.
[0087] In order to further verify the effectiveness of the driving condition identification method based on LSTM speed prediction optimization IA-SVM of the present invention and compare the performance improvement effect of the IA-SVM driving condition identification method, this example applies the IA-SVM driving condition identification method based on LSTM speed prediction optimization to two actual urban bus operating conditions, such as Fig. 9 and Fig.10 The figures are respectively used for verifying the online recognition effect under working condition 1 and working condition 2. The online recognition accuracy is shown in Table 3.
[0088] Table 3
[0089]
[0090]
[0091] Under the IA-SVM driving condition recognition method based on LSTM speed prediction optimization, the online recognition accuracy of bus driving conditions is significantly improved, and the subsequent combination with the adaptive control strategy can effectively improve the fuel economy of urban buses. The present invention fully reflects the driving characteristics and effectively improves the online recognition accuracy.
[0092] Further references Fig.11 As an implementation of the methods shown in the above figures, the present application provides an embodiment of an IA-SVM driving condition identification device based on LSTM speed prediction optimization. Figure 2 Corresponding to the method embodiment shown, the device can be specifically applied to various electronic devices.
[0093] The embodiment of the present application provides an IA-SVM driving condition identification device based on LSTM speed prediction optimization, comprising:
[0094] The driving condition online recognition training data acquisition module 1 is configured to acquire historical vehicle operation data, pre-process the historical vehicle operation data, and construct a kinematic segment database, and acquire driving condition online recognition training data based on the kinematic segment database;
[0095] The driving condition online recognition model building module 2 is configured to build a driving condition online recognition model based on the IA optimized SVM algorithm, train the driving condition online recognition model based on the IA optimized SVM algorithm through driving condition online recognition training data, and obtain the driving condition online recognition model;
[0096] The speed prediction model building module 3 is configured to build a speed prediction model based on LSTM, and train the speed prediction model based on LSTM using the historical travel of the vehicle as speed prediction training data to obtain a speed prediction model;
[0097] The vehicle driving condition recognition module 4 is configured to obtain the vehicle operation data collected in real time, input the speed prediction model to predict the future speed sequence in real time, and splice the future speed sequence with the historical speed sequence to form an identification sequence, and input the identification sequence into the driving condition online recognition model to identify the vehicle driving condition.
[0098] The following provides electronic devices (such as Figure 1 The electronic device is only an example and should not bring any limitation to the functions and scope of use of the embodiments of the present application.
[0099] The computer device includes a central processing unit (CPU) and a graphics processing unit (GPU), which can perform various appropriate actions and processes according to the program stored in the read-only memory (ROM) or the program loaded from the storage part into the random access memory (RAM). In the RAM, various programs and data required for the operation of the device are also stored. The CPU, GPU, ROM and RAM are connected to each other through a bus. The input / output (I / O) interface is also connected to the bus.
[0100] The following components are connected to the I / O interface: an input part including a keyboard, a mouse, etc.; an output part including a display such as a liquid crystal display (LCD), etc. and a speaker, etc.; a storage part including a hard disk, etc.; and a communication part including a network interface card such as a LAN card, a modem, etc. The communication part performs communication processing via a network such as the Internet. A drive can also be connected to the I / O interface as needed. Removable media, such as a magnetic disk, an optical disk, a magneto-optical disk, a semiconductor memory, etc., are installed on the drive as needed so that a computer program read therefrom is installed into the storage part as needed.
[0101] In particular, according to an embodiment of the present disclosure, the process described above with reference to the flowchart can be implemented as a computer software program. For example, an embodiment of the present disclosure includes a computer program product, which includes a computer program carried on a computer-readable medium, and the computer program includes a program code for executing the method shown in the flowchart. In such an embodiment, the computer program can be downloaded and installed from a network through a communication part, and / or installed from a removable medium. When the computer program is executed by a central processing unit (CPU) and a graphics processing unit (GPU), the above-mentioned functions defined in the method of the present application are executed.
[0102] It should be noted that the computer-readable medium described in the present application may be a computer-readable signal medium or a computer-readable medium or any combination of the above two. The computer-readable medium may be, for example, but not limited to, an electrical, magnetic, optical, electromagnetic, infrared, or semiconductor device, device or component, or any combination of the above. More specific examples of computer-readable media may include, but are not limited to: an electrical connection with one or more wires, a portable computer disk, a hard disk, a random access memory (RAM), a read-only memory (ROM), an erasable programmable read-only memory (EPROM or flash memory), an optical fiber, a portable compact disk read-only memory (CD-ROM), an optical storage device, a magnetic storage device, or any suitable combination of the above. In the present application, a computer-readable medium may be any tangible medium containing or storing a program that can be used by or in combination with an instruction execution device, device or device. In the present application, a computer-readable signal medium may include a data signal propagated in a baseband or as part of a carrier wave, which carries a computer-readable program code. This propagated data signal may take a variety of forms, including but not limited to electromagnetic signals, optical signals, or any suitable combination of the above. The computer-readable signal medium may also be any computer-readable medium other than a computer-readable medium that can send, propagate or transmit a program for use by or in conjunction with an instruction execution device, apparatus or device. The program code contained on the computer-readable medium may be transmitted using any appropriate medium, including but not limited to: wireless, wire, optical cable, RF, etc., or any suitable combination of the above.
[0103] Computer program code for performing the operations of the present application may be written in one or more programming languages or a combination thereof, including object-oriented programming languages, such as Java, Smalltalk, C++, and conventional procedural programming languages, such as "C" or similar programming languages. The program code may be executed entirely on the user's computer, partially on the user's computer, as a separate software package, partially on the user's computer and partially on a remote computer, or entirely on a remote computer or server. In the case of a remote computer, the remote computer may be connected to the user's computer through any type of network, including a local area network (LAN) or a wide area network (WAN), or may be connected to an external computer (e.g., via the Internet using an Internet service provider).
[0104] The flow chart and block diagram in the accompanying drawings illustrate the possible architecture, function and operation of the device, method and computer program product according to various embodiments of the present application. In this regard, each box in the flow chart or block diagram can represent a module, a program segment or a part of a code, and the module, the program segment or a part of the code contains one or more executable instructions for realizing the specified logical function. It should also be noted that in some alternative implementations, the functions marked in the box can also occur in a different order from the order marked in the accompanying drawings. For example, two boxes represented in succession can actually be executed substantially in parallel, and they can sometimes be executed in the opposite order, depending on the functions involved. It should also be noted that each box in the block diagram and / or flow chart, and the combination of the boxes in the block diagram and / or flow chart can be implemented with a dedicated hardware-based device that performs a specified function or operation, or can be implemented with a combination of dedicated hardware and computer instructions.
[0105] The modules involved in the embodiments described in this application may be implemented by software or hardware, and the modules described may also be set in a processor.
[0106] As another aspect, the present application also provides a computer-readable medium, which may be included in the electronic device described in the above embodiment; or it may exist independently and not be assembled into the electronic device. The above computer-readable medium carries one or more programs. When the above one or more programs are executed by the electronic device, the electronic device: obtains the historical operation data of the vehicle, pre-processes the historical operation data of the vehicle, and constructs a kinematic segment database, and obtains the online recognition training data of the driving condition based on the kinematic segment database; establishes an online recognition model of the driving condition based on the IA optimized SVM algorithm, and trains the online recognition model of the driving condition based on the IA optimized SVM algorithm through the online recognition training data of the driving condition to obtain the online recognition model of the driving condition; establishes a speed prediction model based on LSTM, and trains the speed prediction model based on LSTM with the historical travel of the vehicle as the speed prediction training data to obtain the speed prediction model; obtains the vehicle operation data collected in real time, inputs the speed prediction model into the real-time prediction to obtain the future speed sequence, and splices the future speed sequence with the historical speed sequence to form a recognition sequence, and inputs the recognition sequence into the online recognition model of the driving condition to identify the vehicle driving condition.
[0107] The above description is only a preferred embodiment of the present application and an explanation of the technical principles used. Those skilled in the art should understand that the scope of the invention involved in the present application is not limited to the technical solution formed by a specific combination of the above technical features, but should also cover other technical solutions formed by any combination of the above technical features or their equivalent features without departing from the above invention concept. For example, the above features are replaced with the technical features with similar functions disclosed in this application (but not limited to) by each other to form a technical solution.
Claims
1. A driving condition recognition method based on IA-SVM with LSTM speed prediction optimization, characterized in that: The following steps are involved: S1, acquiring historical vehicle operation data, preprocessing the historical vehicle operation data, and constructing a kinematic segment database, and acquiring driving condition online recognition training data based on the kinematic segment database; S2, establishing an online driving condition recognition model based on the IA optimized SVM algorithm, training the online driving condition recognition model based on the IA optimized SVM algorithm through the online driving condition recognition training data, and obtaining the online driving condition recognition model, wherein in the training process of the online driving condition recognition model based on the IA optimized SVM algorithm, the IA algorithm offline training iterative optimization process is used to obtain the optimal penalty factor C and RBF kernel function width g in the SVM algorithm under different recognition cycles and update cycles, the discriminant function is obtained through the Lagrange multiplier method, and the offline recognition accuracy is used as the fitness function; S3, establish a speed prediction model based on LSTM, and train the speed prediction model based on LSTM using the historical travel of the vehicle as speed prediction training data to obtain a speed prediction model, wherein the speed prediction model based on LSTM includes an input layer, a hidden layer, and an output layer, and the relationship between the input layer, the hidden layer, and the output layer is refined into the relationship between an input gate, a forget gate, and an output gate: f t =σ g (W f x t +U f h t-1 +b f ); i t =σ g (W i x t +U i h t-1 +b i ); the t =s g (W o x t +U o h t-1 +b o ); h t =o t *tanh(C t ); Among them, σ g is the gate activation function, W f , W i , W o , W C is the weight matrix that maps the hidden layer input to the input gate, forget gate, and output gate; U f , U i , U o , U C is the weight matrix connecting the input gate, forget gate and output gate with the input unit state; b f , b i , b o , b C is the deviation vector; C t is the cell input state, C t-1 Output status for cells; S4, obtaining the vehicle operation data collected in real time, inputting the data into the speed prediction model to predict the future speed sequence in real time, and splicing the future speed sequence with the historical speed sequence to form an identification sequence, and inputting the identification sequence into the driving condition online identification model to identify the vehicle driving condition.
2. The IA-SVM driving condition identification method based on LSTM speed prediction optimization according to claim 1 is characterized in that: The step S1 specifically includes: S11, performing filtering and noise reduction processing on the vehicle operation data using a filtering and noise reduction algorithm, and building the kinematic segment database, wherein the kinematic segment database includes characteristic parameters of at least one kinematic segment, and constructing a characteristic parameter matrix based on the maximum driving speed, average driving speed, and idle time ratio of each kinematic segment; S12, performing standardization processing on the characteristic parameter matrix to obtain a standardized characteristic parameter matrix; S13, performing cluster analysis on the standardized characteristic parameter matrix by a clustering algorithm to obtain typical driving conditions of different types of vehicles, and combining the standardized characteristic parameter matrix and the typical driving conditions of different types of vehicles to form the driving condition online recognition training data.
3. The IA-SVM driving condition identification method based on LSTM speed prediction optimization according to claim 2 is characterized in that: The filtering noise reduction algorithm includes a seven-point quadratic filtering algorithm, and the clustering algorithm includes a PSO optimized k-means clustering algorithm.
4. The IA-SVM driving condition identification method based on LSTM speed prediction optimization according to claim 1 is characterized in that: The step S2 also includes determining the length of the optimal recognition cycle and update cycle of the driving condition online recognition model.
5. The IA-SVM driving condition identification method based on LSTM speed prediction optimization according to claim 1 is characterized in that: The IA algorithm includes antigen recognition and antibody generation, antibody evaluation and immune evolution, wherein the antigen recognition and antibody generation are to determine constraints, antibody evaluation functions and antibody encoding methods, and generate initial antibodies; The antibody evaluation is achieved by calculating antibody affinity and concentration; the immune evolution includes immune selection, variation, cloning, inhibition and refreshing population.
6. The IA-SVM driving condition identification method based on LSTM speed prediction optimization according to claim 4 is characterized in that: Before inputting the recognition sequence into the trained driving condition online recognition model in step S4, the method further includes: preprocessing the recognition sequence and converting it into a feature parameter matrix within an optimal recognition period.
7. An IA-SVM driving condition recognition device based on LSTM speed prediction optimization, characterized in that: include: A driving condition online recognition training data acquisition module is configured to acquire vehicle historical operation data, pre-process the vehicle historical operation data, and construct a kinematic segment database, and acquire driving condition online recognition training data based on the kinematic segment database; A driving condition online recognition model establishment module is configured to establish a driving condition online recognition model based on an IA optimized SVM algorithm, train the driving condition online recognition model based on the IA optimized SVM algorithm through the driving condition online recognition training data, and obtain the driving condition online recognition model. In the driving condition online recognition model establishment module, during the training process of the driving condition online recognition model based on the IA optimized SVM algorithm, the IA algorithm offline training iterative optimization process is used to obtain the optimal penalty factor C and RBF kernel function width g in the SVM algorithm under different recognition cycles and update cycles, and the discriminant function is obtained through the Lagrange multiplier method, and the offline recognition accuracy is used as the fitness function; The speed prediction model establishment module is configured to establish a speed prediction model based on LSTM, and train the speed prediction model based on LSTM using the historical travel of the vehicle as speed prediction training data to obtain a speed prediction model. The speed prediction model based on LSTM includes an input layer, a hidden layer, and an output layer. The relationship between the input layer, the hidden layer, and the output layer is refined into the relationship between an input gate, a forget gate, and an output gate: f t =σ g (W f x t +U f h t-1 +b f ); i t =σ g (W i x t +U i h t-1 +b i ); the t =s g (W o x t +U o h t-1 +b o ); h t =o t *tanh(C t ); Among them, σ g is the gate activation function, W f , W i , W o , W C is the weight matrix that maps the hidden layer input to the input gate, forget gate, and output gate; U f , U i , U o , U C is the weight matrix connecting the input gate, forget gate and output gate with the input unit state; b f , b i , b o , b C is the deviation vector; C t is the cell input state, C t-1 Output status for cells; The vehicle driving condition recognition module is configured to obtain the vehicle operation data collected in real time, input the speed prediction model to predict the future speed sequence in real time, and splice the future speed sequence with the historical speed sequence to form an identification sequence, and input the identification sequence into the driving condition online recognition model to identify the vehicle driving condition.
8. A computer-readable storage medium having a computer program stored thereon, characterized in that: When the program is executed by a processor, the method according to any one of claims 1 to 6 is implemented.
