CN115187443B - Watermark embedding and detecting method and device based on spatial domain residual error feature fusion - Google Patents

Watermark embedding and detecting method and device based on spatial domain residual error feature fusion Download PDF

Info

Publication number
CN115187443B
CN115187443B CN202210792241.9A CN202210792241A CN115187443B CN 115187443 B CN115187443 B CN 115187443B CN 202210792241 A CN202210792241 A CN 202210792241A CN 115187443 B CN115187443 B CN 115187443B
Authority
CN
China
Prior art keywords
image
watermark
fusion
residual error
histogram
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Active
Application number
CN202210792241.9A
Other languages
Chinese (zh)
Other versions
CN115187443A (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.)
Hainan University
Original Assignee
Hainan University
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 Hainan University filed Critical Hainan University
Priority to CN202210792241.9A priority Critical patent/CN115187443B/en
Publication of CN115187443A publication Critical patent/CN115187443A/en
Application granted granted Critical
Publication of CN115187443B publication Critical patent/CN115187443B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Images

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
    • G06T1/00General purpose image data processing
    • G06T1/0021Image watermarking
    • G06T1/005Robust watermarking, e.g. average attack or collusion attack resistant
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06VIMAGE OR VIDEO RECOGNITION OR UNDERSTANDING
    • G06V10/00Arrangements for image or video recognition or understanding
    • G06V10/20Image preprocessing
    • G06V10/28Quantising the image, e.g. histogram thresholding for discrimination between background and foreground patterns
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06VIMAGE OR VIDEO RECOGNITION OR UNDERSTANDING
    • G06V10/00Arrangements for image or video recognition or understanding
    • G06V10/70Arrangements for image or video recognition or understanding using pattern recognition or machine learning
    • G06V10/77Processing image or video features in feature spaces; using data integration or data reduction, e.g. principal component analysis [PCA] or independent component analysis [ICA] or self-organising maps [SOM]; Blind source separation
    • G06V10/80Fusion, i.e. combining data from various sources at the sensor level, preprocessing level, feature extraction level or classification level
    • G06V10/806Fusion, i.e. combining data from various sources at the sensor level, preprocessing level, feature extraction level or classification level of extracted features

Abstract

The scheme relates to a watermark embedding and detecting method and device based on airspace residual error characteristic fusion. The method comprises the following steps: acquiring an original image to be added with a watermark and a binary watermark image; calculating an image residual error matrix corresponding to the original image; generating a pseudo-random matrix according to the image residual error matrix; acquiring an expansion compression factor and a fusion factor, and performing watermark feature fusion to obtain a fusion result; compressing the fusion result and generating an embedded watermark image; acquiring a watermark image to be detected and an original watermark embedded image, carrying out histogram specification on the histogram of the watermark image to be detected according to the histogram of the original watermark embedded image, calculating an image residual error matrix corresponding to the watermark image to be detected, and carrying out image enhancement processing to obtain a watermark detection result. When the watermark is embedded, the texture or edge rich area is selected as the watermark embedding area, so that the capability of resisting and eliminating residual errors or removing watermark attack can be improved, and the watermark embedding method has super-strong safety and robustness.

Description

Watermark embedding and detecting method and device based on spatial domain residual error feature fusion
Technical Field
The invention relates to the technical field of image information processing, in particular to a watermark embedding and detecting method and device based on spatial domain residual error feature fusion.
Background
The widespread distribution of multimedia contents such as photos and images, and the rapid development of image editing processing technology and artificial intelligence technology pose a serious challenge to the rights and safety of image contents. Digital watermarking technology is one of the main methods for image content rights and security protection that are widely and effectively applied at present. Existing image watermarking techniques can be broadly classified into the following three types: (1) The visible watermark is embedded into the protected image content in a way that the copyright information can be seen by naked eyes but the display of the main content of the image is not influenced, so that the purpose of protecting the rights and interests of the image content is achieved; (2) Invisible watermarks are obtained, namely rights and interests information is encrypted and then randomly embedded into relevant positions (such as spatial domain pixel points or frequency domain corresponding frequency band coefficients) and the embedded information is recovered through a special hidden information extraction process, so that the purposes of protecting contents such as copyright, detecting tampering and the like are achieved; (3) The method is characterized in that the visible watermark is hidden, namely, the comprehensive characteristics of the visible watermark and the invisible watermark are combined, and the watermark information is hidden in a dark area with lower resolution, so that the display quality of the main image content is higher, a special watermark extraction process is not needed, and the embedded watermark can be displayed only through gamma correction of display equipment or a common image contrast enhancement method.
However, the above three image watermarking techniques have the following problems, respectively: (1) The visible watermark is visible, and the rights and interests mark image has unicity, so that the watermark is easily and accurately removed through a large number of different image samples with the same watermark, and the aims of improving the visual quality of the main image content and changing the rights and interests of the image are fulfilled; (2) The invisible watermark is easy to be cracked by an attacker through simple geometric transformation and loss of detection synchronism because of the need of a special watermark extraction process; (3) Stealth visible watermarks, although able to combine the advantages of visible and invisible watermarks, are limited to dark areas with low contrast where the content is an unimportant part of the image subject content and thus vulnerable to removal attacks.
In summary, the conventional image watermarking technology has the problems of insufficient security and robustness.
Disclosure of Invention
Based on this, in order to solve the above technical problems, a watermark embedding and detecting method and device based on spatial domain residual error feature fusion are provided, which can ensure the rights and interests of image content and have better security and robustness.
A watermark embedding method based on spatial domain residual error feature fusion comprises the following steps:
acquiring an original image to be added with a watermark and a binary watermark image;
acquiring a quality threshold value, and extracting image processing data corresponding to the original image; calculating an image residual error matrix corresponding to the original image according to the quality threshold, the image processing data and the original image;
generating a pseudo-random matrix according to the image residual error matrix;
acquiring an expansion compression factor and a fusion factor, and performing watermark feature fusion according to the expansion compression factor, the fusion factor, the image residual matrix, the pseudorandom matrix and the binary watermark image to obtain a fusion result;
and compressing the fusion result, and generating an embedded watermark image according to the compressed fusion result and the image processing data.
In one embodiment, the obtaining an expansion compression factor and a fusion factor, and performing watermark feature fusion according to the expansion compression factor, the fusion factor, the image residual error matrix, the pseudorandom matrix, and the binary watermark image to obtain a fusion result includes:
acquiring the expansion compression factor, and performing expansion processing on the image residual error matrix according to the expansion compression factor to obtain an expanded image residual error matrix;
extracting target features according to the image residual error matrix after the expansion processing and the quality threshold;
and adjusting the target characteristics according to each element in the image residual error matrix after the expansion processing to obtain adjusted target characteristics, and performing watermark characteristic fusion according to the adjusted target characteristics, the pseudorandom matrix and the binary watermark image to obtain a fusion result.
In one embodiment, the adjusting the target feature according to each element in the image residual matrix after the expansion processing to obtain an adjusted target feature includes:
sequentially extracting each element in the image residual error matrix after the expansion processing, and sequentially determining the numerical range of each element;
acquiring preset adjustment rules, and determining a target adjustment rule according to the numerical range;
and adjusting the elements according to the target adjustment rule to obtain the adjusted target characteristics.
A watermark embedding device based on spatial domain residual feature fusion, the device comprising:
the image acquisition module is used for acquiring an original image to be added with a watermark and a binary watermark image;
the image residual error calculation module is used for acquiring a quality threshold value and extracting image processing data corresponding to the original image; calculating an image residual error matrix corresponding to the original image according to the quality threshold, the image processing data and the original image;
the matrix generation module is used for generating a pseudo-random matrix according to the image residual error matrix;
the characteristic fusion module is used for acquiring an expansion compression factor and a fusion factor, and performing watermark characteristic fusion according to the expansion compression factor, the fusion factor, the image residual error matrix, the pseudorandom matrix and the binary watermark image to obtain a fusion result;
and the embedded watermark image generating module is used for compressing the fusion result and generating an embedded watermark image according to the compressed fusion result and the image processing data.
In one embodiment, the feature fusion module is further configured to: acquiring the expansion compression factor, and performing expansion processing on the image residual error matrix according to the expansion compression factor to obtain an expanded image residual error matrix; extracting target features according to the image residual error matrix after the expansion processing and the quality threshold; and adjusting the target characteristics according to each element in the image residual error matrix after the expansion processing to obtain adjusted target characteristics, and performing watermark characteristic fusion according to the adjusted target characteristics, the pseudorandom matrix and the binary watermark image to obtain a fusion result.
In one embodiment, the feature fusion module is further configured to: sequentially extracting each element in the image residual error matrix after the expansion treatment, and sequentially determining the numerical range of each element; acquiring preset adjustment rules, and determining a target adjustment rule according to the numerical range; and adjusting the elements according to the target adjustment rule to obtain the adjusted target characteristics.
A watermark detection method based on spatial domain residual error feature fusion comprises the following steps:
acquiring a watermark image to be detected and an original watermark embedded image, and calculating a histogram of the watermark image to be detected corresponding to the watermark image to be detected and an original watermark embedded image histogram corresponding to the original watermark embedded image;
if the histogram of the watermark image to be detected is consistent with the histogram of the original watermark embedded image, calculating a watermark image residual error matrix corresponding to the watermark image to be detected;
and carrying out image enhancement processing on the watermark image residual error matrix to obtain a watermark detection result.
In one embodiment, the method further comprises:
and if the histogram of the watermark image to be detected is not consistent with the histogram of the original watermark embedded image, performing histogram stipulation operation on the histogram of the watermark image to be detected according to the histogram of the original watermark embedded image, so that the operated histogram of the watermark image to be detected is consistent with the histogram of the original watermark embedded image.
A watermark detection apparatus based on spatial domain residual feature fusion, the apparatus comprising:
the histogram acquisition module is used for acquiring a watermark image to be detected and an original watermark embedded image, and calculating a watermark image histogram to be detected corresponding to the watermark image to be detected and an original watermark embedded image histogram corresponding to the original watermark embedded image;
the histogram comparison module is used for calculating a watermark image residual error matrix corresponding to the watermark image to be detected if the histogram of the watermark image to be detected is consistent with the histogram of the original watermark embedded image;
and the watermark detection module is used for carrying out image enhancement processing on the watermark image residual error matrix to obtain a watermark detection result.
In one embodiment, the histogram comparison module is further configured to: and if the histogram of the watermark image to be detected is not consistent with the histogram of the original watermark embedded image, performing histogram stipulation operation on the histogram of the watermark image to be detected according to the histogram of the original watermark embedded image, so that the operated histogram of the watermark image to be detected is consistent with the histogram of the original watermark embedded image.
According to the watermark embedding and detecting method and device based on the spatial domain residual error feature fusion, an original image to be added with a watermark and a binary watermark image are obtained; acquiring a quality threshold value, and extracting image processing data corresponding to the original image; calculating an image residual error matrix corresponding to the original image according to the quality threshold, the image processing data and the original image; generating a pseudo-random matrix according to the image residual error matrix; acquiring an expansion compression factor and a fusion factor, and performing watermark feature fusion according to the expansion compression factor, the fusion factor, the image residual matrix, the pseudorandom matrix and the binary watermark image to obtain a fusion result; and compressing the fusion result, and generating an embedded watermark image according to the compressed fusion result and the image processing data. Acquiring a watermark image to be detected and an original watermark embedded image, and calculating a histogram of the watermark image to be detected corresponding to the watermark image to be detected and an original watermark embedded image histogram corresponding to the original watermark embedded image; if the histogram of the watermark image to be detected is consistent with the histogram of the original watermark embedded image, calculating a watermark image residual error matrix corresponding to the watermark image to be detected; and carrying out image enhancement processing on the watermark image residual error matrix to obtain a watermark detection result. The image residual error matrix is combined with the feature fusion, and a compression contrast processing strategy is adopted for the result, so that the generated embedded watermark image has higher visual quality; when the characteristics are fused, the confusion fusion key space is the same as the security level of the pseudo-random matrix, when the watermark is embedded, the texture or edge rich area is selected as the watermark embedding area, the capability of resisting and eliminating residual errors or removing watermark attacks can be improved under the condition of ensuring the image visual quality, and the method has super-strong security and robustness.
Drawings
FIG. 1 is a diagram of an application environment of a watermark embedding and detecting method based on spatial domain residual error feature fusion in an embodiment;
FIG. 2 is a flowchart illustrating a watermark embedding method based on spatial domain residual error feature fusion in an embodiment;
FIG. 3 is a block diagram of a watermark embedding apparatus based on spatial domain residual feature fusion in an embodiment;
FIG. 4 is a flowchart illustrating a watermark detection method based on spatial domain residual feature fusion in an embodiment;
FIG. 5 is a block diagram of an embodiment of a watermark detection apparatus based on spatial domain residual feature fusion;
fig. 6 is an exemplary embedded watermark example, wherein: the upper part is an F (I) and residual R image obtained by uniformly quantizing and transforming F by adopting a quantization step Q =17, and the lower part is a standard test image I, an image with the size of 512 multiplied by 512 and a camouflage image which is embedded with a watermark and has the same size;
fig. 7 shows an original watermark image and an attack-free residual watermark image with enlarged contrast;
fig. 8 is a watermark image obtained using a spectral residual saliency detection procedure;
fig. 9 is a detection result and an image of an AFFINE2 attack mode in a stirmark4.0 test platform, wherein the upper left image is a watermark image seen by naked eyes, the right image is a result obtained after spectral residual error method processing, and the lower image is a corresponding attack result image;
fig. 10 is a detection result and an image of an AFFINE8 attack mode in a stirmark4.0 test platform, wherein the upper left image is a watermark image seen by naked eyes, the right image is a result obtained after spectral residual error method processing, and the lower image is a corresponding attack result image;
fig. 11 is a detection result and an image of a CROP50 attack mode in a stirmark4.0 test platform, wherein the left image at the upper part is a watermark image seen by naked eyes, the right image is a result obtained after spectral residual error method processing, and the corresponding attack result image is arranged at the lower part;
fig. 12 is a detection result and an image by using LATESTRNDDIST 0.95.95 attack mode in a stirmark4.0 test platform, wherein the upper left image is a watermark image seen by naked eyes, the right image is a result obtained after spectral residual error method processing, and the lower image is a corresponding attack result image;
fig. 13 is a detection result and an image of LATESTRNDDIST 1.1.1 attack mode in a stirmark4.0 test platform, wherein the upper left image is a watermark image seen by naked eyes, the right image is a result obtained after spectral residual error method processing, and the lower image is a corresponding attack result image;
fig. 14 is a detection result and an image of MEDIAN3 attack mode in a stirmark4.0 test platform, wherein the upper left image is a watermark image seen by naked eyes, the right image is a result obtained after spectral residual error method processing, and the lower part is a corresponding attack result image;
fig. 15 shows a detection result and an image of an RESC90 attack mode in a stirmark4.0 test platform, where the upper left image is a watermark image seen with naked eyes, the right image is a result obtained after a spectral residual error method, and the lower image is a corresponding attack result image;
fig. 16 is a detection result and an image of the RESC110 attack mode in the stirmark4.0 test platform, wherein the left image at the upper part is a watermark image seen by naked eyes, the right image is a result obtained after the spectral residual error method processing, and the corresponding attack result image is arranged at the lower part;
fig. 17 shows the detection results and images of the rmil 30 attack mode in the stirmark4.0 test platform, wherein the left image at the top is a watermark image seen by naked eyes, the right image is the result obtained after the spectral residual error method processing, and the corresponding attack result image is arranged at the bottom;
fig. 18 is a detection result and an image by using an RML100 attack mode in a stirmark4.0 test platform, wherein the upper left image is a watermark image seen by naked eyes, the right image is a result obtained after processing by a spectral residual error method, and the lower image is a corresponding attack result image;
FIG. 19 is a test result and image of RNDDIST0.95 attack mode in a StirMark4.0 test platform, wherein the upper left image is a watermark image seen by naked eyes, the right image is a result obtained after spectral residual error method processing, and the lower image is a corresponding attack result image;
fig. 20 shows the detection results and images of the ROT-2 attack mode in the stirmark4.0 test platform, where the upper left image is a watermark image seen by naked eyes, the right image is the result obtained after spectral residual error method processing, and the lower image is the corresponding attack result image;
fig. 21 is a detection result and an image of the ROT10 attack mode in the stirmark4.0 test platform, wherein the left image at the upper part is a watermark image seen by naked eyes, the right image is a result obtained after spectral residual error method processing, and the corresponding attack result image is at the lower part;
FIG. 22 shows the detection results and images of ROTCROP-0.75 attack mode in a StirMark4.0 test platform, wherein the left image at the upper part is a watermark image seen by naked eyes, the right image is the result obtained after spectral residual error method processing, and the corresponding attack result image is arranged at the lower part;
fig. 23 shows the detection result and image of ROTCROP1 attack mode in the stirmark4.0 test platform, where the upper left image is the watermark image seen by naked eyes, the right image is the result obtained after the spectral residual error method, and the lower image is the corresponding attack result image;
fig. 24 shows the detection result and image of the manner of the rotiscale 2 attack in the stirmark4.0 test platform, where the left image at the top is the watermark image seen by naked eyes, the right image is the result obtained after the spectral residual error method, and the corresponding attack result image is below;
FIG. 25 is a diagram of the detection results and images of the ROTSCALE-1 attack mode in the StirMark4.0 test platform, wherein the left image at the top is a watermark image seen by naked eyes, the right image is the result obtained after the spectral residual error method processing, and the corresponding attack result image is arranged at the bottom;
fig. 26 is a detection result and an image of an RNDDIST0.95 attack manner in a stirmark4.0 test platform when a quantization step Q =31, where the upper left image is a watermark image seen by naked eyes, the right image is a result obtained after processing by a spectral residual error method, and the lower image is a corresponding attack result image;
fig. 27 is a detection result and an image of a CONV _1 attack mode in a stirmark4.0 test platform when a quantization step Q =111, where a left image is an attack result image and a right image is a watermark image seen by naked eyes;
fig. 28 is a detection result and an image of a JPEG _15 attack mode in a stirmark4.0 test platform when a quantization step Q =111, where a left image is an attack result image and a right image is a watermark image seen by naked eyes;
fig. 29 is a detection result and an image of NOISE _20 attack mode in a stirmark4.0 test platform when quantization step Q =111, where the left image is an attack result image and the right image is a watermark image seen by naked eyes;
fig. 30 is an attack mode detection result and an image obtained by guessing a watermark region using a histogram and randomly modifying the guessed region when the quantization step Q =111, where the left image is an attack result image and the right image is a watermark image seen by naked eyes;
fig. 31 is an attack detection result and an image obtained by performing regional guessing using a histogram and performing mean filtering in the guessed region when the quantization step Q =111, where the left image is an attack result image and the right image is a watermark image seen with naked eyes;
fig. 32 is an attack mode detection result and an image obtained by performing smooth filtering using a 9 × 9 mean template when the quantization step Q =111, where the left image is an attack result image and the right image is a watermark image seen by naked eyes;
fig. 33 is an attack mode detection result and an attack image obtained by histogram equalization when the quantization step Q =111, where the left image is an attack result image and the right image is a watermark image seen by naked eyes.
Detailed Description
In order to make the objects, technical solutions and advantages of the present application more apparent, the present application is described in further detail below with reference to the accompanying drawings and embodiments. It should be understood that the specific embodiments described herein are merely illustrative of the present application and are not intended to limit the present application.
The watermark embedding method based on the spatial domain residual error feature fusion and the watermark detection method based on the spatial domain residual error feature fusion provided by the embodiment of the application can be applied to the application environment shown in fig. 1. As shown in FIG. 1, the application environment includes a computer device 110. The computer device 110 may obtain an original image to be watermarked and a binary watermark image; acquiring a quality threshold value, and extracting image processing data corresponding to an original image; calculating an image residual error matrix corresponding to the original image according to the quality threshold, the image processing data and the original image; generating a pseudo-random matrix according to the image residual error matrix; acquiring an expansion compression factor and a fusion factor, and performing watermark feature fusion according to the expansion compression factor, the fusion factor, an image residual matrix, a pseudorandom matrix and a binary watermark image to obtain a fusion result; and compressing the fusion result, and generating an embedded watermark image according to the compressed fusion result and the image processing data. The computer device 110 may further obtain a to-be-detected watermark image and an original watermark embedded image, and calculate a to-be-detected watermark image histogram corresponding to the to-be-detected watermark image and an original watermark embedded image histogram corresponding to the original watermark embedded image; if the histogram of the watermark image to be detected is consistent with the histogram of the original watermark embedded image, calculating a watermark image residual error matrix corresponding to the watermark image to be detected; and carrying out image enhancement processing on the watermark image residual error matrix to obtain a watermark detection result. The computer device 110 may be, but is not limited to, various personal computers, notebook computers, smart phones, robots, tablet computers, and other devices.
In one embodiment, as shown in fig. 2, there is provided a watermark embedding method based on spatial domain residual feature fusion, including the following steps:
step 202, obtaining an original image to be added with a watermark and a binary watermark image.
The original image to be watermarked may be used to represent an image that needs to be watermarked, and may be specified by a user through a computer device. A binary watermark image may be used to represent the image that needs to be added to the original image. The original image to be added may be represented by I and the binary watermark image may be represented by W.
Step 204, acquiring a quality threshold, and extracting image processing data corresponding to the original image; and calculating an image residual error matrix corresponding to the original image according to the quality threshold, the image processing data and the original image.
The quality threshold may be represented by Q, and the quality threshold may be a specific value that is set. The image processing data may be represented as a mathematical transformation F, wherein the mathematical transformation F includes, but is not limited to, processing methods such as existing cartoon image decomposition, uniform representation of each block based on image segmentation, image compression, and image quantization. In this embodiment, the image processing data may also be a result obtained by mathematically transforming F under the control of a key K, and the key, that is, F (I, K), may further prevent an attacker from obtaining a residual image before an unknown key by setting the control of the key K, and thus remove watermark information, and ensure security. Specifically, the mathematical transformation F is independent of the original image pixel spatial position itself, and F (I, K), etc., will be uniformly denoted as F (I) hereinafter for simplicity.
According to the quality threshold Q, the image processing data F and the original image I, in calculating an image residual error matrix R corresponding to the original image, the calculation formula may be: r = I-F (I), and | | | R | < Q; where | R | | may be used to represent the image residual matrix norm.
When Q is small, the residual error belongs to a high-frequency component region of the image, and compared with a complex background, the visual saliency of the newly-added features is not high enough in strength and is easy to remove by being attacked by blurring, smoothing and the like; if the watermark embedding area is a texture or edge rich area, the pixel contrast and the dynamic range of the watermark embedding area are relatively large, the information content and the protection value of residual main content are improved by increasing Q, and the visual significance of newly-added features is generally large.
Specifically, when Q is small, the residual information amount is generally small, and although the robustness and the security are high for corresponding geometric deformation attacks, the attacks such as simple residual elimination, i.e., I replacement by F (I), smoothing attack, noise attack, and lossy compression attack are fragile; when Q is larger, the residual error information amount is generally larger, and at this time, if the watermark embedding area is a texture or edge rich area, the watermark can not only have better imperceptibility by properly selecting Q and a fusion factor, but also can effectively resist elimination residual error attack, smooth attack, noise attack, conventional compression attack and the like.
And step 206, generating a pseudo-random matrix according to the image residual error matrix.
Wherein the dimension of the pseudo-random matrix may be the same as the dimension of the image residual matrix. Specifically, a pseudo-random matrix V having the same dimension as the image residual matrix R may be generated from the key seed S.
And 208, acquiring the expansion compression factor and the fusion factor, and performing watermark feature fusion according to the expansion compression factor, the fusion factor, the image residual error matrix, the pseudorandom matrix and the binary watermark image to obtain a fusion result.
The expansion compression factor may be denoted as T, and may be a specific value; the fusion factor may be expressed as α, and α may range in value from 0 to 1.
The compression factor, the fusion factor, the image residual matrix, the pseudo-random matrix and the binary watermark image are expanded, the watermark features are fused in a classified multi-dimensional feature mode, and the obtained fusion result can improve the visual quality of the image.
In the process of watermark fusion embedding, the fusion embedding of watermark content is highly related to a pseudo-random matrix generated by a key seed S, and the security of the fusion embedding of watermark content is determined by the key space of the key seed S; in addition, as a result of aliasing feature fusion, the fusion is analyzed from uniform distribution or normal distribution, the fusion has strong randomness, and the proportion of watermark feature pixels to original pixels is about 1: therefore, the attack of removing the watermark region inevitably causes the loss and the change of the original main content of the region on one hand, and enlarges the distortion rate of the image content, and on the other hand, the attack is difficult to remove because the watermark region and the region outside the watermark may have more obvious difference, so that the attack has stronger robustness and safety.
And step 210, compressing the fusion result, and generating an embedded watermark image according to the compressed fusion result and the image processing data.
Specifically, the fusion result may be compressed by expanding the compression factor T, and the fusion result may be denoted as temp, and the compressed fusion result may be represented as: floor (temp × T/255), where floor () may be used to represent a rounding operation that truncates the fractional part.
An embedded watermark image may be generated from the compressed fusion result, the image processing data, and the generated embedded watermark image may be represented as O _ img, and O _ img = F (I) + temp.
In the embodiment, an image residual error matrix R obtained by introducing mathematical transformation F irrelevant to the image space position is taken as an information hiding host space, watermark information is expressed by introducing a newly added feature at an embedding position, and natural balance between good ornamental image quality and clearer watermark detection is realized by means of a compression and expansion mechanism; the watermark information embedding is not based on a simple noise model any more, but adaptively adds a common characteristic to the pixels of the same type under the condition of not changing the relative characteristics of the pixels at corresponding positions, the characteristic can be identified by human eyes under the condition of amplification, or the characteristic is extracted by visual saliency detection software, and the software depends more on the visual saliency brought by the space group structure of the characteristic rather than the gray value or the color value, so that the corresponding modification distortion can be ensured to be maintained in the relative dynamic range determined by corresponding content and controlled by a contrast companding mode; the watermark strength only depends on the visual significance brought by the space group structure of the newly added features, so that the single-dimensional expression mode of the watermark embedding function of the traditional noise model is changed, and the complete visual expression of the sparse content of the binary watermark information structure is realized by using smaller modification.
In the embodiment, the watermark embedding method based on spatial domain residual error feature fusion is provided, which includes obtaining an original image to be added with a watermark and a binary watermark image; acquiring a quality threshold value, and extracting image processing data corresponding to an original image; calculating an image residual error matrix corresponding to the original image according to the quality threshold, the image processing data and the original image; generating a pseudo-random matrix according to the image residual error matrix; acquiring an expansion compression factor and a fusion factor, and performing watermark feature fusion according to the expansion compression factor, the fusion factor, an image residual matrix, a pseudorandom matrix and a binary watermark image to obtain a fusion result; and compressing the fusion result, and generating an embedded watermark image according to the compressed fusion result and the image processing data. The image residual error matrix is combined with the feature fusion, and a compression contrast processing strategy is adopted for the result, so that the generated embedded watermark image has higher visual quality; when the characteristics are fused, the security level of the confusion fusion key space is the same as that of the pseudo-random matrix, when the watermark is embedded, the texture or edge rich area is selected as a watermark embedding area, the capability of resisting and eliminating residual errors or removing watermark attacks can be improved under the condition of ensuring the visual quality of the image, and the method has super-strong security and robustness.
In an embodiment, the watermark embedding method based on spatial domain residual error feature fusion may further include a process of performing feature fusion to obtain a fusion result, where the specific process includes: acquiring an expansion compression factor, and performing expansion processing on the image residual error matrix according to the expansion compression factor to obtain an expanded image residual error matrix; extracting target characteristics according to the image residual error matrix and the quality threshold after the expansion processing; and adjusting the target characteristics according to each element in the image residual error matrix after the expansion processing to obtain the adjusted target characteristics, and performing watermark characteristic fusion according to the adjusted target characteristics, the pseudorandom matrix and the binary watermark image to obtain a fusion result.
In this embodiment, the watermark feature fusion embedding process may be composed of three steps of expansion, feature extraction, and confusion fusion. Specifically, in the expanding step, an expansion compression factor T may be obtained first, so as to expand the image residual matrix according to the expansion compression factor T, and obtain an expanded image residual matrix, where the expanded image residual matrix may be represented by R ', where R' = floor (R × 255/T), floor () may be used to represent an integer operation of rounding off a fractional part, and/or may represent a multiplication operation and a division operation, respectively.
Secondly, in the process of feature extraction, target features can be extracted according to the image residual error matrix and the quality threshold after expansion processing, and the formula of feature extraction can be as follows: Δ = floor (R'/Q). And then, in the process of confusion fusion, performing watermark feature fusion according to the adjusted target feature delta, the pseudo-random matrix V and the binary watermark image W to obtain a fusion result. Specifically, the residual image matrix R ' after the expansion process may be operated point by point, that is, taking a point R ' (x, y), where (x, y) may be used to represent the row-column position coordinates of the elements in the R ' matrix. The obtained fusion result can be denoted as temp (x, y), and the calculation formula of the fusion result can be: temp (x, y) = floor ((α × Δ + (1- α) × R '). V + R '. 1-V) × W + R '. 1-W), where.
In this embodiment, when the features of watermarks are fused in the binary watermark image W, a texture or edge rich region may be selected as a watermark embedding region to improve the residual main content information, so as to improve the capability of resisting residual rejection or watermark removal attack.
In an embodiment, the provided watermark embedding method based on spatial domain residual feature fusion may further include a process of adjusting the features, where the specific process includes: sequentially extracting each element in the image residual error matrix after the expansion processing, and sequentially determining the numerical range of each element; acquiring preset adjustment rules, and determining a target adjustment rule according to the numerical range; and adjusting the elements through the target adjustment rule to obtain the adjusted target characteristics.
When feature adjustment is performed, each element in the image residual matrix after the expansion processing, that is, the extraction point R '(x, y), may be sequentially extracted, and the feature Δ (x, y) may be adjusted according to the size of R' (x, y). Specifically, when performing the feature adjustment, the numerical range to which the point R '(x, y) belongs may be determined in sequence, in this embodiment, the range of the point R' (x, y) may be specifically divided into three numerical segments, which are 0 to 32, 32 to 64, and greater than 64, and different adjustment rules may be corresponding to different numerical segments. The adjustment rules can be preset and correspond to three different numerical value segments one to one, so that the computer equipment can adjust elements of different numerical value segments according to different adjustment rules.
When the feature Δ (x, y) is resized according to R' (x, y), the adjustment rule is as follows:
Δ = Δ × round (6-R '/8) if R ' (x, y) > =0 and R ' (x, y) <= 32;
Δ = Δ × round (3-R '/32) if R ' (x, y) >32 and R ' (x, y) < = 64;
Δ = Δ × round (1/3+R '/96) if R' (x, y) > 64; where round () is a rounding function. After feature adjustment, further fusion calculations may be performed. In this embodiment, specifically, the obtained fusion result may be denoted as temp (x, y), and the calculation formula of the fusion result may be: temp (x, y) = floor ((α × Δ + (1- α) × R '). V + R '. 1-V) × W + R '. 1-W), where.
Each element in the image residual matrix R 'is extracted in sequence, and therefore, feature adjustment and fusion calculation need to be performed on each element until all elements in R' are calculated.
The watermark embedding method based on the spatial domain residual error feature fusion can adaptively fuse a new feature in a watermark embedding area under the condition of not changing the relative relation of the gray value or the color value of the pixel of the main image content, and controls the visibility of the new feature through a residual error contrast companding mechanism, so that the watermark form can be better distinguished from the residual error of the watermark image by the new feature through the visual significance performance of the expanded watermark image; the obtained watermark image not only has higher visual quality, but also has natural robustness to the conventional image geometric deformation attack; particularly, the texture and the edge rich area are selected to embed the watermark so as to improve the information content of the corresponding residual content, and the method not only can effectively inhibit the visual influence of the watermark on the content of the main image, but also can effectively resist almost all attacks listed in a StirMark4.0 test platform and various existing removal attacks, thereby breaking through the contradiction relation between the visual quality, the robustness and the safety in the traditional watermark technology and effectively ensuring the rights and interests of the content of the image and the safety.
In one embodiment, as shown in fig. 3, a watermark embedding apparatus based on spatial domain residual feature fusion is provided, including: an image obtaining module 310, an image residual calculating module 320, a matrix generating module 330, a feature fusing module 340, and an embedded watermark image generating module 350, wherein:
an image obtaining module 310, configured to obtain an original image to be watermarked and a binary watermark image;
an image residual calculation module 320, configured to obtain a quality threshold and extract image processing data corresponding to an original image; calculating an image residual error matrix corresponding to the original image according to the quality threshold, the image processing data and the original image;
a matrix generating module 330, configured to generate a pseudo-random matrix according to the image residual error matrix;
the feature fusion module 340 is configured to obtain an expansion compression factor and a fusion factor, and perform feature fusion of watermarks according to the expansion compression factor, the fusion factor, an image residual matrix, a pseudorandom matrix, and a binary watermark image to obtain a fusion result;
and an embedded watermark image generating module 350, configured to compress the fusion result, and generate an embedded watermark image according to the compressed fusion result and the image processing data.
In an embodiment, the feature fusion module 340 is further configured to obtain an expansion compression factor, and perform expansion processing on the image residual matrix according to the expansion compression factor to obtain an image residual matrix after the expansion processing; extracting target characteristics according to the image residual error matrix after the expansion processing and a quality threshold; and adjusting the target characteristics according to each element in the image residual error matrix after the expansion processing to obtain the adjusted target characteristics, and performing watermark characteristic fusion according to the adjusted target characteristics, the pseudorandom matrix and the binary watermark image to obtain a fusion result.
In one embodiment, the feature fusion module 340 is further configured to sequentially extract each element in the expanded image residual matrix, and sequentially determine a numerical range of each element; acquiring preset adjustment rules, and determining a target adjustment rule according to the numerical range; and adjusting the elements through a target adjustment rule to obtain the adjusted target characteristics.
As shown in fig. 4, in an embodiment, a watermark detection method based on spatial domain residual feature fusion is provided, which includes the following steps:
step 402, acquiring a watermark image to be detected and an original watermark embedded image, and calculating a watermark image histogram to be detected corresponding to the watermark image to be detected and an original watermark embedded image histogram corresponding to the original watermark embedded image.
The watermark image to be detected may be an image to be detected and verified after the watermark is added, wherein the original watermark embedded image may be a watermark embedded image representing a trusted source acquired from each terminal device. And calculating the corresponding histogram of the watermark image to be detected and the original watermark embedded image according to the watermark image to be detected and the original watermark embedded image.
And step 404, if the histogram of the watermark image to be detected is consistent with the histogram of the original watermark embedded image, calculating a watermark image residual error matrix corresponding to the watermark image to be detected.
In this embodiment, if the watermark image to be detected is D _ img, the original watermark embedded image is B _ img, the quality threshold Q, and the image processing data F, the specific watermark detection process is as follows: and comparing the histograms of the D _ img and the B _ img, namely comparing the histogram of the watermark image to be detected with the histogram of the original watermark embedded image, and if the histograms of the watermark image to be detected are consistent with the histogram of the original watermark embedded image, calculating a watermark image residual matrix R' = D _ img-F (D _ img) corresponding to the watermark image to be detected.
And step 406, performing image enhancement processing on the watermark image residual error matrix to obtain a watermark detection result.
The image enhancement processing may be a gray scale transform or other image enhancement processing, such as gamma correction, so that the watermark therein can be recognized by the naked eye.
When watermark detection is carried out, a special complex watermark detector is not needed, and only simple contrast enhancement or expansion treatment is needed to be carried out on the obtained residual error, so that corresponding watermark information can be distinguished and identified through human vision; watermark information and main content residual error are interwoven together according to a certain pseudo-random distribution mode, the theoretical basis of distinguishing and identifying is visual saliency detection, namely, a foreground object is identified from a complex background, in this respect, human vision has the advantage of being unique, but machine identification still has certain limitation in the current progress, and the difference provides reliable safety for ensuring that the watermark is not removed; a large number of experimental results show that even though the machine can automatically extract the watermark mask through visual saliency detection, because the newly added feature system is formed by randomly fusing actual watermark elements and main content pixels (including edges and texture regions) according to a pseudorandom matrix V, under the condition of unknown key seeds, the existing signal separation method cannot remove the watermark and cannot change the main content of the image, so that the security at the key level is achieved; and watermark detection has the effect of simple calculation, although neighborhood pixel similarity is considered, the whole algorithm implementation is still point operation, and the calculation complexity is O (N).
In the application, the watermark embedding and watermark detecting processes are converted into the problems of visual feature fusion and visual saliency detection, and a contrast companding mechanism is adopted to perform multi-dimensional feature fusion adjustment on image pixels at the watermark embedding position and neighborhood relations of the image pixels, so that watermark information of the image pixels has good imperceptibility in a compressed state and visual saliency in an expanded state; since the watermark strength depends only on the visual saliency of its common features within the corresponding region, independent of the specific grey value (color value) size; and the confusion fusion process can ensure that the watermark and the main content are randomly interwoven together, and the residual transformation has spatial position independence and natural capability of resisting desynchronizing attacks such as geometric deformation and the like and watermark removal attacks, so that a better balance effect of image quality and robustness is obtained, and a solid technical support is provided for the application of multimedia content safety and rights and interests protection.
In one embodiment, the watermark detection method based on spatial domain residual feature fusion may further include a process of adjusting a histogram, where the specific process includes: if the histogram of the watermark image to be detected is inconsistent with the histogram of the original watermark embedded image, performing histogram specified operation on the histogram of the watermark image to be detected according to the histogram of the original watermark embedded image, or adopting a reverse adjustment strategy of corresponding gray scale transformation and histogram equalization attack to ensure that the operated histogram of the watermark image to be detected is consistent with the histogram of the original watermark embedded image.
If the histogram of the watermark image to be detected is inconsistent with the histogram of the original watermark embedded image, histogram specification operation can be carried out on the histogram of the watermark image to be detected, or a reverse adjustment strategy of attacks such as corresponding gray level transformation, histogram equalization and the like is adopted, so that the histogram of D _ img is generally consistent with the histogram of B _ img, namely the histogram of the watermark image to be detected after the histogram specification operation is consistent with the histogram of the original watermark embedded image.
In one embodiment, as shown in fig. 5, a watermark detection apparatus based on spatial domain residual feature fusion is provided, including: a histogram acquisition module 510, a histogram comparison module 520, and a watermark detection module 530, wherein:
a histogram obtaining module 510, configured to obtain a to-be-detected watermark image and an original watermark embedded image, and calculate a to-be-detected watermark image histogram corresponding to the to-be-detected watermark image and an original watermark embedded image histogram corresponding to the original watermark embedded image;
a histogram comparing module 520, configured to calculate a watermark image residual error matrix corresponding to the watermark image to be detected if the histogram of the watermark image to be detected is consistent with the histogram of the original watermark embedded image;
and the watermark detection module 530 is configured to perform image enhancement processing on the watermark image residual error matrix to obtain a watermark detection result.
In an embodiment, the histogram comparing module 520 is further configured to, if the histogram of the to-be-detected watermark image is not consistent with the histogram of the original watermark embedded image, perform a histogram stipulation operation on the histogram of the to-be-detected watermark image according to the histogram of the original watermark embedded image, or adopt a reverse adjustment strategy of corresponding gray scale transformation and histogram equalization attack, so that the operated histogram of the to-be-detected watermark image is consistent with the histogram of the original watermark embedded image.
In one embodiment, the specific experiments of watermark embedding, watermark detection and attack resistance are as follows:
when watermark embedding is performed, as shown in fig. 6, if uniform quantization is selected as transform F and quantization step parameter Q =17 is selected for standard test image I, F (I) and residual R = I-F (I) thereof are easily obtained, and output of dummy image O _ img is found to be smaller than the original image in PSNR of 45.4db and ssim of 0.9953.
When watermark detection is performed, as shown in fig. 7, 7a may be used to represent an original binary watermark image, and 7b may be used to represent an image obtained after contrast expansion of a residual image, from which watermark image content may be clearly identified; fig. 8 shows watermark image information extracted by using the algorithm for detecting the significance of the spectral residual, and the content of the watermark image information can be generally identified.
When the capability of resisting various geometric deformation attacks is detected, watermark detection results of the geometric deformation attacks under various parameters listed in a stir mark4.0 watermark attack test platform when Q =17 are respectively shown in fig. 9 to fig. 25, wherein a geometric deformation example of RNDDIST0.95 when Q =31 is given in fig. 26, it can be seen that although the resolution is slightly more laborious for individual attacks, the main content of the final watermark can be still resolved, and the watermark detection robustness is fully embodied.
When the capability of resisting the removal attack is detected, fig. 27 to fig. 32 respectively show the results of watermark detection on images after convolution, compression, noise attack in the stirmark4.0 watermark attack test platform and guess filter attack, random modification attack and global smooth filter attack based on histograms specially designed in the scheme of the present application when Q = 111. It can be seen that this type of attack fails to completely remove the watermark, especially in the edge regions and texture regions, which all sufficiently attest to the high security of the watermark.
Specifically, when an operation experiment is performed, the experimental operation environment is an operating system windows10, and the simulation experiment software is matlab2019b. In the experiment, a standard test image I with an image size of 512 × 512 is selected, as shown in fig. 6. According to the application requirements, a uniform quantization function is selected as F, the quantization step Q =17 and the fusion factor α =0.5 are taken, the visual quality PSNR =45.4db, ssim =0.9953 and the companding factor T = Q of the generated disguised image are generated, and compared with 255, the companding multiple =255/17=15 visually and completely meets the application requirements, as shown in fig. 6, and the residual visual saliency at this time can also meet the robustness and safety requirements, as shown in fig. 7-25.
For applications with higher robustness and security requirements, for example: and it is also required to resist convolution, highly lossy compression, noise and corresponding guess attack and smooth filtering attack, it may be considered to select texture regions (such as hat regions and hair regions in fig. 6) or adopt a visible watermark mode, and select Q =111, and the generated disguised image PSNR =28.95db, ssim =0.91, and for the above various attacks, 99.92% of the watermarks thereof can be detected, which obviously meets the requirements of practical application.
It should be particularly noted that, for the attacks based on the histogram, such as gray scale transformation, histogram equalization, etc., a strategy of histogram comparison and inverse processing may be adopted, specifically, a mapping relationship between the histogram of the gray scale values of the attack image and the histogram of the original watermark embedded image is constructed according to the principle that the frequency of the gray scale values of the image before and after the attack is necessarily similar, and inverse processing is performed, so as to achieve approximate restoration from the attack image to the original watermark embedded image, so that the histograms of the attack image and the original watermark embedded image are substantially consistent in distribution, thereby suppressing interference brought by the attack on watermark identification, and ensuring that the watermark can be effectively detected, as shown in fig. 33.
The technical features of the above embodiments can be arbitrarily combined, and for the sake of brevity, all possible combinations of the technical features in the above embodiments are not described, but should be considered as the scope of the present specification as long as there is no contradiction between the combinations of the technical features.
The above-mentioned embodiments only express several embodiments of the present application, and the description thereof is more specific and detailed, but not construed as limiting the scope of the invention. It should be noted that, for a person skilled in the art, several variations and modifications can be made without departing from the concept of the present application, which falls within the scope of protection of the present application. Therefore, the protection scope of the present patent shall be subject to the appended claims.

Claims (10)

1. A watermark embedding method based on spatial domain residual error feature fusion is characterized by comprising the following steps:
acquiring an original image to be added with a watermark and a binary watermark image;
acquiring a quality threshold value, and extracting image processing data corresponding to the original image; calculating an image residual error matrix corresponding to the original image according to the quality threshold, the image processing data and the original image;
generating a pseudo-random matrix according to the image residual error matrix;
acquiring an expansion compression factor and a fusion factor, and performing watermark feature fusion according to the expansion compression factor, the fusion factor, the image residual matrix, the pseudorandom matrix and the binary watermark image to obtain a fusion result; the watermark feature fusion embedding process comprises three steps of expansion, feature extraction and confusion fusion; in the expansion step, an expansion compression factor T is obtained, an image residual error matrix R is expanded according to the expansion compression factor T to obtain an image residual error matrix after the expansion processing, and the image residual error matrix after the expansion processing is represented by R ', wherein R' = floor (R.255/T), floor () represents rounding operation of a fraction-removed part, and/or represents multiplication and division operation respectively; in the feature extraction process, extracting target features according to the image residual error matrix and the quality threshold after expansion processing, wherein the feature extraction formula is as follows: Δ = floor (R'/Q), where Q represents a quality threshold; in the process of confusion fusion, carrying out watermark feature fusion according to the adjusted target feature delta, the pseudorandom matrix V and the binary watermark image W to obtain a fusion result; performing point-by-point operation according to the expanded image residual error matrix R ', namely taking a point R ' (x, y), wherein (x, y) can be used for representing row-column position coordinates of elements in the R ' matrix; the obtained fusion result is denoted as temp (x, y), and the calculation formula of the fusion result is: temp (x, y) = floor ((α × Δ + (1- α) × R '). V + R '. 1-V) × W + R '. 1-W), wherein,. Denotes a matrix dot product and α denotes a fusion factor;
and compressing the fusion result, and generating an embedded watermark image according to the compressed fusion result and the image processing data.
2. The watermark embedding method based on spatial domain residual error feature fusion of claim 1, wherein the obtaining of the expansion compression factor and the fusion factor and the feature fusion of the watermark according to the expansion compression factor, the fusion factor, the image residual error matrix, the pseudorandom matrix and the binary watermark image to obtain a fusion result comprises:
acquiring the expansion compression factor, and performing expansion processing on the image residual error matrix according to the expansion compression factor to obtain an expanded image residual error matrix;
extracting target features according to the image residual error matrix after the expansion processing and the quality threshold;
and adjusting the target characteristics according to each element in the image residual error matrix after the expansion processing to obtain adjusted target characteristics, and performing watermark characteristic fusion according to the adjusted target characteristics, the pseudorandom matrix and the binary watermark image to obtain a fusion result.
3. The spatial domain residual feature fusion-based watermark embedding method according to claim 2, wherein the adjusting the target feature according to each element in the expanded image residual matrix to obtain an adjusted target feature comprises:
sequentially extracting each element in the image residual error matrix after the expansion processing, and sequentially determining the numerical range of each element;
acquiring preset adjustment rules, and determining a target adjustment rule according to the numerical range;
and adjusting the elements according to the target adjustment rule to obtain the adjusted target characteristics.
4. A watermark embedding device based on spatial domain residual error feature fusion is characterized by comprising:
the image acquisition module is used for acquiring an original image to be added with a watermark and a binary watermark image;
the image residual error calculation module is used for acquiring a quality threshold value and extracting image processing data corresponding to the original image; calculating an image residual error matrix corresponding to the original image according to the quality threshold, the image processing data and the original image;
the matrix generation module is used for generating a pseudo-random matrix according to the image residual error matrix;
the characteristic fusion module is used for acquiring an expansion compression factor and a fusion factor, and performing watermark characteristic fusion according to the expansion compression factor, the fusion factor, the image residual error matrix, the pseudorandom matrix and the binary watermark image to obtain a fusion result; the watermark feature fusion embedding process comprises three steps of expansion, feature extraction and confusion fusion; in the expansion step, an expansion compression factor T is obtained, an image residual error matrix R is expanded according to the expansion compression factor T to obtain an image residual error matrix after the expansion processing, and the image residual error matrix after the expansion processing is represented by R ', wherein R' = floor (R × 255/T), floor () represents the rounding operation of the fraction-removed part, and/or represents multiplication and division operation respectively; in the feature extraction process, extracting target features according to the image residual error matrix and the quality threshold after expansion processing, wherein the feature extraction formula is as follows: Δ = floor (R'/Q), where Q represents a quality threshold; in the process of confusion fusion, carrying out watermark feature fusion according to the adjusted target feature delta, the pseudorandom matrix V and the binary watermark image W to obtain a fusion result; performing point-by-point operation according to the expanded image residual error matrix R ', namely taking a point R ' (x, y), wherein (x, y) can be used for representing row-column position coordinates of elements in the R ' matrix; the obtained fusion result is denoted as temp (x, y), and the calculation formula of the fusion result is: temp (x, y) = floor ((α ×. Δ + (1- α) × R '). V + R '. W + R '. 1-W), wherein,. Indicates a matrix dot product and α indicates a fusion factor;
and the embedded watermark image generation module is used for compressing the fusion result and generating an embedded watermark image according to the compressed fusion result and the image processing data.
5. The spatial domain residual feature fusion based watermark embedding device according to claim 4, wherein the feature fusion module is further configured to: acquiring the expansion compression factor, and performing expansion processing on the image residual error matrix according to the expansion compression factor to obtain an expanded image residual error matrix; extracting target features according to the image residual error matrix after the expansion processing and the quality threshold; and adjusting the target characteristics according to each element in the image residual error matrix after the expansion processing to obtain adjusted target characteristics, and performing watermark characteristic fusion according to the adjusted target characteristics, the pseudorandom matrix and the binary watermark image to obtain a fusion result.
6. The spatial domain residual feature fusion based watermark embedding device according to claim 5, wherein the feature fusion module is further configured to: sequentially extracting each element in the image residual error matrix after the expansion processing, and sequentially determining the numerical range of each element; acquiring preset adjustment rules, and determining a target adjustment rule according to the numerical range; and adjusting the elements according to the target adjustment rule to obtain the adjusted target characteristics.
7. A watermark detection method based on spatial domain residual error feature fusion is used for carrying out watermark detection on an embedded watermark image generated by the method of any one of claims 1 to 3; characterized in that the method comprises:
acquiring a watermark image to be detected and an original watermark embedded image, and calculating a histogram of the watermark image to be detected corresponding to the watermark image to be detected and a histogram of the original watermark embedded image corresponding to the original watermark embedded image;
if the histogram of the watermark image to be detected is consistent with the histogram of the original watermark embedded image, calculating a watermark image residual error matrix corresponding to the watermark image to be detected;
and carrying out image enhancement processing on the watermark image residual error matrix to obtain a watermark detection result.
8. The spatial domain residual feature fusion based watermark detection method according to claim 7, further comprising:
and if the histogram of the watermark image to be detected is not consistent with the histogram of the original watermark embedded image, performing histogram stipulation operation on the histogram of the watermark image to be detected according to the histogram of the original watermark embedded image, so that the operated histogram of the watermark image to be detected is consistent with the histogram of the original watermark embedded image.
9. A watermark detection device based on spatial domain residual error feature fusion is used for carrying out watermark detection on an embedded watermark image generated by the device of any one of claims 4 to 6; characterized in that the device comprises:
the histogram acquisition module is used for acquiring a watermark image to be detected and an original watermark embedded image, and calculating a watermark image histogram to be detected corresponding to the watermark image to be detected and an original watermark embedded image histogram corresponding to the original watermark embedded image;
the histogram comparison module is used for calculating a watermark image residual error matrix corresponding to the watermark image to be detected if the histogram of the watermark image to be detected is consistent with the histogram of the original watermark embedded image;
and the watermark detection module is used for carrying out image enhancement processing on the watermark image residual error matrix to obtain a watermark detection result.
10. The spatial domain residual feature fusion based watermark detection apparatus according to claim 9, wherein the histogram comparison module is further configured to: and if the histogram of the watermark image to be detected is not consistent with the histogram of the original watermark embedded image, performing histogram stipulation operation on the histogram of the watermark image to be detected according to the histogram of the original watermark embedded image, so that the operated histogram of the watermark image to be detected is consistent with the histogram of the original watermark embedded image.
CN202210792241.9A 2022-07-05 2022-07-05 Watermark embedding and detecting method and device based on spatial domain residual error feature fusion Active CN115187443B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN202210792241.9A CN115187443B (en) 2022-07-05 2022-07-05 Watermark embedding and detecting method and device based on spatial domain residual error feature fusion

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN202210792241.9A CN115187443B (en) 2022-07-05 2022-07-05 Watermark embedding and detecting method and device based on spatial domain residual error feature fusion

Publications (2)

Publication Number Publication Date
CN115187443A CN115187443A (en) 2022-10-14
CN115187443B true CN115187443B (en) 2023-04-07

Family

ID=83516461

Family Applications (1)

Application Number Title Priority Date Filing Date
CN202210792241.9A Active CN115187443B (en) 2022-07-05 2022-07-05 Watermark embedding and detecting method and device based on spatial domain residual error feature fusion

Country Status (1)

Country Link
CN (1) CN115187443B (en)

Family Cites Families (7)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JP3735521B2 (en) * 1999-09-30 2006-01-18 株式会社東芝 Embedded code generation method and apparatus, embedded code detection method and apparatus, and digital watermark embedding apparatus
CN1234070C (en) * 2003-06-19 2005-12-28 上海交通大学 Synchronous detection method of transformed digital watermark
CN104217389B (en) * 2014-01-22 2017-09-05 河南师范大学 A kind of method and apparatus based on the image watermark insertion, the extraction that improve Arnold conversion
CN111768328B (en) * 2020-07-07 2021-08-13 中国科学院自动化研究所 Text image watermark embedding method and system and text image watermark extracting method and system
CN114255151A (en) * 2020-09-25 2022-03-29 浙江工商大学 High-resolution image robust digital watermarking method based on key point detection and deep learning
CN112907435A (en) * 2021-04-09 2021-06-04 辽宁工程技术大学 High-robustness holographic blind watermarking algorithm based on improved Boqi coding and data interval mapping
CN114092302A (en) * 2021-10-25 2022-02-25 海南大学 Medical image robust watermarking method based on residual error network and depth separable convolution

Also Published As

Publication number Publication date
CN115187443A (en) 2022-10-14

Similar Documents

Publication Publication Date Title
Qi et al. A singular-value-based semi-fragile watermarking scheme for image content authentication with tamper localization
Cheema et al. A novel optimized semi-blind scheme for color image watermarking
Nasir et al. Multiple spatial watermarking technique in color images
Inamdar et al. Dual watermarking technique with multiple biometric watermarks
JPH10191017A (en) Method for imparting and detecting watermark
US9159112B2 (en) Digital watermarking using saturation patterns
US20230008085A1 (en) Method for embedding watermark in video data and apparatus, method for extracting watermark in video data and apparatus, device, and storage medium
Liu et al. Robust blind image watermarking based on chaotic mixtures
Fu et al. Watermarking scheme based on support vector machine for colour images
Jagadeesh et al. Fuzzy inference system based robust digital image watermarking technique using discrete cosine transform
Chakraborty et al. Reversible color image watermarking using trigonometric functions
Wan et al. Robust image watermarking based on two-layer visual saliency-induced JND profile
Juarez-Sandoval et al. Digital image ownership authentication via camouflaged unseen-visible watermarking
Huang et al. Protect fragile regions in steganography LSB embedding
CN113240569A (en) Fingerprint image encryption method, device and system
CN109829890A (en) A kind of jpeg image vector safety evaluation method
CN115187443B (en) Watermark embedding and detecting method and device based on spatial domain residual error feature fusion
Maheswari et al. Image Steganography using Hybrid Edge Detector and Ridgelet Transform.
Wazirali et al. Hyper Edge Detection with Clustering for Data Hiding.
CN112700363B (en) Self-adaptive visual watermark embedding method and device based on region selection
CN114630130A (en) Face-changing video tracing method and system based on deep learning
Dong et al. Frequency domain digital watermark algorithm implemented in spatial domain based on correlation coefficient and quadratic DCT transform
CN110570343B (en) Image watermark embedding method and device based on self-adaptive feature point extraction
Dixit et al. LWT-DCT based image watermarking scheme using normalized SVD
Li et al. A robust image hiding method based on sign embedding and fuzzy classification

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