Data processing method and device, storage medium and computer device
Patent Information
- Application Number
- CN202110462476.7
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2021-04-27
- Publication Date
- 2026-09-04
- Estimated Expiration
- 2041-04-27
AI Technical Summary
[0004]本发明实施例提供了一种数据处理方法、装置、存储介质及计算机设备,以至少解决相关技术的差分隐私算法中,出现的隐私性与保序性无法很好地得到权衡的技术问题
[0143] (1) It weakens the strict sequential consistency constraint, so that the data disturbance retains the order of the real data as much as possible.
Smart Images

Figure CN115248925B_ABST
Abstract
Description
Technical Field
[0001] This invention relates to the field of data processing, and more specifically, to a data processing method, apparatus, storage medium, and computer equipment. Background Technology
[0002] Currently, differential privacy has become the de facto standard for privacy protection. Generally, differential privacy randomizes the dataset or the query results of the dataset, and achieves privacy protection of the query results by introducing random perturbations. In related technologies, differential privacy has been widely used and deployed in different application scenarios. In addition to providing provably secure privacy protection, in actual business, the results returned by differential privacy need to meet specific constraints, that is, the output results after differential privacy processing still meet the given constraints. There are three common types of constraints: (1) The differential privacy output results and the real results meet numerical operation constraints. For example, in the histogram publishing scenario, the sum of the count results of each enumeration value should be equal to the given total number. Consistency constraints of numerical operation relationships have been widely required in the field. (2) The query results of the same data are the same. Since the differential privacy algorithm is a randomized algorithm, it is generally difficult to achieve consistency constraints of the same query results of the same data. If the same results are required, there are generally two methods: introducing a key or random seed, and local differential privacy. (3) The differential privacy output results and the real results meet order constraints. Compared with numerical operation relationships, order constraints have not been widely studied. However, when using the above methods to process data, a problem arises where privacy and order preservation cannot be properly balanced.
[0003] There is currently no effective solution to the above problems. Summary of the Invention
[0004] This invention provides a data processing method, apparatus, storage medium, and computer device to at least solve the technical problem in differential privacy algorithms of related technologies where privacy and order preservation cannot be well balanced.
[0005] According to one aspect of the present invention, a data processing method is provided, comprising: acquiring data to be subjected to differential privacy processing; determining differential privacy parameters based on the ordering and privacy properties of the data; and performing differential privacy processing on the data based on the differential privacy parameters.
[0006] Optionally, the method further includes: dividing the data into multiple first data partitions; wherein, performing differential privacy processing on the data according to the differential privacy parameter includes: performing differential privacy processing on the multiple first data partitions respectively according to the differential privacy parameter, and mapping the resulting multiple first processing results to the first result partitions corresponding to the multiple first data partitions respectively.
[0007] Optionally, differential privacy processing is performed on the plurality of first data partitions according to the differential privacy parameter, and the resulting plurality of first processing results are mapped to the first result partitions corresponding to the plurality of first data partitions, including: determining the partition of predetermined data in the plurality of first data partitions, and the position of the predetermined data in the partition; performing differential privacy processing on the predetermined data using the differential privacy parameter to obtain the first processing result corresponding to the predetermined data, and mapping the first processing result to the position corresponding to the position in the partition.
[0008] Optionally, the method further includes: adding noise to the multiple first data partitions to obtain second data partitions; performing differential privacy processing on the multiple first data partitions according to the differential privacy parameter, and mapping the multiple first processing results to the first result partitions corresponding to the multiple first data partitions, including: performing differential privacy processing on the second data partitions according to the differential privacy parameter, and mapping the multiple second processing results to the result partitions corresponding to the second data partitions.
[0009] Optionally, adding noise to the plurality of first data partitions to obtain second data partitions includes: determining the sensitivity and differential privacy parameters of the noise to be added; adding the noise to the boundaries of the plurality of first data partitions to obtain the second data partitions.
[0010] Optionally, differential privacy processing is performed on the data according to the differential privacy parameters, including: performing distance-based local differential privacy processing on the data according to the differential privacy parameters, wherein the distance-based local differential privacy processing includes: the closer the distance between two data points, the more difficult it is to distinguish between the two results obtained by performing differential privacy processing on the two data points respectively.
[0011] Optionally, acquiring the data to be processed for differential privacy includes: acquiring the original continuous data to be processed for differential privacy; and discretizing the original continuous data to obtain the discretized data.
[0012] Optionally, differential privacy processing is performed on the data according to the differential privacy parameters, including: performing differential privacy processing on the discretized data according to the differential privacy parameters to obtain discrete data processing results; and performing continuity processing on the discrete data processing results to obtain continuous data processing results.
[0013] Optionally, the data includes at least one of the following: range data, quantile data, machine learning classification data, and regression data.
[0014] According to another aspect of the present invention, a data processing method is also provided, comprising: displaying a data input box on an interactive interface; receiving data to be differentially privacy processed in the data input box; displaying a result output component on the interactive interface; and displaying a data processing result on the interactive interface in response to an operation on the result output component, wherein the data processing result is obtained by performing differential privacy processing on the data according to differential privacy parameters, and the differential privacy parameters are determined according to the order preservation and privacy of the data.
[0015] According to another aspect of the present invention, a data processing method is also provided, comprising: acquiring data to be subjected to differential privacy processing; partitioning the data to obtain a plurality of first data partitions; and performing differential privacy processing on the plurality of first data partitions respectively using differential privacy parameters to obtain a differential privacy processing result of the data.
[0016] Optionally, differential privacy parameters are used to perform differential privacy processing on the plurality of first data partitions respectively to obtain differential privacy processing results for the data, including: determining the first partition where the first data is located in the plurality of first data partitions, and the position of the first data in the first partition, wherein the first data is any data in any data partition among the plurality of first data partitions; performing differential privacy processing on the first data using the differential privacy parameters to obtain a first processing result; and mapping the first processing result to the position in the first result partition corresponding to the position of the first partition in the first result partition corresponding to the first partition where the first data is located.
[0017] Optionally, different data partitions among the plurality of first data partitions may use different differential privacy parameters.
[0018] Optionally, the method further includes: adding noise to the boundaries of the plurality of first data partitions to obtain a plurality of corresponding second data partitions; wherein, using differential privacy parameters to perform differential privacy processing on the plurality of first data partitions respectively to obtain differential privacy processing results of the data includes: using differential privacy parameters to perform differential privacy processing on the plurality of second data partitions respectively to obtain differential privacy processing results of the data.
[0019] Optionally, differential privacy parameters are used to perform differential privacy processing on the plurality of second data partitions respectively to obtain differential privacy processing results for the data, including: determining the second partition where the second data is located in the plurality of second data partitions, and the position in the second partition, wherein the second data is any data in any data partition among the plurality of second data partitions; performing differential privacy processing on the second data using the differential privacy parameters to obtain a second processing result; and mapping the second processing result to the position in the second result partition corresponding to the position in the second partition corresponding to the second partition where the first data is located.
[0020] Optionally, the differential privacy parameters used in different data partitions among the plurality of second data partitions are different.
[0021] Optionally, differential privacy parameters are used to perform differential privacy processing on the plurality of first data partitions respectively to obtain differential privacy processing results of the data, including: using the differential privacy parameters to perform distance-based local differential privacy processing on the plurality of first data partitions, wherein the distance-based local differential privacy processing includes: the closer the distance between two data, the more difficult it is to distinguish between the two results obtained by performing differential privacy processing on the two data respectively.
[0022] According to another aspect of the present invention, a data processing method is also provided, comprising: a client device receiving data to be subjected to differential privacy processing; the client device sending the data to a server; the server performing differential privacy processing on the data according to differential privacy parameters to obtain a data processing result, wherein the differential privacy parameters are determined based on the ordering and privacy of the data; and the server returning the data processing result to the client device.
[0023] According to another aspect of the present invention, a data processing apparatus is also provided, comprising: a first acquisition module for acquiring data to be subjected to differential privacy processing; a determination module for determining differential privacy parameters based on the ordering and privacy properties of the data; and a first processing module for performing differential privacy processing on the data based on the differential privacy parameters.
[0024] According to another aspect of the present invention, a data processing apparatus is also provided, comprising: a display module for displaying a data input box on an interactive interface; a receiving module for receiving data to be differentially privacy processed in the data input box; a display module for displaying a result output component on the interactive interface; and a display module for displaying a data processing result on the interactive interface in response to an operation on the result output component, wherein the data processing result is obtained by performing differential privacy processing on the data according to differential privacy parameters, and the differential privacy parameters are determined based on the order preservation and privacy of the data.
[0025] According to another aspect of the present invention, a data processing apparatus is also provided, comprising: a second acquisition module for acquiring data to be subjected to differential privacy processing; a partitioning module for partitioning the data to obtain a plurality of first data partitions; and a second processing module for performing differential privacy processing on the plurality of first data partitions respectively using differential privacy parameters to obtain differential privacy processing results of the data.
[0026] According to another aspect of the present invention, a data processing system is also provided, comprising: a client device configured to receive data to be subjected to differential privacy processing and send the data to a server; and a server configured to perform differential privacy processing on the data according to differential privacy parameters to obtain a data processing result and return the data processing result to the client device, wherein the differential privacy parameters are determined based on the order preservation and privacy of the data.
[0027] According to another aspect of the present invention, a storage medium is also provided, the storage medium including a stored program, wherein, when the program is executed, the device where the storage medium is located controls the execution of the data processing method described in any one of the above embodiments.
[0028] According to another aspect of the present invention, a computer device is also provided, comprising: a memory and a processor, the memory storing a computer program; the processor being configured to execute the computer program stored in the memory, wherein the computer program, when executed, causes the processor to perform any of the data processing methods described above.
[0029] In this embodiment of the invention, a differential privacy processing method is designed for data processing. The magnitude of the differential privacy parameter is determined based on the balance between data order preservation and privacy, thereby determining the method for applying data perturbation. This allows for the selection of the most effective privacy protection method between privacy and order preservation, depending on the data type and requirements. Furthermore, while preserving data order to a certain extent, the strict order consistency constraint is weakened, ensuring that data processing trade-offs take data privacy into account. Moreover, compared to traditional differential privacy algorithms, this type of differential privacy algorithm more effectively balances privacy and order preservation, improving data protection strength and thus solving the technical problem in related differential privacy algorithms where privacy and order preservation cannot be well balanced. Attached Figure Description
[0030] The accompanying drawings, which are included to provide a further understanding of the invention and form part of this application, illustrate exemplary embodiments of the invention and, together with their description, serve to explain the invention and do not constitute an undue limitation thereof. In the drawings:
[0031] Figure 1 A hardware structure block diagram of a computer terminal for implementing a data processing method is shown.
[0032] Figure 2 This is a flowchart of a data processing method according to Embodiment 1 of the present invention;
[0033] Figure 3 This is a flowchart of the second data processing method according to Embodiment 1 of the present invention;
[0034] Figure 4 This is a flowchart of the third data processing method according to Embodiment 1 of the present invention;
[0035] Figure 5 This is a flowchart of the fourth data processing method according to Embodiment 1 of the present invention;
[0036] Figure 6 This is a schematic diagram of a data processing method provided by an optional embodiment of the present invention;
[0037] Figure 7 This is a schematic diagram of the direct mechanism scheme of the data processing method provided by an optional embodiment of the present invention;
[0038] Figure 8 This is a schematic diagram of a fixed partitioning mechanism scheme for a data processing method provided by an optional embodiment of the present invention;
[0039] Figure 9 This is a schematic diagram of a dynamic partitioning mechanism scheme for a data processing method provided by an optional embodiment of the present invention;
[0040] Figure 10 This is a structural block diagram of a data processing device according to Embodiment 2 of the present invention;
[0041] Figure 11 This is a structural block diagram of the data processing device 2 provided according to Embodiment 2 of the present invention;
[0042] Figure 12 This is a structural block diagram of the data processing device three provided in Embodiment 2 of the present invention;
[0043] Figure 13 This is a structural block diagram of the data processing system provided in Embodiment 2 of the present invention;
[0044] Figure 14 This is a structural block diagram of a computer terminal according to an embodiment of the present invention. Detailed Implementation
[0045] To enable those skilled in the art to better understand the present invention, the technical solutions of the present invention will be clearly and completely described below with reference to the accompanying drawings of the embodiments of the present invention. Obviously, the described embodiments are only some embodiments of the present invention, and not all embodiments. Based on the embodiments of the present invention, all other embodiments obtained by those skilled in the art without creative effort should fall within the scope of protection of the present invention.
[0046] It should be noted that the terms "first," "second," etc., in the specification, claims, and accompanying drawings of this invention are used to distinguish similar objects and are not necessarily used to describe a specific order or sequence. It should be understood that such data can be interchanged where appropriate so that the embodiments of the invention described herein can be implemented in orders other than those illustrated or described herein. Furthermore, the terms "comprising" and "having," and any variations thereof, are intended to cover a non-exclusive inclusion; for example, a process, method, system, product, or apparatus that comprises a series of steps or units is not necessarily limited to those steps or units explicitly listed, but may include other steps or units not explicitly listed or inherent to such processes, methods, products, or apparatus.
[0047] First, some nouns or terms that appear in the description of the embodiments of this application shall be interpreted as follows:
[0048] 1. Differential Privacy: Differential privacy is a privacy protection mechanism that reduces the impact of individual data on the aggregation result by adding a certain level of noise to the aggregated data, thereby protecting individual privacy while allowing data owners to publish relatively accurate aggregated data. In differential privacy, the data owner is completely trustworthy and holds the true data of each individual.
[0049] Assume the data owner holds the actual data for each individual, forming a dataset D. Let mechanism M be a (noise) mechanism for publishing aggregated data results on dataset D, and let Pr[M(D) ∈ S] denote that the data results published by M on dataset D are placed in set S. We say that if for any two neighboring datasets D and D' (i.e., the two datasets differ by only one individual), for any set S, we have Pr[M(D) ∈ S] ≤ If Pr[M(D') ∈ S], then mechanism M is said to satisfy ε-differential privacy.
[0050] 2. Local Differential Privacy: In local differential privacy, the data owner is not entirely trustworthy. Each individual adds a certain amount of noise to the data before uploading it to the data owner.
[0051] Assume that the data owner holds the real data for each individual, forming a dataset D, and is given the set X of all possible values for the data held by each individual. Let M be a mechanism for noise processing on the input data x ∈ X, and let Pr[M(x) ∈ S] denote the data results published by M on dataset D in set S. If for any possible pair of input data x, x' ∈ X, Pr[M(x) ∈ S] ≤ If Pr[M(x') ∈ S], then mechanism M is said to satisfy ε-local differential privacy.
[0052] 3. Distance-based Local Differential Privacy: Distance-based local differential privacy is a weakened version of local differential privacy. The basic idea is that if x and x' are close, then M(x) and M(x') are difficult to distinguish; if x and x' are far apart, then M(x) and M(x') are easier to distinguish.
[0053] It is assumed that the data owner holds the real data of each individual to form a data set D, and a given individual holds the set X of all possible values of the data. Let M be a mechanism that performs noise processing on input data x ∈ X, and let Pr[M(x) ∈ S] represent that the data result released by M under data set D is in set S. If for any possible pair of input data x, x'∈ X, Pr[M(x) ∈ S] ≤ eεD(x,x')Pr[M(x') ∈ S], then the mechanism M is said to satisfy ε-local differential privacy. Here D(x,x') represents the distance between x and x', and different D(x,x') can be defined according to different types of data.
[0054] 4. Order-Preserving Encryption (referred to as "OPE"): Order-preserving encryption uses a key k∈ K, a plaintext value range M = , , a ciphertext value range C = , , wherein plaintext m ∈M is input, and the encryption algorithm for outputting ciphertext c ∈ C is c = OPE(k, M, C, m). It satisfies the following properties:
[0055] (1) Determinism: With the same key k, plaintext value range M, ciphertext value range C, and plaintext m ∈ M as input, the algorithm outputs the same ciphertext c ∈ C.
[0056] (2) Order preservation: For the same key k, plaintext value range M, and ciphertext value range C, when the plaintext satisfies m < m', the ciphertext satisfies OPE(k, M, C, m) < OPE(k, M, C, m').
[0057] (3) Efficiency: Both the computational complexity and storage complexity of order-preserving encryption are low (i.e., polynomial time computational / storage complexity).
[0058] Example 1
[0059] According to an embodiment of the present invention, an embodiment of a data processing method is also provided. It should be noted that the steps shown in the flowchart of the accompanying drawings can be executed in a computer system such as a set of computer-executable instructions, and although the logical sequence is shown in the flowchart, in some cases, the steps shown or described can be executed in an order different from that here.
[0060] The method embodiment provided in Embodiment 1 of the present application can be executed in a mobile terminal, a computer terminal or a similar computing device. Figure 1A hardware structure block diagram of a computer terminal (or mobile device) for implementing a data processing method is shown. Figure 1 As shown, the computer terminal 10 (or mobile device) may include one or more processors 102 (shown as 102a, 102b, ..., 102n in the figure) 102 (processor 102 may include, but is not limited to, a microprocessor MCU or a programmable logic device FPGA, etc.), a memory 104 for storing data, and a transmission module 106 for communication functions. In addition, it may also include: a display, an input / output interface (I / O interface), a universal serial bus (USB) port (which may be included as one of the ports of a BUS bus), a network interface, a power supply, and / or a camera. Those skilled in the art will understand that... Figure 1 The structure shown is for illustrative purposes only and does not limit the structure of the aforementioned electronic device. For example, computer terminal 10 may also include... Figure 1 The more or fewer components shown, or having the same Figure 1 The different configurations shown.
[0061] It should be noted that the aforementioned one or more processors 102 and / or other data processing circuits are generally referred to herein as "data processing circuits". These data processing circuits may be embodied, in whole or in part, in software, hardware, firmware, or any other combination thereof. Furthermore, the data processing circuits may be a single, independent processing module, or may be integrated, in whole or in part, into any other element within the computer terminal 10 (or mobile device). As involved in the embodiments of this application, the data processing circuits serve as a processor control mechanism (e.g., selection of a variable resistor termination path connected to an interface).
[0062] The memory 104 can be used to store software programs and modules of application software, such as program instructions / data storage devices corresponding to the data processing method in this embodiment of the invention. The processor 102 executes various functional applications and data processing by running the software programs and modules stored in the memory 104, thereby implementing the data processing method of the aforementioned application. The memory 104 may include high-speed random access memory, and may also include non-volatile memory, such as one or more magnetic storage devices, flash memory, or other non-volatile solid-state memory. In some instances, the memory 104 may further include memory remotely located relative to the processor 102, and these remote memories can be connected to the computer terminal 10 via a network. Examples of such networks include, but are not limited to, the Internet, corporate intranets, local area networks, mobile communication networks, and combinations thereof.
[0063] The transmission device 106 is used to receive or send data via a network. Specific examples of the network described above may include a wireless network provided by the communication provider of the computer terminal 10. In one example, the transmission device 106 includes a Network Interface Controller (NIC), which can connect to other network devices via a base station to communicate with the Internet. In another example, the transmission device 106 may be a Radio Frequency (RF) module, used for wireless communication with the Internet.
[0064] The display may be, for example, a touchscreen liquid crystal display (LCD) that allows the user to interact with the user interface of the computer terminal 10 (or mobile device).
[0065] Under the aforementioned operating environment, this application provides the following: Figure 2 The data processing method shown. Figure 2 This is a flowchart of a data processing method according to Embodiment 1 of the present invention, as follows: Figure 2 As shown, the method includes the following steps:
[0066] Step S202: Obtain the data to be processed for differential privacy.
[0067] Step S204: Determine differential privacy parameters based on the order preservation and privacy requirements of the data;
[0068] Step S206: Perform differential privacy processing on the data according to the differential privacy parameters.
[0069] Through the above steps, a differential privacy processing method is designed for data processing. The magnitude of the differential privacy parameter is determined based on the balance between data order preservation and privacy, thereby determining the method for applying data perturbation. This allows for the selection of the most effective privacy protection method between privacy and order preservation, depending on the data type and requirements. Furthermore, while preserving data order to a certain extent, the strict order consistency constraint is weakened, ensuring that data processing trade-offs take privacy into account. Compared to traditional differential privacy algorithms, this method more effectively balances privacy and order preservation, improving data protection strength and thus solving the technical problem in related differential privacy algorithms where privacy and order preservation cannot be well balanced.
[0070] As an optional implementation, data to be processed for differential privacy is acquired. This data can be discrete, such as binomial distribution data, Poisson distribution data, etc.; or continuous, such as uniform distribution data, exponential distribution data, normal distribution data, etc. In various application scenarios, the data includes at least one of the following: range data, quantile data, machine learning classification data, and regression data. Depending on the type of data, this invention can be used in different application scenarios, including: privacy-preserving range queries, i.e., querying the number of data points within a given range, such as: purchase amount less than 10,000 yuan; quantile queries, such as: querying the minimum, 1 / 4 quantile, median, 3 / 4 quantile, maximum, etc.; and privacy-preserving machine learning algorithms, such as: classification learning algorithms, regression learning algorithms, etc. In terms of data privacy protection, this invention can be applied to various scenarios, meeting diverse needs, and is highly practical and widely applicable.
[0071] As an optional embodiment, acquiring the data to be processed for differential privacy includes: acquiring the original continuous data to be processed for differential privacy; and discretizing the original continuous data to obtain discretized data. There are many ways to convert continuous data into discrete data, such as converting continuous data into discrete data based on a decoding algorithm.
[0072] As an optional implementation, differential privacy processing is performed on the discretized data based on differential privacy parameters to obtain discrete data processing results; then, continuous processing is performed on the discrete data processing results to obtain continuous data processing results. There are many ways to convert discrete data into continuous data, such as using an encoding algorithm.
[0073] As an optional implementation, dividing the data into multiple first data partitions allows for the retrieval of data from different time periods and of different types as needed. This avoids large-scale privacy processing of all data simultaneously, reducing the occurrence of data processing failures and lowering processing latency. Furthermore, dividing the data into multiple partitions allows for separate processing of data within each partition, providing different levels of privacy protection based on the required level of privacy for different data types, thus achieving a reasonable balance between order preservation and privacy. For example, a hospital may have medical records for multiple patients, including: name, gender, height, weight, ID number, cause of illness, etc. It is known that ID number has a high weight in the medical records, while gender, height, and weight have low weights. In this case, privacy protection can be strengthened for high-weight information, while order preservation can be strengthened for low-weight information. Based on specific needs, this ensures a reasonable balance between order preservation and privacy for patient medical records, guaranteeing data privacy while maintaining a certain consistency in order. Dividing the data into regions, since the regions already have a fixed order, can enhance the orderliness of data processing, thus improving the orderliness of data processing compared to distance-based local differential privacy processing.
[0074] As an optional embodiment, differential privacy processing is performed on multiple first data partitions according to differential privacy parameters, and the resulting first processing results are mapped to first result partitions corresponding to the multiple first data partitions. This includes: determining the partition of predetermined data in the multiple first data partitions, and its position within the partition; performing differential privacy processing on the predetermined data using differential privacy parameters to obtain the first processing result corresponding to the predetermined data, and mapping the first processing result to the position corresponding to the position within the partition. In different partitions, differential privacy processing is performed using differential privacy parameters for the location of data in different partitions, and the result of the differential privacy processing is mapped to the original data's location, resulting in privacy-protected data, ensuring the order preservation requirement for data privacy. This targeted processing method enhances the level of privacy protection when processing different types of data with different needs, and more effectively protects user privacy.
[0075] As an optional embodiment, noise is added to multiple first data partitions to obtain second data partitions; the sensitivity and differential privacy parameter of the noise to be added are determined; noise is added at the boundaries of the multiple first data partitions to obtain second data partitions. That is, the magnitude of the noise is determined based on the sensitivity and differential privacy parameter. In the relationship between the differential privacy parameter and the amount of data noise, the smaller the differential privacy parameter, the greater the noise, the stronger the data privacy, and the less likely the data is to retain its true order, resulting in weaker order preservation; conversely, the larger the differential privacy parameter, the smaller the noise, the weaker the data privacy, and the more likely the data is to retain its true order, resulting in stronger order preservation. In the relationship between sensitivity and the amount of data noise, the resulting sensitivity varies depending on the interval and the degree of data density. The appropriate sensitivity is set according to requirements, and the amount of data noise is adjusted based on the sensitivity. This allows the data processing method to more reasonably balance order preservation and privacy. Not only does it preserve the order of data to a certain extent, but it also requires that the amount of noise introduced in differential privacy algorithms be controlled. This makes such differential privacy algorithms introduce less randomness compared to traditional differential privacy algorithms, and provides a weaker level of privacy protection.
[0076] As an optional embodiment, differential privacy processing is performed on multiple first data partitions according to differential privacy parameters, and the resulting first processing results are mapped to first result partitions corresponding to the multiple first data partitions. This includes: performing differential privacy processing on second data partitions according to differential privacy parameters, and mapping the resulting second processing results to result partitions corresponding to the second data partitions. Noise is added to the boundaries of the first data partitions. By reasonably applying differential privacy parameters and noise, the data processing results can be obtained, achieving a better balance between privacy and order preservation. Using the above processing, adding noise to fixed first data partitions makes the data partitions dynamic, effectively preventing attackers from determining the range of the real data based on the differentially privacy-processed data, thus avoiding a decrease in data privacy.
[0077] As an optional implementation, distance-based local differential privacy processing is performed on the data according to differential privacy parameters. This distance-based local differential privacy processing includes the following: the closer the distance between two data points, the more difficult it is to distinguish between the two results obtained by performing differential privacy processing on each data point. This not only weakens the strict order consistency constraint but also ensures that data perturbations retain the order of the real data as much as possible, and allows the degree of privacy protection for data perturbations to be described through a reasonable differential privacy definition.
[0078] According to embodiments of the present invention, a data processing method is also provided. Figure 3 This is a flowchart of the second data processing method according to Embodiment 1 of the present invention, as follows: Figure 3As shown, the method includes the following steps:
[0079] Step S302: Display a data input box on the interactive interface;
[0080] Step S304: Receive the data to be processed for differential privacy in the data input box;
[0081] Step S306: Display the result output component on the interactive interface;
[0082] Step S308: In response to the operation on the result output component, the data processing result is displayed on the interactive interface. The data processing result is obtained by performing differential privacy processing on the data according to the differential privacy parameter. The differential privacy parameter is determined based on the order preservation and privacy of the data.
[0083] Using the above processing method, users only need to input data into the interactive interface to automatically perform differential privacy processing on the input data according to its characteristics, thus obtaining the data processing result. By determining the magnitude of the differential privacy parameter based on order preservation and privacy, and then automatically processing the data, data privacy protection is efficiently achieved, effectively improving the strength of data protection and solving the technical problem in differential privacy algorithms of related technologies where privacy and order preservation cannot be well balanced.
[0084] According to embodiments of the present invention, a data processing method is also provided. Figure 4 This is a flowchart of the third data processing method according to Embodiment 1 of the present invention, as follows: Figure 4 As shown, the method includes the following steps:
[0085] Step S402: Obtain the data to be processed for differential privacy.
[0086] Step S404: Partition the data to obtain multiple first data partitions;
[0087] Step S406: Differential privacy parameters are used to perform differential privacy processing on multiple first data partitions to obtain the differential privacy processing results of the data.
[0088] By employing the above processing, after partitioning the data into multiple first data partitions, differential privacy parameters are used to process these multiple first data partitions. Since the multiple first data partitions obtained by partitioning the data themselves possess a certain degree of order preservation, differential privacy processing of the data effectively considers the preservation of data order to a certain extent. Therefore, while effectively protecting the data, it also effectively performs order preservation processing, achieving a good balance between data order preservation and privacy. This effectively solves the technical problem in differential privacy algorithms of related technologies where privacy and order preservation cannot be well balanced.
[0089] As an optional embodiment, when using differential privacy parameters to perform differential privacy processing on multiple first data partitions to obtain differential privacy processing results, various processing methods can be adopted. For example, the following processing method can be adopted: determine the first partition where the first data is located in the multiple first data partitions, and the position in the first partition, wherein the first data is any data in any data partition among the multiple first data partitions; apply differential privacy parameters to the first data to obtain a first processing result; map the first processing result to the position corresponding to the first partition position in the first result partition corresponding to the first partition where the first data is located. Using the above processing, for any data in any partition among the multiple first data partitions (wherein, the data can be a continuous data segment or a discrete data), differential privacy processing is performed to obtain a first processing result. Since each partition is located in a predetermined position in the data, the result obtained after differential privacy processing of the corresponding data should also be consistent with its position in the data, thus effectively protecting the orderliness of the data.
[0090] As an optional embodiment, the differential privacy parameters used by different data partitions in the plurality of first data partitions can be the same or different. Optionally, when the differential privacy parameters used by different data partitions in the plurality of first data partitions are different, each first data partition can flexibly select differential privacy parameters according to the characteristics of the data in each partition. On the one hand, different differential privacy parameters can enable the data in different partitions to better guarantee privacy. On the other hand, since each partition can effectively avoid interference between partitions to a certain extent, the order can be effectively guaranteed, so that privacy and order preservation can be further balanced.
[0091] As an optional embodiment, to further improve the balance between privacy and order preservation, noise can be added to the boundaries of multiple first data partitions to obtain corresponding multiple second data partitions; wherein, differential privacy parameters are used to perform differential privacy processing on the multiple first data partitions respectively to obtain differential privacy processing results of the data, including: using differential privacy parameters to perform differential privacy processing on the multiple second data partitions respectively to obtain differential privacy processing results of the data. Since fixed partitioning of data strongly reflects the order between data to a certain extent, this can also reduce the privacy of the data to some extent. Therefore, to avoid the privacy problem caused by fixed partitioning, some interference can be introduced into the boundaries of fixed partitions to make the partition interface somewhat hidden, thus protecting the privacy of the data. This interference is the noise added to the boundary as mentioned above. After adding noise to the boundary, a new boundary of data partition is obtained. When differential privacy processing is performed based on this new boundary, the data partitioning is not particularly clear, that is, the order between data is not so obvious, thus effectively ensuring the privacy of the data.
[0092] As an optional embodiment, when applying differential privacy parameters to perform differential privacy processing on multiple second data partitions to obtain differential privacy processing results, the same method as applying differential privacy processing to multiple first data partitions can be used. That is, when performing differential privacy processing on the second data in the data partitions obtained at the new boundaries, the resulting second processing result is mapped to the position corresponding to the location of the data. For example, the second data can first be determined as the second partition in which the multiple second data partitions are located, and its position within the second partition. Here, the second data is any data in any one of the multiple second data partitions. Differential privacy parameters are then applied to the second data to obtain a second processing result. This second processing result is then mapped to the position corresponding to the second partition's location within the second result partition corresponding to the second partition where the first data is located.
[0093] As an optional embodiment, the differential privacy parameters used by different data partitions in the plurality of second data partitions can be the same or different. Similar to the first data partition, when different data partitions in the plurality of second data partitions use different differential privacy parameters, the order can be effectively guaranteed, so that privacy and order preservation can be further balanced.
[0094] As an optional embodiment, differential privacy parameters are used to perform differential privacy processing on multiple first data partitions respectively. When obtaining the differential privacy processing results of the data, the corresponding differential privacy processing method can be selected as needed. For example, distance-based local differential privacy processing can be selected to process the data, that is, differential privacy parameters are used to perform distance-based local differential privacy processing on multiple first data partitions. The distance-based local differential privacy processing includes: the closer the distance between two data, the more difficult it is to distinguish between the two results obtained by performing differential privacy processing on the two data respectively.
[0095] According to embodiments of the present invention, a data processing method is also provided. Figure 5 This is a flowchart of the fourth data processing method according to Embodiment 1 of the present invention, as follows: Figure 5 As shown, the method includes the following steps:
[0096] Step S502: The client device receives the data to be processed for differential privacy.
[0097] In step S504, the client device sends data to the server;
[0098] Step S506: The server performs differential privacy processing on the data according to the differential privacy parameters to obtain the data processing result, wherein the differential privacy parameters are determined based on the order preservation and privacy of the data;
[0099] In step S508, the server returns the data processing result to the client device.
[0100] Using the above processing, the client device only needs to receive and send data. The server can then process the data by designing differential privacy parameters appropriately, and the client device can receive the data processing results, effectively protecting the data. This method provides efficient and direct privacy protection, solving the technical problem in related differential privacy algorithms where privacy and order preservation cannot be well balanced.
[0101] Based on the above embodiments and optional embodiments, taking the method related to order preservation and desensitization as an example, the present invention provides an optional implementation method, which is described in detail below.
[0102] Among the related technologies for order-preserving data anonymization, order-preserving encryption methods have been proposed. In order-preserving encryption, the ciphertext and plaintext maintain a strict order constraint; the order of the plaintext can be determined simply by comparing the order of the ciphertext. However, the strict order-preserving constraint requires a deterministic algorithm, which cannot satisfy the definition of differential privacy. Therefore, because order-preserving encryption reveals the order of the plaintext data, its protection of plaintext data is very limited. Actual attack results show that order-preserving encryption is highly vulnerable to statistical attacks (also known as "Statistical Attacks").
[0103] On the other hand, various cryptographic processing methods have been proposed, such as the Order-Preserving Encoding Protocol and the Order-Revealing Encryption. However, the former requires interaction with the party storing the encrypted data when comparing the size of the ciphertext data, while the latter requires calling a public comparison function to compare the size of the ciphertext, and the plaintext order cannot be directly determined from the ciphertext order.
[0104] The aforementioned data privacy protection methods fail to strike a good balance between data privacy and protection. Based on the need for data privacy protection, existing privacy protection methods need to be modified and adjusted to support richer distance and order preservation definitions.
[0105] Therefore, in this optional embodiment, a differential privacy data processing method (i.e., a partially order-preserving desensitization processing method) is provided, which reasonably balances order preservation and privacy. Compared with the order-preserving encryption method, this optional embodiment weakens the strict order consistency constraint, so that data perturbation retains the order of real data as much as possible, and the degree of privacy protection of data perturbation can be described by a reasonable differential privacy definition. The optional embodiment is described in detail below.
[0106] Related explanations;
[0107] The aforementioned partial order-preserving desensitization processing may include:
[0108] 1) Encoding algorithm (also known as "Encode"): Discretizes continuous data x ∈ R to obtain discretized data.
[0109] X ← Encode(x, Δd): The algorithm takes the original data x and a unit distance Δd as input. The output is discretized data X ∈ Z. The formula for the encoding algorithm is X = x / Δd, rounded down. Note that if the original data is already discretized (e.g., double, float, etc.), the encoding algorithm is unnecessary.
[0110] 2) Randomization algorithm (also known as "Randomize"): performs partial order-preserving desensitization processing on the data;
[0111] Y ← Randomize(X, ε, Δf): The algorithm takes the original data X ∈ R or discretized data X ∈ Z as input, the differential privacy parameter ε, and the sensitivity Δf. If the input X is the original data, the algorithm outputs partly ordered and desensitized continuous data Y ∈ R. If the input X is discretized data, the algorithm outputs partly ordered and desensitized discretized data Y ∈ Z.
[0112] 3) Decoding algorithm (abbreviated as "Decode"): Performs continuous processing on discretized data X ∈ Z to obtain continuous data.
[0113] y ← Decode(Y, Δd): The algorithm takes discretized data Y ∈ Z and a unit distance Δd as input. The algorithm outputs continuous data y ∈ R. The formula for the decoding algorithm is Y = y Δd. It should be noted that if the original data is continuous, then a decoding algorithm is not necessary.
[0114] Figure 6 This is a schematic diagram of a data processing method provided by an optional embodiment of the present invention, such as... Figure 6 As shown, the optional implementation method will be described below, wherein it is assumed that the data are points in a two-dimensional space, as shown in Figure (a):
[0115] 1. When the differential privacy parameter ε is relatively large, a small amount of noise is added to each data point, and the noise range is shown in Figure (b).
[0116] It should be noted that, except for a very few data points, the retrieval range of other data after adding noise is still within the dotted line, and the order will not be affected, thus possessing a certain degree of order preservation.
[0117] 2. When the differential privacy parameter ε is relatively small, a relatively large amount of noise is added to each data point, and the noise range is shown in Figure (c).
[0118] It should be noted that the retrieval range of some data after adding noise is not inside the dotted line, and the order of some data may have an impact, thus possessing a certain degree of privacy.
[0119] The aforementioned partial order-preserving desensitization processing can be implemented in various ways. For example, it can be implemented in at least one of the following ways: 1) direct mechanism, 2) fixed partition mechanism and 3) dynamic partition mechanism, which will be explained below.
[0120] 1) Direct Mechanism
[0121] Existing local differential privacy algorithms that define sensitive information in a dataset based on distance policies can serve as a fundamental relative distance differential privacy algorithm. Figure 7 Figure 1 is a schematic diagram of the direct mechanism scheme of the data processing method provided by an optional embodiment of the present invention. When the original data is continuous data, it is shown in Figure (a); when the original data is discrete data, it is shown in Figure (b). The mechanism will be described in detail below:
[0122] 1. Users run the relative distance differential privacy algorithm locally;
[0123] 2. The distance-based local differential privacy algorithm adds an exponential distribution (e.g., discrete Laplace distribution noise with noise parameter ε / 2, geometric distribution noise, step distribution noise, Gaussian noise) to the original data X (e.g., continuous data, discrete data), so that the probability of the output result after adding noise is inversely proportional to its distance relative to X.
[0124] 3. Adjust the size of ε to balance the order and the strength of privacy protection. The larger ε is, the better the order of the algorithm, and the lower the strength of privacy protection.
[0125] The direct mechanism scheme mentioned above, based on the sensitivity of distance definition, limits the amount of perturbation added to the data by the differential privacy mechanism, so that the perturbed data retains the order information of the real data with a higher probability.
[0126] 2) Fixed partitioning mechanism
[0127] To further improve the order preservation of the desensitization algorithm, a local differential privacy algorithm based on interval strategy for defining sensitive information is proposed. Figure 8 This is a schematic diagram of a fixed partitioning mechanism scheme for a data processing method provided by an optional embodiment of the present invention. When the original data is continuous data, it is shown in Figure (a); when the original data is discrete data, it is shown in Figure (b). The mechanism will be described in detail below:
[0128] 1. Given the length t > 0 of each partition, that is, divide the entire data domain into ..., [-2t, -t), [-t, 0), [0, t), [t, 2t)...;
[0129] 2. Calculate O = X / t, and round the result down (i.e. find the integer less than or equal to X / t that is closest to X / t, such as 1.5 rounded down to 1, 1 rounded down to 1, and -1.5 rounded down to -2) to obtain the partition index where the data X is located.
[0130] 3. Calculate o = X - O·t, and round down the result to obtain the position of data X within the partition;
[0131] 4. Call the randomization algorithm described above within the partition and map the result back to the corresponding partition.
[0132] In the fixed partitioning mechanism scheme described above (2), the fixed partitioning order-preserving desensitization algorithm guarantees that data mapped to different partitions is absolutely ordered after perturbation, while data mapped to the same partition is partially ordered after perturbation. The dataset published by the algorithm has better ordering than the basic distance-based order-preserving desensitization algorithm in the direct mechanism scheme described above (1). However, under more relaxed privacy assumptions, this scheme can easily determine the range of the true data value based on the perturbed data values.
[0133] 3) Dynamic partitioning mechanism
[0134] To avoid determining the range of the true data value based on the perturbed data value, a perturbation is proposed on the boundary of the partition to improve the privacy protection strength of the order-preserving de-identification algorithm between partitions. Figure 9 This is a schematic diagram of the dynamic partitioning mechanism scheme of the data processing method provided by an optional embodiment of the present invention. When the original data is continuous data, it is shown in Figure (a); when the original data is discrete data, it is shown in Figure (b). The mechanism will be described in detail below:
[0135] 1. Users deterministically map raw data to corresponding interval ranges;
[0136] 2. Determine the left and right boundaries of the interval containing the original data. and Add noise with sensitivity Δ = 2t and differential privacy parameter ε (using the same method as in step 1) to obtain the noisy intervals. = [ , );
[0137] 3. Calculation = X - ;
[0138] 4. In the interval [0, ) - The above-mentioned fixed partitioning mechanism is used to perform fixed partitioning of the data.
[0139] It should be noted that the left endpoint value of the interval after adding noise Less than the right endpoint of the interval , t = - .
[0140] The dynamic partitioning mechanism described in point 3 above not only improves the order preservation of the desensitization algorithm but also avoids determining the range of the true data value based on the perturbed data value. This effectively balances the privacy and order preservation aspects of data privacy protection.
[0141] Furthermore, it should be noted that the practical solutions mentioned above, including but not limited to direct mechanisms, fixed partitioning mechanisms, and dynamic partitioning mechanisms, can also be designed in other ways, as long as the probability value of lower noise is greater than the probability value of higher noise during differential privacy processing, i.e., satisfying the definition of distance differential privacy and partial order preservation. For example, depending on the different scenarios and requirements of data privacy protection applications, designing the sensitivity of boundary value differential privacy processing in the dynamic partitioning mechanism to be other than 2t can result in different differential privacy conclusions.
[0142] The following beneficial effects can be achieved through the above optional implementation methods:
[0143] (1) It weakens the strict sequential consistency constraint, so that the data disturbance retains the order of the real data as much as possible.
[0144] (2) Describe the degree of privacy protection of data perturbation through a reasonable differential privacy definition.
[0145] (3) It can be applied to range queries, quantile queries and machine learning classification and regression scenarios.
[0146] It should be noted that, for the sake of simplicity, the foregoing method embodiments are all described as a series of actions. However, those skilled in the art should understand that the present invention is not limited to the described order of actions, because according to the present invention, some steps can be performed in other orders or simultaneously. Furthermore, those skilled in the art should also understand that the embodiments described in the specification are preferred embodiments, and the actions and modules involved are not necessarily essential to the present invention.
[0147] Through the above description of the embodiments, those skilled in the art can clearly understand that the data processing method according to the above embodiments can be implemented by means of software plus necessary general-purpose hardware platform. Of course, it can also be implemented by hardware, but in many cases the former is a better implementation method. Based on this understanding, the technical solution of the present invention, or the part that contributes to the prior art, can be embodied in the form of a software product. This computer software product is stored in a storage medium (such as ROM / RAM, magnetic disk, optical disk) and includes several instructions to cause a terminal device (which may be a mobile phone, computer, server, or network device, etc.) to execute the methods of the various embodiments of the present invention.
[0148] Example 2
[0149] According to an embodiment of the present invention, an apparatus for implementing the above-described data processing method one is also provided. Figure 10 This is a structural block diagram of a data processing apparatus according to Embodiment 2 of the present invention, as shown below. Figure 10 As shown, the device includes: a first acquisition module 1002, a determination module 1004, and a first processing module 1006. The device will be described below.
[0150] The first acquisition module 1002 is used to acquire data to be subjected to differential privacy processing; the determination module 1004 is connected to the first acquisition module 1002 and is used to determine differential privacy parameters based on the order preservation and privacy of the data; the first processing module 1006 is connected to the determination module 1004 and is used to perform differential privacy processing on the data based on the differential privacy parameters.
[0151] According to an embodiment of the present invention, an apparatus for implementing the second data processing method described above is also provided. Figure 11 This is a structural block diagram of the data processing device two provided according to Embodiment 2 of the present invention, as shown below. Figure 11 As shown, the device includes: a display module 1102, a receiving module 1104, a display module 1106, and a display module 1108. The device will be described below.
[0152] Display module 1102 is used to display a data input box on the interactive interface; receiving module 1104 is connected to the display module 1102 and is used to receive data to be processed for differential privacy in the data input box; display module 1106 is connected to the receiving module 1104 and is used to display a result output component on the interactive interface; display module 1108 is connected to the display module 1106 and is used to respond to operations on the result output component and display the data processing result on the interactive interface, wherein the data processing result is obtained by performing differential privacy processing on the data according to differential privacy parameters, and the differential privacy parameters are determined according to the order preservation and privacy of the data.
[0153] According to an embodiment of the present invention, an apparatus for implementing the above-described data processing method three is also provided. Figure 12 This is a structural block diagram of the data processing device three provided in Embodiment 2 of the present invention, as shown below. Figure 12 As shown, the device includes: a second acquisition module 1202, a partitioning module 1204, and a second processing module 1206. The device will be described below.
[0154] The second acquisition module 1202 is used to acquire the data to be processed for differential privacy; the partitioning module 1204 is connected to the second acquisition module 1202 and is used to partition the data to obtain multiple first data partitions; the second processing module 1206 is connected to the partitioning module 1204 and is used to perform differential privacy processing on the multiple first data partitions respectively using differential privacy parameters to obtain the differential privacy processing result of the data.
[0155] According to an embodiment of the present invention, a system for implementing the above-described data processing method four is also provided. Figure 13 This is a structural block diagram of the data processing system provided in Embodiment 2 of the present invention, as shown below. Figure 13 As shown, the system includes: client device 1302 and server device 1304. The system is described below.
[0156] Client device 1302 is used to receive data to be processed for differential privacy and send the data to server device; server device 1304 is connected to the client device 1302 and is used to perform differential privacy processing on the data according to differential privacy parameters to obtain data processing results and return the data processing results to the client device, wherein the differential privacy parameters are determined according to the order preservation and privacy of the data.
[0157] It should be noted that the above modules correspond to the steps in Embodiment 1, and the instances and application scenarios implemented by the above modules and the corresponding steps are the same, but are not limited to the content disclosed in Embodiment 1. It should be noted that the above modules, as part of the device, can run in the computer terminal 10 provided in Embodiment 1.
[0158] Example 3
[0159] Embodiments of the present invention can provide a computer terminal, which can be any computer terminal device in a group of computer terminals. Optionally, in this embodiment, the computer terminal can also be replaced by a mobile terminal or other terminal device.
[0160] Optionally, in this embodiment, the computer terminal may be located in at least one of a plurality of network devices in a computer network.
[0161] In this embodiment, the computer terminal described above can execute the program code for the following steps in the data processing method of the application: obtaining data to be processed for differential privacy; determining differential privacy parameters based on the ordering and privacy of the data; and performing differential privacy processing on the data based on the differential privacy parameters.
[0162] Optionally, Figure 14 This is a structural block diagram of a computer terminal according to an embodiment of the present invention. Figure 14 As shown, the computer terminal may include one or more (only one is shown in the figure) processors 142, memory 144, etc.
[0163] The memory can be used to store software programs and modules, such as the program instructions / modules corresponding to the data processing method and apparatus in this embodiment of the invention. The processor executes various functional applications and data processing by running the software programs and modules stored in the memory, thereby realizing the aforementioned data processing method. The memory may include high-speed random access memory, and may also include non-volatile memory, such as one or more magnetic storage devices, flash memory, or other non-volatile solid-state memory. In some instances, the memory may further include memory remotely located relative to the processor, and these remote memories can be connected to terminal A via a network. Examples of such networks include, but are not limited to, the Internet, corporate intranets, local area networks, mobile communication networks, and combinations thereof.
[0164] The processor can invoke information and application programs stored in memory via a transmission device to perform the following steps: acquire data to be processed for differential privacy; determine differential privacy parameters based on the ordering and privacy requirements of the data; and perform differential privacy processing on the data based on the differential privacy parameters.
[0165] Optionally, the processor may also execute program code that performs the following steps: dividing the data into multiple first data partitions; wherein, performing differential privacy processing on the data according to differential privacy parameters includes: performing differential privacy processing on the multiple first data partitions respectively according to the differential privacy parameters, and mapping the multiple first processing results to the first result partitions corresponding to the multiple first data partitions respectively.
[0166] Optionally, the processor may also execute program code that performs differential privacy processing on multiple first data partitions according to differential privacy parameters, and maps the resulting multiple first processing results to first result partitions corresponding to the multiple first data partitions, including: determining the partition of the predetermined data in the multiple first data partitions, and the position of the predetermined data in the partition; performing differential privacy processing on the predetermined data using differential privacy parameters to obtain the first processing result corresponding to the predetermined data, and mapping the first processing result to the position corresponding to the position in the partition.
[0167] Optionally, the processor may also execute program code with the following steps: adding noise to the multiple first data partitions to obtain second data partitions; performing differential privacy processing on the multiple first data partitions according to differential privacy parameters, and mapping the multiple first processing results to the first result partitions corresponding to the multiple first data partitions, including: performing differential privacy processing on the second data partitions according to differential privacy parameters, and mapping the multiple second processing results to the result partitions corresponding to the second data partitions.
[0168] Optionally, the processor may also execute program code that performs the following steps: adding noise to multiple first data partitions to obtain second data partitions, including: determining the sensitivity and differential privacy parameters of the noise to be added; adding noise at the boundaries of the multiple first data partitions to obtain second data partitions.
[0169] Optionally, the processor may also execute program code that performs differential privacy processing on the data according to the differential privacy parameters, including: performing distance-based local differential privacy processing on the data according to the differential privacy parameters, wherein the distance-based local differential privacy processing includes: the closer the distance between two data points, the more difficult it is to distinguish between the two results obtained by performing differential privacy processing on the two data points respectively.
[0170] Optionally, the processor may also execute program code that performs the following steps: acquiring data to be processed for differential privacy, including: acquiring the original continuous data to be processed for differential privacy; discretizing the original continuous data to obtain the discretized data.
[0171] Optionally, the processor may also execute program code that performs differential privacy processing on the data according to differential privacy parameters, including: performing differential privacy processing on the discretized data according to the differential privacy parameters to obtain discrete data processing results; and performing continuity processing on the discrete data processing results to obtain continuous data processing results.
[0172] Optionally, the processor may also execute program code that includes at least one of the following: range data, quantile data, machine learning classification data, and regression data.
[0173] The processor can invoke information and applications stored in memory via a transmission device to perform the following steps: displaying a data input box on an interactive interface; receiving data to be processed for differential privacy in the data input box; displaying a result output component on the interactive interface; responding to operations on the result output component and displaying the data processing result on the interactive interface, wherein the data processing result is obtained by performing differential privacy processing on the data according to differential privacy parameters, and the differential privacy parameters are determined based on the order preservation and privacy of the data.
[0174] The processor can access information and applications stored in the memory via a transmission device to perform the following steps: acquire data to be processed for differential privacy; partition the data to obtain multiple first data partitions; and apply differential privacy parameters to the multiple first data partitions to obtain the differential privacy processing result of the data.
[0175] Optionally, the processor may also execute program code with the following steps: using differential privacy parameters, performing differential privacy processing on multiple first data partitions respectively to obtain differential privacy processing results of the data, including: determining the first partition where the first data is located in the multiple first data partitions, and the position in the first partition, wherein the first data is any data in any data partition among the multiple first data partitions; using differential privacy parameters, performing differential privacy processing on the first data to obtain a first processing result; mapping the first processing result to the position in the first result partition corresponding to the position in the first partition where the first data is located.
[0176] Optionally, the processor may also execute program code that uses different differential privacy parameters for different data partitions in multiple first data partitions.
[0177] Optionally, the processor may also execute program code for the following steps: the method further includes: adding noise to the boundaries of multiple first data partitions to obtain multiple corresponding second data partitions; wherein, differential privacy parameters are used to perform differential privacy processing on the multiple first data partitions respectively to obtain differential privacy processing results of the data, including: using differential privacy parameters to perform differential privacy processing on the multiple second data partitions respectively to obtain differential privacy processing results of the data.
[0178] Optionally, the processor may also execute program code with the following steps: using differential privacy parameters, performing differential privacy processing on multiple second data partitions respectively to obtain differential privacy processing results of the data, including: determining the second partition where the second data is located in the multiple second data partitions, and the position in the second partition, wherein the second data is any data in any data partition among the multiple second data partitions; using differential privacy parameters, performing differential privacy processing on the second data to obtain a second processing result; mapping the second processing result to the position in the second result partition corresponding to the position in the second partition corresponding to the second partition where the first data is located.
[0179] Optionally, the processor may also execute program code that uses different differential privacy parameters for different data partitions in multiple second data partitions.
[0180] Optionally, the processor may also execute program code that performs the following steps: using differential privacy parameters to perform differential privacy processing on multiple first data partitions respectively, and obtaining differential privacy processing results of the data, including: using differential privacy parameters to perform distance-based local differential privacy processing on multiple first data partitions, wherein the distance-based local differential privacy processing includes: the closer the distance between two data, the more difficult it is to distinguish between the two results obtained by performing differential privacy processing on the two data respectively.
[0181] The processor can invoke information and applications stored in memory through the transmission device to perform the following steps: the client device receives data to be processed for differential privacy; the client device sends the data to the server; the server performs differential privacy processing on the data according to differential privacy parameters to obtain the data processing result, wherein the differential privacy parameters are determined based on the ordering and privacy of the data; the server returns the data processing result to the client device.
[0182] This invention provides a data processing method. A differential privacy processing method is designed for data processing. The magnitude of the differential privacy parameter is determined based on the balance between data order preservation and privacy, thereby determining the method of applying data perturbation. This allows for the selection of the most effective privacy protection method between privacy and order preservation, depending on the data type and requirements. Furthermore, while preserving data order to a certain extent, the strict order consistency constraint is weakened, ensuring that data processing retains the true order of the data as much as possible. Moreover, compared to traditional differential privacy algorithms, this method more effectively balances privacy and order preservation, improving data protection strength and thus solving the technical problem in related differential privacy algorithms where privacy and order preservation cannot be well balanced.
[0183] Those skilled in the art will understand that Figure 14 The structure shown is for illustrative purposes only. The computer terminal can also be a smartphone (such as an Android phone, an iOS phone, etc.), a tablet computer, a mobile internet device (MID), a PAD, and other terminal devices. Figure 14 This does not limit the structure of the aforementioned electronic devices. For example, a computer terminal may also include components that are more... Figure 14 The more or fewer components shown (such as network interfaces, display devices, etc.), or having the same Figure 14 The different configurations shown.
[0184] Those skilled in the art will understand that all or part of the steps in the various methods of the above embodiments can be implemented by a program instructing the hardware related to the terminal device. The program can be stored in a computer-readable storage medium, which may include: flash drive, read-only memory (ROM), random access memory (RAM), disk or optical disk, etc.
[0185] Example 4
[0186] Embodiments of the present invention also provide a storage medium. Optionally, in this embodiment, the storage medium can be used to store the program code executed by the data processing method provided in Embodiment 1.
[0187] Optionally, in this embodiment, the storage medium may be located in any computer terminal in a group of computer terminals in a computer network, or in any mobile terminal in a group of mobile terminals.
[0188] Optionally, in this embodiment, the storage medium is configured to store program code for performing the following steps: acquiring data to be processed for differential privacy; determining differential privacy parameters based on the ordering and privacy of the data; and performing differential privacy processing on the data based on the differential privacy parameters.
[0189] Optionally, in this embodiment, the storage medium is configured to store program code for performing the following steps: dividing data into multiple first data partitions; wherein, performing differential privacy processing on the data according to differential privacy parameters includes: performing differential privacy processing on the multiple first data partitions respectively according to the differential privacy parameters, and mapping the resulting multiple first processing results to the first result partitions corresponding to the multiple first data partitions respectively.
[0190] Optionally, in this embodiment, the storage medium is configured to store program code for performing the following steps: performing differential privacy processing on multiple first data partitions according to differential privacy parameters, and mapping the resulting multiple first processing results to first result partitions corresponding to the multiple first data partitions, including: determining the partition of predetermined data in the multiple first data partitions, and the position of the predetermined data in the partition; performing differential privacy processing on the predetermined data using differential privacy parameters to obtain the first processing result corresponding to the predetermined data, and mapping the first processing result to the position corresponding to the position in the partition.
[0191] Optionally, in this embodiment, the storage medium is configured to store program code for performing the following steps: adding noise to a plurality of first data partitions to obtain second data partitions; performing differential privacy processing on the plurality of first data partitions according to differential privacy parameters, and mapping the resulting plurality of first processing results to first result partitions corresponding to the plurality of first data partitions, including: performing differential privacy processing on the second data partitions according to differential privacy parameters, and mapping the resulting plurality of second processing results to result partitions corresponding to the second data partitions.
[0192] Optionally, in this embodiment, the storage medium is configured to store program code for performing the following steps: adding noise to a plurality of first data partitions to obtain a second data partition, including: determining the sensitivity and differential privacy parameters of the noise to be added; adding noise at the boundaries of the plurality of first data partitions to obtain a second data partition.
[0193] Optionally, in this embodiment, the storage medium is configured to store program code for performing the following steps: performing differential privacy processing on the data according to differential privacy parameters, including: performing distance-based local differential privacy processing on the data according to the differential privacy parameters, wherein the distance-based local differential privacy processing includes: the closer the distance between two data points, the more difficult it is to distinguish between the two results obtained by performing differential privacy processing on the two data points respectively.
[0194] Optionally, in this embodiment, the storage medium is configured to store program code for performing the following steps: obtaining data to be differentially privacy processed, including: obtaining the original continuous data to be differentially privacy processed; and discretizing the original continuous data to obtain discretized data.
[0195] Optionally, in this embodiment, the storage medium is configured to store program code for performing the following steps: performing differential privacy processing on the data according to differential privacy parameters, including: performing differential privacy processing on the discretized data according to the differential privacy parameters to obtain discrete data processing results; and performing continuity processing on the discrete data processing results to obtain continuous data processing results.
[0196] Optionally, in this embodiment, the storage medium is configured to store program code for performing the following steps: the data includes at least one of the following: range data, quantile data, machine learning classification data, and regression data.
[0197] Optionally, in this embodiment, the storage medium is configured to store program code for performing the following steps: displaying a data input box on the interactive interface; receiving data to be differentially privacy processed in the data input box; displaying a result output component on the interactive interface; and displaying the data processing result on the interactive interface in response to an operation on the result output component, wherein the data processing result is obtained by performing differential privacy processing on the data according to differential privacy parameters, and the differential privacy parameters are determined based on the order preservation and privacy of the data.
[0198] Optionally, in this embodiment, the storage medium is configured to store program code for performing the following steps: acquiring data to be processed for differential privacy; partitioning the data to obtain multiple first data partitions; and using differential privacy parameters to perform differential privacy processing on the multiple first data partitions respectively to obtain the differential privacy processing result of the data.
[0199] Optionally, in this embodiment, the storage medium is configured to store program code for performing the following steps: using differential privacy parameters to perform differential privacy processing on multiple first data partitions respectively, to obtain differential privacy processing results of the data, including: determining the first partition where the first data is located in the multiple first data partitions, and the position in the first partition, wherein the first data is any data in any data partition among the multiple first data partitions; using differential privacy parameters to perform differential privacy processing on the first data, to obtain a first processing result; mapping the first processing result to the position in the first result partition corresponding to the position in the first partition corresponding to the first partition where the first data is located.
[0200] Optionally, in this embodiment, the storage medium is configured to store program code for performing the following steps: different data partitions in a plurality of first data partitions use different differential privacy parameters.
[0201] Optionally, in this embodiment, the storage medium is configured to store program code for performing the following steps: the method further includes: adding noise to the boundaries of multiple first data partitions to obtain corresponding multiple second data partitions; wherein, differential privacy parameters are used to perform differential privacy processing on the multiple first data partitions respectively to obtain differential privacy processing results of the data, including: using differential privacy parameters to perform differential privacy processing on the multiple second data partitions respectively to obtain differential privacy processing results of the data.
[0202] Optionally, in this embodiment, the storage medium is configured to store program code for performing the following steps: using differential privacy parameters to perform differential privacy processing on multiple second data partitions respectively, to obtain differential privacy processing results of the data, including: determining the second partition where the second data is located in the multiple second data partitions, and the position in the second partition, wherein the second data is any data in any one of the multiple second data partitions; using differential privacy parameters to perform differential privacy processing on the second data, to obtain a second processing result; mapping the second processing result to the position in the second result partition corresponding to the position in the second partition corresponding to the second partition where the first data is located.
[0203] Optionally, in this embodiment, the storage medium is configured to store program code for performing the following steps: different data partitions in a plurality of second data partitions use different differential privacy parameters.
[0204] Optionally, in this embodiment, the storage medium is configured to store program code for performing the following steps: using differential privacy parameters to perform differential privacy processing on multiple first data partitions respectively to obtain differential privacy processing results of the data, including: using differential privacy parameters to perform distance-based local differential privacy processing on multiple first data partitions, wherein the distance-based local differential privacy processing includes: the closer the distance between two data, the more difficult it is to distinguish between the two results obtained by performing differential privacy processing on the two data respectively.
[0205] Optionally, in this embodiment, the storage medium is configured to store program code for performing the following steps: the client device receives data to be processed for differential privacy; the client device sends the data to the server; the server performs differential privacy processing on the data according to differential privacy parameters to obtain the data processing result, wherein the differential privacy parameters are determined based on the ordering and privacy of the data; the server returns the data processing result to the client device.
[0206] The sequence numbers of the above embodiments of the present invention are for descriptive purposes only and do not represent the superiority or inferiority of the embodiments.
[0207] In the above embodiments of the present invention, the descriptions of each embodiment have different focuses. For parts not described in detail in a certain embodiment, please refer to the relevant descriptions of other embodiments.
[0208] In the several embodiments provided in this application, it should be understood that the disclosed technical content can be implemented in other ways. The device embodiments described above are merely illustrative; for example, the division of units is only a logical functional division, and in actual implementation, there may be other division methods. For example, multiple units or components may be combined or integrated into another system, or some features may be ignored or not executed. Furthermore, the displayed or discussed mutual coupling, direct coupling, or communication connection may be through some interfaces; the indirect coupling or communication connection between units or modules may be electrical or other forms.
[0209] The units described as separate components may or may not be physically separate. The components shown as units may or may not be physical units; that is, they may be located in one place or distributed across multiple network units. Some or all of the units can be selected to achieve the purpose of this embodiment according to actual needs.
[0210] Furthermore, the functional units in the various embodiments of the present invention can be integrated into one processing unit, or each unit can exist physically separately, or two or more units can be integrated into one unit. The integrated unit can be implemented in hardware or as a software functional unit.
[0211] If the integrated unit is implemented as a software functional unit and sold or used as an independent product, it can be stored in a computer-readable storage medium. Based on this understanding, the technical solution of the present invention, in essence, or the part that contributes to the prior art, or all or part of the technical solution, can be embodied in the form of a software product. This computer software product is stored in a storage medium and includes several instructions to cause a computer device (which may be a personal computer, server, or network device, etc.) to execute all or part of the steps of the methods described in the various embodiments of the present invention. The aforementioned storage medium includes various media capable of storing program code, such as USB flash drives, read-only memory (ROM), random access memory (RAM), portable hard drives, magnetic disks, or optical disks.
[0212] The above description is only a preferred embodiment of the present invention. It should be noted that for those skilled in the art, several improvements and modifications can be made without departing from the principle of the present invention, and these improvements and modifications should also be considered within the scope of protection of the present invention.
Claims
1. A data processing method, characterized in that, include: Obtain the data to be processed for differential privacy; Based on the order preservation and privacy requirements of the data, determine the differential privacy parameters; The data is processed for differential privacy based on the differential privacy parameters. The differential privacy processing of the data based on the differential privacy parameters includes: The differential privacy parameters are used to perform differential privacy processing on predetermined data in the data to obtain a first processing result corresponding to the predetermined data, and the first processing result is mapped to the position corresponding to the predetermined data.
2. The method according to claim 1, characterized in that, Also includes: The data is divided into multiple first data partitions.
3. The method according to claim 2, characterized in that, Mapping the first processing result to the location corresponding to the predetermined data includes: Determine the partition of the predetermined data in the plurality of first data partitions, and the position of the data in the partitions; The first processing result is mapped to the position corresponding to the position in the partition.
4. The method according to claim 2, characterized in that, Also includes: Noise is added to the multiple first data partitions to obtain second data partitions; According to the differential privacy parameters, differential privacy processing is performed on the plurality of first data partitions respectively, and the resulting plurality of first processing results are mapped to the first result partitions corresponding to the plurality of first data partitions respectively, including: according to the differential privacy parameters, differential privacy processing is performed on the second data partitions respectively, and the resulting plurality of second processing results are mapped to the result partitions corresponding to the second data partitions respectively.
5. The method according to claim 4, characterized in that, Noise is added to the multiple first data partitions to obtain second data partitions, including: Determine the sensitivity and differential privacy parameters for the noise to be added; The noise is added to the boundaries of the plurality of first data partitions to obtain the second data partition.
6. The method according to claim 1, characterized in that, Based on the differential privacy parameters, the data undergoes differential privacy processing, including: Based on the differential privacy parameters, the data is subjected to distance-based local differential privacy processing, wherein the distance-based local differential privacy processing includes: the closer the distance between two data points, the more difficult it is to distinguish between the two results obtained by performing differential privacy processing on the two data points respectively.
7. The method according to claim 1, characterized in that, Obtain the data to be processed for differential privacy, including: Obtain the raw, continuous data to be processed for differential privacy. The original continuous data is discretized to obtain discretized data.
8. The method according to claim 7, characterized in that, Based on the differential privacy parameters, the data undergoes differential privacy processing, including: Based on the differential privacy parameters, differential privacy processing is performed on the discretized data to obtain discrete data processing results; The discrete data processing results are then subjected to continuous processing to obtain continuous data processing results.
9. The method according to any one of claims 1 to 8, characterized in that, The data includes at least one of the following: range data, quantile data, machine learning classification data, and regression data.
10. A data processing method, characterized in that, include: Display data input boxes on the interactive interface; The data to be processed for differential privacy is received in the data input box; The result output component is displayed in the interactive interface; In response to the operation of the result output component, the data processing result is displayed on the interactive interface. The data processing result performs differential privacy processing on predetermined data in the data according to differential privacy parameters to obtain a first processing result corresponding to the predetermined data. The first processing result is then mapped to the position corresponding to the predetermined data. The differential privacy parameters are determined based on the order preservation and privacy of the data.
11. A data processing method, characterized in that, include: Obtain the data to be processed for differential privacy; The data is partitioned to obtain multiple first data partitions; Differential privacy parameters are used to perform differential privacy processing on the multiple first data partitions respectively, to obtain the differential privacy processing result of the data; Specifically, differential privacy parameters are used to perform differential privacy processing on the multiple first data partitions to obtain the differential privacy processing results of the data, including: Using the differential privacy parameters, differential privacy processing is performed on the first data of the plurality of first data partitions respectively to obtain the first processing result corresponding to the first data, and the first processing result is mapped to the position corresponding to the first data.
12. The method according to claim 11, characterized in that, Mapping the first processing result to the location corresponding to the first data includes: Determine the first partition in which the first data is located among the plurality of first data partitions, and the position of the first data in the first partition, wherein the first data is any data in any one of the plurality of first data partitions; The first processing result is mapped to the position in the first result partition corresponding to the first partition where the first data is located.
13. The method according to claim 11, characterized in that, Different data partitions among the multiple first data partitions use different differential privacy parameters.
14. The method according to claim 11, characterized in that, Also includes: Noise is added to the boundaries of the plurality of first data partitions to obtain the corresponding plurality of second data partitions; Specifically, differential privacy processing is performed on the plurality of first data partitions using differential privacy parameters to obtain differential privacy processing results for the data, including: performing differential privacy processing on the plurality of second data partitions using differential privacy parameters to obtain differential privacy processing results for the data.
15. The method according to claim 14, characterized in that, Differential privacy parameters are used to perform differential privacy processing on the multiple second data partitions respectively, resulting in differential privacy processing results for the data, including: Determine the second data in the second partition where the plurality of second data partitions are located, and the position of the second data in the second partition, wherein the second data is any data in any one of the plurality of second data partitions; Using the differential privacy parameters, the second data is subjected to differential privacy processing to obtain a second processing result; The second processing result is mapped to the position in the second result partition corresponding to the second partition where the first data is located.
16. The method according to claim 14, characterized in that, The differential privacy parameters used in different data partitions among the multiple second data partitions are different.
17. The method according to any one of claims 11 to 16, characterized in that, Differential privacy parameters are used to perform differential privacy processing on the plurality of first data partitions respectively, to obtain the differential privacy processing result of the data, including: Using the differential privacy parameters, distance-based local differential privacy processing is performed on the plurality of first data partitions. The distance-based local differential privacy processing includes the following: the closer the distance between two data, the more difficult it is to distinguish between the two results obtained by performing differential privacy processing on the two data respectively.