Method and device for constructing heterogeneity distribution model
By using effective score functions to replace the original score functions in the context of big data distributed, and using iterative algorithms to approximate the optimal solution, the problem of parameter estimation difficulties caused by data exchange difficulties in distributed data of heterogeneous bank alliances is solved, and heterogeneity is achieved The construction of the sexual distribution model improves the accuracy and completeness of the model.
Patent Information
- Application Number
- CN202411002688.7
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2024-07-25
- Publication Date
- 2024-11-08
AI Technical Summary
In the context of big data distribution, heterogeneous bank alliance distributed data cannot directly share original data due to data security and communication efficiency limitations, resulting in the inability to use traditional statistical methods and difficult to estimate federal model parameters.
A method for constructing a heterogeneous distribution model is proposed. By replacing the original scoring function with an effective scoring function, approximate the optimal solution using the iterative algorithm, calculate the initial estimate value and approximate Heisen matrix value of the common parameters, and update the heterogeneous parameters. A heterogeneous distribution model was constructed to solve the problem of parameter estimation difficulties caused by data exchange difficulties.
It realizes the use of effective score functions to deal with heterogeneity in heterogeneous distributed bank data, and approximates the optimal solution through iterative algorithms, solving the problem of difficult estimation of federal model parameters, and improving the accuracy and completeness of the model.
Smart Images

Figure CN118915969A_ABST
Abstract
Description
Technical Field
[0001] The present application relates to the field of big data technology, and in particular to a method and device for constructing a heterogeneous distribution model. Background Art
[0002] Distributed statistical methods face some problems that centralized storage methods have never encountered.
[0003] First, the distributed storage method means that due to the limited storage capacity of a single node machine, it is impossible to put all the data on a single node for calculation; second, the distributed scenario means that data needs to be exchanged between nodes. When exchanging data between nodes, the amount of data that can be exchanged is limited compared to the amount of original data due to communication efficiency and algorithm efficiency; third, in real scenarios, each data owner may only agree to exchange statistical data rather than basic data for the sake of their own data security. In terms of modeling distributed data of heterogeneous banking alliances, the original data comes from multiple banking centers. In order to protect data privacy and its own data security, the banking center cannot share the original data with other banking centers and can only consider sharing some statistical data.
[0004] Due to the above reasons, traditional statistical methods cannot be used directly in the context of big data distribution. Summary of the invention
[0005] In response to the problems in the prior art, the embodiments of the present application provide a method and device for constructing a heterogeneous distribution model, which can at least partially solve the problems in the prior art.
[0006] On the one hand, the present application proposes a method for constructing a heterogeneous distribution model, comprising:
[0007] Compute initial estimates of common parameters based on local, heterogeneous banking union distribution data;
[0008] Sending the initial estimated value of the common parameter to the master node, the master node being used to calculate the average value of the common parameter according to the initial value of the common parameter sent by each of the sub-nodes;
[0009] Solving the effective score function according to the average value of the common parameter to obtain a first updated value of the common parameter;
[0010] Sending the first updated value of the common parameter to the master node, the master node being used to solve the overall replacement effective score function according to the first updated value of the common parameter sent by each of the child nodes to obtain a second updated value of the common parameter;
[0011] Calculating a value of an approximate Hessian matrix according to a second updated value of the common parameter;
[0012] Sending the value of the approximate Hessian matrix to a master node, wherein the master node is used to solve the approximate global Hessian matrix according to the value of the approximate Hessian matrix sent by each of the child nodes to obtain a third updated value of the common parameter;
[0013] updating the value of the heterogeneity parameter using an alternative effective score function according to a third updated value of the common parameter;
[0014] According to the value of the heterogeneity parameter and the third updated value of the common parameter, a heterogeneity distribution model of the node is constructed.
[0015] In some embodiments, an initial estimate of the common parameter is calculated according to the following formula:
[0016]
[0017] In the formula,
[0018] In some embodiments, the expression of the effective score function is as follows:
[0019]
[0020] In the formula, s j (y; β, γ j ) represents the effective score function of the j-th node, y is the response variable in the heterogeneous banking alliance distribution data of the j-th node, β is the common parameter on the j-th node, γ j is the redundant parameter of the jth node, and is the information matrix I on the jth node (j) The information matrix is the submatrix of the corresponding position of the information matrix, which is the inverse of the variance of each variable in the data set under a given model. It can be used to estimate the standard error and confidence space of the model parameters. The f function is the joint density function under given parameters.
[0021] In some embodiments, the expression of the approximate Hessian matrix is as follows:
[0022] A t,j T A t,j ;
[0023] A t,j T A t,j ;
[0024] In the formula, A t,j Contains the matrix A of the tth iteration t The data subset κ j The corresponding row, in l″ i It means taking the derivative of the likelihood function twice. represents the transpose of the corresponding vector of the parameter θ of the tth row of the i-th node, x i is the explanatory variable of the i-th node, and θ = (β, γ) represents the unknown parameter.
[0025] In some embodiments, the expression of the alternative effective score function is as follows:
[0026]
[0027] Among them, g * (y;β) represents the alternative effective score function, s j is the effective score function on the jth node, K is the number of nodes, y is the response variable of the jth node, y ij The value of the jth response variable at the ith node, β * is a set of estimates of the common parameters, is the redundant parameter estimate of the first node, The set of redundant parameter estimates of the jth node, and the f function is the joint density function under given parameters.
[0028] On the other hand, the present application proposes a method for constructing a heterogeneous distribution model, comprising:
[0029] Obtaining the initial estimated values of the common parameters sent by each child node;
[0030] Calculating an average value of the common parameter according to the initial value of the common parameter sent by each of the sub-nodes;
[0031] Sending the average value of the common parameter to each of the child nodes, wherein each of the child nodes is used to solve the effective score function according to the average value of the common parameter to obtain a first updated value of the common parameter;
[0032] Solving the overall replacement effective score function according to the first updated value of the common parameter sent by each of the child nodes to obtain a second updated value of the common parameter;
[0033] Sending the second updated value of the common parameter to each of the child nodes, each of the child nodes being used to calculate the value of the approximate Hessian matrix according to the second updated value of the common parameter;
[0034] Solving the approximate global Hessian matrix according to the value of the approximate Hessian matrix sent by each of the child nodes to obtain a third updated value of the common parameter;
[0035] The third updated value of the common parameter is sent to each of the child nodes, and each of the child nodes is used to update the value of the heterogeneity parameter according to the third updated value of the common parameter, and construct a logistic regression model of the child node according to the value of the heterogeneity parameter updated by the child node and the third updated value of the common parameter.
[0036] In some embodiments, the overall alternative effective score function is expressed as follows:
[0037]
[0038] in, represents the overall alternative effective score function, represents the alternative effective score function on the first node, β represents the true value of the common parameter that needs to be estimated, represents the average value of the common parameter estimated by all nodes for the first time, and γ represents the true value of the redundant parameter to be estimated. represents the estimated value of the redundant parameter on the jth node, Represents the average matrix of the redundant parameter vector estimates on each child node, L j Represents the global empirical likelihood function at the jth node;
[0039]
[0040] Among them, y i1 represents the value of the ith response variable of the 1st node, and n represents the number of response variables / explanatory variables in the heterogeneous banking alliance distribution data of the jth node;
[0041]
[0042]
[0043] Among them, K is the number of nodes, y is the true value of the response variable, and β represents the true value of the common parameter to be estimated. It represents the average value of the common parameter estimated by all nodes for the first time. represents the estimated value of the redundant parameter on the jth node, represents the estimated value of the redundant parameter on the first node, the f function is the joint density function under the given parameters, and L j Represents the global empirical likelihood function at the jth node.
[0044] In some embodiments, the expression of the approximate global Hessian matrix is as follows:
[0045]
[0046] Where n represents the number of response variables / explanatory variables in the heterogeneous banking alliance distribution data of the jth node, K is the number of nodes,
[0047]
[0048]
[0049]
[0050]
[0051] M βγ First, we find the partial derivative of β, and then find the partial derivative of γ.
[0052] M γγ is to find the partial derivative of γ twice,
[0053]
[0054]
[0055]
[0056] Among them, l″ i It means to find the derivative of the likelihood function l twice, x ij represents the explanatory variable corresponding to the i-th common parameter part at the j-th node, z ij represents the explanatory variable corresponding to the i-th redundant parameter part on the j-th node, β t represents the estimated value of the common parameter at the tth iteration, γ t,j represents the true value of the redundant parameter of the tth row on the jth node, X ij A represents the matrix of all explanatory variables. j =A t,j , A t,j Contains the matrix A of the tth iteration t The data subset κ j The corresponding row, in l″ i It means taking the derivative of the likelihood function twice. represents the transpose of the corresponding vector of the parameter θ of the tth row of the i-th node, x i is the explanatory variable of the i-th node, and θ = (β, γ) represents the unknown parameter.
[0057] On the other hand, the present application provides a device for constructing a heterogeneous distribution model, comprising:
[0058] A first calculation module, for calculating initial estimates of common parameters based on local heterogeneous bank alliance distributed data;
[0059] A first sending module, used for sending the initial estimated value of the common parameter to the master node, and the master node is used for calculating the average value of the common parameter according to the initial value of the common parameter sent by each of the sub-nodes;
[0060] A first solving module, used for solving the effective score function according to the average value of the common parameter to obtain a first updated value of the common parameter;
[0061] A second sending module, configured to send the first updated value of the common parameter to a master node, wherein the master node is configured to solve the overall replacement effective score function according to the first updated value of the common parameter sent by each of the child nodes to obtain a second updated value of the common parameter;
[0062] A second calculation module, used for calculating the value of the approximate Hessian matrix according to the second updated value of the common parameter;
[0063] A third sending module, used for sending the value of the approximate Hessian matrix to the master node, and the master node is used for solving the approximate global Hessian matrix according to the value of the approximate Hessian matrix sent by each of the child nodes to obtain a third updated value of the common parameter;
[0064] an updating module, configured to update the value of the heterogeneity parameter using an alternative effective score function according to a third updated value of the common parameter;
[0065] The construction module is used to construct a heterogeneity distribution model of the node according to the value of the heterogeneity parameter and the third updated value of the common parameter.
[0066] On the other hand, the present application provides a device for constructing a heterogeneous distribution model, comprising:
[0067] An acquisition module, used to acquire an initial estimated value of a common parameter sent by each sub-node;
[0068] A third calculation module, configured to calculate an average value of the common parameter according to the initial value of the common parameter sent by each of the sub-nodes;
[0069] A fourth sending module, configured to send the average value of the common parameter to each of the child nodes, wherein each of the child nodes is configured to solve the effective score function according to the average value of the common parameter to obtain a first updated value of the common parameter;
[0070] A second solving module, configured to solve the overall replacement effective score function according to the first updated value of the common parameter sent by each of the child nodes, to obtain a second updated value of the common parameter;
[0071] A fifth sending module, used for sending the second updated value of the common parameter to each of the child nodes, and each of the child nodes is used for calculating the value of the approximate Hessian matrix according to the second updated value of the common parameter;
[0072] A third solving module, used for solving the approximate global Hessian matrix according to the value of the approximate Hessian matrix sent by each of the child nodes, to obtain a third updated value of the common parameter;
[0073] The sixth sending module is used to send the third updated value of the common parameter to each of the child nodes, and each of the child nodes is used to update the value of the heterogeneity parameter according to the third updated value of the common parameter, and to construct a logistic regression model of the child node according to the value of the heterogeneity parameter updated by the child node and the third updated value of the common parameter.
[0074] An embodiment of the present application also provides an electronic device, including a memory, a processor, and a computer program stored in the memory and executable on the processor, wherein when the processor executes the program, the steps of the method for constructing a heterogeneous distribution model described in any of the above embodiments are implemented.
[0075] An embodiment of the present application further provides a computer-readable storage medium having a computer program stored thereon, which, when executed by a processor, implements the steps of the method for constructing a heterogeneous distribution model described in any of the above embodiments.
[0076] An embodiment of the present application also provides a computer program product, which includes a computer program stored on a non-transitory computer-readable storage medium, and the computer program includes program instructions. When the program instructions are executed by a computer, the computer can execute the methods provided by the above-mentioned method embodiments.
[0077] The method and device for constructing a heterogeneous distribution model provided in an embodiment of the present application calculate an initial estimate of a common parameter based on local heterogeneous bank alliance distributed data; send the initial estimate of the common parameter to a master node, and the master node is used to calculate the average value of the common parameter based on the initial value of the common parameter sent by each of the child nodes; solve the effective score function according to the average value of the common parameter to obtain a first updated value of the common parameter; send the first updated value of the common parameter to the master node, and the master node is used to solve the overall alternative effective score function according to the first updated value of the common parameter sent by each of the child nodes to obtain a second updated value of the common parameter; calculate the value of an approximate Hessian matrix according to the second updated value of the common parameter; send the value of the approximate Hessian matrix to the master node, and the master node is used to solve the approximate global Hessian matrix according to the value of the approximate Hessian matrix sent by each of the child nodes to obtain a third updated value of the common parameter; update the value of the heterogeneous parameter using the alternative effective score function according to the third updated value of the common parameter; construct the heterogeneous distribution model of this node according to the value of the heterogeneous parameter and the third updated value of the common parameter. In this way, the effective scoring function is used to replace the original scoring function to deal with the heterogeneity between the child nodes, and then the optimal solution is approximated by the iterative algorithm. The above method solves the problem of heterogeneous distributed bank data, the inability to share information due to the difficulty in exchanging data between nodes, and the difficulty in estimating the parameters of the federated model. BRIEF DESCRIPTION OF THE DRAWINGS
[0078] In order to more clearly illustrate the embodiments of the present application or the technical solutions in the prior art, the following briefly introduces the drawings required for use in the embodiments or the prior art descriptions. Obviously, the drawings described below are only some embodiments of the present application. For ordinary technicians in this field, other drawings can be obtained based on these drawings without creative work. In the drawings:
[0079] Figure 1 It is a flowchart of a method for constructing a heterogeneous distribution model provided in one embodiment of the present application.
[0080] Figure 2 It is a flowchart of a method for constructing a heterogeneous distribution model provided in one embodiment of the present application.
[0081] Figure 3 It is a schematic diagram of a data exchange transmission network provided in an embodiment of the present application.
[0082] Figure 4 These are the linear and box plots of the estimation error when K=20 and redundancy parameter∈[1,10].
[0083] Figure 5It is the linear graph and box plot of the estimation error when K=20 & redundancy parameter∈[0.1,1].
[0084] Figure 6 It is a structural schematic diagram of a device for constructing a heterogeneous distribution model provided in one embodiment of the present application.
[0085] Figure 7 It is a structural schematic diagram of a device for constructing a heterogeneous distribution model provided in one embodiment of the present application.
[0086] Figure 8 It is a schematic diagram of the physical structure of an electronic device provided in one embodiment of the present application. DETAILED DESCRIPTION
[0087] In order to make the purpose, technical scheme and advantages of the embodiments of the present application clearer, the embodiments of the present application are further described in detail below in conjunction with the accompanying drawings. Here, the illustrative embodiments of the present application and their descriptions are used to explain the present application, but are not intended to limit the present application. It should be noted that, in the absence of conflict, the embodiments in the present application and the features in the embodiments can be arbitrarily arranged with each other.
[0088] The terms “first”, “second”, etc. used in this document do not specifically refer to an order or sequence, nor are they used to limit this application. They are only used to distinguish elements or operations described with the same technical terms.
[0089] The words “include,” “including,” “have,” “contain,” etc. used in this document are open-ended terms, meaning including but not limited to.
[0090] As used herein, "and / or" includes any and all permutations of the items described.
[0091] The information collected by this application is information and data authorized by the user or fully authorized by all parties, and the collection, storage, use, processing, transmission, provision, disclosure and application of relevant data comply with the relevant laws, regulations and standards of relevant countries and regions, take necessary confidentiality measures, do not violate public order and good customs, and provide users with corresponding operation entrances for users to choose to agree or reject the automated decision-making results; if the user chooses to reject, the expert decision-making process will be entered.
[0092] In order to better understand the present application, the key terms involved in the present application are first introduced in detail below.
[0093] Distributed storage: In 1988, Bernstein et al. investigated, consolidated and introduced the current status of concurrent control of distributed databases, mainly solving the concurrency problems of read-write operations and write-write operations. In 2003, Ghemawat et al. designed and implemented a scalable distributed file system, which truly realized the implementation of distributed storage. The key cost of data storage lies in the cost of the machine. Chang et al. designed a distributed storage system for managing structured data, effectively managing PB-level data on thousands of servers to ensure the correctness and integrity of the data. After the basic architecture of data storage and management was formed, Dean et al. pioneered the design of an implementation method for processing large data sets - MapReduce, based on the idea of "mobile computing rather than mobile data". At this point, the basic solution for data storage, management and calculation in distributed scenarios has been formed, and distributed storage has also been used in the industrial sector.
[0094] Heterogeneity: Heterogeneity is an issue that cannot be ignored in the context of big data. In real data, due to different regional environments, there will be differences in the data collected in different regions. For example, in medical data, the patient data collected by each data center has obvious group differences due to population and environmental reasons. The assumptions for the heterogeneous massive data set (Yi, Xi, Zi) (i = 1) N are as follows: Assume that there are s sub-groups, and the j-th group follows the following partial linear model distribution:
[0095]
[0096] Among them, the linear function of Y depends on X, and X is the explanatory variable that differs among subgroups; the nonlinear function of Y depends on Z, and Z is the same explanatory variable for all subgroups.
[0097] Newton Iteration Method: Iterative solution is a commonly used parameter optimization method in parameter estimation. When the optimal solution cannot be obtained directly, the optimal solution can be gradually approached through iterative solution. The Newton Iteration Method is one of the most commonly used parameter estimation methods. This method uses the first few terms of the Taylor series of the function expansion to find the roots of the equation. Assuming that the target equation is f(x) = 0, after Taylor expansion, only the first two terms are retained to obtain g(x) = f(x0) + f′(x0)(x-x0). Then the equation is equivalent to g(x) = 0.
[0098] Alternating Direction Multiplier Method: The Alternating Direction Multiplier Method solves the problem of being unable to be decomposed. The Alternating Direction Multiplier Method is very suitable for distributed convex optimization problems, especially when large-scale problems arise. The Alternating Direction Multiplier Method combines the decomposability of the dual ascent algorithm with the convergence of the Lagrange multiplier method, and obtains the optimal solution through three steps of alternating iterations.
[0099] The execution subject of the method for constructing the heterogeneous distribution model provided in the present application includes but is not limited to a computer.
[0100] Figure 1 is a flow chart of a method for constructing a heterogeneous distribution model provided in an embodiment of the present application, such as Figure 1 As shown, the method for constructing a heterogeneous distribution model provided in the embodiment of the present application includes:
[0101] S101. Calculate initial estimates of common parameters based on local heterogeneous banking alliance distributed data;
[0102] S102, sending the initial estimated value of the common parameter to the master node, the master node being used to calculate the average value of the common parameter according to the initial value of the common parameter sent by each of the sub-nodes;
[0103] S103, solving the effective score function according to the average value of the common parameter to obtain a first updated value of the common parameter;
[0104] S104, sending the first updated value of the common parameter to the master node, the master node being used to solve the overall replacement effective score function according to the first updated value of the common parameter sent by each of the child nodes to obtain a second updated value of the common parameter;
[0105] S105, calculating the value of the approximate Hessian matrix according to the second updated value of the common parameter;
[0106] S106, sending the value of the approximate Hessian matrix to the master node, the master node being used to solve the approximate global Hessian matrix according to the value of the approximate Hessian matrix sent by each of the child nodes, to obtain a third updated value of the common parameter;
[0107] S107, updating the value of the heterogeneity parameter using an alternative effective score function according to the third updated value of the common parameter;
[0108] S108. Construct a heterogeneity distribution model of the node according to the value of the heterogeneity parameter and the third updated value of the common parameter.
[0109] The method for constructing a heterogeneous distribution model provided in the embodiment of the present application uses an effective scoring function to replace the original scoring function to handle the heterogeneity between the child nodes, and then approximates the optimal solution through an iterative algorithm. The above method solves the problem of heterogeneous distributed bank data, the inability to share information due to the difficulty in exchanging data between nodes, and the difficulty in estimating parameters of the federated model.
[0110] In some embodiments, an initial estimate of the common parameter is calculated according to the following formula:
[0111]
[0112] Where yi is the response variable, x i is the explanatory variable, θ = (β, γ) is the unknown parameter, including the common parameter β and the redundant parameter γ, This means solving the β that minimizes the following formula.
[0113] In some embodiments, the expression of the effective score function is as follows:
[0114]
[0115] In the formula, s j (y; β, γ j ) represents the effective score function of the j-th node, y is the response variable in the heterogeneous banking alliance distribution data of the j-th node, β is the common parameter on the j-th node, γ j is the redundant parameter of the jth node, and is the information matrix I on the jth node (j) The information matrix is the submatrix of the corresponding position of the information matrix, which is the inverse of the variance of each variable in the data set under a given model. It can be used to estimate the standard error and confidence space of the model parameters. The f function is the joint density function under given parameters.
[0116] In some embodiments, the expression of the approximate Hessian matrix is as follows:
[0117] A t,j T A t,j ;
[0118] In the formula, A t,j Contains the matrix A of the tth iteration t The data subset κ j The corresponding row, in l″ i It means taking the derivative of the likelihood function twice. represents the transpose of the corresponding vector of the parameter θ of the tth row of the i-th node, x i is the explanatory variable of the i-th node, and θ = (β, γ) represents the unknown parameter.
[0119] In some embodiments, the expression of the alternative effective score function is as follows:
[0120]
[0121] Among them, g * (y;β) represents the alternative effective score function, sj is the effective score function on the jth node, K is the number of nodes, y is the response variable of the jth node, y ij The value of the jth response variable at the ith node, β * is a set of estimates of the common parameters, is the redundant parameter estimate of the first node, The set of redundant parameter estimates of the jth node, and the f function is the joint density function under given parameters.
[0122] Figure 2 is a flow chart of a method for constructing a heterogeneous distribution model provided in an embodiment of the present application, such as Figure 2 As shown, the method for constructing a heterogeneous distribution model provided in the embodiment of the present application includes:
[0123] S201, obtaining an initial estimated value of a common parameter sent by each child node;
[0124] S202, calculating an average value of the common parameter according to the initial value of the common parameter sent by each of the sub-nodes;
[0125] S203, sending the average value of the common parameter to each of the child nodes, wherein each of the child nodes is used to solve the effective score function according to the average value of the common parameter to obtain a first updated value of the common parameter;
[0126] S204, solving the overall replacement effective score function according to the first updated value of the common parameter sent by each of the child nodes to obtain a second updated value of the common parameter;
[0127] S205, sending the second updated value of the common parameter to each of the child nodes, and each of the child nodes is used to calculate the value of the approximate Hessian matrix according to the second updated value of the common parameter;
[0128] S206, solving the approximate global Hessian matrix according to the value of the approximate Hessian matrix sent by each of the child nodes to obtain a third updated value of the common parameter;
[0129] S207. Send the third updated value of the common parameter to each of the child nodes, each of the child nodes is used to update the value of the heterogeneity parameter according to the third updated value of the common parameter, and construct a logistic regression model of the child node according to the value of the heterogeneity parameter updated by the child node and the third updated value of the common parameter.
[0130] The method for constructing a heterogeneous distribution model provided in the embodiment of the present application uses an effective scoring function to replace the original scoring function to handle the heterogeneity between the child nodes, and then approximates the optimal solution through an iterative algorithm. The above method solves the problem of heterogeneous distributed bank data, the inability to share information due to the difficulty in exchanging data between nodes, and the difficulty in estimating parameters of the federated model.
[0131] In some embodiments, the overall alternative effective score function is expressed as follows:
[0132]
[0133] in, represents the overall alternative effective score function, represents the alternative effective score function on the first node, β represents the true value of the common parameter that needs to be estimated, represents the average value of the common parameter estimated by all nodes for the first time, and γ represents the true value of the redundant parameter to be estimated. represents the estimated value of the redundant parameter on the jth node, Represents the average matrix of the redundant parameter vector estimates on each child node, L j Represents the global empirical likelihood function at the jth node;
[0134]
[0135] Among them, y i1 represents the value of the ith response variable of the 1st node, and n represents the number of response variables / explanatory variables in the heterogeneous banking alliance distribution data of the jth node;
[0136]
[0137] Among them, K is the number of nodes, y is the true value of the response variable, and β represents the true value of the common parameter to be estimated. It represents the average value of the common parameter estimated by all nodes for the first time. represents the estimated value of the redundant parameter on the jth node, represents the estimated value of the redundant parameter on the first node, the f function is the joint density function under the given parameters, and L j Represents the global empirical likelihood function at the jth node.
[0138] In some embodiments, the expression of the approximate global Hessian matrix is as follows:
[0139]
[0140] Where n represents the number of response variables / explanatory variables in the heterogeneous banking alliance distribution data of the jth node, K is the number of nodes,
[0141]
[0142]
[0143]
[0144]
[0145] M βγ First, we find the partial derivative of β, and then find the partial derivative of γ.
[0146] M γγ is to find the partial derivative of γ twice,
[0147]
[0148]
[0149]
[0150] Among them, l″ i It means to find the derivative of the likelihood function l twice, x ij represents the explanatory variable corresponding to the i-th common parameter part at the j-th node, z ij represents the explanatory variable corresponding to the i-th redundant parameter part on the j-th node, β t represents the estimated value of the common parameter at the tth iteration, γ t,j represents the true value of the redundant parameter of the tth row on the jth node, X ij A represents the matrix of all explanatory variables. j =A t,j , A t,j Contains the matrix A of the tth iteration t The data subset κ j The corresponding row, in l″ i It means to find two derivatives of the likelihood function. represents the transpose of the corresponding vector of the parameter θ of the tth row of the i-th node, x i is the explanatory variable of the i-th node, and θ = (β, γ) represents the unknown parameter.
[0151] Since there are many parameters involved in this application, the meaning of each parameter is explained in detail through Table 1 below to better understand the differences between the parameters.
[0152] Table 1: Parameter definition table
[0153]
[0154]
[0155]
[0156] In order to better understand the present application, the method for constructing the heterogeneous distribution model provided by the present application is described in detail below through a specific embodiment.
[0157] Traditional statistical methods cannot be used directly in the context of big data distribution. Therefore, how to compress the dimension of the parameter estimation function on a single node, and then aggregate the parameter estimation function on the main node through data exchange has become a key technical problem that needs to be solved urgently by distributed statistical methods. In terms of theory, there are relatively few studies on heterogeneous distributed models in the existing literature. Most scholars’ research directions are homogeneous distributed models or heterogeneous low-dimensional models. Therefore, this application is meaningful in theory for the research on the distributed data model of heterogeneous bank alliances. In terms of practical significance, the real data of banks is currently mainly stored in a distributed environment, and most of them have heterogeneous properties. Therefore, this application provides a feasible method for model establishment and parameter estimation of distributed data of heterogeneous bank alliances in reality, which is of practical significance.
[0158] For the distributed data of heterogeneous bank alliances, in order to deal with the heterogeneity between each child node, the main idea of this application is to replace the original scoring function with an effective scoring function. Duan et al. have proved that the effective scoring function is insensitive to heterogeneous interference variables and can reduce the deviation of the estimation results of common variables; for the model, this application reduces the dimension of the parameters through regularization terms. The specific method is to use a penalized effective scoring function to perform parameter estimation and variable selection on heterogeneous distributed models. Solving the penalized effective scoring function is a constrained optimization problem. In order to facilitate calculation, it is necessary to approximate the optimal solution through an iterative algorithm. Therefore, inspired by the global optimization approximate Newton, a global optimization approximate Newton iteration suitable for the penalized effective scoring function is proposed. Finally, the effectiveness of the global optimization approximate Newton iteration method of the penalized effective scoring function is jointly proved through simulation.
[0159] The above method solves the problem of heterogeneous distributed banking data, the inability to share information due to the difficulty in exchanging data between nodes, and the difficulty in estimating parameters of the federated model.
[0160] The detailed scheme provided in this embodiment is as follows:
[0161] (1) Technical solution for dimensional compression of parameter estimation functions on a single node
[0162] Estimating the parameters of the model through the score function is an important method in statistical analysis. It is obtained by taking the derivative of the logarithmic empirical likelihood function. The main idea of the maximum empirical likelihood function method is to hope that the value of the parameter can maximize the probability of observing the current set of sample data. Assume that a set of sample data is in the form of (y i , x i ), i∈(1,...,n), and the unknown parameter is θ, then the empirical likelihood function is defined as:
[0163]
[0164] The log-empirical likelihood function is defined as:
[0165]
[0166] After taking the partial derivative of the maximum empirical likelihood function, we get the score function:
[0167]
[0168] By solving the equation s(θ)=0, we can get the estimated value of the parameter θ.
[0169] The effective scoring function proposed in this application is a technical solution for dimensional compression of parameter estimation function on a single node, which is essentially a score function of common parameter β combined with redundant parameter γ j The projection on the space orthogonal to the space where the score function of is located. At the jth node, the effective score function is defined as follows:
[0170]
[0171] in, and It is the submatrix of the corresponding position of the information matrix on the jth node. The information matrix refers to the matrix composed of the inverse of the variance of each variable in the data set under a given model, which can be used to estimate the standard error and confidence space of the model parameters. j is the effective score function on the jth node, K is the number of nodes, yi is the response variable, x i is the explanatory variable, β is the common parameter, γ is the redundant parameter, and the f function is the joint density function under given parameters.
[0172] The effective scoring function compresses the original score function matrix of (p+m)*n into a p*n matrix. By projecting the score function of the common parameter β(p*1) onto a space orthogonal to the space of the score function of the redundant parameter γj(m*1), the problem of simultaneously estimating the common parameter β and the redundant parameter γj is converted into a problem of estimating the common parameter β alone, compressing the data dimension of the parameter estimation function on a single node and reducing the amount of data exchanged between subsequent nodes.
[0173] (2) Technical solutions for constructing data exchange and transmission networks
[0174] In order to realize data exchange between nodes, this application proposes an asynchronous data exchange method, which can use the publish-subscribe mode. First, select any node from all nodes as the master node, which is used as a bridge for data exchange between other nodes. After the data transmission channel between each child node and the master node is established, each child node will transmit the data to the master node, and then the master node will process it and transmit it to each child node. This solution can also realize data exchange between each child node. Figure 3 As shown, for example, when data exchange is required between node 1 and node 4, node 1 and node 4 will first transmit their own data to the master node, and then obtain the required data from the master node.
[0175] Data exchange between two nodes can be achieved through the network. In the network, data is transmitted in the form of data packets. The data packet contains the source address, destination address, data and other control information. Data exchange between nodes can be achieved through the following steps:
[0176] 1) Determine the address of the target node: Before exchanging data, the address of the target node needs to be determined.
[0177] 2) Packing data into packets: Pack the data to be sent into packets and add control information such as source address and destination address.
[0178] 3) Select a suitable transport protocol: Select a suitable transport protocol, such as TCP or UDP, according to the network environment and requirements.
[0179] 4) Send data packet: Send the packaged data packet to the target node.
[0180] 5) The target node receives the data packet: After receiving the data packet, the target node parses the control information and extracts the data.
[0181] (3) Aggregation technology solution for parameter estimation functions on the master node
[0182] After the data of each child node is transmitted to the master node through the above-mentioned data exchange scheme, the substitute effective functions of a single node are then aggregated. This application proposes a master node function aggregation technical solution: constructing an overall effective score function, and solving the overall effective substitute score function can obtain the estimated value of the common parameter. The expression of the overall effective score function is:
[0183] where s j is the effective score function on the jth node, K is the number of nodes, y i is the response variable, x i is the explanatory variable, β is the common parameter, γ is the redundant parameter, and the f function is the joint density function under given parameters.
[0184] In order to improve the computational efficiency of the data, an alternative effective score function g*(y;β) is constructed by using the individual level data of one (e.g., the first) node and the summary level data of other nodes to approximate the effective score function. The approximate expression of the alternative effective score function is as follows:
[0185]
[0186] in, is the density ratio, which is used to adjust the heterogeneity between nodes, s j is the effective score function on the jth node, K is the number of nodes, yi is the response variable, x i is the explanatory variable, β is the common parameter, γ is the redundant parameter, and the f function is the joint density function under given parameters.
[0187] It can be shown that the alternative effective score function equation holds, where S is the overall effective score function of all nodes, Yi is the response variable, β is a common parameter, Γ is a redundant parameter, and g is an alternative effective score function.
[0188] For the unknowns β*, γj*, and Ij in the alternative effective score function, they can be replaced by initial estimates β, j, and H(1, j), respectively, where
[0189]
[0190] In summary, the approximate expression of the alternative effective score function is:
[0191]
[0192] make The final overall alternative effective score function expression is:
[0193]
[0194] in,
[0195] In the specific solution process, the estimated values of the common parameters of each node are first averaged to obtain the initial estimated value β, and then An updated estimate β~o of β is obtained, and after transmitting this estimate to each child node, each child node updates the estimated value of the redundant parameter.
[0196] The specific implementation steps of the method for constructing a heterogeneous distribution model of distributed data of a heterogeneous banking alliance are as follows:
[0197] 1) In order to meet the characteristics of distributed data, a data exchange and transmission network is first constructed between all nodes.
[0198] 2) In order to reduce the amount of data transmitted and increase data transmission efficiency, the dimension of the parameter estimation function is compressed on a single node. Specifically, for a general parameter estimation function, the dimension of the parameter is equal to the dimension of the function. In this large step, we compress the dimension of the function from the dimension of common parameters + redundant parameters to the dimension of common parameters. During data transmission, the amount of data transmitted is reduced, which increases the transmission efficiency. Each child node calculates the initial estimate Solving the equation is
[0199]
[0200] Through the data exchange transmission network constructed in the above steps, each child node transmits the initial estimated value of β to the master node and summarizes it on the master node to obtain After the master node obtains the summary value of β, it transmits it through the data exchange transmission network. Transmitted to the child node. Calculated on each node Then it is transmitted to the master node through the data exchange transmission network, and the master node calculates And transmit it to the child nodes through the data exchange transmission network. Each child node calculates A t,j T A t,j The value is transmitted through the data exchange network to the master node.
[0201] 3) After acquiring the data from each node, the master node aggregates the parameter estimation function. The master node calculates:
[0202]
[0203] According to the formula Update the β estimate and transmit it to each child node to update the parameter estimate. Each child node updates γ j The estimated value of .
[0204] At this point, this scheme can obtain the parameter estimates of the logistic regression model constructed for the distributed data of heterogeneous alliance banks.
[0205] The following will verify the effectiveness of the method of this application through experiments, and compare the two algorithms with other common distributed parameter estimation methods in terms of estimation accuracy and robustness. In a simulated data environment, the experiment will generate simulated data with 4 differentiated data features, and repeat the experiment many times to exclude the influence of random factors on the experimental results. Due to the widespread use of logistic regression models in distributed medical data, a distributed heterogeneous logistic regression model is used in this application to generate simulated data. In a real data environment, this application will use patient data from certain regions to verify the effectiveness of the algorithm. The real data contains patient data from 5 regions, and the patient data between regions are different and heterogeneous, so this application will identify the heterogeneous factors, split the explanatory variables into common variables and heterogeneous variables, and then establish a logistic regression model for the explanatory variables and the dependent variables, and compare the accuracy of the predictions of different algorithms. The procedures for simulated data experiments and real data experiments can all be completed by Python.
[0206] In the simulated data analysis, it is assumed that the data is distributed on K (K = 20, 50) node machines, and the data volume of each node is n∈[100, 300]. The data on the jth node is (Yj, Xj) following the logistic regression model, where Yj obeys the binary Bernoulli distribution and has two values of -1 and 1, Xj = (xj, zj) is an n*d dimensional matrix, xj∈Rn*p represents the homogeneous independent variables between the nodes, and zj∈Rn*(dp) represents the heterogeneous independent variables between the nodes. β is a common parameter, and γj is a redundant parameter on the jth node. The dependent variable Yj and the independent variable (xj, zj) obey the following model assumptions:
[0207] logit{Pr(Yj=1xj,zj)}=βxj+γjzj
[0208] Among them, xj follows the bivariate Bernoulli distribution Ber(q), where q follows the uniform distribution U(0.1, 0.5); zj follows the multivariate normal distribution, whose mean is the negative of the values of the first 10 common variables xj, and the variance is I(dp)*(dp). The first m terms of the common parameter β are 1, and the values of the last pm terms are all 0, and γj follows the uniform distribution Uj(-aj, aj).
[0209] See also Figure 4 and Figure 5, this application compares the estimated variance in two scenarios: 1) the total number of nodes is 20 and the redundant parameters are small; 2) the total number of nodes is 20 and the redundant parameters are large. In the experiment of simulated data, the performance of the following four methods is compared:
[0210] M0: represents one iteration of the ADMM-PESF method
[0211] M1: represents the GANT-PESF method with multiple iterations (the method provided by this application)
[0212] M2: represents one-iteration SESF method
[0213] M3: represents the average of all local maximum likelihood estimation EE method in one iteration
[0214] It can be seen that in the above two scenarios, the estimation variance of the GANT-PESF method with multiple iterations is smaller than that of the other three methods, which means that the performance of this method is higher.
[0215] Therefore, this application can solve the difficulties in information exchange between the sub-nodes of the bank alliance data, and the contradiction between privacy data protection and effective data exchange. In addition, when modeling distributed data, this application takes into account the common problem of heterogeneous data and estimates the parameters of the heterogeneous part, which is conducive to increasing the accuracy and completeness of the model.
[0216] Figure 6 is a schematic diagram of a process of constructing a heterogeneous distribution model provided in an embodiment of the present application. Figure 6 As shown, the device for constructing a heterogeneous distribution model provided in the embodiment of the present application includes:
[0217] A first calculation module 31, for calculating initial estimates of common parameters based on local heterogeneous bank alliance distributed data;
[0218] A first sending module 32, configured to send the initial estimated value of the common parameter to a master node, wherein the master node is configured to calculate an average value of the common parameter according to the initial value of the common parameter sent by each of the sub-nodes;
[0219] A first solving module 33, configured to solve the effective score function according to the average value of the common parameter to obtain a first updated value of the common parameter;
[0220] A second sending module 34 is used to send the first updated value of the common parameter to the master node, and the master node is used to solve the overall replacement effective score function according to the first updated value of the common parameter sent by each of the child nodes to obtain the second updated value of the common parameter;
[0221] A second calculation module 35, used for calculating the value of the approximate Hessian matrix according to the second updated value of the common parameter;
[0222] A third sending module 36 is used to send the value of the approximate Hessian matrix to the master node, and the master node is used to solve the approximate global Hessian matrix according to the value of the approximate Hessian matrix sent by each of the child nodes to obtain a third updated value of the common parameter;
[0223] An updating module 37, configured to update the value of the heterogeneity parameter using an alternative effective score function according to the third updated value of the common parameter;
[0224] The construction module 38 is used to construct a heterogeneity distribution model of the node according to the value of the heterogeneity parameter and the third updated value of the common parameter.
[0225] The heterogeneous distribution model construction device provided in the embodiment of the present application uses an effective scoring function to replace the original scoring function to handle the heterogeneity between the child nodes, and then approximates the optimal solution through an iterative algorithm. The above method solves the problem of heterogeneous distributed bank data, the inability to share information due to the difficulty in exchanging data between nodes, and the difficulty in estimating parameters of the federated model.
[0226] Figure 7 is a schematic diagram of a process of constructing a heterogeneous distribution model provided in an embodiment of the present application. Figure 7 As shown, the device for constructing a heterogeneous distribution model provided in the embodiment of the present application includes:
[0227] An acquisition module 41 is used to acquire an initial estimated value of a common parameter sent by each sub-node;
[0228] A third calculation module 42, configured to calculate an average value of the common parameter according to the initial value of the common parameter sent by each of the sub-nodes;
[0229] A fourth sending module 43, configured to send the average value of the common parameter to each of the child nodes, wherein each of the child nodes is configured to solve the effective score function according to the average value of the common parameter to obtain a first updated value of the common parameter;
[0230] A second solving module 44 is used to solve the overall replacement effective score function according to the first updated value of the common parameter sent by each of the child nodes to obtain a second updated value of the common parameter;
[0231] A fifth sending module 45, configured to send the second updated value of the common parameter to each of the child nodes, and each of the child nodes is configured to calculate a value of an approximate Hessian matrix according to the second updated value of the common parameter;
[0232] A third solving module 46 is used to solve the approximate global Hessian matrix according to the value of the approximate Hessian matrix sent by each of the child nodes to obtain a third updated value of the common parameter;
[0233] The sixth sending module 47 is used to send the third updated value of the common parameter to each of the child nodes, and each of the child nodes is used to update the value of the heterogeneity parameter according to the third updated value of the common parameter, and to construct a logistic regression model of the child node according to the value of the heterogeneity parameter updated by the child node and the third updated value of the common parameter.
[0234] The heterogeneous distribution model construction device provided in the embodiment of the present application uses an effective scoring function to replace the original scoring function to handle the heterogeneity between the child nodes, and then approximates the optimal solution through an iterative algorithm. The above method solves the problem of heterogeneous distributed bank data, the inability to share information due to the difficulty in exchanging data between nodes, and the difficulty in estimating parameters of the federated model.
[0235] The embodiments of the device provided in the embodiments of the present application can be specifically used to execute the processing flow applied to the above-mentioned various method embodiments. Its functions are not repeated here, and reference can be made to the detailed description of the above-mentioned method embodiments.
[0236] It should be noted that the method and device for constructing a heterogeneous distribution model provided in the embodiments of the present application can be used in the financial field, and can also be used in any technical field other than the financial field. The embodiments of the present application do not limit the application field of the method and device for constructing a heterogeneous distribution model.
[0237] Figure 8 A schematic diagram of the physical structure of an electronic device provided in an embodiment of the present application is shown in FIG. Figure 8 As shown, the electronic device may include: a processor 501, a communication interface 502, a memory 503 and a communication bus 504, wherein the processor 501, the communication interface 502 and the memory 503 communicate with each other through the communication bus 504. The processor 501 may call the logic instructions in the memory 503 to execute the method described in any of the above embodiments.
[0238] In addition, the logic instructions in the above-mentioned memory 503 can be implemented in the form of software functional units and can be stored in a computer-readable storage medium when sold or used as an independent product. Based on such an understanding, the technical solution of the present application can be essentially or partly embodied in the form of a software product that contributes to the prior art, and the computer software product is stored in a storage medium, including several instructions to enable a computer device (which can be a personal computer, a server, or a network device, etc.) to perform all or part of the steps of the method described in each embodiment of the present application. The aforementioned storage medium includes: various media that can store program codes, such as a USB flash drive, a mobile hard disk, a read-only memory (ROM), a random access memory (RAM), a disk or an optical disk.
[0239] This embodiment discloses a computer program product, which includes a computer program stored on a non-transitory computer-readable storage medium. The computer program includes program instructions. When the program instructions are executed by a computer, the computer can execute the methods provided by the above-mentioned method embodiments.
[0240] This embodiment provides a computer-readable storage medium, wherein the computer-readable storage medium stores a computer program, and the computer program enables the computer to execute the methods provided by the above method embodiments.
[0241] Those skilled in the art will appreciate that the embodiments of the present application may be provided as methods, systems, or computer program products. Therefore, the present application may adopt the form of a complete hardware embodiment, a complete software embodiment, or an embodiment in combination with software and hardware. Moreover, the present application may adopt the form of a computer program product implemented in one or more computer-usable storage media (including but not limited to disk storage, CD-ROM, optical storage, etc.) that include computer-usable program code.
[0242] The present application is described with reference to the flowcharts and / or block diagrams of the methods, devices (systems), and computer program products according to the embodiments of the present application. It should be understood that the processes and / or blocks in the flowcharts and / or block diagrams, as well as the combination of the processes and / or blocks in the flowcharts and / or block diagrams, can be implemented by computer program instructions. These computer program instructions can be provided to a processor of a general-purpose computer, a special-purpose computer, an embedded processor, or other programmable data processing device to generate a machine, so that the instructions executed by the processor of the computer or other programmable data processing device generate instructions for implementing the processes in the flowcharts. Figure 1 A process or multiple processes and / or boxes Figure 1 A device that provides the functions specified in a block or multiple blocks.
[0243] These computer program instructions may also be stored in a computer-readable memory capable of directing a computer or other programmable data processing device to operate in a specific manner, so that the instructions stored in the computer-readable memory produce an article of manufacture comprising an instruction device, which implements the process Figure 1 A process or multiple processes and / or boxes Figure 1 A function specified in one or more boxes.
[0244] These computer program instructions can also be loaded onto a computer or other programmable data processing device so that a series of operating steps are executed on the computer or other programmable device to produce a computer-implemented process, thereby providing instructions for implementing the process. Figure 1 A process or multiple processes and / or boxes Figure 1 The steps for the functions specified in one or more boxes.
[0245] In the description of this specification, the description with reference to the terms "one embodiment", "a specific embodiment", "some embodiments", "for example", "example", "specific example", or "some examples" means that the specific features, structures, materials or characteristics described in conjunction with the embodiment or example are included in at least one embodiment or example of the present application. In this specification, the schematic representation of the above terms does not necessarily refer to the same embodiment or example. Moreover, the specific features, structures, materials or characteristics described may be combined in any one or more embodiments or examples in a suitable manner.
[0246] The specific embodiments described above further illustrate the purpose, technical solutions and beneficial effects of the present application. It should be understood that the above description is only a specific embodiment of the present application and is not intended to limit the scope of protection of the present application. Any modifications, equivalent substitutions, improvements, etc. made within the spirit and principles of the present application should be included in the scope of protection of the present application.
Claims
1. A method for constructing a heterogeneous distribution model, characterized in that: include: Compute initial estimates of common parameters based on local, heterogeneous banking union distribution data; Sending the initial estimated value of the common parameter to the master node, the master node being used to calculate the average value of the common parameter according to the initial value of the common parameter sent by each of the sub-nodes; Solving the effective score function according to the average value of the common parameter to obtain a first updated value of the common parameter; Sending the first updated value of the common parameter to the master node, the master node being used to solve the overall replacement effective score function according to the first updated value of the common parameter sent by each of the child nodes to obtain a second updated value of the common parameter; Calculating a value of an approximate Hessian matrix according to a second updated value of the common parameter; Sending the value of the approximate Hessian matrix to a master node, wherein the master node is used to solve the approximate global Hessian matrix according to the value of the approximate Hessian matrix sent by each of the child nodes to obtain a third updated value of the common parameter; updating the value of the heterogeneity parameter using an alternative effective score function according to a third updated value of the common parameter; According to the value of the heterogeneity parameter and the third updated value of the common parameter, a heterogeneity distribution model of the node is constructed.
2. The method according to claim 1, characterized in that Initial estimates of the common parameters are calculated according to the following formula: In the formula, represents the initial estimate of the unknown parameters of the jth node, is the response variable in the heterogeneous banking alliance distribution data of the jth node, X j is the explanatory variable in the heterogeneous banking alliance distribution data of the jth node, θ j =(β j , γ j ) is the unknown parameter of the jth node, including the common parameter β j and the redundant parameter γ j , The meaning is to solve the β that minimizes the value of the following formula. j , n represents the number of response variables / explanatory variables in the heterogeneous banking alliance distribution data of the jth node.
3. The method according to claim 2, characterized in that The expression of the effective score function is as follows: In the formula, represents the effective score function of the jth node, is the response variable in the heterogeneous banking alliance distribution data of the jth node, β is the common parameter on the jth node, and γ j is the redundant parameter of the jth node, and is the information matrix I on the jth node (j) The information matrix is the submatrix of the corresponding position of the information matrix, which is the inverse of the variance of each variable in the data set under a given model. It can be used to estimate the standard error and confidence space of the model parameters. The f function is the joint density function under given parameters.
4. The method according to claim 3, characterized in that: The expression of the approximate Hessian matrix is as follows: In the formula, A t,j Contains the matrix A of the tth iteration t The data subset κ j The corresponding row, in It means taking the derivative of the likelihood function twice. represents the transpose of the corresponding vector of the parameter θ of the tth row of the i-th node, x i is the explanatory variable of the i-th node, and θ=(β,γ) represents the unknown parameter.
5. The method according to claim 4, characterized in that The expression of the alternative effective score function is as follows: in, represents the alternative effective score function, s j is the effective score function on the jth node, K is the number of nodes, is the response variable of the jth node, The value of the jth response variable at the ith node, β * is a set of estimates of the common parameters, is the redundant parameter estimate of the first node, The set of redundant parameter estimates of the jth node, and the f function is the joint density function under given parameters.
6. A method for constructing a heterogeneous distribution model, characterized in that: include: Obtaining the initial estimated values of the common parameters sent by each child node; Calculating an average value of the common parameter according to the initial value of the common parameter sent by each of the sub-nodes; Sending the average value of the common parameter to each of the child nodes, wherein each of the child nodes is used to solve the effective score function according to the average value of the common parameter to obtain a first updated value of the common parameter; Solving the overall replacement effective score function according to the first updated value of the common parameter sent by each of the child nodes to obtain a second updated value of the common parameter; Sending the second updated value of the common parameter to each of the child nodes, each of the child nodes being used to calculate the value of the approximate Hessian matrix according to the second updated value of the common parameter; Solving the approximate global Hessian matrix according to the value of the approximate Hessian matrix sent by each of the child nodes to obtain a third updated value of the common parameter; The third updated value of the common parameter is sent to each of the child nodes, and each of the child nodes is used to update the value of the heterogeneity parameter according to the third updated value of the common parameter, and construct a logistic regression model of the child node according to the value of the heterogeneity parameter updated by the child node and the third updated value of the common parameter.
7. The method according to claim 6, characterized in that The expression of the overall alternative effective score function is as follows: in, represents the overall alternative effective score function, represents the alternative effective score function on the first node, β represents the true value of the common parameter that needs to be estimated, represents the average value of the common parameter estimated by all nodes for the first time, and γ represents the true value of the redundant parameter to be estimated. represents the estimated value of the redundant parameter on the jth node, Represents the average matrix of the redundant parameter vector estimates on each child node, L j Represents the global empirical likelihood function at the jth node; in, represents the value of the ith response variable of the 1st node, and n represents the number of response variables / explanatory variables in the heterogeneous banking alliance distribution data of the jth node; Where K is the number of nodes, is the true value of the response variable, β represents the true value of the common parameter to be estimated, It represents the average value of the common parameter estimated by all nodes for the first time. represents the estimated value of the redundant parameter on the jth node, represents the estimated value of the redundant parameter on the first node, the f function is the joint density function under the given parameters, and L j Represents the global empirical likelihood function at the jth node.
8. The method according to claim 6, characterized in that The expression of the approximate global Hessian matrix is as follows: Where n represents the number of response variables / explanatory variables in the heterogeneous banking alliance distribution data of the jth node, K is the number of nodes, M βγ First, we take the partial derivative of β and then the partial derivative of γ. M γγ Yes, take the partial derivative of γ twice, Among them, l″ i It means to find the derivative of the likelihood function l twice, x ij represents the explanatory variable corresponding to the i-th common parameter part at the j-th node, z ij represents the explanatory variable corresponding to the i-th redundant parameter part on the j-th node, β t represents the estimated value of the common parameter at the tth iteration, γ t,j represents the true value of the redundant parameter of the tth row on the jth node, X ij A is the matrix representing all explanatory variables. j =A t,j , A t,j Contains the matrix A of the tth iteration t The data subset κ j The corresponding row, in It means taking the derivative of the likelihood function twice. represents the transpose of the corresponding vector of the parameter θ of the tth row of the i-th node, x i is the explanatory variable of the i-th node, and θ=(β,γ) represents the unknown parameter.
9. A device for constructing a heterogeneous distribution model, characterized in that: include: A first calculation module, for calculating initial estimates of common parameters based on local heterogeneous bank alliance distributed data; A first sending module, used for sending the initial estimated value of the common parameter to the master node, and the master node is used for calculating the average value of the common parameter according to the initial value of the common parameter sent by each of the sub-nodes; A first solving module, used for solving the effective score function according to the average value of the common parameter to obtain a first updated value of the common parameter; A second sending module, configured to send the first updated value of the common parameter to a master node, wherein the master node is configured to solve the overall replacement effective score function according to the first updated value of the common parameter sent by each of the child nodes to obtain a second updated value of the common parameter; A second calculation module, used for calculating the value of the approximate Hessian matrix according to the second updated value of the common parameter; A third sending module, used for sending the value of the approximate Hessian matrix to the master node, and the master node is used for solving the approximate global Hessian matrix according to the value of the approximate Hessian matrix sent by each of the child nodes to obtain a third updated value of the common parameter; an updating module, configured to update the value of the heterogeneity parameter using an alternative effective score function according to a third updated value of the common parameter; The construction module is used to construct a heterogeneity distribution model of the node according to the value of the heterogeneity parameter and the third updated value of the common parameter.
10. A device for constructing a heterogeneous distribution model, characterized in that: include: An acquisition module, used to acquire an initial estimated value of a common parameter sent by each sub-node; A third calculation module, configured to calculate an average value of the common parameter according to the initial value of the common parameter sent by each of the sub-nodes; A fourth sending module, configured to send the average value of the common parameter to each of the child nodes, wherein each of the child nodes is configured to solve the effective score function according to the average value of the common parameter to obtain a first updated value of the common parameter; A second solving module, configured to solve the overall replacement effective score function according to the first updated value of the common parameter sent by each of the child nodes, to obtain a second updated value of the common parameter; A fifth sending module, used for sending the second updated value of the common parameter to each of the child nodes, and each of the child nodes is used for calculating the value of the approximate Hessian matrix according to the second updated value of the common parameter; A third solving module, used for solving the approximate global Hessian matrix according to the value of the approximate Hessian matrix sent by each of the child nodes, to obtain a third updated value of the common parameter; The sixth sending module is used to send the third updated value of the common parameter to each of the child nodes, and each of the child nodes is used to update the value of the heterogeneity parameter according to the third updated value of the common parameter, and to construct a logistic regression model of the child node according to the value of the heterogeneity parameter updated by the child node and the third updated value of the common parameter.
11. An electronic device comprising a memory, a processor, and a computer program stored in the memory and executable on the processor, characterized in that: When the processor executes the computer program, the steps of the method according to any one of claims 1 to 5 or 6 to 8 are implemented.
12. A computer-readable storage medium having a computer program stored thereon, characterized in that: When the computer program is executed by a processor, the steps of the method according to any one of claims 1 to 5 or 6 to 8 are implemented.
