A data processing method, device, equipment and computer readable medium
By performing feature extraction, clustering division and orthogonal basis random sampling on image data, sparse storage and high-quality reconstruction of image data are achieved, and the storage pressure problem caused by the large amount of image data is solved.
Patent Information
- Application Number
- CN202210672748.0
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2022-06-15
- Publication Date
- 2025-04-29
- Estimated Expiration
- 2042-06-15
AI Technical Summary
The amount of data in image files is huge, especially image data in uncompressed formats and compressed formats such as IPEG and GIF, which occupies too much storage space, which puts huge pressure on computer storage.
By acquiring image data, extracting image features, and performing clustering and division, the first image data and the second image data are obtained. The first image data is randomly sampled based on an orthogonal basis to obtain sparse data. The second image data and sparse data are stored, and in response to the user's call operation, data reconstruction is performed based on the sparse data, image data is restored and output.
It reduces the pressure of image data storage, reduces the storage space occupied by image data, and can reconstruct images in high quality, alleviating the problem of excessive storage pressure in storage devices.
Smart Images

Figure CN114998599B_ABST
Abstract
Description
Technical Field
[0001] The present application relates to the field of computer technology, and in particular to a data processing method, device, equipment and computer-readable medium. Background Art
[0002] As electronic modernization technology develops faster and faster, the number of electronic images is growing exponentially. The pixels on the electronic images are recorded in the form of digital codes. Image files include uncompressed formats and compressed formats such as IPEG and GIF. All image data must be stored in the electronic certificate management system. Although the image fidelity is good, the amount of data is huge, which puts tremendous pressure on computer storage.
[0003] In the process of implementing this application, the inventors found that there are at least the following problems in the prior art:
[0004] Image files include uncompressed formats as well as compressed formats such as IPEG and GIF. All image data must be stored in the certificate management system. The amount of data is huge and the images occupy too much storage space. Summary of the invention
[0005] In view of this, the embodiments of the present application provide a data processing method, apparatus, device and computer-readable medium, which can solve the problem that existing image files include uncompressed formats and compressed formats such as IPEG and GIF, all image data must be stored in the certificate management system, the data volume is huge, and the image occupies too much storage.
[0006] To achieve the above objective, according to one aspect of an embodiment of the present application, a data processing method is provided, including:
[0007] Acquire image data, and then extract image features corresponding to the image data;
[0008] Clustering the image features to obtain clusters, and then dividing the image data according to the clusters to obtain first image data and second image data;
[0009] Randomly sampling the first image data based on an orthogonal basis to obtain corresponding sparse data;
[0010] storing the second image data and the sparse data;
[0011] In response to detecting a user's calling operation on the stored second image data and sparse data, a data reconstruction process is performed based on the sparse data to obtain reconstructed first image data, which is then combined with the second image data to obtain restored image data and output.
[0012] Optionally, clustering is performed on the image features to obtain clusters, including:
[0013] The image features whose similarity in different image data exceeds a preset threshold are clustered into one category, thereby obtaining clusters.
[0014] Optionally, dividing the image data according to each cluster to obtain the first image data and the second image data includes:
[0015] Dividing the image data corresponding to each cluster into second image data;
[0016] Based on the image data and the second image data, the first image data is determined.
[0017] Optionally, randomly sampling the first image data based on an orthogonal basis to obtain corresponding sparse data includes:
[0018] Performing region division on the first image data to obtain region division data;
[0019] The region partition data is randomly sampled based on an orthogonal basis to obtain the corresponding sparse data.
[0020] Optionally, extracting image features corresponding to the image data includes:
[0021] Extract high-level and low-level features corresponding to image data.
[0022] Optionally, clustering is performed on the image features to obtain clusters, including:
[0023] Fuse high-level features with low-level features to obtain fused features;
[0024] Cluster the fused features to obtain corresponding clusters.
[0025] Optionally, high-level features and low-level features are fused to obtain fused features, including:
[0026] Obtaining a first confidence score corresponding to the high-level feature and a second confidence score corresponding to the low-level feature;
[0027] The high-level features and the low-level features are fused based on the first confidence score and the second confidence score to obtain a fused feature.
[0028] In addition, the present application also provides a data processing device, including:
[0029] An acquisition unit is configured to acquire image data and then extract image features corresponding to the image data;
[0030] An image data division unit is configured to cluster the image features to obtain clusters, and then divide the image data according to the clusters to obtain first image data and second image data;
[0031] A sampling unit, configured to perform random sampling on the first image data based on an orthogonal basis to obtain corresponding sparse data;
[0032] A storage unit configured to store the second image data and the sparse data;
[0033] The output unit is configured to, in response to detecting a user's call operation on the stored second image data and sparse data, perform a data reconstruction process based on the sparse data to obtain reconstructed first image data, and then combine it with the second image data to obtain restored image data and output it.
[0034] Optionally, the image data dividing unit is further configured to:
[0035] The image features whose similarity in different image data exceeds a preset threshold are clustered into one category, thereby obtaining clusters.
[0036] Optionally, the image data dividing unit is further configured to:
[0037] Dividing the image data corresponding to each cluster into second image data;
[0038] Based on the image data and the second image data, the first image data is determined.
[0039] Optionally, the sampling unit is further configured to:
[0040] Performing region division on the first image data to obtain region division data;
[0041] The region partition data is randomly sampled based on an orthogonal basis to obtain the corresponding sparse data.
[0042] Optionally, the acquisition unit is further configured to:
[0043] Extract high-level and low-level features corresponding to image data.
[0044] Optionally, the image data dividing unit is further configured to:
[0045] Fuse high-level features with low-level features to obtain fused features;
[0046] Cluster the fused features to obtain corresponding clusters.
[0047] Optionally, the image data dividing unit is further configured to:
[0048] Obtaining a first confidence score corresponding to the high-level feature and a second confidence score corresponding to the low-level feature;
[0049] The high-level features and the low-level features are fused based on the first confidence score and the second confidence score to obtain a fused feature.
[0050] In addition, the present application also provides a data processing device, including: one or more processors; a storage device for storing one or more programs, when the one or more programs are executed by one or more processors, the one or more processors implement the data processing method as described above.
[0051] In addition, the present application also provides a computer-readable medium on which a computer program is stored, and when the program is executed by a processor, the data processing method as described above is implemented.
[0052] To achieve the above objective, according to another aspect of the embodiments of the present application, a computer program product is provided.
[0053] A computer program product according to an embodiment of the present application includes a computer program, and when the program is executed by a processor, the data processing method provided by the embodiment of the present application is implemented.
[0054] One embodiment of the above invention has the following advantages or beneficial effects: the application obtains image data and then extracts image features corresponding to the image data; clusters the image features to obtain clusters, and then divides the image data according to the clusters to obtain first image data and second image data; randomly samples the first image data based on an orthogonal basis to obtain corresponding sparse data; stores the second image data and the sparse data; in response to detecting a user's call operation on the stored second image data and sparse data, performs a data reconstruction process based on the sparse data to obtain reconstructed first image data, and then combines the data with the second image data to obtain restored image data and output it. This reduces the storage pressure of image data and reduces the storage space occupied by image data. At the same time, images can be reconstructed with high quality, which greatly alleviates the problem of excessive storage pressure on storage devices.
[0055] The further effects of the above-mentioned non-conventional optional manner will be described below in conjunction with the specific implementation manner. BRIEF DESCRIPTION OF THE DRAWINGS
[0056] The accompanying drawings are used to better understand the present application and do not constitute an improper limitation on the present application.
[0057] Figure 1 is a schematic diagram of the main flow of a data processing method according to an embodiment of the present application;
[0058] Figure 2 is a schematic diagram of the main flow of a data processing method according to an embodiment of the present application;
[0059] Figure 3It is a main flow chart of a data processing method according to an embodiment of the present application;
[0060] Figure 4 is a schematic diagram of main units of a data processing device according to an embodiment of the present application;
[0061] Figure 5 is an exemplary system architecture diagram to which the embodiments of the present application can be applied;
[0062] Figure 6 It is a structural diagram of a computer system of a terminal device or server suitable for implementing an embodiment of the present application. DETAILED DESCRIPTION
[0063] The following is a description of exemplary embodiments of the present application in conjunction with the accompanying drawings, including various details of the embodiments of the present application to facilitate understanding, which should be considered as merely exemplary. Therefore, it should be recognized by those of ordinary skill in the art that various changes and modifications may be made to the embodiments described herein without departing from the scope and spirit of the present application. Similarly, for the sake of clarity and conciseness, the description of well-known functions and structures is omitted in the following description. The acquisition, storage, use, and processing of data in the technical solution of the present application are in compliance with the relevant provisions of national laws and regulations.
[0064] Figure 1 is a schematic diagram of the main flow of a data processing method according to an embodiment of the present application, such as Figure 1 As shown, the data processing method includes:
[0065] Step S101, acquiring image data, and then extracting image features corresponding to the image data.
[0066] In this embodiment, the execution subject of the data processing method (for example, a server) can obtain image data through a wired connection or a wireless connection. The image data can be, for example, an electronic photo. The format of the electronic photo can be a compressed format such as IPEG, GIF, etc. The execution subject can record and save the pixels in the obtained image data in the form of digital codes to realize the processing of the obtained image data.
[0067] After acquiring the image data, the execution subject can also extract the image features corresponding to the image data. Specifically, the execution subject can input the acquired image data into a feature extraction model, such as a CNN model, and use the convolution layer and pooling layer of the CNN model to extract the image features of the input image data. Image features include color features, texture features, shape features, and spatial relationship features. Among them, color features are a global feature that describes the surface properties of the scene corresponding to the image or image region; texture features are also a global feature that also describes the surface properties of the scene corresponding to the image or image region; shape features have two types of representation methods, one is contour features, and the other is regional features. The contour features of the image are mainly aimed at the outer boundaries of the object, while the regional features of the image are related to the entire shape region; spatial relationship features refer to the spatial position or relative direction relationship between multiple targets segmented from the image. These relationships can also be divided into connection / adjacency relationships, overlap / overlapping relationships, and inclusion / inclusion relationships.
[0068] Step S102: clustering the image features to obtain clusters, and then dividing the image data according to the clusters to obtain first image data and second image data.
[0069] In an embodiment of the present application, the acquired image data may include one or more images. When multiple images are included, the execution entity may compare the image features extracted from the multiple images based on color and texture, and then cluster the image features with the same or similar comparison results to obtain clusters. Then, the execution entity may divide the image data based on the clusters to obtain first image data and second image data. Specifically, the first image data may be a part of an image (for example, A1), and the second image data may be another part of the image (for example, A2, where A1+A2 may constitute a whole image).
[0070] Specifically, the image features are clustered to obtain clusters, including:
[0071] The image features whose similarity in different image data exceeds a preset threshold are clustered into one category, thereby obtaining clusters.
[0072] The execution entity can cluster similar parts of each image corresponding to the acquired image data into one category (that is, cluster image features in different images whose similarity exceeds a preset threshold into one category), and cluster dissimilar parts into another category (that is, cluster image features whose similarity is lower than a preset threshold into another category), thereby obtaining various clustering clusters.
[0073] Specifically, the image data is divided according to each cluster to obtain the first image data and the second image data, including:
[0074] The image data corresponding to each cluster is divided into second image data, that is, image data corresponding to similar parts. The image data forms a cluster, which means that there are similar parts in each image corresponding to the image data. The similar parts can be divided into second image data, and the other data in each image except the second image data is divided into first image data, that is, image data corresponding to dissimilar parts.
[0075] Based on the image data and the second image data, the first image data is determined.
[0076] The execution subject can divide each image corresponding to the acquired image data into two parts, one part is the image data corresponding to the clustering cluster, that is, the second image data, and the other part is the image data of each image except the image data corresponding to the clustering cluster, that is, the first image data.
[0077] Step S103: randomly sample the first image data based on an orthogonal basis to obtain corresponding sparse data.
[0078] Specifically, randomly sampling the first image data based on an orthogonal basis to obtain corresponding sparse data includes:
[0079] The first image data is divided into regions to obtain region division data. The execution subject can divide the image data corresponding to the dissimilar parts (i.e., the first image data) into regions to obtain each divided region (i.e., region division data). The region division data is randomly sampled based on an orthogonal basis to obtain corresponding sparse data. The orthogonal basis is the sparse basis used when applying compressed sensing to image processing, that is, when using compressed sensing theory to perform data processing on an image, the sparse basis used is an orthogonal basis, and the inner product of any two different bases in the orthogonal basis is 0, which will greatly simplify the calculation. In random sampling, random sampling using an orthogonal basis can increase sparsity and make the data more concentrated.
[0080] Compressed sensing, that is, the signal is sparse or sparse in the variation domain, and a measurement matrix that is unrelated to the sparse basis can be used to project the high-dimensional signal onto a low-dimensional space. These projections can then be used to reconstruct the original signal with high probability by solving optimization problems. Applying compressed sensing to image data processing can include the following execution steps: a. Finding a suitable sparse basis; b. Designing an incoherent sensing matrix; c. Constructing a reconstruction algorithm. Using compressed sensing can reduce the number of electronic photos collected, reduce data storage pressure, and reconstruct electronic photos with high quality, which can greatly alleviate the problem of excessive storage pressure on storage devices.
[0081] Step S104: storing the second image data and the sparse data.
[0082] After obtaining the sparse data corresponding to the first image data, the execution subject can store the second image data (that is, the image data of similar parts in each image) and the sparse data. Specifically, the storage can be done locally or in the cloud, and the storage location is not specifically limited in the embodiment of the present application.
[0083] Step S105 , in response to detecting a user's call operation on the stored second image data and sparse data, a data reconstruction process is performed based on the sparse data to obtain reconstructed first image data, which is then combined with the second image data to obtain restored image data and output.
[0084] When the execution entity detects the user's calling operation on the stored second image data and sparse data, it can indicate that the user needs to view the original image corresponding to the second image data and the sparse data. The execution entity can use the OMP algorithm to reconstruct the sparse data to obtain the corresponding first image data, and then the execution entity can splice the reconstructed first image data and the called second image data to obtain the restored image data and output it for display.
[0085] This embodiment obtains image data and then extracts image features corresponding to the image data; clusters the image features to obtain clusters, and then divides the image data according to the clusters to obtain first image data and second image data; randomly samples the first image data based on an orthogonal basis to obtain corresponding sparse data; stores the second image data and the sparse data; in response to detecting a user's call operation on the stored second image data and sparse data, performs a data reconstruction process based on the sparse data to obtain reconstructed first image data, and then combines the data with the second image data to obtain restored image data and output it. This reduces the storage pressure of image data and reduces the storage space occupied by image data. At the same time, images can be reconstructed with high quality, which greatly alleviates the problem of excessive storage pressure on storage devices.
[0086] Figure 2 is a schematic diagram of the main flow of a data processing method according to an embodiment of the present application, such as Figure 2 As shown, the data processing method includes:
[0087] Step S201, acquiring image data, and extracting high-level features and low-level features corresponding to the image data.
[0088] For example, when the image data corresponds to a face image, the high-level feature may be a face, and the low-level features may be contours, noses, eyes, etc. The execution subject may input the acquired image data into the feature extraction model to call the deep neural network in the feature extraction model to extract the high-level features, call the shallow neural network in the feature extraction model to extract the low-level features, and output the confidence score of the high-level features and the confidence score of the shallow features. The confidence score is used to characterize the credibility of the features output by the feature extraction model.
[0089] Step S202: Fusing high-level features and low-level features to obtain fused features.
[0090] The feature fusion method can comprehensively utilize high-level features and low-level features to achieve complementary advantages of multiple features and obtain more robust and accurate clustering results.
[0091] Specifically, high-level features and low-level features are fused to obtain fused features, including:
[0092] Obtain a first confidence score corresponding to the high-level feature and a second confidence score corresponding to the low-level feature; the execution entity can obtain the confidence score corresponding to the high-level feature from the output of the feature extraction model, that is, the first confidence score, and can obtain the confidence score of the low-level feature from the output of the feature extraction model, that is, the second confidence score.
[0093] The high-level features and the low-level features are fused based on the first confidence score and the second confidence score to obtain a fused feature.
[0094] The execution entity can convert high-level features into high-level feature vectors through word embedding, such as a, and use the first confidence score as the weight of the high-level feature vector, such as x1, and convert low-level features into low-level feature vectors b through word embedding, and use the second confidence score as the weight of the low-level feature vector, such as x2, to obtain a fused feature c, such as c=a*x1+b*x2, where * represents multiplication, a*x1 means the product of a and x1, and b*x2 means the product of b and x2.
[0095] Step S203: clustering the fused features to obtain corresponding clusters.
[0096] The execution subject can cluster the fused features obtained after fusion according to the similarity between the fused features, cluster the fused features whose similarity exceeds the threshold into one category, and then obtain each cluster. By clustering based on the fused features, the obtained clusters can be made more accurate, thus laying the foundation for accurate image division.
[0097] Step S204 , dividing the image data according to each cluster to obtain first image data and second image data.
[0098] The acquired image data is divided according to the clustering clusters, and each image corresponding to the image data is divided into a part that is consistent with other images and a part that is inconsistent, which are respectively called the first image data and the second image data. Among them, other images refer to images other than the currently processed image among the images corresponding to the image data. That is, the consistent parts among the images corresponding to the acquired image data are determined, and the inconsistent parts are also determined, wherein the consistent parts are called the second image data, and the inconsistent parts are called the first image data. By dividing the image data based on the clustering clusters obtained by the fusion features, the divided image data can be made more accurate.
[0099] Step S205 : randomly sampling the first image data based on an orthogonal basis to obtain corresponding sparse data.
[0100] Step S206: store the second image data and the sparse data.
[0101] Step S207, in response to detecting a user's call operation on the stored second image data and sparse data, a data reconstruction process is performed based on the sparse data to obtain reconstructed first image data, which is then combined with the second image data to obtain restored image data and output.
[0102] The embodiments of the present application can reduce the storage pressure of image data and reduce the storage space occupied by image data. At the same time, it can reconstruct images with high quality, thus alleviating the problem of excessive storage pressure on storage devices to a great extent.
[0103] Figure 3 Schematic diagram of an application scenario of a data processing method according to an embodiment of the present application. The data processing method of the embodiment of the present application can be applied to the scenario of storing images. Figure 3 As shown, in the process of storing images, many images have similar parts. First, the unchanged image parts in the image template data are fully stored in the database. For the inconsistent parts in the image, that is, the image variable data, the region is divided. Randomly sample the inconsistent parts in the image, and collect about 5% of the data. In random sampling, orthogonal bases can be used for random sampling, so as to increase sparsity and make the data obtained by random sampling more concentrated. The collected sparse data is used to store the image data. The compressed image data is reconstructed using the improved OMP algorithm to restore the image data for users to view.
[0104] The embodiment of the present application establishes a formal computer database by utilizing an electronic certificate system to store electronic photos. For similar photos, only a similar portion needs to be stored. For inconsistent portions of the image, although the amount of data stored has been reduced compared to before, random sampling can be performed using compressed sensing to further reduce the amount of data stored.
[0105] When the stored image is an electronic certificate, by taking advantage of the similarity of some electronic photos, such as ID card photos and business licenses, the similar information of the electronic photos is first stored and saved, and the dissimilar parts of the photos are stored using compressed sensing. This can greatly reduce the amount of data storage while ensuring that the photos can be restored, effectively alleviating the pressure on storage devices. With the promotion of electronic certificates, more and more electronic photos need to be stored, and higher requirements are placed on hardware facilities and storage space. In order to alleviate the storage pressure of the equipment, the similarity of some electronic photos is used to store the consistent parts of the image in full, and for the inconsistent parts, the compressed sensing method is used to reduce the amount of data to be stored again, effectively alleviating the storage pressure of the equipment.
[0106] Figure 4 Schematic diagram of the main units of the data processing device according to an embodiment of the present application. Figure 4 As shown, the data processing device 400 includes an acquisition unit 401 , an image data division unit 402 , a sampling unit 403 , a storage unit 404 and an output unit 405 .
[0107] The acquisition unit 401 is configured to acquire image data and then extract image features corresponding to the image data.
[0108] The image data division unit 402 is configured to cluster the image features to obtain clusters, and then divide the image data according to the clusters to obtain first image data and second image data.
[0109] The sampling unit 403 is configured to perform random sampling on the first image data based on an orthogonal basis to obtain corresponding sparse data.
[0110] The storage unit 404 is configured to store the second image data and the sparse data.
[0111] The output unit 405 is configured to, in response to detecting a user's call operation on the stored second image data and sparse data, perform a data reconstruction process based on the sparse data to obtain reconstructed first image data, and then combine it with the second image data to obtain restored image data and output it.
[0112] In some embodiments, the image data division unit 402 is further configured to: group image features in different image data whose similarities exceed a preset threshold into one category, thereby obtaining clusters.
[0113] In some embodiments, the image data dividing unit 402 is further configured to: divide the image data corresponding to each cluster into second image data; and determine the first image data according to the image data and the second image data.
[0114] In some embodiments, the sampling unit 403 is further configured to: perform region division on the first image data to obtain region division data; and perform random sampling on the region division data based on an orthogonal basis to obtain corresponding sparse data.
[0115] In some embodiments, the acquisition unit 401 is further configured to extract high-level features and low-level features corresponding to the image data.
[0116] In some embodiments, the image data division unit 402 is further configured to: fuse the high-level features and the low-level features to obtain fused features; and cluster the fused features to obtain corresponding clusters.
[0117] In some embodiments, the image data division unit 402 is further configured to: obtain a first confidence score corresponding to the high-level feature and a second confidence score corresponding to the low-level feature; and fuse the high-level feature and the low-level feature based on the first confidence score and the second confidence score to obtain a fused feature.
[0118] It should be noted that the data processing method and the data processing device in the present application have a corresponding relationship in terms of specific implementation content, so the repeated content will not be described again.
[0119] Figure 5 An exemplary system architecture 500 to which the data processing method or data processing device according to the embodiment of the present application can be applied is shown.
[0120] like Figure 5 As shown, system architecture 500 may include terminal devices 501, 502, 503, a network 504 and a server 505. Network 504 is used to provide a medium for communication links between terminal devices 501, 502, 503 and server 505. Network 504 may include various connection types, such as wired, wireless communication links or optical fiber cables, etc.
[0121] Users can use terminal devices 501, 502, 503 to interact with server 505 through network 504 to receive or send messages, etc. Various communication client applications can be installed on terminal devices 501, 502, 503, such as shopping applications, web browser applications, search applications, instant messaging tools, email clients, social platform software, etc. (only as examples).
[0122] The terminal devices 501 , 502 , and 503 may be various devices having a data processing screen and supporting web browsing, including but not limited to smart phones, tablet computers, laptop computers, desktop computers, and the like.
[0123] Server 505 may be a server that provides various services, such as a background management server that supports image data acquired by users using terminal devices 501, 502, and 503 (only as an example). The background management server may acquire image data, and then extract image features corresponding to the image data; cluster the image features to obtain clusters, and then divide the image data according to the clusters to obtain first image data and second image data; randomly sample the first image data based on an orthogonal basis to obtain corresponding sparse data; store the second image data and the sparse data; in response to detecting a user's call operation on the stored second image data and sparse data, perform a data reconstruction process based on the sparse data to obtain reconstructed first image data, and then combine it with the second image data to obtain restored image data and output it. This can reduce the pressure on image data storage, reduce the storage space occupied by image data, and at the same time reconstruct images with high quality, which greatly alleviates the problem of excessive storage pressure on storage devices.
[0124] It should be noted that the data processing method provided in the embodiment of the present application is generally executed by the server 505 , and accordingly, the data processing device is generally arranged in the server 505 .
[0125] It should be understood that Figure 5 The number of terminal devices, networks and servers in the embodiment is only for illustration. Any number of terminal devices, networks and servers may be provided according to implementation requirements.
[0126] Reference below Figure 6 , which shows a schematic diagram of the structure of a computer system 600 of a terminal device suitable for implementing an embodiment of the present application. Figure 6 The terminal device shown is merely an example and should not bring any limitation to the functions and scope of use of the embodiments of the present application.
[0127] like Figure 6As shown, the computer system 600 includes a central processing unit (CPU) 601, which can perform various appropriate actions and processes according to a program stored in a read-only memory (ROM) 602 or a program loaded from a storage part 608 into a random access memory (RAM) 603. In the RAM 603, various programs and data required for the operation of the computer system 600 are also stored. The CPU 601, the ROM 602, and the RAM 603 are connected to each other via a bus 604. An input / output (I / O) interface 605 is also connected to the bus 604.
[0128] The following components are connected to the I / O interface 605: an input section 606 including a keyboard, a mouse, etc.; an output section 607 including a cathode ray tube (CRT), a liquid crystal display (LCD), etc., and a speaker, etc.; a storage section 608 including a hard disk, etc.; and a communication section 609 including a network interface card such as a LAN card, a modem, etc. The communication section 609 performs communication processing via a network such as the Internet. A drive 610 is also connected to the I / O interface 605 as needed. A removable medium 611, such as a magnetic disk, an optical disk, a magneto-optical disk, a semiconductor memory, etc., is installed on the drive 610 as needed, so that a computer program read therefrom is installed into the storage section 608 as needed.
[0129] In particular, according to the embodiments disclosed in the present application, the process described above with reference to the flowchart can be implemented as a computer software program. For example, the embodiments disclosed in the present application include a computer program product, which includes a computer program carried on a computer-readable medium, and the computer program includes a program code for executing the method shown in the flowchart. In such an embodiment, the computer program can be downloaded and installed from the network through the communication part 609, and / or installed from the removable medium 611. When the computer program is executed by the central processing unit (CPU) 601, the above-mentioned functions defined in the system of the present application are executed.
[0130] It should be noted that the computer-readable medium shown in the present application may be a computer-readable signal medium or a computer-readable storage medium or any combination of the above two. Computer-readable storage media may include, for example, but are not limited to electrical, magnetic, optical, electromagnetic, infrared, or semiconductor systems, devices or devices, or any combination of the above. More specific examples of computer-readable storage media may include, but are not limited to: an electrical connection with one or more wires, a portable computer disk, a hard disk, a random access memory (RAM), a read-only memory (ROM), an erasable programmable read-only memory (EPROM or flash memory), an optical fiber, a portable compact disk read-only memory (CD-ROM), an optical storage device, a magnetic storage device, or any suitable combination of the above. In the present application, a computer-readable storage medium may be any tangible medium containing or storing a program that can be used by or in combination with an instruction execution system, device or device. In the present application, a computer-readable signal medium may include a data signal propagated in a baseband or as part of a carrier wave, in which a computer-readable program code is carried. This propagated data signal may take a variety of forms, including but not limited to electromagnetic signals, optical signals, or any suitable combination of the above. Computer-readable signal media may also be any computer-readable medium other than computer-readable storage media, which may send, propagate or transmit a program for use by or in conjunction with an instruction execution system, apparatus or device. The program code contained on the computer-readable medium may be transmitted using any appropriate medium, including but not limited to: wireless, wire, optical cable, RF, etc., or any suitable combination of the above.
[0131] The flow chart and block diagram in the accompanying drawings illustrate the possible architecture, function and operation of the system, method and computer program product according to various embodiments of the present application. In this regard, each box in the flow chart or block diagram can represent a module, a program segment or a part of a code, and the above-mentioned module, program segment or a part of a code contains one or more executable instructions for realizing the specified logical function. It should also be noted that in some alternative implementations, the functions marked in the box can also occur in a different order from the order marked in the accompanying drawings. For example, two boxes represented in succession can actually be executed substantially in parallel, and they can sometimes be executed in the opposite order, depending on the functions involved. It should also be noted that each box in the block diagram or flow chart, and the combination of the boxes in the block diagram or flow chart can be implemented with a dedicated hardware-based system that performs a specified function or operation, or can be implemented with a combination of dedicated hardware and computer instructions.
[0132] The units involved in the embodiments described in the present application may be implemented by software or hardware. The units described may also be set in a processor, for example, it may be described as: a processor includes an acquisition unit, an image data division unit, a sampling unit, a storage unit, and an output unit. The names of these units do not, in some cases, constitute limitations on the units themselves.
[0133] As another aspect, the present application also provides a computer-readable medium, which may be included in the device described in the above embodiment; or it may exist independently and not be assembled into the device. The above computer-readable medium carries one or more programs, and when the above one or more programs are executed by a device, the device acquires image data, and then extracts image features corresponding to the image data; clusters the image features to obtain clusters, and then divides the image data according to the clusters to obtain first image data and second image data; randomly samples the first image data based on an orthogonal basis to obtain corresponding sparse data; stores the second image data and the sparse data; in response to detecting a user's call operation on the stored second image data and sparse data, performs a data reconstruction process based on the sparse data to obtain the reconstructed first image data, and then combines it with the second image data to obtain the restored image data and outputs it.
[0134] The computer program product of the present application includes a computer program, and the computer program implements the data processing method in the embodiment of the present application when executed by a processor.
[0135] According to the technical solution of the embodiment of the present application, the storage pressure of image data can be reduced, the storage space occupied by image data can be reduced, and at the same time, the image can be reconstructed with high quality, thereby greatly alleviating the problem of excessive storage pressure on storage devices.
[0136] The above specific implementations do not constitute a limitation on the protection scope of this application. It should be understood by those skilled in the art that various modifications, combinations, sub-combinations and substitutions may occur depending on design requirements and other factors. Any modifications, equivalent substitutions and improvements made within the spirit and principles of this application should be included in the protection scope of this application.
Claims
1. A data processing method, characterized in that: include: Acquire image data, and then extract image features corresponding to the image data; Clustering the image features to obtain clusters, and then dividing the image data according to the clusters to obtain first image data and second image data; wherein the image data corresponding to each cluster is divided into second image data, and the image data corresponding to each cluster is image data corresponding to similar parts; and the other data in each image except the second image data is divided into first image data; Randomly sampling the first image data based on an orthogonal basis to obtain corresponding sparse data; storing the second image data and the sparse data; In response to detecting a user's calling operation on the stored second image data and the sparse data, a data reconstruction process is performed based on the sparse data to obtain reconstructed first image data, which is then combined with the second image data to obtain restored image data and output.
2. The method according to claim 1, characterized in that The clustering of the image features to obtain clusters includes: The image features whose similarity in different image data exceeds a preset threshold are clustered into one category, thereby obtaining clusters.
3. The method according to claim 1, characterized in that The dividing the image data according to the clusters to obtain the first image data and the second image data includes: Dividing the image data corresponding to each cluster into second image data; First image data is determined based on the image data and the second image data.
4. The method according to claim 1, characterized in that The randomly sampling the first image data based on an orthogonal basis to obtain corresponding sparse data includes: Performing region division on the first image data to obtain region division data; The region division data is randomly sampled based on an orthogonal basis to obtain corresponding sparse data.
5. The method according to claim 1, characterized in that The extracting the image features corresponding to the image data includes: Extract high-level features and low-level features corresponding to the image data.
6. The method according to claim 5, characterized in that The clustering of the image features to obtain clusters includes: Fusing the high-level features with the low-level features to obtain fused features; The fused features are clustered to obtain corresponding clusters.
7. The method according to claim 6, characterized in that The fusing the high-level features and the low-level features to obtain fused features includes: Obtaining a first confidence score corresponding to the high-level feature and a second confidence score corresponding to the low-level feature; The high-level features and the low-level features are fused based on the first confidence score and the second confidence score to obtain a fused feature.
8. A data processing device, characterized in that: include: an acquisition unit, configured to acquire image data and then extract image features corresponding to the image data; The image data division unit is configured to cluster the image features to obtain clusters, and then divide the image data according to the clusters to obtain first image data and second image data; wherein the image data corresponding to each cluster is divided into second image data, and the image data corresponding to each cluster is image data corresponding to similar parts; and the other data in each image except the second image data is divided into first image data; A sampling unit, configured to perform random sampling on the first image data based on an orthogonal basis to obtain corresponding sparse data; a storage unit configured to store the second image data and the sparse data; The output unit is configured to, in response to detecting a user's call operation on the stored second image data and the sparse data, perform a data reconstruction process based on the sparse data to obtain reconstructed first image data, and then combine it with the second image data to obtain restored image data and output it.
9. The device according to claim 8, characterized in that The image data dividing unit is further configured to: The image features whose similarity in different image data exceeds a preset threshold are clustered into one category, thereby obtaining clusters.
10. The device according to claim 8, characterized in that The image data dividing unit is further configured to: Dividing the image data corresponding to each cluster into second image data; First image data is determined based on the image data and the second image data.
11. The device according to claim 8, characterized in that The sampling unit is further configured to: Performing region division on the first image data to obtain region division data; The region division data is randomly sampled based on an orthogonal basis to obtain corresponding sparse data.
12. The device according to claim 8, characterized in that The acquisition unit is further configured to: Extract high-level features and low-level features corresponding to the image data.
13. The device according to claim 12, characterized in that The image data dividing unit is further configured to: Fusing the high-level features with the low-level features to obtain fused features; The fused features are clustered to obtain corresponding clusters.
14. A data processing device, characterized in that: include: one or more processors; a storage device for storing one or more programs, When the one or more programs are executed by the one or more processors, the one or more processors implement the method according to any one of claims 1 to 7.
15. A computer readable medium having a computer program stored thereon, characterized in that: When the program is executed by a processor, the method according to any one of claims 1 to 7 is implemented.
16. A computer program product comprising a computer program, characterized in that When the computer program is executed by a processor, the method according to any one of claims 1 to 7 is implemented.
Citation Information
Patent Citations
Image denoising method and image denoising device
CN103186885A
Systems and Methods for Homogenization of Disparate Datasets
US20220059190A1