Method, device and server for determining feature distance
By using secret sharing protocol rules to split feature columns in data processing scenarios, it is possible to calculate the feature distance of the data object to be measured relative to the group while protecting data privacy, solving the problem of data leakage and improving data security.
Patent Information
- Application Number
- CN202111061773.7
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2021-09-10
- Publication Date
- 2024-10-29
- Estimated Expiration
- 2041-09-10
AI Technical Summary
In complex data processing scenarios, when the first data party and the second data party need to cooperate to calculate the characteristic distance of the data object to be measured relative to the group, how to do so while protecting the data privacy of both parties and avoid data leakage.
By constructing the target feature column of the target data object and splitting it into shards using protocol rules based on secret sharing, the feature distance of the target data object relative to the first object group is interactively calculated to ensure that both parties only hold the shards and not the complete data.
It realizes the cooperative calculation of feature distance on the premise of protecting the data privacy of both parties, avoids data leakage, and improves data security.
Smart Images

Figure CN113821825B_ABST
Abstract
Description
Technical Field
[0001] This specification belongs to the field of Internet technology, and in particular, relates to a method, device and server for determining a characteristic distance. Background Art
[0002] In some more complex data processing scenarios, the first data party and the second data party each hold different types of feature data of the same group of data objects. Sometimes, both parties need to cooperate to calculate the feature distance of the data object to be tested relative to the group, and in the process of cooperatively calculating the feature distance, it is required to avoid leaking the data held by one party to the other party or other third parties.
[0003] Therefore, there is an urgent need for a method that can collaboratively calculate the feature distance of the data object to be tested relative to the group while protecting the data privacy of both parties. Summary of the invention
[0004] The embodiments of this specification provide a method, device and server for determining a characteristic distance, which can cooperatively determine the characteristic distance of a target data object relative to a first object group while protecting the data privacy of both parties.
[0005] A method, device and server for determining a characteristic distance provided in the embodiments of this specification are implemented as follows:
[0006] A method for determining a feature distance is applied to a first server, comprising: constructing a first target feature column of a target data object according to a feature value of a first type of feature of a target data object and a feature mean of the first type of feature of a first object group; wherein the first object group includes a plurality of first objects; using the first target feature column of the target data object to perform a first interaction with a second server to obtain a first slice of the target feature column of the target data object; wherein the second server obtains a second slice of the target feature column of the target data object; according to a preset protocol rule, using the first slice of the target feature column of the target data object and the first slice of the inverse of the covariance matrix of the features of the first object group as input, performing a preset feature distance function operation with the second server to obtain a first slice of the feature distance of the target data object relative to the first object group; wherein the second server obtains a second slice of the feature distance, and the preset protocol rule at least includes a protocol rule based on secret sharing.
[0007] A device for determining a feature distance comprises: a construction module, for constructing a first target feature column of a target data object according to a feature value of a first type of feature of the target data object and a feature mean of the first type of feature of a first object group; wherein the first object group comprises a plurality of first objects; an interaction module, for performing a first interaction with a second server using the first target feature column of the target data object to obtain a first slice of the target feature column of the target data object; wherein the second server obtains a second slice of the target feature column of the target data object; and an operation module, for performing an operation of a preset feature distance function with the second server according to a preset protocol rule, taking the first slice of the target feature column of the target data object and the first slice of the inverse of the covariance matrix of the features of the first object group as input, to obtain a first slice of the feature distance of the target data object relative to the first object group; wherein the second server obtains a second slice of the feature distance, wherein the preset protocol rule at least comprises a protocol rule based on secret sharing.
[0008] A server comprises a processor and a memory for storing instructions executable by the processor, wherein when the processor executes the instructions, the following steps are achieved: constructing a first target feature column of a target data object according to a feature value of a first type of feature of the target data object and a feature mean of the first type of feature of a first object group; wherein the first object group includes a plurality of first objects; performing a first interaction with a second server using the first target feature column of the target data object to obtain a first slice of the target feature column of the target data object; wherein the second server obtains a second slice of the target feature column of the target data object; and performing a preset feature distance function operation with the second server according to a preset protocol rule, taking the first slice of the target feature column of the target data object and the first slice of the inverse of the covariance matrix of the features of the first object group as inputs, obtaining a first slice of the feature distance of the target data object relative to the first object group; wherein the second server obtains a second slice of the feature distance, wherein the preset protocol rule at least includes a protocol rule based on secret sharing.
[0009] A computer-readable storage medium stores computer instructions, which implement the following steps when executed: construct a first target feature column of a target data object according to a feature value of a first type of feature of the target data object and a feature mean of the first type of feature of a first object group; wherein the first object group includes a plurality of first objects; use the first target feature column of the target data object to perform a first interaction with a second server to obtain a first slice of the target feature column of the target data object; wherein the second server obtains a second slice of the target feature column of the target data object; according to a preset protocol rule, use the first slice of the target feature column of the target data object and the first slice of the inverse of the covariance matrix of the features of the first object group as input, perform a preset feature distance function operation with the second server, and obtain a first slice of the feature distance of the target data object relative to the first object group; wherein the second server obtains a second slice of the feature distance, and the preset protocol rule at least includes a protocol rule based on secret sharing.
[0010] The method, device and server for determining the characteristic distance provided by the embodiment of the present specification, when the first server and the second server holding different data need to cooperate to determine the characteristic distance of the target data object relative to the first object group, the first server can first use the characteristic value based on the first type of characteristic of the target data object held and the characteristic mean of the first type of characteristic of the first object group to construct the first target characteristic column of the target data object, and perform a first interaction with the second server holding the second target characteristic column of the target data object to obtain the first slice of the target characteristic column of the target data object; the first server then performs a preset characteristic distance function operation with the first slice of the target characteristic column of the target data object and the first slice of the inverse covariance matrix of the characteristics of the first object group held according to the preset protocol rules, and the second server holding and using the second slice of the target characteristic column of the target data object and the second slice of the inverse covariance matrix of the characteristics of the first object group to obtain the first slice of the characteristic distance of the target data object relative to the first object group, and the second server obtains the second slice of the characteristic distance. Thus, the characteristic distance of the target data object relative to the first object group can be determined cooperatively under the premise of protecting the data privacy of both parties, effectively avoiding the disclosure of the data held by the party to the other party or other third parties in the process of cooperatively determining the characteristic distance. BRIEF DESCRIPTION OF THE DRAWINGS
[0011] In order to more clearly illustrate the embodiments of this specification, the drawings required for use in the embodiments will be briefly introduced below. The drawings described below are only some embodiments recorded in this specification. For ordinary technicians in this field, other drawings can be obtained based on these drawings without paying creative work.
[0012] Figure 1It is a schematic diagram of an embodiment of the structural composition of a system applying the method for determining a characteristic distance provided in an embodiment of this specification;
[0013] Figure 2 is a schematic diagram of an embodiment of a method for determining a characteristic distance provided by an embodiment of this specification, in a scenario example;
[0014] Figure 3 is a schematic diagram of an embodiment of a method for determining a characteristic distance provided by an embodiment of this specification, in a scenario example;
[0015] Figure 4 is a flowchart of a method for determining a characteristic distance provided by an embodiment of this specification;
[0016] Figure 5 It is a schematic diagram of the structure of a server provided by an embodiment of this specification;
[0017] Figure 6 It is a schematic diagram of the structural composition of a device for determining a characteristic distance provided by an embodiment of this specification. DETAILED DESCRIPTION
[0018] In order to enable those skilled in the art to better understand the technical solutions in this specification, the technical solutions in the embodiments of this specification will be clearly and completely described below in conjunction with the drawings in the embodiments of this specification. Obviously, the described embodiments are only part of the embodiments of this specification, not all of the embodiments. Based on the embodiments in this specification, all other embodiments obtained by ordinary technicians in this field without creative work should fall within the scope of protection of this specification.
[0019] The embodiment of this specification provides a method for determining a characteristic distance, and the method for determining a characteristic distance can be specifically applied to a system including a first server and a second server. Figure 1 The first server and the second server may be connected in a wired or wireless manner to perform specific data interaction.
[0020] The first server may be specifically understood as a server deployed on the side of the first data party (e.g., a shopping website, etc.). Specifically, the first server may at least hold feature values of first-category features of multiple first objects (e.g., user objects) owned by the first data party. The first-category features may specifically include one or more first features.
[0021] For example, the above-mentioned first feature can specifically be a shopping feature of the user object; accordingly, the above-mentioned multiple first features may include: the shopping frequency of the user object, the monthly shopping consumption amount of the user object, the type of goods purchased by the user object, the brand of goods most frequently purchased by the user object, etc.
[0022] The second server can be specifically understood as a server deployed on the side of the second data party (for example, a bank, etc.). Specifically, the second server can at least hold the feature values of the second type of features of the same multiple first objects owned by the second data party. The second type of features can specifically include one or more second features.
[0023] For example, the second type of feature may specifically be an asset feature of the user object; correspondingly, the multiple second features may include: the monthly income of the user object, the mortgage record of the user object, the financial management income of the user object, and the like.
[0024] In this embodiment, the first server and the second server may specifically include a background server applied to one side of the data processing system, which can realize functions such as data transmission and data processing. Specifically, the first server and the second server may be, for example, an electronic device with data calculation, storage and network interaction functions. Alternatively, the first server and the second server may also be software programs running in the electronic device to provide support for data processing, storage and network interaction. In this embodiment, the number of servers included in the first server and the second server is not specifically limited. The first server and the second server may specifically be one server, or several servers, or a server cluster formed by several servers.
[0025] It should be noted that the feature values of the first type of features of the plurality of first objects held by the first server and the feature values of the second type of features of the plurality of first objects held by the second server are feature values of different types of features of the same batch of user objects. The group obtained by combining the plurality of first objects can be recorded as a first object group.
[0026] Before specific implementation, the first server and the second server may also first align the feature values of the first type of features and the feature values of the second type of features held by each server according to the identity identifier of the user object of the feature data. Through the above alignment process, the feature value of the first type of features of the user object ranked at the i-th position (or numbered i) in the first object group held by the first server and the feature value of the second type of features of the user object ranked at the i-th position (or numbered i) in the first object group held by the second server can correspond to the same user object.
[0027] Specifically, for example, the first server may hold the feature values of the first type of features of W user objects, and the first type of features specifically includes m different first features. For the feature value of the first type of features of any user object numbered i among the W user objects, the following vector representation may be used: (x i,1 ,x i,2 ,x i,3 ,...,x i,m ). Among them, x i,m It represents the feature value of the first feature numbered m in the first category of features of the user object numbered i, where m is an integer greater than or equal to 1, and i is an integer greater than or equal to 1 and less than or equal to W.
[0028] Similarly, the second server may hold the feature values of the second features of the same batch of W user objects, and the second features may specifically include n different second features. The feature value of the second feature of any user object numbered i among the W user objects may be represented by the following vector: (y i,1 ,y i,2 ,y i,3 ,...,y i,n ). Among them, y i,n It represents the feature value of the second feature numbered n in the second category feature of the user object numbered i, where n is an integer greater than or equal to 1, and i is an integer greater than or equal to 1 and less than or equal to W.
[0029] Among them, the eigenvalue of the first type of feature (x i,1 ,x i,2 ,x i,3 ,...,x i,m ) and the eigenvalue of the second type of feature (y i,1 ,y i,2 ,y i,3 ,...,y i,n ) Feature values of different types of features belonging to the same user object.
[0030] It should also be noted that the multiple user objects included in the above-mentioned first object group may be user objects that carry the same type label (eg, risk label) and belong to the same first type (eg, risky users).
[0031] In this embodiment, before specific implementation, refer to Figure 2As shown, the first server can first use the feature values of the first category of features of the user objects it holds according to the preset protocol rules to perform a second interaction with the second server that holds the feature values of the second category of features of the user objects, so as to obtain a first slice of the covariance matrix of the features of the first object group (a share of the covariance matrix) under the premise of protecting data privacy; wherein the second server can obtain a second slice of the covariance matrix of the features of the first object group (another share of the covariance matrix).
[0032] The above-mentioned preset protocol rules at least include protocol rules based on secret sharing.
[0033] The above-mentioned oblivious transfer (OT) can specifically refer to a communication protocol that can protect the data privacy of both parties. Based on this protocol, the two communicating parties cannot know the specific data input by the other party, so that the two communicating parties can transmit data information in a selectively obfuscated manner.
[0034] The above-mentioned secret sharing (SS) is also called secret sharing, which can specifically refer to a multi-party security protocol. Based on secret sharing, the secret can be split in an appropriate way, and each share after the split (referred to as a share) can be held and managed by different participants. A single participant cannot recover the secret information based on a single share, and only several participants can work together to recover the secret message.
[0035] By interacting through the above-mentioned preset protocol rules, the first server and the second server can safely complete various related function operations and data interactions without knowing the specific data used by the other party, thereby protecting the data security of the participants.
[0036] Specifically, first, the first server can locally calculate the variance of each first feature in the first category features of the first object group (which can be recorded as the variance of the first category features), the covariance between different first features in the first category features (which can be recorded as the covariance between the first category features), and the feature mean of each first feature in the first category features (which can be recorded as the feature mean of the first category features, for example, u) based on the feature values of the first category features of multiple first objects included in the first object group.
[0037] Next, the first server may construct an initial first-category feature column of the first object group according to the feature values of the first-category features of the plurality of first objects.
[0038] For example, for the first feature numbered t in the first category of features, the following feature column can be constructed: [x 1,t ,x 2,t ,...,xi,t ,...,x W,t According to the above method, m feature columns corresponding to the m first features can be constructed as the initial first category feature columns of the first object group.
[0039] Then, the first server may subtract the corresponding feature mean from each feature value in the above initial first-category feature column to obtain the required first-category feature column of the first object group.
[0040] For example, for the first feature numbered t in the first category of features, the corresponding feature mean is u t ; The feature column [x 1,t ,x 2,t ,...,x i,t ,...,x W,t Each eigenvalue contained in ] is subtracted from u t , and get the processed feature column: [x 1,t -u t ,x 2,t -u t ,...,x i,t -u t ,...,x W,t -u t ]=[x 1,t ',x 2,t ',...,x i,t ',...,x W,t '], which can be abbreviated as a t According to the above method, m processed feature sequences corresponding to the m first features can be constructed as the first type feature sequences of the first object group.
[0041] Similarly, the second server may first calculate locally the variance of the second-category features of the first objects, the covariance between the second-category features, and the feature mean of the second-category features based on the feature values of the second-category features of multiple first objects; and then construct the second-category feature column of the first object group based on the feature values of the second-category features of multiple first objects and the feature mean of the second-category features of the first object group.
[0042] Furthermore, the first server may use the first type of feature column of the first object group and cooperate with the second server using the second type of feature column of the first object to calculate a first slice of the covariance between the first type of feature and the second type of feature; wherein the second server obtains a second slice of the covariance between the first type of feature and the second type of feature.
[0043] Specifically, it is taken as an example that the first server and the second server cooperate to calculate the covariance between any first feature numbered p in the first category of features and any second feature numbered q in the second category of features.
[0044] The first server or the second server may initiate a first joint operation request for calculating the covariance.
[0045] The first server may respond to the first joint operation request by sending the feature column a corresponding to the first feature numbered p in the first type of feature column p =[x 1,p ',x 2,p ',...,x i,p ',...,x W,p '] as input, and the feature column b corresponding to the second feature numbered q in the second category feature column q =[y 1,q ',y 2,q ',...,y i,q ',...,y W,q '] The second server as input jointly performs the first function operation (which can be recorded as cov(a p ,b q )) to obtain a first slice of the covariance between a first feature numbered p and a second feature numbered q, and the second server obtains a second slice of the covariance.
[0046] Among them, the above-mentioned joint first function operation can specifically be based on a secure multi-party computing (MPC) protocol to perform the first function operation to ensure that the first server and the second server participating in the calculation only know the data input by themselves and the data obtained by themselves, but cannot know the data input by the other party and the data obtained by the other party, thereby effectively protecting the data security of both parties participating in the calculation.
[0047] The first function may specifically include a covariance calculation function modified based on the secure multi-party computing protocol. When calculating the first function, the feature column a may be firstly p and b q The eigenvalues at the same position in are multiplied to obtain W products; the cumulative sum of the W products is divided by (W-1) to obtain the covariance between the first feature numbered p and the second feature numbered q; the covariance is then split into two components, and the first component is output to the first server, and the second component is output to the second server.
[0048] Through the above manner, the first server and the second server can cooperate multiple times to calculate the covariance between each first feature in the first category of features and each second feature in the second category of features; and the first server can obtain the first slice of the covariance between each first feature in the first category of features and each second feature in the second category of features as the first slice of the covariance between the first category of features and the second category of features; at the same time, the second server can obtain the second slice of the covariance between each first feature in the first category of features and each second feature in the second category of features as the second slice of the covariance between the first category of features and the second category of features.
[0049] Then, the first server can use the first slice of the variance of the first type of features, the covariance between the first type of features, and the covariance between the first type of features and the second type of features to interact with the second slice of the variance of the second type of features, the covariance between the second type of features, and the covariance between the first type of features and the second type of features to combine a complete covariance matrix, that is, the covariance matrix C of the features of the first object group. In addition, the first service can obtain and hold the first slice of the covariance matrix; at the same time, the second server can obtain and hold the second slice of the covariance matrix.
[0050] The covariance matrix of the features of the first object group can effectively and comprehensively reflect the cluster features of the plurality of first objects in the first object group based on the dimension of statistical distribution.
[0051] It should be noted that the covariance matrix of the above features includes both the relevant information of the first type of features held by the first server and the relevant information of the second type of features held by the second server.
[0052] In order to prevent either the first server or the second server from inferring the relevant data held by the other party based on the covariance matrix, the complete covariance matrix will not be provided to either party. Instead, the covariance matrix is split into a first slice and a second slice, and the first server and the second server respectively hold and keep a slice of the covariance matrix. This ensures that neither party holds the complete covariance matrix. In addition, when the two parties need to use the covariance matrix for cooperation, they can input the slices of the covariance matrix held by each party to obtain and use the complete covariance matrix.
[0053] In this embodiment, in order to facilitate the subsequent use of the covariance matrix for specific data processing more efficiently under the premise of protecting data privacy, the first server can also use the first slice of the covariance matrix of the features of the first object group to perform a third interaction with the second server using the second slice of the covariance matrix of the features of the first object, and perform an inverse operation on the covariance matrix under the premise of protecting data privacy. In addition, the first server can obtain and store the first slice of the inverse of the covariance matrix of the features of the first object group; at the same time, the second server can obtain and store the second slice of the inverse of the covariance matrix of the features of the first object group. In this way, the first server and the second server can directly use the inverse slice of the above-mentioned covariance matrix to cooperate in data processing, reducing the processing volume of subsequent data processing.
[0054] Through the above process, before specific implementation, the first server and the second server can respectively use the feature values of different features of the first object they hold, and cooperate to obtain and respectively keep a slice of the covariance matrix of the features of the first object group while protecting the data privacy of both parties.
[0055] Currently, the first server wants to detect whether a newly registered target user object (or target data object) is a risky user. The first server holds the feature value of the first type of feature of the target user object, and the second server holds the feature value of the second type of feature of the target user object.
[0056] In specific implementation, first, the first server may initiate a detection request for a target user object, wherein the detection request at least carries an identity identifier of the target user object to be detected.
[0057] See also Figure 3 As shown, the first server can respond to the detection request and construct a first target feature sequence of the target user object according to the feature value of the first type of feature of the target user object held and the feature mean of the first type of feature of the first object group.
[0058] Specifically, the first server may first construct an initial first target feature column of the target user object according to the feature value of the first type of feature of the target user object: h k =[x k,1 ,x k,2 ,x k,3 ,...,x k,m ]. The subscript k can be understood as the number or identity of the target user object.
[0059] Then, the feature values of each first feature in the above initial first target feature column are subtracted from the corresponding feature mean to obtain the first target feature column of the target user object: h k '=[xk,1 -u1,x k,2 -u2,...,x k,m -u m ]=[x k,1 ',x k,2 ',x k,3 ',...,x k,m ']. Among them, u m It is the feature mean of the first feature numbered m among the feature means of the first category of features.
[0060] Similarly, the second server can respond to the detection request and construct a second target feature column of the target user object locally based on the feature value of the second feature of the target user object held and the feature mean of the second feature of the first object group, which can be recorded as: k '=[y k,1 ',y k,2 ',y k,3 ',...,y k,n '].
[0061] Then, the first server can use the first target feature column of the target user object to perform a first interaction with the second server using the second target feature column of the target user object, so as to obtain a complete target feature column of the target user object under the premise of protecting the data privacy of both parties, which can be expressed as c k =[x k,1 ',x k,2 ',x k,3 ',...,x k,m ',y k,1 ',y k,2 ',y k,3 ',...,y k,n ']; and, the first server only obtains and holds the first slice of the target feature column of the target user object; meanwhile, the second server only obtains and holds the second slice of the target feature column of the target user object.
[0062] In this way, neither the first server nor the second server holds a complete target feature list of the target user object, thereby avoiding leaking the features of the target user object held by the first server and the second server to the other party.
[0063] Furthermore, the above-mentioned preset protocol rules may also include protocol rules based on multi-party secure computing. The first server may, according to the preset protocol rules, take the first slice of the target feature column of the target data object held and the first slice of the inverse covariance matrix of the features of the first object group as input, and cooperate with the second server taking the second slice of the target feature column of the target data object held and the second slice of the inverse covariance matrix of the features of the first object group as input to perform operations on the preset feature distance function to calculate the feature distance of the target user object relative to the first object group; and the first server obtains the first slice of the feature distance; at the same time, the second server obtains the second slice of the feature distance.
[0064] The characteristic distance may be specifically the Mahalanobis distance, which is a statistically based distance that can represent the difference between a point and a distribution.
[0065] It should be noted that in this embodiment, the Mahalanobis distance is selected instead of the Euclidean distance (or Euclidean distance) as the feature distance for measuring the difference between the target user object and the first object group as a whole. This is because the use of the Euclidean distance does not distinguish between different feature dimensions, which will inevitably ignore certain feature statistical information. The use of the Mahalanobis distance can make full use of the above feature statistical information, and then based on the dimension of statistical distribution, it can more accurately reflect the difference in features between the target user object and the first object group as a whole, improve the accuracy of detection, and reduce detection errors.
[0066] When the characteristic distance is the Mahalanobis distance, the above preset characteristic distance function can be expressed as follows:
[0067] (c k ).T*inv(C)*(c k )
[0068] Among them, c k represents the target feature column of the target user object, C represents the covariance matrix of the features of the first object group, (c k ).T represents the transpose of the target feature column of the target user object, and inv(C) represents the inverse of the covariance matrix of the features of the first object group.
[0069] Specifically, the first server can, according to the preset protocol rules, take the first slice of the target feature column of the target data object and the first slice of the inverse of the covariance matrix of the features of the first object group as input, and cooperate with the second server to solve the above-mentioned preset feature distance function through secure multi-party computing to obtain the first slice of the feature distance.
[0070] Finally, the first server may initiate a comparison request.
[0071] The first server responds to the comparison request, takes the first slice of the feature distance as input, and cooperates with the second server taking the second slice of the feature distance as input to perform a preset comparison function operation to obtain a corresponding comparison result.
[0072] The preset comparison function is used to restore the characteristic distance according to the first slice and the second slice of the input characteristic distance; and compare the characteristic distance with the preset distance threshold value to obtain and output the corresponding comparison result.
[0073] Correspondingly, the first server can obtain and determine whether the characteristic distance is less than a preset distance threshold based on the comparison result. In the case where it is determined that the characteristic distance is less than the preset distance threshold, it can be determined that the target user object and the first object in the first object group belong to the same type. Therefore, it can be determined that the type of the target user object is a risky user. Then, a risk label can be set for the target user object, and / or the target user object can be subjected to risk tracking and monitoring. On the contrary, in the case where it is determined that the characteristic distance is greater than or equal to the preset distance threshold, it can be determined that the target user object and the first object in the first object group belong to different types. Therefore, it can be determined that the type of the target user object is a normal user.
[0074] Through the above embodiments, based on the method provided in the embodiments of this specification, the first server and the second server can cooperate to calculate and obtain different slices of the characteristic distance of the target user object relative to the first object group without leaking the data held by each party to the other party; and using the different slices of the characteristic distance held by each party, they can further cooperate to determine the specific type of the target user object without leaking the data held by each party to the other party.
[0075] See also Figure 4 As shown, the embodiment of this specification provides a method for determining a characteristic distance, wherein the method is specifically applied to the first server side. When implemented specifically, the method may include the following contents:
[0076] S401: constructing a first target feature column of the target data object according to a feature value of a first feature of the target data object and a feature mean of the first feature of the first object group; wherein the first object group includes a plurality of first objects;
[0077] S402: Performing a first interaction with a second server using a first target feature column of a target data object to obtain a first shard of the target feature column of the target data object; wherein the second server obtains a second shard of the target feature column of the target data object;
[0078] S403: According to the preset protocol rules, taking the first slice of the target feature column of the target data object and the first slice of the inverse of the covariance matrix of the features of the first object group as input, the preset feature distance function is operated with the second server to obtain the first slice of the feature distance of the target data object relative to the first object group; wherein the second server obtains the second slice of the feature distance, and the preset protocol rules at least include protocol rules based on secret sharing.
[0079] In some embodiments, the first server may be a server deployed on the first data party. The first server may hold the feature values of the first type of features of the first objects included in the first object group and the feature values of the first type of features of the target data objects.
[0080] The second server may be a server deployed on the second data entity. The second server may hold the feature values of the second features of the first objects included in the first object group and the feature values of the second features of the target data objects.
[0081] The first object group may specifically include a plurality of first objects. The target data object may specifically be a data object in the first object group, or may be any data object outside the first object group.
[0082] The first type of features may specifically include one or more different first features. The second type of features may specifically include one or more different second features.
[0083] In some embodiments, the multiple first objects included in the first object group may be data objects of the same type (referred to as the first type).
[0084] In some embodiments, the target data object may be a target user object to be detected for risk. Accordingly, the first type may include risky users. The first objects included in the first object group may be sample user objects that are known to be risky and belong to risky users.
[0085] Of course, the target data objects and the first type listed above are only schematic illustrations. In specific implementation, the target data objects may also include other types of data objects according to specific application scenarios and processing requirements. For example, in the enterprise operation supervision scenario, the target data object may also be a target enterprise object whose operation status is to be detected. Accordingly, the first type may also include normal operating enterprises, etc.
[0086] In some embodiments, before specific implementation, the first server may first use the feature values of the first category of features held by the first object group according to preset protocol rules, and cooperate with the second server using the feature values of the second category of features to calculate a first slice of the inverse covariance matrix of the features of the first object group; wherein the second server obtains a second slice of the inverse covariance matrix of the features of the first object group.
[0087] The covariance matrix of the features of the first object group can effectively and comprehensively reflect the cluster features of the plurality of first objects in the first object group based on the dimension of statistical distribution.
[0088] The above-mentioned preset protocol rules at least include protocol rules based on secret sharing. Furthermore, the above-mentioned preset protocol rules may also include protocol rules based on inadvertent transmission. Interaction based on the above-mentioned preset protocol rules can enable the first server and the second server to safely complete related function operations and data interactions without knowing the specific data used by the other party, thereby protecting the data security of the participants. In addition, for specific application scenarios, the above-mentioned preset protocol rules may also include protocol rules based on multi-party secure computing.
[0089] In some embodiments, the above-mentioned construction of the first target feature column of the target data object based on the feature value of the first category feature of the target data object and the feature mean of the first category feature of the first object group may include the following contents during specific implementation: the first server arranges the feature value of the first category feature of the target data object according to a preset feature sorting to obtain an initial first target feature column of the target data object; and then subtracts the corresponding feature mean in the feature mean of the first category feature of the first object group from each feature value in the initial first target feature column to obtain the first target feature column of the target data object.
[0090] Similarly, the second server may construct and obtain a second target feature column of the target data object.
[0091] In some embodiments, the first server may, according to preset protocol rules, use the first target feature column of the target data object to perform a first interaction with the second server using the second target feature column of the target data object, and combine to obtain a complete target feature column of the target data object; and the first server may obtain a first fragment of the target feature column; at the same time, the second server may obtain a second fragment of the target feature column.
[0092] In some embodiments, the first server may use the first slice of the target feature column of the target data object and the first slice of the inverse covariance matrix of the features of the first object group as input according to a preset protocol rule, and cooperate with the second server using the second slice of the target feature column of the target data object and the second slice of the inverse covariance matrix of the features of the first object group as input to perform operations on a preset feature distance function to calculate the feature distance of the target data object relative to the first object group; and the first server may obtain the first slice of the feature distance; at the same time, the second server may obtain the second slice of the feature distance.
[0093] In some embodiments, the characteristic distance may specifically include Mahalanobis distance, etc. Of course, in specific implementation, other suitable types of distances may be used as characteristic distances for measuring the difference between the target data object and the first object group as a whole, according to specific application scenarios and processing requirements.
[0094] In some embodiments, after obtaining the first slice of the characteristic distance of the target data object relative to the first object group, the method may also include the following contents when it is specifically implemented: the first server responds to the comparison request, takes the first slice of the characteristic distance as input, and cooperates with the second server which takes the second slice of the characteristic distance as input to perform a preset comparison function operation to obtain a comparison result; based on the comparison result, determines whether the characteristic distance is less than a preset distance threshold; when it is determined that the characteristic distance is less than the preset distance threshold, it can be determined that the type of the target data object is the first type.
[0095] In some embodiments, when it is determined that the characteristic distance is greater than or equal to a preset distance threshold, it can be determined that the type of the target data object is not the first type. The preset distance threshold can be obtained in advance based on historical sample data statistics.
[0096] In some embodiments, before constructing a first target feature column of the target data object based on the feature value of the first category of features of the target data object and the feature mean of the first category of features of the first object group, the method may also include the following contents when implemented: the first server uses the feature values of the first category of features of multiple first objects to perform a second interaction with the second server to obtain a first slice of the covariance matrix of the features of the first object group; wherein the second server obtains a second slice of the covariance matrix of the features of the first object group; the first server uses the first slice of the covariance matrix of the features of the first object group to perform a third interaction with the second server to obtain a first slice of the inverse of the covariance matrix of the features of the first object group; wherein the second server obtains a second slice of the inverse of the covariance matrix of the features of the first object group.
[0097] In some embodiments, the above-mentioned second interaction with the second server using the feature value of the first category feature of the first object may include the following contents during specific implementation: the first server calculates the variance of the first category feature, the covariance between the first category features, and the feature mean of the first category feature of the first object group according to the feature values of the first category features of multiple first objects; the first server constructs the first category feature column of the first object group according to the feature values of the first category features of multiple first objects and the feature mean of the first category features of the first object group; the first server uses the first category feature column of the first object group to cooperate with the second server using the second category feature column of the first object to calculate the first slice of the covariance between the first category feature and the second category feature; wherein the second server obtains the second slice of the covariance between the first category feature and the second category feature; the first server uses the variance of the first category feature, the covariance between the first category features, and the first slice of the covariance between the first category feature and the second category feature to interact with the second server to obtain the first slice of the covariance matrix; wherein the second server obtains the second slice of the covariance matrix.
[0098] In some embodiments, the first type of features may specifically include multiple first features; correspondingly, the first type of feature columns may specifically include multiple first feature columns, wherein each first feature column corresponds to one first feature.
[0099] Similarly, the second type of features may specifically include multiple second features; correspondingly, the second type of feature columns may specifically include multiple second feature columns, wherein each second feature column corresponds to one second feature.
[0100] In some embodiments, the above-mentioned use of the first type of feature column of the first object group cooperates with the second server using the second type of feature column of the first object to calculate the first slice of the covariance between the first type of feature and the second type of feature. When implemented specifically, it may include the following contents: the first server respectively uses multiple first feature columns of the first object, and cooperates with the second server using the second type of feature column of the first object to calculate the first slice of the covariance between multiple first features in the first type of feature and the second type of feature, as the first slice of the covariance between the first type of feature and the second type of feature.
[0101] The covariance between the first category features and the second category features may specifically include the covariance between each first feature in the first category features and each second feature in the second category features.
[0102] In some embodiments, the above-mentioned construction of the first category feature column of the first object group based on the feature values of the first category features of multiple first objects and the feature mean of the first category features of the first object group may include the following contents during specific implementation: the first server constructs an initial first category feature column of the first object group based on the feature values of the first category features of multiple first objects; and subtracts the feature mean of the first category features of the first object group from each feature value in the initial first category feature column of the first object group to obtain the first category feature column of the first object group.
[0103] In some embodiments, the first type feature column of the first object group may specifically include multiple first feature columns corresponding to multiple first features. Taking the construction of any current first feature column of the multiple first feature columns as an example, the first server may extract the feature values of the current first features of each first object from the feature values of the first type features of the first object held; then, according to the sorting of the object identifiers of the first objects pre-aligned with the second server, the feature values of the current first features of the multiple first objects are arranged to obtain the current initial first feature column; further, each feature value in the current initial first feature column is subtracted from the feature mean of the first type features of the first object group to obtain the current first feature column.
[0104] According to the above method, the first server can construct multiple first feature columns locally as the first type of feature columns of the first object group. Similarly, the second server can construct multiple second feature columns locally as the second type of feature columns of the first object group.
[0105] As can be seen from the above, based on the method for determining the characteristic distance provided in the embodiment of this specification, when both parties need to cooperate to determine the characteristic distance of the target data object relative to the first object group, the first server first uses the first target characteristic column of the target data object constructed based on the characteristic value of the first type of characteristic of the target data object held and the characteristic mean of the first type of characteristic of the first object group, and performs a first interaction with the second server to obtain different slices of the target characteristic column of the target data object; the first server then performs a preset characteristic distance function operation with the second server according to the preset protocol rules, using the first slice of the target characteristic column of the target data object and the first slice of the inverse of the covariance matrix of the characteristics of the first object group, to obtain different slices of the characteristic distance of the target data object relative to the first object group. Thus, the characteristic distance of the target data object relative to the first object group can be determined cooperatively under the premise of protecting the data privacy of both parties; it can also be further accurately determined through cooperation based on the above characteristic distance, under the premise of protecting the data privacy of both parties, whether the target data object is of the same type as the first object in the first object group, and whether it belongs to the first type.
[0106] The embodiment of the present specification also provides a server, including a processor and a memory for storing processor executable instructions, wherein the processor can perform the following steps according to the instructions when implemented: construct a first target feature column of the target data object according to the feature value of the first category of features of the target data object and the feature mean of the first category of features of the first object group; wherein the first object group includes multiple first objects; use the first target feature column of the target data object to perform a first interaction with a second server to obtain a first slice of the target feature column of the target data object; wherein the second server obtains a second slice of the target feature column of the target data object; according to a preset protocol rule, use the first slice of the target feature column of the target data object and the first slice of the inverse covariance matrix of the features of the first object group as input, perform a preset feature distance function operation with the second server, and obtain a first slice of the feature distance of the target data object relative to the first object group; wherein the second server obtains the second slice of the feature distance, and the preset protocol rule at least includes a protocol rule based on secret sharing.
[0107] In order to complete the above instructions more accurately, refer to Figure 5 As shown, the embodiment of this specification also provides another specific server, wherein the server includes a network communication port 501, a processor 502 and a memory 503, and the above structures are connected through internal cables so that each structure can perform specific data interaction.
[0108] The network communication port 501 may be used to initiate a collaborative processing request to the second server.
[0109] The processor 502 can be specifically used to respond to the collaborative processing request, construct a first target feature column of the target data object according to the feature value of the first category of features of the target data object and the feature mean of the first category of features of the first object group; wherein the first object group includes multiple first objects; use the first target feature column of the target data object to perform a first interaction with the second server to obtain a first slice of the target feature column of the target data object; wherein the second server obtains a second slice of the target feature column of the target data object; according to a preset protocol rule, use the first slice of the target feature column of the target data object and the first slice of the inverse covariance matrix of the features of the first object group as input, perform a preset feature distance function operation with the second server, and obtain a first slice of the feature distance of the target data object relative to the first object group; wherein the second server obtains the second slice of the feature distance, and the preset protocol rule at least includes a protocol rule based on secret sharing.
[0110] The memory 503 may be specifically used to store corresponding instruction programs.
[0111] In this embodiment, the network communication port 501 can be a virtual port that is bound to different communication protocols so that different data can be sent or received. For example, the network communication port can be a port responsible for web data communication, a port responsible for FTP data communication, or a port responsible for email data communication. In addition, the network communication port can also be a physical communication interface or communication chip. For example, it can be a wireless mobile network communication chip, such as GSM, CDMA, etc.; it can also be a Wifi chip; it can also be a Bluetooth chip.
[0112] In this embodiment, the processor 502 may be implemented in any appropriate manner. For example, the processor may take the form of a microprocessor or processor and a computer-readable medium storing a computer-readable program code (such as software or firmware) executable by the (micro)processor, a logic gate, a switch, an application specific integrated circuit (ASIC), a programmable logic controller, and an embedded microcontroller, etc. This specification does not limit this.
[0113] In this embodiment, the memory 503 may include multiple levels. In a digital system, anything that can store binary data can be a memory; in an integrated circuit, a circuit with a storage function but no physical form is also called a memory, such as RAM, FIFO, etc.; in a system, a storage device with a physical form is also called a memory, such as a memory stick, TF card, etc.
[0114] The embodiment of the present specification also provides a computer-readable storage medium based on the above-mentioned feature distance determination method, the computer-readable storage medium stores computer program instructions, and when the computer program instructions are executed, the following are achieved: constructing a first target feature column of the target data object according to the feature value of the first category of features of the target data object and the feature mean of the first category of features of the first object group; wherein the first object group includes multiple first objects; using the first target feature column of the target data object to perform a first interaction with a second server to obtain a first slice of the target feature column of the target data object; wherein the second server obtains a second slice of the target feature column of the target data object; according to a preset protocol rule, using the first slice of the target feature column of the target data object and the first slice of the inverse of the covariance matrix of the features of the first object group as input, performing a preset feature distance function operation with the second server to obtain a first slice of the feature distance of the target data object relative to the first object group; wherein the second server obtains the second slice of the feature distance, and the preset protocol rule at least includes a protocol rule based on secret sharing.
[0115] In this embodiment, the storage medium includes, but is not limited to, a random access memory (RAM), a read-only memory (ROM), a cache, a hard disk (HDD), or a memory card. The memory may be used to store computer program instructions. The network communication unit may be an interface for network connection communication set in accordance with the standard specified by the communication protocol.
[0116] In this embodiment, the functions and effects specifically implemented by the program instructions stored in the computer-readable storage medium can be explained in comparison with other implementations and will not be described in detail here.
[0117] See also Figure 6 As shown, at the software level, the embodiment of this specification also provides a device for determining a characteristic distance, which may specifically include the following structural modules:
[0118] The construction module 601 may be specifically used to construct a first target feature column of the target data object according to a feature value of a first feature of the target data object and a feature mean of the first feature of the first object group; wherein the first object group includes a plurality of first objects;
[0119] The interaction module 602 may be specifically configured to use the first target feature column of the target data object to perform a first interaction with the second server to obtain a first fragment of the target feature column of the target data object; wherein the second server obtains a second fragment of the target feature column of the target data object;
[0120] The operation module 603 can be specifically used to perform a preset feature distance function operation with the second server according to a preset protocol rule, with the first slice of the target feature column of the target data object and the first slice of the inverse of the covariance matrix of the features of the first object group as input, to obtain the first slice of the feature distance of the target data object relative to the first object group; wherein the second server obtains the second slice of the feature distance, and the preset protocol rule at least includes a protocol rule based on secret sharing.
[0121] In some embodiments, the characteristic distance may specifically include Mahalanobis distance, etc.
[0122] In some embodiments, the type of the first objects included in the first object group may specifically be a first type.
[0123] In some embodiments, the first type of features may specifically include multiple first features; correspondingly, the first type of feature columns may include multiple first feature columns.
[0124] In some embodiments, the preset protocol rules may specifically include protocol rules based on oblivious transmission.
[0125] In some embodiments, the target data object may specifically include a target user object to be detected for risk, and the first type includes risky users, and the like.
[0126] In some embodiments, the device may also specifically include a comparison module, which may be specifically used to respond to a comparison request, take a first slice of the feature distance as input, and cooperate with a second server taking a second slice of the feature distance as input to perform a preset comparison function operation to obtain a comparison result; based on the comparison result, determine whether the feature distance is less than a preset distance threshold; when it is determined that the feature distance is less than the preset distance threshold, determine that the type of the target data object is the first type.
[0127] In some embodiments, the device also includes a preprocessing module, wherein the preprocessing module is specifically used to perform a second interaction with a second server using the eigenvalues of the first category of features of multiple first objects to obtain a first slice of the covariance matrix of the features of the first object group before constructing the first target feature column of the target data object based on the eigenvalues of the first category of features of the target data object and the feature mean of the first category of features of the first object group; wherein the second server obtains the second slice of the covariance matrix of the features of the first object group; and perform a third interaction with the second server using the first slice of the covariance matrix of the features of the first object group to obtain a first slice of the inverse of the covariance matrix of the features of the first object group; wherein the second server obtains the second slice of the inverse of the covariance matrix of the features of the first object group.
[0128] In some embodiments, when the above-mentioned preprocessing module is specifically implemented, it can be executed according to the following procedure to perform a second interaction to obtain a first slice of the covariance matrix: according to the eigenvalues of the first-class features of multiple first objects, the variance of the first-class features, the covariance between the first-class features, and the feature mean of the first-class features of the first object group are calculated; according to the eigenvalues of the first-class features of multiple first objects and the feature mean of the first-class features of the first object group, a first-class feature column of the first object group is constructed; using the first-class feature column of the first object group, in cooperation with a second server using the second-class feature column of the first object, a first slice of the covariance between the first-class features and the second-class features is calculated; wherein the second server obtains a second slice of the covariance between the first-class features and the second-class features; using the variance of the first-class features, the covariance between the first-class features, and the first slice of the covariance between the first-class features and the second-class features, interact with the second server to obtain a first slice of the covariance matrix; wherein the second server obtains a second slice of the covariance matrix, and the preset protocol rules at least include protocol rules based on secret sharing.
[0129] It should be noted that the units, devices or modules described in the above embodiments can be implemented by computer chips or entities, or by products with certain functions. For the convenience of description, the above devices are described separately by functions divided into various modules. Of course, when implementing this specification, the functions of each module can be implemented in the same or more software and / or hardware, or the modules that implement the same function can be implemented by a combination of multiple sub-modules or sub-units. The device embodiments described above are only schematic. For example, the division of the units is only a logical function division. There may be other division methods in actual implementation, such as multiple units or components can be combined or integrated into another system, or some features can be ignored or not executed. Another point is that the mutual coupling or direct coupling or communication connection shown or discussed can be through some interfaces, indirect coupling or communication connection of devices or units, which can be electrical, mechanical or other forms.
[0130] As can be seen from the above, based on the characteristic distance determination device provided in the embodiment of this specification, it is possible to cooperatively determine the characteristic distance of the target data object relative to the first object group under the premise of protecting the data privacy of both parties; further, it is possible to cooperatively determine whether the target data object is of the same type as the first object included in the first object group, and whether it is of the first type, under the premise of protecting the data privacy of both parties.
[0131] Although the present specification provides method operation steps as described in the embodiments or flow charts, more or less operation steps may be included based on conventional or non-creative means. The order of steps listed in the embodiments is only one way of executing the order of many steps, and does not represent a unique execution order. When the device or client product in practice is executed, it can be executed in sequence or in parallel according to the method shown in the embodiments or the drawings (for example, a parallel processor or a multi-threaded processing environment, or even a distributed data processing environment). The term "include", "include" or any other variant thereof is intended to cover non-exclusive inclusion, so that the process, method, product or device including a series of elements includes not only those elements, but also includes other elements that are not explicitly listed, or also includes elements inherent to such a process, method, product or device. In the absence of more restrictions, it is not excluded that there are other identical or equivalent elements in the process, method, product or device including the elements. The first, second, etc. words are used to represent the name, and do not represent any particular order.
[0132] Those skilled in the art also know that, in addition to implementing the controller in a purely computer-readable program code, the controller can be made to implement the same function in the form of logic gates, switches, application-specific integrated circuits, programmable logic controllers, and embedded microcontrollers by logically programming the method steps. Therefore, such a controller can be considered as a hardware component, and the devices for implementing various functions included therein can also be considered as structures within the hardware component. Or even, the devices for implementing various functions can be considered as both software modules for implementing the method and structures within the hardware component.
[0133] This specification may be described in the general context of computer-executable instructions executed by a computer, such as program modules. Generally, program modules include routines, programs, objects, components, data structures, classes, etc. that perform specific tasks or implement specific abstract data types. This specification may also be practiced in distributed computing environments where tasks are performed by remote processing devices connected through a communication network. In a distributed computing environment, program modules may be located in local and remote computer-readable storage media including storage devices.
[0134] Through the description of the above embodiments, it can be known that those skilled in the art can clearly understand that the present specification can be implemented by means of software plus a necessary general hardware platform. Based on such an understanding, the technical solution of the present specification can essentially be embodied in the form of a software product, which can be stored in a storage medium such as ROM / RAM, a disk, an optical disk, etc., and includes a number of instructions for enabling a computer device (which can be a personal computer, a mobile terminal, a server, or a network device, etc.) to execute the methods described in each embodiment of the present specification or some parts of the embodiments.
[0135] The various embodiments in this specification are described in a progressive manner, and the same or similar parts between the various embodiments can be referred to each other, and each embodiment focuses on the differences from other embodiments. This specification can be used in many general or special computer system environments or configurations. For example: personal computers, server computers, handheld devices or portable devices, tablet devices, multi-processor systems, microprocessor-based systems, set-top boxes, programmable electronic devices, network PCs, minicomputers, mainframe computers, distributed computing environments including any of the above systems or devices, etc.
[0136] Although the present specification is described through embodiments, those skilled in the art will appreciate that there are many modifications and changes to the present specification without departing from the spirit of the present specification, and it is intended that the appended claims include these modifications and changes without departing from the spirit of the present specification.
Claims
1. A method for determining a feature distance, applied to a first server, comprising: Constructing a first target feature column of the target data object according to a feature value of a first type of feature of the target data object and a feature mean of the first type of feature of the first object group; wherein the first object group includes a plurality of first objects; Using the first target feature column of the target data object to perform a first interaction with the second server, obtaining a first shard of the target feature column of the target data object; wherein the second server obtains a second shard of the target feature column of the target data object; According to a preset protocol rule, a first slice of a target feature column of a target data object and a first slice of an inverse covariance matrix of features of a first object group are used as inputs, and a preset feature distance function is calculated with a second server to obtain a first slice of a feature distance of the target data object relative to the first object group; wherein the second server obtains a second slice of the feature distance, and the preset protocol rule at least includes a protocol rule based on secret sharing; The first target feature column of the target data object is used to perform a first interaction with the second server to obtain a first shard of the target feature column of the target data object, including: using the first target feature column of the target user object, performing a first interaction with the second server using the second target feature column of the target user object, so as to obtain a complete target feature column of the target user object under the premise of protecting the data privacy of both parties; and the first server obtains and holds the first shard of the target feature column of the target user object, and the second server obtains and holds the second shard of the target feature column of the target user object; Among them, the preset protocol rules also include protocol rules based on multi-party secure computing; correspondingly, the method also includes: according to the preset protocol rules, taking the first slice of the target feature column of the target data object held and the first slice of the inverse covariance matrix of the features of the first object group as input, cooperating with the second server taking the second slice of the target feature column of the target data object held and the second slice of the inverse covariance matrix of the features of the first object group as input, performing the operation of the preset feature distance function to calculate the feature distance of the target user object relative to the first object group; and the first server obtains the first slice of the feature distance, and the second server obtains the second slice of the feature distance. The method according to claim 1 , wherein the characteristic distance comprises a Mahalanobis distance. 3 . The method according to claim 1 , wherein the type of the first objects included in the first object group is a first type.
4. The method according to claim 3, after obtaining the first segment of the characteristic distance of the target data object relative to the first object group, the method further comprises: In response to the comparison request, taking the first slice of the characteristic distance as input, cooperating with the second server taking the second slice of the characteristic distance as input to perform a preset comparison function operation to obtain a comparison result; According to the comparison result, determining whether the characteristic distance is less than a preset distance threshold; When it is determined that the characteristic distance is less than a preset distance threshold, the type of the target data object is determined to be the first type.
5. The method according to claim 1, before constructing a first target feature column of the target data object according to the feature value of the first type of feature of the target data object and the feature mean of the first type of feature of the first object group, the method further comprises: Using the feature values of the first type of features of the plurality of first objects to perform a second interaction with the second server to obtain a first slice of the covariance matrix of the features of the first object group; wherein the second server obtains a second slice of the covariance matrix of the features of the first object group; A third interaction is performed with the second server using the first slice of the covariance matrix of the features of the first object group to obtain the first slice of the inverse of the covariance matrix of the features of the first object group; wherein the second server obtains the second slice of the inverse of the covariance matrix of the features of the first object group.
6. The method according to claim 5, using the feature value of the first type of feature of the first object to perform a second interaction with the second server, comprises: Calculate the variance of the first-category features, the covariance between the first-category features, and the feature mean of the first-category features of the first object group according to the feature values of the first-category features of the plurality of first objects; Constructing a first-category feature column for the first object group according to feature values of the first-category features of the plurality of first objects and feature means of the first-category features of the first object group; Using the first type of feature column of the first object group, in cooperation with the second server using the second type of feature column of the first object, a first slice of the covariance between the first type of feature and the second type of feature is calculated; wherein the second server obtains a second slice of the covariance between the first type of feature and the second type of feature; Using the variance of the first category of features, the covariance between the first category of features, and the first slice of the covariance between the first category of features and the second category of features, interact with the second server to obtain a first slice of the covariance matrix; wherein the second server obtains a second slice of the covariance matrix.
7. The method according to claim 6, wherein the first type of features includes a plurality of first features; Correspondingly, the first type of feature columns includes multiple first feature columns.
8. The method according to claim 7, using the first type feature column of the first object group, cooperating with the second server using the second type feature column of the first object, to calculate the first slice of the covariance between the first type feature and the second type feature, comprising: Using multiple first feature columns of the first object respectively, in cooperation with a second server using the second feature column of the first object, a first slice of the covariance between multiple first features in the first category of features and the second category of features is calculated as the first slice of the covariance between the first category of features and the second category of features.
9. The method according to claim 6, constructing a first-category feature sequence of the first object group according to feature values of the first-category features of the plurality of first objects and feature means of the first-category features of the first object group, comprising: constructing an initial first-category feature sequence of a first object group according to feature values of first-category features of a plurality of first objects; The feature mean of the first category features of the first object group is subtracted from each feature value in the initial first category feature column of the first object group to obtain the first category feature column of the first object group.
10. The method according to claim 1, wherein the preset protocol rules further include protocol rules based on oblivious transmission.
11. The method according to claim 3, wherein the target data object comprises a target user object to be detected for risk, and the first type comprises risky users.
12. A device for determining a characteristic distance, comprising: A construction module, used to construct a first target feature column of the target data object according to a feature value of a first type of feature of the target data object and a feature mean of the first type of feature of the first object group; wherein the first object group includes a plurality of first objects; An interaction module, configured to use a first target feature column of a target data object to perform a first interaction with a second server to obtain a first slice of the target feature column of the target data object; wherein the second server obtains a second slice of the target feature column of the target data object; The operation module is used to perform a preset feature distance function operation with the second server according to a preset protocol rule, taking the first slice of the target feature column of the target data object and the first slice of the inverse covariance matrix of the features of the first object group as input, to obtain the first slice of the feature distance of the target data object relative to the first object group; wherein the second server obtains the second slice of the feature distance, and the preset protocol rule at least includes a protocol rule based on secret sharing; The interaction module is specifically used to use the first target feature column of the target user object to perform a first interaction with the second server using the second target feature column of the target user object, so as to obtain a complete target feature column of the target user object under the premise of protecting the data privacy of both parties; and the first server obtains and holds a first slice of the target feature column of the target user object, and the second server obtains and holds a second slice of the target feature column of the target user object; Among them, the preset protocol rules also include protocol rules based on multi-party secure computing; accordingly, the operation module is specifically used to cooperate with the second server that uses the second slice of the target feature column of the target data object held and the second slice of the inverse covariance matrix of the features of the first object group as input, according to the preset protocol rules, to perform the operation of the preset feature distance function to calculate the feature distance of the target user object relative to the first object group; and the first server obtains the first slice of the feature distance, and the second server obtains the second slice of the feature distance.
13. A server, comprising a processor and a memory for storing processor-executable instructions, wherein the processor implements the steps of the method according to any one of claims 1 to 11 when executing the instructions.
14. A computer-readable storage medium having computer instructions stored thereon, wherein the instructions, when executed, implement the steps of the method according to any one of claims 1 to 11.
Citation Information
Patent Citations
Method and device for clustering private data of multiple parties
CN111444544A
Collaborative computing method and system for protecting data privacy of two parties
CN111475854A
Method and device for clustering private data of multiple parties
CN111523143A
Method and device for jointly determining object feature correlation in private data by multiple parties
CN112818290A
Data processing method and device based on privacy protection and server
CN113094739A
