A digital intelligent environmental sanitation data optimization storage method and device and storage medium
By calculating the feature similarity and transformation probability of smart sanitation data, constructing a probability matrix and extracting cluster centers, the problem of unreasonable data storage in smart sanitation was solved, and efficient data storage and retrieval were achieved.
Patent Information
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- GRAND BLUE URBAN ENVIRONMENT SERVICE CO LTD
- Filing Date
- 2024-08-22
- Publication Date
- 2026-07-10
AI Technical Summary
The data from smart sanitation is massive and complex, and the existing storage methods are not optimized enough, resulting in low data query efficiency.
By calculating the feature data similarity and transformation probability distribution of sample sanitation data, a probability matrix is constructed and eigenvalue decomposition is performed to extract the cluster centers of clusters, which are stored as an index structure, and similarity is calculated for retrieval during querying.
The storage of sanitation data has been optimized to improve data query efficiency, and automated classification and efficient data retrieval have been achieved.
Smart Images

Figure CN119166632B_ABST
Abstract
Description
Technical Field
[0001] This invention belongs to the technical field of data storage, and particularly relates to a digital intelligent sanitation data optimization storage method and device. Background Technology
[0002] Digitalized smart sanitation data refers to the digital processing and intelligent application of various data involved in sanitation work to improve sanitation efficiency, reduce resource waste, and support decision-making and management. The main contents of digitalized sanitation data include: Geographic Information System (GIS) data: Marking the location information of sanitation facilities, routes, garbage bins, sewage outlets, etc., on a map to provide spatial reference and resource distribution. Waste sorting data: Recording the sorting and disposal of waste by residents or businesses according to different categories, facilitating waste sorting, recycling, and resource utilization. Waste collection and transportation data: Recording information such as the routes of garbage trucks, the amount of waste collected each time, and the collection time, to facilitate the scheduling and optimization of sanitation vehicle use. Sweeping operation data: Recording information such as the work area, work time, and sweeping volume of cleaning personnel, helping to understand the completion of cleaning tasks and the allocation of human resources. Environmental monitoring data: Including monitoring data of environmental parameters such as noise, PM2.5, and air quality, used to assess the environmental impact of sanitation work and take corresponding improvement measures. Equipment operation data: Record the working status and fault information of sanitation equipment (such as garbage can compressors, sweeping robots, etc.) to facilitate equipment maintenance and management.
[0003] The sheer volume and complexity of smart sanitation data present significant challenges for its storage. Optimizing the storage of this data has become a pressing technical issue. Summary of the Invention
[0004] In view of this, embodiments of the present invention provide a method, apparatus and storage medium for optimizing the storage of digital smart sanitation data, in order to solve the technical problem of how to optimize the storage of smart sanitation data.
[0005] A first aspect of this invention provides a method for optimizing and storing digital smart sanitation data, the method comprising:
[0006] First calculation step: Calculate the feature data corresponding to the sample sanitation data, and calculate the first similarity between each of the feature data; the sample sanitation data is used to train multiple cluster centers;
[0007] The second calculation step is to calculate the transition probability distribution between each feature data based on the first similarity; the transition probability distribution refers to the probability of mutual conversion between two feature data.
[0008] First construction step: Construct a probability matrix based on the transformation probability distribution; wherein each column element is the transformation probability distribution between a single feature data and multiple other feature data;
[0009] The third calculation step is to perform eigenvalue decomposition on the probability matrix to obtain the dimensionality-reduced probability matrix.
[0010] The second construction step: Based on the probability matrix, construct a probability distribution map;
[0011] Extraction steps: Extract the clusters from the probability distribution map and calculate the cluster centers of the clusters; all nodes in the clusters are connected to one or more nodes in the cluster.
[0012] Storage steps: Use the cluster centers of the clusters as the index structure, and store the sanitation data to be stored corresponding to each cluster center in the corresponding storage area under the index structure.
[0013] Furthermore, the storage step includes:
[0014] First calculation sub-step: Calculate the second similarity between multiple cluster centers;
[0015] Judgment sub-step: If the second similarity is greater than the preset similarity, then merge the cluster centers corresponding to the second similarity to obtain merged cluster centers;
[0016] First selection sub-step: Use the merged cluster center and other cluster centers as the index structure respectively; the other cluster centers refer to the cluster centers that have not been merged;
[0017] Storage sub-step: Store the sanitation data to be stored corresponding to each cluster center into the corresponding storage area under the index structure.
[0018] Furthermore, following the storage step, the following steps are also included:
[0019] Second calculation sub-step: Obtain the query statement or query condition, and calculate the feature vector corresponding to the query statement or query condition;
[0020] The third calculation sub-step: Calculate the third similarity between the feature vector and the fused cluster centers and other cluster centers in the index structure;
[0021] Second selection sub-step: Take the storage area corresponding to the index structure of the third similarity as the target storage area;
[0022] Retrieval sub-step: In the target storage area, retrieve the target sanitation data corresponding to the query statement or query conditions.
[0023] Furthermore, the second calculation step includes:
[0024] Substituting the first similarity into the following calculation formula, the transition probability distribution between each feature data is obtained;
[0025]
[0026] Where P(ij) represents the transition probability distribution between the i-th feature data and the j-th feature data, x i and x j Let ||x| represent two feature data. i -x j || represents the first similarity between two feature data, and ∑k≠i represents the similarity after removing feature data x. i Sum all feature data except x k This represents the k-th feature data among all feature data. σ represents the average of all feature data, and σ represents the adjustment coefficient.
[0027] Furthermore, the third calculation step includes:
[0028] Fourth calculation sub-step: Calculate the covariance matrix corresponding to the probability matrix;
[0029] Fifth calculation sub-step: Perform eigenvalue decomposition on the covariance matrix to obtain multiple eigenvectors and multiple eigenvalues;
[0030] Arrangement sub-step: Arrange the multiple feature values and select the feature vectors corresponding to the first k feature values;
[0031] First construction sub-step: Construct a projection matrix from the feature vectors in order;
[0032] The sixth calculation sub-step: Multiply the probability matrix by the projection matrix to obtain the dimensionality-reduced probability matrix.
[0033] Furthermore, the extraction step includes:
[0034] Selection sub-step: Select any node in the distribution graph and obtain the current node connected to that node;
[0035] First sub-step: Obtain the subsequent nodes connected to the current node;
[0036] Repeat the sub-step: using the subsequent node as the current node, repeatedly execute the step of obtaining the subsequent nodes connected to the current node until there are no new nodes connected, thus obtaining the cluster;
[0037] The seventh calculation sub-step: Calculate the mean of the feature data in the cluster to obtain the cluster center.
[0038] Furthermore, the second construction step includes:
[0039] The second acquisition sub-step is to acquire the value of each element in the reduced probability matrix and the feature data corresponding to each element, and to construct an initial distribution graph based on the value of each element and the two feature data corresponding to each element; the nodes of the distribution graph are feature data, and the edges between the nodes are the values corresponding to the two feature data.
[0040] Filtering sub-steps: Remove edges with values below a threshold from the initial distribution graph, and remove isolated nodes from the initial distribution graph to obtain the probability distribution graph.
[0041] A second aspect of the present invention provides a digital intelligent sanitation data optimization and storage device, comprising:
[0042] The first calculation unit is used to calculate the feature data corresponding to the sample sanitation data and to calculate the first similarity between each of the feature data; the sample sanitation data is used to train multiple cluster centers.
[0043] The second calculation unit is used to calculate the transition probability distribution between each feature data based on the first similarity; the transition probability distribution refers to the probability of mutual transformation between two feature data.
[0044] The first construction unit is used to construct a probability matrix based on the transformation probability distribution; wherein each column element is the transformation probability distribution between a single feature data and multiple other feature data;
[0045] The third calculation unit is used to perform eigenvalue decomposition on the probability matrix to obtain a dimension-reduced probability matrix.
[0046] The second construction unit is used to construct a probability distribution map based on the probability matrix;
[0047] An extraction unit is used to extract clusters from the probability distribution map and calculate the cluster centers of the clusters; all nodes in the clusters are connected to one or more nodes in the cluster.
[0048] The storage unit is used to use the cluster centers of the clusters as an index structure, and to store the sanitation data to be stored corresponding to each cluster center in the corresponding storage area under the index structure.
[0049] A third aspect of the present invention provides a terminal device, including a memory, a processor, and a computer program stored in the memory and executable on the processor, wherein the processor executes the computer program to implement the steps of the method described in the first aspect.
[0050] A fourth aspect of the present invention provides a computer-readable storage medium storing a computer program that, when executed by a processor, implements the steps of the method described in the first aspect.
[0051] The beneficial effects of this invention compared to existing technologies are as follows: This invention calculates the first similarity between each of the feature data corresponding to the sample sanitation data; the sample sanitation data is used to train multiple cluster centers; based on the first similarity, the conversion probability distribution between each feature data is calculated; the conversion probability distribution refers to the probability of mutual conversion between two feature data; based on the conversion probability distribution, a probability matrix is constructed; wherein each column element is the conversion probability distribution between a single feature data and multiple other feature data; the probability matrix is decomposed into eigenvalues to obtain a dimension-reduced probability matrix; based on the probability matrix, a probability distribution graph is constructed; clusters are extracted from the probability distribution graph, and the cluster centers of the clusters are calculated; all nodes in the clusters are connected to one or more nodes in the clusters; the cluster centers of the clusters are used as an index structure, and the sanitation data to be stored corresponding to each cluster center is stored in the corresponding storage area under the index structure. In the above scheme, to classify and store different sanitation data, feature data corresponding to different sample sanitation data is calculated, and the transformation relationship between different feature data is analyzed based on the feature data. Then, based on the probability distribution map, the cluster centers of multiple clusters are calculated. Different cluster centers are used as index structures, and the sanitation data to be stored corresponding to each cluster center is stored in its respective storage area under the index structure. The above scheme realizes the automatic classification of sanitation data through feature data clustering, storing similar data in the same storage area. This not only optimizes the storage of sanitation data and improves the rationality of storage, but also improves the query efficiency in subsequent query processes. Attached Figure Description
[0052] To more clearly illustrate the technical solutions in the embodiments of the present invention, the drawings used in the description of the embodiments or related technologies will be briefly introduced below. Obviously, the drawings described below are only some embodiments of the present invention. For those skilled in the art, other drawings can be obtained based on these drawings without creative effort.
[0053] Figure 1A schematic flowchart of a digital intelligent sanitation data optimization and storage method provided by the present invention is shown;
[0054] Figure 2 This diagram illustrates a digital intelligent sanitation data optimization and storage device according to an embodiment of the present invention.
[0055] Figure 3 A schematic diagram of a terminal device provided in an embodiment of the present invention is shown. Detailed Implementation
[0056] In the following description, specific details such as particular system architectures and techniques are set forth for illustrative purposes and not for limitation, in order to provide a thorough understanding of the embodiments of the invention. However, those skilled in the art will understand that the invention can be implemented in other embodiments without these specific details. In other instances, detailed descriptions of well-known systems, apparatuses, circuits, and methods are omitted so as not to obscure the description of the invention with unnecessary detail.
[0057] This invention provides a method, apparatus, and storage medium for optimizing the storage of digital smart sanitation data, in order to solve the technical problem of how to optimize the storage of smart sanitation data.
[0058] First, this invention provides a method for optimizing and storing digital intelligent sanitation data. Please refer to [link / reference]. Figure 1 , Figure 1 A schematic flowchart of a digital intelligent sanitation data optimization and storage method provided by the present invention is shown. Figure 1 As shown, the digital intelligent sanitation data optimization and storage method may include the following steps:
[0059] First calculation step: Calculate the feature data corresponding to the sample sanitation data, and calculate the first similarity between each of the feature data; the sample sanitation data is used to train multiple cluster centers;
[0060] Due to the massive volume and complex classification of sanitation data, manual classification and storage are highly subjective and detrimental to improving subsequent data retrieval efficiency. Therefore, this application utilizes automated classification to allocate different storage spaces to different types of sanitation data. Furthermore, the cluster centers obtained from clustering can also be used in subsequent data queries, thus achieving a high degree of coordination between storage and retrieval. This not only optimizes the rationality of data storage but also improves the efficiency of subsequent data retrieval.
[0061] The sample sanitation data is artificially pre-set training data used to train cluster centers for classification. This sample sanitation data may contain all or some types of sanitation data.
[0062] For character-based sanitation sample data, key character retrieval is used to extract key characters, which are then encoded to obtain feature data (vectors) composed of multiple encoded values.
[0063] As an embodiment of this application, since there are significant differences between character-based and image-based sample sanitation data, if image-based sample sanitation data exists, it is necessary to classify and optimize the storage of character-based and image-based sample sanitation data separately. Specifically, for image-based sample sanitation data, image processing is required to extract image feature data.
[0064] Each character-type sanitation data point consists of a data group composed of multiple single-point data. For example, in a single sanitation operation, the data on the garbage truck's route includes multiple trajectory points, vehicle information, and operator details. The data on the amount of garbage collected in a single sanitation operation includes collection location points, garbage bin codes, and the quantity collected. Collection time includes multiple collection time points within a day, along with corresponding numbering and location information for each collection time point.
[0065] The first similarity between each feature data is calculated using Euclidean distance.
[0066] The second calculation step is to calculate the transition probability distribution between each feature data based on the first similarity; the transition probability distribution refers to the probability of mutual conversion between two feature data.
[0067] Transformation probability distributions are used to extract similarity features between feature data, thereby improving the data foundation for subsequent calculations. The larger the value of the transformation probability distribution, the higher the transformation probability between feature data.
[0068] Specifically, the second calculation step includes the following steps:
[0069] Substituting the first similarity into the following calculation formula, the transition probability distribution between each feature data is obtained;
[0070]
[0071] Where P(ij) represents the transition probability distribution between the i-th feature data and the j-th feature data, x i and x j Let ||x| represent two feature data. i -x j || represents the first similarity between two feature data, and ∑k≠i represents the similarity after removing feature data x. i Sum all feature data except x k This represents the k-th feature data among all feature data. Let represent the average of all feature data, and σ represent the adjustment coefficient. Smaller σ values result in a sharp transition probability distribution, while larger σ values produce a smoother transition probability distribution.
[0072] First construction step: Construct a probability matrix based on the transformation probability distribution; where each column represents the transformation probability distribution between a single feature data point and multiple other feature data points; (Construct an N×N similarity matrix P, where N is the number of data points in the dataset. The element Pij of this matrix represents the transition probability from data point Xi to Xj.)
[0073] For example, suppose the feature data are A1, A2, B1, and B2. The transition probability distribution calculated based on the feature data is A1A2, A1B1, A1B2, A2A1, A2B1, A2B2, B1A1, B1A2, B1B2, B2A1, B2A2, B2B1. A1A2 represents the transition probability from A1 to A2, and so on.
[0074] Based on the above transformation probabilities, the resulting probability matrix is as follows:
[0075] The third calculation step is to perform eigenvalue decomposition on the probability matrix to obtain the dimensionality-reduced probability matrix.
[0076] Specifically, the third calculation step includes a fourth calculation sub-step, a fifth calculation sub-step, a permutation sub-step, a first construction sub-step, and a sixth calculation sub-step:
[0077] Fourth calculation sub-step: Calculate the covariance matrix corresponding to the probability matrix;
[0078] Fifth calculation sub-step: Perform eigenvalue decomposition on the covariance matrix to obtain multiple eigenvectors and multiple eigenvalues;
[0079] Arrangement sub-step: Arrange the multiple feature values and select the feature vectors corresponding to the first k feature values;
[0080] First construction sub-step: Construct a projection matrix from the feature vectors in order;
[0081] The sixth calculation sub-step: Multiply the probability matrix by the projection matrix to obtain the dimensionality-reduced probability matrix.
[0082] For example, suppose the probability matrix is X, with n samples and m features. The dimensionality-reduced probability matrix is Y, with n samples and k principal components (features).
[0083] Each sample is a vector in the probability matrix, typically denoted as Xi, where i represents the index of the sample (1 <= i <= n). Similarly, in the reduced-dimensional probability matrix, each sample is also a vector, denoted as Yi.
[0084] The i-th row of the probability matrix represents the feature vector of the i-th sample, denoted as Xi = [x1i, x2i, ..., xmi], where j represents the index of the feature (1 <= j <= m), and xji represents the value of the i-th sample on the j-th feature.
[0085] The i-th row of the reduced probability matrix also represents the feature vector of the i-th sample, denoted as Yi = [y1i, y2i, ..., yki], where j represents the index of the reduced feature (1 <= j <= k), and yji represents the value of the i-th sample on the j-th reduced feature.
[0086] It is important to note that during dimensionality reduction, the probability matrix is mapped to the reduced-dimensional space through a projection matrix. Therefore, the feature of each sample in the reduced-dimensional probability matrix is the projection of the probability matrix into the reduced-dimensional space.
[0087] In this embodiment, the covariance matrix is calculated based on the given probability matrix. The resulting covariance matrix is then decomposed into eigenvalues, yielding multiple eigenvectors and eigenvalues. All eigenvalues are arranged in order of magnitude, and the eigenvectors corresponding to the first k eigenvalues are selected. These selected eigenvectors are then used to construct a projection matrix. The original probability matrix is multiplied by the constructed projection matrix to obtain the dimensionality-reduced probability matrix. Through these steps, the original probability matrix can be dimensionality-reduced, resulting in a new probability matrix that has undergone eigenvalue decomposition and projection transformation. The dimensionality-reduced matrix has a lower dimension than the original matrix but still retains important information, making it valuable for data analysis.
[0088] The second construction step is to construct a probability distribution graph based on the probability matrix. The probability distribution graph consists of nodes and edges between nodes, where the nodes are composed of the feature data and the edges are composed of the transformation probability distribution.
[0089] By treating the feature data as nodes and the corresponding transformation probability distribution values between nodes as edges, a probability distribution graph is obtained.
[0090] Specifically, the second construction step includes a second acquisition sub-step and a filtering sub-step:
[0091] The second acquisition sub-step is to acquire the value of each element in the reduced probability matrix and the feature data corresponding to each element, and to construct an initial distribution graph based on the value of each element and the two feature data corresponding to each element; the nodes of the distribution graph are feature data, and the edges between the nodes are the values corresponding to the two feature data.
[0092] Filtering sub-steps: Remove edges with values below a threshold from the initial distribution graph, and remove isolated nodes from the initial distribution graph to obtain the probability distribution graph.
[0093] In this embodiment, to avoid unnecessary computation, edges with values below the threshold are removed, and isolated nodes are also removed.
[0094] Extraction steps: Extract the clusters from the probability distribution map and calculate the cluster centers of the clusters; all nodes in the clusters are connected to one or more nodes in the cluster.
[0095] Traverse all nodes in the probability distribution graph, extract nodes with connections, and obtain multiple clusters.
[0096] Specifically, the extraction step includes a selection sub-step, a first acquisition sub-step, a repeated execution sub-step, and a seventh calculation sub-step:
[0097] Selection sub-step: Select any node in the distribution graph and obtain the current node connected to that node;
[0098] First sub-step: Obtain the subsequent nodes connected to the current node;
[0099] Repeat the sub-step: using the subsequent node as the current node, repeatedly execute the step of obtaining the subsequent nodes connected to the current node until there are no new nodes connected, thus obtaining the cluster;
[0100] The seventh calculation sub-step: Calculate the mean of the feature data in the cluster to obtain the cluster center.
[0101] Storage steps: Use the cluster centers of the clusters as the index structure, and store the sanitation data to be stored corresponding to each cluster center in the corresponding storage area under the index structure.
[0102] For the sanitation data to be stored, extract the feature data and calculate the distance between the feature data and multiple cluster centers. Select the target cluster center corresponding to the smallest distance and store the sanitation data to be stored in the storage area under the index structure corresponding to the target cluster center.
[0103] Specifically, the storage step includes a first calculation sub-step, a judgment sub-step, a first selection sub-step, and a storage sub-step:
[0104] First calculation sub-step: Calculate the second similarity between multiple cluster centers;
[0105] Judgment sub-step: If the second similarity is greater than the preset similarity, then merge the cluster centers corresponding to the second similarity to obtain merged cluster centers;
[0106] First selection sub-step: Use the merged cluster center and other cluster centers as the index structure respectively; the other cluster centers refer to the cluster centers that have not been merged;
[0107] Storage sub-step: Store the sanitation data to be stored corresponding to each cluster center into the corresponding storage area under the index structure.
[0108] After training and obtaining multiple cluster centers based on sample sanitation data, the sanitation data to be stored needs to be stored into the corresponding storage areas under the index structure based on these multiple cluster centers. Different cluster centers correspond to different storage areas.
[0109] In this embodiment, similar cluster centers are merged in order to improve the rationality of cluster center classification.
[0110] Optionally, after the storage step, a second calculation sub-step, a third calculation sub-step, a second selection sub-step, and a retrieval sub-step may also be included:
[0111] Second calculation sub-step: Obtain the query statement or query condition, and calculate the feature vector corresponding to the query statement or query condition;
[0112] The third calculation sub-step: Calculate the third similarity between the feature vector and the fused cluster centers and other cluster centers in the index structure;
[0113] Second selection sub-step: Take the storage area corresponding to the index structure of the third similarity as the target storage area;
[0114] Obtain the fusion cluster center or other cluster center corresponding to the third similarity, and use the storage area of the index structure corresponding to the fusion cluster center or other cluster center as the target storage area.
[0115] Retrieval sub-step: In the target storage area, retrieve the target sanitation data corresponding to the query statement or query conditions.
[0116] The above scheme can quickly generate relevant indexes by calculating the feature vectors corresponding to the query statement or query conditions. Calculating the third similarity between the feature vectors and the fused cluster centers and other cluster centers improves the accuracy of the results. The target storage area is determined based on the third similarity, avoiding invalid searches and reducing retrieval time. Optimizing the index structure can accelerate data retrieval and improve the overall system performance.
[0117] In this embodiment, a first similarity is calculated between each of the feature data corresponding to the sample sanitation data; the sample sanitation data is used to train multiple cluster centers; based on the first similarity, a transition probability distribution between each feature data is calculated; the transition probability distribution refers to the probability of mutual transformation between two feature data; a probability matrix is constructed based on the transition probability distribution; wherein each column element is the transition probability distribution between a single feature data and multiple other feature data; the probability matrix is subjected to eigenvalue decomposition to obtain a dimension-reduced probability matrix; a probability distribution graph is constructed based on the probability matrix; clusters are extracted from the probability distribution graph, and the cluster centers of the clusters are calculated; all nodes in the clusters are connected to one or more nodes in the clusters; the cluster centers of the clusters are used as an index structure, and the sanitation data to be stored corresponding to each cluster center is stored in the corresponding storage area under the index structure. In the above scheme, to classify and store different sanitation data, feature data corresponding to different sample sanitation data is calculated, and the transformation relationship between different feature data is analyzed based on the feature data. Then, based on the probability distribution map, the cluster centers of multiple clusters are calculated. Different cluster centers are used as index structures, and the sanitation data to be stored corresponding to each cluster center is stored in its respective storage area under the index structure. The above scheme realizes the automatic classification of sanitation data through feature data clustering, storing similar data in the same storage area. This not only optimizes the storage of sanitation data and improves the rationality of storage, but also improves the query efficiency in subsequent query processes.
[0118] like Figure 2 This invention provides a digital intelligent sanitation data optimization and storage device 2, please refer to [link / reference]. Figure 2 , Figure 2 The diagram shows a schematic of a digital intelligent sanitation data optimization and storage device provided by the present invention, as shown below. Figure 2 The digital smart sanitation data optimization and storage device shown includes:
[0119] The first calculation unit 21 is used to calculate the feature data corresponding to the sample sanitation data and calculate the first similarity between each of the feature data; the sample sanitation data is used to train multiple cluster centers.
[0120] The second calculation unit 22 is used to calculate the conversion probability distribution between each feature data based on the first similarity; the conversion probability distribution refers to the probability of mutual conversion between two feature data.
[0121] The first construction unit 23 is used to construct a probability matrix based on the transformation probability distribution; wherein each column element is the transformation probability distribution between a single feature data and multiple other feature data;
[0122] The third calculation unit 24 is used to perform eigenvalue decomposition on the probability matrix to obtain a dimension-reduced probability matrix.
[0123] The second construction unit 25 is used to construct a probability distribution graph based on the probability matrix; the probability distribution graph is composed of nodes and edges between nodes, the nodes are composed of the feature data, and the edges are composed of the transformation probability distribution;
[0124] Extraction unit 26 is used to extract clusters in the probability distribution map and calculate the cluster center of the clusters; all nodes in the clusters are connected to one or more nodes in the clusters.
[0125] Storage unit 27 is used to use the cluster centers of the clusters as an index structure, and to store the sanitation data to be stored corresponding to each cluster center in the corresponding storage area under the index structure.
[0126] This invention provides a digital intelligent sanitation data optimization and storage device. The device involves sending a data encryption request and destination terminal information to an encryption server from a sending end; receiving encryption information returned by the encryption server based on the destination terminal information; the encryption information including a random value and an encryption identifier; obtaining the MAC address of the destination terminal and converting it into a hexadecimal positive integer; inputting the random value and the positive integer into an encryption function based on the encryption identifier to obtain a key sequence output by the encryption function; dividing the plaintext data into multiple data blocks based on the number of keys in the key sequence; encrypting the multiple data blocks according to the key sequence to obtain multiple ciphertext data; combining the multiple ciphertext data in sequence to obtain target data, and sending the target data to the destination terminal. In this scheme, both the sending and receiving ends request the same random value from the encryption server to prevent data theft during transmission between them. Furthermore, calculating the key sequence based on the encryption identifier and the random value, dividing the data into multiple blocks, and encrypting them with different keys increases data security. Finally, the encrypted data is sequentially combined and sent to the destination terminal, thus ensuring the confidentiality and integrity of financial data during transmission. Because the process of obtaining the random value is decoupled, and the calculation of the key sequence is based on the encrypted identifier and the random value, the difficulty of deciphering the encrypted data is greatly increased, thereby enhancing the security of financial data transmission.
[0127] Figure 3 This is a schematic diagram of a terminal device provided in an embodiment of the present invention. Figure 3 As shown, a terminal device 3 in this embodiment includes: a processor 30, a memory 31, and a computer program 32 stored in the memory 31 and executable on the processor 30, such as a program for optimizing and storing digital intelligent sanitation data. When the processor 30 executes the computer program 32, it implements the steps in the various embodiments of the digital intelligent sanitation data optimization and storage method described above, for example... Figure 1 The first calculation step to the storage step is shown. Alternatively, when the processor 30 executes the computer program 32, it implements the functions of each unit in the above-described device embodiments, for example... Figure 2 The functions of units 21 to 27 are shown.
[0128] For example, the computer program 32 may be divided into one or more units, which are stored in the memory 31 and executed by the processor 30 to complete the present invention. The one or more units may be a series of computer program instruction segments capable of performing a specific function, which describe the execution process of the computer program 32 in the terminal device 3.
[0129] For example, the computer program 32 can be divided into the specific functions of each unit as follows:
[0130] The first calculation unit is used to calculate the feature data corresponding to the sample sanitation data and to calculate the first similarity between each of the feature data; the sample sanitation data is used to train multiple cluster centers.
[0131] The second calculation unit is used to calculate the transition probability distribution between each feature data based on the first similarity; the transition probability distribution refers to the probability of mutual transformation between two feature data.
[0132] The first construction unit is used to construct a probability matrix based on the transformation probability distribution; wherein each column element is the transformation probability distribution between a single feature data and multiple other feature data;
[0133] The third calculation unit is used to perform eigenvalue decomposition on the probability matrix to obtain a dimension-reduced probability matrix.
[0134] The second construction unit is used to construct a probability distribution graph based on the probability matrix; the probability distribution graph is composed of nodes and edges between nodes, the nodes are composed of the feature data, and the edges are composed of the transformation probability distribution;
[0135] An extraction unit is used to extract clusters from the probability distribution map and calculate the cluster centers of the clusters; all nodes in the clusters are connected to one or more nodes in the cluster.
[0136] The storage unit is used to use the cluster centers of the clusters as an index structure, and to store the sanitation data to be stored corresponding to each cluster center in the corresponding storage area under the index structure.
[0137] The terminal device includes, but is not limited to, a processor 30 and a memory 31. Those skilled in the art will understand that... Figure 3 This is merely an example of a terminal device 3 and does not constitute a limitation on a terminal device 3. It may include more or fewer components than shown, or combine certain components, or different components. For example, the terminal device may also include input / output devices, network access devices, buses, etc.
[0138] The processor 30 can be a Central Processing Unit (CPU), or other general-purpose processors, digital signal processors (DSPs), application-specific integrated circuits (ASICs), field-programmable gate arrays (FPGAs), or other programmable logic devices, discrete gate or transistor logic devices, discrete hardware components, etc. The general-purpose processor can be a microprocessor or any conventional processor.
[0139] The memory 31 can be an internal storage unit of the terminal device 3, such as a hard disk or memory of the terminal device 3. The memory 31 can also be an external storage device of the terminal device 3, such as a plug-in hard disk, smart media card (SMC), secure digital card (SD), flash card, etc., equipped on the terminal device 3. Furthermore, the memory 31 can include both internal and external storage units of the terminal device 3. The memory 31 is used to store the computer program and other programs and data required by the roaming control device. The memory 31 can also be used to temporarily store data that has been output or will be output.
[0140] It should be understood that the sequence number of each step in the above embodiments does not imply the order of execution. The execution order of each process should be determined by its function and internal logic, and should not constitute any limitation on the implementation process of the embodiments of the present invention.
[0141] It should be noted that the information interaction and execution process between the above-mentioned devices / units are based on the same concept as the method embodiments of the present invention. For details on their specific functions and technical effects, please refer to the method embodiments section, which will not be repeated here.
[0142] Those skilled in the art will clearly understand that, for the sake of convenience and brevity, the above-described division of functional units and modules is merely an example. In practical applications, the above functions can be assigned to different functional units and modules as needed, that is, the internal structure of the device can be divided into different functional units or modules to complete all or part of the functions described above. The functional units and modules in the embodiments 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. Furthermore, the specific names of the functional units and modules are only for easy differentiation and are not intended to limit the scope of protection of this invention. The specific working process of the units and modules in the above system can be referred to the corresponding process in the foregoing method embodiments, and will not be repeated here.
[0143] This invention also provides a computer-readable storage medium storing a computer program that, when executed by a processor, implements the steps described in the various method embodiments above.
[0144] This invention provides a computer program product that, when run on a mobile terminal, enables the mobile terminal to implement the steps described in the above-described method embodiments.
[0145] 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, all or part of the processes in the methods of the above embodiments of the present invention can be implemented by a computer program instructing related hardware. The computer program can be stored in a computer-readable storage medium, and when executed by a processor, it can implement the steps of the various method embodiments described above. The computer program includes computer program code, which can be in the form of source code, object code, executable files, or certain intermediate forms. The computer-readable medium can include at least: any entity or device capable of carrying computer program code to a photographic device / terminal device, a recording medium, a computer memory, a read-only memory (ROM), a random access memory (RAM), an electrical carrier signal, a telecommunication signal, and a software distribution medium. Examples include USB flash drives, portable hard drives, magnetic disks, or optical disks. In some jurisdictions, according to legislation and patent practice, computer-readable media cannot be electrical carrier signals or telecommunication signals.
[0146] In the above embodiments, the descriptions of each embodiment have different focuses. For parts that are not described in detail or recorded in a certain embodiment, please refer to the relevant descriptions of other embodiments.
[0147] Those skilled in the art will recognize that the units and algorithm steps of the various examples described in conjunction with the embodiments disclosed herein can be implemented in electronic hardware, or a combination of computer software and electronic hardware. Whether these functions are implemented in hardware or software depends on the specific application and design constraints of the technical solution. Those skilled in the art can use different methods to implement the described functions for each specific application, but such implementations should not be considered beyond the scope of this invention.
[0148] In the embodiments provided by this invention, it should be understood that the disclosed apparatus / network devices and methods can be implemented in other ways. For example, the apparatus / network device embodiments described above are merely illustrative. For instance, the division of modules or 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 coupling or direct coupling or communication connection shown or discussed may be through some interfaces; the indirect coupling or communication connection between devices or units may be electrical, mechanical, or other forms.
[0149] 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; they may be located in one place or distributed across multiple network units.
[0150] It should be understood that, when used in this specification and the appended claims, the term "comprising" indicates the presence of the described features, integrals, steps, operations, elements and / or components, but does not exclude the presence or addition of one or more other features, integrals, steps, operations, elements, components and / or collections thereof.
[0151] It should also be understood that the term “and / or” as used in this specification and the appended claims refers to any combination of one or more of the associated listed items and all possible combinations, and includes such combinations.
[0152] As used in this specification and the appended claims, the term "if" may be interpreted, depending on the context, as "when," "once," "in response to determination," or "in response to detection." Similarly, the phrase "if determined" or "if [the described condition or event] is detected" may be interpreted, depending on the context, as meaning "once determined," "in response to determination," "once [the described condition or event] is detected," or "in response to detection of [the described condition or event]."
[0153] Furthermore, in the description of this invention and the appended claims, the terms "first," "second," "third," etc., are used only to distinguish descriptions and should not be construed as indicating or implying relative importance.
[0154] References to "one embodiment" or "some embodiments" as described in this specification mean that one or more embodiments of the invention include a specific feature, structure, or characteristic described in connection with that embodiment. Therefore, the phrases "in one embodiment," "in some embodiments," "in other embodiments," "in still other embodiments," etc., appearing in different parts of this specification do not necessarily refer to the same embodiment, but rather mean "one or more, but not all, embodiments," unless otherwise specifically emphasized. The terms "comprising," "including," "having," and variations thereof mean "including but not limited to," unless otherwise specifically emphasized.
[0155] The above-described embodiments are only used to illustrate the technical solutions of the present invention, and are not intended to limit it. Although the present invention has been described in detail with reference to the foregoing embodiments, those skilled in the art should understand that modifications can still be made to the technical solutions described in the foregoing embodiments, or equivalent substitutions can be made to some of the technical features. Such modifications or substitutions do not cause the essence of the corresponding technical solutions to deviate from the spirit and scope of the technical solutions of the embodiments of the present invention, and should all be included within the protection scope of the present invention.
Claims
1. A method for optimizing and storing digital intelligent sanitation data, characterized in that, The digital intelligent sanitation data optimization and storage method includes: First calculation step: Calculate the feature data corresponding to the sample sanitation data, and calculate the first similarity between each of the feature data; the sample sanitation data is used to train multiple cluster centers; wherein, the sample sanitation data includes character-type sanitation data and image-type sanitation data; the character-type sanitation data and the image-type sanitation data are classified and stored respectively; The second calculation step is to calculate the transition probability distribution between each feature data based on the first similarity; the transition probability distribution refers to the probability of mutual conversion between two feature data. First construction step: Construct a probability matrix based on the transformation probability distribution; wherein, each column element is the transformation probability distribution between a single feature data and multiple other feature data, and the other feature data refers to feature data other than the single feature data; The third calculation step is to perform eigenvalue decomposition on the probability matrix to obtain the dimensionality-reduced probability matrix. The second construction step is to construct a probability distribution graph based on the probability matrix. The probability distribution graph consists of nodes and edges between nodes, where the nodes are composed of the feature data and the edges are composed of the transformation probability distribution. Extraction steps: Extract the clusters from the probability distribution map and calculate the cluster centers of the clusters; all nodes in the clusters are connected to one or more nodes in the cluster. Storage steps: Use the cluster centers of the clusters as the index structure, and store the sanitation data to be stored corresponding to each cluster center in the corresponding storage area under the index structure.
2. The digital intelligent sanitation data optimization and storage method as described in claim 1, characterized in that, The storage step includes: First calculation sub-step: Calculate the second similarity between multiple cluster centers; Judgment sub-step: If the second similarity is greater than the preset similarity, then merge the cluster centers corresponding to the second similarity to obtain merged cluster centers; First selection sub-step: Use the merged cluster center and other cluster centers as the index structure respectively; the other cluster centers refer to the cluster centers that have not been merged; Storage sub-step: Store the sanitation data to be stored corresponding to each cluster center into the corresponding storage area under the index structure.
3. The digital intelligent sanitation data optimization and storage method as described in claim 2, characterized in that, Following the storage step, the method further includes: Second calculation sub-step: Obtain the query statement or query condition, and calculate the feature vector corresponding to the query statement or query condition; The third calculation sub-step: Calculate the third similarity between the feature vector and the fused cluster centers and other cluster centers in the index structure; Second selection sub-step: Take the storage area corresponding to the index structure of the third similarity as the target storage area; Retrieval sub-step: In the target storage area, retrieve the target sanitation data corresponding to the query statement or query conditions.
4. The digital intelligent sanitation data optimization and storage method as described in claim 1, characterized in that, The second calculation step includes: Substituting the first similarity into the following calculation formula, the transition probability distribution between each feature data is obtained; ; in, This represents the transition probability distribution between the i-th feature data and the j-th feature data. and This represents two feature data. This represents the first similarity between two feature data points. This indicates the removal of feature data. Sum all feature data except those mentioned above. This represents the k-th feature data among all feature data. This represents the average of all feature data. This represents the adjustment factor.
5. The digital intelligent sanitation data optimization and storage method as described in claim 1, characterized in that, The third calculation step includes: Fourth calculation sub-step: Calculate the covariance matrix corresponding to the probability matrix; Fifth calculation sub-step: Perform eigenvalue decomposition on the covariance matrix to obtain multiple eigenvectors and multiple eigenvalues; Arrangement sub-step: Arrange the multiple feature values and select the feature vectors corresponding to the first k feature values; First construction sub-step: Construct a projection matrix from the feature vectors in order; The sixth calculation sub-step: Multiply the probability matrix by the projection matrix to obtain the dimensionality-reduced probability matrix.
6. The digital intelligent sanitation data optimization and storage method as described in claim 1, characterized in that, The extraction steps include: Selection sub-step: Select any node in the probability distribution graph and obtain the current node connected to that node; First sub-step: Obtain the subsequent nodes connected to the current node; Repeat the sub-step: using the subsequent node as the current node, repeatedly execute the step of obtaining the subsequent nodes connected to the current node until there are no new nodes connected, thus obtaining the cluster; The seventh calculation sub-step: Calculate the mean of the feature data in the cluster to obtain the cluster center.
7. The digital intelligent sanitation data optimization and storage method as described in claim 1, characterized in that, The second construction step includes: The second acquisition sub-step is to acquire the value of each element in the reduced probability matrix and the feature data corresponding to each element, and to construct an initial distribution graph based on the value of each element and the two feature data corresponding to each element; the nodes of the distribution graph are feature data, and the edges between the nodes are the values corresponding to the two feature data. Filtering sub-steps: Remove edges with values below a threshold from the initial distribution graph, and remove isolated nodes from the initial distribution graph to obtain the probability distribution graph.
8. A digital intelligent sanitation data optimization and storage device, characterized in that, The digital intelligent sanitation data optimization and storage device includes: The first calculation unit is used to calculate the feature data corresponding to the sample sanitation data and to calculate the first similarity between each of the feature data; the sample sanitation data is used to train multiple cluster centers; wherein, the sample sanitation data includes character-type sanitation data and image-type sanitation data; the character-type sanitation data and the image-type sanitation data are classified and stored respectively; The second calculation unit is used to calculate the transition probability distribution between each feature data based on the first similarity; the transition probability distribution refers to the probability of mutual transformation between two feature data. The first construction unit is used to construct a probability matrix based on the transformation probability distribution; wherein each column element is the transformation probability distribution between a single feature data and multiple other feature data, and the other feature data refers to feature data other than the single feature data; The third calculation unit is used to perform eigenvalue decomposition on the probability matrix to obtain a dimension-reduced probability matrix. The second construction unit is used to construct a probability distribution graph based on the probability matrix; the probability distribution graph is composed of nodes and edges between nodes, the nodes are composed of the feature data, and the edges are composed of the transformation probability distribution; An extraction unit is used to extract clusters from the probability distribution map and calculate the cluster centers of the clusters; all nodes in the clusters are connected to one or more nodes in the cluster. The storage unit is used to use the cluster centers of the clusters as an index structure, and to store the sanitation data to be stored corresponding to each cluster center in the corresponding storage area under the index structure.
9. A terminal device, characterized in that, The device includes: a memory, a processor, and a digital smart sanitation data optimization storage program stored in the memory and executable on the processor, the digital smart sanitation data optimization storage program being configured to implement the steps of the digital smart sanitation data optimization storage method as described in any one of claims 1 to 7.
10. A computer-readable storage medium storing a computer program, characterized in that, When the computer program is executed by the processor, it implements the steps of the digital intelligent sanitation data optimization and storage method as described in any one of claims 1 to 7.