Fast Color Image Compression Method Based on Split Quaternion Model

Through the combination of split quaternion model and singular value decomposition, the problem of high computational complexity in color image compression is solved, and efficient color image compression is achieved and image quality is maintained.

CN115474048BActive Publication Date: 2025-07-04CRRC QINGDAO SIFANG ROLLING STOCK RESEARCH INSTITUTE CO LTD
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN202211113127.5
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2022-09-14
Publication Date
2025-07-04
Estimated Expiration
2042-09-14

AI Technical Summary

Technical Problem

When processing color images, existing color image compression methods ignore the intrinsic connections between color channels, resulting in high computational complexity and low efficiency.

Method used

Using the split quaternion model, the color image is represented as a split quaternion matrix. By calculating the singular value decomposition of the actually representing the matrix, combining the threshold function to reduce the dimensions, and storing the best approximation matrix to complete image compression.

Benefits of technology

While maintaining the intrinsic connection between the three primary color channels of the color image, it significantly reduces the computational complexity, improves the compression efficiency and visual fidelity of image reconstruction.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN115474048B_ABST
    Figure CN115474048B_ABST
Patent Text Reader

Abstract

The present invention provides a fast color image compression method based on a split quaternion model. The steps of this method mainly include: S1: Construct a split quaternion model, and represent the original color image with the split quaternion model to obtain a split quaternion matrix; S2: Calculate the real representation matrix of the split quaternion matrix and the singular value decomposition of the real representation matrix; S3: Calculate the singular value decomposition of the split quaternion matrix according to the singular value decomposition of the real representation matrix, that is, the singular value decomposition of the original color image; S4: Substitute the given threshold and the singular value norm of the split quaternion matrix into the threshold function to obtain the dimensionality reduction degree; S5: Under the constraint of the threshold function, according to the dimensionality reduction degree, store the effective decomposition matrix of the best approximation matrix to complete image compression. The present invention can maintain the internal connection between the three primary color channels of the color image, greatly reduce the computational complexity, and the corresponding calculation time. The PSNR value and the SSIM value show the good performance of the method of the present invention.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present invention relates to the technical field of image processing, and relates to a fast color image compression method based on a split quaternion model. Background Art

[0002] Images are one of the most important information carriers in the field of visual information. The increasing use of digital images has caused problems in storage and transmission. Image compression is a commonly used processing method, the purpose of which is to transform and combine the source data of the image to be processed according to certain rules, so as to represent the image with as few bits as possible, and at the same time restore the quality of the image as well as possible to meet the requirements of a predetermined application scenario. The reasons why image data can be compressed are mainly as follows: (1) There is a certain correlation between the pixels that make up the image, whether in the row direction or the column direction, that is, the original image data is highly correlated. Applying a certain coding method to extract or reduce these correlations can achieve the purpose of compressing the data; (2) From the perspective of information theory, the data describing the image source is composed of two parts: effective information and redundancy. Removing the redundancy can save the overhead in transmission and storage, and at the same time does not damage the effective information of the image source; (3) Allowing a certain degree of distortion in image coding in many cases is also an important reason why images can be compressed. Since the initial research on image compression in 1948, the compression methods and technologies for grayscale images have been greatly developed. However, due to the rapid application of color image technology in real life and network technology, researchers have turned their attention to color image compression. See the literature "Wu P., Xie K., Yu H., Zheng Y., Yu W., A new preprocessing algorithm used in color image compression. Advances in FCCS, 1, AISC. 2012; 159: 465-471." and "Singh S.K., Kumar S., A framework to design novel SVD based color image compression. Third UKSim European Symposium on Computer Modeling and Simulation, IEEE. 2009; 235-240." Compared with grayscale images, color images can greatly improve the information capacity and fidelity. It can be decomposed into multiple color channels, so the compression of color images is more challenging than that of single grayscale images.

[0003] Regarding color images, there are various techniques such as YCbCr, RGB, YIQ, HSI, etc. in the literature. Among them, RGB is obviously the most popular technical means because this channel format can express colors most naturally in the real world. Each of the three channels R, G, and B is highly correlated with the other two. One of the typical algorithms for color image compression is multi-channel compression. For example, in the literature "Wu P., Xie K., Yu H., Zheng Y., Yu W., A new preprocessing algorithm used in color image compression. Advances in FCCS, 1, AISC. 2012; 159: 465 - 471.", the color image is first decomposed into individual color channels, and then the individual color channels are processed independently. The essence of this method is to process grayscale images, but the drawback of this processing method is that it ignores the connection between color channels. That is to say, on the basis of the original grayscale image processing methods and techniques, traditional color image compression processing is to divide a color image as a whole into three R, G, and B grayscale images, and then combine the processing results of the three grayscale images to construct the original color image. Obviously, this technology forcibly separates and processes the three-dimensional combined components, ignoring the internal connection between the components.

[0004] In recent years, algorithms based on quaternions have been very common. The pixels of a color image can be regarded as quaternions. Therefore, a color image can be considered as a quaternion matrix. If the whole color pixel is processed, then the spectral relationship between color channels will run through the whole operation and processing process. However, we must note that this type of algorithm requires more operations. The equivalent isomorphism between any split quaternion matrix and a 2m×2n real matrix makes this type of algorithm simple, which is also caused by the special four-dimensional algebraic structure of split quaternions. Traditional quaternions do not have this real equivalent isomorphism relationship.

[0005] Compression algorithms using Singular Value Decomposition (SVD) have become increasingly popular. For example, in the literature "Singh S.K., Kumar S., A framework to design novel SVD - based color image compression. Third UKSim European Symposium on Computer Modeling and Simulation, IEEE. 2009; 235 - 240.", the RGB image is converted to the YCbCr format, and then SVD compression is performed on the three components of luminance, blue, and red respectively. In the literature "Andrews H.C., Patterson C.L., Singular value decompositions and digital image processing. IEEE Transactions on Acoustics, Speech and Signal Processing. 1976; 1(24): 26 - 53. doi:10.1109 / TASSP.1976.1162766.", an image compression technique based on SVD and DCT is proposed. In the literature "Aharon M., Elad M., Bruckstein A., K - SVD: an algorithm for designing overcomplete dictionaries for sparse representation. IEEE Transactions on Signal Processing. 2006; 11(54): 4311 - 4322. doi:10.1109 / TSP.2006.881199." and the literature "Bryta O., Elad M., Compression of facial images using the K - SVD algorithm. J. Visual Commmuion and Image Representation, 2008; 19(4): 270 - 282. doi:10.1016 / j.jvcir.2008.03.001.", the entire image is divided into several sub - blocks of equal size, and SVD is performed on each sub - block.In the literature "Shih Y.T., Chien C.S., Chuang C.Y., An adaptive parameterized block-based singular value decomposition for image de-noise and compression. Appl. Math. Comput. 2012; 218: 10370-10385.", an algorithm was proposed. By studying the relationship between the required PSNR value and the number of singular values, the appropriate number of singular values was automatically selected for each sub-block. It can be seen that dealing with image compression problems based on matrix singular value theory and algorithms is also a research hotspot. Especially after its combination with four-dimensional matrix algebra theory, it not only gives a mathematical model explanation for the image compression algorithm, but also preserves the internal connection between color channels to a certain extent.

[0006] A color image can be represented by a pure imaginary quaternion matrix. Furthermore, some color image problems can be transformed into algebraic structure problems of quaternion matrices, and some quaternion matrix algorithms have thus evolved. For example: Quaternion Toolbox (abbreviation: QTFM), complex structure-preserving algorithms for quaternion problems, and real structure-preserving algorithms for quaternion problems, etc. However, in this representation form, three-dimensional color image problems are transformed into four-dimensional quaternion matrix problems. Each step of processing the problem must ensure the algebraic structure of the quaternion matrix. Although the internal connection between the R, G, and B components of the color image is preserved, the computational complexity of the problem has also increased significantly. Summary of the Invention

[0007] The purpose of the present invention is to solve one of the above technical problems, and provide a fast color image compression method based on the split quaternion model, which can maintain the internal connection between the R, G, and B primary color channels of the color image and greatly reduce the computational complexity.

[0008] To achieve the above purpose, the technical solution adopted by the present invention is:

[0009] A fast color image compression method based on the split quaternion model includes the following steps:

[0010] S1: Construct a split quaternion model, and represent the original color image with the split quaternion model to obtain a split quaternion matrix A;

[0011] S2: Calculate the real representation matrix of the split quaternion matrix A and the singular value decomposition of the real representation matrix;

[0012] S3: Calculate the singular value decomposition of the split quaternion matrix A according to the singular value decomposition of the real representation matrix, that is, the singular value decomposition of the original color image;

[0013] S4: Given a threshold, substitute the given threshold and the singular value norm of the split quaternion matrix A into the threshold function to obtain the degree of dimensionality reduction.

[0014] S5: Under the constraint of the threshold function, select the best approximation matrix of the original color image, and store the effective decomposition matrix of the best approximation matrix according to the degree of dimensionality reduction to complete image compression.

[0015] In some embodiments of the present invention, in step S1, when the real part of the split quaternion model is zero, the split quaternion model is expressed as:

[0016] q(x,y) = r(x,y)i + g(x,y)j + b(x,y)k (1)

[0017] In the formula, r(x,y), g(x,y), and b(x,y) respectively represent the red, green, and blue at the point (x,y) in the color image, that is, the pixel point in the x-th row and y-th column of the three-primary color matrix, and i, j, and k are the three imaginary part units of the split quaternion q.

[0018] In some embodiments of the present invention, in step S1, the original color image has m rows and n columns, and the original color image is expressed in the split quaternion model as:

[0019]

[0020] In the formula, A is the split quaternion matrix of the original color image, and R, G, and B are real matrices, respectively representing the red, green, and blue color matrices; represents the split quaternion ring H s an m×n matrix.

[0021] In some embodiments of the present invention, in step S2, the specific steps for calculating the real representation matrix of the split quaternion matrix are as follows:

[0022] For any split quaternion matrix where A s is an m×n real matrix, s = 1, 2, 3, 4, the real representation matrix A σ of the split quaternion matrix A is defined as:

[0023]

[0024] And the real representation matrix satisfies the following equation:

[0025] (A + D) σ = A σ + D σ , (AC) σ = A σ C σ , (aA) σ= aA σ , (A H ) σ = (A σ ) T (4)

[0026] Wherein, is an arbitrary m×n split quaternion matrix, is an arbitrary n×p split quaternion matrix, a is a real number, represents the i-conjugate transpose matrix of the split quaternion matrix A, represents the real matrix A s transpose matrix;

[0027] Calculate the real representation matrix of the split quaternion matrix through formula (3).

[0028] In some embodiments of the present invention, in step S2, the specific steps for calculating the singular value decomposition of the real representation matrix are as follows:

[0029] For any split quaternion matrix Let m≥n, according to the singular value decomposition theory of the real representation matrix, there exists an orthogonal matrix and a real matrix such that:

[0030]

[0031] Wherein, u i ∈R 2m , i = 1, 2,..., 2n, τ1≥τ2≥…≥τ 2n ≥0, τ1, τ2,…, τ 2n are the singular values of the real representation matrix A σ , v j ∈R 2n , j = 1, 2,…, 2n;

[0032] Calculate the singular value decomposition of the real representation matrix A σ through formula (5).

[0033] In some embodiments of the present invention, in step S3, the specific steps for obtaining the singular value decomposition of the split quaternion matrix are as follows:

[0034] Calculate the non-zero singular value σ of the split quaternion matrix A according to the following formula t :

[0035]

[0036] Wherein, p is the number of non - zero singular values of the real representation matrix A σ ;

[0037] Through the construction form of the singular values and τ1≥τ2≥…≥τ p ≥0, we get |σ1|≥|σ2|≥…≥|σ r |≥0;

[0038] Calculate the left and right singular vectors of the split - quaternion matrix A according to the following formula:

[0039]

[0040] Wherein, μ s is a left singular vector of the split - quaternion matrix A, ν s is a right singular vector of the split - quaternion matrix A, s = 1,2,…,n; Satisfying k = 1,2,…,2n;

[0041] Combining formula (6) and formula (7), there exists a unique diagonal split - quaternion matrix Σ r = diag(σ1,σ2,…,σ r ),|σ1|≥|σ2|≥…≥|σ r |≥0, such that:

[0042]

[0043] Wherein, U H U = I n ,V H V = I n ;

[0044] Then σ1,…,σ r are called the singular values of the split - quaternion matrix A;

[0045] According to the singular - value decomposition of the split - quaternion matrix A, the component - product form of the singular - value decomposition of the split - quaternion matrix A is as follows:

[0046]

[0047] Wherein, μ t is the left singular vector, that is, the column of U; ν t is the right singular vector, that is, the column of V;

[0048] In some embodiments of the present invention, in step S4, the specific steps to obtain the dimensionality reduction degree are:

[0049] Given a threshold value, substitute the given threshold value and the singular value norm of the split quaternion matrix A into the following threshold function:

[0050]

[0051] wherein is the optimal approximation matrix of the split quaternion matrix A, α = s - 1 is the number of singular values of the split quaternion matrix A, and s is the degree of dimensionality reduction;

[0052] Calculate the degree of dimensionality reduction through formula (10).

[0053] In some embodiments of the present invention, in step S5, the specific steps of storing the effective decomposition matrix of the optimal approximation matrix according to the degree of dimensionality reduction are as follows: according to the degree of dimensionality reduction, retain α = s - 1 singular values, then the singular value decomposition of the m×n original color image is into an m×α matrix, an α×α matrix, and an n×α matrix. Since α is much smaller than the minimum of {m, n}, at this time, storing the three matrices of the m×α matrix, the α×α matrix, and the n×α matrix can complete image compression.

[0054] In some embodiments of the present invention, the specific steps of reconstructing the optimal approximation matrix are as follows: extract the m×α matrix, the α×α matrix, and the n×α matrix of the decomposition matrix of the compressed image in step S5, and multiply the three decomposition matrices to satisfy the matrix multiplication m×n = (m×α)×(α×α)×(n×α) H , reconstruct the optimal approximation matrix, and after visualizing the optimal approximation matrix, obtain an approximate image of the original color image to complete the reconstruction of image compression.

[0055] Compared with the prior art, the beneficial effects of the present invention are as follows:

[0056] A fast color image compression method based on a split quaternion model is proposed. For the first time, the split quaternion matrix theory is used to deal with color image problems. Through the equivalent transformation of practical problems, the three-dimensional color image compression problem is transformed into the singular value decomposition problem of the split quaternion matrix. In the process of color image compression, traditional image processing methods are no longer used, and there is no need to split the original color image into three grayscale images for processing. To a certain extent, the internal connection between the three primary color channels is maintained. Different from using quaternion algebraic techniques to deal with color image problems, in the matrix decomposition process, there is no need to ensure the algebraic structure of the split quaternion matrix, which is completely simplified into a 2m×2n real matrix problem, converting the four-dimensional space problem into a two-dimensional space problem, and greatly reducing the computational complexity. BRIEF DESCRIPTION OF THE DRAWINGS

[0057] To more clearly illustrate the technical solutions in the embodiments of the present invention, the following will briefly introduce the accompanying drawings required for use in the embodiments or the description of the prior art. Obviously, the accompanying drawings in the following description are only some embodiments of the present invention. For those of ordinary skill in the art, without creative efforts, other accompanying drawings can be obtained based on these drawings.

[0058] Figure 1 It is a flowchart of the fast color image compression method based on the split quaternion model provided by the present invention.

[0059] Figure 2a It is a comparison chart of the CPU time between the fast color image compression method based on the split quaternion model provided by the present invention and five existing SVD algorithms.

[0060] Figure 2b It is a comparison chart of the errors between the fast color image compression method based on the split quaternion model provided by the present invention and five existing SVD algorithms.

[0061] Figure 3a It is the original color image of Lena.

[0062] Figure 3b It is the original color image of Baboon.

[0063] Figure 3c It is the original color image of Peppers.

[0064] Figure 3d It is the original color image of Airplane.

[0065] Figure 4a It is a compressed image that retains 10 singular values of the color image "Lena" based on the fast color image compression method based on the split quaternion model provided by the present invention.

[0066] Figure 4b It is a compressed image that retains 10 singular values of the color image "Lena" based on the SVD algorithm of the existing quaternion toolbox.

[0067] Figure 4c It is a compressed image that retains 10 singular values of the color image "Lena" based on the real structure-preserving SVD algorithm of the existing quaternion matrix.

[0068] Figure 4d It is a compressed image that retains 10 singular values of the color image "Lena" based on the SVD algorithm of the equivalent complex matrix of the existing quaternion matrix.

[0069] Figure 4eCompressed images that retain 10 singular values of the color image "Lena" for the SVD algorithm based on the existing real matrix block [R; G; B].

[0070] Figure 4f Compressed images that retain 10 singular values of the color image "Lena" for the SVD algorithm based on the existing three color spaces.

[0071] Figure 5a Compressed images that retain 30 singular values of the color image "Lena" for the fast color image compression method based on the split quaternion model provided by the present invention.

[0072] Figure 5b Compressed images that retain 30 singular values of the color image "Lena" for the SVD color image compression method based on the existing quaternion toolbox.

[0073] Figure 5c Compressed images that retain 30 singular values of the color image "Lena" for the real structure-preserving SVD color image compression method based on the existing quaternion matrix.

[0074] Figure 5d Compressed images that retain 30 singular values of the color image "Lena" for the SVD color image compression method based on the equivalent complex matrix of the existing quaternion matrix.

[0075] Figure 5e Compressed images that retain 30 singular values of the color image "Lena" for the SVD color image compression method based on the existing real matrix block [R; G; B].

[0076] Figure 5f Compressed images that retain 30 singular values of the color image "Lena" for the SVD color image compression method based on the existing three color spaces.

[0077] Figure 6a Compressed images that retain 50 singular values of the color image "Lena" for the fast color image compression method based on the split quaternion model provided by the present invention.

[0078] Figure 6b Compressed images that retain 50 singular values of the color image "Lena" for the SVD algorithm based on the existing quaternion toolbox.

[0079] Figure 6c Compressed images that retain 50 singular values of the color image "Lena" for the real structure-preserving SVD algorithm based on the existing quaternion matrix.

[0080] Figure 6dCompressed images retaining 50 singular values of the color image "Lena" for the SVD algorithm based on the existing quaternion matrix equivalent complex matrix.

[0081] Figure 6e Compressed images retaining 50 singular values of the color image "Lena" for the SVD algorithm based on the existing real matrix block [R; G; B].

[0082] Figure 6f Compressed images retaining 50 singular values of the color image "Lena" for the SVD algorithm based on the existing three color spaces.

[0083] Figure 7a CPU time graphs required for reconstructing four color images 3a, 3b, 3c, and 3d by selecting 30 singular values using the fast color image compression method based on the split quaternion model provided by the present invention and the existing 5 SVD algorithms.

[0084] Figure 7b CPU time graphs required for reconstructing four color images 3a, 3b, 3c, and 3d by selecting 60 singular values using the fast color image compression method based on the split quaternion model provided by the present invention and the existing 5 SVD algorithms.

[0085] Figure 7c CPU time graphs required for reconstructing four color images 3a, 3b, 3c, and 3d by selecting 90 singular values using the fast color image compression method based on the split quaternion model provided by the present invention and the existing 5 SVD algorithms. Detailed implementation manners

[0086] In order to make the technical problems, technical solutions and beneficial effects to be solved by the present invention clearer, the present invention will be further described in detail below with reference to the accompanying drawings and embodiments. It should be understood that the specific embodiments described herein are only used to explain the present invention and are not used to limit the present invention.

[0087] The present invention provides a fast color image compression method based on a split quaternion model. During the color image compression process, this method can maintain the internal connection between the R, G, and B primary color channels of the color image and greatly reduce the computational complexity.

[0088] The steps of this method are described in detail as follows, and the process reference is Figure 1 。

[0089] S1: Construct a split quaternion model, and represent the original color image with the split quaternion model to obtain a split quaternion matrix A.

[0090] Specifically, when the real part of the split quaternion model is zero, the split quaternion model is expressed as:

[0091] q(x,y) = r(x,y)i + g(x,y)j + b(x,y)k (1)

[0092] Wherein, r(x,y), g(x,y), and b(x,y) respectively represent the red, green, and blue of the point (x,y) in the color image, that is, the pixel point in the x-th row and y-th column of the three-primary color matrix, and i, j, k are the three imaginary unit parts of the split quaternion q.

[0093] Specifically, the original color image has m rows and n columns, and the original color image is represented by the split quaternion model as follows:

[0094]

[0095] Wherein, A is the split quaternion matrix of the original color image, and R, G, B are real number matrices, representing the red, green, and blue color matrices respectively; Represents the split quaternion ring H s The m×n order matrix on.

[0096] S2: Calculate the real representation matrix of the split quaternion matrix A and the singular value decomposition of the real representation matrix.

[0097] Specifically, the specific steps for calculating the real representation matrix of the split quaternion matrix are as follows:

[0098] For any split quaternion matrix Wherein, A s Is an m×n order real matrix, s = 1, 2, 3, 4, and the real representation matrix A σ Of the split quaternion matrix A is defined as:

[0099]

[0100] And the real representation matrix satisfies the following equations:

[0101] (A + D) σ = A σ + D σ , (AC) σ = A σ C σ , (aA) σ = aA σ , (A H ) σ = (A σ ) T (4)

[0102] Wherein, Is an arbitrary m×n order split quaternion matrix, Is an arbitrary n×p order split quaternion matrix, a ∈ R is a real number, Denote the i-conjugate transpose matrix of the split quaternion matrix A, Denote the real matrix A s of the transpose matrix;

[0103] Calculate the real representation matrix of the split quaternion matrix by formula (3).

[0104] It should be noted that the advantage of using the split quaternion model for color images is that the split quaternion matrix algebraic structure problem is completely isomorphic to the above 2m×2n real matrix problem. Therefore, the real representation matrix is a ring For the ring R 2m×2n of the isomorphism.

[0105] Specifically, the specific steps for calculating the singular value decomposition of the real representation matrix are as follows:

[0106] For any split quaternion matrix Let m≥n (without loss of generality). By the singular value decomposition theory of the real representation matrix, there exists an orthogonal matrix and a real matrix such that:

[0107]

[0108] where, u i ∈R 2m , i = 1, 2,..., 2n, τ1≥τ2≥…≥τ 2n ≥0, τ1, τ2,…, τ 2n is the singular value of the real representation matrix A σ ; v j ∈R 2n , j = 1, 2,…, 2n;

[0109] Calculate the singular value decomposition of the real representation matrix A σ by formula (5).

[0110] S3: Calculate the singular value decomposition of the split quaternion matrix A according to the singular values of the real representation matrix, that is, the singular value decomposition of the original color image.

[0111] The specific steps to obtain the singular value decomposition of the split quaternion matrix are as follows:

[0112] Calculate the non-zero singular value σ of the split quaternion matrix A according to the following formula t :

[0113]

[0114] where, p is the real representation matrix Aσ The number of non - zero singular values;

[0115] Through the construction form of the singular values and τ1≥τ2≥…≥τ p ≥0, we get |σ1|≥|σ2|≥…≥|σ r |≥0;

[0116] Calculate the left and right singular vectors of the split - quaternion matrix A according to the following formula:

[0117]

[0118] In the formula, μ s is a left singular vector of the split - quaternion matrix A, ν s is a right singular vector of the split - quaternion matrix A, s = 1,2,…,n; Satisfy k = 1,2,…,2n;

[0119] Combining formula (6) and formula (7), there exists a unique diagonal split - quaternion matrix Σ r = diag(σ1,σ2,…,σ r ),|σ1|≥|σ2|≥…≥|σ r |≥0, such that:

[0120]

[0121] In the formula, U H U = I n ,V H V = I n ;

[0122] Then σ1,…,σ r are called the singular values of the split - quaternion matrix A;

[0123] According to the singular values of the split - quaternion matrix A, the component - product form of the singular - value decomposition of the split - quaternion matrix A is obtained as follows:

[0124]

[0125] In the formula, μ t is the left singular vector, that is, the column of U; ν t is the right singular vector, that is, the column of V;

[0126] S4: Given a threshold, substitute the given threshold and the singular - value norm of the split - quaternion matrix A into the threshold function to obtain the dimensionality reduction degree.

[0127] The specific steps to obtain the dimensionality reduction degree are as follows:

[0128] Given a threshold, substitute the given threshold and the singular value norm of the split quaternion matrix A into the following threshold function:

[0129]

[0130] wherein, is the best approximation matrix of the split quaternion matrix A, α = s - 1 is the number of singular values of the split quaternion matrix A, and s is the degree of dimensionality reduction;

[0131] Calculate the degree of dimensionality reduction through formula (10).

[0132] It should be noted that the dimensionality reduction dimension can also be determined by using a graph sorted by singular value norms from large to small, and the dimensionality reduction dimension is the inflection point of the curve in the graph.

[0133] S5: Under the constraint of the threshold function, select the best approximation matrix of the original color image, and store the effective decomposition matrix of the best approximation matrix according to the degree of dimensionality reduction to complete image compression.

[0134] The specific steps of storing the effective decomposition matrix of the best approximation matrix according to the degree of dimensionality reduction are as follows: according to the degree of dimensionality reduction, retain α = s - 1 singular values, then the singular value decomposition of the m×n best approximation matrix is an m×α - order matrix, an α×α - order matrix, and an n×α - order matrix. Since α is much smaller than the minimum value of {m, n}, at this time, storing the three matrices of the m×α - order matrix, the α×α - order matrix, and the n×α - order matrix can complete image compression.

[0135] In a specific embodiment, continue to refer to Figure 1 , the above - mentioned fast color image compression method based on the split quaternion model further includes the following steps: extract the m×α - order matrix, the α×α - order matrix, and the n×α - order matrix of the decomposition matrix of the compressed image in step S5, multiply the three decomposition matrices, satisfying the matrix multiplication m×n = (m×α)×(α×α)×(n×α) H , reconstruct the best approximation matrix, and imageize the best approximation matrix to obtain an approximate image of the original color image to complete image compression reconstruction.

[0136] Through the above reconstruction of the best approximation matrix, the compressed image can be reconstructed and displayed as the original color image.

[0137] In the field of image processing, visual fidelity can be measured by a variety of numerical parameters. For example: the structural similarity index (hereinafter referred to as: SSIM) or the peak signal - to - noise ratio (hereinafter referred to as: PSNR) between the original color image A' and the compressed image (i.e., the best approximation image A α ').

[0138] Next, several different quantization criteria (including: CPU time, PSNR, SSIM) are used to judge the performance of the above-mentioned fast color image compression method based on the split quaternion model of the present invention and five existing color image compression methods. Among them, the five existing color image compression methods are: (1) SVD color image compression method of the quaternion toolbox; (2) real structure-preserving SVD color image compression method of the quaternion matrix; (3) SVD color image compression method of the equivalent complex matrix of the quaternion matrix; (4) SVD color image compression method of the real matrix block [R; G; B]; (5) SVD color image compression method of three color spaces.

[0139] The structural similarity index is defined as:

[0140]

[0141] In the formula, A α ' is the best approximation image of the original color image A', μ A' is the local mean of the original color image A', σ A' is the standard deviation of the original color image A', is the local mean of the best approximation image A α ', is the standard deviation of the best approximation image A α ', is the covariance between the original color image A' and the best approximation image A α '; C1 = (0.01 × L) 2 is the regularization constant of brightness, C2 = (0.03 × L) 2 is the regularization constant of contrast, and L is the specified dynamic range value.

[0142] The peak signal-to-noise ratio is defined as:

[0143]

[0144] In the formula, A α ' is the best approximation image of the original color image A', A'(:,:,1) = R, A'(:,:,2) = G, A'(:,:,3) = B.

[0145] Example 1: To simulate the pixel values of the color image matrix, matrices A1, A2, A3, and A4 are defined as follows:

[0146] A1 = zeros(m,n), A2 = 255 × rand(m,n), A3 = 255 × rand(m,n),

[0147] A4 = 255 × rand(m,n), m = n = 25:25:500.

[0148] Compare the CPU time and error of the fast color image compression method based on the split quaternion model of the present invention and five existing color image compression methods. See Figure 2a , Figure 2b , in the figure, SVDSQ represents the fast color image compression method based on the split quaternion model of the present invention, QSVD of QTFM represents the SVD color image compression method of the quaternion toolbox, Structure-preserving method represents the real structure-preserving SVD color image compression method of the quaternion matrix, SVD of complex matrix represents the SVD color image compression method of the equivalent complex matrix of the quaternion matrix; SVD of [R; G; B] represents the SVD color image compression method of the real matrix block [R; G; B]; SVD in three color spaces represents the SVD color image compression method in three color spaces. Obviously, the running times of the SVD color image compression method of the quaternion toolbox and the real structure-preserving SVD color image compression method of the quaternion matrix are relatively slow, and the running times of the remaining methods are relatively fast. The SVD decomposition of the 500-order matrix is all completed in less than 1 second. In terms of error, the error of the fast color image compression method based on the split quaternion model of the present invention remains at 3×10 -15 below, which not only has a time advantage but also has good performance. In addition, processing the color image compression problem based on four-dimensional algebraic models (such as: quaternion model, split quaternion model) can better ensure the internal connection of the three color spaces and has an advantage in performance.

[0149] Example 2: Figures 3a - 3d Four classic color images are given, and the images are from the CVGUGR (English: Computer Vision Group - University of Granada) image database. Each color image can be represented as a pure imaginary split quaternion matrix or a pure imaginary quaternion matrix. Use the fast color image compression method based on the split quaternion model of the present invention and the five existing compression methods in Example 1 to Figures 3a - 3d compress the given color images.

[0150] Figures 4a - 4f , Figures 5a - 5f , Figures 6a - 6f shows the best compression approximation images of the fast color image compression method based on the split quaternion model of the present invention and five existing compression methods, corresponding to Figure 3a10, 30, and 50 singular values. Obviously, when 10 singular values are selected for color image compression, the fast color image compression method based on the split quaternion model of the present invention can more completely retain the eye information of the image. When 30 and 50 singular values are selected for color image compression, the fast color image compression method based on the split quaternion model of the present invention can more completely and clearly retain the background information of the image.

[0151] Figures 7a - 7c Shows the CPU time required for the fast color image compression method based on the split quaternion model of the present invention that selects a certain number of singular values and 5 existing compression methods to compress and reconstruct four color images. Among them, Figure 7a 30 singular values are selected, Figure 7b 60 singular values are selected, Figure 7c 90 singular values are selected. Obviously, the fast color image compression method based on the split quaternion model of the present invention has significant time advantages.

[0152] For the fast color image compression method based on the split quaternion model of the present invention and 5 existing compression methods, the fidelity of the compressed images after color image compression is shown in Tables 1 and 2. Table 1 shows the PSNR data of the above 6 compression methods, and Table 2 shows the SSIM data of the above 6 compression methods. In Tables 1 and 2, PSNR1 and SSIM1 show the peak signal-to-noise ratio and structural similarity index of the fast color image compression method based on the split quaternion model of the present invention; PSNR2 and SSIM2 show the performance of the SVD color image compression method of the quaternion toolbox; PSNR3 and SSIM3 show the performance of the real structure-preserving SVD color image compression method of the quaternion matrix; PSNR4 and SSIM4 show the performance of the SVD color image compression method of the equivalent complex matrix of the quaternion matrix; PSNR5 and SSIM5 show the performance of the SVD color image compression method of the real matrix block [R; G; B]; PSNR6 and SSIM6 show the performance of the SVD color image compression method of the three color spaces. Compared with traditional color image compression algorithms, the color image processing process based on the four-dimensional algebraic model can preserve more image information, and under the same compression conditions, the corresponding PSNR and SSIM values are relatively high. In addition, the three color image compression methods based on quaternion singular value decomposition only differ in time, and their performances are the same.

[0153] Table 1

[0154]

[0155] Table 2

[0156]

[0157]

[0158] As can be seen from Table 1 and Table 2, obviously, the fast color image compression method based on the split quaternion model of the present invention is significantly superior to other image compression methods in terms of visual fidelity. The compression speed is affected by the computational complexity and the size of the storage space. Computational complexity is an important factor that any commercial entity needs to consider, especially in the case of a large amount of images. An efficient and fast compression method is even more important. The fast color image compression method based on the split quaternion model of the present invention, with the unique algebraic structure of split quaternions, not only ensures the internal connection of the three color spaces, but also the unique 2m×2n real matrix representation greatly improves the speed of the algorithm, and its performance is the best among the 6 compression methods.

[0159] The above are only the preferred embodiments of the present invention and are not intended to limit the present invention. Any modifications, equivalent replacements, and improvements made within the spirit and principle of the present invention shall be included in the protection scope of the present invention.

Claims

1. A fast color image compression method based on a split quaternion model, characterized in that, Including the following steps: S1: Construct a split quaternion model, and represent the original color image with the split quaternion model to obtain a split quaternion matrix A; when the real part of the split quaternion model is zero, the split quaternion model is expressed as: q(x,y)=r(x,y)i+g(x,y)j+b(x,y)k(1) In the formula, r(x,y), g(x,y), and b(x,y) respectively represent the red, green, and blue of the point (x,y) in the color image, that is, the pixel point in the x-th row and y-th column of the three-primary color matrix, and i, j, k are the three imaginary part units of the split quaternion q; The original color image has m rows and n columns, and the original color image is represented by the split quaternion model as: Wherein, A is the split quaternion matrix of the original color image, and R, G, and B are real number matrices, respectively representing the red, green, and blue color matrices; denotes the split quaternion ring H s an m×n order matrix over; S2: Calculate the real representation matrix of the split quaternion matrix A and the singular value decomposition of the real representation matrix; the specific steps for calculating the real representation matrix of the split quaternion matrix are: For any split quaternion matrix wherein, A s is a real matrix of order m×n, s = 1, 2, 3, 4, denotes a matrix of order m×n over the split quaternion ring H s The real representation matrix A of the split quaternion matrix A σ is defined as: And the real representation matrix satisfies the following equation: (A + D) σ = A σ + D σ ,(AC) σ = A σ C σ ,(aA) σ = aA σ ,(A H ) σ =(A σ ) T (4) In the formula, is an arbitrary m×n split quaternion matrix, is an arbitrary n×p split quaternion matrix, and a is a real number. represents the i-conjugate transpose matrix of the split quaternion matrix A, represents the real matrix A s 's transpose matrix; Calculate the real representation matrix of the split quaternion matrix through formula (3); S3: Calculate the singular value decomposition of the split quaternion matrix A according to the singular value decomposition of the real representation matrix, that is, the singular value decomposition of the original color image; S4: Given a threshold, substitute the given threshold and the singular value norm of the split quaternion matrix A into the threshold function to obtain the dimensionality reduction degree; S5: Under the constraint of the threshold function, select the best approximation matrix of the original color image, and store the effective decomposition matrix of the best approximation matrix according to the dimensionality reduction degree to complete image compression.

2. The fast color image compression method based on the split quaternion model according to claim 1, characterized in that In step S2, the specific steps for calculating the singular value decomposition of the real representation matrix are: For any split quaternion matrix Let \(m\geq n\). By the singular value decomposition theory of real representation matrices, there exists an orthogonal matrix and a real matrix such that: wherein, u i ∈R 2m , i = 1, 2, ..., 2n, τ1≥τ2≥…≥τ 2n ≥0, τ1, τ2, …, τ 2n are the singular values of the real representation matrix A σ . v j ∈R 2n , j = 1, 2, ..., 2n; Calculate the real representation matrix A through formula (5). σ Perform the singular value decomposition of.

3. The fast color image compression method based on the split quaternion model according to claim 2, wherein In step S3, the specific steps for obtaining the singular value decomposition of the split quaternion matrix are: Calculate the non-zero singular value σ of the split quaternion matrix A according to the following formula t :[[]]END]] where \(t = 1,2,\cdots,r\) \(p\) is the number of non - zero singular values of the real representation matrix \(A\) σ ; Through the construction form of singular values and τ1≥τ2≥…≥τ p ≥0, we obtain |σ1|≥|σ2|≥…≥|σ r |≥0; Calculate the left and right singular vectors of the split quaternion matrix A according to the following formula: where μ s is a left singular vector of the split quaternion matrix A, ν s is a right singular vector of the split quaternion matrix A, s = 1, 2, …, n; satisfies k = 1, 2, …, 2n; Combining formula (6) and formula (7), there exists a unique diagonal split quaternion matrix Σ r = diag(σ1, σ2, …, σ r ), |σ1| ≥ |σ2| ≥ … ≥ |σ r | ≥ 0, such that: In the formula, U H U = I n ,V H V = I n ; Then σ1, …, σ r are called the singular values of the split quaternion matrix A; According to the singular value decomposition of the split quaternion matrix A, the component product form of the singular value decomposition of the split quaternion matrix A is as follows: where μ t is the left singular vector, i.e., the column of U; ν t is the right singular vector, i.e., the column of V; 4. The fast color image compression method based on the split quaternion model according to claim 3, characterized in that In step S4, the specific steps for obtaining the dimensionality reduction degree are: Given a threshold, substitute the given threshold and the singular value norm of the split quaternion matrix A into the following threshold function: In the formula, is the optimal approximation matrix of the split quaternion matrix A, α = s - 1 is the number of singular values of the split quaternion matrix A, and s is the degree of dimensionality reduction; Calculate the dimensionality reduction degree through formula (10).

5. The fast color image compression method based on the split quaternion model according to claim 4, wherein The specific steps for storing the effective decomposition matrix of the best approximation matrix according to the dimensionality reduction degree are: in step S5, according to the dimensionality reduction degree, retain α = s - 1 singular values, then the singular value decomposition of the m×n best approximation matrix is three decomposition matrices of an m×α-order matrix, an α×α-order matrix, and an n×α-order matrix. α is much smaller than the minimum value of {m,n}. At this time, storing the three decomposition matrices of the m×α-order matrix, the α×α-order matrix, and the n×α-order matrix can complete image compression.

6. The fast color image compression method based on the split quaternion model according to claim 5, characterized in that, It also includes the following steps: Extract the decomposed matrices of the compressed image in step S5, namely the m×α matrix, the α×α matrix, and the n×α matrix, and multiply the three decomposed matrices, satisfying the matrix multiplication m×n = (m×α)×(α×α)×(n×α). H Reconstruct the best approximation matrix, and visualize the best approximation matrix to obtain an approximate image of the original color image, thus completing the image compression and reconstruction.