CN110262925B - Remote backup method, device, terminal equipment and medium for pictures - Google Patents

Remote backup method, device, terminal equipment and medium for pictures Download PDF

Info

Publication number
CN110262925B
CN110262925B CN201910379833.6A CN201910379833A CN110262925B CN 110262925 B CN110262925 B CN 110262925B CN 201910379833 A CN201910379833 A CN 201910379833A CN 110262925 B CN110262925 B CN 110262925B
Authority
CN
China
Prior art keywords
picture
pictures
target
preset
component
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Active
Application number
CN201910379833.6A
Other languages
Chinese (zh)
Other versions
CN110262925A (en
Inventor
彭捷
郭海峰
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Ping An Technology Shenzhen Co Ltd
Original Assignee
Ping An Technology Shenzhen Co Ltd
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Ping An Technology Shenzhen Co Ltd filed Critical Ping An Technology Shenzhen Co Ltd
Priority to CN201910379833.6A priority Critical patent/CN110262925B/en
Publication of CN110262925A publication Critical patent/CN110262925A/en
Priority to PCT/CN2019/118540 priority patent/WO2020224225A1/en
Application granted granted Critical
Publication of CN110262925B publication Critical patent/CN110262925B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F11/00Error detection; Error correction; Monitoring
    • G06F11/07Responding to the occurrence of a fault, e.g. fault tolerance
    • G06F11/14Error detection or correction of the data by redundancy in operation
    • G06F11/1402Saving, restoring, recovering or retrying
    • G06F11/1446Point-in-time backing up or restoration of persistent data
    • G06F11/1448Management of the data involved in backup or backup restore
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L67/00Network arrangements or protocols for supporting network services or applications
    • H04L67/01Protocols
    • H04L67/06Protocols specially adapted for file transfer, e.g. file transfer protocol [FTP]

Landscapes

  • Engineering & Computer Science (AREA)
  • Theoretical Computer Science (AREA)
  • Computer Networks & Wireless Communication (AREA)
  • Signal Processing (AREA)
  • Quality & Reliability (AREA)
  • Physics & Mathematics (AREA)
  • General Engineering & Computer Science (AREA)
  • General Physics & Mathematics (AREA)
  • Information Retrieval, Db Structures And Fs Structures Therefor (AREA)
  • Information Transfer Between Computers (AREA)

Abstract

The invention is suitable for the technical field of data processing, and provides a remote backup method, a device, terminal equipment and a medium for pictures, wherein the pictures with the definition not less than a definition threshold value are used as effective pictures by calculating the definition of the pictures stored in the terminal equipment; combining the effective pictures with the generation time interval smaller than the preset time interval into a picture set according to the generation time of each effective picture; calculating the similarity of every two pictures in the picture set, and determining redundant pictures based on the similarity; taking pictures except the redundant pictures as target pictures; taking an application program for generating the target picture as a target application program and calling a preset level of each target application program; and decomposing a target picture generated by a target application program with a preset grade higher than a preset grade threshold into a plurality of target picture components, and uploading each target picture component of the same target picture to different remote servers for backup so as to reduce the data volume of remote storage and ensure the data security.

Description

Remote backup method, device, terminal equipment and medium for pictures
Technical Field
The invention belongs to the technical field of data processing, and particularly relates to a remote picture backup method, device, terminal equipment and medium.
Background
In daily life, pictures taken or downloaded by people through mobile terminals are generally stored in a local memory, and in some cases, in order to avoid the problem of picture loss caused by the loss, damage and the like of the mobile terminals, many mobile terminals upload the locally stored pictures to a remote server so as to remotely backup the pictures.
However, the pictures stored in mobile terminals often contain many blurred or redundant pictures, for example: blurred pictures due to false shots, or groups of similar pictures taken in one background, etc. Obviously, uploading all pictures stored in the mobile terminal to the far-field server causes unnecessary storage resource waste, and simultaneously causes the problem of low storage efficiency. On the other hand, remote backup of photos also presents the risk of being stolen and intercepted by hackers or by personnel inside the server.
Disclosure of Invention
In view of the above, the embodiments of the present invention provide a method, an apparatus, a terminal device, and a medium for remote backup of pictures, so as to solve the problems of storage resource waste and poor security in the remote backup process in the prior art.
A first aspect of an embodiment of the present invention provides a remote backup method for a picture, including:
calculating the definition of the pictures stored in the terminal equipment, and setting the pictures with the definition not smaller than a preset definition threshold as effective pictures; distributing the effective pictures generated in a preset time period to more than one picture set according to the generation time of each effective picture, wherein the time interval of the generation time of each effective picture is smaller than the preset time interval in each picture set containing more than two effective pictures; calculating the similarity of every two pictures in each picture set, determining redundant pictures in each picture set based on the similarity, and taking pictures except the redundant pictures generated in the preset time period as target pictures; taking the application program generating each target picture as a target application program corresponding to each target picture, and calling a preset grade of each target application program; and decomposing the target picture generated by the target application program with the preset grade higher than the preset grade threshold into a plurality of target picture components, and respectively uploading each target picture component of the same target picture to a plurality of different remote servers for backup.
A second aspect of an embodiment of the present invention provides a remote backup apparatus for a picture, including:
the computing module is used for computing the definition of the pictures stored in the terminal equipment and setting the pictures with the definition not smaller than a preset definition threshold value as effective pictures; the combination module is used for distributing the effective pictures generated in a preset time period to more than one picture set according to the generation time of each effective picture, wherein the time interval of the generation time of each effective picture is smaller than the preset time interval in each picture set containing more than two effective pictures; the deleting and repeating module is used for calculating the similarity of every two pictures in each picture set, determining redundant pictures in each picture set based on the similarity, and taking pictures except the redundant pictures generated in the preset time period as target pictures; the calling module is used for taking the application program for generating each target picture as a target application program corresponding to each target picture and calling the preset grade of each target application program; and the backup module is used for decomposing the target picture generated by the target application program with the preset grade higher than the preset grade threshold into a plurality of target picture components and uploading each target picture component of the same target picture to a plurality of different remote servers for backup.
A third aspect of an embodiment 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, characterized in that the processor implements the steps of the method provided by the first aspect of the embodiments of the invention when the computer program is executed by the processor.
A fourth aspect of the embodiments of the present invention provides a computer readable storage medium storing a computer program, characterized in that the computer program when executed by a processor implements the steps of the method provided by the first aspect of the embodiments of the present invention.
In the embodiment of the invention, the definition of the picture stored in the terminal equipment is calculated, and the picture with the definition not smaller than the preset definition threshold is set as the effective picture, so that the resource waste caused by carrying out remote backup on the blurred picture in the subsequent process is avoided; distributing the effective pictures generated in a preset time period to more than one picture set according to the generation time of each effective picture, calculating the similarity of every two pictures in each picture set, and determining redundant pictures in each picture set based on the similarity, so that the redundant pictures are more rapidly selected, and more useless similarity calculation is avoided; taking pictures except the redundant pictures, which are stored in the terminal equipment and have the generation time within the preset time period, as target pictures; taking the application program generating each target picture as a target application program corresponding to each target picture, and calling a preset grade of each target application program; the target picture generated by the target application program with the preset grade higher than the preset grade threshold is decomposed into a plurality of target picture components, and each target picture component of the same target picture is respectively uploaded to a plurality of different remote servers for backup, so that when the target picture component stored in part of the remote servers is stolen, a pirate cannot recover the target picture.
Drawings
In order to more clearly illustrate the technical solutions of the embodiments of the present invention, the drawings that are needed in the embodiments or the description of the prior art will be briefly described below, it being obvious that the drawings in the following description are only some embodiments of the present invention, and that other drawings may be obtained according to these drawings without inventive effort for a person skilled in the art.
Fig. 1 is a flowchart of an implementation of a remote backup method of pictures provided by an embodiment of the present invention;
fig. 2 is a flowchart of a specific implementation of a remote picture backup method S105 according to an embodiment of the present invention;
fig. 3 is a flowchart of a specific implementation of a remote backup method S106 of a picture provided by an embodiment of the present invention;
fig. 4 is a block diagram of a remote backup apparatus for pictures according to an embodiment of the present invention;
fig. 5 is a schematic diagram of a terminal device according to an embodiment of the present invention.
Detailed Description
In the following description, for purposes of explanation and not limitation, specific details are set forth such as the particular system architecture, techniques, etc., in order to provide a thorough understanding of the embodiments of the present invention. It will be apparent, however, to one skilled in the art that the present invention may be practiced in other embodiments that depart from these specific details. In other instances, detailed descriptions of well-known systems, devices, circuits, and methods are omitted so as not to obscure the description of the present invention with unnecessary detail.
In order to illustrate the technical scheme of the invention, the following description is made by specific examples.
Fig. 1 shows an implementation flow of a remote backup method of pictures provided by an embodiment of the present invention, where the method flow includes steps S101 to S107. The specific implementation principle of each step is as follows.
In S101, the sharpness of the picture stored in the terminal device is calculated, and the picture whose sharpness is not less than a preset sharpness threshold is set as a valid picture.
It will be appreciated that in everyday life, the terminal device may take pictures, which are generally very blurred and useless to the user, without the user noticing, due to the user's mishandling; the user may also in some cases download a number of photos in bulk from the web page, and there may be some very blurred photos in these photos. Obviously, if the user performs remote backup on the pictures stored in the terminal device, if the blurred pictures are also subjected to remote backup, the storage resources of the remote server are wasted.
For the above reasons, in the embodiment of the present invention, it is necessary to first calculate the sharpness of the picture, set the picture with sharpness not less than the preset sharpness threshold as an effective picture, and set the picture with sharpness less than the preset sharpness threshold as an ineffective picture.
Optionally, the step of specifically calculating the sharpness of the picture stored in the terminal device includes:
step 1, converting the picture into a gray image, and sharpening the gray image to generate a sharpened image corresponding to the picture.
Specifically, in general, the picture stored in the terminal device is a color picture, and in order to facilitate subsequent calculation, it is necessary here to first convert the color picture (a picture containing 3 channels (RGB)) into a grayscale picture (a picture containing 1 channel). Alternatively, an average value of the RGB values of 3 channels corresponding to each pixel point in the color picture may be calculated and used as the gray value of each pixel point, so as to convert the picture stored in the terminal device into a gray image.
Further, the gray level image is sharpened through a preset image sharpening program, and a sharpened image is generated, so that the outline in the gray level image is more highlighted, and the situation that the picture which is not clear enough but basically identifiable is set as an invalid picture is avoided. Alternatively, the grayscale image may be sharpened using an OpenCV computer vision library.
And 2, calculating the standard deviation of gray values corresponding to all pixel points in the sharpened image corresponding to the picture, and taking the standard deviation as the definition of the picture.
It will be appreciated that the standard deviation of a set of data may be used to reflect the degree of differentiation of the set of data, and thus the standard deviation of the gray values corresponding to the individual pixels in the sharpened image may reflect the overall degree of differentiation of the individual pixels in the sharpened image. In the embodiment of the invention, if the standard deviation is too small, the difference among objects contained in the picture stored in the terminal equipment after sharpening is still too small, and the picture is obviously blurred, so that the picture can be judged as an invalid picture in the subsequent process.
In S102, according to the generation time of each effective picture, the effective pictures generated in the preset time period are distributed to more than one picture set, where in each picture set containing more than two effective pictures, the time interval of the generation time of each effective picture is smaller than the preset time interval.
It will be appreciated that during the photographing of a user, there may be situations where a continuous shot occurs, and when the user downloads pictures from a web page, it is also possible to download a plurality of very similar pictures. Obviously, for the above situation, if all the valid photos are uploaded when the remote backup is performed on the pictures in the terminal device, there still exists a problem of wasting storage resources of the remote server.
Based on the above reasons, after the effective pictures are screened out according to the definition of the pictures, the embodiment of the invention also needs to further screen the effective pictures from the dimension of the similarity of the effective pictures, so that one picture is screened out from each group of repeated or very high-similarity effective pictures to carry out uploading backup, thereby reducing the uploaded data volume, improving the uploading speed and saving the storage space of a remote server.
Notably, since the terminal device may generate a large number of pictures within the preset time period, if the similarity between the two pictures generated within the preset time period is calculated separately, the calculation amount may be very large, which may seriously affect the calculation efficiency of the terminal device. Therefore, in the embodiment of the invention, the pictures with higher similarity are basically generated by continuous shooting or continuous downloading, so that the generation time interval of the pictures with higher similarity is often small. Therefore, in an embodiment of the present invention, an aggregation calculation is first performed based on this principle. The method for aggregation calculation comprises the following steps: and distributing the effective pictures generated in the preset time period to more than one picture set according to the generation time of each effective picture, wherein the time interval of the generation time of each effective picture is smaller than the preset time interval in each picture set containing more than two effective pictures.
Illustratively, valid pictures generated within 6 hours are allocated to a plurality of picture sets, and it is ensured that if one picture set contains more than 2 valid pictures, the interval of the generation time of every two valid pictures in the picture set is less than 5 seconds. It can be appreciated that in the subsequent calculation, only the similarity of the effective pictures in each pair in one picture set needs to be calculated, and the similarity of the effective pictures in each pair contained in different picture sets does not need to be calculated, so that the calculation amount about the similarity is greatly reduced.
In S103, calculating the similarity of every two pictures in each picture set, determining a redundant picture in each picture set based on the similarity, and taking the pictures generated in the preset time period and except for the redundant picture as target pictures.
Specifically, in the embodiment of the invention, according to the RGB value of each pixel point in each picture, a feature matrix representing the picture is generated, and the similarity of the feature matrix corresponding to every two pictures is calculated as the similarity of every two pictures by using a Euclidean distance calculation formula, a cosine similarity formula or other picture similarity calculation formulas.
Notably, as described above, the embodiment of the present invention only calculates the similarity of every two pictures in each picture set, but does not calculate the similarity of every two pictures in different picture sets, so that the calculation amount of the similarity can be greatly reduced.
Optionally, taking a plurality of pictures with similarity higher than a preset similarity threshold value in each picture set as a subset; and selecting one picture with highest definition from each subset, and taking the picture which is not selected in the subset as the redundant picture.
It can be understood that, assuming that the similarity of some pictures in a picture set is very high, in order to save the storage resource of a remote server, the embodiment of the invention only selects one picture from the pictures with very high similarity to upload, so that the related information shot by a user is not lost, and the uploaded data volume can be reduced to the maximum extent.
In S104, the application program that generates each target picture is taken as the target application program corresponding to each target picture, and the preset level of each target application program is called.
It can be understood that, the remote backup of the picture may have a risk of losing data, and the importance or sensitivity of the pictures generated (including shooting or downloading) by different application programs in the embodiment of the present invention is different, so that the embodiment of the present invention presets a preset level for the application program that can generate the picture, so that in a subsequent process, the importance level of the picture generated by the application program can be determined according to the preset level of the application program.
Alternatively, the preset level of the application program may be set manually by a user, or may be set automatically by the terminal device. If the terminal equipment is automatically set, the terminal equipment sets the preset level of the application program carried by the operating system when leaving the factory to be higher level, and sets the application program downloaded and installed by the user later to be lower level.
In S105, the target picture generated by the target application program with the preset level higher than the preset level threshold is decomposed into a plurality of target picture components.
Notably, in the conventional method for ensuring that the picture is not stolen and leaked, encryption processing is often performed on the picture, but the encrypted picture still has the risk of being cracked after being entirely stolen. Particularly, when an internal person of a server steals an encrypted picture, the encrypted picture is easy to decipher because the encrypted picture is familiar with the terminal equipment and the encryption algorithm used by the server.
Therefore, in the embodiment of the invention, a plurality of remote servers are often present in a distributed system in the remote backup process, and one target picture can be actually decomposed for a plurality of times to generate a plurality of target picture components, and when only part of target picture components are intercepted, a interceptor can not actually recognize the information of the original target picture, so that the target picture is decomposed and then stored in a distributed manner, thereby being beneficial to ensuring that the information contained in the target picture is not recognized and understood by a pirate after the target picture is stolen, and further ensuring the safety of remote backup. After the user needs to download the previous backup target picture through the terminal equipment, downloading each target picture component according to the IDs of different target pictures, and further reconstructing the target picture components through a picture reconstruction technology, so as to generate a target picture.
As an embodiment of the present invention, as shown in fig. 2, the step S105 includes:
s1051, decomposing the target picture generated by the target application program with the preset grade higher than the preset grade threshold into a plurality of high-frequency picture components of the first layer and 1 low-frequency picture component of the first layer through a discrete wavelet transform algorithm.
Optionally, the target image is decomposed by a haar wavelet transform algorithm, and since this step is the first decomposition of the target image, a high-frequency picture component in the horizontal direction, a high-frequency picture component in the vertical direction, a high-frequency picture component in the diagonal direction, and 1 low-frequency picture component of the first layer are generated.
S1052, starting from the low-frequency picture component of the first layer, repeatedly performing a decomposition operation for a preset number of times, where the decomposition operation includes: the low-frequency picture component of the upper layer is decomposed into a plurality of high-frequency picture components of the lower layer and 1 low-frequency picture component of the lower layer through a discrete wavelet transform algorithm.
Alternatively, assuming that the preset number of times is 2, the decomposition is performed 2 times again on the basis of the low-frequency picture components of the first layer generated in S1051, and the high-frequency picture components and the low-frequency picture components of the third layer and the fourth layer are generated.
And S1053, taking the high-frequency picture component and the low-frequency picture component of each layer as the target picture component.
It can be understood that the high-frequency image component includes high-frequency information of the edge of the object in the target image, and the low-frequency image component includes information of a portion of the target image with gentle change, so that any one target image component only includes partial information in the target image, and in the remote backup process, even if some target image components are intercepted, the interceptor cannot recognize the complete information of the target image.
In S106, each target picture component of the same target picture is uploaded to a plurality of different remote servers for backup.
Notably, any of the target picture components in the embodiments of the present invention has a corresponding picture ID, a decomposition category, and a decomposition level, where the decomposition category is used to indicate whether the target picture component is a low frequency picture component or a high frequency picture component, the decomposition level is used to indicate at which level (e.g., a first layer, a second layer, etc.) the target picture component is generated during the decomposition of the target picture, and the picture ID is used to indicate from which target picture the target picture component is decomposed.
Optionally, in the embodiment of the present invention, when the target image components are uploaded to a plurality of different remote servers for backup, the image ID, the decomposition type and the decomposition level of each target image component are uploaded to the remote servers together, so that it is ensured that when the terminal device needs to restore the image, after downloading each target image component, the target image is restored by reconstructing the image ID, the decomposition type and the decomposition level of each target image component.
It can be appreciated that there is still a certain security risk of uploading the target picture component after it is marked with its corresponding picture ID, decomposition category and decomposition level directly. For example, the information content of the target picture is relatively simple, or the interceptor intercepts or steals a large number of target picture components stored in a plurality of remote servers at a time, so that the target picture can still be reconstructed or restored according to the picture ID, the decomposition category and the decomposition level of the stolen target picture components. In order to solve this problem, the embodiment of the present invention further provides another implementation flow of S106, as shown in fig. 3, which is described in detail as follows:
s1061, determining a decomposition category and a decomposition level corresponding to each target picture component, where the decomposition category is used to indicate that the target picture component is the low-frequency picture component or the high-frequency picture component, and the decomposition level is used to indicate the level of the target picture component when the target picture component is generated in the decomposition process of the target picture.
As described above, the description of the decomposition category and the decomposition level corresponding to the target picture component has been detailed above.
S1062, searching watermark data corresponding to each target picture component according to the decomposition category and the decomposition level of each target picture component through the corresponding relation among the preset decomposition level, the decomposition category and the watermark data.
In the embodiment of the invention, after knowing the decomposition level and the decomposition category corresponding to a target picture component, watermark data corresponding to the target picture component can be determined according to a preset corresponding relation.
Notably, when determining watermark data corresponding to a target picture component, the embodiments of the present invention will not refer to the picture ID of the target picture component, because the number of picture IDs is too large, and different watermark data cannot be generated according to different picture IDs.
And S1063, adding corresponding watermark data for each target picture component, generating watermark picture components, and uploading each watermark picture component to different remote servers for backup.
Obviously, when uploading a watermark picture component, the watermark picture component is marked according to a picture ID corresponding to a target picture component for generating the watermark picture component, so that when reconstructing a target picture in the future, the watermark picture component is judged to be used for reconstructing which target picture.
It can be appreciated that in this way, on the one hand, watermark data in the downloaded watermark picture component can be verified when the target picture is reconstructed in the future, so as to determine whether the watermark picture component is tampered with in the remote server; on the other hand, after watermark data is extracted from the watermark picture component, the decomposition level and the decomposition category corresponding to the watermark picture component are determined according to the preset correspondence between the decomposition level, the decomposition category and the watermark data, and then the target picture can be reconstructed.
Notably, by adding watermark data to the target picture component and establishing a corresponding relation between the watermark data and the decomposition level and the decomposition type, even if a hacker or a person in the server intercepts all watermark picture components, under the condition that the corresponding relation between the watermark data and the decomposition level and the decomposition type is not known, whether each watermark picture component specifically represents a low-frequency picture component or a high-frequency picture component cannot be clearly determined, and whether the watermark picture component is the data corresponding to the picture component generated in the decomposition process cannot be determined, so that a plurality of watermark picture components cannot be accurately reconstructed after the watermark data is removed, a target picture cannot be generated, and the information in the target picture cannot be leaked.
In S107, the target picture generated by the target application program with the preset level not higher than the preset level threshold is directly uploaded to the remote server.
It can be understood that, assuming that the preset level of a target application program is low, the sensitivity of the generated target pictures is low, so as to reduce the calculation amount of the terminal device, the target pictures are not decomposed and are directly uploaded to a remote server for backup.
In the embodiment of the invention, the picture with the definition not smaller than the definition threshold value is used as the effective picture by calculating the definition of the picture stored in the terminal equipment; combining the effective pictures with the generation time interval smaller than the preset time interval into a picture set according to the generation time of each effective picture; calculating the similarity of every two pictures in the picture set, and determining redundant pictures based on the similarity; taking pictures except the redundant pictures as target pictures; taking an application program for generating the target picture as a target application program and calling a preset level of each target application program; and decomposing a target picture generated by a target application program with a preset grade higher than a preset grade threshold into a plurality of target picture components, and uploading each target picture component of the same target picture to different remote servers for backup so as to reduce the data volume of remote storage and ensure the data security.
Corresponding to the remote backup method of the picture described in the above embodiments, fig. 4 shows a block diagram of the remote backup device of the picture provided in the embodiment of the present invention, and for convenience of explanation, only the portion relevant to the embodiment of the present invention is shown.
Referring to fig. 4, the apparatus includes:
a calculating module 401, configured to calculate a definition of a picture stored in a terminal device, and set a picture whose definition is not less than a preset definition threshold as a valid picture;
a combination module 402, configured to allocate the valid pictures generated in a preset time period to more than one picture set according to the generation time of each valid picture, where in each picture set containing more than two valid pictures, the time interval of the generation time of each valid picture is less than the preset time interval;
the deleting module 403 is configured to calculate a similarity of every two pictures in each picture set, determine a redundant picture in each picture set based on the similarity, and use a picture generated in the preset time period and except for the redundant picture as a target picture;
the retrieving module 404 is configured to take the application program that generates each target picture as a target application program corresponding to each target picture, and retrieve a preset level of each target application program;
and the backup module 405 is configured to decompose the target picture generated by the target application program with the preset level higher than the preset level threshold into a plurality of target picture components, and upload each target picture component of the same target picture to a plurality of different remote servers for backup.
Optionally, the computing module is specifically configured to:
converting the picture into a gray image, sharpening the gray image, and generating a sharpened image corresponding to the picture;
and calculating the standard deviation of gray values corresponding to all pixel points in the sharpened image corresponding to the picture, and taking the standard deviation as the definition of the picture.
Optionally, the puncturing module is specifically configured to: taking a plurality of pictures with similarity higher than a preset similarity threshold value in each picture set as a subset; and selecting one picture with highest definition from each subset, and taking the picture which is not selected in the subset as the redundant picture.
Optionally, the backup module is specifically configured to:
decomposing a target picture generated by the target application program with the preset grade higher than a preset grade threshold value into a plurality of high-frequency picture components of a first layer and 1 low-frequency picture component of the first layer through a discrete wavelet transform algorithm;
repeating a decomposition operation for a preset number of times from the low frequency picture component of the first layer, the decomposition operation including: decomposing the low-frequency picture component of the upper layer into a plurality of high-frequency picture components of the lower layer and 1 low-frequency picture component of the lower layer through a discrete wavelet transform algorithm;
the high frequency picture component and the low frequency picture component of each layer are taken as the target picture component.
Optionally, the backup module is further configured to:
determining a decomposition category and a decomposition level corresponding to each target picture component, wherein the decomposition category is used for indicating that the target picture component is the low-frequency picture component or the high-frequency picture component, and the decomposition level is used for indicating the level of the target picture component when the target picture component is generated in the decomposition process of the target picture;
searching watermark data corresponding to each target picture component according to the decomposition category and the decomposition level of each target picture component through the corresponding relation among the preset decomposition level, the decomposition category and the watermark data;
and adding corresponding watermark data for each target picture component, generating watermark picture components, and uploading each watermark picture component to different remote servers for backup.
Optionally, the backup module is further configured to: and directly uploading the target picture generated by the target application program with the preset grade not higher than the preset grade threshold to the remote server.
In the embodiment of the invention, the picture with the definition not smaller than the definition threshold value is used as the effective picture by calculating the definition of the picture stored in the terminal equipment; combining the effective pictures with the generation time interval smaller than the preset time interval into a picture set according to the generation time of each effective picture; calculating the similarity of every two pictures in the picture set, and determining redundant pictures based on the similarity; taking pictures except the redundant pictures as target pictures; taking an application program for generating the target picture as a target application program and calling a preset level of each target application program; and decomposing a target picture generated by a target application program with a preset grade higher than a preset grade threshold into a plurality of target picture components, and uploading each target picture component of the same target picture to different remote servers for backup so as to reduce the data volume of remote storage and ensure the data security.
Fig. 5 is a schematic diagram of a terminal device according to an embodiment of the present invention. As shown in fig. 5, the terminal device 5 of this embodiment includes: a processor 50, a memory 51 and a computer program 52, such as a remote backup program of pictures, stored in said memory 51 and executable on said processor 50. The processor 50, when executing the computer program 52, implements the steps of the remote backup method embodiment of each picture described above, such as steps 101 to 107 shown in fig. 1. Alternatively, the processor 50 may perform the functions of the modules/units of the apparatus embodiments described above, such as the units 401 to 405 of fig. 4, when executing the computer program 52.
By way of example, the computer program 52 may be partitioned into one or more modules/units that are stored in the memory 51 and executed by the processor 50 to complete the present invention. The one or more modules/units may be a series of computer program instruction segments capable of performing specific functions for describing the execution of the computer program 52 in the terminal device 5.
The terminal device 5 may be a computing device such as a desktop computer, a notebook computer, a palm computer, a cloud terminal device, etc. The terminal device may include, but is not limited to, a processor 50, a memory 51. It will be appreciated by those skilled in the art that fig. 5 is merely an example of the terminal device 5 and does not constitute a limitation of the terminal device 5, and may include more or less components than illustrated, or may combine certain components, or different components, e.g., the terminal device may further include an input-output device, a network access device, a bus, etc.
The processor 50 may be a central processing unit (Central Processing Unit, CPU), other general purpose processors, digital signal processors (Digital Signal Processor, DSP), application specific integrated circuits (Application Specific Integrated Circuit, ASIC), off-the-shelf programmable gate arrays (Field-Programmable Gate Array, FPGA) or other programmable logic devices, discrete gate or transistor logic devices, discrete hardware components, or the like. A general purpose processor may be a microprocessor or the processor may be any conventional processor or the like.
The memory 51 may be an internal storage unit of the terminal device 5, such as a hard disk or a memory of the terminal device 5. The memory 51 may be an external storage device of the terminal device 5, such as a plug-in hard disk, a Smart Media Card (SMC), a Secure Digital (SD) Card, a Flash memory Card (Flash Card) or the like, which are provided on the terminal device 5. Further, the memory 51 may also include both an internal storage unit and an external storage device of the terminal device 5. The memory 51 is used for storing the computer program as well as other programs and data required by the terminal device. The memory 51 may also be used to temporarily store data that has been output or is to be output.
It will be apparent to those skilled in the art that, for convenience and brevity of description, only the above-described division of the functional units and modules is illustrated, and in practical application, the above-described functional distribution may be performed by different functional units and modules, that is, the internal structure of the apparatus is divided into different functional units or modules, so as to perform all or part of the above-described functions. The functional units and modules in the embodiment may be integrated in one processing unit, or each unit may exist alone physically, or two or more units may be integrated in one unit, where the integrated units may be implemented in a form of hardware or a form of a software functional unit. In addition, specific names of the functional units and modules are only for convenience of distinguishing from each other, and are not used for limiting the protection scope of the present application. The specific working process of the units and modules in the above system may refer to the corresponding process in the foregoing method embodiment, which is not described herein again.
In the foregoing embodiments, the descriptions of the embodiments are emphasized, and in part, not described or illustrated in any particular embodiment, reference is made to the related descriptions of other embodiments.
The units described as separate units may or may not be physically separate, and units shown as units may or may not be physical units, may be located in one place, or may be distributed on a plurality of network units. Some or all of the units may be selected according to actual needs to achieve the purpose of the solution of this embodiment.
The integrated modules/units, if implemented in the form of software functional units and sold or used as stand-alone products, may be stored in a computer readable storage medium. Based on such understanding, the present invention may implement all or part of the flow of the method of the above embodiment, or may be implemented by a computer program to instruct related hardware, where the computer program may be stored in a computer readable storage medium.
The above embodiments are only for illustrating the technical solution of the present invention, and not for limiting the same; although the invention has been described in detail with reference to the foregoing embodiments, it will be understood by those of ordinary skill in the art that: the technical scheme described in the foregoing embodiments can be modified or some technical features thereof can be replaced by equivalents; such modifications and substitutions do not depart from the spirit and scope of the technical solutions of the embodiments of the present invention, and are intended to be included in the scope of the present invention.

Claims (9)

1. A method for remotely backing up pictures, comprising:
calculating the definition of the pictures stored in the terminal equipment, and setting the pictures with the definition not smaller than a preset definition threshold as effective pictures;
distributing the effective pictures generated in a preset time period to more than one picture set according to the generation time of each effective picture, wherein the time interval of the generation time of each effective picture is smaller than the preset time interval in each picture set containing more than two effective pictures;
calculating the similarity of every two pictures in each picture set, determining redundant pictures in each picture set based on the similarity, and taking pictures except the redundant pictures generated in the preset time period as target pictures;
taking the application program generating each target picture as a target application program corresponding to each target picture, and calling a preset grade of each target application program;
decomposing a target picture generated by the target application program with the preset grade higher than a preset grade threshold into a plurality of target picture components, and respectively uploading each target picture component of the same target picture to a plurality of different remote servers for backup;
the decomposing the target picture generated by the target application program with the preset grade higher than the preset grade threshold into a plurality of target picture components includes:
decomposing a target picture generated by the target application program with the preset grade higher than a preset grade threshold value into a plurality of high-frequency picture components of a first layer and 1 low-frequency picture component of the first layer through a discrete wavelet transform algorithm;
repeating a decomposition operation for a preset number of times from the low frequency picture component of the first layer, the decomposition operation including: decomposing the low-frequency picture component of the upper layer into a plurality of high-frequency picture components of the lower layer and 1 low-frequency picture component of the lower layer through a discrete wavelet transform algorithm;
the high frequency picture component and the low frequency picture component of each layer are taken as the target picture component.
2. The method for remote backup of pictures according to claim 1, wherein the calculating of the sharpness of the pictures stored in the terminal device comprises:
converting the picture into a gray image, sharpening the gray image, and generating a sharpened image corresponding to the picture;
and calculating the standard deviation of gray values corresponding to all pixel points in the sharpened image corresponding to the picture, and taking the standard deviation as the definition of the picture.
3. The method of remote backup of pictures of claim 1, wherein said determining redundant pictures in each picture set based on the similarity comprises:
taking a plurality of pictures with similarity higher than a preset similarity threshold value in each picture set as a subset;
and selecting one picture with highest definition from each subset, and taking the picture which is not selected in the subset as the redundant picture.
4. The method for remote backup of pictures according to claim 1, wherein uploading each target picture component of the same target picture to a plurality of different remote terminal devices for backup, respectively, comprises:
determining a decomposition category and a decomposition level corresponding to each target picture component, wherein the decomposition category is used for indicating that the target picture component is the low-frequency picture component or the high-frequency picture component, and the decomposition level is used for indicating the level of the target picture component when the target picture component is generated in the decomposition process of the target picture;
searching watermark data corresponding to each target picture component according to the decomposition category and the decomposition level of each target picture component through the corresponding relation among the preset decomposition level, the decomposition category and the watermark data;
and adding corresponding watermark data for each target picture component, generating watermark picture components, and uploading each watermark picture component to different remote servers for backup.
5. The method for remote backup of pictures of claim 1, further comprising:
and directly uploading the target picture generated by the target application program with the preset grade not higher than the preset grade threshold to the remote server.
6. A remote backup apparatus for pictures, the apparatus comprising:
the computing module is used for computing the definition of the pictures stored in the terminal equipment and setting the pictures with the definition not smaller than a preset definition threshold value as effective pictures;
the combination module is used for distributing the effective pictures generated in a preset time period to more than one picture set according to the generation time of each effective picture, wherein the time interval of the generation time of each effective picture is smaller than the preset time interval in each picture set containing more than two effective pictures;
the deleting and repeating module is used for calculating the similarity of every two pictures in each picture set, determining redundant pictures in each picture set based on the similarity, and taking pictures except the redundant pictures generated in the preset time period as target pictures;
the calling module is used for taking the application program for generating each target picture as a target application program corresponding to each target picture and calling the preset grade of each target application program;
the backup module is used for decomposing a target picture generated by the target application program with the preset grade higher than the preset grade threshold into a plurality of target picture components, and respectively uploading each target picture component of the same target picture to a plurality of different remote servers for backup;
the backup module is specifically configured to:
decomposing a target picture generated by the target application program with the preset grade higher than a preset grade threshold value into a plurality of high-frequency picture components of a first layer and 1 low-frequency picture component of the first layer through a discrete wavelet transform algorithm;
repeating a decomposition operation for a preset number of times from the low frequency picture component of the first layer, the decomposition operation including: decomposing the low-frequency picture component of the upper layer into a plurality of high-frequency picture components of the lower layer and 1 low-frequency picture component of the lower layer through a discrete wavelet transform algorithm;
the high frequency picture component and the low frequency picture component of each layer are taken as the target picture component.
7. The remote backup device of pictures according to claim 6, wherein the computing module is specifically configured to:
converting the picture into a gray image, sharpening the gray image, and generating a sharpened image corresponding to the picture;
and calculating the standard deviation of gray values corresponding to all pixel points in the sharpened image corresponding to the picture, and taking the standard deviation as the definition of the picture.
8. A terminal device comprising a memory, a processor and a computer program stored in the memory and executable on the processor, characterized in that the processor implements the steps of the method according to any of claims 1 to 5 when the computer program is executed.
9. A computer readable storage medium storing a computer program, characterized in that the computer program when executed by a processor implements the steps of the method according to any one of claims 1 to 5.
CN201910379833.6A 2019-05-08 2019-05-08 Remote backup method, device, terminal equipment and medium for pictures Active CN110262925B (en)

Priority Applications (2)

Application Number Priority Date Filing Date Title
CN201910379833.6A CN110262925B (en) 2019-05-08 2019-05-08 Remote backup method, device, terminal equipment and medium for pictures
PCT/CN2019/118540 WO2020224225A1 (en) 2019-05-08 2019-11-14 Picture remote backup method and apparatus, and terminal device and medium

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN201910379833.6A CN110262925B (en) 2019-05-08 2019-05-08 Remote backup method, device, terminal equipment and medium for pictures

Publications (2)

Publication Number Publication Date
CN110262925A CN110262925A (en) 2019-09-20
CN110262925B true CN110262925B (en) 2024-01-30

Family

ID=67914446

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201910379833.6A Active CN110262925B (en) 2019-05-08 2019-05-08 Remote backup method, device, terminal equipment and medium for pictures

Country Status (2)

Country Link
CN (1) CN110262925B (en)
WO (1) WO2020224225A1 (en)

Families Citing this family (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN110262925B (en) * 2019-05-08 2024-01-30 平安科技(深圳)有限公司 Remote backup method, device, terminal equipment and medium for pictures
CN112269675A (en) * 2020-09-22 2021-01-26 宇龙计算机通信科技(深圳)有限公司 Data backup method and device and terminal equipment

Citations (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN105262810A (en) * 2015-09-29 2016-01-20 北京金山安全软件有限公司 Cloud backup method and device for picture and electronic equipment
CN105701834A (en) * 2016-02-26 2016-06-22 努比亚技术有限公司 Picture automatic backup device and method
CN105808380A (en) * 2016-02-26 2016-07-27 北京金山安全软件有限公司 Picture backup method and device and electronic equipment
CN109298971A (en) * 2018-08-28 2019-02-01 维沃移动通信有限公司 A kind of picture backup method and terminal

Family Cites Families (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US9146816B2 (en) * 2012-06-14 2015-09-29 International Business Machines Corporation Managing system image backup
CN110262925B (en) * 2019-05-08 2024-01-30 平安科技(深圳)有限公司 Remote backup method, device, terminal equipment and medium for pictures

Patent Citations (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN105262810A (en) * 2015-09-29 2016-01-20 北京金山安全软件有限公司 Cloud backup method and device for picture and electronic equipment
CN105701834A (en) * 2016-02-26 2016-06-22 努比亚技术有限公司 Picture automatic backup device and method
CN105808380A (en) * 2016-02-26 2016-07-27 北京金山安全软件有限公司 Picture backup method and device and electronic equipment
WO2017143846A1 (en) * 2016-02-26 2017-08-31 北京金山安全软件有限公司 Picture backup method and apparatus, and electronic device
CN109298971A (en) * 2018-08-28 2019-02-01 维沃移动通信有限公司 A kind of picture backup method and terminal

Also Published As

Publication number Publication date
CN110262925A (en) 2019-09-20
WO2020224225A1 (en) 2020-11-12

Similar Documents

Publication Publication Date Title
US10438000B1 (en) Using recognized backup images for recovery after a ransomware attack
Lin et al. Fast, automatic and fine-grained tampered JPEG image detection via DCT coefficient analysis
CN107563974B (en) Image denoising method and device, electronic equipment and storage medium
CN110262925B (en) Remote backup method, device, terminal equipment and medium for pictures
US11057626B2 (en) Video processing device and method for determining motion metadata for an encoded video
CN107301091A (en) Resource allocation methods and device
CN114637870B (en) Image data processing method, device, equipment and storage medium
CN112699400B (en) Image information security processing method and device
CN110473136B (en) Image processing method and device based on SURF-DCT (speeded Up robust features-discrete cosine transform) mixing
US20200244459A1 (en) Watermarking in a virtual desktop infrastructure environment
CN107832021B (en) Electronic evidence fixing method, terminal equipment and storage medium
CN114708138B (en) Network disk image watermark adding method and device, network disk and storage medium
Liu et al. Wavelet‐Based Color Pathological Image Watermark through Dynamically Adjusting the Embedding Intensity
Bobok et al. Steganalysis method efficient for the hidden communication channel with low capacity
CN112487943B (en) Key frame de-duplication method and device and electronic equipment
US8908986B1 (en) Systems and methods for selecting ink colors
CN111191612B (en) Video image matching method, device, terminal equipment and readable storage medium
CN116057937A (en) Method and electronic device for detecting and removing artifacts/degradation in media
CN113763225A (en) Image perception hashing method, system and equipment and information data processing terminal
CN113191210A (en) Image processing method, device and equipment
CN113706639A (en) Image compression method and device based on rectangular NAM, storage medium and computing equipment
Qian et al. Web Photo Source Identification based on Neural Enhanced Camera Fingerprint
CN112752098B (en) Video editing effect verification method and device
CN113554543B (en) Identification method and device based on scrambled image, electronic equipment and medium
CN113688645B (en) Identification method, system and equipment

Legal Events

Date Code Title Description
PB01 Publication
PB01 Publication
SE01 Entry into force of request for substantive examination
SE01 Entry into force of request for substantive examination
GR01 Patent grant
GR01 Patent grant