CN108765349A - A kind of image repair method and system with watermark - Google Patents

A kind of image repair method and system with watermark Download PDF

Info

Publication number
CN108765349A
CN108765349A CN201810546819.6A CN201810546819A CN108765349A CN 108765349 A CN108765349 A CN 108765349A CN 201810546819 A CN201810546819 A CN 201810546819A CN 108765349 A CN108765349 A CN 108765349A
Authority
CN
China
Prior art keywords
watermark
pixel
target area
repaired
complex pattern
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.)
Pending
Application number
CN201810546819.6A
Other languages
Chinese (zh)
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.)
Sichuan Feixun Information Technology Co Ltd
Original Assignee
Sichuan Feixun Information Technology 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 Sichuan Feixun Information Technology Co Ltd filed Critical Sichuan Feixun Information Technology Co Ltd
Priority to CN201810546819.6A priority Critical patent/CN108765349A/en
Publication of CN108765349A publication Critical patent/CN108765349A/en
Pending legal-status Critical Current

Links

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06TIMAGE DATA PROCESSING OR GENERATION, IN GENERAL
    • G06T5/00Image enhancement or restoration
    • G06T5/77Retouching; Inpainting; Scratch removal
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06TIMAGE DATA PROCESSING OR GENERATION, IN GENERAL
    • G06T1/00General purpose image data processing
    • G06T1/0021Image watermarking
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06TIMAGE DATA PROCESSING OR GENERATION, IN GENERAL
    • G06T5/00Image enhancement or restoration
    • G06T5/70Denoising; Smoothing
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06TIMAGE DATA PROCESSING OR GENERATION, IN GENERAL
    • G06T2207/00Indexing scheme for image analysis or image enhancement
    • G06T2207/20Special algorithmic details
    • G06T2207/20081Training; Learning

Landscapes

  • Physics & Mathematics (AREA)
  • General Physics & Mathematics (AREA)
  • Engineering & Computer Science (AREA)
  • Theoretical Computer Science (AREA)
  • Image Processing (AREA)
  • Editing Of Facsimile Originals (AREA)

Abstract

The invention discloses a kind of image repair method and system with watermark, method include the following steps:Obtain the complex pattern to be repaired with watermark identifier;The target area for including the watermark identifier is made in the complex pattern subscript to be repaired;Foreground image is extracted in the target area, the foreground image is the watermark template of the complex pattern to be repaired;The watermark in the complex pattern to be repaired is repaired according to the watermark template.Then the present invention repairs the watermark in complex pattern to be repaired according to the watermark template of the complex pattern to be repaired got, image repair effect can be improved by first obtaining the watermark template of complex pattern to be repaired.

Description

A kind of image repair method and system with watermark
Technical field
The invention belongs to image restoration technology field, more particularly to a kind of image repair method and system with watermark.
Background technology
In data science utilization, the image means of production important as image procossing subject, in the data of model construction In analysis, play the role of very important.But the image found from network at present, mostly there is watermark.With watermark Image no matter tested for image processing and analyzing, or for deep learning, the training of data set, all can greatly influence to calculate Efficiency, accuracy rate and the robustness of method.In order to remove the watermark in image, existing method is made a return journey using fixing watermark template Except the watermark in image, known to the watermark in image and in the case of fixed, preferable effect can be obtained, but works as water When print changes, the repairing effect of image can become far short of what is expected, and therefore, fixed watermark template does not adapt to changeable network rings Border and demand.
Invention content
The object of the present invention is to provide a kind of image repair method and system with watermark is realized according to image itself Watermark template removes the purpose of image watermark, to improve the repairing effect of image.
Technical solution provided by the invention is as follows:
A kind of image repair method with watermark, includes the following steps:
Obtain the complex pattern to be repaired with watermark identifier;
The target area for including the watermark identifier is made in the complex pattern subscript to be repaired;
Foreground image is extracted in the target area, the foreground image is the watermark mould of the complex pattern to be repaired Plate;
The watermark in the complex pattern to be repaired is repaired according to the watermark template.
Further, described to make the target area comprising the watermark identifier in the complex pattern subscript to be repaired and specifically wrap It includes:
Sample data set is obtained, neural network model is trained by the sample data set;
The watermark identifier in the complex pattern to be repaired is identified according to the neural network model after training, and obtains institute State the location information of watermark identifier;
It is made comprising the water in the complex pattern subscript to be repaired according to the location information of the watermark identifier identified The first minimum rectangle frame that marking is known;The first minimum rectangle frame is the target area.
Further, further include:After calibrating the target area, the pixel outside the target area is deleted.
Further, described to extract foreground image in the target area and specifically include:
The the second minimum rectangle frame for including the target area is obtained in the complex pattern to be repaired;
Foreground image is extracted in the second minimum rectangle frame.
Further, described watermark in the complex pattern to be repaired is repaired according to the watermark template to specifically include:
According to location information of the watermark template in the complex pattern to be repaired, in the mesh of the complex pattern to be repaired Mark finds watermark pixel in region, and the pixel of the watermark pixel in the target area is set to zero;
The pixel value for obtaining all non-watermark pixels around the watermark pixel in pre-set radius, will be described all The pixel value of non-watermark pixel is summed and is averaged, and the pixel filling value of the watermark pixel is obtained;
The corresponding watermark pixel is filled using the pixel filling value;
Image in the target area after filling is smoothed, obtains repairing image.
Further, described to be specifically included using the presently described watermark pixel of pixel filling value filling:
When the target area is multiple, and there are intersection in multiple target areas, if the watermark pixel is located at When the non-intersection area of the target area, filled in the non-intersection area of the target area using the pixel filling value Watermark pixel;If the watermark pixel is located at the intersection area of the target area, the pixel filling value is calculated Average value fills the watermark pixel in the intersection area using the average value.
The present invention also provides a kind of image repair systems with watermark, including:
Acquisition module, for obtaining the complex pattern to be repaired with watermark identifier;
Demarcating module, for making the target area for including the watermark identifier in the complex pattern subscript to be repaired;
Extraction module, for extracting foreground image in the target area, the foreground image is described to be repaired The watermark template of image;
Repair module, for repairing the watermark in the complex pattern to be repaired according to the watermark template.
Further, the demarcating module includes:
First acquisition unit, for obtaining sample data set;
Training unit, for training neural network model by the sample data set;
Recognition unit, for identifying the watermark in the complex pattern to be repaired according to the neural network model after training Mark, and obtain the location information of the watermark identifier;
Unit is demarcated, for fixed in the complex pattern subscript to be repaired according to the location information of the watermark identifier identified Go out to include the first minimum rectangle frame of the watermark identifier;The first minimum rectangle frame is the target area.
Further, further include removing module, it, will be outside the target area for after calibrating the target area Pixel is deleted.
Further, the extraction module includes:
Second acquisition unit, for obtaining the second minimum rectangle for including the target area in the complex pattern to be repaired Frame;
Extraction unit, for extracting foreground image in the second minimum rectangle frame.
Further, the repair module includes:
Searching unit, for the location information according to the watermark template in the complex pattern to be repaired, described to be repaired Watermark pixel is found in the target area of complex pattern;
Deleting unit, for the pixel of the watermark pixel in the target area to be set to zero;
Third acquiring unit, for obtaining all non-watermark pixels around the watermark pixel in pre-set radius Pixel value;
Computing unit obtains the watermark for summing and being averaged the pixel value of all non-watermark pixels The pixel filling value of pixel;
Fills unit, for filling the corresponding watermark pixel using the pixel filling value;
Processing unit obtains repairing image for being smoothed the image in the target area after filling.
Further, the fills unit is additionally operable to when the target area be multiple, and multiple target areas have When intersection, if the watermark pixel is located at the non-intersection area of the target area, filled using the pixel filling value Watermark pixel in the non-intersection area of the target area;If the watermark pixel is located at the intersection of the target area When region, the average value of the pixel filling value is calculated, the watermark pixel in the intersection area is filled using the average value Point.
A kind of image repair method and system with watermark provided through the invention, can bring following at least one Advantageous effect:
1, the watermark template of the invention by first obtaining complex pattern to be repaired, then according to the water of the complex pattern to be repaired got Die plate repairs the watermark in complex pattern to be repaired, and image repair effect can be improved.
2, the present invention identifies the watermark identifier in complex pattern to be repaired according to trained neural network model, and water can be improved The recognition accuracy that marking is known, further can be improved the precision of watermark template, to achieve the purpose that improve image repair effect.
3, the present invention deletes the pixel outside target area after getting target area, is subsequently carrying out foreground extraction When, noise jamming can be reduced, to improve foreground extraction effect.
4, after the present invention gets watermark template, in complex pattern to be repaired, corresponding watermark template area has been deleted Pixel so that during image repair, got rid of the interference of watermark region, image repair effect can be improved.
Description of the drawings
Below by a manner of clearly understandable, preferred embodiment is described with reference to the drawings, to a kind of image with watermark Restorative procedure and above-mentioned characteristic, technical characteristic, advantage and its realization method of system are further described.
Fig. 1 is a kind of flow diagram of the embodiment one of the image repair method with watermark of the present invention;
Fig. 2 is a kind of flow diagram of the embodiment two of the image repair method with watermark of the present invention;
Fig. 3 is a kind of flow diagram of the example IV of the image repair method with watermark of the present invention;
Fig. 4 is a kind of structure of second minimum rectangle frame of the example IV of the image repair method with watermark of the present invention Schematic diagram;
Fig. 5 is a kind of flow diagram of the embodiment five of the image repair method with watermark of the present invention;
Fig. 6 is a kind of structural schematic block diagram of the embodiment seven of the image repair system with watermark of the present invention;
Fig. 7 is a kind of structural schematic block diagram of the embodiment eight of the image repair system with watermark of the present invention;
Fig. 8 is a kind of structural schematic block diagram of the embodiment eight of the image repair system with watermark of the present invention;
Fig. 9 is a kind of structural schematic block diagram of the embodiment eight of the image repair system with watermark of the present invention.
Specific implementation mode
In order to more clearly explain the embodiment of the invention or the technical proposal in the existing technology, control is illustrated below The specific implementation mode of the present invention.It should be evident that drawings in the following description are only some embodiments of the invention, for For those of ordinary skill in the art, without creative efforts, other are can also be obtained according to these attached drawings Attached drawing, and obtain other embodiments.
To make simplified form, part related to the present invention is only schematically shown in each figure, they are not represented Its practical structures as product.In addition, so that simplified form is easy to understand, there is identical structure or function in some figures Component only symbolically depicts one of those, or has only marked one of those.Herein, "one" is not only indicated " only this ", can also indicate the situation of " more than one ".
According to first embodiment provided by the invention, as shown in Figure 1,
A kind of image repair method with watermark, includes the following steps:
Obtain the complex pattern to be repaired with watermark identifier;
The target area for including the watermark identifier is made in the complex pattern subscript to be repaired;
Foreground image is extracted in the target area, the foreground image is the watermark mould of the complex pattern to be repaired Plate;
The watermark in the complex pattern to be repaired is repaired according to the watermark template.
Specifically, the image repair method with watermark of the present embodiment can be applied to terminal device and server, terminal Equipment can be smart mobile phone, tablet computer, laptop and PC machine etc..In the present embodiment, first obtains and carry watermark identifier Complex pattern to be repaired, which can be to be obtained on image or network that terminal device or server local store The image arrived.
After getting complex pattern to be repaired, the target area for including above-mentioned watermark identifier is made in complex pattern subscript to be repaired, this Watermark identifier in embodiment includes word, letter, numbers and symbols etc..Target area can be one or more, such as watermark mark It is multiple to know, at this point, target area is also multiple, and may overlap between multiple target areas, mutually include or mutually Separation, if watermark identifier is one, at this point, target area is also one.After getting target area, extracted using display foreground Method extracts foreground image in target area, and foreground image is the watermark template of complex pattern to be repaired, is wrapped in the watermark template Containing above-mentioned watermark identifier.The last watermark template according to the complex pattern to be repaired itself got removes in complex pattern to be repaired Watermark, and image repair is carried out to the region for removing watermark.The present embodiment is repaiied according to the watermark template of complex pattern to be repaired itself Watermark in multiple complex pattern to be repaired, can be improved image repair effect.
According to second embodiment provided by the invention, as shown in Fig. 2,
It is described to make the target area comprising the watermark identifier in the complex pattern subscript to be repaired and specifically include:
Sample data set is obtained, neural network model is trained by the sample data set;
The watermark identifier in the complex pattern to be repaired is identified according to the neural network model after training, and obtains institute State the location information of watermark identifier;
It is made comprising the water in the complex pattern subscript to be repaired according to the location information of the watermark identifier identified The first minimum rectangle frame that marking is known;The first minimum rectangle frame is the target area.
Specifically, the present embodiment is the preferred embodiment of above-mentioned first embodiment.A large amount of phase is first collected in the present embodiment Data are closed to obtain sample data set, the sample data concentrate include the letters of all kinds of styles, number, all kinds of fonts, font with And various symbols etc..It is trained by the sample data set pair neural network model, the neural network model in the present embodiment For fast rcnn resnet v2, certain the present embodiment can also use other existing neural network models, as long as can realize Positioning is identified to word, letter, the numbers and symbols etc. in image.
Neural network is a process for seeking optimal solution during training, training when, first to sample data set into Rower is fixed, then will identify that the regions such as the word, the letter that navigate to are compared with the region actually demarcated, it is accurate to obtain identification Then rate continues to train according to recognition accuracy, when the recognition accuracy of neural network model no longer changes substantially, god It is optimal through network model, i.e., the neural network model after training identified in complex pattern to be repaired the accuracy rate of watermark identifier compared with It is high so that the precision of the watermark template subsequently got is also higher.Watermark mark is identified by the neural network model after training Know (word, letter, numbers and symbols etc.), and get the location information of watermark identifier, according to the watermark identifier identified Location information makes the first minimum rectangle frame comprising watermark identifier in complex pattern subscript to be repaired, which is upper The target area stated.Both included watermark pixel in first minimum rectangle frame, and had also included non-watermark pixel.When complex pattern to be repaired In watermark identifier be it is multiple when, then have multiple first minimum rectangle frames, each first minimum rectangle frame be include some The minimum rectangle frame of watermark identifier.The the first minimum rectangle frame of this in the present embodiment is to solve to obtain by Boundings algorithms, Certainly, other existing methods also can be used in the present embodiment, as long as the first minimum rectangle frame can be obtained.It includes water to calibrate After the first minimum rectangle frame that marking is known, interference of the image of the first minimum rectangle outer frame to subsequent processes can be reduced, is carried Hi-vision repairing effect.
According to 3rd embodiment provided by the invention,
Further include:After calibrating the target area, the pixel outside the target area is deleted.
Specifically, the present embodiment is the preferred embodiment of above-mentioned first embodiment and second embodiment, and the present embodiment is being marked After making target area, the pixel outside target area is deleted.First method is first to consider to seek the rectangle frame of target area Intersection point judges whether to intersect, if if intersection, then acquires intersecting area, then adds the disjoint range of the two, obtains One Minimum Area finally deletes the pixel outside Minimum Area, and the complexity of such method, algorithm is higher, may be easy out It is wrong.Second method is to carry out traversing operation to image, judge each pixel, if belong to any one target area (rectangle Frame), so retain if belonged to, if be not belonging to, directly deletes in this way, thinking is simple, and efficiency is higher.By mesh The pixel marked outside region is deleted, and when subsequently carrying out foreground extraction, noise jamming can be reduced, to improve foreground extraction effect.
According to fourth embodiment provided by the invention, as shown in figure 3, described extract foreground picture in the target area As specifically including:
The the second minimum rectangle frame for including the target area is obtained in the complex pattern to be repaired;
Foreground image is extracted in the second minimum rectangle frame.
Specifically, the present embodiment is the preferred embodiment of above-mentioned first, second, and third embodiment, is getting target area To get to after one or more first minimum rectangle frames behind domain, second comprising target area is got in complex pattern to be repaired Minimum rectangle frame, as shown in figure 4, rectangle frame 1 represents target area (i.e. the first minimum rectangle frame) in figure, rectangle frame 2 represents Two minimum rectangle frames, figure 4, it can be seen that when target area is not intersected with other target areas, (first most for the target area Small rectangle frame) it is the second minimum rectangle frame, when target area is intersected with other target areas, the second minimum rectangle frame is packet The minimum rectangle frame of target area containing intersection.After getting the second minimum rectangle frame, is extracted using foreground extracting method Foreground image in two minimum rectangle frames, the present embodiment can be used before GrabCut algorithms get in the second minimum rectangle frame Scape image can also be used other existing algorithms and get foreground image in the second minimum rectangle frame.Using GrabCut algorithms When extracting foreground image, input is above-mentioned second minimum rectangle frame, then carries the foreground image in the second minimum rectangle frame It takes out, the foreground image extracted is the watermark template of complex pattern to be repaired.After pixel outside first delete target region, then into Row foreground extraction can reduce the noise jamming in foreground extraction, improve foreground extraction effect.
According to the 5th embodiment provided by the invention, as shown in figure 5,
It is described watermark in the complex pattern to be repaired is repaired according to the watermark template to specifically include:
According to location information of the watermark template in the complex pattern to be repaired, in the mesh of the complex pattern to be repaired Mark finds watermark pixel in region, and the pixel of the watermark pixel in the target area is set to zero;
The pixel value for obtaining all non-watermark pixels around the watermark pixel in pre-set radius, will be described all The pixel value of non-watermark pixel is summed and is averaged, and the pixel filling value of the watermark pixel is obtained;
The corresponding watermark pixel is filled using the pixel filling value;
Image in the target area after filling is smoothed, obtains repairing image.
Specifically, the present embodiment is the preferred embodiment of above-mentioned first, second, third and fourth embodiment.When getting After the watermark template of complex pattern to be repaired itself, according to location information of the watermark template in complex pattern to be repaired, in complex pattern to be repaired Target area in find watermark pixel, and the pixel of watermark pixel is set to zero.Then each watermark pixel is obtained The pixel value of all non-watermark pixels in point surrounding pre-set radius, wherein pre-set radius can be set according to real image It sets, the radius being arranged in the present embodiment is 10 pixels, will be all non-aqueous in pre-set radius around each watermark pixel The pixel value of printing vegetarian refreshments is summed and is averaged, and the pixel filling value of each watermark pixel is obtained.For example, finding watermark picture Vegetarian refreshments A and B, obtain the pixel value of all non-watermark pixels around watermark pixel A in pre-set radius, and by watermark picture The pixel value summation of all non-watermark pixels around vegetarian refreshments A is averaged, then obtains the pixel filling value a of watermark pixel A; The pixel value of all non-watermark pixels around watermark pixel B in pre-set radius is obtained, and will be around watermark pixel The pixel value summation of all non-watermark pixels is averaged, then obtains the pixel filling value b of watermark pixel B.Then picture is utilized Plain Filling power a fills watermark pixel A, utilizes pixel filling value b filling watermark pixels B.By all water in target area After the completion of the filling of printing vegetarian refreshments, the image in target area is smoothed, avoids the occurrence of discontinuous and corner angle problem.Example Such as, image can be smoothed by gaussian filtering, to improve image repair effect.
According to sixth embodiment provided by the invention,
It is described to be specifically included using the presently described watermark pixel of pixel filling value filling:
When the target area is multiple, and there are intersection in multiple target areas, if the watermark pixel is located at When the non-intersection area of the target area, filled in the non-intersection area of the target area using the pixel filling value Watermark pixel;If the watermark pixel is located at the intersection area of the target area, the pixel filling value is calculated Average value fills the watermark pixel in the intersection area using the average value.
Specifically, the present embodiment is the preferred embodiment of above-mentioned 5th embodiment.When target area is multiple, and multiple mesh When there is intersection in mark region, if watermark pixel is located at the non-intersection area of target area, the watermark pixel is directly utilized Pixel filling value is filled the watermark pixel;If watermark pixel is located at the intersection area of target area, get When the pixel filling value of each watermark pixel in intersection area, each watermark pixel is not filled directly, but will be handed over After the pixel filling value of each watermark pixel is averaged again in collection region, recycle in average value filling intersection area Watermark pixel.For example, there are two target areas, respectively target area D and target area E, target area D and target area E intersects, and intersection area F, there are three watermark pixels, respectively c1, c2 and c3, if c1 is located at non-intersection area, ascends the throne When outside intersection area F, directly c1 is filled using the pixel filling value of c1;If c2 and c3 is located in intersection area F, After getting the pixel filling value of c2 and c3, c2 and c3 are not filled first, but respectively to the pixel filling value of c2 and c3 It is averaged, obtains the last Filling power of c2 and c3 and is filled again, in the mode being averaged again and embodiment five The mode being averaged is identical.The pixel filling value of intersecting area is averaged again, the image in target area can be made more continuous, To improve image repair effect.
According to the 7th embodiment provided by the invention, as shown in fig. 6,
A kind of image repair system with watermark, including:
Acquisition module 100, for obtaining the complex pattern to be repaired with watermark identifier;
Demarcating module 200, for making the target area for including the watermark identifier in the complex pattern subscript to be repaired;
Extraction module 300, for extracting foreground image in the target area, the foreground image is described to be repaired The watermark template of complex pattern;
Repair module 400, for repairing the watermark in the complex pattern to be repaired according to the watermark template.
The concrete mode that modules in the present embodiment execute operation carries out in the embodiment of the method Detailed description, will be not set forth in detail explanation herein.
According to the 8th embodiment provided by the invention, as shown in Figures 6 to 9,
A kind of image repair system with watermark, including:
Acquisition module 100, for obtaining the complex pattern to be repaired with watermark identifier;
Demarcating module 200, for making the target area for including the watermark identifier in the complex pattern subscript to be repaired;
Extraction module 300, for extracting foreground image in the target area, the foreground image is described to be repaired The watermark template of complex pattern;
Repair module 400, for repairing the watermark in the complex pattern to be repaired according to the watermark template.
Preferably, the demarcating module 200 includes:
First acquisition unit 210, for obtaining sample data set;
Training unit 220, for training neural network model by the sample data set;
Recognition unit 230, for being identified in the complex pattern to be repaired according to the neural network model after training Watermark identifier, and obtain the location information of the watermark identifier;
Demarcate unit 240, for according to the location information of the watermark identifier identified in the complex pattern to be repaired Calibrate the first minimum rectangle frame for including the watermark identifier;The first minimum rectangle frame is the target area.
Preferably, further include removing module, for after calibrating the target area, by the picture outside the target area Element is deleted.
Preferably, the extraction module 300 includes:
Second acquisition unit 310, it is minimum for obtaining second comprising the target area in the complex pattern to be repaired Rectangle frame;
Extraction unit 320, for extracting foreground image in the second minimum rectangle frame.
Further, the repair module 400 includes:
Searching unit 410 is waited for for the location information according to the watermark template in the complex pattern to be repaired described It repairs in the target area of image and finds watermark pixel;
Deleting unit 420, for the pixel of the watermark pixel in the target area to be set to zero;
Third acquiring unit 430, for obtaining all non-watermark pixels around the watermark pixel in pre-set radius The pixel value of point;
Computing unit 440 obtains the water for summing and being averaged the pixel value of all non-watermark pixels The pixel filling value of printing vegetarian refreshments;
Fills unit 450, for filling the corresponding watermark pixel using the pixel filling value;
Processing unit 460 obtains reparation figure for being smoothed to the image in the target area after filling Picture.
Preferably, the fills unit 450 is additionally operable to when the target area be multiple, and multiple target areas have When intersection, if the watermark pixel is located at the non-intersection area of the target area, filled using the pixel filling value Watermark pixel in the non-intersection area of the target area;If the watermark pixel is located at the intersection of the target area When region, the average value of the pixel filling value is calculated, the watermark pixel in the intersection area is filled using the average value Point.
The concrete mode that modules in the present embodiment execute operation carries out in the embodiment of the method Detailed description, will be not set forth in detail explanation herein.
It should be noted that above-described embodiment can be freely combined as needed.The above is only the preferred of the present invention Embodiment, it is noted that for those skilled in the art, in the premise for not departing from the principle of the invention Under, several improvements and modifications can also be made, these improvements and modifications also should be regarded as protection scope of the present invention.

Claims (12)

1. a kind of image repair method with watermark, which is characterized in that include the following steps:
Obtain the complex pattern to be repaired with watermark identifier;
The target area for including the watermark identifier is made in the complex pattern subscript to be repaired;
Foreground image is extracted in the target area, the foreground image is the watermark template of the complex pattern to be repaired;
The watermark in the complex pattern to be repaired is repaired according to the watermark template.
2. a kind of image repair method with watermark according to claim 1, which is characterized in that described described to be repaired The target area comprising the watermark identifier is calibrated on complex pattern to specifically include:
Sample data set is obtained, neural network model is trained by the sample data set;
The watermark identifier in the complex pattern to be repaired is identified according to the neural network model after training, and obtains the water The location information that marking is known;
It is made comprising the watermark mark in the complex pattern subscript to be repaired according to the location information of the watermark identifier identified The the first minimum rectangle frame known;The first minimum rectangle frame is the target area.
3. a kind of image repair method with watermark according to claim 1, which is characterized in that further include:
After calibrating the target area, the pixel outside the target area is deleted.
4. according to a kind of image repair method with watermark of claim 1-3 any one of them, which is characterized in that it is described Foreground image is extracted in the target area to specifically include:
The the second minimum rectangle frame for including the target area is obtained in the complex pattern to be repaired;
Foreground image is extracted in the second minimum rectangle frame.
5. a kind of image repair method with watermark according to claim 1, which is characterized in that described according to the water The watermark that die plate is repaired in the complex pattern to be repaired specifically includes:
According to location information of the watermark template in the complex pattern to be repaired, in the target area of the complex pattern to be repaired Watermark pixel is found in domain, and the pixel of the watermark pixel in the target area is set to zero;
The pixel value for obtaining all non-watermark pixels around the watermark pixel in pre-set radius, will be described all non-aqueous The pixel value of printing vegetarian refreshments is summed and is averaged, and the pixel filling value of the watermark pixel is obtained;
The corresponding watermark pixel is filled using the pixel filling value;
Image in the target area after filling is smoothed, obtains repairing image.
6. a kind of image repair method with watermark according to claim 5, which is characterized in that described to utilize the picture Plain Filling power is filled presently described watermark pixel and is specifically included:
When the target area is multiple, and there are intersection in multiple target areas, if the watermark pixel is positioned at described When the non-intersection area of target area, the watermark in the non-intersection area of the target area is filled using the pixel filling value Pixel;If the watermark pixel is located at the intersection area of the target area, being averaged for the pixel filling value is calculated Value, the watermark pixel in the intersection area is filled using the average value.
7. a kind of image repair system with watermark, which is characterized in that including:
Acquisition module, for obtaining the complex pattern to be repaired with watermark identifier;
Demarcating module, for making the target area for including the watermark identifier in the complex pattern subscript to be repaired;
Extraction module, for extracting foreground image in the target area, the foreground image is the complex pattern to be repaired Watermark template;
Repair module, for repairing the watermark in the complex pattern to be repaired according to the watermark template.
8. a kind of image repair system with watermark according to claim 7, which is characterized in that the demarcating module packet It includes:
First acquisition unit, for obtaining sample data set;
Training unit, for training neural network model by the sample data set;
Recognition unit, for identifying the watermark mark in the complex pattern to be repaired according to the neural network model after training Know, and obtains the location information of the watermark identifier;
Unit is demarcated, for making packet in the complex pattern subscript to be repaired according to the location information of the watermark identifier identified The first minimum rectangle frame containing the watermark identifier;The first minimum rectangle frame is the target area.
9. a kind of image repair method with watermark according to claim 7, which is characterized in that further include deleting mould Block, for after calibrating the target area, the pixel outside the target area to be deleted.
10. according to a kind of image repair method with watermark of claim 7-9 any one of them, which is characterized in that described Extraction module includes:
Second acquisition unit, for obtaining the second minimum rectangle frame for including the target area in the complex pattern to be repaired;
Extraction unit, for extracting foreground image in the second minimum rectangle frame.
11. a kind of image repair method with watermark according to claim 7, which is characterized in that the repair module Including:
Searching unit, for the location information according to the watermark template in the complex pattern to be repaired, in the figure to be repaired Watermark pixel is found in the target area of picture;
Deleting unit, for the pixel of the watermark pixel in the target area to be set to zero;
Third acquiring unit, the pixel for obtaining all non-watermark pixels around the watermark pixel in pre-set radius Value;
Computing unit obtains the watermark pixel for summing and being averaged the pixel value of all non-watermark pixels The pixel filling value of point;
Fills unit, for filling the corresponding watermark pixel using the pixel filling value;
Processing unit obtains repairing image for being smoothed the image in the target area after filling.
12. a kind of image repair method with watermark according to claim 11, which is characterized in that the fills unit It is additionally operable to when the target area be multiple, and when there are intersection in multiple target areas, if the watermark pixel is located at institute When stating the non-intersection area of target area, the water in the non-intersection area of the target area is filled using the pixel filling value Printing vegetarian refreshments;If the watermark pixel is located at the intersection area of the target area, the flat of the pixel filling value is calculated Mean value fills the watermark pixel in the intersection area using the average value.
CN201810546819.6A 2018-05-31 2018-05-31 A kind of image repair method and system with watermark Pending CN108765349A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN201810546819.6A CN108765349A (en) 2018-05-31 2018-05-31 A kind of image repair method and system with watermark

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN201810546819.6A CN108765349A (en) 2018-05-31 2018-05-31 A kind of image repair method and system with watermark

Publications (1)

Publication Number Publication Date
CN108765349A true CN108765349A (en) 2018-11-06

Family

ID=64001145

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201810546819.6A Pending CN108765349A (en) 2018-05-31 2018-05-31 A kind of image repair method and system with watermark

Country Status (1)

Country Link
CN (1) CN108765349A (en)

Cited By (8)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN111260757A (en) * 2018-12-03 2020-06-09 马上消费金融股份有限公司 Image processing method and device and terminal equipment
CN111325699A (en) * 2020-03-20 2020-06-23 腾讯科技(深圳)有限公司 Image restoration method and training method of image restoration model
CN111612681A (en) * 2019-02-22 2020-09-01 阿里巴巴集团控股有限公司 Data acquisition method, watermark identification method, watermark removal method and device
CN111626912A (en) * 2020-04-09 2020-09-04 智者四海(北京)技术有限公司 Watermark removing method and device
CN111754414A (en) * 2019-03-29 2020-10-09 搜狗(杭州)智能科技有限公司 Image processing method and device for image processing
CN113222843A (en) * 2021-05-10 2021-08-06 北京有竹居网络技术有限公司 Image restoration method and related equipment thereof
CN113744150A (en) * 2021-08-31 2021-12-03 杭州隆埠科技有限公司 Image watermarking removing method and device
CN114302252A (en) * 2021-12-31 2022-04-08 深圳万兴软件有限公司 Method and device for removing watermark from video, computer equipment and storage medium

Citations (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN105427233A (en) * 2015-12-29 2016-03-23 小米科技有限责任公司 Method and device for removing watermark
CN103530843B (en) * 2013-10-14 2016-08-10 杭州电子科技大学 A kind of photo watermark embedding based on color information compression and removing method
CN105898322A (en) * 2015-07-24 2016-08-24 乐视云计算有限公司 Video watermark removing method and device
CN107808358A (en) * 2017-11-13 2018-03-16 携程计算机技术(上海)有限公司 Image watermark automatic testing method
EP3308371A1 (en) * 2015-06-10 2018-04-18 Deluxe Media Inc. System and method for digital watermarking

Patent Citations (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN103530843B (en) * 2013-10-14 2016-08-10 杭州电子科技大学 A kind of photo watermark embedding based on color information compression and removing method
EP3308371A1 (en) * 2015-06-10 2018-04-18 Deluxe Media Inc. System and method for digital watermarking
CN105898322A (en) * 2015-07-24 2016-08-24 乐视云计算有限公司 Video watermark removing method and device
CN105427233A (en) * 2015-12-29 2016-03-23 小米科技有限责任公司 Method and device for removing watermark
CN107808358A (en) * 2017-11-13 2018-03-16 携程计算机技术(上海)有限公司 Image watermark automatic testing method

Non-Patent Citations (3)

* Cited by examiner, † Cited by third party
Title
CHUN-HSIANG HUANG等: "Attacking Visible Watermarking Schemes", 《IEEE TRANSACTIONS ON MULTIMEDIA》 *
叶春: "数字图像水印及修复算法研究", 《中国优秀硕士学位论文全文数据库信息科技辑》 *
熊志勇: "基于线性预测的图像可擦除水印算法", 《现代电子技术》 *

Cited By (11)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN111260757A (en) * 2018-12-03 2020-06-09 马上消费金融股份有限公司 Image processing method and device and terminal equipment
CN111612681A (en) * 2019-02-22 2020-09-01 阿里巴巴集团控股有限公司 Data acquisition method, watermark identification method, watermark removal method and device
CN111754414A (en) * 2019-03-29 2020-10-09 搜狗(杭州)智能科技有限公司 Image processing method and device for image processing
CN111754414B (en) * 2019-03-29 2023-10-27 北京搜狗科技发展有限公司 Image processing method and device for image processing
CN111325699A (en) * 2020-03-20 2020-06-23 腾讯科技(深圳)有限公司 Image restoration method and training method of image restoration model
CN111325699B (en) * 2020-03-20 2021-05-25 腾讯科技(深圳)有限公司 Image restoration method and training method of image restoration model
CN111626912A (en) * 2020-04-09 2020-09-04 智者四海(北京)技术有限公司 Watermark removing method and device
CN113222843A (en) * 2021-05-10 2021-08-06 北京有竹居网络技术有限公司 Image restoration method and related equipment thereof
CN113222843B (en) * 2021-05-10 2023-11-10 北京有竹居网络技术有限公司 Image restoration method and related equipment thereof
CN113744150A (en) * 2021-08-31 2021-12-03 杭州隆埠科技有限公司 Image watermarking removing method and device
CN114302252A (en) * 2021-12-31 2022-04-08 深圳万兴软件有限公司 Method and device for removing watermark from video, computer equipment and storage medium

Similar Documents

Publication Publication Date Title
CN108765349A (en) A kind of image repair method and system with watermark
CN102999886B (en) Image Edge Detector and scale grating grid precision detection system
CN104299009B (en) License plate character recognition method based on multi-feature fusion
CN112652015B (en) BIM-based pavement disease marking method and device
CN106548169A (en) Fuzzy literal Enhancement Method and device based on deep neural network
CN108509988B (en) Test paper score automatic statistical method and device, electronic equipment and storage medium
CN109886978B (en) End-to-end alarm information identification method based on deep learning
CN110543877A (en) Identification recognition method, training method and device of model thereof and electronic system
CN110689000B (en) Vehicle license plate recognition method based on license plate sample generated in complex environment
Liu et al. Road centerlines extraction from high resolution images based on an improved directional segmentation and road probability
CN111797821A (en) Text detection method and device, electronic equipment and computer storage medium
CN107818321A (en) A kind of watermark date recognition method for vehicle annual test
CN104637066B (en) The quick framework extraction method of bianry image based on sequential refinement
CN113240623B (en) Pavement disease detection method and device
CN112883926B (en) Identification method and device for form medical images
CN112686243A (en) Method and device for intelligently identifying picture characters, computer equipment and storage medium
CN108171229B (en) Method and system for identifying hollow adhesion verification code
CN115797336A (en) Fault detection method and device of photovoltaic module, electronic equipment and storage medium
CN103699876A (en) Method and device for identifying vehicle number based on linear array CCD (Charge Coupled Device) images
CN114880730A (en) Method and device for determining target equipment and photovoltaic system
CN114419087A (en) Focus image generation method and device, electronic equipment and storage medium
CN110188661A (en) Boundary Recognition method and device
CN109086327A (en) A kind of method and device quickly generating webpage visual structure graph
CN114842492A (en) Key information extraction method and device, storage medium and electronic equipment
CN113971627B (en) License plate picture generation method and device

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
WD01 Invention patent application deemed withdrawn after publication
WD01 Invention patent application deemed withdrawn after publication

Application publication date: 20181106