CN110264442A - A kind of integrity check method of watermark, electronic equipment and readable storage medium storing program for executing - Google Patents

A kind of integrity check method of watermark, electronic equipment and readable storage medium storing program for executing Download PDF

Info

Publication number
CN110264442A
CN110264442A CN201910406641.XA CN201910406641A CN110264442A CN 110264442 A CN110264442 A CN 110264442A CN 201910406641 A CN201910406641 A CN 201910406641A CN 110264442 A CN110264442 A CN 110264442A
Authority
CN
China
Prior art keywords
watermark
tested
image
integrity check
block
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.)
Granted
Application number
CN201910406641.XA
Other languages
Chinese (zh)
Other versions
CN110264442B (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.)
Suzhou Keda Technology Co Ltd
Original Assignee
Suzhou Keda 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 Suzhou Keda Technology Co Ltd filed Critical Suzhou Keda Technology Co Ltd
Priority to CN201910406641.XA priority Critical patent/CN110264442B/en
Publication of CN110264442A publication Critical patent/CN110264442A/en
Application granted granted Critical
Publication of CN110264442B publication Critical patent/CN110264442B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Classifications

    • 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
    • G06T7/00Image analysis
    • G06T7/0002Inspection of images, e.g. flaw detection
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06TIMAGE DATA PROCESSING OR GENERATION, IN GENERAL
    • G06T7/00Image analysis
    • G06T7/10Segmentation; Edge detection
    • G06T7/13Edge detection
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04NPICTORIAL COMMUNICATION, e.g. TELEVISION
    • H04N19/00Methods or arrangements for coding, decoding, compressing or decompressing digital video signals
    • H04N19/10Methods or arrangements for coding, decoding, compressing or decompressing digital video signals using adaptive coding
    • H04N19/134Methods or arrangements for coding, decoding, compressing or decompressing digital video signals using adaptive coding characterised by the element, parameter or criterion affecting or controlling the adaptive coding
    • H04N19/167Position within a video image, e.g. region of interest [ROI]
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04NPICTORIAL COMMUNICATION, e.g. TELEVISION
    • H04N19/00Methods or arrangements for coding, decoding, compressing or decompressing digital video signals
    • H04N19/10Methods or arrangements for coding, decoding, compressing or decompressing digital video signals using adaptive coding
    • H04N19/169Methods or arrangements for coding, decoding, compressing or decompressing digital video signals using adaptive coding characterised by the coding unit, i.e. the structural portion or semantic portion of the video signal being the object or the subject of the adaptive coding
    • H04N19/17Methods or arrangements for coding, decoding, compressing or decompressing digital video signals using adaptive coding characterised by the coding unit, i.e. the structural portion or semantic portion of the video signal being the object or the subject of the adaptive coding the unit being an image region, e.g. an object
    • H04N19/176Methods or arrangements for coding, decoding, compressing or decompressing digital video signals using adaptive coding characterised by the coding unit, i.e. the structural portion or semantic portion of the video signal being the object or the subject of the adaptive coding the unit being an image region, e.g. an object the region being a block, e.g. a macroblock
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04NPICTORIAL COMMUNICATION, e.g. TELEVISION
    • H04N19/00Methods or arrangements for coding, decoding, compressing or decompressing digital video signals
    • H04N19/46Embedding additional information in the video signal during the compression process
    • H04N19/467Embedding additional information in the video signal during the compression process characterised by the embedded information being invisible, e.g. watermarking
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04NPICTORIAL COMMUNICATION, e.g. TELEVISION
    • H04N19/00Methods or arrangements for coding, decoding, compressing or decompressing digital video signals
    • H04N19/85Methods or arrangements for coding, decoding, compressing or decompressing digital video signals using pre-processing or post-processing specially adapted for video compression
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06TIMAGE DATA PROCESSING OR GENERATION, IN GENERAL
    • G06T2201/00General purpose image data processing
    • G06T2201/005Image watermarking
    • G06T2201/0065Extraction of an embedded watermark; Reliable detection

Abstract

The invention discloses a kind of integrity check method of watermark, electronic equipment and readable storage medium storing program for executing, this method comprises: obtaining image to be tested;The location information of predetermined area-of-interest based on image to be tested is treated checking image and is cut, and image block to be tested is obtained;It treats checking image block and carries out watermark identification, obtain watermark feature information to be tested;Watermark feature information to be tested and predetermined watermark characteristic information corresponding with watermark feature information to be tested are compared, the watermark integrity check results of image to be tested are obtained.By implementing the present invention, it can be realized the automatic inspection to the integrality of watermark, improve the reliability of inspection result, and the image block to be tested that checking image is cut is treated to the location information according to the predetermined area-of-interest of image to be tested and is tested, the data volume for finally needing to test can largely be reduced, improve the checkability of the integrity check method of the watermark.

Description

A kind of integrity check method of watermark, electronic equipment and readable storage medium storing program for executing
Technical field
The present invention relates to technical field of multimedia information more particularly to a kind of integrity check method of watermark, Electronic equipment and readable storage medium storing program for executing.
Background technique
The propagation of digital audio/video frequency content with digital broadcasting and broadband network universal increased popularity, to digital audio/video The propagation and related right management of content become content service provider, consumer so that the problem of government regulator pay attention to day by day, Research and development has gone out Digital Rights Management Technology (Digital Rights Management, DRM) to solve this problem.DRM skill Art be in copyright from the producer to publisher, then to consumer and the mistake that is flowed from consumer to other consumers The right of the copyright producer, publisher and consumer are protected in journey.
Digital watermarking is DRM technology important component, and digital watermarking is embedded in having in Streaming Media host data Identifiable digital signal or mode, and the availability of host data is not influenced, it is effectively used for the production of stream media information Power protection.In order to make user when watching the stream media informations such as picture or video, can accurately be known by digital watermarking The source of picture or video, so that the effective property right protection of streaming media information is realized, therefore, for the complete of digital watermarking Whole property (clarity including watermark, can identification, text integrity degree etc.) have higher requirement.In the prior art, for number The completeness check of watermark also rests on the desk checking stage, still, when picture number is larger or video content is longer, makes The mode manually examined carries out the integrity check of watermark, and it is longer to not only result in Check-Out Time, it is also possible to will lead to watermark The problem of a possibility that energy of reviewer declines, and examines error is improved, the reliability of checkability and inspection result compared with It is low.
Summary of the invention
In view of this, the embodiment of the invention provides a kind of integrity check method of watermark, electronic equipment and readable depositing Storage media, when being tested in a manner of solving to use desk checking to the integrality of watermark, checkability and inspection result The lower problem of reliability.
According in a first aspect, including the following steps: the embodiment of the invention provides a kind of integrity check method of watermark Obtain image to be tested;The location information of predetermined area-of-interest based on image to be tested is treated checking image and is cut, Obtain image block to be tested;It treats checking image block and carries out watermark identification, obtain watermark feature information to be tested;By water to be tested Print characteristic information and predetermined watermark characteristic information corresponding with watermark feature information to be tested are compared, and obtain image to be tested Watermark integrity check results.
Checking image is treated by the location information according to the predetermined area-of-interest of image to be tested to be cut, and is obtained Image block to be tested, and treat checking image block and carry out watermark identification, watermark feature information to be tested is obtained, it can be for based on water The integrity detection for printing the watermark of characteristic information provides basis;And by execute by watermark feature information to be tested and with it is to be tested The corresponding predetermined watermark characteristic information of watermark feature information is compared, and obtains the watermark integrity check results of image to be tested The step of, it can be realized the automatic inspection to the integrality of watermark, improve the reliability of inspection result.
It is cut out in addition, treating checking image by the location information of the predetermined area-of-interest based on image to be tested It cuts, obtains image block to be tested, can largely reduce the data volume for finally needing to test (from image to be tested Data volume is reduced to the data volume of image block to be tested), it is imitated so as to improve the inspection of integrity check method of the watermark Rate.
With reference to first aspect, it in first aspect first embodiment, treats checking image block and carries out watermark identification, obtain The step of watermark feature information to be tested, comprising: according to the location information of watermark in image to be tested treat checking image block into Row is cut, and obtains watermark block to be tested;Watermark identification is carried out to watermark block to be tested, obtains watermark feature information to be tested.
It is cut, is obtained by treating checking image in the location information of the predetermined area-of-interest using image to be tested To after image block to be tested, continuation is treated checking image block according to the location information of watermark in image to be tested and is cut, Watermark block to be tested is obtained, can further reduce the data volume for finally needing to test (from the data of image block to be tested Amount, be reduced to the data volume of watermark block to be tested), so as to further increase the watermark integrity check method inspection Efficiency.
First embodiment with reference to first aspect, in first aspect second embodiment, watermark feature information is watermark Text;Wherein, the step of watermark identification being carried out to watermark block to be tested, obtaining watermark feature information to be tested, comprising: to each Watermark block to be tested carries out Text region, obtains watermark text to be tested.
Since general watermark has text or even main contents are exactly text, can using watermark text as Watermark feature information to be tested, and since relative to image recognition, the realization difficulty of Text region is smaller, recognition efficiency is higher, Therefore, by carrying out Text region to each watermark block to be tested, watermark text to be tested is obtained, to be based on the water to be tested Printed text word and corresponding predetermined watermark text, obtain the watermark integrity check results of image to be tested, are capable of providing one kind Realize that difficulty is smaller, the integrity check method of the higher watermark of efficiency.
First embodiment with reference to first aspect, in first aspect third embodiment, watermark feature information is profile Pixel number;Wherein, the step of watermark identification being carried out to watermark block to be tested, obtaining watermark feature information to be tested, comprising: Profile information identical with precognition watermarking images is matched from watermark block to be tested, obtains wire-frame image vegetarian refreshments number to be tested.
Since the number of the pixel of the profile of watermark is can to embody an important feature of the integrality of watermark, because This can using wire-frame image vegetarian refreshments number as watermark feature information, and by matched from watermark block to be tested with precognition watermark The identical profile information of image obtains wire-frame image vegetarian refreshments number to be tested, final to realize based on to be checked in watermark block to be tested Test the integrity check that wire-frame image vegetarian refreshments number carries out watermark;In addition, watermark text to be tested and wheel to be tested ought be based on simultaneously Wide pixel number carries out the integrity check of watermark, increases and examines dimension, can reduce and be based only upon one of which and test When, as caused by watermark feature acquisition of information to be tested error a possibility that inspection result error.
First embodiment with reference to first aspect, in the 4th embodiment of first aspect, watermark feature information to be tested For watermark size and watermark tilt angle;Wherein, watermark identification is carried out to watermark block to be tested, obtains watermark feature letter to be tested The step of breath, comprising: profile information identical with precognition watermarking images is matched from watermark block to be tested;Believed according to profile Breath extracts the apex coordinate of the minimum rectangle comprising the watermark in watermark block to be tested;Using apex coordinate, water to be tested is calculated Print the watermark size to be tested and watermark tilt angle to be tested of the watermark in block.
With reference to first aspect or first aspect first embodiment, in the 5th embodiment of first aspect, based on to The location information of the predetermined area-of-interest of checking image is treated checking image and is cut, and the step of image block to be tested is obtained Suddenly, comprising: image to be tested is converted into YUV image;It is right in YUV image to be extracted using the location information of predetermined area-of-interest The Y-component for answering region obtains image block to be tested.
By the way that image to be tested is converted to YUV image, and YUV is extracted using the location information of predetermined area-of-interest and is schemed The Y-component of corresponding region, can be realized the cutting for treating area-of-interest in checking image as in, simultaneously because it is pre- for extracting The Y-component of area-of-interest is determined, it is thus possible to which the image block to be tested enough made subscribes being convenient for for area-of-interest The gray level image of image or Text region.
With reference to first aspect or first aspect first embodiment, in first aspect sixth embodiment, obtain to The step of checking image, comprising: be sampled, obtain to be checked according to sequence of frames of video of the predetermined sample interval to video to be tested Video frame is tested, and using video frame to be tested as image to be tested.
It is sampled by executing according to sequence of frames of video of the predetermined sample interval to video to be tested, obtains view to be tested Frequency frame, and using video frame to be tested as the step of image to be tested, it can be examined based on the integrality of the watermark of image to be tested The integrity check realized to the watermark of video is tested, simultaneously because really examining is it when treating checking image and testing In image block to be tested or watermark block to be tested, inspection data amount have biggish reduction, therefore, even to be tested Video is tested, and the quantity for extracting the image to be tested that video frame obtains is more, using the method that the present invention is implemented to be checked Testing the integrity check that video carries out watermark also has feasibility.
With reference to first aspect or first aspect first embodiment, in the 7th embodiment of first aspect, according to Watermark feature information and predetermined watermark characteristic information corresponding with watermark feature information to be tested are examined, image to be tested is obtained Watermark integrity check results the step of, comprising: judge the watermark feature value in watermark feature information to be tested relative to pre- Whether the ratio for determining the watermark feature value in watermark feature information is greater than predetermined ratio;Water in watermark feature information to be tested When print characteristic value is greater than predetermined ratio relative to the ratio of the watermark feature value in predetermined watermark characteristic information, figure to be tested is determined The watermark of picture is complete.
According to second aspect, the embodiment of the invention provides a kind of electronic equipment, comprising: memory and processor, it is described Connection is communicated with each other between memory and the processor, computer instruction is stored in the memory, and the processor is logical It crosses and executes the computer instruction, thereby executing water described in any one of first aspect or first aspect embodiment The integrity check method of print.
It is described computer-readable the embodiment of the invention provides a kind of computer readable storage medium according to the third aspect Storage medium stores computer instruction, and the computer instruction is for making the computer execute first aspect or first aspect Any one embodiment described in watermark integrity check method.
Detailed description of the invention
It, below will be to specific in order to illustrate more clearly of the specific embodiment of the invention or technical solution in the prior art Embodiment or attached drawing needed to be used in the description of the prior art be briefly described, it should be apparent that, it is described below Attached drawing is some embodiments of the present invention, for those of ordinary skill in the art, before not making the creative labor It puts, is also possible to obtain other drawings based on these drawings.
Fig. 1 is a kind of a kind of method flow diagram of the integrity check method of watermark provided in an embodiment of the present invention;
A kind of specific embodiment flow chart of step S103 in Fig. 2 bitmap 1;
Fig. 3 is a kind of specific embodiment flow chart of step S202 in Fig. 2;
Fig. 4 is the exemplary diagram of the minimum rectangle provided in an embodiment of the present invention comprising the watermark in watermark block to be tested;
Fig. 5 is a kind of another method flow diagram of the integrity check method of watermark provided in an embodiment of the present invention;
Fig. 6 is a kind of another method flow diagram of the integrity check method of watermark provided in an embodiment of the present invention;
Fig. 7 is the hardware structural diagram of a kind of electronic equipment provided in an embodiment of the present invention.
Specific embodiment
In order to make the object, technical scheme and advantages of the embodiment of the invention clearer, below in conjunction with the embodiment of the present invention In attached drawing, technical scheme in the embodiment of the invention is clearly and completely described, it is clear that described embodiment is A part of the embodiment of the present invention, instead of all the embodiments.Based on the embodiments of the present invention, those skilled in the art are not having Every other embodiment obtained under the premise of creative work is made, shall fall within the protection scope of the present invention.
In the description of the present invention, it should be noted that term " first ", " second ", " third " are used for description purposes only, It is not understood to indicate or imply relative importance.
Embodiment 1
Fig. 1 shows the flow chart of the integrity check method of the watermark of the embodiment of the present invention, as shown in Figure 1, this method It may include steps of:
S101: image to be tested is obtained.Herein, image to be tested can for single channel image, multichannel image or Any one of image types such as the video frame images in video.
S102: the location information of the predetermined area-of-interest based on image to be tested is treated checking image and is cut, and obtains To image block to be tested.Herein, the concrete type of location information is to be configured according to the type of predetermined area-of-interest, Such as, when predetermined area-of-interest is polygonal region, location information can be the apex coordinate of predetermined area-of-interest;When pre- Determine area-of-interest be border circular areas when, location information can be predetermined area-of-interest central coordinate of circle and radius.
It herein, can be by directly extracting the side of the corresponding total data of predetermined area-of-interest in image to be tested Formula realizes the cutting for treating checking image, obtains image block to be tested, walks further, it is also possible to be realized by following implementation Rapid S102:
Step A: image to be tested is converted into YUV image.
Step B: using predetermined area-of-interest location information extract YUV image in corresponding region Y-component, obtain to Checking image block.The Y-component of corresponding region in YUV image is extracted by the location information using predetermined area-of-interest, is realized The cutting for treating area-of-interest in checking image obtains image block to be tested, simultaneously as extracting is predetermined region of interest The Y-component in domain, it is thus possible to which the image block to be tested reservation area-of-interest enough made is convenient for image or text The gray level image of word identification.
S103: it treats checking image block and carries out watermark identification, obtain watermark feature information to be tested.Herein, watermark is special Reference breath includes at least one of watermark text, watermark wire-frame image vegetarian refreshments number, watermark size and watermark gradient.
Herein, when watermark feature information is watermark text, Text region can be carried out by treating checking image block Mode, obtain watermark text to be tested;It, can be by to be checked when watermark feature information is watermark wire-frame image vegetarian refreshments number It tests in image block and matches profile information identical with precognition watermarking images, then obtain the number of the pixel in the profile Mode obtains wire-frame image vegetarian refreshments number to be tested;It, can be with when watermark feature information is watermark size and/or watermark gradient Profile information identical with precognition watermarking images is matched from image block to be tested by elder generation to mention then according to profile information Take the apex coordinate of the minimum rectangle comprising the watermark in image block to be tested, the side finally calculated using the apex coordinate Formula obtains watermark size to be tested and/or watermark tilt angle to be tested.Further, since text in watermark generally with water It is identical to print whole gradient, it therefore, can also be by treating checking image block when watermark feature information is watermark gradient It carries out Text region and obtains watermark text glyph, the vertex for then extracting the minimum rectangle comprising watermark text glyph is sat Mark, finally by the apex coordinate calculated in the way of, obtain watermark tilt angle to be tested.
S104: by watermark feature information to be tested and predetermined watermark characteristic information corresponding with watermark feature information to be tested It is compared, obtains the watermark integrity check results of image to be tested.
It herein, can be by judging the watermark feature value in watermark feature information to be tested relative to predetermined watermark feature Whether the ratio of the watermark feature value in information is greater than the mode of predetermined ratio, judges whether the watermark of image to be tested is complete, Specifically, when the watermark feature value in watermark feature information to be tested is relative to the watermark feature value in predetermined watermark characteristic information Ratio be greater than predetermined ratio mode, determine whether the watermark of image to be tested complete;It is of course also possible to by directly comparing The mode of watermark feature information to be tested and the similarity of predetermined watermark characteristic information judges whether the watermark of image to be tested is complete It is whole, specifically, the water of image to be tested can be determined when watermark feature information to be tested levels off to predetermined watermark characteristic information Print is complete.Herein, predetermined ratio can be in the requirement and image to be detected according to the integrity check accuracy of watermark The concrete application scenes such as appearance are determined.
It herein, can be by judging watermark to be tested when watermark feature information to be tested is watermark text to be tested Whether the number of words of text is greater than the mode of predetermined text ratio relative to the ratio of the number of words of predetermined watermark text, or compare to Examine whether the correct number of words in watermark text is greater than predetermined text ratio relative to the ratio of the number of words of predetermined watermark text Mode judges whether the watermark of image to be tested is complete;When watermark feature information is watermark wire-frame image vegetarian refreshments number, Ke Yitong Cross that judge whether watermark wire-frame image vegetarian refreshments number to be tested is greater than relative to the ratio of predetermined watermark wire-frame image vegetarian refreshments number predetermined The mode of pixel ratio judges whether the watermark of image to be tested is complete;When watermark feature information is watermark size and/or water When printing gradient, by judge watermark size to be tested and/or watermark gradient to be tested and corresponding predetermined watermark size and/ Or whether the similarity of predetermined watermark gradient meets the mode for reaching predetermined similarity, judge image to be tested watermark whether Completely.
It herein, can be based on one of water for carrying out image to be tested when watermark feature information includes a variety of When the inspection result that print integrity check obtains is complete, that is, determine that the final watermark integrity check results of image to be tested are Completely, can also be in the inspection result that the watermark integrity check for being carried out image to be tested based on each of them is obtained When whole, just determine that the final watermark integrity check results of image to be tested are complete, it is, of course, also possible to making image to be tested The type of watermark feature information of watermark integrity check results when being complete when reaching predetermined kind of number, determine image to be tested Final watermark integrity check results be it is complete, do not do any restrictions herein.
In embodiments of the present invention, by the location information according to the predetermined area-of-interest of image to be tested to be tested Image is cut, and image block to be tested is obtained, and is treated checking image block and carried out watermark identification, and watermark feature to be tested is obtained Information can provide basis for the integrity detection of the watermark based on watermark feature information;And by by watermark feature to be tested Information and predetermined watermark characteristic information corresponding with watermark feature information to be tested are compared, and obtain the watermark of image to be tested The step of integrity check results, can be realized the automatic inspection to the integrality of watermark, improve the reliability of inspection result.
It is cut out in addition, treating checking image by the location information of the predetermined area-of-interest based on image to be tested It cuts, obtains image block to be tested, can largely reduce the data volume for finally needing to test (from image to be tested Data volume is reduced to the data volume of image block to be tested), it is imitated so as to improve the inspection of integrity check method of the watermark Rate.
As a kind of optional embodiment of the embodiment of the present invention, in order to further reduce the number for finally needing to test According to amount, so that the checkability of the integrity check method of the watermark is further increased, as shown in Fig. 2, step S103 can wrap Include following steps:
S201: checking image block is treated according to the location information of watermark in image to be tested and is cut, is obtained to be tested Watermark block.Herein, the quantity of watermark is at least one in image to be tested, thus, the location information of corresponding watermark is also At least one.Herein, the watermark block to be tested obtained is the corresponding figure of at least one watermark in predetermined area-of-interest As block.
S202: watermark identification is carried out to watermark block to be tested, obtains watermark feature information to be tested.
It include that watermark size and watermark are inclined with watermark feature information as a kind of optional embodiment of the embodiment of the present invention The integrity check method of the watermark of the embodiment of the present invention is described, as shown in figure 3, step S202 may include for rake angle Following steps:
S301: profile information identical with precognition watermarking images is matched from watermark block to be tested.
S302: according to profile information, the apex coordinate of the minimum rectangle comprising the watermark in watermark block to be tested is extracted.? Here, as shown in figure 4, the coordinate (x of the minimum point of the available minimum rectangle comprising the watermark in watermark block to be testedi, yi), and the coordinate on two vertex adjacent with the minimum point, such as (the x ' in Fig. 4i, y 'i) and (x "i, y "i), certainly, as long as Obtain any 3 points of coordinate of the minimum rectangle, obtain above three point (minimum point of minimum rectangle and with this most Two adjacent vertex of low spot) coordinate only for convenience of it will be understood by those skilled in the art that cited by the scheme of the embodiment of the present invention Specific example, any restriction to the technical solution of the embodiment of the present invention should not be constituted.
S303: utilize apex coordinate, calculate the watermark in watermark block to be tested watermark size to be tested and water to be tested Print tilt angle.Herein, it uses the example above, the calculation formula of watermark size to be tested are as follows:
The calculation formula of watermark tilt angle to be tested are as follows:
Wherein, wiRefer to watermark width to be tested, hiRefer to watermark height to be tested.
It include watermark text and wire-frame image vegetarian refreshments with watermark feature information as a kind of optional embodiment of the present embodiment The integrity check method of the watermark of the embodiment of the present invention is described for number.As shown in figure 5, this method may include as follows Step:
S501: image to be tested is obtained.
S502: the location information of the predetermined area-of-interest based on image to be tested is treated checking image and is cut, and obtains To image block to be tested.The particular content of the step is referred to step S102 to understand, details are not described herein.
S503: checking image block is treated according to the location information of watermark in image to be tested and is cut, is obtained to be tested Watermark block.The particular content of the step is referred to step S201 to understand, details are not described herein.
S504: carrying out Text region to each watermark block to be tested, obtains watermark text to be tested, and from watermark to be tested Profile information identical with precognition watermarking images is matched in block, obtains wire-frame image vegetarian refreshments number to be tested.
S505: judge whether the ratio of number of words of the number of words of watermark text to be tested relative to predetermined watermark text is greater than One predetermined number of words ratio.Herein, the first predetermined number of words ratio is the number greater than 0 and less than 1, such as 0.8,0.85 or 0.9 etc., Specifically, it can actually be answered according to the requirement of the accuracy of the integrity check of watermark and particular content of figure to be tested etc. It is determined with the needs of scene.Herein, the number of words when the number of words of watermark text to be tested relative to predetermined watermark text When ratio is greater than the first predetermined number of words ratio, step S506 is executed;When the number of words of watermark text to be tested is relative to predetermined watermark When the ratio of the number of words of text is less than or equal to the first predetermined number of words ratio, determine that the watermark of image to be tested is imperfect.
S506: judge number of words of the correct number of words in watermark text to be tested relative to predetermined watermark text ratio whether Greater than the second predetermined number of words ratio.Herein, the second predetermined number of words ratio is number greater than 0 and less than 1, such as 0.8,0.85 or 0.9 etc., it specifically, can be according to the requirement of the accuracy of the integrity check of watermark and particular content of figure to be tested etc. The needs of practical application scene are determined.Herein, when the correct number of words in watermark text to be tested is relative to predetermined watermark When the ratio of the number of words of text is greater than the second predetermined number of words ratio, step S507 is executed;When correct in watermark text to be tested When number of words is less than or equal to the second predetermined number of words ratio relative to the ratio of the number of words of predetermined watermark text, image to be tested is determined Watermark is imperfect.
S507: it is pre- to judge whether wire-frame image vegetarian refreshments number to be tested is greater than relative to the ratio of predetermined profile pixel number Determine profile point ratio.Herein, the second predetermined number of words ratio is the number greater than 0 and less than 1, such as 0.75,0.8 or 0.85 etc., Specifically, it can actually be answered according to the requirement of the accuracy of the integrity check of watermark and particular content of figure to be tested etc. It is determined with the needs of scene.Herein, when wire-frame image vegetarian refreshments number to be tested is relative to predetermined profile pixel number When ratio is greater than predetermined profile point ratio, step S508 is executed;When wire-frame image vegetarian refreshments number to be tested is relative to predetermined profile picture When the ratio of vegetarian refreshments number is less than or equal to predetermined profile point ratio, determine that the watermark of image to be tested is imperfect.
S508: determine that the watermark of image to be tested is complete.
It in embodiments of the present invention, can since general watermark has text or even main contents are exactly text Using by watermark text as watermark feature information to be tested, simultaneously because the number of the pixel of the profile of watermark is can to embody One important feature of the integrality of watermark, therefore can pass through using wire-frame image vegetarian refreshments number as watermark feature information The integrity check for being carried out watermark based on watermark text to be tested and wire-frame image vegetarian refreshments number to be tested simultaneously, is increased and examines dimension Degree can reduce when being based only upon one of which and testing, be examined as caused by watermark feature acquisition of information to be tested error As a result a possibility that malfunctioning.
As a kind of optional embodiment of the embodiment of the present invention, come so that the integrity check object of watermark is video as an example The integrity check method of the watermark of the embodiment of the present invention is described.As shown in fig. 6, this method may include:
S601: it is sampled according to sequence of frames of video of the predetermined sample interval to video to be tested, obtains video to be tested Frame, and using video frame to be tested as image to be tested.Herein, predetermined sample interval can be set according to the needs of users It sets, does not do any restrictions herein.In practical applications, in order to which the integrality for carrying out sufficient watermark to video to be tested is examined It tests, video to be tested can be sampled according to human eye characteristic, is i.e. 24 frames of sampling per second or so, of course, it is possible in pumping per second Sample is slightly less than 24 frames, such as 20 frames, 18 frames etc., herein, the sampling interval=(video after original video frame rate/sampling to be tested Frame per second) -1.
S602: the location information of the predetermined area-of-interest based on image to be tested is treated checking image and is cut, and obtains To image block to be tested.The particular content of the step is referred to step S102 to understand, details are not described herein.
S603: it treats checking image block and carries out watermark identification, obtain watermark feature information to be tested.The step it is specific in Appearance be referred to step S103 or step S201~step S202 or step S301~step S303 or step S503~ Step S504 understands that details are not described herein.
S604: by watermark feature information to be tested and predetermined watermark characteristic information corresponding with watermark feature information to be tested It is compared, obtains the watermark integrity check results of image to be tested.The particular content of the step is referred to step S104 Or step S505~S508 understands, details are not described herein.
S605: according to the quantity for being confirmed as complete image in the corresponding image to be tested of video to be tested, relative to The total quantity of the corresponding image to be tested of video to be tested, obtains the watermark integrity check results of video to be tested.Herein, The quantity for being confirmed as complete image in the corresponding image to be tested of video to be tested can be calculated, relative to video to be tested The ratio of the total quantity of corresponding image to be tested, and by way of judging whether the ratio reaches predetermined threshold, judge to It examines the watermark of video whether complete, specifically, when the ratio reaches predetermined threshold, determines that the watermark of video to be tested is complete It is whole.Herein, predetermined threshold is the number greater than 0 less than 1, such as 0.8,0.85 or 0.9 etc., it specifically, can be according to watermark The needs of the practical application scenes such as the particular content of the requirement of the accuracy of integrity check and video to be tested are determined.
In embodiments of the present invention, it is carried out by executing according to sequence of frames of video of the predetermined sample interval to video to be tested Sampling, obtains video frame to be tested, and using video frame to be tested as the step of image to be tested, can be based on image to be tested The integrity check of watermark realize to the integrity check of the watermark of video, test simultaneously because treating checking image When, really examining is image block to be tested therein or watermark block to be tested, and inspection data amount has biggish reduction, because This, even testing to video to be tested, the quantity for extracting the image to be tested that video frame obtains is more, uses the present invention The integrity check that the method for implementation carries out watermark to video to be tested also has feasibility.
The embodiment of the invention also provides a kind of electronic equipment, as shown in fig. 7, the electronic equipment may include processor 71 With memory 72, wherein processor 71 can be connected with memory 72 by bus or other modes, to pass through bus in Fig. 7 For connection.
Processor 71 can be central processing unit (Central Processing Unit, CPU).Processor 71 can be with For other general processors, digital signal processor (Digital Signal Processor, DSP), specific integrated circuit (Application Specific Integrated Circuit, ASIC), field programmable gate array (Field- Programmable Gate Array, FPGA) either other programmable logic device, discrete gate or transistor logic, The combination of the chips such as discrete hardware components or above-mentioned all kinds of chips.
Memory 72 is used as a kind of non-transient computer readable storage medium, can be used for storing non-transient software program, non- Transient computer executable program and module, such as the corresponding program of the integrity check method of the watermark in the embodiment of the present invention Instruction/module.Non-transient software program, instruction and the module that processor 71 is stored in memory 72 by operation, thus Execute the various function application and data processing of processor, the i.e. integrity check of watermark in realization above method embodiment Method.
Memory 72 may include storing program area and storage data area, wherein storing program area can storage program area, Application program required at least one function;It storage data area can the data etc. that are created of storage processor 71.In addition, storage Device 72 may include high-speed random access memory, can also include non-transient memory, for example, at least a magnetic disk storage Part, flush memory device or other non-transient solid-state memories.In some embodiments, it includes relative to place that memory 72 is optional The remotely located memory of device 71 is managed, these remote memories can pass through network connection to processor 71.The reality of above-mentioned network Example includes but is not limited to internet, intranet, local area network, mobile radio communication and combinations thereof.
One or more of modules are stored in the memory 72, when being executed by the processor 71, are executed The integrity check method of watermark in embodiment as shown in figures 1 to 6.
Above-mentioned electronic equipment detail can correspond to corresponding associated description in embodiment referring to FIG. 1 to 6 Understood with effect, details are not described herein again.
It is that can lead to it will be understood by those skilled in the art that realizing all or part of the process in above-described embodiment method Computer program is crossed to instruct relevant hardware and complete, the program can be stored in a computer-readable storage medium In, the program is when being executed, it may include such as the process of the embodiment of above-mentioned each method.Wherein, the storage medium can for magnetic disk, CD, read-only memory (Read-Only Memory, ROM), random access memory (Random Access Memory, RAM), flash memory (Flash Memory), hard disk (Hard Disk Drive, abbreviation: HDD) or solid state hard disk (Solid-State Drive, SSD) etc.;The storage medium can also include the combination of the memory of mentioned kind.
Obviously, the above embodiments are merely examples for clarifying the description, and does not limit the embodiments.It is right For those of ordinary skill in the art, can also make on the basis of the above description it is other it is various forms of variation or It changes.There is no necessity and possibility to exhaust all the enbodiments.And it is extended from this it is obvious variation or It changes still within the protection scope of the invention.

Claims (10)

1. a kind of integrity check method of watermark, which comprises the steps of:
Obtain image to be tested;
The location information of predetermined area-of-interest based on the image to be tested cuts the image to be tested, obtains Image block to be tested;
Watermark identification is carried out to the image block to be tested, obtains watermark feature information to be tested;
By the watermark feature information to be tested and predetermined watermark characteristic information corresponding with the watermark feature information to be tested It is compared, obtains the watermark integrity check results of the image to be tested.
2. the integrity check method of watermark according to claim 1, which is characterized in that described to the image to be tested The step of block carries out watermark identification, obtains watermark feature information to be tested, comprising:
The image block to be tested is cut according to the location information of watermark in the image to be tested, is obtained described to be checked Test watermark block;
Watermark identification is carried out to the watermark block to be tested, obtains watermark feature information to be tested.
3. the integrity check method of watermark according to claim 2, which is characterized in that the watermark feature information is water Printed text word;Wherein, described the step of is carried out by watermark identification, obtains watermark feature information to be tested for the watermark block to be tested, Include:
Text region is carried out to each watermark block to be tested, obtains the watermark text to be tested.
4. the integrity check method of watermark according to claim 2, which is characterized in that the watermark feature information is wheel Wide pixel number;Wherein, described that watermark identification is carried out to the watermark block to be tested, obtain watermark feature information to be tested Step, comprising:
Profile information identical with precognition watermarking images is matched from the watermark block to be tested, obtains contour pixel to be tested Point number.
5. the integrity check method of watermark according to claim 2, which is characterized in that the watermark feature information is water Print size and watermark tilt angle;Wherein, described that watermark identification is carried out to the watermark block to be tested, it is special to obtain watermark to be tested The step of reference ceases, comprising:
Profile information identical with precognition watermarking images is matched from the watermark block to be tested;
According to the profile information, the apex coordinate of the minimum rectangle comprising the watermark in the watermark block to be tested is extracted;
Using the apex coordinate, the watermark size to be tested and watermark to be tested of the watermark in the watermark block to be tested are calculated Tilt angle.
6. the integrity check method of watermark according to claim 1 or 2, which is characterized in that described based on described to be checked The location information for testing the predetermined area-of-interest of image cuts the image to be tested, obtains the step of image block to be tested Suddenly, comprising:
The image to be tested is converted into YUV image;
The Y-component that corresponding region in the YUV image is extracted using the location information of the predetermined area-of-interest is obtained described Image block to be tested.
7. the integrity check method of watermark according to claim 1 or 2, which is characterized in that described to obtain figure to be tested The step of picture, comprising:
It is sampled according to sequence of frames of video of the predetermined sample interval to video to be tested, obtains video frame to be tested, and by institute Video frame to be tested is stated as the image to be tested.
8. the integrity check method of watermark according to claim 1 or 2, which is characterized in that described according to described to be checked Watermark feature information and predetermined watermark characteristic information corresponding with the watermark feature information to be tested are tested, is obtained described to be checked The step of testing the watermark integrity check results of image, comprising:
Judge the watermark feature value in the watermark feature information to be tested relative to the water in the predetermined watermark characteristic information Whether the ratio of print characteristic value is greater than predetermined ratio;
When the watermark feature value in the watermark feature information to be tested is relative to the watermark in the predetermined watermark characteristic information When the ratio of characteristic value is greater than predetermined ratio, determine that the watermark of the image to be tested is complete.
9. a kind of electronic equipment characterized by comprising memory and processor, between the memory and the processor Connection is communicated with each other, computer instruction is stored in the memory, the processor, which passes through, executes the computer instruction, from And perform claim requires the integrity check method of the described in any item watermarks of 1-8.
10. a kind of computer readable storage medium, which is characterized in that the computer-readable recording medium storage has computer to refer to It enables, the integrity check that the computer instruction is used to that the computer perform claim to be made to require the described in any item watermarks of 1-8 Method.
CN201910406641.XA 2019-05-16 2019-05-16 Integrity checking method of watermark, electronic equipment and readable storage medium Active CN110264442B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN201910406641.XA CN110264442B (en) 2019-05-16 2019-05-16 Integrity checking method of watermark, electronic equipment and readable storage medium

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN201910406641.XA CN110264442B (en) 2019-05-16 2019-05-16 Integrity checking method of watermark, electronic equipment and readable storage medium

Publications (2)

Publication Number Publication Date
CN110264442A true CN110264442A (en) 2019-09-20
CN110264442B CN110264442B (en) 2021-07-27

Family

ID=67914733

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201910406641.XA Active CN110264442B (en) 2019-05-16 2019-05-16 Integrity checking method of watermark, electronic equipment and readable storage medium

Country Status (1)

Country Link
CN (1) CN110264442B (en)

Cited By (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN110990801A (en) * 2019-11-29 2020-04-10 深圳市商汤科技有限公司 Information verification method and device, electronic equipment and storage medium
CN113112501A (en) * 2021-05-11 2021-07-13 上海市东方海事工程技术有限公司 Vehicle-mounted track inspection device and method based on deep learning
CN114466181A (en) * 2021-12-29 2022-05-10 沈阳中科创达软件有限公司 Video anomaly detection method, device, equipment and system

Citations (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN102880999A (en) * 2012-09-21 2013-01-16 吉林大学 Color image digital watermark method capable of resisting stamping, printing and scanning processes
CN107481179A (en) * 2017-05-17 2017-12-15 上海冠众光学科技有限公司 Antifalsification label recognition methods with watermarked information and device
US20180211673A1 (en) * 2012-10-15 2018-07-26 Digimarc Corporation Multi-mode audio recognition and auxiliary data encoding and decoding
CN108596916A (en) * 2018-04-16 2018-09-28 深圳市联软科技股份有限公司 Watermark recognition methods, system, terminal and medium similar in a kind of color
CN108810619A (en) * 2018-06-29 2018-11-13 北京奇虎科技有限公司 Identify the method, apparatus and electronic equipment of watermark in video

Patent Citations (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN102880999A (en) * 2012-09-21 2013-01-16 吉林大学 Color image digital watermark method capable of resisting stamping, printing and scanning processes
US20180211673A1 (en) * 2012-10-15 2018-07-26 Digimarc Corporation Multi-mode audio recognition and auxiliary data encoding and decoding
CN107481179A (en) * 2017-05-17 2017-12-15 上海冠众光学科技有限公司 Antifalsification label recognition methods with watermarked information and device
CN108596916A (en) * 2018-04-16 2018-09-28 深圳市联软科技股份有限公司 Watermark recognition methods, system, terminal and medium similar in a kind of color
CN108810619A (en) * 2018-06-29 2018-11-13 北京奇虎科技有限公司 Identify the method, apparatus and electronic equipment of watermark in video

Cited By (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN110990801A (en) * 2019-11-29 2020-04-10 深圳市商汤科技有限公司 Information verification method and device, electronic equipment and storage medium
CN110990801B (en) * 2019-11-29 2022-05-17 深圳市商汤科技有限公司 Information verification method and device, electronic equipment and storage medium
CN113112501A (en) * 2021-05-11 2021-07-13 上海市东方海事工程技术有限公司 Vehicle-mounted track inspection device and method based on deep learning
CN113112501B (en) * 2021-05-11 2023-01-20 上海市东方海事工程技术有限公司 Vehicle-mounted track inspection device and method based on deep learning
CN114466181A (en) * 2021-12-29 2022-05-10 沈阳中科创达软件有限公司 Video anomaly detection method, device, equipment and system

Also Published As

Publication number Publication date
CN110264442B (en) 2021-07-27

Similar Documents

Publication Publication Date Title
US10607311B2 (en) Hierarchical watermark detector
CN110264442A (en) A kind of integrity check method of watermark, electronic equipment and readable storage medium storing program for executing
Liu et al. Image retargeting quality assessment
US9996891B2 (en) System and method for digital watermarking
US8355525B2 (en) Parallel processing of digital watermarking operations
WO2020228520A1 (en) Image transformation method and device, storage medium and computer equipment
CN103294667A (en) Method and system for tracing homologous image through watermark
US11520806B1 (en) Tokenized voice authenticated narrated video descriptions
CN111836118B (en) Video processing method, device, server and storage medium
US10769247B2 (en) System and method for interacting with information posted in the media
US8478033B2 (en) Image inspection apparatus and method
Reed et al. Closed form non-iterative watermark embedding
US20150086113A1 (en) System and Method for Detection and Segmentation of Touching Characters for OCR
CN108776959B (en) Image processing method and device and terminal equipment
CN116189109A (en) Model training method, road event detection method, device and related equipment
CN115391751A (en) Infringement determination method
US20140300790A1 (en) Image processing apparatus, and non-transitory computer readable medium storing image processing program
CN115393756A (en) Visual image-based watermark identification method, device, equipment and medium
Liu et al. Steganalysis based on wavelet texture analysis and neural network
CN110992044B (en) Data processing method and device, electronic equipment and readable storage medium
US10282618B2 (en) Multi-blend fingerprinting
US11983195B2 (en) Tokenized voice authenticated narrated video descriptions
CN115564634B (en) Video countermeasure watermark embedding method, device, electronic equipment and storage medium
Ilchev Accurate data embedding in JPEG images for image authentication
Ortega-Rebollo et al. Parallel semi-fragile color image watermarking authentication scheme using EXIF metadata

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