WO2020029589A1 - 基于联邦学习的模型参数获取方法、系统及可读存储介质 - Google Patents
基于联邦学习的模型参数获取方法、系统及可读存储介质 Download PDFInfo
- Publication number
- WO2020029589A1 WO2020029589A1 PCT/CN2019/079997 CN2019079997W WO2020029589A1 WO 2020029589 A1 WO2020029589 A1 WO 2020029589A1 CN 2019079997 W CN2019079997 W CN 2019079997W WO 2020029589 A1 WO2020029589 A1 WO 2020029589A1
- Authority
- WO
- WIPO (PCT)
- Prior art keywords
- terminal
- model
- value
- loss value
- sample
- Prior art date
Links
Images
Classifications
-
- G—PHYSICS
- G06—COMPUTING; CALCULATING OR COUNTING
- G06F—ELECTRIC DIGITAL DATA PROCESSING
- G06F21/00—Security arrangements for protecting computers, components thereof, programs or data against unauthorised activity
- G06F21/60—Protecting data
- G06F21/606—Protecting data by securing the transmission between two devices or processes
-
- G—PHYSICS
- G06—COMPUTING; CALCULATING OR COUNTING
- G06F—ELECTRIC DIGITAL DATA PROCESSING
- G06F21/00—Security arrangements for protecting computers, components thereof, programs or data against unauthorised activity
- G06F21/60—Protecting data
- G06F21/602—Providing cryptographic facilities or services
-
- G—PHYSICS
- G06—COMPUTING; CALCULATING OR COUNTING
- G06N—COMPUTING ARRANGEMENTS BASED ON SPECIFIC COMPUTATIONAL MODELS
- G06N20/00—Machine learning
-
- H—ELECTRICITY
- H04—ELECTRIC COMMUNICATION TECHNIQUE
- H04L—TRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
- H04L63/00—Network architectures or network communication protocols for network security
- H04L63/04—Network architectures or network communication protocols for network security for providing a confidential data exchange among entities communicating through data packet networks
- H04L63/0428—Network architectures or network communication protocols for network security for providing a confidential data exchange among entities communicating through data packet networks wherein the data content is protected, e.g. by encrypting or encapsulating the payload
-
- H—ELECTRICITY
- H04—ELECTRIC COMMUNICATION TECHNIQUE
- H04L—TRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
- H04L9/00—Cryptographic mechanisms or cryptographic arrangements for secret or secure communications; Network security protocols
- H04L9/008—Cryptographic mechanisms or cryptographic arrangements for secret or secure communications; Network security protocols involving homomorphic encryption
-
- H—ELECTRICITY
- H04—ELECTRIC COMMUNICATION TECHNIQUE
- H04L—TRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
- H04L9/00—Cryptographic mechanisms or cryptographic arrangements for secret or secure communications; Network security protocols
- H04L9/30—Public key, i.e. encryption algorithm being computationally infeasible to invert or user's encryption keys not requiring secrecy
-
- G—PHYSICS
- G06—COMPUTING; CALCULATING OR COUNTING
- G06F—ELECTRIC DIGITAL DATA PROCESSING
- G06F2221/00—Indexing scheme relating to security arrangements for protecting computers, components thereof, programs or data against unauthorised activity
- G06F2221/21—Indexing scheme relating to G06F21/00 and subgroups addressing additional information or applications relating to security arrangements for protecting computers, components thereof, programs or data against unauthorised activity
- G06F2221/2107—File encryption
Definitions
- the invention relates to the technical field of data processing, and in particular, to a method, a system, and a readable storage medium for acquiring model parameters based on federated learning.
- Machine learning can be applied to various fields, such as data mining, computer vision, natural language processing, biometric recognition, medical diagnosis, detection of credit card fraud, securities market analysis, and DNA (deoxyribonucleic acid, DNA ) Sequence sequencing and so on.
- Machine learning usually provides sample data to the system.
- the learning part uses the sample data to modify the system's knowledge base to improve the efficiency of the system's execution part to complete the task.
- the execution part completes the task according to the knowledge base, and at the same time, the obtained information is fed back to the learning part.
- the main purpose of the present invention is to provide a method, a system, and a readable storage medium for obtaining model parameters based on federated learning, which aims to solve the existing technical problems of how to combine data of all parties and improve the accuracy of the obtained model.
- the present invention provides a method for acquiring model parameters based on federation learning.
- the method for acquiring model parameters based on federation learning includes steps:
- the third terminal When the third terminal receives the encrypted loss value sent by the second terminal, the third terminal decrypts the loss value to obtain the decrypted loss value, where the loss value corresponds to the first terminal Calculated by calculating the first data and the second data corresponding to the second terminal;
- a sample parameter corresponding to the gradient value is determined, and a sample parameter corresponding to the gradient value is determined as a model parameter of the model to be trained.
- the third terminal decrypts the loss value, and before the step of obtaining the decrypted loss value, the method further includes:
- the second terminal When the second terminal receives the encrypted first data sent by the first terminal, the second terminal calculates the second data corresponding to the first data, and obtains the second data corresponding to the second data. Sample labels, wherein the sample labels corresponding to the first data and the second data are the same;
- a homomorphic encryption algorithm is used to encrypt the loss value to obtain the encrypted loss value, and send the encrypted loss value to the third terminal.
- the method further includes:
- the first terminal calculates first data according to the updated sample parameters and variable values corresponding to feature variables in the intersection sample data, and calculates the first data, and A piece of data is encrypted, and the encrypted first data is sent to the second terminal.
- the step of the second terminal correspondingly updating the sample parameters according to the updated gradient value includes:
- the second terminal After the second terminal receives the updated gradient value, the second terminal calculates a product between the updated gradient value and a preset coefficient
- the third terminal decrypts the loss value, and before the step of obtaining the decrypted loss value, the method further includes:
- the first terminal encrypts a first sample identifier by using a pre-stored first public key, and sends the encrypted first sample identifier to the second terminal, and detects whether the first terminal identifier is received by the second terminal, A second sample identifier encrypted by using a pre-stored second public key;
- the second sample ID is encrypted again by using the first public key to obtain a second encrypted value, and it is detected whether the first sample sent by the second terminal is received.
- first encrypted value is equal to the second encrypted value, determining that the first sample ID is the same as the second sample ID, and determining sample data corresponding to the first sample ID as Intersection sample data of the second terminal.
- the method further includes:
- the second terminal determines a model parameter and receives an execution request
- the second terminal sends the execution request to the first terminal for the first terminal to receive the execution request after receiving the execution request. Returning a first prediction score to the second terminal according to the corresponding model parameter and the variable value of the corresponding feature variable of the execution request;
- the step of detecting whether the model to be trained is in a convergence state based on the decrypted loss value includes:
- the present invention also provides a model parameter acquisition system.
- the model parameter acquisition system includes a memory, a processor, and a federated learning-based system stored on the memory and operable on the processor.
- a model parameter acquisition program that, when executed by the processor, implements the steps of the federal learning-based model parameter acquisition method described above.
- the present invention also provides a computer-readable storage medium, where the computer-readable storage medium stores a model parameter acquisition program based on federal learning, and the program parameter acquisition program based on federal learning is processed Implementing the steps of the method for obtaining model parameters based on federation learning as described above when the processor executes.
- the third terminal decrypts the loss value to obtain the decrypted loss value, wherein the loss value is obtained through the first terminal and the second terminal.
- the third terminal decrypts the loss value to obtain the decrypted loss value, wherein the loss value is obtained through the first terminal and the second terminal.
- Calculated from the sample data detecting whether the model to be trained is in a convergent state based on the decrypted loss value; if it is detected that the model to be trained is in a convergent state, obtaining the gradient value corresponding to the loss value; determining the sample parameters corresponding to the gradient value, The sample parameters corresponding to the gradient values are determined as the model parameters of the model to be trained.
- the combined calculation of the sample data of the first terminal and the second terminal is implemented to obtain the loss value, so as to help learn to determine the model parameters in the model to be trained by combining the sample data of the first terminal and the second terminal, and improve the accuracy of the trained model degree.
- FIG. 1 is a schematic structural diagram of a hardware operating environment involved in a solution according to an embodiment of the present invention
- FIG. 2 is a schematic flowchart of a first embodiment of a method for acquiring model parameters based on federated learning according to the present invention
- FIG. 3 is a schematic flowchart of a second embodiment of a method for acquiring model parameters based on federated learning according to the present invention
- FIG. 4 is a schematic flowchart of a third embodiment of a method for acquiring model parameters based on federated learning according to the present invention.
- FIG. 1 is a schematic structural diagram of a hardware operating environment involved in a solution according to an embodiment of the present invention.
- FIG. 1 is a schematic structural diagram of a hardware operating environment of the model parameter acquisition system.
- the model parameter acquisition system in the embodiment of the present invention may be a terminal device such as a PC, a portable computer, or the like.
- the model parameter acquisition system may include a processor 1001, such as a CPU, a network interface 1004, a user interface 1003, a memory 1005, and a communication bus 1002.
- the communication bus 1002 is used to implement connection and communication between these components.
- the user interface 1003 may include a display, an input unit such as a keyboard, and the optional user interface 1003 may further include a standard wired interface and a wireless interface.
- the network interface 1004 may optionally include a standard wired interface and a wireless interface (such as a WI-FI interface).
- the memory 1005 may be a high-speed RAM memory or a non-volatile memory (for example, a magnetic disk memory).
- the memory 1005 may optionally be a storage device independent of the foregoing processor 1001.
- model parameter acquisition system shown in FIG. 1 does not constitute a limitation on the model parameter acquisition system, and may include more or fewer components than shown, or some components may be combined, or different Of the components.
- a memory 1005 as a computer storage medium may include an operating system, a network communication module, a user interface module, and a model parameter acquisition program based on federation learning.
- the operating system is a program that manages and controls model parameter acquisition system hardware and software resources, and supports federation-based model parameter acquisition programs and other software or program operations.
- the user interface 1003 is mainly used to connect the first terminal, the second terminal, and the third terminal to perform data communication with each terminal;
- the network interface 1004 is mainly used to connect to the background server and The background server performs data communication;
- the processor 1001 can be used to call the federal learning-based model parameter acquisition program stored in the memory 1005 and perform the following operations:
- the third terminal When the third terminal receives the encrypted loss value sent by the second terminal, it controls the third terminal to decrypt the loss value to obtain the decrypted loss value, where the loss value is passed through the first terminal Calculated by corresponding first data and second data corresponding to the second terminal;
- a sample parameter corresponding to the gradient value is determined, and a sample parameter corresponding to the gradient value is determined as a model parameter of the model to be trained.
- the processor 1001 It can also be used to call the federation-based model parameter acquisition program stored in the memory 1005, and perform the following steps:
- the second terminal After the second terminal receives the encrypted first data sent by the first terminal, control the second terminal to calculate the second data corresponding to the first data, and obtain the second data corresponding to A sample label, wherein the sample labels corresponding to the first data and the second data are the same;
- a homomorphic encryption algorithm is used to encrypt the loss value to obtain the encrypted loss value, and send the encrypted loss value to the third terminal.
- the processor 1001 may be further configured to call a federation-based model parameter acquisition program stored in the memory 1005 and execute the following: step:
- the first terminal calculates first data according to the updated sample parameters and variable values corresponding to feature variables in the intersection sample data, and calculates the first data, and A piece of data is encrypted, and the encrypted first data is sent to the second terminal.
- step of the second terminal correspondingly updating the sample parameters according to the updated gradient value includes:
- the second terminal After the second terminal receives the updated gradient value, the second terminal calculates a product between the updated gradient value and a preset coefficient
- the processor 1001 It can also be used to call the federation-based model parameter acquisition program stored in the memory 1005, and perform the following steps:
- the second sample ID is encrypted again by using the first public key to obtain a second encrypted value, and it is detected whether the first sample sent by the second terminal is received.
- first encrypted value is equal to the second encrypted value, determining that the first sample ID is the same as the second sample ID, and determining sample data corresponding to the first sample ID as Intersection sample data of the second terminal.
- the processor 1001 may be further configured to call the memory 1005
- the federation-based model parameter acquisition program stored in the program and performs the following steps:
- the second terminal After the second terminal determines a model parameter and receives an execution request, the second terminal is controlled to send the execution request to the first terminal so that the first terminal receives the execution request And returning a first prediction score to the second terminal according to the corresponding model parameter and the variable value corresponding to the characteristic variable of the execution request;
- the step of detecting whether the model to be trained is in a convergence state according to the decrypted loss value includes:
- FIG. 2 is a schematic flowchart of a first embodiment of a method for acquiring model parameters based on federated learning according to the present invention.
- This embodiment of the present invention provides an embodiment of a method for acquiring model parameters based on federated learning. It should be noted that although the logical sequence is shown in the flowchart, in some cases, it can be performed in a different order than here. The steps shown or described.
- Methods for obtaining model parameters based on federated learning include:
- Step S10 After the third terminal receives the encrypted loss value sent by the second terminal, the third terminal decrypts the loss value to obtain the decrypted loss value, where the loss value is The first data corresponding to one terminal and the second data corresponding to the second terminal are calculated.
- the third terminal After the third terminal receives the encrypted loss value sent by the second terminal, the third terminal decrypts the loss value to obtain the decrypted loss value.
- the loss value is calculated by the second terminal according to the first data sent by the first terminal and the second data corresponding to the first data, and the first data is based on the sample data of the first terminal and the corresponding sample.
- the parameter is calculated, and the second data is calculated by the second terminal according to its sample data and corresponding sample parameters.
- the loss value contains multiple calculation factors.
- the second terminal uses the public key sent by the third terminal to encrypt each calculation factor through a homomorphic encryption addition algorithm to obtain the encrypted calculation factor, and adds the encrypted calculation factors to obtain the encrypted loss. And send the encrypted loss value to the third terminal.
- the third terminal When the third terminal receives the encrypted loss value, it obtains the encrypted calculation factor corresponding to the encrypted loss value, and decrypts the encrypted calculation factor by using the private key corresponding to the second terminal's encrypted calculation factor public key to obtain The original calculation factor. The decrypted loss value is obtained through the original calculation factor.
- the third terminal when the third terminal generates the public key and the private key by using an asymmetric encryption algorithm, the third terminal sends the public key to the first terminal and the second terminal, so that the first terminal and the second terminal correspondingly encrypt according to the public key. Data to be transmitted.
- the first terminal, the second terminal, and the third terminal may be a smart phone, a personal computer, a server, and the like.
- step S20 it is detected whether the model to be trained is in a convergence state according to the decrypted loss value.
- the third terminal After the third terminal obtains the decrypted loss value, the third terminal detects whether the model to be trained is in a convergence state according to the decrypted loss value.
- step S20 includes:
- Step a Obtain a first loss value sent by the second terminal last time, and record the decrypted loss value as a second loss value.
- the third terminal obtains the decrypted loss value
- the third terminal obtains the first loss value sent by the second terminal last time, and records the decrypted loss value as the second loss value.
- the first loss value is also the loss value after the third terminal decrypts. It can be understood that the first loss value is a loss value sent by the second terminal last time, and the second loss value is a loss value currently sent by the second terminal.
- Step b Calculate a difference between the first loss value and the second loss value, and determine whether the difference is less than or equal to a preset threshold.
- step c when it is determined that the difference is less than or equal to the preset threshold, it is determined that the model to be trained is in a convergence state.
- step d when it is determined that the difference is greater than the preset threshold, it is determined that the model to be trained is not in a convergent state.
- the third terminal After the third terminal obtains the first loss value and the second loss value, the third terminal calculates a difference between the first loss value and the second loss value, and determines whether the difference is less than or equal to a preset threshold. When it is determined that the difference is less than or equal to a preset threshold, the third terminal determines that the model to be trained is in a convergence state; when it is determined that the difference is greater than a preset threshold, the third terminal determines that the model to be trained is not in a convergence state.
- the specific value of the preset threshold may be set according to specific needs. In this embodiment, the value corresponding to the preset threshold is not specifically limited.
- step S30 if it is detected that the model to be trained is in a convergence state, a gradient value corresponding to the loss value is obtained.
- Step S40 Determine a sample parameter corresponding to the gradient value, and determine a sample parameter corresponding to the gradient value as a model parameter of the model to be trained.
- the third terminal obtains a gradient value corresponding to the loss value, and determines sample parameters corresponding to the gradient value, and determines the sample parameters corresponding to the gradient value as model parameters of the model to be trained .
- there are two gradient values corresponding to the loss value which are the gradient value sent by the first terminal to the third terminal, and the gradient value sent by the second terminal to the third terminal.
- the first terminal calculates its corresponding gradient value, it encrypts its gradient value, and sends the encrypted gradient value to the third terminal.
- the second terminal sends the encrypted loss value to the third terminal, the second terminal sends the encrypted gradient value to the third terminal together.
- the encryption method of the encryption gradient value and the encryption loss value of the second terminal is the same, which will not be described in detail in this embodiment.
- the method for encrypting the gradient value at the first terminal is the same as the method for encrypting the gradient value at the second terminal, which is not described in detail in this embodiment.
- the loss value and the encrypted value sent by the second terminal to the third terminal are corresponding to the sample parameters corresponding to the first terminal and the second terminal, the variable values corresponding to the characteristic variables, and the sample data of the intersection of the second terminal. Calculated from sample tag values.
- the sample parameters corresponding to the first terminal and the second terminal may be the same or different.
- the gradient value and the loss value are iteratively updated until the model to be trained is in a convergent state.
- the model to be trained there are model parameters corresponding to the first terminal and model parameters corresponding to the second terminal.
- the third terminal may use the sample parameter corresponding to the first terminal in the corresponding gradient value as the model parameter corresponding to the first terminal in the model to be trained, and the second parameter The sample parameters corresponding to the terminal are used as the model parameters corresponding to the second terminal in the model to be trained.
- the third terminal determines the model parameters, it sends a prompt message to the first terminal and the second terminal to prompt the model parameters corresponding to the first terminal and the second terminal according to the prompt information.
- both the first terminal and the second terminal have corresponding model parameters, the model parameters corresponding to the first terminal are stored by the first terminal, and the model parameters corresponding to the second terminal are stored by the second terminal.
- the third terminal decrypts the loss value to obtain the decrypted loss value, where the loss value is obtained through the first terminal and the second terminal. Calculated from the sample data of the test; check whether the model to be trained is in a convergent state based on the decrypted loss value; if it is detected that the model to be trained is in a convergent state, obtain the gradient value corresponding to the loss value; determine the sample parameters corresponding to the gradient value , Determine the sample parameters corresponding to the gradient value as the model parameters of the model to be trained.
- the combined calculation of the sample data of the first terminal and the second terminal is implemented to obtain the loss value, so as to help learn to determine the model parameters in the model to be trained by combining the sample data of the first terminal and the second terminal, and improve the accuracy of the trained model degree.
- the second embodiment of the method for obtaining model parameters based on federation learning is different from the first embodiment of the method for obtaining model parameters based on federation learning.
- the method for obtaining model parameters based on federation learning further includes:
- Step S50 After the second terminal receives the encrypted first data sent by the first terminal, the second terminal calculates the second data corresponding to the first data, and acquires the second data Sample labels corresponding to the data, wherein the sample labels corresponding to the first data and the second data are the same.
- the second terminal After the second terminal receives the first data sent by the first terminal, the second terminal calculates the second data corresponding to the first data, and obtains a sample tag corresponding to the second data.
- the first data is a sum of a product of a sample parameter in the first terminal and a corresponding variable value in a feature variable in the sample data of the intersection of the first terminal, and a square of the sum of the products.
- the calculation formula corresponding to the original first data is: The square of the sum of the products is expressed as: Among them, w 1 , w 2 ... w n represent the sample parameters corresponding to the first terminal, and the number of variable values corresponding to the characteristic variables in the first terminal is equal to the number of sample parameters corresponding to the first terminal, that is, one variable value corresponds to one sample Parameter, x represents the eigenvalue of the feature variable, 1,2 ... n represents the corresponding variable value and the number of sample parameters. For example, when there are three variable values for each feature variable in the first terminal intersection sample data, then it should be noted that the first data sent by the first terminal to the second terminal is the encrypted first data.
- the first terminal uses the public key sent by the third terminal to pass the homomorphic encryption algorithm. Encrypt the first data to obtain the encrypted first data, and send the encrypted first data to the second terminal.
- the first data sent to the second terminal that is, the encrypted first data can be expressed as [[u A ]] and
- the process of calculating the second data by the second terminal is similar to the process of calculating the first data by the first terminal.
- the formula for calculating the sum of the product of the sample parameter in the second terminal and the feature variable corresponding to the variable in the sample data at the intersection of the second terminal is Wherein, w 1 , w 2 ... w n represent sample parameters corresponding to the feature values of each sample data feature variable in the second terminal. It should be noted that the sample identifiers corresponding to the first data and the second data are the same.
- each sample data has a corresponding sample identifier, but the sample data of the first terminal does not have a sample tag, the sample data of the second terminal has a sample tag, and one sample The ID corresponds to a sample label.
- Each sample data has at least one characteristic variable, and each characteristic variable has at least one variable value.
- the sample ID of each sample data is different.
- the sample ID of each sample data is also different, but the sample labels corresponding to different sample data may be the same or different. .
- Step S60 Calculate a loss value according to the sample label, the first data, and the second data.
- step S70 the loss value is encrypted by using a homomorphic encryption algorithm to obtain the encrypted loss value, and the encrypted loss value is sent to the third terminal.
- the second terminal After the second terminal obtains the sample tag corresponding to the second data, the first data sent by the first terminal, and the calculated second data, the second terminal according to the tag value corresponding to the sample tag, the first data, and the second data The loss is calculated.
- the loss value is expressed as loss
- the encrypted loss value is expressed as [[loss]]
- y represents the label value of the second data corresponding to the sample label
- the value of the label value corresponding to the sample label can be set according to specific needs. For example, in this embodiment, “0” and “1” can be used to indicate the correspondence of different sample labels.
- the tag value is expressed as loss
- the encrypted loss value is expressed as [[loss]]
- the second terminal uses the public key sent by the third terminal to encrypt each calculation factor for calculating the loss value through the homomorphic encryption algorithm to obtain the encrypted loss value, and the encrypted loss The value is sent to the third terminal.
- log2, yw T x, and (w T x) 2 are calculation factors for calculating the loss value. It should be noted that, in this embodiment, [[x]] is used to indicate x after encryption.
- the parameter server is adopted.
- Both the first terminal and the second terminal have independent parameter servers, which are used to synchronize the aggregation and update of the respective sample data, while avoiding the leakage of the respective sample data, and
- the sample parameters corresponding to the first terminal and the second terminal, that is, the model parameters are stored separately, which improves the data security of the first terminal and the second terminal.
- the loss value is calculated according to the first data of the first terminal, the second data of the second terminal, and the sample label corresponding to the second data, and the data required for calculating the loss value is encrypted by using a homomorphic encryption algorithm, so that the first In the process of calculating the loss value of the two terminals, the specific sample data of the first terminal cannot be obtained, which realizes that in the process of calculating the model parameters of the first terminal and the second terminal sample data, the first terminal and the second terminal are not exposed.
- the loss value required to calculate the model parameters is calculated on the basis of the sample data, which improves the privacy of the sample data of the first terminal and the second terminal in the process of calculating the model parameters.
- the third embodiment of the method for acquiring model parameters based on federal learning is different from the first or second embodiment of the method for acquiring model parameters based on federal learning.
- the method for acquiring model parameters based on federal learning further includes :
- Step S80 if it is detected that the model to be trained is not in the convergence state, obtain a gradient value sent by the second terminal and the first terminal, and update the gradient value to obtain the updated gradient value.
- the third terminal obtains the gradient values sent by the second terminal and the first terminal, and updates the gradient values corresponding to the first terminal and the second terminal to obtain the first terminal and the The updated gradient value corresponding to the two terminals.
- the gradient value sent to the third terminal is also the public key sent by the third terminal, and is homomorphically encrypted After the algorithm is encrypted.
- the formula for the second terminal to calculate its corresponding gradient value is: The gradient value sent by the second terminal to the third terminal is expressed as [[g B ]].
- the second terminal After the second terminal calculates [[d]], it sends [[d]] to the first terminal. After the first terminal receives [[d]] sent by the second terminal, the first terminal calculates its corresponding gradient value according to [[d]], and sends its corresponding gradient value to the third terminal.
- the third terminal may first use its private key to decrypt the gradient value sent by the first terminal and the second terminal, and then derive the gradient value after decryption to obtain the updated gradient value. Further, the third terminal may reduce or increase the decrypted gradient value according to a certain proportion of the model to be trained to obtain an updated gradient value.
- Step S90 Send the updated gradient value to the first terminal and the second terminal for the first terminal and the second terminal to update the sample parameters correspondingly according to the updated gradient value.
- the first terminal calculates first data according to the updated sample parameters and variable values corresponding to feature variables in the intersection sample data, and calculates the first data, and A piece of data is encrypted, and the encrypted first data is sent to the second terminal.
- the third terminal After the third terminal obtains the updated gradient value, it sends the updated gradient value corresponding to the first terminal to the first terminal, and sends the updated gradient value corresponding to the second terminal to the second terminal. After the first terminal receives the updated gradient value sent by the third terminal, the first terminal updates its corresponding sample parameter according to the updated gradient value.
- the first terminal After the first terminal updates the sample parameters, the first terminal obtains the feature variables corresponding to its intersection sample data, determines the variable values corresponding to the feature variables, and calculates the first data based on the variable values and the updated sample parameters, and encrypts the The first data is sent to the second terminal after the encrypted first data.
- the process of calculating the first data by the first terminal has been described in detail in the second embodiment, and will not be described in detail in this embodiment.
- step of the second terminal correspondingly updating the sample parameters according to the updated gradient value includes:
- Step g After the second terminal receives the updated gradient value, the second terminal calculates a product between the updated gradient value and a preset coefficient.
- Step h subtract the product from the sample parameters before the update to obtain the updated sample parameters.
- the second terminal calculates a product between the updated gradient value and a preset coefficient, and subtracts the product from the sample parameter to obtain an updated sample. parameter.
- the n corresponding to the first terminal and the second terminal may be the same or different.
- the third terminal may update the corresponding gradient value and send the updated gradient value to the first terminal and the second terminal for the first terminal and the third terminal.
- the two terminals After receiving the updated gradient value, the two terminals update the sample parameters corresponding to the updated gradient value, and use the updated sample parameter as the model parameter.
- the third terminal updates the gradient value, and sends the updated gradient value to the first terminal and the second terminal for the first terminal and the second terminal to
- the updated gradient value updates the corresponding sample parameters until the model to be trained is in a convergent state to improve the accuracy of the analysis data of the model to be trained.
- the difference between the fourth embodiment of the method for obtaining model parameters based on federal learning and the first, second or third embodiment of the method for obtaining model parameters based on federal learning is that the method for obtaining model parameters based on federal learning further includes:
- step i the first terminal encrypts the first sample identifier by using a pre-stored first public key, and sends the encrypted first sample identifier to the second terminal, and detects whether the second terminal is received.
- the second sample identifier sent is encrypted using the pre-stored second public key.
- the first terminal encrypts the first sample identifier by using the first public key stored in advance, obtains the encrypted first sample identifier, and sends the encrypted first sample identifier To the second terminal.
- the first terminal detects whether the second sample identifier sent by the second terminal is encrypted using the pre-stored second public key.
- the second terminal encrypts the second sample identifier using the pre-stored second public key, obtains the encrypted second sample identifier, and sends the encrypted second sample identifier to the first terminal.
- the encrypted first sample identifier is obtained after the first terminal encrypts the data identifier corresponding to the sample data held by it, and the second sample identifier is the data identifier corresponding to the second terminal sample data.
- the first terminal may use the public key generated in advance to encrypt the first sample identifier.
- the public key used by the first terminal and the second terminal for encryption is generated by an asymmetric encryption algorithm.
- Step j After receiving the encrypted second sample ID, use the first public key to perform second encryption on the second sample ID to obtain a second encrypted value, and detect whether the second terminal is received. The first encrypted value sent.
- the first terminal When the first terminal receives the encrypted second sample identifier sent by the second terminal, the first terminal uses its public key, that is, uses the first public key to perform second encryption on the second sample identifier.
- the second sample identifier of is recorded as the second encrypted value, and it is detected whether the first encrypted value sent by the second terminal is received.
- the second terminal After the second terminal receives the encrypted first sample identifier sent by the first terminal, the second terminal uses its public key, that is, uses the second public key to perform second encryption on the encrypted second sample identifier.
- the first sample identifier after the second encryption is recorded as the first encrypted value, and the first encrypted value is sent to the first terminal.
- Step k after receiving the encrypted value, determine whether the first encrypted value is equal to the second encrypted value.
- Step l if the first encrypted value is equal to the second encrypted value, determine that the first sample identifier is the same as the second sample identifier, and compare the sample data corresponding to the first sample identifier Determined as the intersection sample data with the second terminal.
- the first terminal determines whether the first encrypted value is equal to the second encrypted value. If it is determined that the first encrypted value is equal to the second encrypted value, the first terminal determines that the sample data corresponding to the first sample identifier is the intersection sample data; if it is determined that the first encrypted value is not equal to the second encrypted value, the first terminal It is determined that the sample data carrying the first sample identifier is not intersection sample data. It can be understood that when the first encrypted value is equal to the second encrypted value, it indicates that the first sample identifier corresponding to the first encrypted value and the second sample identifier corresponding to the second encrypted value are the same.
- the process of determining the intersection sample data is: (1)
- the second terminal compares id_a_fa_fb (first encrypted value) and id_b_fb_fa (second encrypted value). If the two encrypted strings are equal, it means that id_a and id_b are the same.
- the sample data of the first terminal is: ⁇ id1: x1, x2>, ⁇ id2: x1, x2>, ⁇ id3: x1, x2> ⁇
- the sample data of the second terminal is: ⁇ id2: x3, x4 >, ⁇ Id3: x3, x4>, ⁇ id4: x3, x4>
- the intersection sample data in the second terminal is: ⁇ id2: x3, x4>, ⁇ id3: x3, x4> ⁇
- the intersection sample data is: ⁇ id2: x1, x2>, ⁇ id3: x1, x2> ⁇ .
- the first terminal may divide its intersection sample data into several shares, and then the second terminal may The terminal divides the division result of the sample data, and matches by the sample identification pair to divide the intersection sample data of itself.
- the first terminal and the second terminal can obtain the sample data of the intersection of the sample data of the first terminal and the second terminal without leaking the data owned by the first terminal and the second terminal. Data security of the second terminal.
- the difference between the fourth embodiment of the method for obtaining model parameters based on federal learning and the first, second, third, or fourth embodiment of the method for obtaining model parameters based on federal learning differs from the method for obtaining model parameters based on federal learning Also includes:
- Step m After the second terminal determines the model parameters and receives the execution request, the second terminal sends the execution request to the first terminal for the first terminal to receive the After executing the request, a first prediction score is returned to the second terminal according to the corresponding model parameter and the variable value of the characteristic variable corresponding to the execution request.
- the second terminal After the second terminal determines the model parameters, the second terminal detects whether an execution request is received. When the second terminal receives the execution request, the second terminal sends the execution request to the first terminal. After the first terminal receives the execution request, the first terminal obtains its corresponding model parameters and variable values of the characteristic variables corresponding to the execution request, calculates a first prediction score according to the model parameters and the variable values, and The prediction score is sent to the second terminal. It can be understood that the formula for the first terminal to calculate the first prediction score is:
- step n after receiving the first prediction score, a second prediction score is calculated according to the corresponding model parameter and the variable value corresponding to the characteristic variable of the execution request.
- the second terminal After the second terminal receives the first prediction score sent by the first terminal, the second terminal calculates the second prediction score according to the corresponding model parameter and the variable value of the characteristic variable corresponding to the execution request.
- the formula for the second terminal to calculate the second prediction score is:
- Step o add the first prediction score and the second prediction score to obtain a total prediction score, and input the prediction score to the model to be trained to obtain a model score, and according to the model score It is determined whether to execute the execution request.
- the second terminal After the second terminal obtains the first prediction score and the second prediction score, the second terminal adds the first prediction score and the second prediction score to obtain the sum of the prediction scores, and inputs the sum of the prediction scores into the model to be trained to obtain Model score.
- the expression of the sum of predicted scores is: ,
- the expression of the model to be trained is
- the second terminal may determine whether to execute the execution request according to the model score. For example, when the model to be trained is a fraud model and the execution request is a loan request, if the calculated model score is greater than or equal to a preset score, the second terminal determines that the loan request is a fraud request and refuses to execute the loan request; if The calculated model score is less than a preset score, and the second terminal determines that the loan request is a real loan request and executes the loan request.
- the execution request is analyzed by the model to be trained to determine whether to execute the execution request, which improves the security of the execution process of the second terminal.
- an embodiment of the present invention also provides a computer-readable storage medium.
- the computer-readable storage medium stores a model parameter acquisition program based on federation learning, and the model parameter acquisition program based on federation learning is executed by a processor. Implement the steps of the reward sending method as described above.
- the specific implementation manner of the computer-readable storage medium of the present invention is basically the same as each embodiment of the method for acquiring model parameters based on the federal learning, and is not repeated here.
- the methods in the above embodiments can be implemented by means of software plus a necessary universal hardware platform, and of course, also by hardware, but in many cases the former is better.
- Implementation Based on such an understanding, the technical solution of the present invention, in essence, or a part that contributes to the prior art, can be embodied in the form of a software product, which is stored in a storage medium (such as ROM / RAM, magnetic disk, The optical disc) includes a plurality of instructions for causing a terminal device (which may be a mobile phone, a computer, a server, an air conditioner, or a network device, etc.) to execute the methods described in the embodiments of the present invention.
- a terminal device which may be a mobile phone, a computer, a server, an air conditioner, or a network device, etc.
Landscapes
- Engineering & Computer Science (AREA)
- Theoretical Computer Science (AREA)
- Computer Security & Cryptography (AREA)
- Software Systems (AREA)
- General Engineering & Computer Science (AREA)
- Computing Systems (AREA)
- Signal Processing (AREA)
- Computer Networks & Wireless Communication (AREA)
- General Physics & Mathematics (AREA)
- Physics & Mathematics (AREA)
- Computer Hardware Design (AREA)
- Artificial Intelligence (AREA)
- Evolutionary Computation (AREA)
- Data Mining & Analysis (AREA)
- Computer Vision & Pattern Recognition (AREA)
- Mathematical Physics (AREA)
- Medical Informatics (AREA)
- Health & Medical Sciences (AREA)
- Bioethics (AREA)
- General Health & Medical Sciences (AREA)
- Information Retrieval, Db Structures And Fs Structures Therefor (AREA)
- Storage Device Security (AREA)
- Complex Calculations (AREA)
Abstract
一种基于联邦学习的模型参数获取方法、系统及可读存储介质,该方法包括步骤:当第三终端接收到第二终端发送的加密后的损失值后,所述第三终端解密所述损失值,得到解密后的所述损失值,其中,所述损失值是通过第一终端对应的第一数据和所述第二终端对应的第二数据计算得到的(S10);根据解密后的所述损失值检测待训练模型是否处于收敛状态(S20);若检测到待训练模型处于收敛状态,则获取与损失值对应的梯度值(S30);确定与梯度值对应的样本参数,将与梯度值对应的样本参数确定为待训练模型的模型参数(S40)。该方法实现了联合第一终端和第二终端的样本数据计算得到损失值,以通过联合第一终端和第二终端的样本数据联合帮助学习确定待训练模型中的模型参数,提高了训练所得模型的准确度。
Description
本申请要求于2018年8月10日提交中国专利局、申请号为201810913275.2、发明名称为“基于联邦学习的模型参数获取方法、系统及可读存储介质”的中国专利申请的优先权,其全部内容通过引用结合在申请中。
本发明涉及数据处理技术领域,尤其涉及一种基于联邦学习的模型参数获取方法、系统及可读存储介质。
随着机器学习的快速发展,机器学习可应用于各个领域,如数据挖掘、计算机视觉、自然语言处理、生物特征识别、医学诊断、检测信用卡欺诈、证券市场分析和DNA(deoxyribonucleic acid,脱氧核糖核酸)序列测序等。机器学习通常是系统提供样本数据,学习部分利用样本数据修改系统的知识库,以增进系统执行部分完成任务的效能,执行部分根据知识库完成任务,同时把获得的信息反馈给学习部分。
目前,由于各方的样本数据具有密切联系,如果机器学习仅使用一方的样本数据,则学习得到的模型不准确,因此,如何联合各方的样本数据,得到模型中的参数,提高模型的准确度,是亟待解决的问题。
发明内容
本发明的主要目的在于提供一种基于联邦学习的模型参数获取方法、系统及可读存储介质,旨在解决现有的如何联合各方数据,提高所得模型的准确度的技术问题。
为实现上述目的,本发明提供一种基于联邦学习的模型参数获取方法,所述基于联邦学习的模型参数获取方法包括步骤:
当第三终端接收到第二终端发送的加密后的损失值后,所述第三终端解密所述损失值,得到解密后的所述损失值,其中,所述损失值 是通过第一终端对应的第一数据和所述第二终端对应的第二数据计算得到的;
根据解密后的所述损失值检测待训练模型是否处于收敛状态;
若检测到所述待训练模型处于收敛状态,则获取与所述损失值对应的梯度值;
确定与所述梯度值对应的样本参数,将与所述梯度值对应的样本参数确定为所述待训练模型的模型参数。
优选地,所述当第三终端接收到第二终端发送的加密后的损失值后,所述第三终端解密所述损失值,得到解密后的所述损失值的步骤之前,还包括:
当所述第二终端接收到所述第一终端发送的加密后的第一数据后,所述第二终端计算与所述第一数据对应的第二数据,以及获取所述第二数据对应的样本标签,其中,所述第一数据和所述第二数据对应的样本标签相同;
根据所述样本标签、所述第一数据和所述第二数据计算损失值;
采用同态加密算法加密所述损失值,得到加密后的所述损失值,并将加密后的所述损失值发送给所述第三终端。
优选地,所述根据解密后的所述损失值检测待训练模型是否处于收敛状态的步骤之后,还包括:
若检测到所述待训练模型未处于所述收敛状态,则获取所述第二终端和所述第一终端发送的梯度值,并更新所述梯度值,得到更新后的所述梯度值;
将更新后的所述梯度值发送给所述第一终端和所述第二终端,以供所述第一终端和所述第二终端根据更新后的所述梯度值对应更新样本参数;
其中,当所述第一终端更新所述样本参数后,所述第一终端根据更新后的所述样本参数和交集样本数据中特征变量对应的变量值计算得到第一数据,并对所述第一数据进行加密,将加密后的第一数据发送给所述第二终端。
优选地,所述第二终端根据更新后的所述梯度值对应更新样本参 数的步骤包括:
当第二终端接收到更新后的所述梯度值后,所述第二终端计算更新后的所述梯度值与预设系数之间的乘积;
将更新前的样本参数减去所述乘积,得到更新后的所述样本参数。
优选地,所述当第三终端接收到第二终端发送的加密后的损失值后,所述第三终端解密所述损失值,得到解密后的所述损失值的步骤之前,还包括:
所述第一终端采用预存的第一公钥加密第一样本标识,并将加密后的第一样本标识发送给所述第二终端,并检测是否接收到所述第二终端发送的,采用预存的第二公钥加密后的第二样本标识;
当接收到加密后的第二样本标识后,采用所述第一公钥对所述第二样本标识进行二次加密,得到第二加密值,并检测是否接收到所述第二终端发送的第一加密值;
当接收到所述加密值后,判断所述第一加密值与所述第二加密值是否相等;
若所述第一加密值与所述第二加密值相等,则确定所述第一样本标识与所述第二样本标识相同,并将所述第一样本标识对应的样本数据确定为与所述第二终端的交集样本数据。
优选地,所述确定与所述梯度值对应的样本参数,将与所述梯度值对应的样本参数确定为所述待训练模型的模型参数的步骤之后,还包括:
当所述第二终端确定模型参数,且接收到执行请求后,所述第二终端将所述执行请求发送给所述第一终端,以供所述第一终端在接收到所述执行请求后,根据对应的所述模型参数和所述执行请求对应特征变量的变量值返回第一预测分数给所述第二终端;
当接收到所述第一预测分数后,根据对应的所述模型参数和所述执行请求对应特征变量的变量值计算第二预测分数;
将所述第一预测分数和所述第二预测分数相加,得到预测分数总和,并根据所述预测分数总和输入所述待训练模型中,得到模型分数,并根据所述模型分数确定是否执行所述执行请求。
优选地,所述根据解密后的所述损失值检测待训练模型是否处于收敛状态的步骤包括:
获取所述第二终端前一次发送的第一损失值,并将解密后的所述损失值记为第二损失值;
计算所述第一损失值和所述第二损失值之间的差值,并判断所述差值是否小于或者等于预设阈值;
当确定所述差值小于或者等于所述预设阈值时,确定所述待训练模型处于收敛状态;
当确定所述差值大于所述预设阈值时,确定所述待训练模型未处于收敛状态。
此外,为实现上述目的,本发明还提供一种模型参数获取系统,所述模型参数获取系统包括存储器、处理器和存储在所述存储器上并可在所述处理器上运行的基于联邦学习的模型参数获取程序,所述基于联邦学习的模型参数获取程序被所述处理器执行时实现如上所述的基于联邦学习的模型参数获取方法的步骤。
此外,为实现上述目的,本发明还提供一种计算机可读存储介质,所述计算机可读存储介质上存储有基于联邦学习的模型参数获取程序,所述基于联邦学习的模型参数获取程序被处理器执行时实现如上所述的基于联邦学习的模型参数获取方法的步骤。
本发明通过当第三终端接收到第二终端发送的加密后的损失值后,第三终端解密损失值,得到解密后的损失值,其中,损失值是通过第一终端和第二终端中的样本数据计算得到的;根据解密后的损失值检测待训练模型是否处于收敛状态;若检测到待训练模型处于收敛状态,则获取与损失值对应的梯度值;确定与梯度值对应的样本参数,将与梯度值对应的样本参数确定为待训练模型的模型参数。实现了联合第一终端和第二终端的样本数据计算得到损失值,以通过联合第一终端和第二终端的样本数据联合帮助学习确定待训练模型中的模型参数,提高了训练所得模型的准确度。
图1是本发明实施例方案涉及的硬件运行环境的结构示意图;
图2为本发明基于联邦学习的模型参数获取方法第一实施例的流程示意图;
图3为本发明基于联邦学习的模型参数获取方法第二实施例的流程示意图;
图4为本发明基于联邦学习的模型参数获取方法第三实施例的流程示意图。
本发明目的的实现、功能特点及优点将结合实施例,参照附图做进一步说明。
应当理解,此处所描述的具体实施例仅仅用以解释本发明,并不用于限定本发明。
如图1所示,图1是本发明实施例方案涉及的硬件运行环境的结构示意图。
需要说明的是,图1即可为模型参数获取系统的硬件运行环境的结构示意图。本发明实施例模型参数获取系统可以是PC,便携计算机等终端设备。
如图1所示,该模型参数获取系统可以包括:处理器1001,例如CPU,网络接口1004,用户接口1003,存储器1005,通信总线1002。其中,通信总线1002用于实现这些组件之间的连接通信。用户接口1003可以包括显示屏(Display)、输入单元比如键盘(Keyboard),可选用户接口1003还可以包括标准的有线接口、无线接口。网络接口1004可选的可以包括标准的有线接口、无线接口(如WI-FI接口)。存储器1005可以是高速RAM存储器,也可以是稳定的存储器(non-volatile memory),例如磁盘存储器。存储器1005可选的还可以是独立于前述处理器1001的存储装置。
本领域技术人员可以理解,图1中示出的模型参数获取系统结构并不构成对模型参数获取系统的限定,可以包括比图示更多或更少的部件,或者组合某些部件,或者不同的部件布置。
如图1所示,作为一种计算机存储介质的存储器1005中可以包括操作系统、网络通信模块、用户接口模块以及基于联邦学习的模型参 数获取程序。其中,操作系统是管理和控制模型参数获取系统硬件和软件资源的程序,支持基于联邦学习的模型参数获取程序以及其它软件或程序的运行。
在图1所示的模型参数获取系统中,用户接口1003主要用于连接第一终端、第二终端和第三终端等,与各个终端进行数据通信;网络接口1004主要用于连接后台服务器,与后台服务器进行数据通信;而处理器1001可以用于调用存储器1005中存储的基于联邦学习的模型参数获取程序,并执行以下操作:
当第三终端接收到第二终端发送的加密后的损失值后,控制所述第三终端解密所述损失值,得到解密后的所述损失值,其中,所述损失值是通过第一终端对应的第一数据和所述第二终端对应的第二数据计算得到的;
根据解密后的所述损失值检测待训练模型是否处于收敛状态;
若检测到所述待训练模型处于收敛状态,则获取与所述损失值对应的梯度值;
确定与所述梯度值对应的样本参数,将与所述梯度值对应的样本参数确定为所述待训练模型的模型参数。
进一步地,所述当第三终端接收到第二终端发送的加密后的损失值后,控制所述第三终端解密所述损失值,得到解密后的所述损失值的步骤之前,处理器1001还可以用于调用存储器1005中存储的基于联邦学习的模型参数获取程序,并执行以下步骤:
当所述第二终端接收到所述第一终端发送的加密后的第一数据后,控制所述第二终端计算与所述第一数据对应的第二数据,以及获取所述第二数据对应的样本标签,其中,所述第一数据和所述第二数据对应的样本标签相同;
根据所述样本标签、所述第一数据和所述第二数据计算损失值;
采用同态加密算法加密所述损失值,得到加密后的所述损失值,并将加密后的所述损失值发送给所述第三终端。
进一步地,所述根据解密后的所述损失值检测待训练模型是否处 于收敛状态的步骤之后,处理器1001还可以用于调用存储器1005中存储的基于联邦学习的模型参数获取程序,并执行以下步骤:
若检测到所述待训练模型未处于所述收敛状态,则获取所述第二终端和所述第一终端发送的梯度值,并更新所述梯度值,得到更新后的所述梯度值;
将更新后的所述梯度值发送给所述第一终端和所述第二终端,以供所述第一终端和所述第二终端根据更新后的所述梯度值对应更新样本参数;
其中,当所述第一终端更新所述样本参数后,所述第一终端根据更新后的所述样本参数和交集样本数据中特征变量对应的变量值计算得到第一数据,并对所述第一数据进行加密,将加密后的第一数据发送给所述第二终端。
进一步地,所述第二终端根据更新后的所述梯度值对应更新样本参数的步骤包括:
当第二终端接收到更新后的所述梯度值后,所述第二终端计算更新后的所述梯度值与预设系数之间的乘积;
将更新前的样本参数减去所述乘积,得到更新后的所述样本参数。
进一步地,所述当第三终端接收到第二终端发送的加密后的损失值后,控制所述第三终端解密所述损失值,得到解密后的所述损失值的步骤之前,处理器1001还可以用于调用存储器1005中存储的基于联邦学习的模型参数获取程序,并执行以下步骤:
控制所述第一终端采用预存的第一公钥加密第一样本标识,并将加密后的第一样本标识发送给所述第二终端,并检测是否接收到所述第二终端发送的,采用预存的第二公钥加密后的第二样本标识;
当接收到加密后的第二样本标识后,采用所述第一公钥对所述第二样本标识进行二次加密,得到第二加密值,并检测是否接收到所述第二终端发送的第一加密值;
当接收到所述加密值后,判断所述第一加密值与所述第二加密值是否相等;
若所述第一加密值与所述第二加密值相等,则确定所述第一样本 标识与所述第二样本标识相同,并将所述第一样本标识对应的样本数据确定为与所述第二终端的交集样本数据。
进一步地,所述确定与所述梯度值对应的样本参数,将与所述梯度值对应的样本参数确定为所述待训练模型的模型参数的步骤之后,处理器1001还可以用于调用存储器1005中存储的基于联邦学习的模型参数获取程序,并执行以下步骤:
当所述第二终端确定模型参数,且接收到执行请求后,控制所述第二终端将所述执行请求发送给所述第一终端,以供所述第一终端在接收到所述执行请求后,根据对应的所述模型参数和所述执行请求对应特征变量的变量值返回第一预测分数给所述第二终端;
当接收到所述第一预测分数后,根据对应的所述模型参数和所述执行请求对应特征变量的变量值计算第二预测分数;
将所述第一预测分数和所述第二预测分数相加,得到预测分数总和,并根据所述预测分数总和输入所述待训练模型中,得到模型分数,并根据所述模型分数确定是否执行所述执行请求。
进一步地,所述根据解密后的所述损失值检测待训练模型是否处于收敛状态的步骤包括:
获取所述第二终端前一次发送的第一损失值,并将解密后的所述损失值记为第二损失值;
计算所述第一损失值和所述第二损失值之间的差值,并判断所述差值是否小于或者等于预设阈值;
当确定所述差值小于或者等于所述预设阈值时,确定所述待训练模型处于收敛状态;
当确定所述差值大于所述预设阈值时,确定所述待训练模型未处于收敛状态。
基于上述的结构,提出基于联邦学习的模型参数获取方法的各个实施例。
参照图2,图2为本发明基于联邦学习的模型参数获取方法第一实施例的流程示意图。
本发明实施例提供了基于联邦学习的模型参数获取方法的实施 例,需要说明的是,虽然在流程图中示出了逻辑顺序,但是在某些情况下,可以以不同于此处的顺序执行所示出或描述的步骤。
基于联邦学习的模型参数获取方法包括:
步骤S10,当第三终端接收到第二终端发送的加密后的损失值后,所述第三终端解密所述损失值,得到解密后的所述损失值,其中,所述损失值是通过第一终端对应的第一数据和所述第二终端对应的第二数据计算得到的。
当第三终端接收到第二终端发送的加密后的损失值后,第三终端解密该损失值,得到解密后的损失值。需要说明的是,该损失值是第二终端根据第一终端发送的第一数据和与第一数据对应的第二数据计算得到的,第一数据是第一终端根据其样本数据和对应的样本参数计算得到的,第二数据是第二终端根据其样本数据和对应的样本参数计算得到的。在损失值中,含有多个计算因子。在本实施例中,第二终端采用第三终端发送的公钥,通过同态加密加法算法加密各个计算因子,得到加密后的计算因子,将加密后的计算因子相加,得到加密后的损失值,并将加密后的损失值发送给第三终端。当第三终端接收到加密后的损失值后,获取加密后的损失值对应的加密后的计算因子,通过与第二终端加密计算因子公钥对应的私钥解密该加密后的计算因子,得到原始的计算因子,通过该原始的计算因子得到解密后的损失值。其中,当第三终端采用非对称加密算法产生公钥和私钥后,第三终端将公钥发送给第一终端和第二终端,以便于第一终端和第二终端根据该公钥对应加密所需传输数据。第一终端、第二终端和第三终端可为智能手机、个人计算机和服务器等。
步骤S20,根据解密后的所述损失值检测待训练模型是否处于收敛状态。
当第三终端得到解密后的损失值后,第三终端根据解密后的损失值检测待训练模型是否处于收敛状态。
进一步地,步骤S20包括:
步骤a,获取所述第二终端前一次发送的第一损失值,并将解密后的所述损失值记为第二损失值。
具体地,当第三终端得到解密后的损失值后,第三终端获取第二终端前一次发送的第一损失值,并将解密后的损失值记为第二损失值。需要说明的是,当待训练模型未处于收敛状态时,第二终端会持续给第三终端发送损失值,直到待训练模型处于收敛状态。第一损失值也是第三终端解密后的损失值。可以理解的是,第一损失值是第二终端前一次发送的损失值,第二损失值是第二终端当前发送的损失值。
步骤b,计算所述第一损失值和所述第二损失值之间的差值,并判断所述差值是否小于或者等于预设阈值。
步骤c,当确定所述差值小于或者等于所述预设阈值时,确定所述待训练模型处于收敛状态。
步骤d,当确定所述差值大于所述预设阈值时,确定所述待训练模型未处于收敛状态。
当第三终端获取到第一损失值和第二损失值后,第三终端计算第一损失值和第二损失值之间的差值,并判断该差值是否小于或者等于预设阈值。当确定该差值小于或者等于预设阈值时,第三终端确定待训练模型处于收敛状态;当确定该差值大于预设阈值时,第三终端确定待训练模型未处于收敛状态。其中,预设阈值的具体数值可根据具体需要而设置,在本实施例中对预设阈值对应的数值不做具体限制。
步骤S30,若检测到所述待训练模型处于收敛状态,则获取与所述损失值对应的梯度值。
步骤S40,确定与所述梯度值对应的样本参数,将与所述梯度值对应的样本参数确定为所述待训练模型的模型参数。
若检测到待训练模型处于收敛状态,第三终端则获取与损失值对应的梯度值,并确定与该梯度值对应的样本参数,将与梯度值对应的样本参数确定为待训练模型的模型参数。需要说明的是,损失值对应的梯度值有两个,分别为第一终端发送给第三终端的梯度值,以及第二终端发送给第三终端的梯度值。当第一终端计算得到其对应的梯度值后,加密其梯度值,并将加密后的梯度值发送给第三终端。第二终端在将加密后的损失值发送给第三终端时,第二终端会将加密后的梯度值一起发送给第三终端。其中,第二终端加密梯度值和加密损失值 的加密方法相同,在本实施例不再详细赘述。第一终端加密梯度值的方法与第二终端加密梯度值的方法相同,在本实施例中不再详细赘述。
在本实施例中,第二终端发送给第三终端的损失值和加密值都是通过第一终端和第二终端对应的样本参数、特征变量对应的变量值和第二终端交集样本数据对应的样本标签值计算所得。第一终端和第二终端对应的样本参数可以相同,也可以不同。在得到模型参数的过程中,会不断迭代更新梯度值和损失值,直到待训练模型处于收敛状态。在待训练模型中,存在第一终端对应的模型参数和第二终端对应的模型参数。
当检测到待训练模型处于收敛状态时,第三终端可将计算对应梯度值中第一终端对应的样本参数作为待训练模型中第一终端对应的模型参数,以及将计算对应梯度值中第二终端对应的样本参数作为待训练模型中第二终端对应的模型参数。
进一步地,当第三终端确定模型参数后,会发送提示消息给第一终端和第二终端,以根据该提示信息提示第一终端和第二终端各自对应的模型参数。需要说明的是,第一终端和第二终端都存在对应的模型参数,第一终端对应的模型参数由第一终端存储,第二终端对应的模型参数由第二终端存储。
本实施例通过当第三终端接收到第二终端发送的加密后的损失值后,第三终端解密损失值,得到解密后的损失值,其中,损失值是通过第一终端和第二终端中的样本数据计算得到的;根据解密后的损失值检测待训练模型是否处于收敛状态;若检测到待训练模型处于收敛状态,则获取与损失值对应的梯度值;确定与梯度值对应的样本参数,将与梯度值对应的样本参数确定为待训练模型的模型参数。实现了联合第一终端和第二终端的样本数据计算得到损失值,以通过联合第一终端和第二终端的样本数据联合帮助学习确定待训练模型中的模型参数,提高了训练所得模型的准确度。
进一步地,提出本发明基于联邦学习的模型参数获取方法第二实施例。
所述基于联邦学习的模型参数获取方法第二实施例与所述基于 联邦学习的模型参数获取方法第一实施例的区别在于,参照图3,基于联邦学习的模型参数获取方法还包括:
步骤S50,当所述第二终端接收到所述第一终端发送的加密后的第一数据后,所述第二终端计算与所述第一数据对应的第二数据,以及获取所述第二数据对应的样本标签,其中,所述第一数据和所述第二数据对应的样本标签相同。
当第二终端接收到第一终端发送的第一数据后,第二终端计算与第一数据对应的第二数据,以及获取第二数据对应的样本标签。其中,第一数据为第一终端中样本参数与第一终端交集样本数据中特征变量对应变量值乘积之和,以及该乘积之和的平方。计算原始第一数据对应的计算公式为:
乘积之和的平方表示为:
其中,w
1,w
2…w
n表示第一终端对应的样本参数,第一终端中特征变量对应变量值的个数与第一终端对应样本参数的个数相等,即一个变量值对应一个样本参数,x表示特征变量的特征值,1,2…n表示对应变量值和样本参数的个数。如当第一终端交集样本数据中的每个特征变量存在三个变量值,则
需要说明的是,第一终端发送给第二终端的第一数据是加密后的第一数据,当第一终端计算得到第一数据后,采用第三终端发送的公钥,通过同态加密算法加密第一数据,得到加密后的第一数据,并将加密后的第一数据发送给第二终端。其中,发送给第二终端的第一数据,即加密后的第一数据可表示为[[u
A]]和
第二终端计算第二数据的过程与第一终端计算第一数据的过程类似,如计算第二终端中样本参数与第二终端交集样本数据中特征变量对应变量值乘积之和的公式为:
其中,w
1,w
2…w
n表示第二终端中各个样本数据特征变量对应特征值的样本参数。需要说明的是,第一数据和第二数据对应的样本标识是相同的。在第一终端和第二终端的样本数据中,每个样本数据都存在对应的样本标识,但第一终端的样本数据是不存在样本标签的,第二终端的样本数据存在样本标签,一个样本标识对应一个样本标签。每个样本数据至少存在一个特征变量,每个特征变量至少存在一个变量值。 在第一终端中,每个样本数据的样本标识都不一样,在第二终端中,每个样本数据的样本标识也都不一样,但是不同样本数据对应的样本标签可能相同,也可能不相同。
步骤S60,根据所述样本标签、所述第一数据和所述第二数据计算损失值。
步骤S70,采用同态加密算法加密所述损失值,得到加密后的所述损失值,并将加密后的所述损失值发送给所述第三终端。
当第二终端得到第二数据对应的样本标签,第一终端发送的第一数据,和计算所得的第二数据后,第二终端根据该样本标签对应的标签值、第一数据和第二数据计算得到损失值。
在本实施例中,损失值表示为loss,加密后的损失值表示为[[loss]],
其中,y表示第二数据对应样本标签的标签值,样本标签对应的标签值的数值可根据具体需要而设置,如在本实施例中,如可用“0”和“1”表示不同样本标签对应的标签值。
当第二终端计算得到损失值后,第二终端采用第三终端发送的公钥,通过同态加密算法加密各个计算损失值的计算因子,以得到加密后的损失值,并将加密后的损失值发送给第三终端。其中,log2、yw
Tx和(w
Tx)
2为计算损失值的计算因子。需要说明的是,在本实施例中,采用[[x]]表示加密后的x。
需要说明的是,在本实施例中,采用参数服务器的方式,第一终端和第二终端都拥有独立的参数服务器,用于各自样本数据的聚合更 新同步,同时避免各自样本数据的泄露,且第一终端和第二终端对应的样本参数,即模型参数都是各自存储的,提高了第一终端和第二终端数据的安全性。
本实施例通过根据第一终端的第一数据和第二终端的第二数据,以及第二数据对应的样本标签计算损失值,并采用同态加密算法加密计算损失值所需的数据,使第二终端在计算损失值过程中,并不能获取第一终端的具体样本数据,实现了在联合第一终端和第二终端样本数据计算模型参数过程中,可在不暴露第一终端和第二终端样本数据的基础上计算出计算模型参数所需的损失值,提高了计算模型参数过程中第一终端和第二终端样本数据的隐私性。
进一步地,提出本发明基于联邦学习的模型参数获取方法第三实施例。
所述基于联邦学习的模型参数获取方法第三实施例与所述基于联邦学习的模型参数获取方法第一或第二实施例的区别在于,参照图4,基于联邦学习的模型参数获取方法还包括:
步骤S80,若检测到所述待训练模型未处于所述收敛状态,则获取所述第二终端和所述第一终端发送的梯度值,并更新所述梯度值,得到更新后的所述梯度值。
若检测到待训练模型未处于收敛状态,第三终端则获取第二终端和所述第一终端发送的梯度值,并更新第一终端和第二终端对应的梯度值,得到第一终端和第二终端对应的更新后的梯度值。其中,当第二终端发送损失值给第三终端过程中,会同时将梯度值一起发送给第三终端,发送给第三终端的梯度值也是经过第三终端发送的公钥,通过同态加密算法加密后的。第二终端计算其对应梯度值的公式为:
第二终端发送给第三终端梯度值表示为[[g
B]]。
第二终端在计算得到[[d]]后,会将[[d]]发送给第一终端。当第一终端接收到第二终端发送的[[d]]后,第一终端根据[[d]]计算其对应的梯度值,并将其对应的梯度值发送给第三终端。第一终端根据[[d]]计算其对应的梯度值的公式为:[[g
A]]=∑[[d]]x
A。
在本实施例中,第三终端可先采用其私钥解密第一终端和第二终端发送的梯度值,然后对解密后的梯度值进行求导,得到更新后的梯度值。进一步地,第三终端可根据待训练模型的特征,按照一定比例降低或者提高解密后的梯度值,以得到更新后的梯度值。
步骤S90,将更新后的所述梯度值发送给所述第一终端和所述第二终端,以供所述第一终端和所述第二终端根据更新后的所述梯度值对应更新样本参数;
其中,当所述第一终端更新所述样本参数后,所述第一终端根据更新后的所述样本参数和交集样本数据中特征变量对应的变量值计算得到第一数据,并对所述第一数据进行加密,将加密后的第一数据发送给所述第二终端。
当第三终端得到更新后的梯度值后,将第一终端对应的更新后的梯度值发送给第一终端,以及将第二终端对应的更新后的梯度值发送给第二终端。当第一终端接收到第三终端发送的更新后的梯度值后,第一终端根据更新后的梯度值更新其对应的样本参数。具体地,第一终端根据更新后的梯度值更新其对应样本参数所用公式为:w
A=w
A0-ηg
A,其中,w
A表示更新后的样本参数,w
A0表示更新前的样本参数,即第一终端之前计算第一数据所用的样本参数;η为一个系数,是预先设置好的,其对应的数值可根据具体需要而设置;g
A为更新后的梯度值。
当第一终端更新样本参数后,第一终端获取其交集样本数据对应的特征变量,确定该特征变量对应的变量值,并根据该变量值和更新 后的样本参数计算得到第一数据,加密该第一数据,将加密后的第一数据发送给第二终端。第一终端计算得到第一数据的过程已在第二实施例中详细描述,在本实施例中不再详细赘述。
进一步地,所述第二终端根据更新后的所述梯度值对应更新样本参数的步骤包括:
步骤g,当第二终端接收到更新后的所述梯度值后,所述第二终端计算更新后的所述梯度值与预设系数之间的乘积。
步骤h,将更新前的样本参数减去所述乘积,得到更新后的所述样本参数。
当第二终端接收到第三终端发送的更新后的梯度值后,第二终端计算更新后的梯度值与预设系数之间的乘积,将样本参数减去该乘积,以得到更新后的样本参数。具体地,第二终端根据更新后的梯度值更新其对应样本参数所用公式为:w
B=w
B0-ηg
B,其中,w
B表示更新后的样本参数,w
B0表示更新前的样本参数,即第二终端之前计算第二数据所用的样本参数;η为一个系数,是预先设置好的,即预设系数,其对应的数值可根据具体需要而设置;g
B为更新后的梯度值。其中,第一终端和第二终端对应的η可以相同,也可以不同。
进一步地,当第三终端确定待训练模型处于收敛状态时,第三终端可更新对应的梯度值,并将更新后的梯度值发送给第一终端和第二终端,以供第一终端和第二终端在接收到更新后的梯度值后,对应根据更新后的梯度值更新样本参数,将更新后的样本参数作为模型参数。
本实施例通过当检测到待训练模型未处于收敛状态时,第三终端更新梯度值,并将更新后的梯度值发送给第一终端和第二终端,以供第一终端和第二终端根据更新后的梯度值更新对应的样本参数,直到待训练模型处于收敛状态,以提高所得待训练模型分析数据的准确性。
进一步地,提出本发明基于联邦学习的模型参数获取方法第四实施例。
所述基于联邦学习的模型参数获取方法第四实施例与所述基于联邦学习的模型参数获取方法第一、第二或第三实施例的区别在于,基于联邦学习的模型参数获取方法还包括:
步骤i,所述第一终端采用预存的第一公钥加密第一样本标识,并将加密后的第一样本标识发送给所述第二终端,并检测是否接收到所述第二终端发送的,采用预存的第二公钥加密后的第二样本标识。
当需要得到待训练模型的模型参数后,第一终端采用预先存储的第一公钥加密第一样本标识,得到加密后的第一样本标识,并将加密后的第一样本标识发送给第二终端。第一终端检测是否接收到第二终端发送的,采用预存的第二公钥加密后的第二样本标识。
当需要得到待训练模型的模型参数后,第二终端采用预先存储的第二公钥加密第二样本标识,得到加密后的第二样本标识,并将加密后的第二样本标识发送给第一终端。
需要说明的是,加密后的第一样本标识为第一终端加密其所持有的样本数据对应的数据标识后所得到的,,第二样本标识为第二终端样本数据对应的数据标识。具体地,第一终端可采用其预先生成的公钥加密第一样本标识。第一终端和第二终端加密所用的公钥是通过非对称加密算法生成的。
步骤j,当接收到加密后的第二样本标识后,采用所述第一公钥对所述第二样本标识进行二次加密,得到第二加密值,并检测是否接收到所述第二终端发送的第一加密值。
当第一终端接收到第二终端发送的加密后的第二样本标识后,第一终端采用其公钥,即采用第一公钥对第二样本标识进行二次加密,将经过二次加密后的第二样本标识记为第二加密值,并检测是否接收到第二终端发送的第一加密值。其中,当第二终端接收到第一终端发送的加密后的第一样本标识后,第二终端采用其公钥,即采用第二公钥对加密后的第二样本标识进行二次加密,将经过二次加密后的第一样本标识记为第一加密值,并将第一加密值发送给第一终端。
步骤k,当接收到所述加密值后,判断所述第一加密值与所述第二加密值是否相等。
步骤l,若所述第一加密值与所述第二加密值相等,则确定所述第一样本标识与所述第二样本标识相同,并将所述第一样本标识对应的样本数据确定为与所述第二终端的交集样本数据。
当第一终端接收到第一终端发送的第二加密值后,第一终端判断第一加密值与第二加密值是否相等。若确定第一加密值与第二加密值相等,第一终端则确定对应携带第一样本标识的样本数据为交集样本数据;若确定第一加密值与第二加密值不相等,第一终端则确定携带第一样本标识的样本数据不是交集样本数据。可以理解的是,当第一加密值与第二加密值相等时,表明第一加密值对应的第一样本标识与第二加密值对应的第二样本标识是相同的。
如当第一终端的公钥为pub_a,第二终端的公钥为pub_b时,确定交集样本数据的过程为:(1)第一终端采用其公钥pub_a对id_a(第一样本标识)加密:id_a_fa=f(id_a,pub_a),然后把id_a_fa发送给第二终端,第二终端采用公钥pub_b把该id_a加密串进行再次加密,得到id_a_fa_fb=f(id_a_fa,pub_b)。(2)第二终端采用公钥pub_b对id_b(第二样本标识)加密:id_b_fb=f(id_b,pub_b),然后把id_b_fb发送给第一终端,第一终端采用公钥pub_a把该id_b加密串进行再次加密:id_b_fb_fa=f(id_b_fb,pub_a),然后把id_b_fb_fa发送第二终端。(3)第二终端比较id_a_fa_fb(第一加密值)和id_b_fb_fa(第二加密值),如果这两个加密串相等,则表示id_a和id_b相同。
如若第一终端的样本数据为:{<id1:x1,x2>,<id2:x1,x2>,<id3:x1,x2>},第二终端的样本数据为:{<id2:x3,x4>,<id3:x3,x4>,<id4:x3,x4>,则第二终端中交集样本数据为:{<id2:x3,x4>,<id3:x3,x4>},第一终端中的交集样本数据为:{<id2:x1,x2>,<id3:x1,x2>}。
需要说明的是,第二终端确定其与第一终端中携带相同样本标识的交集样本数据的过程,与第一终端确定其与第二终端中携带相同样本标识的交集样本数据的过程一致,在本实施例中不再详细赘述。
在确定模型参数的过程中,当得到第一终端对应的交集样本数据和第二终端对应的交集样本数据后,第一终端可将其交集样本数据划分成若干份,然后第二终端根据第一终端划分样本数据的划分结果,通过样本标识对进行匹配,以对自己的交集样本数据进行划分。
本实施例通过在第一终端和第二终端不泄露自己所拥有数据的 情况下,得到第一终端和第二终端样本数据的交集样本数据,提高了计算数据信息值过程中,第一终端和第二终端数据的安全性。
进一步地,提出本发明基于联邦学习的模型参数获取方法第五实施例。
所述基于联邦学习的模型参数获取方法第四实施例与所述基于联邦学习的模型参数获取方法第一、第二、第三或第四实施例的区别在于,基于联邦学习的模型参数获取方法还包括:
步骤m,当所述第二终端确定模型参数,且接收到执行请求后,所述第二终端将所述执行请求发送给所述第一终端,以供所述第一终端在接收到所述执行请求后,根据对应的所述模型参数和所述执行请求对应特征变量的变量值返回第一预测分数给所述第二终端。
当第二终端确定模型参数后,第二终端检测是否接收到执行请求。当第二终端接收到执行请求后,第二终端将该执行请求发送给第一终端。当第一终端接收到执行请求后,第一终端获取其对应的模型参数,以及获取执行请求对应特征变量的变量值,根据该模型参数和变量值计算得到第一预测分数,并将该第一预测分数发送给第二终端。可以理解的是,第一终端计算第一预测分数的公式为:
步骤n,当接收到所述第一预测分数后,根据对应的所述模型参数和所述执行请求对应特征变量的变量值计算第二预测分数。
步骤o,将所述第一预测分数和所述第二预测分数相加,得到预测分数总和,并根据所述预测分数总和输入所述待训练模型中,得到模型分数,并根据所述模型分数确定是否执行所述执行请求。
当第二终端得到第一预测分数和第二预测分数后,第二终端将第一预测分数和第二预测分数相加,得到预测分数总和,并将该预测分 数总和输入待训练模型中,得到模型分数。其中,预测分数总和的表达式为:
,待训练模型的表达式为
当得到模型分数后,第二终端可根据该模型分数判断是否执行该执行请求。如当该待训练模型为欺诈模型,该执行请求为贷款请求时,若计算所得的模型分数大于或者等于预设分数,第二终端则确定该贷款请求为欺诈请求,拒绝执行该贷款请求;若计算所得的模型分数小于预设分数,第二终端则确定该贷款请求为真实的贷款请求,执行该贷款请求。
本实施例通过第二终端接收到执行请求后,通过待训练模型分析该执行请求,以确定是否执行该执行请求,提高了第二终端执行请求过程中的安全性。
此外,本发明实施例还提出一种计算机可读存储介质,所述计算机可读存储介质上存储有基于联邦学习的模型参数获取程序,所述基于联邦学习的模型参数获取程序被处理器执行时实现如上所述的奖励发送方法的步骤。
本发明计算机可读存储介质具体实施方式与上述基于联邦学习的模型参数获取方法各实施例基本相同,在此不再赘述。
需要说明的是,在本文中,术语“包括”、“包含”或者其任何其他变体意在涵盖非排他性的包含,从而使得包括一系列要素的过程、方法、物品或者装置不仅包括那些要素,而且还包括没有明确列出的其他要素,或者是还包括为这种过程、方法、物品或者装置所固有的要素。在没有更多限制的情况下,由语句“包括一个……”限定的要素,并不排除在包括该要素的过程、方法、物品或者装置中还存在另外的相同要素。
上述本发明实施例序号仅仅为了描述,不代表实施例的优劣。
通过以上的实施方式的描述,本领域的技术人员可以清楚地了解到上述实施例方法可借助软件加必需的通用硬件平台的方式来实现,当然也可以通过硬件,但很多情况下前者是更佳的实施方式。基于这 样的理解,本发明的技术方案本质上或者说对现有技术做出贡献的部分可以以软件产品的形式体现出来,该计算机软件产品存储在一个存储介质(如ROM/RAM、磁碟、光盘)中,包括若干指令用以使得一台终端设备(可以是手机,计算机,服务器,空调器,或者网络设备等)执行本发明各个实施例所述的方法。
以上仅为本发明的优选实施例,并非因此限制本发明的专利范围,凡是利用本发明说明书及附图内容所作的等效结构或等效流程变换,或直接或间接运用在其他相关的技术领域,均同理包括在本发明的专利保护范围内。
Claims (20)
- 一种基于联邦学习的模型参数获取方法,其特征在于,所述基于联邦学习的模型参数获取方法包括以下步骤:当第三终端接收到第二终端发送的加密后的损失值后,所述第三终端解密所述损失值,得到解密后的所述损失值,其中,所述损失值是通过第一终端对应的第一数据和所述第二终端对应的第二数据计算得到的;根据解密后的所述损失值检测待训练模型是否处于收敛状态;若检测到所述待训练模型处于收敛状态,则获取与所述损失值对应的梯度值;确定与所述梯度值对应的样本参数,将与所述梯度值对应的样本参数确定为所述待训练模型的模型参数。
- 如权利要求1所述的基于联邦学习的模型参数获取方法,其特征在于,所述当第三终端接收到第二终端发送的加密后的损失值后,所述第三终端解密所述损失值,得到解密后的所述损失值的步骤之前,还包括:当所述第二终端接收到所述第一终端发送的加密后的第一数据后,所述第二终端计算与所述第一数据对应的第二数据,以及获取所述第二数据对应的样本标签,其中,所述第一数据和所述第二数据对应的样本标签相同;根据所述样本标签、所述第一数据和所述第二数据计算损失值;采用同态加密算法加密所述损失值,得到加密后的所述损失值,并将加密后的所述损失值发送给所述第三终端。
- 如权利要求1所述的基于联邦学习的模型参数获取方法,其特征在于,所述根据解密后的所述损失值检测待训练模型是否处于收敛状态的步骤之后,还包括:若检测到所述待训练模型未处于所述收敛状态,则获取所述第二终端和所述第一终端发送的梯度值,并更新所述梯度值,得到更新后的所述梯度值;将更新后的所述梯度值发送给所述第一终端和所述第二终端,以供所述第一终端和所述第二终端根据更新后的所述梯度值对应更新样本参数;其中,当所述第一终端更新所述样本参数后,所述第一终端根据更新后的所述样本参数和交集样本数据中特征变量对应的变量值计算得到第一数据,并对所述第一数据进行加密,将加密后的第一数据发送给所述第二终端。
- 如权利要求3所述的基于联邦学习的模型参数获取方法,其特征在于,所述第二终端根据更新后的所述梯度值对应更新样本参数的步骤包括:当第二终端接收到更新后的所述梯度值后,所述第二终端计算更新后的所述梯度值与预设系数之间的乘积;将更新前的样本参数减去所述乘积,得到更新后的所述样本参数。
- 如权利要求3所述的基于联邦学习的模型参数获取方法,其特征在于,所述当第三终端接收到第二终端发送的加密后的损失值后,所述第三终端解密所述损失值,得到解密后的所述损失值的步骤之前,还包括:所述第一终端采用预存的第一公钥加密第一样本标识,并将加密后的第一样本标识发送给所述第二终端,并检测是否接收到所述第二终端发送的,采用预存的第二公钥加密后的第二样本标识;当接收到加密后的第二样本标识后,采用所述第一公钥对所述第二样本标识进行二次加密,得到第二加密值,并检测是否接收到所述第二终端发送的第一加密值;当接收到所述加密值后,判断所述第一加密值与所述第二加密值是否相等;若所述第一加密值与所述第二加密值相等,则确定所述第一样本标识与所述第二样本标识相同,并将所述第一样本标识对应的样本数据确定为与所述第二终端的交集样本数据。
- 如权利要求1所述的基于联邦学习的模型参数获取方法,其特征在于,所述确定与所述梯度值对应的样本参数,将与所述梯度值 对应的样本参数确定为所述待训练模型的模型参数的步骤之后,还包括:当所述第二终端确定模型参数,且接收到执行请求后,所述第二终端将所述执行请求发送给所述第一终端,以供所述第一终端在接收到所述执行请求后,根据对应的所述模型参数和所述执行请求对应特征变量的变量值返回第一预测分数给所述第二终端;当接收到所述第一预测分数后,根据对应的所述模型参数和所述执行请求对应特征变量的变量值计算第二预测分数;将所述第一预测分数和所述第二预测分数相加,得到预测分数总和,并根据所述预测分数总和输入所述待训练模型中,得到模型分数,并根据所述模型分数确定是否执行所述执行请求。
- 如权利要求1所述的基于联邦学习的模型参数获取方法,其特征在于,所述根据解密后的所述损失值检测待训练模型是否处于收敛状态的步骤包括:获取所述第二终端前一次发送的第一损失值,并将解密后的所述损失值记为第二损失值;计算所述第一损失值和所述第二损失值之间的差值,并判断所述差值是否小于或者等于预设阈值;当确定所述差值小于或者等于所述预设阈值时,确定所述待训练模型处于收敛状态;当确定所述差值大于所述预设阈值时,确定所述待训练模型未处于收敛状态。
- 如权利要求2所述的基于联邦学习的模型参数获取方法,其特征在于,所述根据解密后的所述损失值检测待训练模型是否处于收敛状态的步骤包括:获取所述第二终端前一次发送的第一损失值,并将解密后的所述损失值记为第二损失值;计算所述第一损失值和所述第二损失值之间的差值,并判断所述差值是否小于或者等于预设阈值;当确定所述差值小于或者等于所述预设阈值时,确定所述待训练 模型处于收敛状态;当确定所述差值大于所述预设阈值时,确定所述待训练模型未处于收敛状态。
- 如权利要求3所述的基于联邦学习的模型参数获取方法,其特征在于,所述根据解密后的所述损失值检测待训练模型是否处于收敛状态的步骤包括:获取所述第二终端前一次发送的第一损失值,并将解密后的所述损失值记为第二损失值;计算所述第一损失值和所述第二损失值之间的差值,并判断所述差值是否小于或者等于预设阈值;当确定所述差值小于或者等于所述预设阈值时,确定所述待训练模型处于收敛状态;当确定所述差值大于所述预设阈值时,确定所述待训练模型未处于收敛状态。
- 如权利要求4所述的基于联邦学习的模型参数获取方法,其特征在于,所述根据解密后的所述损失值检测待训练模型是否处于收敛状态的步骤包括:获取所述第二终端前一次发送的第一损失值,并将解密后的所述损失值记为第二损失值;计算所述第一损失值和所述第二损失值之间的差值,并判断所述差值是否小于或者等于预设阈值;当确定所述差值小于或者等于所述预设阈值时,确定所述待训练模型处于收敛状态;当确定所述差值大于所述预设阈值时,确定所述待训练模型未处于收敛状态。
- 如权利要求5所述的基于联邦学习的模型参数获取方法,其特征在于,所述根据解密后的所述损失值检测待训练模型是否处于收敛状态的步骤包括:获取所述第二终端前一次发送的第一损失值,并将解密后的所述损失值记为第二损失值;计算所述第一损失值和所述第二损失值之间的差值,并判断所述差值是否小于或者等于预设阈值;当确定所述差值小于或者等于所述预设阈值时,确定所述待训练模型处于收敛状态;当确定所述差值大于所述预设阈值时,确定所述待训练模型未处于收敛状态。
- 如权利要求6所述的基于联邦学习的模型参数获取方法,其特征在于,所述根据解密后的所述损失值检测待训练模型是否处于收敛状态的步骤包括:获取所述第二终端前一次发送的第一损失值,并将解密后的所述损失值记为第二损失值;计算所述第一损失值和所述第二损失值之间的差值,并判断所述差值是否小于或者等于预设阈值;当确定所述差值小于或者等于所述预设阈值时,确定所述待训练模型处于收敛状态;当确定所述差值大于所述预设阈值时,确定所述待训练模型未处于收敛状态。
- 一种模型参数获取系统,其特征在于,所述模型参数获取系统包括存储器、处理器和存储在所述存储器上并可在所述处理器上运行的基于联邦学习的模型参数获取程序,所述基于联邦学习的模型参数获取程序被所述处理器执行时实现如下步骤:当第三终端接收到第二终端发送的加密后的损失值后,所述第三终端解密所述损失值,得到解密后的所述损失值,其中,所述损失值是通过第一终端对应的第一数据和所述第二终端对应的第二数据计算得到的;根据解密后的所述损失值检测待训练模型是否处于收敛状态;若检测到所述待训练模型处于收敛状态,则获取与所述损失值对应的梯度值;确定与所述梯度值对应的样本参数,将与所述梯度值对应的样本参数确定为所述待训练模型的模型参数。
- 如权利要求13所述的模型参数获取系统,其特征在于,所述当第三终端接收到第二终端发送的加密后的损失值后,所述第三终端解密所述损失值,得到解密后的所述损失值的步骤之前,所述处理器还用于调用所述存储器中存储的基于联邦学习的模型参数获取程序,并执行以下步骤:当所述第二终端接收到所述第一终端发送的加密后的第一数据后,所述第二终端计算与所述第一数据对应的第二数据,以及获取所述第二数据对应的样本标签,其中,所述第一数据和所述第二数据对应的样本标签相同;根据所述样本标签、所述第一数据和所述第二数据计算损失值;采用同态加密算法加密所述损失值,得到加密后的所述损失值,并将加密后的所述损失值发送给所述第三终端。
- 如权利要求13所述的模型参数获取系统,其特征在于,所述根据解密后的所述损失值检测待训练模型是否处于收敛状态的步骤之后,所述处理器还用于调用所述存储器中存储的基于联邦学习的模型参数获取程序,并执行以下步骤:若检测到所述待训练模型未处于所述收敛状态,则获取所述第二终端和所述第一终端发送的梯度值,并更新所述梯度值,得到更新后的所述梯度值;将更新后的所述梯度值发送给所述第一终端和所述第二终端,以供所述第一终端和所述第二终端根据更新后的所述梯度值对应更新样本参数;其中,当所述第一终端更新所述样本参数后,所述第一终端根据更新后的所述样本参数和交集样本数据中特征变量对应的变量值计算得到第一数据,并对所述第一数据进行加密,将加密后的第一数据发送给所述第二终端。
- 如权利要求15所述的模型参数获取系统,其特征在于,所述第二终端根据更新后的所述梯度值对应更新样本参数的步骤包括:当第二终端接收到更新后的所述梯度值后,所述第二终端计算更新后的所述梯度值与预设系数之间的乘积;将更新前的样本参数减去所述乘积,得到更新后的所述样本参数。
- 如权利要求15所述的模型参数获取系统,其特征在于,所述当第三终端接收到第二终端发送的加密后的损失值后,所述第三终端解密所述损失值,得到解密后的所述损失值的步骤之前,所述处理器还用于调用所述存储器中存储的基于联邦学习的模型参数获取程序,并执行以下步骤:所述第一终端采用预存的第一公钥加密第一样本标识,并将加密后的第一样本标识发送给所述第二终端,并检测是否接收到所述第二终端发送的,采用预存的第二公钥加密后的第二样本标识;当接收到加密后的第二样本标识后,采用所述第一公钥对所述第二样本标识进行二次加密,得到第二加密值,并检测是否接收到所述第二终端发送的第一加密值;当接收到所述加密值后,判断所述第一加密值与所述第二加密值是否相等;若所述第一加密值与所述第二加密值相等,则确定所述第一样本标识与所述第二样本标识相同,并将所述第一样本标识对应的样本数据确定为与所述第二终端的交集样本数据。
- 如权利要求13所述的模型参数获取系统,其特征在于,所述确定与所述梯度值对应的样本参数,将与所述梯度值对应的样本参数确定为所述待训练模型的模型参数的步骤之后,所述处理器还用于调用所述存储器中存储的基于联邦学习的模型参数获取程序,并执行以下步骤:当所述第二终端确定模型参数,且接收到执行请求后,所述第二终端将所述执行请求发送给所述第一终端,以供所述第一终端在接收到所述执行请求后,根据对应的所述模型参数和所述执行请求对应特征变量的变量值返回第一预测分数给所述第二终端;当接收到所述第一预测分数后,根据对应的所述模型参数和所述执行请求对应特征变量的变量值计算第二预测分数;将所述第一预测分数和所述第二预测分数相加,得到预测分数总和,并根据所述预测分数总和输入所述待训练模型中,得到模型分数, 并根据所述模型分数确定是否执行所述执行请求。
- 如权利要求13所述的模型参数获取系统,其特征在于,所述根据解密后的所述损失值检测待训练模型是否处于收敛状态的步骤包括:获取所述第二终端前一次发送的第一损失值,并将解密后的所述损失值记为第二损失值;计算所述第一损失值和所述第二损失值之间的差值,并判断所述差值是否小于或者等于预设阈值;当确定所述差值小于或者等于所述预设阈值时,确定所述待训练模型处于收敛状态;当确定所述差值大于所述预设阈值时,确定所述待训练模型未处于收敛状态。
- 一种计算机可读存储介质,其特征在于,所述计算机可读存储介质上存储有基于联邦学习的模型参数获取程序,所述基于联邦学习的模型参数获取程序被处理器执行时实现如权利要求1所述的基于联邦学习的模型参数获取方法的步骤。
Priority Applications (2)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
EP19847381.1A EP3848838A4 (en) | 2018-08-10 | 2019-03-28 | METHOD AND SYSTEM FOR MODEL PARAMETER ACQUISITION BASED ON FEDERATED LEARNING, AND READABLE BACKGROUND |
US17/231,314 US20210232974A1 (en) | 2018-08-10 | 2021-04-15 | Federated-learning based method of acquiring model parameters, system and readable storage medium |
Applications Claiming Priority (2)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN201810913275.2A CN109165515A (zh) | 2018-08-10 | 2018-08-10 | 基于联邦学习的模型参数获取方法、系统及可读存储介质 |
CN201810913275.2 | 2018-08-10 |
Related Child Applications (1)
Application Number | Title | Priority Date | Filing Date |
---|---|---|---|
US17/231,314 Continuation US20210232974A1 (en) | 2018-08-10 | 2021-04-15 | Federated-learning based method of acquiring model parameters, system and readable storage medium |
Publications (1)
Publication Number | Publication Date |
---|---|
WO2020029589A1 true WO2020029589A1 (zh) | 2020-02-13 |
Family
ID=64895611
Family Applications (1)
Application Number | Title | Priority Date | Filing Date |
---|---|---|---|
PCT/CN2019/079997 WO2020029589A1 (zh) | 2018-08-10 | 2019-03-28 | 基于联邦学习的模型参数获取方法、系统及可读存储介质 |
Country Status (4)
Country | Link |
---|---|
US (1) | US20210232974A1 (zh) |
EP (1) | EP3848838A4 (zh) |
CN (1) | CN109165515A (zh) |
WO (1) | WO2020029589A1 (zh) |
Cited By (7)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN111598254A (zh) * | 2020-05-22 | 2020-08-28 | 深圳前海微众银行股份有限公司 | 联邦学习建模方法、设备及可读存储介质 |
CN111611610A (zh) * | 2020-04-12 | 2020-09-01 | 西安电子科技大学 | 联邦学习信息处理方法、系统、存储介质、程序、终端 |
CN113190871A (zh) * | 2021-05-28 | 2021-07-30 | 脸萌有限公司 | 数据保护方法、装置、可读介质及电子设备 |
CN113722738A (zh) * | 2021-09-02 | 2021-11-30 | 脸萌有限公司 | 数据保护方法、装置、介质及电子设备 |
US20220060235A1 (en) * | 2020-08-18 | 2022-02-24 | Qualcomm Incorporated | Federated learning for client-specific neural network parameter generation for wireless communication |
CN115086399A (zh) * | 2022-07-28 | 2022-09-20 | 深圳前海环融联易信息科技服务有限公司 | 基于超网络的联邦学习方法、装置及计算机设备 |
US11748661B2 (en) * | 2021-09-15 | 2023-09-05 | Beijing Baidu Netcom Science Technology Co., Ltd. | Training method and apparatus for a distributed machine learning model and medium |
Families Citing this family (61)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN109165515A (zh) * | 2018-08-10 | 2019-01-08 | 深圳前海微众银行股份有限公司 | 基于联邦学习的模型参数获取方法、系统及可读存储介质 |
CN111435452B (zh) * | 2019-01-11 | 2023-11-03 | 百度在线网络技术(北京)有限公司 | 模型训练方法、装置、设备和介质 |
CN109871702B (zh) * | 2019-02-18 | 2024-06-28 | 深圳前海微众银行股份有限公司 | 联邦模型训练方法、系统、设备及计算机可读存储介质 |
CN109902742B (zh) * | 2019-02-28 | 2021-07-16 | 深圳前海微众银行股份有限公司 | 基于加密迁移学习的样本补全方法、终端、系统及介质 |
CN109886417B (zh) * | 2019-03-01 | 2024-05-03 | 深圳前海微众银行股份有限公司 | 基于联邦学习的模型参数训练方法、装置、设备及介质 |
CN110262819B (zh) * | 2019-06-04 | 2021-02-26 | 深圳前海微众银行股份有限公司 | 一种联邦学习的模型参数更新方法及装置 |
CN110288094B (zh) * | 2019-06-10 | 2020-12-18 | 深圳前海微众银行股份有限公司 | 基于联邦学习的模型参数训练方法及装置 |
CN110276210B (zh) * | 2019-06-12 | 2021-04-23 | 深圳前海微众银行股份有限公司 | 基于联邦学习的模型参数的确定方法及装置 |
CN112085206B (zh) * | 2019-06-13 | 2024-04-09 | 北京百度网讯科技有限公司 | 联合逻辑回归建模方法、装置以及终端 |
CN110245510B (zh) * | 2019-06-19 | 2021-12-07 | 北京百度网讯科技有限公司 | 用于预测信息的方法和装置 |
CN110263921B (zh) * | 2019-06-28 | 2021-06-04 | 深圳前海微众银行股份有限公司 | 一种联邦学习模型的训练方法及装置 |
CN112149706B (zh) * | 2019-06-28 | 2024-03-15 | 北京百度网讯科技有限公司 | 模型训练方法、装置、设备和介质 |
CN112183757B (zh) * | 2019-07-04 | 2023-10-27 | 创新先进技术有限公司 | 模型训练方法、装置及系统 |
CN110363305B (zh) * | 2019-07-17 | 2023-09-26 | 深圳前海微众银行股份有限公司 | 联邦学习方法、系统、终端设备及存储介质 |
CN110378487B (zh) * | 2019-07-18 | 2021-02-26 | 深圳前海微众银行股份有限公司 | 横向联邦学习中模型参数验证方法、装置、设备及介质 |
CN110472745B (zh) * | 2019-08-06 | 2021-04-27 | 深圳前海微众银行股份有限公司 | 一种联邦学习中的信息传输方法及装置 |
CN110503207A (zh) * | 2019-08-28 | 2019-11-26 | 深圳前海微众银行股份有限公司 | 联邦学习信用管理方法、装置、设备及可读存储介质 |
CN110689137B (zh) * | 2019-09-24 | 2022-11-25 | 网易传媒科技(北京)有限公司 | 参数确定方法、系统、介质和电子设备 |
EP4052412A1 (en) * | 2019-10-30 | 2022-09-07 | Via Science, Inc. | Secure outsourcing of a multiplication |
CN110796266B (zh) * | 2019-10-30 | 2021-06-15 | 深圳前海微众银行股份有限公司 | 基于公共信息的强化学习实现方法、设备及存储介质 |
CN110751294A (zh) * | 2019-10-31 | 2020-02-04 | 深圳前海微众银行股份有限公司 | 联合多方特征数据的模型预测方法、装置、设备及介质 |
CN110837653B (zh) * | 2019-11-07 | 2023-09-19 | 深圳前海微众银行股份有限公司 | 标签预测方法、装置以及计算机可读存储介质 |
CN110851785B (zh) * | 2019-11-14 | 2023-06-06 | 深圳前海微众银行股份有限公司 | 纵向联邦学习优化方法、装置、设备及存储介质 |
CN110851786B (zh) * | 2019-11-14 | 2023-06-06 | 深圳前海微众银行股份有限公司 | 基于纵向联邦学习的企业间数据交互方法、装置、设备及存储介质 |
CN111144576A (zh) * | 2019-12-13 | 2020-05-12 | 支付宝(杭州)信息技术有限公司 | 模型训练方法、装置和电子设备 |
CN110995737B (zh) * | 2019-12-13 | 2022-08-02 | 支付宝(杭州)信息技术有限公司 | 联邦学习的梯度融合方法及装置和电子设备 |
CN111079153B (zh) * | 2019-12-17 | 2022-06-03 | 支付宝(杭州)信息技术有限公司 | 安全建模方法、装置、电子设备及存储介质 |
CN111125735B (zh) * | 2019-12-20 | 2021-11-02 | 支付宝(杭州)信息技术有限公司 | 一种基于隐私数据进行模型训练的方法及系统 |
CN111143878B (zh) * | 2019-12-20 | 2021-08-03 | 支付宝(杭州)信息技术有限公司 | 一种基于隐私数据进行模型训练的方法及系统 |
CN112734045B (zh) * | 2020-01-16 | 2022-07-12 | 支付宝(杭州)信息技术有限公司 | 一种联邦学习的异常处理方法、装置及电子设备 |
CN111310047B (zh) * | 2020-02-20 | 2021-04-23 | 深圳前海微众银行股份有限公司 | 基于fm模型的信息推荐方法、装置、设备及存储介质 |
CN111343265B (zh) * | 2020-02-20 | 2021-03-19 | 深圳前海微众银行股份有限公司 | 信息推送方法、装置、设备及可读存储介质 |
CN111046857A (zh) * | 2020-03-13 | 2020-04-21 | 同盾控股有限公司 | 基于知识联邦的人脸识别方法、装置、设备、介质及系统 |
CN111414636A (zh) * | 2020-03-20 | 2020-07-14 | 深圳前海微众银行股份有限公司 | 识别模型的更新方法、装置、设备及存储介质 |
CN111383096A (zh) * | 2020-03-23 | 2020-07-07 | 中国建设银行股份有限公司 | 欺诈检测及其模型训练方法、装置、电子设备及存储介质 |
CN111160573B (zh) * | 2020-04-01 | 2020-06-30 | 支付宝(杭州)信息技术有限公司 | 保护数据隐私的双方联合训练业务预测模型的方法和装置 |
CN111177791B (zh) * | 2020-04-10 | 2020-07-17 | 支付宝(杭州)信息技术有限公司 | 保护数据隐私的双方联合训练业务预测模型的方法和装置 |
CN111178549B (zh) * | 2020-04-10 | 2020-07-07 | 支付宝(杭州)信息技术有限公司 | 保护数据隐私的双方联合训练业务预测模型的方法和装置 |
CN111626434B (zh) * | 2020-05-15 | 2022-06-07 | 浪潮电子信息产业股份有限公司 | 一种分布式训练参数更新方法、装置、设备及存储介质 |
CN111340150B (zh) * | 2020-05-22 | 2020-09-04 | 支付宝(杭州)信息技术有限公司 | 用于对第一分类模型进行训练的方法及装置 |
CN111371544B (zh) * | 2020-05-27 | 2020-09-08 | 支付宝(杭州)信息技术有限公司 | 基于同态加密的预测方法、装置、电子设备及存储介质 |
CN111882054B (zh) * | 2020-05-27 | 2024-04-12 | 杭州中奥科技有限公司 | 对双方加密关系网络数据交叉训练的方法及相关设备 |
CN111783142B (zh) * | 2020-07-06 | 2021-10-08 | 北京字节跳动网络技术有限公司 | 数据保护方法、装置、服务器和介质 |
CN111738440B (zh) * | 2020-07-31 | 2020-11-24 | 支付宝(杭州)信息技术有限公司 | 一种基于领域自适应与联邦学习的模型训练方法及系统 |
CN114091043A (zh) * | 2020-08-04 | 2022-02-25 | 中移(成都)信息通信科技有限公司 | 一种相关性系数计算方法、装置、设备及计算机存储介质 |
CN111915019B (zh) * | 2020-08-07 | 2023-06-20 | 平安科技(深圳)有限公司 | 联邦学习方法、系统、计算机设备和存储介质 |
CN112084520B (zh) * | 2020-09-18 | 2021-03-23 | 支付宝(杭州)信息技术有限公司 | 保护数据隐私的双方联合训练业务预测模型的方法及装置 |
CN112241537B (zh) * | 2020-09-23 | 2023-02-10 | 易联众信息技术股份有限公司 | 纵向联邦学习建模方法、系统、介质及设备 |
CN112257876B (zh) * | 2020-11-15 | 2021-07-30 | 腾讯科技(深圳)有限公司 | 联邦学习方法、装置、计算机设备及介质 |
CN112668472B (zh) * | 2020-12-28 | 2021-08-31 | 中国科学院自动化研究所 | 基于联邦学习的虹膜图像特征提取方法、系统和装置 |
CN112765559B (zh) * | 2020-12-29 | 2024-08-20 | 平安科技(深圳)有限公司 | 联邦学习的过程中模型参数的处理方法、装置及相关设备 |
CN112333216B (zh) * | 2021-01-07 | 2021-04-06 | 深圳索信达数据技术有限公司 | 一种基于联邦学习的模型训练方法及系统 |
CN112347500B (zh) * | 2021-01-11 | 2021-04-09 | 腾讯科技(深圳)有限公司 | 分布式系统的机器学习方法、装置、系统、设备及存储介质 |
CN113807534B (zh) * | 2021-03-08 | 2023-09-01 | 京东科技控股股份有限公司 | 联邦学习模型的模型参数训练方法、装置和电子设备 |
CN113377830A (zh) * | 2021-05-21 | 2021-09-10 | 北京沃东天骏信息技术有限公司 | 确定超参的方法、训练联邦学习模型的方法及电子设备 |
CN113378198B (zh) * | 2021-06-24 | 2022-04-15 | 深圳市洞见智慧科技有限公司 | 一种保护用户标识的模型的联邦训练系统、方法及装置 |
CN113689003B (zh) * | 2021-08-10 | 2024-03-22 | 华东师范大学 | 一种安全的去除第三方的混合联邦学习框架及方法 |
CN113657616B (zh) * | 2021-09-02 | 2023-11-03 | 京东科技信息技术有限公司 | 联邦学习模型的更新方法和装置 |
CN113657615B (zh) * | 2021-09-02 | 2023-12-05 | 京东科技信息技术有限公司 | 联邦学习模型的更新方法和装置 |
CN113536770B (zh) * | 2021-09-09 | 2021-11-30 | 平安科技(深圳)有限公司 | 基于人工智能的文本解析方法、装置、设备及存储介质 |
CN116415267A (zh) * | 2021-12-30 | 2023-07-11 | 新智我来网络科技有限公司 | 一种联合学习模型迭代更新方法、装置、系统及存储介质 |
Citations (4)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
US6119112A (en) * | 1997-11-19 | 2000-09-12 | International Business Machines Corporation | Optimum cessation of training in neural networks |
CN107704930A (zh) * | 2017-09-25 | 2018-02-16 | 阿里巴巴集团控股有限公司 | 基于共享数据的建模方法、装置、系统及电子设备 |
CN108229646A (zh) * | 2017-08-08 | 2018-06-29 | 北京市商汤科技开发有限公司 | 神经网络模型压缩方法、装置、存储介质和电子设备 |
CN109165515A (zh) * | 2018-08-10 | 2019-01-08 | 深圳前海微众银行股份有限公司 | 基于联邦学习的模型参数获取方法、系统及可读存储介质 |
Family Cites Families (4)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN104980518B (zh) * | 2015-06-26 | 2018-11-23 | 深圳市腾讯计算机系统有限公司 | 多学习主体并行训练模型的方法、装置和系统 |
US10402469B2 (en) * | 2015-10-16 | 2019-09-03 | Google Llc | Systems and methods of distributed optimization |
US20180089587A1 (en) * | 2016-09-26 | 2018-03-29 | Google Inc. | Systems and Methods for Communication Efficient Distributed Mean Estimation |
US11455573B2 (en) * | 2019-09-30 | 2022-09-27 | International Business Machines Corporation | Data protection distributed learning |
-
2018
- 2018-08-10 CN CN201810913275.2A patent/CN109165515A/zh active Pending
-
2019
- 2019-03-28 EP EP19847381.1A patent/EP3848838A4/en active Pending
- 2019-03-28 WO PCT/CN2019/079997 patent/WO2020029589A1/zh unknown
-
2021
- 2021-04-15 US US17/231,314 patent/US20210232974A1/en active Pending
Patent Citations (4)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
US6119112A (en) * | 1997-11-19 | 2000-09-12 | International Business Machines Corporation | Optimum cessation of training in neural networks |
CN108229646A (zh) * | 2017-08-08 | 2018-06-29 | 北京市商汤科技开发有限公司 | 神经网络模型压缩方法、装置、存储介质和电子设备 |
CN107704930A (zh) * | 2017-09-25 | 2018-02-16 | 阿里巴巴集团控股有限公司 | 基于共享数据的建模方法、装置、系统及电子设备 |
CN109165515A (zh) * | 2018-08-10 | 2019-01-08 | 深圳前海微众银行股份有限公司 | 基于联邦学习的模型参数获取方法、系统及可读存储介质 |
Non-Patent Citations (1)
Title |
---|
See also references of EP3848838A4 * |
Cited By (11)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN111611610A (zh) * | 2020-04-12 | 2020-09-01 | 西安电子科技大学 | 联邦学习信息处理方法、系统、存储介质、程序、终端 |
CN111611610B (zh) * | 2020-04-12 | 2023-05-30 | 西安电子科技大学 | 联邦学习信息处理方法、系统、存储介质、程序、终端 |
CN111598254A (zh) * | 2020-05-22 | 2020-08-28 | 深圳前海微众银行股份有限公司 | 联邦学习建模方法、设备及可读存储介质 |
US20220060235A1 (en) * | 2020-08-18 | 2022-02-24 | Qualcomm Incorporated | Federated learning for client-specific neural network parameter generation for wireless communication |
US11909482B2 (en) * | 2020-08-18 | 2024-02-20 | Qualcomm Incorporated | Federated learning for client-specific neural network parameter generation for wireless communication |
CN113190871A (zh) * | 2021-05-28 | 2021-07-30 | 脸萌有限公司 | 数据保护方法、装置、可读介质及电子设备 |
CN113190871B (zh) * | 2021-05-28 | 2023-10-31 | 脸萌有限公司 | 数据保护方法、装置、可读介质及电子设备 |
CN113722738A (zh) * | 2021-09-02 | 2021-11-30 | 脸萌有限公司 | 数据保护方法、装置、介质及电子设备 |
CN113722738B (zh) * | 2021-09-02 | 2023-08-08 | 脸萌有限公司 | 数据保护方法、装置、介质及电子设备 |
US11748661B2 (en) * | 2021-09-15 | 2023-09-05 | Beijing Baidu Netcom Science Technology Co., Ltd. | Training method and apparatus for a distributed machine learning model and medium |
CN115086399A (zh) * | 2022-07-28 | 2022-09-20 | 深圳前海环融联易信息科技服务有限公司 | 基于超网络的联邦学习方法、装置及计算机设备 |
Also Published As
Publication number | Publication date |
---|---|
CN109165515A (zh) | 2019-01-08 |
EP3848838A4 (en) | 2022-06-08 |
US20210232974A1 (en) | 2021-07-29 |
EP3848838A1 (en) | 2021-07-14 |
Similar Documents
Publication | Publication Date | Title |
---|---|---|
WO2020029589A1 (zh) | 基于联邦学习的模型参数获取方法、系统及可读存储介质 | |
CN109284313B (zh) | 基于半监督学习的联邦建模方法、设备及可读存储介质 | |
CN109255444B (zh) | 基于迁移学习的联邦建模方法、设备及可读存储介质 | |
US11665147B2 (en) | Blockchain systems and methods for user authentication | |
WO2020177392A1 (zh) | 基于联邦学习的模型参数训练方法、装置、设备及介质 | |
WO2021004551A1 (zh) | 纵向联邦学习系统优化方法、装置、设备及可读存储介质 | |
WO2017140248A1 (zh) | 数据交换方法、数据交换装置及计算装置 | |
WO2017050093A1 (zh) | 登录信息输入方法、登录信息保存方法及相关装置 | |
US20170242961A1 (en) | Systems and methods for personal omic transactions | |
US10764055B1 (en) | Cluster-based security for network devices | |
WO2017071493A1 (zh) | 身份识别、业务处理以及生物特征信息的处理方法和设备 | |
CN110222086A (zh) | 基于区块链的数据管理方法、装置、设备和存储介质 | |
CN107645486A (zh) | 登录认证方法和装置 | |
CN111027981B (zh) | 多方联合训练针对IoT机具的风险评估模型的方法及装置 | |
CN111368196A (zh) | 模型参数的更新方法、装置、设备及可读存储介质 | |
AU2018100478A4 (en) | Systems and methods for providing a universal decentralized solution for verification of users with cross-verification features | |
CN116502732A (zh) | 基于可信执行环境的联邦学习方法以及系统 | |
SE540649C2 (en) | Method and system for secure password storage | |
WO2021169477A1 (zh) | 基于交叉特征的建模、预测方法、装置、设备及存储介质 | |
CN115358728A (zh) | 基于云计算的erp数据处理方法 | |
US11968305B2 (en) | Four-factor authentication | |
KR20200021136A (ko) | 대화형 메시징 기반의 이벤트 실행이 가능한 챗봇 시스템 서버 및 그 동작 방법 | |
CN111401277B (zh) | 人脸识别模型更新方法、装置、设备和介质 | |
US20240195623A1 (en) | Using virtual objects on different platforms | |
US20240259221A1 (en) | Secured blockchain transfer with insecure entities |
Legal Events
Date | Code | Title | Description |
---|---|---|---|
121 | Ep: the epo has been informed by wipo that ep was designated in this application |
Ref document number: 19847381 Country of ref document: EP Kind code of ref document: A1 |
|
NENP | Non-entry into the national phase |
Ref country code: DE |
|
ENP | Entry into the national phase |
Ref document number: 2019847381 Country of ref document: EP Effective date: 20210310 |