Data processing method and device of data sandbox, storage medium and electronic equipment
By acquiring indexes and merging data in a data sandbox, and performing grouping and regrouping processes, the problems of data security risks and resource waste in the data sandbox are solved, and real-time data updates and enhanced security are achieved.
Patent Information
- Application Number
- CN202311668835.X
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2023-12-06
- Publication Date
- 2026-11-24
- Estimated Expiration
- 2043-12-06
AI Technical Summary
Data sets in data sandboxes face significant security risks, potentially leading to data leaks and resource waste. This is especially true in big data scenarios, where intruders can infer entity information by combining multiple data sets.
By obtaining the index of the data, the data space of the data sandbox is retrieved, and the first data is merged into the existing data. Grouping and regrouping are then performed to limit the amount of data under a certain index and prevent information speculation.
It enables real-time updates and enhanced security within the data sandbox, prevents data leaks, reduces resource waste, and makes information inference more difficult by limiting the amount of data under a certain index.
Smart Images

Figure CN117874038B_ABST
Abstract
Description
Technical Field
[0001] This disclosure relates to the field of data processing technology, and more specifically, to a data processing method, apparatus, storage medium, and electronic device for a data sandbox. Background Technology
[0002] A data sandbox is a technology that separates data ownership and usage rights by creating completely isolated debugging and runtime environments, thereby ensuring data security. Generally, data sandboxes may store rich datasets. In relevant scenarios, these datasets still face significant security risks, potentially leading to data breaches and substantial losses. Summary of the Invention
[0003] The purpose of this disclosure is to provide a method, apparatus, storage medium, and electronic device for processing data in a data sandbox, in order to solve the aforementioned related technical problems.
[0004] To achieve the above objectives, in a first aspect, this disclosure provides a method for processing data from a data sandbox, comprising:
[0005] Get the first dataset to be added to the data sandbox;
[0006] For the first data in the first dataset, obtain the index of the first data to get the first index;
[0007] Based on the first index, retrieve the data space of the data sandbox;
[0008] If second data with the first index is retrieved from the data space, the first data is merged into the second data;
[0009] The merged second data is saved to the data space.
[0010] Optionally, saving the merged second data to the data space includes:
[0011] Determine the target group to which the second data belongs in the data space;
[0012] Obtain the data of the target group in the data space;
[0013] The data in the target group is taken as the target dataset, and the target dataset is further grouped to obtain multiple sub-datasets;
[0014] The multiple sets of sub-data sets are saved to the data space.
[0015] Optionally, obtaining the index of the first data in the first dataset to obtain the first index includes:
[0016] Obtain the index of the first dataset to get the second index;
[0017] Retrieve the data space of the data sandbox according to the second index;
[0018] If a dataset with the second index is retrieved, the index of the first data in the first dataset is obtained to obtain the first index;
[0019] The method further includes:
[0020] If no dataset with the second index is found, the first dataset is used as the target dataset, and the target dataset is regrouped to obtain multiple sub-datasets;
[0021] The multiple sets of sub-data sets are saved to the data space.
[0022] Optionally, the regrouping of the target dataset to obtain multiple sub-datasets includes:
[0023] Based on the quasi-identifier attributes of the data in the target dataset, the target dataset is regrouped to obtain multiple candidate datasets;
[0024] For each group of candidate datasets, calculate the total number of feature attributes of the data in that group of candidate datasets;
[0025] If the total number of the aforementioned feature attributes is greater than or equal to a first threshold, the candidate dataset is treated as a subset of the dataset.
[0026] Optionally, calculating the total number of feature attributes of the data in each group of candidate datasets includes:
[0027] Sort the candidate datasets in each group;
[0028] Based on the ranking, for each group of candidate datasets, calculate the total number of feature attributes of the data in that group of candidate datasets;
[0029] The method further includes:
[0030] If the total number of the feature attributes is less than the first threshold, the candidate dataset is fused with the target candidate dataset to obtain a new candidate dataset. Each candidate dataset includes the new candidate dataset, and the target candidate dataset is the next candidate dataset in the sorting.
[0031] Optionally, the step of fusing the candidate dataset with the target candidate dataset includes:
[0032] Identify the target numerical data from this set of candidate datasets;
[0033] For the current target numerical data, calculate the displacement value required to add the target numerical data to the target candidate dataset;
[0034] For the current target numerical data, calculate the gain value generated by the target candidate dataset after adding the target numerical data to the target candidate dataset;
[0035] If the displacement value is less than the displacement threshold and the gain value is greater than the gain threshold, the current target value data is added to the target candidate dataset.
[0036] If the displacement value is greater than or equal to the displacement threshold, and / or the gain value is less than or equal to the gain threshold, the target numerical data bar is re-determined from the candidate dataset.
[0037] Optionally, saving the multiple sets of subsets of data into the data space includes:
[0038] For each subset of datasets, determine the set of feature attributes for that subset of datasets;
[0039] If the set of feature attributes is a closed set, the subset of data is saved to the data space;
[0040] If the set of feature attributes is not a closed set, the data in the subset of data is split.
[0041] The segmented subset of data is saved to the data space.
[0042] Optionally, the data in this subset of data may be split, including:
[0043] Each piece of data in this subset of data is taken as the third data, and the third data includes the first set of feature attributes;
[0044] If the first set of feature attributes does not include a non-empty proper subset that is a closed set, the first set of feature attributes is split into multiple single-valued subsets;
[0045] Based on each single-value subset, the third data is divided into fourth data whose feature attributes are respectively those of the single-value subsets;
[0046] If the first set of feature attributes includes a non-empty proper subset and the non-empty proper subset is a closed set, the first set of feature attributes is split into a non-empty closed subset and a first subset.
[0047] The third data is divided into a fifth data set whose feature attribute is the non-empty closed subset, and a sixth data set whose feature attribute is the first subset;
[0048] Assign index numbers to the fourth, fifth, and sixth data, wherein the segmented subset includes one or more of the fourth, fifth, and sixth data with the index numbers.
[0049] Optionally, obtaining the first dataset to be added to the data sandbox includes:
[0050] Get the second dataset to be added to the data sandbox;
[0051] Obtain the feature attributes of the data in the second dataset and the quasi-identifier attributes of the data to obtain a feature set;
[0052] Obtain the remaining attributes of the data after removing the feature attribute and the quasi-identifier attribute, to obtain a candidate attribute set;
[0053] For each candidate attribute in the current candidate attribute set, calculate the mutual information between the candidate attribute and the current feature set;
[0054] Identify the target candidate attribute with the highest mutual information value;
[0055] If the mutual information number of the target candidate attribute is greater than or equal to the second threshold, the target candidate attribute is added to the feature set and the target candidate attribute is deleted from the candidate attribute set.
[0056] If the candidate attribute set is empty, the first dataset, which includes the current feature attribute set, is generated based on the second dataset.
[0057] Secondly, a data processing device for a data sandbox is provided, comprising:
[0058] The first acquisition module is used to acquire the first dataset to be added to the data sandbox;
[0059] The second acquisition module is used to obtain the index of the first data in the first dataset to obtain the first index.
[0060] The retrieval module is used to retrieve the data space of the data sandbox based on the first index;
[0061] A first execution module is configured to merge the first data into the second data when second data with the first index is retrieved from the data space;
[0062] The first storage module is used to save the merged second data into the data space.
[0063] Optionally, the first storage module includes:
[0064] The first determining submodule is used to determine the target group to which the second data belongs in the data space;
[0065] The first acquisition submodule is used to acquire the data of the target group in the data space;
[0066] The first grouping submodule is used to take the data of the target group as the target dataset, and further group the target dataset to obtain multiple sub-datasets;
[0067] The first storage submodule is used to save the multiple sets of sub-data sets into the data space.
[0068] Optionally, the second acquisition module includes:
[0069] The second acquisition submodule is used to acquire the index of the first dataset to obtain the second index;
[0070] The first retrieval submodule is used to retrieve the data space of the data sandbox according to the second index;
[0071] The third acquisition submodule is used to, when a dataset with the second index is retrieved, acquire the index of the first data in the first dataset to obtain the first index;
[0072] The device further includes:
[0073] The second execution module is used to, when no dataset with the second index is found, take the first dataset as the target dataset, and regroup the target dataset to obtain multiple sub-datasets;
[0074] The second storage module is used to save the multiple sets of sub-data sets into the data space.
[0075] Optionally, the first grouping submodule and / or the second execution module may further group the target dataset using the following modules to obtain multiple sub-datasets:
[0076] The third execution module is used to regroup the target dataset based on the quasi-identifier attributes of the data in the target dataset to obtain multiple candidate datasets;
[0077] The fourth execution module is used to calculate the total number of feature attributes of the data in each candidate dataset.
[0078] The fifth execution module is used to treat the candidate dataset as a subset if the total number of the feature attributes is greater than or equal to the first threshold.
[0079] Optionally, the fourth execution module includes:
[0080] The sorting submodule allows users to sort the candidate datasets in each group.
[0081] The first calculation submodule is used to calculate the total number of feature attributes of the data in each group of candidate datasets based on the sorting.
[0082] The device further includes:
[0083] The sixth execution module is used to merge the group of candidate datasets with the target candidate dataset when the total number of the feature attributes is less than the first threshold, to obtain a new candidate dataset. Each group of candidate datasets includes the new candidate dataset, and the target candidate dataset is the next group of candidate datasets in the sorting.
[0084] Optionally, the sixth execution module includes:
[0085] The first execution submodule is used to determine the target numerical data from the set of candidate datasets;
[0086] The second execution submodule is used to calculate the displacement value required to add the target value bar data to the target candidate dataset for the current target value bar data;
[0087] The third execution submodule is used to calculate the gain value generated by the target candidate dataset after adding the target value data to the target candidate dataset;
[0088] The fourth execution submodule is used to add the current target value data to the target candidate dataset when the displacement value is less than the displacement threshold and the gain value is greater than the gain threshold.
[0089] The fifth execution submodule is used to re-determine the target numerical data from the candidate dataset when the displacement value is greater than or equal to the displacement threshold and / or the gain value is less than or equal to the gain threshold.
[0090] Optionally, the first storage submodule and / or the second storage module are used to save the multiple sets of sub-data sets to the data space through the following modules:
[0091] The sixth execution submodule is used to determine the set of feature attributes for each sub-dataset.
[0092] The seventh execution submodule is used to save the set of subsets of data into the data space when the set of feature attributes is a closed set;
[0093] The eighth execution submodule is used to segment the data in the subset of data when the set of feature attributes is not a closed set;
[0094] The ninth execution submodule is used to save the segmented subset of data into the data space.
[0095] Optionally, the eighth execution submodule includes:
[0096] The first execution subunit is used to treat each piece of data in the group of subsets as third data, wherein the third data includes a first set of feature attributes;
[0097] The second execution subunit is used to split the first feature attribute set into multiple single-value subsets when the first feature attribute set does not include a non-empty proper subset that is a closed set.
[0098] The third execution subunit is used to divide the third data into fourth data whose feature attributes are respectively the single-value subsets based on each single-value subset;
[0099] The fourth execution subunit is configured to split the first feature attribute set into a non-empty closed subset and a first subset when the first feature attribute set includes a non-empty proper subset and the non-empty proper subset is a closed set.
[0100] The fifth execution subunit is used to divide the third data into fifth data, which includes the non-empty closed subset as a feature attribute, and sixth data, which includes the first subset as a feature attribute.
[0101] The sixth execution subunit is used to assign index numbers to the fourth data, the fifth data, and the sixth data, wherein the segmented group of sub-data sets includes one or more of the fourth data, the fifth data, and the sixth data with the index numbers.
[0102] Optionally, the first acquisition module includes:
[0103] The first submodule is used to obtain the second dataset to be added to the data sandbox;
[0104] The second submodule is used to obtain the feature attributes of the data in the second dataset and the quasi-identifier attributes of the data to obtain a feature set;
[0105] The third submodule is used to obtain the other attributes of the data after removing the feature attribute and the quasi-identifier attribute, and to obtain a candidate attribute set.
[0106] The fourth submodule is used to calculate the mutual information between each candidate attribute in the current candidate attribute set and the current feature set.
[0107] The fifth submodule is used to determine the target candidate attribute with the largest mutual information number;
[0108] The sixth submodule is used to add the target candidate attribute to the feature set and delete the target candidate attribute from the candidate attribute set when the mutual information number of the target candidate attribute is greater than or equal to the second threshold.
[0109] The seventh submodule is used to generate the first dataset, which includes the current set of feature attributes, based on the second dataset when the candidate attribute set is empty.
[0110] Thirdly, a non-transitory computer-readable storage medium is provided, on which a computer program is stored, which, when executed by a processor, implements the steps of the method described in any one of the first aspects.
[0111] Fourthly, an electronic device is provided, comprising:
[0112] A memory on which computer programs are stored;
[0113] A processor for executing the computer program in the memory to implement the steps of the method of any one of the first aspects.
[0114] Using the above scheme, for the first data to be added to the data sandbox, existing data in the data space of the data sandbox can be retrieved based on the first index of the first data. If there is already second data with the first index in the data space, the first data is merged into the second data, and the merged second data is stored in the data space.
[0115] This allows for real-time updates to the data in the data sandbox. Furthermore, unlike directly saving new data to the data sandbox, the above approach integrates new data into existing data. Thus, writing new data does not increase the number of records under a particular index; the number of records under a specific index in the data sandbox can be limited during data writing, such as controlling that an index contains only one record. This makes it more difficult to infer information about an entity from multiple records under a particular index, thereby improving the security of the data in the data sandbox.
[0116] Other features and advantages of this disclosure will be described in detail in the following detailed description section. Attached Figure Description
[0117] The accompanying drawings are provided to further illustrate the present disclosure and form part of the specification. They are used together with the following detailed description to explain the present disclosure, but do not constitute a limitation thereof. In the drawings:
[0118] Figure 1 This is a flowchart illustrating a data processing method for a data sandbox according to an exemplary embodiment of this disclosure.
[0119] Figure 2 This is a flowchart illustrating a data processing method as shown in an exemplary embodiment of this disclosure.
[0120] Figure 3 This is a flowchart illustrating the data processing of a data sandbox according to an exemplary embodiment of this disclosure.
[0121] Figure 4 This is a flowchart illustrating a data merging process as shown in an exemplary embodiment of this disclosure.
[0122] Figure 5 This is a flowchart illustrating a target dataset grouping as shown in an exemplary embodiment of this disclosure.
[0123] Figure 6 This is a flowchart illustrating a data storage method as shown in an exemplary embodiment of this disclosure.
[0124] Figure 7 This is a block diagram of a data processing apparatus for a data sandbox, as shown in an exemplary embodiment of this disclosure.
[0125] Figure 8 This is a block diagram of an electronic device shown in an exemplary embodiment of the present disclosure. Detailed Implementation
[0126] The specific embodiments of this disclosure will be described in detail below with reference to the accompanying drawings. It should be understood that the specific embodiments described herein are for illustration and explanation only and are not intended to limit this disclosure.
[0127] Before introducing the data processing method, apparatus, storage medium, and electronic device of the data sandbox in the embodiments of this disclosure, the application scenarios of the embodiments of this disclosure will be introduced first.
[0128] A data sandbox is a technology that separates data ownership and usage rights by creating completely isolated debugging and runtime environments, thereby ensuring data security. Generally, a data sandbox may store a wealth of datasets. These datasets can be protected through data anonymization, encryption, and other methods. However, in some scenarios, the data still faces the risk of leakage.
[0129] Taking data anonymization as an example, privacy leaks can still occur even after removing directly identifiable elements from the data. For instance, data users can perform joint analysis of one or more non-sensitive attributes (such as gender, age, phone number, etc.) from the dataset with external data sources to uncover hidden sensitive information. In some scenarios, data users may infer sensitive information (such as someone's preferences) based on their background knowledge.
[0130] Furthermore, as new data is generated, the risk of data breaches may also increase. For example, for an entity within a data sandbox, new data generated by that entity can also be written into the data sandbox. Thus, even if the data in the sandbox can hide relevant sensitive attributes, as the number of data entries for that entity in the sandbox continues to increase, an intruder can combine multiple data entries to deduce the entity's information, ultimately leading to data leakage. In addition, in big data scenarios, the entity may also generate duplicate data; writing duplicate data into the data sandbox could result in significant resource waste.
[0131] Therefore, this disclosure provides a method for processing data from a data sandbox. Figure 1 This is a flowchart illustrating a data processing method for a data sandbox according to an exemplary embodiment of this disclosure, such as... Figure 1 As shown, the method includes:
[0132] In step S11, the first dataset to be added to the data sandbox is obtained.
[0133] In one possible implementation, the input dataset can be processed as the first dataset.
[0134] In one possible implementation, the input dataset can also be processed, and the processed dataset can be used as the first dataset.
[0135] For example, in one possible implementation, obtaining the first dataset to be added to the data sandbox includes:
[0136] Get the second dataset to be added to the data sandbox;
[0137] Obtain the feature attributes of the data in the second dataset and the quasi-identifier attributes of the data to obtain a feature set;
[0138] Obtain the remaining attributes of the data after removing the feature attribute and the quasi-identifier attribute, to obtain a candidate attribute set;
[0139] For each candidate attribute in the current candidate attribute set, calculate the mutual information between the candidate attribute and the current feature set;
[0140] Identify the target candidate attribute with the highest mutual information value;
[0141] If the mutual information number of the target candidate attribute is greater than or equal to the second threshold, the target candidate attribute is added to the feature set and the target candidate attribute is deleted from the candidate attribute set.
[0142] If the candidate attribute set is empty, the first dataset, which includes the current feature attribute set, is generated based on the second dataset.
[0143] Figure 2 This is a flowchart illustrating a data processing method according to an exemplary embodiment of this disclosure, with reference to... Figure 2 It can obtain a second dataset to be added to the data sandbox, and obtain the feature attributes of the data in the second dataset and the quasi-identifiers (QIs) of the data to obtain the feature set.
[0144] Specifically, based on preset configurations or user-selected attributes, it can determine which attributes in the second dataset are feature attributes and which are quasi-identifier attributes. For example, feature attributes can refer to relevant sensitive attributes, such as an entity's name or unique identifier. Quasi-identifier attributes can refer to data attributes that, when combined with other information, can identify an entity, such as a user's occupation or age.
[0145] In this way, the feature attributes and quasi-identifier attributes of the data in the second dataset can be obtained, thus forming a feature set. Furthermore, the remaining attributes of the data after removing the feature attributes and quasi-identifier attributes can be obtained, resulting in a candidate attribute set (shown in the diagram as the other attribute set).
[0146] For example, the feature set can be denoted as F, and the candidate attribute set can be denoted as B. Mutual information can be calculated for sets F and B. For instance, the mutual information between each candidate attribute in the current candidate attribute set B and the current feature set can be calculated.
[0147] Candidate attribute b in set B i ′ For example, b can be calculated. i ′ Mutual information number I(b) with c i ′ ,c).
[0148] I(b i ′,c)=(|b i |×|c|) vt .
[0149] Where vt is the user-set calculation threshold, and c is the feature information extracted from feature set F. By calculating the mutual information between each candidate attribute in B and c, the target candidate attribute with the largest mutual information can be determined. If the mutual information of the target candidate attribute is greater than or equal to a second threshold, the target candidate attribute can be added to a pre-generated result set (initially an empty set). Then, the feature set F can be updated using the result set, and the target candidate attribute can be deleted from the candidate attribute set B. In some embodiments, the result set can also be used to count the number of features in the updated feature set.
[0150] If the mutual information number of the target candidate attribute is less than the second threshold, the target candidate attribute can be deleted from the candidate attribute set B.
[0151] In this way, the feature set F and the candidate attribute set B can be updated. It should be understood that after updating the feature set F and the candidate attribute set B, the steps of "for each candidate attribute in the current candidate attribute set, calculate the mutual information between the candidate attribute and the current feature set; determine the target candidate attribute with the largest mutual information; if the mutual information of the target candidate attribute is greater than or equal to the second threshold, add the target candidate attribute to the feature set and delete the target candidate attribute from the candidate attribute set" can be repeated until the candidate attribute set is empty.
[0152] If the candidate attribute set is empty, the first dataset, which includes the current feature attribute set, is generated based on the second dataset.
[0153] By employing the above scheme, attributes related to the "feature attribute" can be filtered from the "candidate attribute set" by calculating the mutual information number and added to the "feature set." This prevents intruders from inferring the content of the feature attribute through seemingly unimportant attributes. Furthermore, the above scheme can remove attributes with low relevance to the "feature attribute," thus reducing the resource overhead of subsequent processing, thereby reducing data complexity and improving data processing efficiency.
[0154] Reference Figure 1 In step S12, the index of the first data in the first dataset is obtained to get the first index.
[0155] For example, in one implementation, the user identifier of the first data can be read and used as the first index.
[0156] In one implementation, each piece of data in the first dataset is considered as a first piece of data. Step S12 can be performed for each piece of first data in the first dataset.
[0157] In one implementation, obtaining the index of the first data in the first dataset to obtain the first index includes:
[0158] Obtain the index of the first dataset to get the second index;
[0159] Retrieve the data space of the data sandbox according to the second index;
[0160] If a dataset with the second index is retrieved, the index of the first data in the first dataset is obtained to obtain the first index.
[0161] For example, Figure 3 This is a flowchart illustrating the data processing of a data sandbox according to an exemplary embodiment of this disclosure, with reference to... Figure 3 During the data and parameter input phase, the first dataset can be used as input. This allows us to determine whether the first dataset is a new dataset.
[0162] For example, the second index of the first dataset can be used to determine whether it is a new dataset. The dataset index can be the type of dataset, such as medical data, shopping data, etc. In implementation, the data space can first be searched based on the second index of the first dataset to determine whether data of the type belonging to the first dataset already exists in the data space. If no dataset with the second index is found, it can be determined that data of the type belonging to the first dataset does not exist in the data space, and at this time, the first dataset can be determined as a new dataset. Therefore, the first dataset can be used as a new dataset, and the new dataset can be processed by merging, grouping, splitting, generalizing, etc., before being written into the data space.
[0163] Furthermore, if data of the type belonging to the first dataset already exists in the data space, i.e., a dataset with the second index is retrieved, it can be determined that the first dataset is not a new dataset. Therefore, the first dataset can be appended to the dataset with the second index in the data space. For example, the index of the first data can be obtained to obtain a first index, and data can be appended one by one based on the first index, thereby merging the first dataset into the existing data in the data space.
[0164] Reference Figure 1 In step S13, the data space of the data sandbox is retrieved according to the first index.
[0165] For example, the first index may be an entity name. In step S13, the entity name may be retrieved in the data space to determine whether the entity's data already exists in the data space.
[0166] In step S14, if second data with a first index is retrieved from the data space, the first data is merged into the second data.
[0167] Figure 4 This is a flowchart illustrating a data merging process as shown in an exemplary embodiment of this disclosure, with reference to... Figure 4 For the first data in the first dataset, the data space can be searched based on the first index of the first data to determine whether there is an index in the data space that is the same as the first index. If a second data with the first index is found, the first data is merged into the second data. After merging, the merged first data can be deleted from the first dataset.
[0168] In addition, such as Figure 4 As shown, merging can also be performed within the first dataset. For example, it is possible to detect whether multiple pieces of first data within the first dataset have the same index, and to merge multiple pieces of first data with the same index.
[0169] The following provides an example of how data merging can be done.
[0170] In one implementation, the first data and the second data are formatted as follows:
[0171] <index,QI1,QI 2. ...,QI m ,{S1,S2,...,S t}>
[0172] Where index represents the index; QI m Represents the m-th quasi-identifier attribute; {S1,S2,S3,...,S... t Let S represent the set of feature attributes (including t types of feature attributes).
[0173] Thus, if the first dataset is Table 1, and the retrieved second dataset is as shown in Table 2, then they can be merged to obtain Table 3:
[0174] index QI1 QI2 QI3 ... S 1 M 43 XX {S11,S12,S13} 2 M 23 YY {S21} 3 W 15 ZZ {S31,S32}
[0175] Table 1
[0176] index QI1 QI2 QI3 ... S 1 M 43 XX {S14,S15} 2 M 23 YY {S21}
[0177] Table 2
[0178] index QI1 QI2 QI3 ... S 1 M 43 XX {S11,S12,S13,S14,S15} 2 M 23 YY {S21} 3 W 15 ZZ {S31,S32}
[0179] Table 3
[0180] In step S15, the merged second data is saved to the data space.
[0181] For example, in one implementation, saving the merged second data to the data space includes:
[0182] Determine the target group to which the second data belongs in the data space;
[0183] Obtain the data of the target group in the data space;
[0184] The data in the target group is taken as the target dataset, and the target dataset is further grouped to obtain multiple sub-datasets;
[0185] The multiple sets of sub-data sets are saved to the data space.
[0186] In the data space, data can be stored in groups. A group of data may include data with multiple indexes. It should be noted that after merging the first data into the second data, the second data may no longer meet the requirements of the original grouping. For example, the age attribute of the second data is 20, and the age of its group is [20, 25]. Thus, if the age attribute of the first data is 26, the age attribute of the merged second data will be [20, 26], which does not conform to the age [20, 25] of the original group. Therefore, the data of the target group in the data space can be obtained; the data of the target group can be used as the target dataset, and the target dataset can be regrouped to obtain multiple sub-datasets; the multiple sub-datasets can be stored in the data space. The regrouping method will be described in subsequent embodiments.
[0187] In some implementations, the first dataset can be a new dataset. In this case, the first dataset can be used as the target dataset, and the target dataset can be regrouped to obtain multiple sub-datasets; the multiple sub-datasets are then saved to the data space.
[0188] Using the above scheme, for the first data to be added to the data sandbox, existing data in the data space of the data sandbox can be retrieved based on the first index of the first data. If the second data with the first index already exists in the data space, the first data is merged into the second data, and the merged second data is stored in the data space.
[0189] This allows for real-time updates to the data in the data sandbox. Furthermore, unlike directly saving new data to the data sandbox, the above approach integrates new data into existing data. Thus, writing new data does not increase the number of records under a particular index; the number of records under a specific index in the data sandbox can be limited during data writing, such as controlling that an index contains only one record. This makes it more difficult to infer information about an entity from multiple records under a particular index, thereby improving the security of the data in the data sandbox.
[0190] The following provides an exemplary description of how to regroup the target dataset.
[0191] In one possible implementation, the target dataset is regrouped to obtain multiple sub-datasets, including:
[0192] Based on the quasi-identifier attributes of the data in the target dataset, the target dataset is regrouped to obtain multiple candidate datasets. For example, the target dataset can be grouped based on quasi-identifier attributes such as age, gender, and occupation. For instance, age can be divided into multiple intervals, with each interval forming a group. Similarly, gender can be divided into multiple categories, with each category forming a group.
[0193] For example, given the quasi-identifier attributes age [10, 20] and gender {male, female}, when dividing the attribute, since age is a numerical range attribute, the median of the range, 15, can be used as the dividing point to divide the age attribute into [10, 15] and [16, 20]. Similarly, the gender attribute can be divided into {male} and {female}.
[0194] Figure 5 This is a flowchart illustrating a target dataset grouping as shown in an exemplary embodiment of this disclosure, with reference to... Figure 5 In some implementations, the grouping process of the target dataset can be performed cyclically. Taking the age attribute grouping mentioned above as an example, for the grouped [10,15], the median of the numerical range, 12 and 13, can be taken as the dividing points and divided into group [10,12] and group [13,15].
[0195] Of course, during implementation, termination conditions for grouping can be set. For example, the termination condition can be set as follows: the values of the quasi-identifier attribute of the data within each group are the same. For example, for group [10,15], if all data belonging to this group have an age attribute value of 11, then it can be determined that this group does not need to be further subdivided into [10,12] and [13,15]. If the values of the age attribute of the data belonging to this group are different, then it can be determined that this group can be further subdivided, such as further subdivided into [10,12] and [13,15]. Similarly, if the values of the quasi-identifier attribute of the data within each group are the same, then it can be determined that the target dataset has been grouped. In this way, through grouping, the target dataset can be divided into multiple candidate datasets.
[0196] After grouping, the total number of feature attributes of the data in each candidate dataset can be calculated.
[0197] For example, in one implementation, the candidate datasets can be sorted.
[0198] Based on the ranking, for each group of candidate datasets, the total number of feature attributes in the data of that group of candidate datasets is calculated. That is, the ranking can be traversed and the total number of feature attributes in each group of candidate datasets can be calculated.
[0199] For example, for the data <1, M, 43, XX, {S11, S12, S13, S14, S15}> in Table 3
[0200] Here, S represents the feature attributes, including {S11, S12, S13, S14, S15}. Therefore, the total number of feature attributes for this data is 5. This allows us to count the total number of feature attribute types within the same candidate dataset. If the total number of feature attributes is greater than or equal to a first threshold, this candidate dataset is considered a subset.
[0201] The first threshold can be set by the user based on their needs. It should be understood that when the total number of feature attributes is large, the probability that an intruder can infer that a certain feature attribute belongs to a certain entity based on this set of candidate datasets is low. For example, if the first threshold is L, the probability that an intruder can infer that a certain feature attribute belongs to a certain entity based on this set of candidate datasets is less than 1 / L.
[0202] Furthermore, if the total number of the feature attributes is less than the first threshold, the candidate dataset is fused with the target candidate dataset to obtain a new candidate dataset. Each candidate dataset includes the new candidate dataset, and the target candidate dataset is the next candidate dataset in the sorting.
[0203] If the total number of the stated feature attributes is less than the first threshold (i.e., privacy constraints are not met), the risk of this set of candidate datasets being compromised is high. Therefore, this set of candidate datasets can be fused with the target candidate dataset.
[0204] In one possible implementation, the fusion of the candidate dataset with the target candidate dataset includes:
[0205] Identify the target numerical data from this set of candidate datasets;
[0206] For the current target numerical data, calculate the displacement value required to add the target numerical data to the target candidate dataset;
[0207] For the current target numerical data, calculate the gain value generated by the target candidate dataset after adding the target numerical data to the target candidate dataset;
[0208] If the displacement value is less than the displacement threshold and the gain value is greater than the gain threshold, the current target value data is added to the target candidate dataset.
[0209] If the displacement value is greater than or equal to the displacement threshold, and / or the gain value is less than or equal to the gain threshold, the target numerical data bar is re-determined from the candidate dataset.
[0210] Combination Figure 5 To illustrate, the candidate dataset can be examined (as shown in the diagram, grouping check) to select target value data. Here, the target value can be set based on requirements. When selecting, the target value data can be selected randomly or sequentially; this embodiment does not impose any limitations on this.
[0211] For example, for group Q i+1 and Q i Q i+1 Groups have a total of Items of data, Q i Groups have a total of 1 record, which can be randomly selected in Q i+1 Selecting x data points from the group yields the target numerical data points, where
[0212] For the selected target numerical data, the displacement value required to add the target numerical data to the target candidate dataset can be calculated, as well as the gain value generated by the target candidate dataset after adding the target numerical data to the target candidate dataset.
[0213] For example, suppose Q i+1 A data item in a group To group Q i The displacement is Move to Q i After grouping, the data becomes but To Q i displacement value for:
[0214]
[0215] Where L() is the information loss degree, used to calculate For example, in When the property is a numeric type,
[0216]
[0217] [left′,right′] is Within the value range of the attribute, [left, right] is Q. i+1 Grouping is done within the range of values for the attribute.
[0218] In addition, When the attribute is a category type,
[0219]
[0220] cnt′ is The number of categories included in the attribute, cnt is Q. i+1 The number of categories included in the attribute.
[0221] Furthermore, for the current target numerical data, a gain value can be calculated for the target candidate dataset after adding the target numerical data. The gain value can be set based on requirements. In one embodiment, the gain value can be the number of data points in the target candidate dataset that do not meet privacy constraints (or the number of data points that meet privacy constraints) that are reduced after adding the target numerical data. Here, the privacy constraint can be set, for example, to a number of feature attributes that is greater than a set value.
[0222] After calculating the displacement value and the gain value, if the displacement value is less than the displacement threshold and the gain value is greater than the gain threshold, then the current target value data is added to the target candidate dataset, thereby updating the target candidate dataset.
[0223] Furthermore, if the displacement value is greater than or equal to a displacement threshold, and / or the gain value is less than or equal to a gain threshold, the target numerical data bar is re-determined from the candidate dataset. After re-selecting the target numerical data bar, the following steps can be performed again:
[0224] For the current target numerical data, calculate the displacement value required to add the target numerical data to the target candidate dataset;
[0225] For the current target numerical data, calculate the gain value generated by the target candidate dataset after adding the target numerical data to the target candidate dataset;
[0226] If the displacement value is less than the displacement threshold and the gain value is greater than the gain threshold, the current target value data is added to the target candidate dataset.
[0227] If the displacement value is greater than or equal to the displacement threshold, and / or the gain value is less than or equal to the gain threshold, the target numerical data bar is re-determined from the candidate dataset.
[0228] In some implementation scenarios, a termination condition can be set. After the termination condition is met, the candidate dataset and the target candidate dataset are merged. The termination condition could be, for example, that the number of times the target numerical data is selected reaches a threshold; or that the target numerical data is selected by traversing the candidate dataset, and none of the selected target numerical data satisfies the condition that the displacement value is less than the displacement threshold and the gain value is greater than the gain threshold.
[0229] The determined subset of data can be saved to the data space of the data sandbox. In one possible implementation, the subset can also be segmented to increase the difficulty of data inference and decryption.
[0230] For example, saving multiple sets of subsets of data into the data space includes:
[0231] For each subset of datasets, determine the set of feature attributes for that subset of datasets;
[0232] If the set of feature attributes is a closed set, the subset of data is saved to the data space;
[0233] If the set of feature attributes is not a closed set, the data in the subset of data is split.
[0234] The segmented subset of data is saved to the data space.
[0235] Figure 6 This is a flowchart illustrating a data storage method as shown in an exemplary embodiment of this disclosure, in conjunction with... Figure 6 The following explanation is provided. Each subset of data can be used as input. For each subset of input data, the set of feature attributes for that subset can be obtained. If the set of feature attributes is a closed set, the output subset is saved to the data space.
[0236] If the set of feature attributes is not a closed set, the subset can be input into a cache queue. For the subset in the cache queue, the data in the subset can be split, and the split subsets can be output and saved to the data space.
[0237] For example, in one possible implementation, the data in the subset of data is segmented, including:
[0238] Each data point in this subset is considered as third data, which includes a first set of feature attributes. If the first set of feature attributes does not include a non-empty proper subset that is a closed set, the first set of feature attributes is split into multiple single-value subsets.
[0239] For example, the third data can be represented as A+S. Here, A represents quasi-identifier attributes, indices, and other information. S is the set of first characteristic attributes of the third data. As an example, the set of first characteristic attributes is {S11, S12}, and the set of first characteristic attributes does not include non-empty proper subsets that are closed sets. Thus, the set of first characteristic attributes can be split into single-valued subsets {S11} and {S12}.
[0240] Based on each single-value subset, the third data is segmented into fourth data whose feature attributes are respectively those of the single-value subsets. Following the above example, each single-value subset can be used as a set of feature attributes, thus forming multiple fourth data sets. In the above example, the fourth data sets can be A+S11 and A+S12.
[0241] Furthermore, if the first set of feature attributes includes a non-empty proper subset, and the non-empty proper subset is a closed set, the first set of feature attributes is split into a non-empty closed subset and a first subset. The third data is then divided into fifth data, which includes the feature attribute of the non-empty closed subset, and sixth data, which includes the feature attribute of the first subset.
[0242] Continuing with the example of the third data being A+S, if S includes a non-empty proper subset T1, and the non-empty proper subset is a closed set, then S can be split into T1 and the first subset T2. In this way, A+T1 can form the fifth data; A+T2 can form the sixth data.
[0243] In addition, index numbers can be assigned to the fourth, fifth, and sixth data, wherein the segmented subset includes one or more of the fourth data, the fifth data, and the sixth data with the index number.
[0244] In other words, new indexes can be assigned to the new data obtained from the split, and thus stored in different index directories.
[0245] In one possible implementation, before assigning index numbers to the fourth, fifth, and sixth data, one or more of the fourth, fifth, and sixth data can be generalized. During generalization, for numeric attributes, the generalization can be applied to the numerical range of the attribute for the subset to which the third data belongs. For example, if the age of the fourth data is 23, and the age range of the subset to which the third data belongs is [23, 43], then the age attribute of the fourth data can be generalized to [23, 43]. Furthermore, for categorical attributes, the generalization can be applied to all categories of the attribute for the subset to which the third data belongs. For example, if the gender of the fourth data is {male}, and the gender of the subset to which the third data belongs is {male, female}, then the gender attribute of the fourth data can be generalized to {male, female}.
[0246] In the above scheme, when the set of feature attributes is not a closed set, the data in the subset is segmented. This allows a single data point to be divided into multiple data points, each with a different index. This helps to conceal feature attributes and increases the difficulty of data cracking. Furthermore, generalization operations can be combined to further increase the difficulty of data cracking, thereby improving data security.
[0247] Based on the same inventive concept, embodiments of this disclosure also provide a data processing apparatus for a data sandbox. Figure 7 This is a block diagram of a data processing apparatus for a data sandbox as shown in an embodiment of this disclosure, with reference to... Figure 7 The device includes:
[0248] The first acquisition module 701 is used to acquire the first dataset to be added to the data sandbox;
[0249] The second acquisition module 702 is used to acquire the index of the first data in the first dataset to obtain the first index.
[0250] The retrieval module 703 is used to retrieve the data space of the data sandbox according to the first index;
[0251] The first execution module 704 is configured to merge the first data into the second data when second data with the first index is retrieved from the data space;
[0252] The first storage module 705 is used to save the merged second data to the data space.
[0253] Using the above scheme, for the first data to be added to the data sandbox, existing data in the data space of the data sandbox can be retrieved based on the first index of the first data. If the second data with the first index already exists in the data space, the first data is merged into the second data, and the merged second data is stored in the data space.
[0254] This allows for real-time updates to the data in the data sandbox. Furthermore, unlike directly saving new data to the data sandbox, the above approach integrates new data into existing data. Thus, writing new data does not increase the number of records under a particular index; the number of records under a specific index in the data sandbox can be limited during data writing, such as controlling that an index contains only one record. This makes it more difficult to infer information about an entity from multiple records under a particular index, thereby improving the security of the data in the data sandbox.
[0255] Optionally, the first storage module 705 includes:
[0256] The first determining submodule is used to determine the target group to which the second data belongs in the data space;
[0257] The first acquisition submodule is used to acquire the data of the target group in the data space;
[0258] The first grouping submodule is used to take the data of the target group as the target dataset, and further group the target dataset to obtain multiple sub-datasets;
[0259] The first storage submodule is used to save the multiple sets of sub-data sets into the data space.
[0260] Optionally, the second acquisition module 702 includes:
[0261] The second acquisition submodule is used to acquire the index of the first dataset to obtain the second index;
[0262] The first retrieval submodule is used to retrieve the data space of the data sandbox according to the second index;
[0263] The third acquisition submodule is used to, when a dataset with the second index is retrieved, acquire the index of the first data in the first dataset to obtain the first index;
[0264] The device further includes:
[0265] The second execution module is used to, when no dataset with the second index is found, take the first dataset as the target dataset, and regroup the target dataset to obtain multiple sub-datasets;
[0266] The second storage module is used to save the multiple sets of sub-data sets into the data space.
[0267] Optionally, the first grouping submodule and / or the second execution module may further group the target dataset using the following modules to obtain multiple sub-datasets:
[0268] The third execution module is used to regroup the target dataset based on the quasi-identifier attributes of the data in the target dataset to obtain multiple candidate datasets;
[0269] The fourth execution module is used to calculate the total number of feature attributes of the data in each candidate dataset.
[0270] The fifth execution module is used to treat the candidate dataset as a subset if the total number of the feature attributes is greater than or equal to the first threshold.
[0271] Optionally, the fourth execution module includes:
[0272] The sorting submodule allows users to sort the candidate datasets in each group.
[0273] The first calculation submodule is used to calculate the total number of feature attributes of the data in each group of candidate datasets based on the sorting.
[0274] The device further includes:
[0275] The sixth execution module is used to merge the group of candidate datasets with the target candidate dataset when the total number of the feature attributes is less than the first threshold, to obtain a new candidate dataset. Each group of candidate datasets includes the new candidate dataset, and the target candidate dataset is the next group of candidate datasets in the sorting.
[0276] Optionally, the sixth execution module includes:
[0277] The first execution submodule is used to determine the target numerical data from the set of candidate datasets;
[0278] The second execution submodule is used to calculate the displacement value required to add the target value bar data to the target candidate dataset for the current target value bar data;
[0279] The third execution submodule is used to calculate the gain value generated by the target candidate dataset after adding the target value data to the target candidate dataset;
[0280] The fourth execution submodule is used to add the current target value data to the target candidate dataset when the displacement value is less than the displacement threshold and the gain value is greater than the gain threshold.
[0281] The fifth execution submodule is used to re-determine the target numerical data from the candidate dataset when the displacement value is greater than or equal to the displacement threshold and / or the gain value is less than or equal to the gain threshold.
[0282] Optionally, the first storage submodule and / or the second storage module are used to save the multiple sets of sub-data sets to the data space through the following modules:
[0283] The sixth execution submodule is used to determine the set of feature attributes for each sub-dataset.
[0284] The seventh execution submodule is used to save the set of subsets of data into the data space when the set of feature attributes is a closed set;
[0285] The eighth execution submodule is used to segment the data in the subset of data when the set of feature attributes is not a closed set;
[0286] The ninth execution submodule is used to save the segmented subset of data into the data space.
[0287] Optionally, the eighth execution submodule includes:
[0288] The first execution subunit is used to treat each piece of data in the group of subsets as third data, wherein the third data includes a first set of feature attributes;
[0289] The second execution subunit is used to split the first feature attribute set into multiple single-value subsets when the first feature attribute set does not include a non-empty proper subset that is a closed set.
[0290] The third execution subunit is used to divide the third data into fourth data whose feature attributes are respectively the single-value subsets based on each single-value subset;
[0291] The fourth execution subunit is configured to split the first feature attribute set into a non-empty closed subset and a first subset when the first feature attribute set includes a non-empty proper subset and the non-empty proper subset is a closed set.
[0292] The fifth execution subunit is used to divide the third data into fifth data, which includes the non-empty closed subset as a feature attribute, and sixth data, which includes the first subset as a feature attribute.
[0293] The sixth execution subunit is used to assign index numbers to the fourth data, the fifth data, and the sixth data, wherein the segmented group of sub-data sets includes one or more of the fourth data, the fifth data, and the sixth data with the index numbers.
[0294] Optionally, the first acquisition module 701 includes:
[0295] The first submodule is used to obtain the second dataset to be added to the data sandbox;
[0296] The second submodule is used to obtain the feature attributes of the data in the second dataset and the quasi-identifier attributes of the data to obtain a feature set;
[0297] The third submodule is used to obtain the other attributes of the data after removing the feature attribute and the quasi-identifier attribute, and to obtain a candidate attribute set.
[0298] The fourth submodule is used to calculate the mutual information between each candidate attribute in the current candidate attribute set and the current feature set.
[0299] The fifth submodule is used to determine the target candidate attribute with the largest mutual information number;
[0300] The sixth submodule is used to add the target candidate attribute to the feature set and delete the target candidate attribute from the candidate attribute set when the mutual information number of the target candidate attribute is greater than or equal to the second threshold.
[0301] The seventh submodule is used to generate the first dataset, which includes the current set of feature attributes, based on the second dataset when the candidate attribute set is empty.
[0302] This disclosure also provides a non-transitory computer-readable storage medium storing a computer program thereon, which, when executed by a processor, implements the steps of the data processing method for the data sandbox provided in any embodiment of this disclosure.
[0303] This disclosure provides an electronic device, including:
[0304] A memory on which computer programs are stored;
[0305] A processor is configured to execute the computer program in the memory to implement the steps of the data processing method for the data sandbox provided in any embodiment of this disclosure.
[0306] Regarding the data processing apparatus for the data sandbox in the above embodiments, the specific manner in which each module performs its operation has been described in detail in the embodiments concerning the data processing method for the data sandbox, and will not be elaborated upon here.
[0307] Figure 8 This is a block diagram illustrating an electronic device 800 according to an exemplary embodiment. For example... Figure 8 As shown, the electronic device 800 may include a processor 801 and a memory 802. The electronic device 800 may also include one or more of a multimedia component 803, an input / output (I / O) interface 804, and a communication component 805.
[0308] The processor 801 controls the overall operation of the electronic device 800 to complete all or part of the steps in the data processing method of the data sandbox described above. The memory 802 stores various types of data to support the operation of the electronic device 800. This data may include, for example, instructions for any application or method operating on the electronic device 800, and application-related data such as contact data, sent and received messages, pictures, audio, video, etc. The memory 802 can be implemented by any type of volatile or non-volatile storage device or a combination thereof, such as Static Random Access Memory (SRAM), Electrically Erasable Programmable Read-Only Memory (EEPROM), Erasable Programmable Read-Only Memory (EPROM), Programmable Read-Only Memory (PROM), Read-Only Memory (ROM), magnetic storage, flash memory, magnetic disk, or optical disk. Multimedia component 803 may include a screen and an audio component. The screen may be, for example, a touchscreen, and the audio component is used to output and / or input audio signals. For example, the audio component may include a microphone for receiving external audio signals. The received audio signals may be further stored in memory 802 or transmitted via communication component 805. The audio component also includes at least one speaker for outputting audio signals. I / O interface 804 provides an interface between processor 801 and other interface modules, such as a keyboard, mouse, buttons, etc. These buttons may be virtual or physical buttons. Communication component 805 is used for wired or wireless communication between the electronic device 800 and other devices. Wireless communication, such as Wi-Fi, Bluetooth, Near Field Communication (NFC), 2G, 3G, 4G, NB-IoT, eMTC, or other 5G technologies, or combinations thereof, is not limited here. Therefore, the corresponding communication component 805 may include: a Wi-Fi module, a Bluetooth module, an NFC module, etc.
[0309] In an exemplary embodiment, the electronic device 800 may be implemented by one or more application-specific integrated circuits (ASICs), digital signal processors (DSPs), digital signal processing devices (DSPDs), programmable logic devices (PLDs), field-programmable gate arrays (FPGAs), controllers, microcontrollers, microprocessors, or other electronic components to perform the data processing method of the data sandbox described above.
[0310] In another exemplary embodiment, a computer-readable storage medium including program instructions is also provided, which, when executed by a processor, implement the steps of the data processing method for the data sandbox described above. For example, the computer-readable storage medium may be the memory 802 including the program instructions described above, which may be executed by the processor 801 of the electronic device 800 to complete the data processing method for the data sandbox described above.
[0311] In another exemplary embodiment, a computer program product is also provided, the computer program product comprising a computer program executable by a programmable device, the computer program having a code portion for performing the data processing method of the data sandbox described above when executed by the programmable device.
[0312] The preferred embodiments of this disclosure have been described in detail above with reference to the accompanying drawings. However, this disclosure is not limited to the specific details of the above embodiments. Within the scope of the technical concept of this disclosure, various simple modifications can be made to the technical solutions of this disclosure, and these simple modifications all fall within the protection scope of this disclosure.
[0313] It should also be noted that the various specific technical features described in the above specific embodiments can be combined in any suitable manner without contradiction. In order to avoid unnecessary repetition, this disclosure will not describe the various possible combinations separately.
[0314] Furthermore, various different embodiments of this disclosure can be combined in any way, as long as they do not violate the spirit of this disclosure, they should also be regarded as the content disclosed in this disclosure.
Claims
1. A method for processing data in a data sandbox, characterized in that, include: Obtain the first dataset to be added to the data sandbox, including: Get the second dataset to be added to the data sandbox; Obtain the feature attributes of the data in the second dataset and the quasi-identifier attributes of the data to obtain a feature set; Obtain the remaining attributes of the data after removing the feature attribute and the quasi-identifier attribute, to obtain a candidate attribute set; For each candidate attribute in the current candidate attribute set, calculate the mutual information between the candidate attribute and the current feature set; Identify the target candidate attribute with the highest mutual information value; If the mutual information number of the target candidate attribute is greater than or equal to the second threshold, the target candidate attribute is added to the feature set and the target candidate attribute is deleted from the candidate attribute set. If the candidate attribute set is empty, generate the first dataset including the current feature attribute set based on the second dataset; For the first data in the first dataset, obtain the index of the first data to get the first index; Based on the first index, retrieve the data space of the data sandbox; If second data with the first index is retrieved from the data space, the first data is merged into the second data; Saving the merged second data to the data space includes: Determine the target group to which the second data belongs in the data space; Obtain the data of the target group in the data space; The data in the target group is taken as the target dataset, and the target dataset is further grouped to obtain multiple sub-datasets; The multiple sets of sub-data sets are saved to the data space.
2. The method according to claim 1, characterized in that, The step of obtaining the index of the first data in the first dataset to obtain the first index includes: Obtain the index of the first dataset to get the second index; Retrieve the data space of the data sandbox according to the second index; If a dataset with the second index is retrieved, the index of the first data in the first dataset is obtained to obtain the first index; The method further includes: If no dataset with the second index is found, the first dataset is used as the target dataset, and the target dataset is regrouped to obtain multiple sub-datasets; The multiple sets of sub-data sets are saved to the data space.
3. The method according to claim 1 or 2, characterized in that, The target dataset is then regrouped to obtain multiple sub-datasets, including: Based on the quasi-identifier attributes of the data in the target dataset, the target dataset is regrouped to obtain multiple candidate datasets; For each group of candidate datasets, calculate the total number of feature attributes of the data in that group of candidate datasets; If the total number of the aforementioned feature attributes is greater than or equal to a first threshold, the candidate dataset is treated as a subset of the dataset.
4. The method according to claim 3, characterized in that, The step of calculating the total number of feature attributes of the data in each candidate dataset includes: Sort the candidate datasets in each group; Based on the ranking, for each group of candidate datasets, calculate the total number of feature attributes of the data in that group of candidate datasets; The method further includes: If the total number of the feature attributes is less than the first threshold, the candidate dataset is fused with the target candidate dataset to obtain a new candidate dataset. Each candidate dataset includes the new candidate dataset, and the target candidate dataset is the next candidate dataset in the sorting.
5. The method according to claim 4, characterized in that, The process of fusing the candidate dataset with the target candidate dataset includes: Identify the target numerical data from this set of candidate datasets; For the current target numerical data, calculate the displacement value required to add the target numerical data to the target candidate dataset; For the current target numerical data, calculate the gain value generated by the target candidate dataset after adding the target numerical data to the target candidate dataset; If the displacement value is less than the displacement threshold and the gain value is greater than the gain threshold, the current target value data is added to the target candidate dataset. If the displacement value is greater than or equal to the displacement threshold, and / or the gain value is less than or equal to the gain threshold, the target numerical data bar is re-determined from the candidate dataset.
6. The method according to claim 3, characterized in that, Saving the multiple sets of sub-data sets to the data space includes: For each subset of datasets, determine the set of feature attributes for that subset of datasets; If the set of feature attributes is a closed set, the subset of data is saved to the data space; If the set of feature attributes is not a closed set, the data in the subset of data is split. The segmented subset of data is saved to the data space.
7. The method according to claim 6, characterized in that, The data in this subset is split, including: Each piece of data in this subset of data is taken as the third data, and the third data includes the first set of feature attributes; If the first set of feature attributes does not include a non-empty proper subset that is a closed set, the first set of feature attributes is split into multiple single-valued subsets; Based on each single-value subset, the third data is divided into fourth data whose feature attributes are respectively those of the single-value subsets; If the first set of feature attributes includes a non-empty proper subset and the non-empty proper subset is a closed set, the first set of feature attributes is split into a non-empty closed subset and a first subset. The third data is divided into a fifth data set whose feature attribute is the non-empty closed subset, and a sixth data set whose feature attribute is the first subset; Assign index numbers to the fourth, fifth, and sixth data, wherein the segmented subset includes one or more of the fourth, fifth, and sixth data with the index numbers.
8. A data processing device for a data sandbox, characterized in that, include: The first acquisition module is used to acquire the first dataset to be added to the data sandbox, including: Get the second dataset to be added to the data sandbox; Obtain the feature attributes of the data in the second dataset and the quasi-identifier attributes of the data to obtain a feature set; Obtain the remaining attributes of the data after removing the feature attribute and the quasi-identifier attribute, to obtain a candidate attribute set; For each candidate attribute in the current candidate attribute set, calculate the mutual information between the candidate attribute and the current feature set; Identify the target candidate attribute with the highest mutual information value; If the mutual information number of the target candidate attribute is greater than or equal to the second threshold, the target candidate attribute is added to the feature set and the target candidate attribute is deleted from the candidate attribute set. If the candidate attribute set is empty, generate the first dataset including the current feature attribute set based on the second dataset; The second acquisition module is used to obtain the index of the first data in the first dataset to obtain the first index. The retrieval module is used to retrieve the data space of the data sandbox based on the first index; A first execution module is configured to merge the first data into the second data when second data with the first index is retrieved from the data space; A first storage module, used to save the merged second data to the data space, includes: Determine the target group to which the second data belongs in the data space; Obtain the data of the target group in the data space; The data in the target group is taken as the target dataset, and the target dataset is further grouped to obtain multiple sub-datasets; The multiple sets of sub-data sets are saved to the data space.
9. A non-transitory computer-readable storage medium having a computer program stored thereon, characterized in that, When executed by a processor, the program implements the steps of the method according to any one of claims 1 to 7.
10. An electronic device, characterized in that, include: A memory on which computer programs are stored; A processor for executing the computer program in the memory to implement the steps of the method according to any one of claims 1 to 7.
Citation Information
Patent Citations
Method for reconciling CMDB configuration item
CN104503982A
