Image hiding method and device based on compressed sensing and run-length encoding

CN116723278BActive Publication Date: 2026-08-28GUANGZHOU POWER SUPPLY BUREAU GUANGDONG POWER GRID CO LTD
View PDF 2 Cites 0 Cited by

Patent Information

Application Number
CN202310647279.1
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2023-06-02
Publication Date
2026-08-28
Estimated Expiration
2043-06-02

AI Technical Summary

Technical Problem

该算法相比于基于颜色转换的可逆算法在嵌入容量和伪装图像的视觉质量上都有很大的提高,但压缩感知又一定的压缩率限制,在压缩率太低的情况下,恢复的秘密图像质量将不令人满意

Benefits of technology

[0026]有益效果:与现有技术相比,本发明具有如下优点:本发明利用压缩感知和游程编码这两种压缩技术对秘密图像进行双重压缩,压缩感知对图像进行尺寸压缩,游程编码对图像进行数值压缩,两种方法的结合不仅减少了秘密图像的像素量,而且极大地减少了每个数值的大小。本发明利用整数小波变换对封面图像进行转换以获得一个低频子带和三个高频子带,考虑到双重压缩的数值结果和高频子带系数有着相似的表现形式,因此可以直接用双重压缩的数值替换高频子带系数完成嵌入操作。这不仅显著缩减了对封面图像像素值的损坏,保证了伪装图像的质量,而且计算复杂度低,节约计算资源。总之,本发明巧妙地结合了压缩感知、游程编码和高频子带嵌入技术,在保证高隐藏容量的前提下,极大地提高了伪装图像的质量,具有容量高、复杂度低等优点。

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN116723278B_ABST
    Figure CN116723278B_ABST
Patent Text Reader

Abstract

The application discloses an image hiding method and device based on compressed sensing and run-length coding. The method first compresses the size of a secret image needing security protection by using compressed sensing technology, then converts the decimal pixel value of the size-compressed secret image into a binary sequence, then compresses the binary sequence by using run-length coding to obtain a numerical sequence with a shorter length, and converts a cover image in a spatial domain into a frequency domain by using integer wavelet transform to obtain four subbands. The numerical sequence compressed twice has a similar form with the high-frequency subband coefficients of the cover image, and can directly replace the high-frequency subband coefficients to complete embedding operation. The application ingeniously combines compressed sensing, run-length coding and high-frequency subband embedding technology, greatly improves the quality of the camouflage image under the premise of ensuring high hiding capacity, and has the advantages of high capacity, low complexity and the like.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This invention relates to the field of information security technology, and in particular to an image hiding method and apparatus based on compressed sensing and run-length encoding. Background Technology

[0002] Image hiding technology refers to embedding one or more secret images into a carrier medium and being able to recover the original visually meaningful secret image. This characteristic of image hiding technology is of great significance to many fields such as military, medical, and copyright protection.

[0003] Common image hiding techniques include color-transformation-based reversible algorithms and compressed sensing-based reversible algorithms. Compressed sensing-based reversible algorithms are currently the mainstream approach. Their core idea is to compress the secret image using compressed sensing technology and then embed it into the target image using general embedding methods. Compared to color-transformation-based reversible algorithms, this algorithm significantly improves embedding capacity and the visual quality of the disguised image. However, compressed sensing has a certain compression ratio limitation; if the compression ratio is too low, the quality of the recovered secret image will be unsatisfactory. Summary of the Invention

[0004] Purpose of the invention: The purpose of this invention is to provide an image hiding method and apparatus based on compressed sensing and run-length encoding, which improves the quality of camouflaged images while ensuring high hiding capacity.

[0005] Technical Solution: To achieve the above objectives, the present invention adopts the following technical solution: an image hiding method based on compressed sensing and run-length encoding, comprising the following steps:

[0006] Compressed sensing technology is used to compress the size of the hidden secret image to reduce the number of pixels in the secret image;

[0007] Convert the decimal pixel values ​​of the compressed secret image to binary and concatenate them into a binary sequence;

[0008] The binary sequence is numerically compressed using run-length encoding to obtain a shorter numerical sequence;

[0009] Integer wavelet transform is used to convert the cover image in the spatial domain to the frequency domain to obtain four sub-bands;

[0010] Replace the coefficients of three high-frequency sub-bands among the four sub-bands with the values ​​of the numerical sequence;

[0011] The inverse integer wavelet transform is used to transform the four sub-bands after modification to obtain the camouflage image.

[0012] Preferably, each decimal pixel value of the size-compressed secret image is converted into an 8-bit binary number and concatenated into a binary sequence.

[0013] Preferably, the numerical sequence is embedded into four sub-bands LL, LH, HL, and HH in the frequency domain of the cover image according to the following method, where LL is the low-frequency sub-band and LH, HL, and HH are the high-frequency sub-bands; each digit in the sequence is replaced with each digit coefficient in the sub-band in a preset order, with the coefficients of the HH sub-band being replaced first, followed by HL and LH in sequence.

[0014] Preferably, if the numerical sequence is not fully embedded, the incomplete part of the sequence is transmitted as the key.

[0015] Preferably, when replacing the coefficients of the high-frequency subband with the values ​​of the numerical sequence, the signs of the coefficients are retained.

[0016] Furthermore, the method for performing the hidden inverse process to recover the original secret image from the disguised image includes:

[0017] The camouflaged image was subjected to integer wavelet transform to obtain four sub-bands, of which the coefficients of three high-frequency sub-bands were modified;

[0018] Extract the run-length encoded numerical sequence from the modified sub-band, and perform inverse run-length encoding on it to obtain the binary sequence;

[0019] Convert the binary sequence into decimal pixel values;

[0020] Compressed sensing technology is used to decompress the obtained decimal pixel values ​​to obtain visually meaningful secret images.

[0021] An image hiding device based on compressed sensing and run-length encoding includes: an initial compression module for compressing the size of the secret image to be hidden using compressed sensing technology to reduce the number of pixels in the secret image; a binary conversion module for converting the decimal pixel values ​​of the size-compressed secret image into binary and concatenating them into a binary sequence; an encoding module for numerically compressing the binary sequence using run-length encoding to obtain a shorter numerical sequence; an image domain conversion module for converting the cover image in the spatial domain to the frequency domain using integer wavelet transform to obtain four sub-bands; and an embedding module for replacing the coefficients of three high-frequency sub-bands in the four sub-bands with the values ​​of the numerical sequence, and transforming the modified four sub-bands using inverse integer wavelet transform to obtain a disguised image.

[0022] Preferably, the four sub-bands in the frequency domain of the cover image are LL, LH, HL, and HH, where LL is the low-frequency sub-band and LH, HL, and HH are the high-frequency sub-bands. The embedding module replaces each coefficient in the sub-band with each digit in the numerical sequence in a preset order, with the coefficients of the HH sub-band being replaced first, followed by HL and LH in that order.

[0023] Furthermore, the image hiding device further includes: a camouflage image domain conversion module, used to perform integer wavelet transform on the camouflage image to obtain four sub-bands, wherein the coefficients of three high-frequency sub-bands are modified; an inverse encoding module, used to extract the run-length encoded numerical sequence from the modified sub-bands and perform inverse run-length encoding on it to obtain a binary sequence; a binary inverse transformation module, used to convert the binary sequence into decimal pixel values; and a decompression module, used to decompress the obtained decimal pixel values ​​using compressed sensing technology to obtain a visually meaningful secret image.

[0024] Based on the same inventive concept, the present invention also provides a computer system, including a memory, a processor, and a computer program stored in the memory and executable on the processor, wherein the computer program, when loaded onto the processor, implements the steps of the image hiding method based on compressed sensing and run-length encoding.

[0025] Based on the same inventive concept, the present invention also provides a computer-readable storage medium storing a computer program that, when executed by a processor, implements the steps of the image hiding method based on compressed sensing and run-length encoding.

[0026] Beneficial Effects: Compared with existing technologies, this invention has the following advantages: This invention utilizes compressed sensing and run-length encoding to perform dual compression of the secret image. Compressed sensing compresses the image size, while run-length encoding compresses the image numerically. The combination of these two methods not only reduces the number of pixels in the secret image but also significantly reduces the size of each numerical value. This invention uses integer wavelet transform to convert the cover image to obtain one low-frequency subband and three high-frequency subbands. Considering that the numerical results of dual compression and the coefficients of the high-frequency subbands have similar representations, the high-frequency subband coefficients can be directly replaced with the dual-compressed values ​​to complete the embedding operation. This not only significantly reduces the damage to the pixel values ​​of the cover image and ensures the quality of the camouflaged image but also has low computational complexity and saves computational resources. In summary, this invention cleverly combines compressed sensing, run-length encoding, and high-frequency subband embedding techniques, greatly improving the quality of the camouflaged image while ensuring high hiding capacity, and has the advantages of high capacity and low complexity. Attached Figure Description

[0027] Figure 1This is a flowchart illustrating an embodiment of the present invention;

[0028] Figure 2 This is a secret image in an embodiment of the present invention;

[0029] Figure 3 This is the cover image in an embodiment of the present invention;

[0030] Figure 4 This is the compressed secret image in the embodiments of the present invention;

[0031] Figure 5 This is a camouflaged image in an embodiment of the present invention;

[0032] Figure 6 This is the recovered secret image in the embodiments of the present invention;

[0033] Figure 7 This is a map showing the horizontal pixel distribution of the secret image in an embodiment of the present invention;

[0034] Figure 8 This is a map showing the distribution of relevant pixels in the vertical direction of the secret image in an embodiment of the present invention;

[0035] Figure 9 This is a pixel distribution map of the secret image in the diagonal direction in an embodiment of the present invention;

[0036] Figure 10 This is a map showing the horizontal pixel distribution of the recovered secret image in an embodiment of the present invention.

[0037] Figure 11 This is a map showing the distribution of relevant pixels in the vertical direction of the recovered secret image in an embodiment of the present invention;

[0038] Figure 12 This is a diagram showing the distribution of relevant pixels in the diagonal direction of the recovered secret image in this embodiment of the invention;

[0039] Figure 13 This is a pixel distribution map of the cover image in the horizontal direction in an embodiment of the present invention;

[0040] Figure 14 This is a pixel distribution map of the cover image in the vertical direction in an embodiment of the present invention;

[0041] Figure 15 This refers to the relevant pixel distribution of the cover image in the diagonal direction in this embodiment of the invention;

[0042] Figure 16 This is a map showing the horizontal pixel distribution of the camouflaged image in an embodiment of the present invention.

[0043] Figure 17This is a map showing the relevant pixel distribution of the camouflaged image in the vertical direction in an embodiment of the present invention;

[0044] Figure 18 This is a pixel distribution map of the camouflaged image in the diagonal direction in an embodiment of the present invention. Detailed Implementation

[0045] The present invention will now be further described. The following embodiments are only used to more clearly illustrate the technical solution of the present invention, and should not be used to limit the scope of protection of the present invention.

[0046] like Figure 1 As shown in the figure, an image hiding method based on compressed sensing and run-length encoding disclosed in this invention first uses compressed sensing technology to compress the size of the secret image to be hidden, thereby reducing the number of pixels in the secret image; then, the decimal pixel values ​​of the size-compressed secret image are converted into binary and concatenated into a binary sequence, and run-length encoding is used to numerically compress the binary sequence to obtain a smaller numerical sequence; then, integer wavelet transform is used to transform the cover image in the spatial domain into the frequency domain to obtain four sub-bands, and the coefficients of three high-frequency sub-bands in the four sub-bands are replaced with the values ​​of the numerical sequence; finally, inverse integer wavelet transform is used to transform the modified four sub-bands to obtain the disguised image. This process is reversible, and the visually meaningful original secret image can be recovered based on the inverse process.

[0047] The image hiding method according to an embodiment of the present invention will be described in detail below, specifically including the following steps:

[0048] S1. Image Compression: To ensure the cover image has a sufficiently large embedding capacity to embed the secret image, or to embed more secret images into a single cover image, the downsampling rate of the secret image needs to be determined first. For compressed sensing technology, the downsampling rate SR can be arbitrarily chosen as needed. To ensure sufficient embedding capacity in the cover image and adequate quality in recovering the secret image, we choose a downsampling rate SR of 0.25 in this example. This is because research has shown that a compression rate of 0.25 achieves a balance between the quality of the camouflage image and the quality of the recovered secret image.

[0049] Based on the determined downsampling rate SR, compressed sensing is used to downsample the secret image to obtain a size-compressed secret image.

[0050] The compression process expression of compressed sensing is:

[0051]

[0052] Here, Φ1 and Φ2 are two measurement matrices, corresponding to the downsampling process, where the secret image S is projected onto a low-dimensional space by the measurement matrices; B is the result after downsampling. Applicable measurement matrices include partial Fourier matrices, partial Hadamard matrices, Gaussian random matrices, etc.

[0053] In this example, assuming the size of the secret image is M×N and the sizes of the two measurement matrices Φ1 and Φ2 are M×N, the size of the compressed secret image is M×N×0.25.

[0054] S2. Number system conversion: To facilitate subsequent processing, each decimal pixel value of the compressed secret image obtained in step S1 is converted into an 8-bit binary sequence, and then all the 8-bit binary sequences are concatenated into a complete binary sequence.

[0055] The specific steps for converting all decimal numbers to binary numbers and concatenating them into a complete binary sequence are as follows:

[0056] S2.1 For a decimal number, divide the decimal number by 2, record the remainder, and round down to get the quotient.

[0057] S2.2 Store the recorded remainders into an array or string.

[0058] S2.3 If the quotient is not 0, repeat steps S2.1 and S2.2 until the quotient is 0.

[0059] S2.4. Reverse the order of the remainders stored in the array or string. If the remainders are less than 8 bits, add leading zeros to obtain an 8-bit binary representation.

[0060] S2.5. Repeat steps S2.1 to S2.4 for each decimal number to obtain an 8-bit binary representation of all decimal numbers.

[0061] S2.6. Concatenate all the 8-bit binary numbers obtained in step S2.5 into a complete binary number. In this example, the length of the complete binary sequence is 8×M×N×0.25.

[0062] S3. Run-length encoding: Run-length encoding is performed on the complete binary sequence obtained in step S2 to reduce the length of the binary sequence.

[0063] The specific steps of run-length encoding are as follows. Let the complete binary sequence be L, and the numerical sequence obtained after run-length encoding be K. Assume that the length of the numerical sequence K is G.

[0064] S3.1 Initialize the counter count = 1 and the run-length encoded sequence K.

[0065] S3.2, Starting from the second element of L, traverse L. For each element:

[0066] S3.2.1 If the element is the same as the previous element, increment the count by 1.

[0067] S3.2.2 If the element is different from the previous element, add the previous element and its occurrence count (i.e., count) to K, and reset the counter count to 1.

[0068] S3.3 Add the last element and its occurrence count to K.

[0069] S3.4 Return the run-length encoded sequence K.

[0070] In this example, it is assumed that a complete binary sequence of length 8×M×N×0.25 is encoded into a numerical sequence of length G, where the length of G is 1 to 2×M×N.

[0071] S4. Image Domain Transformation: In order to successfully embed the secret image into the cover image, the cover image in the spatial domain needs to be transformed into the frequency domain using the integer wavelet transform algorithm to obtain four sub-bands, denoted as LL, LH, HL, and HH, where LL is the low-frequency sub-band and LH, HL, and HH are the high-frequency sub-bands.

[0072] The expression for image domain transformation using integer wavelet transform is as follows:

[0073]

[0074] Among them, C j.k and D j,k These represent the low-frequency and high-frequency components of the image after transformation, respectively. j represents the row of the image, k represents the column, and [] denotes rounding down. In this example, assuming the cover image size is m×n, then j∈[1,m]. The sizes of the four subbands LL, LH, HL, and HH after the transformation are all 1.

[0075] S5. Secret Information Embedding: Embed the numerical sequence K obtained in step S3 into the subbands LH, HL, and HH obtained in step S4. The LL subband is not used for embedding information. The embedding algorithm of this invention replaces each coefficient in the subband with each digit of the numerical sequence K in a preset order, such as from top to bottom and from left to right. The coefficients of the HH subband are replaced first, followed by HL and LH. This yields the modified subbands LL, LH′, HL′, and HH′.

[0076] In this example, the sizes of the four subbands LL, LH′, HL′, and HH′ after the secret information is embedded are still 1. If the length of the numerical sequence K is less than or equal to The numerical sequence K can be completely embedded in subbands LH, HL, and HH; if the length of the numerical sequence K is greater than We only embed the first few bits of the numerical sequence K. The values ​​are transmitted to subbands LH, HL, and HH, while the remaining unembedded values ​​are transmitted as the key.

[0077] S6. Inverse Integer Wavelet Transform: Perform inverse integer wavelet transform on the modified subbands LL, LH′, HL′, HH′ obtained in step S5 to obtain the camouflage image in the spatial domain.

[0078] The expression for the inverse integer wavelet transform corresponding to the integer wavelet transform expression in step S4 is as follows:

[0079]

[0080] In this example, we now have a disguised image of size m×n, which is visually meaningful and similar to the cover image.

[0081] The secret image embedded in the cover image can be recovered from the disguised image. For example... Figure 2 As shown, the specific steps to recover the secret image are as follows:

[0082] SA: Perform integer wavelet transform on the camouflaged image to obtain the modified subbands LL,LH′,HL′,HH′.

[0083] SB, based on the length G of the run-length encoded numerical sequence obtained in step S4, extract G coefficients sequentially from subbands LL, LH′, HL′, HH′ in reverse order of S5. The length G of the numerical sequence needs to be known in advance during the recovery of the secret image. Here, G can be used as a key to be transmitted additionally over a secure network.

[0084] SC. Perform reverse run-length encoding on the G coefficients obtained in step SB to obtain a binary sequence.

[0085] SD converts the binary sequence obtained in step SC into decimal pixel values ​​in units of 8 bits each.

[0086] SE: Decompress the decimal pixel values ​​obtained in step SD using compressed sensing to obtain a visually meaningful secret image.

[0087] In this example, a secret image of size M×N can be obtained through the secret image recovery process. It is visually meaningful and similar to the original secret image.

[0088] The following is an illustrative example of an image hiding method based on compressed sensing and run-length encoding, simulated using MATLAB 2022 software. Images are essentially matrices. For ease of explanation, we assume the cover image matrix C is [22,19,24,18; 18,16,25,27; 9,10,15,23; 20,19,11,13], and the secret image matrix S is [2,8,9,11; 23,32,21,22; 20,19,18,21; 4,11,10,12].

[0089] The secret image S is hidden within the cover image C using an image hiding method based on compressed sensing and run-length encoding. The specific process is as follows:

[0090] (1) Downsampling the secret image: In this example, the downsampling rate SR = 0.25 is determined. Compressed sensing is used to downsample the secret image to obtain a size-compressed secret image. In this example, a Gaussian random matrix is ​​used to generate the measurement matrix. In this example, assuming the size of the secret image is 4×4 and the sizes of the two measurement matrices Φ1 and Φ2 are 4×4, the size of the compressed secret image is 2×4. Assume the compressed secret image matrix is ​​[10,8,12,20].

[0091] (2) Number system conversion: In this example, the compressed secret image matrix [10,8,12,20] obtained in step (1) is converted to a number system to obtain a binary sequence "00001010000010000000110000010100" with a length of 8×4×4×0.25=32.

[0092] (3) Run-length encoding: In this example, the complete binary sequence “00001010000010000000110000010100” with a length of 32 obtained in step (2) is encoded into a numerical sequence K “4111517251112” with a length of 13.

[0093] (4) Image domain transformation: In this example, the cover image matrix C of size 4×4 is [22,19,24,18; 18,16,25,27; 9,10,15,23; 20,19,11,13]. After integer wavelet transform, four subbands LL, LH, HL, and HH of size 2×2 are obtained, which are LL=[22,24; 9,15], LH=[3,6; -1,-8], HL=[4,-1,-11,4], and HH=[1,8; -2,-6].

[0094] (5) Embedding of secret information: In this example, the numerical sequence K "4111517251112" obtained in step (3) is replaced with HH, HL, and LH in sequence. The modified subband HH′ = [4,1; 1,1], HL′ = [5,1; 7,2], and LH′ = [5,1,1,1]. The remaining "2" is not embedded and will be transmitted as the key. In addition, the sign of the coefficients in the subband can also be retained, because the encoded numerical sequence is all positive, and only the absolute value of the coefficients needs to be extracted during the extraction process. If the sign of the subband coefficients is retained, the modified subband HH′ = [4,1; -1, -1], HL′ = [5, -1; -7,2], and LH′ = [5,1, -1, -1].

[0095] (6) Inverse integer wavelet transform: In this example, performing the inverse integer wavelet transform on the four subbands LL=[22,24;9,15],HL′=[5,1;7,2],LH′=[5,1,1,1],HH′=[4,1;1,1] can obtain a camouflage image matrix H=[22,17,24,23;17,16,23,23;9,2,15,13;8,2,14,13], which is similar to the cover image matrix.

[0096] (7) Secret Image Recovery: In this example, the hidden reverse process is performed on the disguised image matrix H = [22,17,24,23; 17,16,23,23; 9,2,15,13; 8,2,14,13] to obtain the recovered secret image S = [3,7,9,10; 20,35,21,22; 22,19,14,20; 7,12,10,15], which is similar to the pixel values ​​of the original secret image matrix.

[0097] The performance of the upsampling-based multi-image reversible hiding method in this embodiment is analyzed below.

[0098] I. Analysis of the quality of camouflaged images

[0099] Currently, the most widely used image quality evaluation metrics are Peak Signal-to-Noise Ratio (PSNR) and Mean Structural Similarity (MSSIM). A higher PSNR value and an MSSIM closer to 1 indicate better visual quality. Here, a Pepper image of size 512×512 is selected as the secret image, as shown... Figure 2 A 512x512 image of Lena was used as the cover image, such as... Figure 3 With a downsampling rate of 0.25, the size of the compressed secret image is 128×512. Figure 4 The final generated camouflage image and the recovered secret image are as follows: Figure 5 and 6In addition, the PSNR and MSSIM, which measure the quality of camouflaged images and the quality of recovered secret images, are shown in Table 1 below.

[0100] Table 1. Quality of Camouflaged Images

[0101]

[0102] from Figure 4 It can be observed that the compressed secret image in this embodiment appears to be noise-like, which further protects the security of the secret image. Figure 5 The generated camouflage image is shown, and it can be observed that it is visually indistinguishable from the cover image, indicating that we have obtained a high-quality camouflage image. Additionally, a comparison... Figure 6 and Figure 2 The discovery revealed no significant difference between the two, indicating that the recovered secret image was visually meaningful and that the disguised image successfully protected the secret image.

[0103] As shown in Table 1, in this embodiment, the PSNR of the camouflaged image reached 30dB, and the MSSIM reached 0.7639, indicating that the camouflaged image is extremely similar to the cover image. This satisfies the requirements for image concealment, and the visually meaningful camouflaged image can be securely transmitted over the network. Furthermore, the PSNR and MSSIM of the recovered secret image are 27.38dB and 0.6907 respectively, indicating that the recovered secret image is very similar to the original secret image.

[0104] II. Correlation Analysis of Adjacent Pixels

[0105] The correlation between adjacent pixels is used to analyze the relationship between the values ​​of adjacent pixels. For a good image hiding method, the camouflaged image should have high pixel correlation. Here, the correlation coefficient is used to measure the strength of the correlation between pixels; the closer the correlation coefficient is to 1, the stronger the correlation between pixels.

[0106] The correlation coefficients of the secret image and the restored image, as well as the cover image and the camouflage image, in the horizontal, vertical, and diagonal directions are shown in Table 2 below. The pixel distributions of the secret image, the restored secret image, the cover image, and the camouflage image are shown below. Figure 7-9 , Figure 10-12 , Figure 13-15 , Figure 16-18 As shown in Table 2, the correlation coefficients of the secret image and the recovered secret image, the cover image and the disguise image are similar in all three directions and are close to 1, which further proves that our scheme has a good concealment effect.

[0107] Table 2 Correlation coefficients

[0108]

[0109] Based on the same inventive concept, this invention discloses an image hiding device based on compressed sensing and run-length encoding, comprising: an initial compression module for compressing the size of the secret image to be hidden using compressed sensing technology to reduce the number of pixels in the secret image; a binary conversion module for converting the decimal pixel values ​​of the size-compressed secret image into binary and concatenating them into a binary sequence; an encoding module for numerically compressing the binary sequence using run-length encoding to obtain a shorter numerical sequence; an image domain conversion module for converting the cover image in the spatial domain to the frequency domain using integer wavelet transform to obtain four sub-bands; and an embedding module for replacing the coefficients of three high-frequency sub-bands in the four sub-bands with the values ​​of the numerical sequence, and transforming the modified four sub-bands using inverse integer wavelet transform to obtain a disguised image. Furthermore, the image hiding device further includes: a camouflage image domain conversion module, used to perform integer wavelet transform on the camouflage image to obtain four sub-bands, wherein the coefficients of three high-frequency sub-bands are modified; an inverse encoding module, used to extract the run-length encoded numerical sequence from the modified sub-bands and perform inverse run-length encoding on it to obtain a binary sequence; a binary inverse transformation module, used to convert the binary sequence into decimal pixel values; and a decompression module, used to decompress the obtained decimal pixel values ​​using compressed sensing technology to obtain a visually meaningful secret image. This system embodiment and the aforementioned method embodiment belong to the same inventive concept. For specific implementation details of each module, please refer to the above method embodiment, which will not be repeated here.

[0110] Based on the same inventive concept, this invention also discloses a computer system, including a memory, a processor, and a computer program stored in the memory and executable on the processor. When the computer program is loaded onto the processor, it implements the steps of the image hiding method based on compressed sensing and run-length encoding.

[0111] Based on the same inventive concept, embodiments of the present invention also disclose a computer-readable storage medium storing a computer program, which, when executed by a processor, implements the steps of the image hiding method based on compressed sensing and run-length encoding.

[0112] Those skilled in the art will understand that the technical solution of this invention, or the part that contributes to the prior art, can be embodied in the form of a software product. This computer software product is stored in a storage medium and includes several instructions to cause a computer system (which may be a personal computer, server, or network device, etc.) to execute all or part of the steps of the method described in the embodiments of this invention. The storage medium includes various media capable of storing computer programs, such as a USB flash drive, portable hard drive, read-only memory (ROM), random access memory (RAM), magnetic disk, or optical disk.

[0113] Finally, it should be noted that the above embodiments are only used to illustrate the technical solutions of the present invention and not to limit it. Although the present invention has been described in detail with reference to the above embodiments, those skilled in the art should understand that modifications or equivalent substitutions can still be made to the specific implementation of the present invention. Any modifications or equivalent substitutions that do not depart from the spirit and scope of the present invention should be covered within the scope of protection of the claims of the present invention.

Claims

1. An image hiding method based on compressed sensing and run-length encoding, characterized in that, Includes the following steps: Compressed sensing technology is used to compress the size of the hidden secret image to reduce the number of pixels in the secret image; Convert the decimal pixel values ​​of the compressed secret image to binary and concatenate them into a binary sequence; The binary sequence is numerically compressed using run-length encoding to obtain a shorter numerical sequence; Integer wavelet transform is used to convert the cover image in the spatial domain to the frequency domain to obtain four sub-bands; Replace the coefficients of three high-frequency sub-bands among the four sub-bands with the values ​​of the numerical sequence; The inverse integer wavelet transform is used to transform the four sub-bands after modification to obtain the camouflage image.

2. The image hiding method based on compressed sensing and run-length encoding according to claim 1, characterized in that, Each decimal pixel value of the compressed secret image is converted into an 8-bit binary number and concatenated into a binary sequence.

3. The image hiding method based on compressed sensing and run-length encoding according to claim 1, characterized in that, The numerical sequence is embedded into four sub-bands LL, LH, HL, and HH in the frequency domain of the cover image according to the following method, where LL is the low-frequency sub-band and LH, HL, and HH are the high-frequency sub-bands; each digit in the sequence is replaced with each digit coefficient in the sub-band in a preset order, with the coefficients of the HH sub-band being replaced first, followed by HL and LH in that order.

4. The image hiding method based on compressed sensing and run-length encoding according to claim 3, characterized in that, If the numerical sequence is not fully embedded, the incomplete part of the sequence is transmitted as the key.

5. The image hiding method based on compressed sensing and run-length encoding according to claim 1, characterized in that, When replacing the coefficients of the high-frequency subband with the values ​​of the numerical sequence, the signs of the coefficients are preserved.

6. The image hiding method based on compressed sensing and run-length encoding according to claim 1, characterized in that, A method for recovering the original secret image from a disguised image by performing the inverse process of concealment includes: The camouflaged image was subjected to integer wavelet transform to obtain four sub-bands, of which the coefficients of three high-frequency sub-bands were modified; Extract the run-length encoded numerical sequence from the modified sub-band, and perform inverse run-length encoding on it to obtain the binary sequence; Convert the binary sequence into decimal pixel values; Compressed sensing technology is used to decompress the obtained decimal pixel values ​​to obtain visually meaningful secret images.

7. An image hiding device based on compressed sensing and run-length encoding, characterized in that, include: The initial compression module is used to compress the size of the secret image to be hidden using compressed sensing technology to reduce the number of pixels in the secret image; The binary conversion module is used to convert the decimal pixel values ​​of the compressed secret image into binary and concatenate them into a binary sequence; An encoding module is used to numerically compress the binary sequence using run-length encoding to obtain a shorter numerical sequence. The image domain conversion module is used to convert the cover image in the spatial domain to the frequency domain using integer wavelet transform to obtain four sub-bands; An embedding module is used to replace the coefficients of three high-frequency sub-bands among the four sub-bands with the values ​​of the numerical sequence, and to transform the modified four sub-bands using inverse integer wavelet transform to obtain a camouflage image.

8. An image hiding device based on compressed sensing and run-length encoding according to claim 7, characterized in that, Also includes: The camouflage image domain transformation module is used to perform integer wavelet transform on the camouflage image to obtain four sub-bands, of which the coefficients of three high-frequency sub-bands have been modified; The inverse encoding module is used to extract the run-length encoded numerical sequence from the modified sub-band and perform inverse run-length encoding on it to obtain a binary sequence. The binary inverse conversion module is used to convert the binary sequence into decimal pixel values; The decompression module is used to decompress the obtained decimal pixel values ​​using compressed sensing technology to obtain visually meaningful secret images.

9. A computer system comprising a memory, a processor, and a computer program stored in the memory and executable on the processor, characterized in that, When the computer program is loaded into the processor, it implements the steps of an image hiding method based on compressed sensing and run-length encoding according to any one of claims 1-5.

10. A computer-readable storage medium storing a computer program, characterized in that, When the computer program is executed by the processor, it implements the steps of an image hiding method based on compressed sensing and run-length encoding according to any one of claims 1-5.

Citation Information

Patent Citations

  • Secure spread spectrum watermarking for multimedia data

    CA2184949A1

  • Method for identifying commutation failure fault of high-voltage direct-current power transmission system based on multiple data

    CN115951110A