CN115422820B - Federal learning model training method applied to road condition prediction and road condition prediction method - Google Patents

Federal learning model training method applied to road condition prediction and road condition prediction method Download PDF

Info

Publication number
CN115422820B
CN115422820B CN202210622132.2A CN202210622132A CN115422820B CN 115422820 B CN115422820 B CN 115422820B CN 202210622132 A CN202210622132 A CN 202210622132A CN 115422820 B CN115422820 B CN 115422820B
Authority
CN
China
Prior art keywords
accident
model
vehicle
model parameters
vehicle terminal
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Active
Application number
CN202210622132.2A
Other languages
Chinese (zh)
Other versions
CN115422820A (en
Inventor
郭敬达
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Guoqi Intelligent Control Beijing Technology Co Ltd
Original Assignee
Guoqi Intelligent Control Beijing Technology Co Ltd
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Guoqi Intelligent Control Beijing Technology Co Ltd filed Critical Guoqi Intelligent Control Beijing Technology Co Ltd
Priority to CN202210622132.2A priority Critical patent/CN115422820B/en
Publication of CN115422820A publication Critical patent/CN115422820A/en
Application granted granted Critical
Publication of CN115422820B publication Critical patent/CN115422820B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F30/00Computer-aided design [CAD]
    • G06F30/20Design optimisation, verification or simulation
    • G06F30/27Design optimisation, verification or simulation using machine learning, e.g. artificial intelligence, neural networks, support vector machines [SVM] or training a model
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F2119/00Details relating to the type or aim of the analysis or the optimisation
    • G06F2119/02Reliability analysis or reliability optimisation; Failure analysis, e.g. worst case scenario performance, failure mode and effects analysis [FMEA]

Abstract

The application provides a federal learning model training method and a road condition prediction method applied to predicting road conditions, which relate to a distributed model training technology, and the method comprises the following steps: and sending the preset initial global model to each vehicle terminal in the N vehicle terminals. Receiving local model parameters sent by each vehicle terminal; the local model parameters transmitted by each of the M vehicle terminals of the N vehicle terminals include a safety model parameter and an accident model parameter; the local model parameters transmitted by each of the N-M vehicle terminals of the N vehicle terminals include security model parameters. According to local model parameters sent by each vehicle terminal in the N vehicle terminals, updating a preset initial global model to obtain a target driving model; the target travel model is transmitted to each of the N vehicle terminals. The method solves the problem of lower accuracy of model prediction of the road conditions in front due to the fact that updating of the model is delayed from running data of the vehicle.

Description

Federal learning model training method applied to road condition prediction and road condition prediction method
Technical Field
The application relates to a distributed model training technology, in particular to a federal learning model training method and a road condition prediction method applied to road condition prediction.
Background
Currently, in federal learning schemes regarding automatic driving, automatic driving needs to be implemented according to a target driving model of a vehicle terminal, wherein the target driving model is obtained according to driving data of the vehicle terminal.
In the prior art, when a target running model of a vehicle is trained and acquired, local model parameters of a vehicle terminal which is trained locally are generally acquired, and then the local model parameters are subjected to aggregation processing to obtain the target running model, so that the target running model is updated to each vehicle terminal.
However, in the prior art, when the local model parameters are aggregated to obtain the target running model, the local model parameters involved in the aggregation include parameters obtained according to the running data of long time, so that the updating of the target running model is very delayed from the running data change of the vehicle terminal, and the accuracy of predicting the road condition in front of the vehicle by the target running model is lower.
Disclosure of Invention
The application provides a federal learning model training method and a road condition prediction method applied to predicting road conditions, which are used for solving the technical problem of lower accuracy of predicting road conditions in front of a model due to the fact that updating of the model is delayed from running data of a vehicle.
In a first aspect, the present application provides a federal learning model training method for predicting road conditions, the method being applied to a server, the method comprising:
transmitting a preset initial global model to each of the N vehicle terminals; the preset initial global model is used for determining a local model of the vehicle terminal, and N is a positive integer greater than 1;
receiving local model parameters sent by each vehicle terminal; the local model parameters sent by each of M vehicle terminals in the N vehicle terminals comprise a safety model parameter and an accident model parameter; the local model parameters sent by each of N-M vehicle terminals in the N vehicle terminals comprise security model parameters; m is a positive integer greater than or equal to 1 and less than or equal to N; the safety model parameters are obtained by training a local model in the vehicle terminal based on the acquired vehicle running data corresponding to the vehicle terminal by the vehicle terminal; the accident model parameters are obtained by training a local model in the vehicle terminal based on the acquired vehicle accident data corresponding to the vehicle terminal by the vehicle terminal;
Updating the preset initial global model according to local model parameters sent by each vehicle terminal in the N vehicle terminals to obtain a target running model; and transmitting the target running model to each of the N vehicle terminals, wherein the target running model is used for predicting the road condition in front of the vehicle terminal.
Further, updating the preset initial global model according to the local model parameters sent by each vehicle terminal in the N vehicle terminals to obtain a target driving model, including:
integrating the M accident model parameters fed back by the M vehicle terminals to obtain integrated accident model parameters; the integrated accident model parameters represent model parameters after training the local model by respective vehicle accident data of the M vehicle terminals;
and updating the preset initial global model according to the safety model parameters sent by each vehicle terminal in the N vehicle terminals and the integrated accident model parameters to obtain a target running model.
Further, updating the preset initial global model according to the safety model parameters sent by each vehicle terminal in the N vehicle terminals and the integrated accident model parameters to obtain a target running model, including:
Determining a weight value corresponding to the safety model parameter and a weight value corresponding to the integrated accident model parameter according to a first preset corresponding relation; the first preset corresponding relation is a corresponding relation between model parameters and weight values;
according to the weight value corresponding to the safety model parameter and the weight value corresponding to the integrated accident model parameter, carrying out aggregation treatment on the safety model parameter and the integrated accident model parameter to obtain an aggregation model;
and updating the preset initial global model according to the aggregation model to obtain a target running model.
Further, integrating the M accident model parameters fed back by the M vehicle terminals to obtain integrated accident model parameters, including:
summing the M accident model parameters fed back by the M vehicle terminals to obtain a parameter sum;
integrating the parameter sum and the M accident model parameters to obtain integrated accident model parameters; wherein the integration process is to divide the parameter sum by M.
Further, the accident model parameters include an accident tag for indicating an accident type; integrating the M accident model parameters fed back by the M vehicle terminals to obtain integrated accident model parameters, wherein the integrated accident model parameters comprise:
According to a preset target accident type, determining accident model parameters corresponding to the target accident type from M accident model parameters fed back by the M vehicle terminals;
and integrating the accident model parameters corresponding to the target accident types to obtain integrated accident model parameters.
Further, the accident model parameters include an accident tag for indicating an accident type; integrating the M accident model parameters fed back by the M vehicle terminals to obtain integrated accident model parameters, wherein the integrated accident model parameters comprise:
determining a weight value corresponding to each accident tag according to the second preset corresponding relation; the second preset corresponding relation is a corresponding relation between the accident label and the weight value;
and integrating the M accident model parameters fed back by the M vehicle terminals according to the accident labels respectively included by the M accident model parameters fed back by the M vehicle terminals and the weight values corresponding to the accident labels to obtain the integrated accident model parameters.
Further, when the target running model is obtained, a preset condition is reached;
the preset conditions are that the preset repeated execution times are reached or an initial global model preset after updating reaches a convergence state.
Further, the vehicle travel data includes one or more of the following: brake data, throttle data and steering chassis data;
the vehicle accident data includes one or more of the following: airbag ejection data of the vehicle terminal, collision data acquired by a sensor of the vehicle terminal, vehicle running data of the vehicle terminal in a preset time period before an accident occurs, and accident model parameters of the vehicle terminal.
In a second aspect, the present application provides a federal learning model training method for predicting road conditions, the method being applied to a vehicle terminal, the method comprising:
receiving a preset initial global model sent by a server, and determining a local model according to the preset initial global model, wherein N is a positive integer greater than 1;
training the local model in the vehicle terminal based on the acquired vehicle running data corresponding to the vehicle terminal and obtaining safety model parameters; training the local model in the vehicle terminal based on the acquired vehicle accident data corresponding to the vehicle terminal and obtaining accident model parameters;
transmitting the security model parameters and the accident model parameters to a server; the local model parameters sent by each of M vehicle terminals in the N vehicle terminals comprise a safety model parameter and an accident model parameter; the local model parameters sent by each of N-M vehicle terminals in the N vehicle terminals comprise security model parameters; m is a positive integer greater than or equal to 1 and less than or equal to N; the local model parameters sent by each vehicle terminal in the N vehicle terminals are used for obtaining a target running model after updating the preset initial global model;
Receiving the target driving model sent by a server; the target driving model is used for predicting the front road condition of the vehicle terminal.
Further, the accident model parameters comprise accident labels, and the accident labels are used for indicating accident types; the accident tag is used for determining integrated accident model parameters;
the integrated accident model parameters are obtained according to the accident model parameters corresponding to the target accident types, and the accident model parameters corresponding to the target accident types are obtained from M accident model parameters fed back by the M vehicle terminals according to the preset target accident types;
or, the integrated accident model parameters are obtained by integrating the M accident model parameters fed back by the M vehicle terminals according to the accident labels respectively included in the M accident model parameters fed back by the M vehicle terminals and the weight values corresponding to the accident labels, and the weight values corresponding to the accident labels are obtained according to a second preset corresponding relation, wherein the second preset corresponding relation is a corresponding relation between the accident labels and the weight values.
Further, the vehicle travel data includes one or more of the following: brake data, throttle data and steering chassis data;
the vehicle accident data includes one or more of the following: airbag ejection data of the vehicle terminal, collision data acquired by a sensor of the vehicle terminal, vehicle running data of the vehicle terminal in a preset time period before an accident occurs, and accident model parameters of the vehicle terminal.
In a third aspect, the present application provides a road condition prediction method based on a federal learning model, where the method is applied to a vehicle terminal, and the method includes:
acquiring actual running data of a vehicle, and inputting the actual running data into a target running model to obtain a front road condition;
wherein the target running model is the target running model according to the first aspect, or the target running model according to the second aspect.
In a fourth aspect, the present application provides a federal learning model training apparatus for predicting road conditions, the apparatus being applied to a server, the apparatus comprising:
the acquisition unit is used for transmitting the preset initial global model to each vehicle terminal in the N vehicle terminals; the preset initial global model is used for determining a local model of the vehicle terminal, and N is a positive integer greater than 1;
The receiving unit is used for receiving the local model parameters sent by each vehicle terminal; the local model parameters sent by each of M vehicle terminals in the N vehicle terminals comprise a safety model parameter and an accident model parameter; the local model parameters sent by each of N-M vehicle terminals in the N vehicle terminals comprise security model parameters; m is a positive integer greater than or equal to 1 and less than or equal to N; the safety model parameters are obtained by training a local model in the vehicle terminal based on the acquired vehicle running data corresponding to the vehicle terminal by the vehicle terminal; the accident model parameters are obtained by training a local model in the vehicle terminal based on the acquired vehicle accident data corresponding to the vehicle terminal by the vehicle terminal;
the updating unit is used for updating the preset initial global model according to the local model parameters sent by each vehicle terminal in the N vehicle terminals to obtain a target running model;
and the transmitting unit is used for transmitting the target running model to each of the N vehicle terminals, wherein the target running model is used for predicting the road condition in front of the vehicle terminal.
Further, the updating unit includes:
the integration module is used for integrating the M accident model parameters fed back by the M vehicle terminals to obtain integrated accident model parameters; the integrated accident model parameters represent model parameters after training the local model by respective vehicle accident data of the M vehicle terminals;
and the updating module is used for updating the preset initial global model according to the safety model parameters sent by each vehicle terminal in the N vehicle terminals and the integrated accident model parameters to obtain a target running model.
Further, the updating module includes:
the first determining submodule is used for determining a weight value corresponding to the safety model parameter and a weight value corresponding to the integrated accident model parameter according to a first preset corresponding relation; the first preset corresponding relation is a corresponding relation between model parameters and weight values;
the aggregation sub-module is used for conducting aggregation treatment on the safety model parameters and the integrated accident model parameters according to the weight values corresponding to the safety model parameters and the weight values corresponding to the integrated accident model parameters to obtain an aggregation model;
And the updating sub-module is used for updating the preset initial global model according to the aggregation model to obtain a target running model.
Further, the integration module includes:
the summation sub-module is used for carrying out summation processing on M accident model parameters fed back by the M vehicle terminals to obtain parameter summation;
the first integration submodule is used for integrating the parameter sum and the M accident model parameters to obtain integrated accident model parameters; wherein the integration process is to divide the parameter sum by M.
Further, the accident model parameters include an accident tag for indicating an accident type; the integration module comprises:
the second determining submodule is used for determining accident model parameters corresponding to the target accident types from M accident model parameters fed back by the M vehicle terminals according to the preset target accident types;
and the second integration sub-module is used for integrating the accident model parameters corresponding to the target accident type to obtain integrated accident model parameters.
Further, the accident model parameters include an accident tag for indicating an accident type; the integration module comprises:
The third determining submodule is used for determining a weight value corresponding to each accident tag according to the second preset corresponding relation; the second preset corresponding relation is a corresponding relation between the accident label and the weight value;
and the third integration sub-module is used for integrating the M accident model parameters fed back by the M vehicle terminals according to the accident labels respectively included by the M accident model parameters fed back by the M vehicle terminals and the weight values corresponding to the accident labels to obtain the integrated accident model parameters.
Further, when the target running model is obtained, a preset condition is reached;
the preset conditions are that the preset repeated execution times are reached or an initial global model preset after updating reaches a convergence state.
Further, the vehicle travel data includes one or more of the following: brake data, throttle data and steering chassis data;
the vehicle accident data includes one or more of the following: airbag ejection data of the vehicle terminal, collision data acquired by a sensor of the vehicle terminal, vehicle running data of the vehicle terminal in a preset time period before an accident occurs, and accident model parameters of the vehicle terminal.
In a fifth aspect, the present application provides a federal learning model training apparatus for predicting road conditions, the apparatus being applied to a vehicle terminal, the apparatus comprising:
the receiving unit is used for receiving a preset initial global model sent by the server;
the determining unit is used for determining a local model according to the preset initial global model, wherein N is a positive integer greater than 1;
the training unit is used for training the local model in the vehicle terminal and obtaining safety model parameters based on the acquired vehicle running data corresponding to the vehicle terminal; training the local model in the vehicle terminal based on the acquired vehicle accident data corresponding to the vehicle terminal and obtaining accident model parameters;
the sending unit is used for sending the safety model parameters and the accident model parameters to a server; the local model parameters sent by each of M vehicle terminals in the N vehicle terminals comprise a safety model parameter and an accident model parameter; the local model parameters sent by each of N-M vehicle terminals in the N vehicle terminals comprise security model parameters; m is a positive integer greater than or equal to 1 and less than or equal to N; the local model parameters sent by each vehicle terminal in the N vehicle terminals are used for obtaining a target running model after updating the preset initial global model;
The receiving unit is used for receiving the target running model sent by the server; the target driving model is used for predicting the front road condition of the vehicle terminal.
Further, the accident model parameters comprise accident labels, and the accident labels are used for indicating accident types; the accident tag is used for determining integrated accident model parameters;
the integrated accident model parameters are obtained according to the accident model parameters corresponding to the target accident types, and the accident model parameters corresponding to the target accident types are obtained from M accident model parameters fed back by the M vehicle terminals according to the preset target accident types;
or, the integrated accident model parameters are obtained by integrating the M accident model parameters fed back by the M vehicle terminals according to the accident labels respectively included in the M accident model parameters fed back by the M vehicle terminals and the weight values corresponding to the accident labels, and the weight values corresponding to the accident labels are obtained according to a second preset corresponding relation, wherein the second preset corresponding relation is a corresponding relation between the accident labels and the weight values.
Further, the vehicle travel data includes one or more of the following: brake data, throttle data and steering chassis data;
the vehicle accident data includes one or more of the following: airbag ejection data of the vehicle terminal, collision data acquired by a sensor of the vehicle terminal, vehicle running data of the vehicle terminal in a preset time period before an accident occurs, and accident model parameters of the vehicle terminal.
In a sixth aspect, the present application provides a server, including a memory, and a processor, where the memory stores a computer program that can be executed on the processor, where the processor implements the method described in the first aspect, or implements the method described in the second aspect, or implements the method described in the third aspect.
In a seventh aspect, the present application provides a vehicle terminal, including a memory, and a processor, where the memory stores a computer program that can be executed on the processor, where the processor implements the method described in the first aspect, or implements the method described in the second aspect, or implements the method described in the third aspect.
In an eighth aspect, the present application provides a federal learning model system for predicting road conditions, the system comprising a server according to the sixth aspect and at least one vehicle terminal according to the seventh aspect.
In a ninth aspect, the present application provides a computer-readable storage medium having stored therein computer-executable instructions for implementing the method according to the first aspect, or implementing the method according to the second aspect, or implementing the method according to the third aspect.
In a tenth aspect, the application provides a computer program product comprising a computer program which, when executed by a processor, implements the method of the first aspect, or implements the method of the second aspect, or implements the method of the third aspect.
The application provides a federal learning model training method and a road condition prediction method applied to predicting road conditions, which are used for sending a preset initial global model to each of N vehicle terminals; the method comprises the steps of determining a local model of a vehicle terminal by a preset initial global model, wherein N is a positive integer greater than 1. Receiving local model parameters sent by each vehicle terminal; the local model parameters sent by each of M vehicle terminals in the N vehicle terminals comprise a safety model parameter and an accident model parameter; the local model parameters transmitted by each of the N-M vehicle terminals of the N vehicle terminals comprise security model parameters; m is a positive integer greater than or equal to 1 and less than or equal to N; the safety model parameters are obtained by training a local model in the vehicle terminal based on the acquired vehicle running data corresponding to the vehicle terminal by the vehicle terminal; the accident model parameters are obtained by the vehicle terminal training the local model in the vehicle terminal based on the obtained vehicle accident data corresponding to the vehicle terminal. According to local model parameters sent by each vehicle terminal in the N vehicle terminals, updating a preset initial global model to obtain a target driving model; and transmitting a target traveling model to each of the N vehicle terminals, wherein the target traveling model is used for predicting the road condition ahead of the vehicle terminal. In the scheme, a preset initial global model is sent to each of N vehicle terminals, after each vehicle terminal receives the initial global model, a local model corresponding to the vehicle terminal can be determined according to the initial global model, the local model in the vehicle terminal is trained according to acquired vehicle accident data corresponding to the vehicle terminal to obtain accident model parameters, the local model in the vehicle terminal is trained according to the acquired vehicle running data corresponding to the vehicle terminal to obtain safety model parameters, and the accident model parameters and the safety model parameters are local model parameters of the vehicle terminal. And then the accident model parameters and the safety model parameters are sent to a server, the accident model parameters and the safety model parameters are received by the server, and a preset initial global model is updated according to the accident model parameters and the safety model parameters sent by each vehicle terminal in the N vehicle terminals, so that a target running model is obtained. And finally, the target running model is sent to each vehicle terminal in the N vehicle terminals, and then the vehicle terminals can predict the road conditions in front of the vehicle terminals according to the target running model in the running process.
Therefore, the target running model is updated in time along with the vehicle accident data of the vehicle and the change of the vehicle running data by receiving the local model parameters obtained by local training of each vehicle terminal and obtaining the target running model according to the plurality of local model parameters, so that the target running model obtained by final training can be sensitive to accidents, the accuracy of predicting the road condition in front of the target running model is greatly improved, and the technical problem that the accuracy of predicting the road condition in front of the model is lower due to the fact that the model is updated later than the running data of the vehicle is solved.
Drawings
The accompanying drawings, which are incorporated in and constitute a part of this specification, illustrate embodiments consistent with the disclosure and together with the description, serve to explain the principles of the disclosure.
Fig. 1 is a schematic flow chart of a federal learning model training method applied to predicting road conditions according to an embodiment of the present application;
FIG. 2 is a flowchart of another training method of a federal learning model for predicting road conditions according to an embodiment of the present application;
FIG. 3 is a flowchart of another federal learning model training method applied to road condition prediction according to an embodiment of the present application;
Fig. 4 is a schematic structural diagram of a federal learning model training device for predicting road conditions according to an embodiment of the present application;
FIG. 5 is a schematic structural diagram of another training device for federal learning model for predicting road conditions according to an embodiment of the present application;
FIG. 6 is a schematic structural diagram of another training device for federal learning model for predicting road conditions according to an embodiment of the present application;
fig. 7 is a schematic structural diagram of a server according to an embodiment of the present application;
fig. 8 is a schematic structural diagram of a vehicle terminal according to an embodiment of the present application;
fig. 9 is a block diagram of an electronic device according to an embodiment of the present application.
Specific embodiments of the present disclosure have been shown by way of the above drawings and will be described in more detail below. These drawings and the written description are not intended to limit the scope of the disclosed concepts in any way, but rather to illustrate the disclosed concepts to those skilled in the art by reference to specific embodiments.
Detailed Description
Reference will now be made in detail to exemplary embodiments, examples of which are illustrated in the accompanying drawings. When the following description refers to the accompanying drawings, the same numbers in different drawings refer to the same or similar elements, unless otherwise indicated. The implementations described in the following exemplary examples are not representative of all implementations consistent with the present disclosure.
In one example, after the vehicle terminal obtains the final trained target driving model in the federal learning scheme regarding automatic driving, the vehicle terminal may predict a front road condition of the vehicle, for example, predict a road condition in front, predict driving data based on the road condition, or the like, according to the target driving model of the vehicle terminal itself during driving. However, as the running data of the vehicle terminal increases, the target running model should be updated rapidly along with the running data, and due to the federal learning mechanism, in the process of training the target running model according to the local model parameters of the vehicle terminal, the local model parameters involved in the aggregation processing include parameters obtained according to the running data of a long time, and the latest running data cannot have a greater influence on the target running model, so that the updating of the target running model is delayed from the running data change of the user, and the vehicle cannot predict the road condition ahead of the vehicle according to the latest target running model.
The application provides federal learning model training for predicting road conditions, and aims to solve the technical problems in the prior art.
The following describes the technical scheme of the present application and how the technical scheme of the present application solves the above technical problems in detail with specific embodiments. The following embodiments may be combined with each other, and the same or similar concepts or processes may not be described in detail in some embodiments. Embodiments of the present application will be described below with reference to the accompanying drawings.
Fig. 1 is a flowchart of a federal learning model training method applied to predicting road conditions, which is provided in an embodiment of the present application, and the method is applied to a server, as shown in fig. 1, and includes steps 101-103:
101. transmitting a preset initial global model to each of the N vehicle terminals; the method comprises the steps of determining a local model of a vehicle terminal by a preset initial global model, wherein N is a positive integer greater than 1.
Illustratively, the execution body of the present embodiment may be a server. The server and N vehicle terminals may participate in the federal learning process. In the federal learning process, a server sends a preset initial global model to each vehicle terminal in N vehicle terminals, and after each vehicle terminal receives the initial global model, the initial global model is covered with a local model of the vehicle terminal to obtain a local model of the vehicle terminal, namely the vehicle terminal can determine the local model according to the initial global model, wherein N is a positive integer greater than 1.
102. Receiving local model parameters sent by each vehicle terminal; the local model parameters sent by each of M vehicle terminals in the N vehicle terminals comprise a safety model parameter and an accident model parameter; the local model parameters transmitted by each of the N-M vehicle terminals of the N vehicle terminals comprise security model parameters; m is a positive integer greater than or equal to 1 and less than or equal to N; the safety model parameters are obtained by training a local model in the vehicle terminal based on the acquired vehicle running data corresponding to the vehicle terminal by the vehicle terminal; the accident model parameters are obtained by the vehicle terminal training the local model in the vehicle terminal based on the obtained vehicle accident data corresponding to the vehicle terminal.
The vehicle terminal may train the local model in the vehicle terminal based on the acquired vehicle driving data corresponding to the vehicle terminal after determining the local model according to the initial global model, to obtain the safety model parameters. The vehicle terminal trains a local model in the vehicle terminal based on the acquired vehicle accident data corresponding to the vehicle terminal to obtain accident model parameters, wherein the accident model parameters are the local model parameters of the vehicle terminal. Both the security model parameters and the incident model parameters are then uploaded to a server. In the uploading process, the local model parameters sent by each of M vehicle terminals in N vehicle terminals comprise a safety model parameter and an accident model parameter, the local model parameters sent by each of N-M vehicle terminals in N vehicle terminals comprise a safety model parameter, and M is a positive integer greater than or equal to 1 and less than or equal to N. Wherein the vehicle travel data includes one or more of: brake data, throttle data and steering chassis data; the vehicle accident data includes one or more of the following: airbag ejection data of the vehicle terminal, collision data acquired by a sensor of the vehicle terminal, vehicle running data of the vehicle terminal in a preset time period before an accident occurs, and accident model parameters of the vehicle terminal.
For example, n=3, the 1 st vehicle terminal acquires vehicle accident data corresponding to the vehicle terminal, i.e., the 1 st vehicle terminal determines that an accident has occurred on its own, and the 2 nd vehicle terminal and the 3 rd vehicle terminal each acquire vehicle running data corresponding to its own, i.e., the 2 nd vehicle terminal and the 3 rd vehicle terminal each determine that no accident has occurred on its own. The 1 st vehicle terminal trains a local model in the vehicle terminal based on the acquired vehicle accident data corresponding to the vehicle terminal to obtain accident model parameters; and, the 1 st vehicle terminal trains the local model in the vehicle terminal based on the acquired vehicle running data corresponding to the vehicle terminal, and obtains the safety model parameters. The 2 nd vehicle terminal and the 3 rd vehicle terminal train the local model in the vehicle terminal based on the acquired vehicle running data corresponding to the vehicle terminal, and obtain the safety model parameters corresponding to the 2 nd vehicle terminal and the safety model parameters corresponding to the 3 rd vehicle terminal. Therefore, the 1 st vehicle terminal is required to feed back the safety model parameters and the accident model parameters; the 2 nd vehicle terminal and the 3 rd vehicle terminal feed back the safety model parameters.
103. According to local model parameters sent by each vehicle terminal in the N vehicle terminals, updating a preset initial global model to obtain a target driving model; and transmitting a target traveling model to each of the N vehicle terminals, wherein the target traveling model is used for predicting the road condition ahead of the vehicle terminal.
The server integrates the M accident model parameters fed back by the M vehicle terminals to obtain integrated accident model parameters, where the integrated accident model parameters represent model parameters after the vehicle accident data of the M vehicle terminals train the local model. And updating a preset initial global model according to the safety model parameters sent by each vehicle terminal in the N vehicle terminals and the integrated accident model parameters to obtain a target running model. And the target running model is sent to each of the N vehicle terminals, and after the vehicle terminal receives the target running model, the vehicle terminal can predict the road condition in front of the vehicle terminal according to the target running model in the running process.
In the embodiment of the application, a preset initial global model is sent to each vehicle terminal in N vehicle terminals; the method comprises the steps of determining a local model of a vehicle terminal by a preset initial global model, wherein N is a positive integer greater than 1. Receiving local model parameters sent by each vehicle terminal; the local model parameters sent by each of M vehicle terminals in the N vehicle terminals comprise a safety model parameter and an accident model parameter; the local model parameters transmitted by each of the N-M vehicle terminals of the N vehicle terminals comprise security model parameters; m is a positive integer greater than or equal to 1 and less than or equal to N; the safety model parameters are obtained by training a local model in the vehicle terminal based on the acquired vehicle running data corresponding to the vehicle terminal by the vehicle terminal; the accident model parameters are obtained by the vehicle terminal training the local model in the vehicle terminal based on the obtained vehicle accident data corresponding to the vehicle terminal. According to local model parameters sent by each vehicle terminal in the N vehicle terminals, updating a preset initial global model to obtain a target driving model; and transmitting a target traveling model to each of the N vehicle terminals, wherein the target traveling model is used for predicting the road condition ahead of the vehicle terminal. In the scheme, a preset initial global model is sent to each of N vehicle terminals, after each vehicle terminal receives the initial global model, a local model corresponding to the vehicle terminal can be determined according to the initial global model, the local model in the vehicle terminal is trained according to acquired vehicle accident data corresponding to the vehicle terminal to obtain accident model parameters, the local model in the vehicle terminal is trained according to the acquired vehicle running data corresponding to the vehicle terminal to obtain safety model parameters, and the accident model parameters and the safety model parameters are local model parameters of the vehicle terminal. And then the accident model parameters and the safety model parameters are sent to a server, the accident model parameters and the safety model parameters are received by the server, and a preset initial global model is updated according to the accident model parameters and the safety model parameters sent by each vehicle terminal in the N vehicle terminals, so that a target running model is obtained. And finally, the target running model is sent to each vehicle terminal in the N vehicle terminals, and then the vehicle terminals can predict the road conditions in front of the vehicle terminals according to the target running model in the running process. Therefore, the target running model is updated in time along with the vehicle accident data of the vehicle and the change of the vehicle running data by receiving the local model parameters obtained by local training of each vehicle terminal and obtaining the target running model according to the plurality of local model parameters, so that the target running model obtained by final training can be sensitive to accidents, the accuracy of predicting the road condition in front of the target running model is greatly improved, and the technical problem that the accuracy of predicting the road condition in front of the model is lower due to the fact that the model is updated later than the running data of the vehicle is solved.
Fig. 2 is a flowchart of another federal learning model training method applied to predicting road conditions, which is provided in an embodiment of the present application, and is applied to a server, as shown in fig. 2, and the method includes steps 201 to 205:
201. transmitting a preset initial global model to each of the N vehicle terminals; the method comprises the steps of determining a local model of a vehicle terminal by a preset initial global model, wherein N is a positive integer greater than 1.
Illustratively, this step may refer to step 101 in fig. 1, and will not be described in detail.
202. Receiving local model parameters sent by each vehicle terminal; the local model parameters sent by each of M vehicle terminals in the N vehicle terminals comprise a safety model parameter and an accident model parameter; the local model parameters transmitted by each of the N-M vehicle terminals of the N vehicle terminals comprise security model parameters; m is a positive integer greater than or equal to 1 and less than or equal to N; the safety model parameters are obtained by training a local model in the vehicle terminal based on the acquired vehicle running data corresponding to the vehicle terminal by the vehicle terminal; the accident model parameters are obtained by the vehicle terminal training the local model in the vehicle terminal based on the obtained vehicle accident data corresponding to the vehicle terminal.
In one example, the vehicle travel data includes one or more of the following: brake data, throttle data and steering chassis data; the vehicle accident data includes one or more of the following: airbag ejection data of the vehicle terminal, collision data acquired by a sensor of the vehicle terminal, vehicle running data of the vehicle terminal in a preset time period before an accident occurs, and accident model parameters of the vehicle terminal.
Illustratively, this step may refer to step 102 in fig. 1, and will not be described in detail.
203. Integrating the M accident model parameters fed back by the M vehicle terminals to obtain integrated accident model parameters; the integrated accident model parameters represent model parameters after the training of the local model by respective vehicle accident data of the M vehicle terminals.
Step 203 includes three implementations:
first implementation of step 203: summing M accident model parameters fed back by M vehicle terminals to obtain a parameter sum; integrating the parameter sum and the M accident model parameters to obtain integrated accident model parameters; the integration process is to divide the sum of parameters by M.
The second implementation of step 203: the accident model parameters comprise accident labels, and the accident labels are used for indicating the accident types; according to a preset target accident type, determining accident model parameters corresponding to the target accident type from M accident model parameters fed back by M vehicle terminals; and integrating the accident model parameters corresponding to the target accident types to obtain integrated accident model parameters.
Third implementation of step 203: the accident model parameters comprise accident labels, and the accident labels are used for indicating the accident types; determining a weight value corresponding to each accident tag according to the second preset corresponding relation; the second preset corresponding relation is the corresponding relation between the accident label and the weight value; and integrating the M accident model parameters fed back by the M vehicle terminals according to the accident labels respectively included by the M accident model parameters fed back by the M vehicle terminals and the weight values corresponding to the accident labels to obtain the integrated accident model parameters.
The server receives the M accident model parameters fed back by the M vehicle terminals, and needs to integrate the M accident model parameters to obtain integrated accident model parameters, where the integrated accident model parameters represent model parameters after the vehicle accident data of the M vehicle terminals train the local model. The following three integration methods are included in the integration process, and are specifically described below.
In a first implementation, the server sums the M accident model parameters fed back by the M vehicle terminals to obtain a parameter sum. Dividing the parameter sum by M to obtain the integrated accident model parameters.
Or in the second implementation manner, when the vehicle terminal obtains the vehicle accident data, the accident type can be determined according to the vehicle accident data, and a corresponding accident label is generated according to the accident type, so that the accident label is carried in the accident model parameter received by the server, and the accident label is used for indicating the accident type. The server presets a target accident type to be trained, and determines accident model parameters corresponding to the target accident type from M accident model parameters fed back by M vehicle terminals according to the preset target accident type. And then integrating the accident model parameters corresponding to the target accident types to obtain integrated accident model parameters.
Or in a third implementation manner, when the vehicle terminal obtains the vehicle accident data, the accident type can be determined according to the vehicle accident data, and a corresponding accident label is generated according to the accident type, so that the accident label is carried in the accident model parameter received by the server, and the accident label is used for indicating the accident type. The server generates and stores a second preset corresponding relation between the accident labels and the weight values in advance, and determines the weight value corresponding to each accident label according to the second preset corresponding relation and the accident type indicated by each accident label. And integrating the M accident model parameters fed back by the M vehicle terminals according to the accident labels respectively included by the M accident model parameters fed back by the M vehicle terminals and the weight values corresponding to the accident labels to obtain the integrated accident model parameters.
204. And updating a preset initial global model according to the safety model parameters sent by each vehicle terminal in the N vehicle terminals and the integrated accident model parameters to obtain a target running model.
In one example, step 204 includes: determining a weight value corresponding to the safety model parameter and a weight value corresponding to the integrated accident model parameter according to a first preset corresponding relation; the first preset corresponding relation is a corresponding relation between the model parameters and the weight values; according to the weight value corresponding to the safety model parameter and the weight value corresponding to the integrated accident model parameter, carrying out aggregation treatment on the safety model parameter and the integrated accident model parameter to obtain an aggregation model; and updating a preset initial global model according to the aggregation model to obtain a target running model.
In one example, the preset condition is reached when the target driving model is obtained; the preset condition is that the preset repeated execution times are reached, or the initial global model preset after updating reaches a convergence state.
The server generates and stores a first preset corresponding relation between the model parameters and the weight values in advance, and determines the weight values corresponding to the safety model parameters and the integrated accident model parameters according to the first preset corresponding relation. And then, based on a preset aggregation formula, a weight value corresponding to the safety model parameter and a weight value corresponding to the integrated accident model parameter, aggregating the safety model parameter and the integrated accident model parameter to obtain an aggregation model. And finally, updating a preset initial global model according to the aggregation model to obtain a target running model. The preset aggregation formula is as follows:
W=(1*W 0 +α*W 1 +β*W 2 +γ*W 3 +χ*W 4 +δ*W 5… +ε*Wa)/n
Wherein alpha, beta, gamma, χ, delta and epsilon are weight values obtained by training the server, W 0 Is the current model parameter corresponding to the current running model of the server, W 1 ~W 5 Is a security model parameter, W, transmitted by each of the 5 vehicle terminals a Is an integrated accident model parameter obtained by integrating a plurality of accident model parameters, a is the number of accident model parameters, and n is the number of local model parameters which participate in aggregation processing in total, namely a safety model parameter W 1 ~W 5 Integrated accident model parameters W a W represents the target running model.
According to the formula, after the weight value corresponding to the safety model parameter and the weight value corresponding to the integrated accident model parameter are determined, multiplying the safety model parameter and the weight value corresponding to the safety model parameter to obtain a first product value, and multiplying the integrated accident model parameter and the weight value corresponding to the integrated accident model parameter to obtain a second product value. Will W 0 And 5 first product values and a second product values are added to obtain a model sum, and finally the model sum is divided by n to obtain the target running model W. Alternatively, if the vehicle terminal determines that no accident has occurred in the vehicle terminal itself, wa=0, without determining W a Corresponding weight values.
After determining the target running model, it is necessary to determine whether the target running model reaches a preset condition, if the target running model reaches the preset condition, determining that the target running model is the final model, and if the target running model does not reach the preset condition, repeating the steps 201 to 204 until the target running model converges. The preset condition is that the preset number of times of repeated execution is reached, or that an initial global model preset after updating reaches a convergence state, specifically, whether the target running model converges or not may be determined according to a prediction result of the target running model, for example, if an accuracy difference of the target running model obtained by two or more adjacent iterations is smaller than a certain threshold, the target running model is considered to converge, and the like.
205. And transmitting a target running model to each of the N vehicle terminals, wherein the target running model is used for predicting the front road condition of the vehicle terminal.
For example, the target driving model is transmitted to each of the N vehicle terminals, and the vehicle terminal may predict the road condition ahead of the vehicle terminal according to the target driving model during driving after the vehicle terminal receives the target driving model.
In the embodiment of the application, a preset initial global model is sent to each vehicle terminal in N vehicle terminals; the method comprises the steps of determining a local model of a vehicle terminal by a preset initial global model, wherein N is a positive integer greater than 1. Receiving local model parameters sent by each vehicle terminal; the local model parameters sent by each of M vehicle terminals in the N vehicle terminals comprise a safety model parameter and an accident model parameter; the local model parameters transmitted by each of the N-M vehicle terminals of the N vehicle terminals comprise security model parameters; m is a positive integer greater than or equal to 1 and less than or equal to N; the safety model parameters are obtained by training a local model in the vehicle terminal based on the acquired vehicle running data corresponding to the vehicle terminal by the vehicle terminal; the accident model parameters are obtained by the vehicle terminal training the local model in the vehicle terminal based on the obtained vehicle accident data corresponding to the vehicle terminal. Integrating the M accident model parameters fed back by the M vehicle terminals to obtain integrated accident model parameters; the integrated accident model parameters represent model parameters after the training of the local model by respective vehicle accident data of the M vehicle terminals. And updating a preset initial global model according to the safety model parameters sent by each vehicle terminal in the N vehicle terminals and the integrated accident model parameters to obtain a target running model. And transmitting a target running model to each of the N vehicle terminals, wherein the target running model is used for predicting the front road condition of the vehicle terminal. Therefore, the target running model is updated in time along with the vehicle accident data of the vehicle and the change of the vehicle running data by receiving the local model parameters obtained by local training of each vehicle terminal and obtaining the target running model according to the plurality of local model parameters, so that the target running model obtained by final training can be sensitive to accidents, the accuracy of predicting the road condition in front of the target running model is greatly improved, and the technical problem that the accuracy of predicting the road condition in front of the model is lower due to the fact that the model is updated later than the running data of the vehicle is solved.
Fig. 3 is a flowchart of another federal learning model training method applied to predicting road conditions according to an embodiment of the present application, where the method is applied to a vehicle terminal, as shown in fig. 3, and the method includes steps 301-304:
301. and receiving a preset initial global model sent by the server, and determining a local model according to the preset initial global model, wherein N is a positive integer greater than 1.
302. Training a local model in the vehicle terminal based on the acquired vehicle running data corresponding to the vehicle terminal, and obtaining safety model parameters; based on the acquired vehicle accident data corresponding to the vehicle terminal, training the local model in the vehicle terminal and obtaining accident model parameters.
In one example, the accident model parameters include accident tags, which are used to indicate the accident type; the accident tag is used for determining integrated accident model parameters; the integrated accident model parameters are obtained according to the accident model parameters corresponding to the target accident types, and the accident model parameters corresponding to the target accident types are obtained from M accident model parameters fed back by M vehicle terminals according to the preset target accident types; or the integrated accident model parameters are obtained by integrating the M accident model parameters fed back by the M vehicle terminals according to the accident labels respectively included by the M accident model parameters fed back by the M vehicle terminals and the weight values corresponding to the accident labels, and the weight values corresponding to the accident labels are obtained according to a second preset corresponding relation, wherein the second preset corresponding relation is the corresponding relation between the accident labels and the weight values.
In one example, the vehicle travel data includes one or more of the following: brake data, throttle data and steering chassis data; the vehicle accident data includes one or more of the following: airbag ejection data of the vehicle terminal, collision data acquired by a sensor of the vehicle terminal, vehicle running data of the vehicle terminal in a preset time period before an accident occurs, and accident model parameters of the vehicle terminal.
303. Transmitting the security model parameters and the accident model parameters to a server; the local model parameters sent by each of M vehicle terminals in the N vehicle terminals comprise a safety model parameter and an accident model parameter; the local model parameters transmitted by each of the N-M vehicle terminals of the N vehicle terminals comprise security model parameters; m is a positive integer greater than or equal to 1 and less than or equal to N; and the local model parameters sent by each vehicle terminal in the N vehicle terminals are used for updating a preset initial global model to obtain a target driving model.
304. Receiving a target driving model sent by a server; the target driving model is used for predicting the front road condition of the vehicle terminal.
For example, the method of this embodiment may refer to the technical solution in the above method, and the specific implementation process and the technical principle are the same, which are not described herein again.
In one example, an embodiment of the present application provides a road condition prediction method based on a federal learning model, where the method is applied to a vehicle terminal, and the method includes:
acquiring actual running data of a vehicle, and inputting the actual running data into a target running model to obtain a front road condition;
the target running model is the target running model provided by the embodiment.
In an exemplary manner, during the running of the vehicle, the vehicle terminal acquires actual running data of the vehicle itself, and inputs the actual running data into the target model to obtain the front road condition.
Fig. 4 is a schematic structural diagram of a federal learning model training device for predicting road conditions, which is applied to a server according to an embodiment of the present application, as shown in fig. 4, and includes:
an obtaining unit 41, configured to send a preset initial global model to each of the N vehicle terminals; the method comprises the steps of determining a local model of a vehicle terminal by a preset initial global model, wherein N is a positive integer greater than 1.
A receiving unit 42 for receiving the local model parameters transmitted from each vehicle terminal; the local model parameters sent by each of M vehicle terminals in the N vehicle terminals comprise a safety model parameter and an accident model parameter; the local model parameters transmitted by each of the N-M vehicle terminals of the N vehicle terminals comprise security model parameters; m is a positive integer greater than or equal to 1 and less than or equal to N; the safety model parameters are obtained by training a local model in the vehicle terminal based on the acquired vehicle running data corresponding to the vehicle terminal by the vehicle terminal; the accident model parameters are obtained by the vehicle terminal training the local model in the vehicle terminal based on the obtained vehicle accident data corresponding to the vehicle terminal.
And the updating unit 43 is configured to update a preset initial global model according to local model parameters sent by each of the N vehicle terminals, so as to obtain a target driving model.
And a transmitting unit 44 for transmitting a target running model to each of the N vehicle terminals, wherein the target running model is used for predicting the road condition ahead of the vehicle terminal.
The device of the embodiment may execute the technical scheme in the above method, and the specific implementation process and the technical principle are the same and are not described herein again.
Fig. 5 is a schematic structural diagram of another model training device for predicting road conditions according to an embodiment of the present application, and based on the embodiment shown in fig. 4, as shown in fig. 5, an updating unit 43 includes:
the integration module 431 is configured to integrate the M accident model parameters fed back by the M vehicle terminals to obtain integrated accident model parameters; the integrated accident model parameters represent model parameters after the training of the local model by respective vehicle accident data of the M vehicle terminals.
And the updating module 432 is configured to update a preset initial global model according to the security model parameters sent by each of the N vehicle terminals and the integrated accident model parameters, so as to obtain a target driving model.
In one example, the update module 432 includes:
a first determining submodule 4321, configured to determine a weight value corresponding to the security model parameter and a weight value corresponding to the integrated accident model parameter according to a first preset correspondence; the first preset corresponding relation is a corresponding relation between the model parameter and the weight value.
And the aggregation sub-module 4322 is used for aggregating the security model parameters and the integrated accident model parameters according to the weight values corresponding to the security model parameters and the weight values corresponding to the integrated accident model parameters to obtain an aggregation model.
And an updating submodule 4323, configured to update a preset initial global model according to the aggregate model to obtain a target driving model.
In one example, the integration module 431 includes:
and the summation submodule 4311 is used for carrying out summation processing on M accident model parameters fed back by the M vehicle terminals to obtain parameter summation.
The first integration submodule 4312 is used for integrating the parameter sum and the M accident model parameters to obtain integrated accident model parameters; the integration process is to divide the sum of parameters by M.
In one example, the incident model parameters include an incident label for indicating the incident type; an integration module 431 comprising:
The second determining submodule 4313 is configured to determine, according to a preset target accident type, an accident model parameter corresponding to the target accident type from M accident model parameters fed back by M vehicle terminals.
The second integration submodule 4314 is used for integrating the accident model parameters corresponding to the target accident type to obtain integrated accident model parameters.
In one example, the incident model parameters include an incident label for indicating the incident type; an integration module 431 comprising:
a third determining submodule 4315, configured to determine a weight value corresponding to each of the event tags according to the second preset correspondence; the second preset corresponding relation is a corresponding relation between the accident label and the weight value.
And the third integration submodule 4316 is used for integrating the M accident model parameters fed back by the M vehicle terminals according to the accident labels respectively included by the M accident model parameters fed back by the M vehicle terminals and the weight values corresponding to the accident labels to obtain the integrated accident model parameters.
In one example, the preset condition is reached when the target driving model is obtained;
the preset condition is that the preset repeated execution times are reached, or the initial global model preset after updating reaches a convergence state.
In one example, the vehicle travel data includes one or more of the following: brake data, throttle data and steering chassis data;
the vehicle accident data includes one or more of the following: airbag ejection data of the vehicle terminal, collision data acquired by a sensor of the vehicle terminal, vehicle running data of the vehicle terminal in a preset time period before an accident occurs, and accident model parameters of the vehicle terminal.
The device of the embodiment may execute the technical scheme in the above method, and the specific implementation process and the technical principle are the same and are not described herein again.
Fig. 6 is a schematic structural diagram of another federal learning model training device for predicting road conditions according to an embodiment of the present application, where the device is applied to a vehicle terminal, as shown in fig. 6, and the device includes:
the receiving unit 51 is configured to receive a preset initial global model sent by the server.
The determining unit 52 is configured to determine a local model according to a preset initial global model, where N is a positive integer greater than 1.
A training unit 53, configured to train the local model in the vehicle terminal and obtain the security model parameter based on the acquired vehicle running data corresponding to the vehicle terminal; based on the acquired vehicle accident data corresponding to the vehicle terminal, training the local model in the vehicle terminal and obtaining accident model parameters.
A transmitting unit 54 for transmitting the security model parameters and the accident model parameters to the server; the local model parameters sent by each of M vehicle terminals in the N vehicle terminals comprise a safety model parameter and an accident model parameter; the local model parameters transmitted by each of the N-M vehicle terminals of the N vehicle terminals comprise security model parameters; m is a positive integer greater than or equal to 1 and less than or equal to N; and the local model parameters sent by each vehicle terminal in the N vehicle terminals are used for updating a preset initial global model to obtain a target driving model.
A receiving unit 55 for receiving the target running model transmitted by the server; the target driving model is used for predicting the front road condition of the vehicle terminal.
The device of the embodiment may execute the technical scheme in the above method, and the specific implementation process and the technical principle are the same and are not described herein again.
Based on the embodiment shown in fig. 6, the accident model parameters include accident labels, which are used to indicate the accident types; the accident tag is used for determining integrated accident model parameters;
the integrated accident model parameters are obtained according to the accident model parameters corresponding to the target accident types, and the accident model parameters corresponding to the target accident types are obtained from M accident model parameters fed back by M vehicle terminals according to the preset target accident types;
Or the integrated accident model parameters are obtained by integrating the M accident model parameters fed back by the M vehicle terminals according to the accident labels respectively included by the M accident model parameters fed back by the M vehicle terminals and the weight values corresponding to the accident labels, and the weight values corresponding to the accident labels are obtained according to a second preset corresponding relation, wherein the second preset corresponding relation is the corresponding relation between the accident labels and the weight values.
In one example, the vehicle travel data includes one or more of the following: brake data, throttle data and steering chassis data;
the vehicle accident data includes one or more of the following: airbag ejection data of the vehicle terminal, collision data acquired by a sensor of the vehicle terminal, vehicle running data of the vehicle terminal in a preset time period before an accident occurs, and accident model parameters of the vehicle terminal.
The device of the embodiment may execute the technical scheme in the above method, and the specific implementation process and the technical principle are the same and are not described herein again.
Fig. 7 is a schematic structural diagram of a server according to an embodiment of the present application, where the server may be a device for training a target driving model, or the server may be a device deployed on a vehicle terminal. As shown in fig. 7, the server includes: a memory 61, and a processor 62.
The memory 61 stores therein a computer program executable on the processor 62.
The processor 62 is configured to perform the methods as provided in the above embodiments.
The server further comprises a receiver 63 and a transmitter 64. The receiver 63 is for receiving instructions and data transmitted from an external device, and the transmitter 64 is for transmitting instructions and data to the external device.
Fig. 8 is a schematic structural diagram of a vehicle terminal according to an embodiment of the present application. As shown in fig. 8, the vehicle terminal includes: a memory 71, and a processor 72.
The memory 71 stores therein a computer program executable on the processor 72.
The processor 72 is configured to perform the method as provided by the above embodiments.
The vehicle terminal further comprises a receiver 73 and a transmitter 74. The receiver 73 is for receiving instructions and data transmitted from an external device, and the transmitter 74 is for transmitting instructions and data to an external device.
Fig. 9 is a block diagram of an electronic device, which may be a mobile phone, a computer, a digital broadcast terminal, a messaging device, a game console, a tablet device, a medical device, an exercise device, a personal digital assistant, or the like, provided in an embodiment of the present application.
The apparatus 800 may include one or more of the following components: a processing component 802, a memory 804, a power component 806, a multimedia component 808, an audio component 810, an input/output (I/O) interface 812, a sensor component 814, and a communication component 816.
The processing component 802 generally controls overall operation of the apparatus 800, such as operations associated with display, telephone calls, data communications, camera operations, and recording operations. The processing component 802 may include one or more processors 820 to execute instructions to perform all or part of the steps of the methods described above. Further, the processing component 802 can include one or more modules that facilitate interactions between the processing component 802 and other components. For example, the processing component 802 can include a multimedia module to facilitate interaction between the multimedia component 808 and the processing component 802.
The memory 804 is configured to store various types of data to support operations at the apparatus 800. Examples of such data include instructions for any application or method operating on the device 800, contact data, phonebook data, messages, pictures, videos, and the like. The memory 804 may be implemented by any type or combination of volatile or nonvolatile memory devices such as Static Random Access Memory (SRAM), electrically erasable programmable read-only memory (EEPROM), erasable programmable read-only memory (EPROM), programmable read-only memory (PROM), read-only memory (ROM), magnetic memory, flash memory, magnetic or optical disk.
The power supply component 806 provides power to the various components of the device 800. The power components 806 may include a power management system, one or more power sources, and other components associated with generating, managing, and distributing power for the device 800.
The multimedia component 808 includes a screen between the device 800 and the user that provides an output interface. In some embodiments, the screen may include a Liquid Crystal Display (LCD) and a Touch Panel (TP). If the screen includes a touch panel, the screen may be implemented as a touch screen to receive input signals from a user. The touch panel includes one or more touch sensors to sense touches, swipes, and gestures on the touch panel. The touch sensor may sense not only the boundary of a touch or sliding action, but also the duration and pressure associated with the touch or sliding operation. In some embodiments, the multimedia component 808 includes a front camera and/or a rear camera. The front camera and/or the rear camera may receive external multimedia data when the apparatus 800 is in an operational mode, such as a photographing mode or a video mode. Each front camera and rear camera may be a fixed optical lens system or have focal length and optical zoom capabilities.
The audio component 810 is configured to output and/or input audio signals. For example, the audio component 810 includes a Microphone (MIC) configured to receive external audio signals when the device 800 is in an operational mode, such as a call mode, a recording mode, and a voice recognition mode. The received audio signals may be further stored in the memory 804 or transmitted via the communication component 816. In some embodiments, audio component 810 further includes a speaker for outputting audio signals.
The I/O interface 812 provides an interface between the processing component 802 and peripheral interface modules, which may be a keyboard, click wheel, buttons, etc. These buttons may include, but are not limited to: homepage button, volume button, start button, and lock button.
The sensor assembly 814 includes one or more sensors for providing status assessment of various aspects of the apparatus 800. For example, the sensor assembly 814 may detect an on/off state of the device 800, a relative positioning of the assemblies, such as a display and keypad of the device 800, the sensor assembly 814 may also detect a change in position of the device 800 or one of the assemblies of the device 800, the presence or absence of user contact with the device 800, an orientation or acceleration/deceleration of the device 800, and a change in temperature of the device 800. The sensor assembly 814 may include a proximity sensor configured to detect the presence of nearby objects without any physical contact. The sensor assembly 814 may also include a light sensor, such as a CMOS or CCD image sensor, for use in imaging applications. In some embodiments, the sensor assembly 814 may also include an acceleration sensor, a gyroscopic sensor, a magnetic sensor, a pressure sensor, or a temperature sensor.
The communication component 816 is configured to facilitate communication between the apparatus 800 and other devices, either in a wired or wireless manner. The device 800 may access a wireless network based on a communication standard, such as WiFi,2G or 3G, or a combination thereof. In one exemplary embodiment, the communication component 816 receives broadcast signals or broadcast related information from an external broadcast management system via a broadcast channel. In one exemplary embodiment, the communication component 816 further includes a Near Field Communication (NFC) module to facilitate short range communications. For example, the NFC module may be implemented based on Radio Frequency Identification (RFID) technology, infrared data association (IrDA) technology, ultra Wideband (UWB) technology, bluetooth (BT) technology, and other technologies.
In an exemplary embodiment, the apparatus 800 may be implemented by one or more Application Specific Integrated Circuits (ASICs), digital Signal Processors (DSPs), digital Signal Processing Devices (DSPDs), programmable Logic Devices (PLDs), field Programmable Gate Arrays (FPGAs), controllers, microcontrollers, microprocessors, or other electronic elements for executing the methods described above.
In an exemplary embodiment, a non-transitory computer readable storage medium is also provided, such as memory 804 including instructions executable by processor 820 of apparatus 800 to perform the above-described method. For example, the non-transitory computer readable storage medium may be ROM, random Access Memory (RAM), CD-ROM, magnetic tape, floppy disk, optical data storage device, etc.
Embodiments of the present application also provide a non-transitory computer-readable storage medium, which when executed by a processor of an electronic device, enables the electronic device to perform the method provided by the above embodiments.
The embodiment of the application also provides a computer program product, which comprises: a computer program stored in a readable storage medium, from which at least one processor of an electronic device can read, the at least one processor executing the computer program causing the electronic device to perform the solution provided by any one of the embodiments described above.
Other embodiments of the disclosure will be apparent to those skilled in the art from consideration of the specification and practice of the disclosure disclosed herein. This application is intended to cover any adaptations, uses, or adaptations of the disclosure following, in general, the principles of the disclosure and including such departures from the present disclosure as come within known or customary practice within the art to which the disclosure pertains. It is intended that the specification and examples be considered as exemplary only, with a true scope and spirit of the disclosure being indicated by the following claims.
It is to be understood that the present disclosure is not limited to the precise arrangements and instrumentalities shown in the drawings, and that various modifications and changes may be effected without departing from the scope thereof. The scope of the present disclosure is limited only by the appended claims.

Claims (27)

1. A federal learning model training method for predicting road conditions, the method being applied to a server, the method comprising:
transmitting a preset initial global model to each of the N vehicle terminals; the preset initial global model is used for determining a local model of the vehicle terminal, and N is a positive integer greater than 1;
receiving local model parameters sent by each vehicle terminal; the local model parameters sent by each of M vehicle terminals in the N vehicle terminals comprise a safety model parameter and an accident model parameter; the local model parameters sent by each of N-M vehicle terminals in the N vehicle terminals comprise security model parameters; m is a positive integer greater than or equal to 1 and less than or equal to N; the safety model parameters are obtained by training a local model in the vehicle terminal based on the acquired vehicle running data corresponding to the vehicle terminal by the vehicle terminal; the accident model parameters are obtained by training a local model in the vehicle terminal based on the acquired vehicle accident data corresponding to the vehicle terminal by the vehicle terminal;
Updating the preset initial global model according to local model parameters sent by each vehicle terminal in the N vehicle terminals to obtain a target running model; and transmitting the target running model to each of the N vehicle terminals, wherein the target running model is used for predicting the road condition in front of the vehicle terminal.
2. The method of claim 1, wherein updating the preset initial global model to obtain a target driving model according to local model parameters sent by each of the N vehicle terminals, comprises:
integrating the M accident model parameters fed back by the M vehicle terminals to obtain integrated accident model parameters; the integrated accident model parameters represent model parameters after training the local model by respective vehicle accident data of the M vehicle terminals;
and updating the preset initial global model according to the safety model parameters sent by each vehicle terminal in the N vehicle terminals and the integrated accident model parameters to obtain a target running model.
3. The method according to claim 2, wherein updating the preset initial global model to obtain a target driving model according to the safety model parameters sent by each of the N vehicle terminals and the integrated accident model parameters comprises:
Determining a weight value corresponding to the safety model parameter and a weight value corresponding to the integrated accident model parameter according to a first preset corresponding relation; the first preset corresponding relation is a corresponding relation between model parameters and weight values;
according to the weight value corresponding to the safety model parameter and the weight value corresponding to the integrated accident model parameter, carrying out aggregation treatment on the safety model parameter and the integrated accident model parameter to obtain an aggregation model;
and updating the preset initial global model according to the aggregation model to obtain a target running model.
4. The method according to claim 2, wherein the integrating the M accident model parameters fed back by the M vehicle terminals to obtain integrated accident model parameters includes:
summing the M accident model parameters fed back by the M vehicle terminals to obtain a parameter sum;
integrating the parameter sum and the M accident model parameters to obtain integrated accident model parameters; wherein the integration process is to divide the parameter sum by M.
5. The method of claim 2, wherein the incident model parameters include an incident tag for indicating an incident type; integrating the M accident model parameters fed back by the M vehicle terminals to obtain integrated accident model parameters, wherein the integrated accident model parameters comprise:
According to a preset target accident type, determining accident model parameters corresponding to the target accident type from M accident model parameters fed back by the M vehicle terminals;
and integrating the accident model parameters corresponding to the target accident types to obtain integrated accident model parameters.
6. The method of claim 2, wherein the incident model parameters include an incident tag for indicating an incident type; integrating the M accident model parameters fed back by the M vehicle terminals to obtain integrated accident model parameters, wherein the integrated accident model parameters comprise:
determining a weight value corresponding to each accident tag according to the second preset corresponding relation; the second preset corresponding relation is a corresponding relation between the accident label and the weight value;
and integrating the M accident model parameters fed back by the M vehicle terminals according to the accident labels respectively included by the M accident model parameters fed back by the M vehicle terminals and the weight values corresponding to the accident labels to obtain the integrated accident model parameters.
7. The method according to any one of claims 1-6, wherein a preset condition is reached when the target running model is obtained;
The preset conditions are that the preset repeated execution times are reached or an initial global model preset after updating reaches a convergence state.
8. The method of any one of claims 1-6, wherein the vehicle travel data comprises one or more of: brake data, throttle data and steering chassis data;
the vehicle accident data includes one or more of the following: airbag ejection data of the vehicle terminal, collision data acquired by a sensor of the vehicle terminal, vehicle running data of the vehicle terminal in a preset time period before an accident occurs, and accident model parameters of the vehicle terminal.
9. A federal learning model training method for predicting road conditions, the method being applied to a vehicle terminal, the method comprising:
receiving a preset initial global model sent by a server, and determining a local model according to the preset initial global model, wherein N is a positive integer greater than 1;
training the local model in the vehicle terminal based on the acquired vehicle running data corresponding to the vehicle terminal and obtaining safety model parameters; training the local model in the vehicle terminal based on the acquired vehicle accident data corresponding to the vehicle terminal and obtaining accident model parameters;
Transmitting the security model parameters and the accident model parameters to a server; the local model parameters sent by each of M vehicle terminals in the N vehicle terminals comprise a safety model parameter and an accident model parameter; the local model parameters sent by each of N-M vehicle terminals in the N vehicle terminals comprise security model parameters; m is a positive integer greater than or equal to 1 and less than or equal to N; the local model parameters sent by each vehicle terminal in the N vehicle terminals are used for obtaining a target running model after updating the preset initial global model;
receiving the target driving model sent by a server; the target driving model is used for predicting the front road condition of the vehicle terminal.
10. The method according to claim 9, wherein the accident model parameters comprise accident tags, the accident tags being used for indicating accident types; the accident tag is used for determining integrated accident model parameters;
the integrated accident model parameters are obtained according to accident model parameters corresponding to the target accident types, and the accident model parameters corresponding to the target accident types are obtained from M accident model parameters fed back by the M vehicle terminals according to the preset target accident types;
Or, the integrated accident model parameters are obtained by integrating the M accident model parameters fed back by the M vehicle terminals according to the accident labels respectively included in the M accident model parameters fed back by the M vehicle terminals and the weight values corresponding to the accident labels, and the weight values corresponding to the accident labels are obtained according to a second preset corresponding relation, wherein the second preset corresponding relation is a corresponding relation between the accident labels and the weight values.
11. The method of claim 9 or 10, wherein the vehicle travel data comprises one or more of: brake data, throttle data and steering chassis data;
the vehicle accident data includes one or more of the following: airbag ejection data of the vehicle terminal, collision data acquired by a sensor of the vehicle terminal, vehicle running data of the vehicle terminal in a preset time period before an accident occurs, and accident model parameters of the vehicle terminal.
12. A road condition prediction method based on a federal learning model, wherein the method is applied to a vehicle terminal, the method comprising:
acquiring actual running data of a vehicle, and inputting the actual running data into a target running model to obtain a front road condition;
Wherein the target running model is a target running model according to any one of claims 1 to 11.
13. A federal learning model training apparatus for predicting road conditions, the apparatus being applied to a server, the apparatus comprising:
the acquisition unit is used for transmitting the preset initial global model to each vehicle terminal in the N vehicle terminals; the preset initial global model is used for determining a local model of the vehicle terminal, and N is a positive integer greater than 1;
the receiving unit is used for receiving the local model parameters sent by each vehicle terminal; the local model parameters sent by each of M vehicle terminals in the N vehicle terminals comprise a safety model parameter and an accident model parameter; the local model parameters sent by each of N-M vehicle terminals in the N vehicle terminals comprise security model parameters; m is a positive integer greater than or equal to 1 and less than or equal to N; the safety model parameters are obtained by training a local model in the vehicle terminal based on the acquired vehicle running data corresponding to the vehicle terminal by the vehicle terminal; the accident model parameters are obtained by training a local model in the vehicle terminal based on the acquired vehicle accident data corresponding to the vehicle terminal by the vehicle terminal;
The updating unit is used for updating the preset initial global model according to the local model parameters sent by each vehicle terminal in the N vehicle terminals to obtain a target running model;
and the transmitting unit is used for transmitting the target running model to each of the N vehicle terminals, wherein the target running model is used for predicting the road condition in front of the vehicle terminal.
14. The apparatus of claim 13, wherein the updating unit comprises:
the integration module is used for integrating the M accident model parameters fed back by the M vehicle terminals to obtain integrated accident model parameters; the integrated accident model parameters represent model parameters after training the local model by respective vehicle accident data of the M vehicle terminals;
and the updating module is used for updating the preset initial global model according to the safety model parameters sent by each vehicle terminal in the N vehicle terminals and the integrated accident model parameters to obtain a target running model.
15. The apparatus of claim 14, wherein the update module comprises:
the first determining submodule is used for determining a weight value corresponding to the safety model parameter and a weight value corresponding to the integrated accident model parameter according to a first preset corresponding relation; the first preset corresponding relation is a corresponding relation between model parameters and weight values;
The aggregation sub-module is used for conducting aggregation treatment on the safety model parameters and the integrated accident model parameters according to the weight values corresponding to the safety model parameters and the weight values corresponding to the integrated accident model parameters to obtain an aggregation model;
and the updating sub-module is used for updating the preset initial global model according to the aggregation model to obtain a target running model.
16. The apparatus of claim 14, wherein the integration module comprises:
the summation sub-module is used for carrying out summation processing on M accident model parameters fed back by the M vehicle terminals to obtain parameter summation;
the first integration submodule is used for integrating the parameter sum and the M accident model parameters to obtain integrated accident model parameters; wherein the integration process is to divide the parameter sum by M.
17. The apparatus of claim 14, wherein the incident model parameters include an incident tag for indicating an incident type; the integration module comprises:
the second determining submodule is used for determining accident model parameters corresponding to the target accident types from M accident model parameters fed back by the M vehicle terminals according to the preset target accident types;
And the second integration sub-module is used for integrating the accident model parameters corresponding to the target accident type to obtain integrated accident model parameters.
18. The apparatus of claim 14, wherein the incident model parameters include an incident tag for indicating an incident type; the integration module comprises:
the third determining submodule is used for determining a weight value corresponding to each accident tag according to the second preset corresponding relation; the second preset corresponding relation is a corresponding relation between the accident label and the weight value;
and the third integration sub-module is used for integrating the M accident model parameters fed back by the M vehicle terminals according to the accident labels respectively included by the M accident model parameters fed back by the M vehicle terminals and the weight values corresponding to the accident labels to obtain the integrated accident model parameters.
19. The apparatus according to any one of claims 13-18, wherein a preset condition is reached when the target running model is obtained;
the preset conditions are that the preset repeated execution times are reached or an initial global model preset after updating reaches a convergence state.
20. The apparatus of any one of claims 13-18, wherein the vehicle travel data comprises one or more of: brake data, throttle data and steering chassis data;
the vehicle accident data includes one or more of the following: airbag ejection data of the vehicle terminal, collision data acquired by a sensor of the vehicle terminal, vehicle running data of the vehicle terminal in a preset time period before an accident occurs, and accident model parameters of the vehicle terminal.
21. A federal learning model training apparatus for predicting road conditions, the apparatus being applied to a vehicle terminal, the apparatus comprising:
the receiving unit is used for receiving a preset initial global model sent by the server;
the determining unit is used for determining a local model according to the preset initial global model, wherein N is a positive integer greater than 1;
the training unit is used for training the local model in the vehicle terminal and obtaining safety model parameters based on the acquired vehicle running data corresponding to the vehicle terminal; training the local model in the vehicle terminal based on the acquired vehicle accident data corresponding to the vehicle terminal and obtaining accident model parameters;
The sending unit is used for sending the safety model parameters and the accident model parameters to a server; the local model parameters sent by each of M vehicle terminals in the N vehicle terminals comprise a safety model parameter and an accident model parameter; the local model parameters sent by each of N-M vehicle terminals in the N vehicle terminals comprise security model parameters; m is a positive integer greater than or equal to 1 and less than or equal to N; the local model parameters sent by each vehicle terminal in the N vehicle terminals are used for obtaining a target running model after updating the preset initial global model;
the receiving unit is used for receiving the target running model sent by the server; the target driving model is used for predicting the front road condition of the vehicle terminal.
22. The apparatus of claim 21, wherein the accident model parameters include an accident tag, the accident tag indicating an accident type; the accident tag is used for determining integrated accident model parameters;
the integrated accident model parameters are obtained according to accident model parameters corresponding to the target accident types, and the accident model parameters corresponding to the target accident types are obtained from M accident model parameters fed back by the M vehicle terminals according to the preset target accident types;
Or, the integrated accident model parameters are obtained by integrating the M accident model parameters fed back by the M vehicle terminals according to the accident labels respectively included in the M accident model parameters fed back by the M vehicle terminals and the weight values corresponding to the accident labels, and the weight values corresponding to the accident labels are obtained according to a second preset corresponding relation, wherein the second preset corresponding relation is a corresponding relation between the accident labels and the weight values.
23. The apparatus of claim 21 or 22, wherein the vehicle travel data comprises one or more of: brake data, throttle data and steering chassis data;
the vehicle accident data includes one or more of the following: airbag ejection data of the vehicle terminal, collision data acquired by a sensor of the vehicle terminal, vehicle running data of the vehicle terminal in a preset time period before an accident occurs, and accident model parameters of the vehicle terminal.
24. A server comprising a memory, a processor, the memory having stored therein a computer program executable on the processor, the processor implementing the method of any of the preceding claims 1-11 when executing the computer program.
25. A vehicle terminal comprising a memory, a processor, the memory having stored therein a computer program executable on the processor, the processor implementing the method of any of the preceding claims 1-11 when the computer program is executed.
26. A federal learning model system for predicting road conditions, the system comprising a server according to claim 24 and a plurality of vehicle terminals according to claim 25.
27. A computer readable storage medium having stored therein computer executable instructions which when executed by a processor are adapted to carry out the method of any one of claims 1-11.
CN202210622132.2A 2022-06-02 2022-06-02 Federal learning model training method applied to road condition prediction and road condition prediction method Active CN115422820B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN202210622132.2A CN115422820B (en) 2022-06-02 2022-06-02 Federal learning model training method applied to road condition prediction and road condition prediction method

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN202210622132.2A CN115422820B (en) 2022-06-02 2022-06-02 Federal learning model training method applied to road condition prediction and road condition prediction method

Publications (2)

Publication Number Publication Date
CN115422820A CN115422820A (en) 2022-12-02
CN115422820B true CN115422820B (en) 2023-09-19

Family

ID=84195716

Family Applications (1)

Application Number Title Priority Date Filing Date
CN202210622132.2A Active CN115422820B (en) 2022-06-02 2022-06-02 Federal learning model training method applied to road condition prediction and road condition prediction method

Country Status (1)

Country Link
CN (1) CN115422820B (en)

Citations (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN113159327A (en) * 2021-03-25 2021-07-23 深圳前海微众银行股份有限公司 Model training method and device based on federal learning system, and electronic equipment
CN114116198A (en) * 2021-10-21 2022-03-01 西安电子科技大学 Asynchronous federal learning method, system, equipment and terminal for mobile vehicle

Family Cites Families (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US11625624B2 (en) * 2019-09-24 2023-04-11 Ford Global Technologies, Llc Vehicle-to-everything (V2X)-based real-time vehicular incident risk prediction

Patent Citations (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN113159327A (en) * 2021-03-25 2021-07-23 深圳前海微众银行股份有限公司 Model training method and device based on federal learning system, and electronic equipment
CN114116198A (en) * 2021-10-21 2022-03-01 西安电子科技大学 Asynchronous federal learning method, system, equipment and terminal for mobile vehicle

Also Published As

Publication number Publication date
CN115422820A (en) 2022-12-02

Similar Documents

Publication Publication Date Title
US20200317190A1 (en) Collision Control Method, Electronic Device and Storage Medium
CN112669583B (en) Alarm threshold adjusting method and device, electronic equipment and storage medium
CN104537860B (en) Driving safety prompt method and device
US10491394B2 (en) Method and device for processing verification code
CN109017554B (en) Driving reminding method and device and computer readable storage medium
CN104134371A (en) Method and device for early warning of vehicle collision
CN107452221B (en) Arrival reminding method and device
CN114841377B (en) Federal learning model training method and recognition method applied to image target recognition
CN109451786B (en) Unmanned aerial vehicle management method and device and communication connection establishment method and device
CN107508573B (en) Crystal oscillator oscillation frequency correction method and device
CN112100445A (en) Image information processing method and device, electronic equipment and storage medium
CN114103985A (en) Obstacle-based prompting method, device and equipment
JP6491757B2 (en) Telephone calling method, apparatus, program, and recording medium
CN113747395A (en) Method and device for broadcasting and receiving configuration information of synchronous signal block
CN113807167A (en) Vehicle collision detection method and device, electronic device and storage medium
CN115422820B (en) Federal learning model training method applied to road condition prediction and road condition prediction method
CN110619361B (en) Method for predicting filter element blockage and device for predicting filter element blockage
CN116520886A (en) Vehicle unmanned plane following method, system, device, electronic equipment and storage medium
CN110543928A (en) method and device for detecting number of people carrying trackless rubber-tyred vehicle
CN113580987B (en) Charging control method and device of charging pile and electronic equipment
CN108989457B (en) Information processing method, server and terminal
CN113515430A (en) Method, device and equipment for monitoring state of process
CN114368357B (en) Vehicle control method, vehicle, intelligent wearable device and readable storage medium
CN114701500B (en) Vehicle lane changing method, device and medium
CN116546502B (en) Relay attack detection method, device and storage medium

Legal Events

Date Code Title Description
PB01 Publication
PB01 Publication
SE01 Entry into force of request for substantive examination
SE01 Entry into force of request for substantive examination
GR01 Patent grant
GR01 Patent grant