Next Article in Journal
No-Signaling in Steepest Entropy Ascent: A Nonlinear, Non-Local, Non-Equilibrium Quantum Dynamics of Composite Systems Strongly Compatible with the Second Law
Previous Article in Journal
Information Geometry-Based Two-Stage Track-Before-Detect Algorithm for Multi-Target Detection in Sea Clutter
 
 
Font Type:
Arial Georgia Verdana
Font Size:
Aa Aa Aa
Line Spacing:
Column Width:
Background:
Article

Two-Dimensional Image Lempel–Ziv Complexity Calculation Method and Its Application in Defect Detection

1
School of Mechanical Engineering, Shandong University of Technology, Zibo 255049, China
2
School of Aeronautics, Northwestern Polytechnical University, Xi’an 710072, China
3
Modern Agricultural Equipment Research Institute, Shandong University of Technology, Zibo 255049, China
*
Authors to whom correspondence should be addressed.
Entropy 2025, 27(10), 1014; https://doi.org/10.3390/e27101014
Submission received: 6 September 2025 / Revised: 24 September 2025 / Accepted: 26 September 2025 / Published: 27 September 2025
(This article belongs to the Special Issue Complexity and Synchronization in Time Series)

Abstract

Although Lempel–Ziv complexity (LZC) can reflect changes in object characteristics by measuring changes in independent patterns in the signal, it can only be applied to one-dimensional time series and cannot be directly applied to two-dimensional images. To address this issue, this paper proposed a two-dimensional Lempel–Ziv complexity by combining the concept of local receptive field in convolutional neural networks. This extends the application scenario of LZC from one-dimensional time series to two-dimensional images, further broadening the scope of application of LZC. First, the pixels and size of the image were normalized. Then, the image was encoded according to the sorting of normalized values within the 4 × 4 region. Next, the encoding result of the image was rearranged into a vector by row. Finally, the Lempel–Ziv complexity of the image could be obtained based on the rearranged vector. The proposed method was further used for defect detection in conjunction with the dilation operator and Sobel operator, and validated by two practical cases. The results showed that the proposed method can effectively identify independent pattern changes in images and can be used for defect detection. The accuracy rate of defect detection can reach 100%.

1. Introduction

The complexity of the time series reflects the nonlinear dynamic characteristics contained in the sequence and further reflects the dynamic behavior or health status of objects [1]. Thus, the capture and analysis of object state changes can be implemented by analyzing the complexity changes in time series.
According to Kolmogorov complexity theory, the complexity of a time series can be replaced by the complexity of a symbol sequence and the complexity of the symbol sequence can be defined as the shortest length that can reproduce the sequence [2,3,4]. On this basis, Lempel and Ziv [5] defined the complexity of random sequences in their research on information theory in 1976, stating that complexity reflected the rate at which new patterns appeared in a given sequence as its length increased, and reflected the degree to which the sequence approached randomness. The complexity algorithm for sequences of elements belonging to a finite set was proposed [5], which mathematically turned the calculation of Kolmogorov complexity into reality. The core idea of the Lempel–Ziv complexity algorithm was to reflect the complexity of the time series by analyzing repeated patterns in the time series. In a time series, the repeating pattern referred to the same subsequence that had appeared in different positions. For example, in the string “ABABAB”, “AB” was a repeating pattern because it appeared repeatedly in different positions. Since its introduction, Lempel–Ziv complexity has been widely applied in various fields [6,7,8,9], which can effectively reflect the independent pattern change in time series (abnormal data and points were equivalent to new independent patterns appearing). Currently, Lempel–Ziv complexity is mainly used for medical signal analysis [10,11,12] and mechanical equipment signal analysis [1,13,14]. The traditional process of calculating Lempel–Ziv complexity compared the original time series with a predefined threshold (usually the median or mean of the time series), which was labeled as 1 when the threshold was exceeded, and 0 otherwise. The original time series was converted to a 0–1 symbol sequence. However, this process resulted in the loss of a lot of information from the original time series, which could easily cause “over coarse-graining”, confuse the randomness and chaotic characteristics of the time series, and even change the dynamics of the original time series, resulting in the complexity analysis producing inaccurate results.
To make the encoded symbol sequence reflect more effective information in the original time series, Zhang et al. [15,16] proposed a 3-bit encoding method to encode the original time series and use it for EEG signal detection. Yin et al. [17] used symbolic aggregate approximation (SAX) to reflect the modulation information of bearing signals and encoded bearing signals to achieve fault severity recognition of bearing. In addition to the above improvement methods for Lempel–Ziv complexity encoding, the theory of entropy was used to achieve improvements in Lempel–Ziv complexity encoding. Many scholars have used the theories of permutation entropy and dispersion entropy to encode the original time series and proposed permutation Lempel–Ziv complexity (PLZ) and dispersion Lempel–Ziv complexity (DLZ). For example, Bai et al. [18] combined permutation entropy and Lempel–Ziv complexity for quantifying the dynamical changes in EEG. Bai et al. [19] used PLZ to describe the changes in EEG and quantify the effects of GABAergic anesthetics on brain activity. Shumbayawonda et al. [20] used PLZ to estimate the complexity of magnetoencephalography signals to research the changes in resting state brain (magnetic) activity caused by healthy aging. Li et al. [21] proposed DLZ for bearing fault diagnosis and live types of ship radiation noise signal classification. Jiao et al. [22] introduced DLZ into the field of underwater acoustics and fault diagnosis and proposed a feature extraction method for ship and gear fault signals based on DLZ. Although the above methods improved the accuracy of Lempel–Ziv complexity in characterizing object characteristics by changing the Lempel–Ziv encoding method, they only focused on the information of objects at one scale and cannot reflect the state of objects more comprehensively.
Therefore, the multiscale analysis method of time series was used to preprocess the original time series to further improve the accuracy of Lempel–Ziv complexity in reflecting object characteristics. The most commonly used multiscale analysis methods were coarse graining operation [23] and hierarchical analysis [24], and multiscale symbolic Lempel–Ziv complexity [25], multiscale permutation Lempel–Ziv complexity [26,27], multiscale dispersion Lempel–Ziv complexity [28,29,30], hierarchical Lempel–Ziv complexity [31], and hierarchical dispersion Lempel–Ziv complexity [14] were proposed by combining the Lempel–Ziv complexity under different encodings. In order to eliminate the problem of increasing scale and decreasing sequence length, refined composite multiscale Lempel–Ziv complexity [32,33,34] was further proposed. In addition, other multiscale methods have also been used in combination with Lempel–Ziv complexity. For example, Li et al. [35] proposed an unequal-step multiscale analysis to solve the problem of decreasing subsequences with increasing scale in existing coarse-graining methods and further proposed unequal-step multiscale integrated mapping dispersion Lempel–Ziv complexity. Li et al. [36] proposed refined time-shift multiscale dispersion Lempel–Ziv complexity by constructing the time-shift multiscale sequence. Utilizing multiscale Lempel–Ziv complexity can more comprehensively reflect the characteristics of objects.
In addition, many denoising methods have been used to preprocess the original time series to eliminate the impact of noise on Lempel–Ziv complexity in response to the problem of noise in mechanical equipment signals. These denoising methods can be further divided into frequency lossy noise reduction methods [37,38,39,40,41] and frequency lossless noise reduction methods [42]. For example, Noman et al. [43] improved the accuracy of Lempel–Ziv complexity in determining the health status of bearing by reducing the noise of the original signal using a continuously adjustable parameterized tunable Q factor wavelet transform. Wang et al. [44] improve the bearing fault severity recognition accuracy of Lempel–Ziv complexity by utilizing optimized variational mode decomposition. Yin et al. [13] utilized manifold learning to reduce noise in the signal and improved the recognition accuracy of bearing fault severity. Reducing the noise of the original signal can effectively reduce the effect of noise on the Lempel–Ziv complexity and improve the accuracy of the Lempel–Ziv complexity in reflecting the bearing condition.
Although changing the encoding method, increasing the scale of analysis, and reducing noise in the signal can effectively improve the accuracy and comprehensiveness of Lempel–Ziv complexity in reflecting object states, all the above methods can only calculate the Lempel–Ziv complexity of one-dimensional time series and cannot calculate the Lempel–Ziv complexity of two-dimensional image signals. However, in the process of detecting defects in images, it was also necessary to determine whether there were new patterns appearing in the image.
To address the above issue, this paper proposed a two-dimensional Lempel–Ziv complexity by combining the concept of local receptive field in convolutional neural networks. First, the pixels and size of the image were normalized to eliminate the impact of image size on Lempel–Ziv complexity. Then, the image was encoded according to the sorting of normalized values within the 4 × 4 region. Next, the encoding result of the image was rearranged into a vector by row. Finally, the Lempel–Ziv complexity of image can be obtained based on the rearranged vector. The main contribution of this paper was to propose a method for calculating the Lempel–Ziv complexity of two-dimensional images, further expanding the application scope of Lempel–Ziv complexity.
The remaining sections of the paper are organized as follows: Section 2 provides the necessary background knowledge of Lempel–Ziv complexity. Two-dimensional Lempel–Ziv complexity is proposed in Section 3. In Section 4, one-dimensional and two-dimensional simulation signals are used to demonstrate the ability of the proposed method to reflect the component changes in the signals. The morphological dilation operator and Sobel operator are combined with the proposed method for defect detection and verified with two practical cases, and the limitations of the proposed method are further discussed. The conclusions of the paper are presented in Section 5.

2. Background Knowledge of Lempel–Ziv Complexity

Lempel–Ziv complexity is widely used in the medical [11,45,46] and industrial [8,47] fields to measure the complexity of one-dimensional time series. It extracts the independent patterns from one-dimensional time series by copying and inserting operations [37], and determines the complexity of the time series based on the number of independent patterns. For a time series X = x 1 , x 2 , x N , the Lempel–Ziv complexity can be calculated as follows:
Step 1: Calculate the mean of the time series as follows:
μ O = 1 N i = 1 N x i
Step 2: Encode the time series based on the relationship between time series and the mean μ O .
s i = 1 x i μ O 0 x i < μ O
Step 3: Initialize parameters S v , 0 = {   } , Q 0 = {   } , C N = 0 , r = 1 .
Step 4: Take Q r = Q r 1 s r and judge if Q r belongs to S v , r 1 = S v , r 2 s r 1 . If Q r S v , r 1 , then set Q r =   , C N r = C N r 1 + 1 , r = r + 1 . If Q r S v , r 1 , then set Q r = Q r 1 s r , C N r = C N r 1 , r = r + 1 .
Step 5: Repeat Step 4 until the time series is completely covered. And the C N N is the number of independent patterns in the time series.
Step 6: Normalize C N N by the following equation to eliminate the impact of time series length on C N N .
0 C n N = C N N C U L 1
where
C U L = lim N C N N = lim N N 1 β log k N N log k N
where k is the size of the alphabets used in the string S N = s 1 s 2 s N .

3. The Proposed Two-Dimensional Lempel–Ziv Complexity

Although Lempel–Ziv complexity can be effectively used for measuring the complexity of one-dimensional time series and has been used for testing anomalous patterns in one-dimensional time series, its calculation method limits its use in two-dimensional images. Therefore, the two-dimensional Lempel–Ziv complexity was proposed by combining the concept of local receptive field [48,49] in convolutional neural networks as shown in Figure 1. For an image I M M × L , the Lempel–Ziv complexity can be obtained as following:
Step 1: Calculate the mean of the image as follows:
μ T = 1 M j = 1 M 1 L i = 1 L i m i j
where i m i j is the pixel in I M M × L .
Step 2: Encode the image to 0–1 based on the relationship between time series and the mean μ T .
i s i = 1 i m i j μ T 0 i m i j < μ T
Step 3: Adjust the size of the image from M × L to 128 × 128 by bicubic interpolation to eliminate the influence of image size on Lempel–Ziv complexity.
Step 4: Encode the image A I 128 × 128 obtained from Step 3 based on the concept of the local receptive field to obtain the image encoding B I 127 × 127 .
b i k l = 1 a i i j = 1 , a i i j + 1 = 1 , a i i + 1 j = 1 , a i + 1 j + 1 = 1 2 a i i j = 1 , a i i j + 1 = 1 , a i i + 1 j = 1 , a i + 1 j + 1 = 0 3 a i i j = 1 , a i i j + 1 = 1 , a i i + 1 j = 0 , a i + 1 j + 1 = 0 4 a i i j = 1 , a i i j + 1 = 1 , a i i + 1 j = 0 , a i + 1 j + 1 = 1 5 a i i j = 1 , a i i j + 1 = 0 , a i i + 1 j = 1 , a i + 1 j + 1 = 1 6 a i i j = 1 , a i i j + 1 = 0 , a i i + 1 j = 1 , a i + 1 j + 1 = 0 7 a i i j = 1 , a i i j + 1 = 0 , a i i + 1 j = 0 , a i + 1 j + 1 = 0 8 a i i j = 1 , a i i j + 1 = 0 , a i i + 1 j = 0 , a i + 1 j + 1 = 1 9 a i i j = 0 , a i i j + 1 = 0 , a i i + 1 j = 1 , a i + 1 j + 1 = 1 10 a i i j = 0 , a i i j + 1 = 0 , a i i + 1 j = 1 , a i + 1 j + 1 = 0 11 a i i j = 0 , a i i j + 1 = 0 , a i i + 1 j = 0 , a i + 1 j + 1 = 0 12 a i i j = 0 , a i i j + 1 = 0 , a i i + 1 j = 0 , a i + 1 j + 1 = 1 13 a i i j = 0 , a i i j + 1 = 1 , a i i + 1 j = 1 , a i + 1 j + 1 = 1 14 a i i j = 0 , a i i j + 1 = 1 , a i i + 1 j = 1 , a i + 1 j + 1 = 0 15 a i i j = 0 , a i i j + 1 = 1 , a i i + 1 j = 0 , a i + 1 j + 1 = 0 16 a i i j = 0 , a i i j + 1 = 1 , a i i + 1 j = 0 , a i + 1 j + 1 = 1
where i = 1 , 2 , , 127 , j = 1 , 2 , , 127 .
Step 5: Convert image encoding B I 127 × 127 to row vector S N = s 1 s 2 s N , where N = 127 × 127 .
Step 6: Initialize parameters S v , 0 =   , Q 0 =   , C N = 0 , r = 1 .
Step 7: Take Q r = Q r 1 s r and judge if Q r belongs to S v , r 1 = S v , r 2 s r 1 . If Q r S v , r 1 , then set Q r =   , C N r = C N r 1 + 1 , r = r + 1 . If Q r S v , r 1 , then set Q r = Q r 1 s r , C N r = C N r 1 , r = r + 1 .
Step 8: Repeat Step 7 until the time series is completely covered and C N N represents the number of independent patterns in the time series.
Step 9: Normalize C N N by the following equation.
0 C n N = C N N C U L 1
where
C U L = lim N C N N = lim N N 1 β log 16 N N log 16 N

4. Results and Discussion

This section will validate the effectiveness of the proposed method. First, one-dimensional and two-dimensional simulation signals are used to demonstrate the ability of the proposed method to reflect component changes in the signals. Then, the morphological dilation operator and Sobel operator are combined with the proposed method for defect detection, and verified with two practical cases. Finally, the limitations of the proposed method are further discussed.

4.1. Case Study 1: The Simulation Signal

As shown in Ref. [13], two simple one-dimensional simulation signals were used to demonstrate the ability of Lempel–Ziv complexity to reflect independent components in the signal. One simulation signal had one frequency component, while the other simulation signal had two frequency components. The waveform of the simulation signal is shown in Figure 2. And the number of independent patterns in the signal calculated using Lempel–Ziv complexity is represented by c.
It can be seen from Figure 2 that as the frequency components in the signal increased, the number of independent components calculated by Lempel–Ziv complexity also increased. For one-dimensional signals, Lempel–Ziv complexity can reflect the variation in independent patterns in the signal.
To demonstrate that the proposed two-dimensional Lempel–Ziv complexity can also reflect the independent patterns change in the two-dimensional signal, the following two-dimensional signal was constructed as shown in Table 1, and the number of independent patterns was calculated using the proposed two-dimensional Lempel–Ziv complexity. An image of the constructed two-dimensional signal is shown in Figure 3.
As shown in Figure 3a,b, the number of independent patterns calculated by two-dimensional Lempel–Ziv complexity in the two-dimensional signal was minimal when there were no graphics in the two-dimensional signal. In addition, the number of independent patterns calculated by two-dimensional Lempel–Ziv complexity also varied when the horizontal and vertical thickness and number of lines changed. However, when periodic components continuously appeared in the signal, the number of independent patterns calculated by two-dimensional Lempel–Ziv complexity remained unchanged. Thus, by comparing Figure 2 and Figure 3, it can be seen that the proposed two-dimensional Lempel–Ziv complexity maintained similar properties to traditional Lempel–Ziv complexity, both of which can reflect changes in the components of the signal.
Therefore, the proposed two-dimensional Lempel–Ziv complexity can be applied to defect detection problems according to the proposed two-dimensional Lempel–Ziv complexity’s ability to reflect the changes in the components of the signal. In order to eliminate the influence of background texture on the proposed two-dimensional Lempel–Ziv complexity, the dilation operator and Sobel operator were first used to preprocess the two-dimensional signal. Below, two practical cases are used to demonstrate the effectiveness of the proposed two-dimensional Lempel–Ziv complexity in defect detection.

4.2. Case Study 2: Type-I RSDDs Dataset

This case was from the Type-I RSDDs dataset [50], which was captured from express rails. The size of the image in the dataset was 1000 × 160 pixels, 1260 × 160 pixels, and 1282 × 160 pixels. Then, seven sets of defective images in the dataset were selected as the samples to validate the proposed two-dimensional Lempel–Ziv complexity. As shown in Figure 4a, seven sets of images were first rotated by 90 degrees, and then 160 × 960 pixels of the seven sets of images were selected. And the above images were divided into six segments of 160 × 160 pixels images, as shown in Figure 4b. Then, the Lempel–Ziv complexity (LZ value) of the six segment images was calculated by the proposed two-dimensional Lempel–Ziv complexity. To further illustrate the advantages of the proposed two-dimensional Lempel–Ziv complexity in calculating image complexity, fractal dimension (FD value) [51], entropy (EN value) [52], machado2015 (MA value) [53], Jpg-ratio (JP value) [54], and GLCM (GL value) [55] were used for comparison. The results are shown in Figure 5.
As shown in Figure 5, for the six segmented images in each set of data, there was no significant trend change in the FD value and EN value, so defect detection cannot be performed based on the FD value and EN value. In addition, for image No. 1, the minimum position of LZ value, MA value, and JP value appeared in the fourth segment, corresponding to the segment where the defect appeared. The minimum position of GL value appeared in the first segment and the maximum position of GL value appeared in the second segment. For image No. 2, the minimum position of the LZ value, MA value, and JP value appeared in the fifth and sixth segments, corresponding to the segment where the defect appeared. The minimum position of GL value appeared in the second segment and the maximum position of the GL value appeared in the fifth and sixth segments. For image No. 3, the minimum position of LZ value and MA value appeared in the fourth segment, corresponding to the segment where the defect appeared. The minimum position of JP value appeared in the first segment, and that of the GL value appeared in the second segment and the maximum position of the GL value appeared in the third and fourth segments. For image No. 4, the minimum position of the LZ value appeared in the sixth segment, corresponding to the segment where the defect appeared. The minimum position of the MA value and GL value appeared in the third segment, and that of the JP value appeared in the fourth segment. The maximum position of GL value appeared in the fifth segment. For image No. 5, the minimum position of LZ value, MA value, and JP value appeared in the third segment, corresponding to the segment where the defect appeared. The minimum position of the GL value appeared in the sixth segment and the maximum position of GL value appeared in the third segment. For image No. 6, the minimum position of the LZ value and JP value appeared in the second segment, corresponding to the segment where the defect appeared. The minimum position of the MA value appeared in the third segment, and that of the GL value appeared in the fourth segment. The maximum position of GL value appeared in the second and fifth segments. For image No. 7, the minimum position of the LZ value and the MA value appeared in the sixth segment, corresponding to the segment where the defect appeared. The minimum position of the JP value appeared in the fifth segment, and that of the GL value appeared in the second segment. The maximum position of the GL value appeared in the sixth segment. Thus, from the above results, it can be seen that although the position of the defects can be determined by the minimum MA value, minimum JP value, and maximum GL value for some samples, only the minimum LZ value corresponds to the segmentation of defects for all samples.

4.3. Case Study 3: AITEX Dataset

This case was from the AITEX dataset [56], which was the dataset of fabric defects. The size of the image in the dataset was 256 × 4096 pixels. Then, seven sets of defective images in the dataset were selected as the samples to validate the proposed two-dimensional Lempel–Ziv complexity. We divided the above images into 16 segments of 256 × 256 pixels images as shown in Figure 6a,b. Then the LZ value, FD value, EN value, MA value, JP value, and GL value were calculated as shown in Figure 7.
As shown in Figure 7, for the LZ value, the minimum position of all the samples appeared in the 13th segment, corresponding to the segment where the defect appeared. For FD value, only for image No. 7, the minimum position appeared in the 13th segment, corresponding to the defect segment, while the minimum position of the remaining samples appeared in the first segment. For EN value, the minimum position appeared in the 16th segment, and the maximum position appeared in the eighth segment, none of which corresponded to the defect segment. For the MA value, the minimum position of image No. 2, No. 4, No. 5, and No. 6 appeared in the 13th segment, corresponding to the defect segment; the minimum position of image No. 1 and No. 7 appeared in the eighth segment, and the minimum position of image No. 3 appeared in the 10th segment. For the JP value, the minimum position of all samples appeared in the eighth segment. The maximum positions of image No. 1, No. 3, No. 4, No. 5, and No. 7 appeared in the first segment and that of the remaining images appeared in the second segment. For the GL value, the maximum position of all the samples appeared in the 13th segment, corresponding to the segment where the defect appeared. Therefore, from the above results, it can be seen that the position of defects can be determined based on the minimum LZ value and the maximum GL value.

4.4. Discussion

Through the above simulation signals and two practical cases, it can be seen that the proposed two-dimensional Lempel–Ziv complexity can effectively reflect the changes in non-periodic components in the image, and combined with the dilation operator and Sobel operator, it can be effectively used for defect detection. However, due to the sensitivity of the proposed two-dimensional Lempel–Ziv complexity to non-periodic components in the image, there were certain limitations when used alone. The brightness, contrast, and texture edge sharpening of the image would affect the two-dimensional Lempel–Ziv complexity. Therefore, taking the 16th segment image of No. 1 in case study 2 as an example, the effects of brightness, contrast, and texture edge sharpening on the two-dimensional Lempel–Ziv complexity are illustrated below. Firstly, the above example image was multiplied by different coefficients (1, 0.8, 0.6, 0.4, 0.2) to simulate different levels of brightness, as shown in Figure 8a–e. The pixel values of the above example image were adjusted to the range of 0 to α (α = 1, 0.8, 0.6, 0.4, 0.2) to simulate different contrast ratios, as shown in Figure 9a–e. The above example image was processed by different sharpening methods (vertical sharpening [57], Robert operator sharpening [58], Sobel operator sharpening [59], Laplacian operator sharpening [60], and LoG operator sharpening [61]) to simulate different edge sharpening, as shown in Figure 10a–e. Then, the two-dimensional Lempel–Ziv complexity of the above images was calculated separately, as shown in Figure 8f, Figure 9f and Figure 10f.
As shown in Figure 8f, there were certain differences in LZ values under different brightnesses. The reason for this phenomenon was that the texture in the above images was relatively complex, and the changes between all pixels were relatively continuous. Therefore, during the normalization process of images with different brightnesses, there was a situation which the values near the mean of all pixels fluctuated up and down around the mean of all pixels due to rounding errors, which further affected the encoding of the image and the LZ value. Therefore, for complex texture images with small differences in pixel values, changes in brightness will affect the LZ value.
As shown in Figure 9f, there were certain difference in LZ values under different contrast ratios. The reason for this phenomenon was basically consistent with the different LZ value under different brightnesses mentioned above. This was mainly because there were pixels with small differences in complex textures. Therefore, during the process of changing the range of pixel values, rounding errors caused the values near to the mean of all pixels to fluctuate up and down around the mean of all pixels, which further affected the encoding and LZ values of the image. Therefore, for complex texture images with small differences in pixel values, changes in contrast ratio will affect the LZ value.
As shown in Figure 10f, there were certain difference in LZ values under different sharpening method. As shown in Figure 10a–e, the images processed by different sharpening methods were completely different, except for the overall texture style. Because sharpening caused the changes in the content of the image, there was a difference in the LZ value. Therefore, when the content of the image changed, it also had an impact on the LZ value.
From the above discussion, it can be seen that for complex textures with small differences between pixels, changes in brightness and contrast will have an impact on the LZ value. To make the discussion more comprehensive, below, we present a simple texture with significant differences between pixels to illustrate the situation under different brightnesses and contrast ratios. We constructed an image of 128 × 128 pixels as shown in Figure 11a, where rows 1 to 64 and the columns 1 to 64 and rows 65 to 128 and columns 65 to 128 are represented by a value of 1, and the remaining positions are represented by 0. Because for the texture in Figure 11, the changes in contrast ratio and brightness using the above method are the same, only the LZ values of the constructed simple texture at different brightness were calculated as shown in Figure 11f.
As shown in Figure 11f, for simple textures with significant differences between pixels, the LZ value remained unchanged at different brightness. This was because there were only two types of texture in the image, light and dark, and there was a significant difference in pixel values between the two textures. Even if the range of light and dark values was changed, this difference would not change. Therefore, the normalization results of the image will not change, and the LZ value will not change.
From the above discussion, it can be seen that the proposed two-dimensional Lempel–Ziv complexity is sensitive to small changes in the content of the image. For the simple textures with significant differences between pixels, the proposed two-dimensional Lempel–Ziv complexity can effectively reflect the changes in texture in the image. However, for complex textures with small differences between pixels, the proposed two-dimensional Lempel–Ziv complexity would be affected by the background texture. Therefore, it is necessary to preprocess the image by using the dilation operator to enhance the texture and the Sobel operator to extract texture edges to eliminate the influence of brightness and contrast on the LZ value.

5. Conclusions

This paper proposed a two-dimensional Lempel–Ziv complexity by combining the concept of local receptive field in convolutional neural networks. This extends the application scenario of LZC from one-dimensional time series to two-dimensional images, further broadening the scope of application of LZC. The pixels and size of the image were first normalized to eliminate the impact of image size on Lempel–Ziv complexity. Then, the image was encoded according to the sorting of normalized values within the 4 × 4 region. Next, the encoding result of the image was rearranged into a vector by row. Finally, the Lempel–Ziv complexity of image can be obtained based on the rearranged vector. The proposed method was further used for defect detection in conjunction with the dilation operator and Sobel operator. Through the verification of the one-dimensional and two-dimensional simulation signals and two practical cases, it was proved that the proposed method was sensitive to small changes in the content of the image and can be used for defect detection.
However, the proposed method still has the following limitations. For simple textures with significant differences between pixels, the proposed two-dimensional Lempel–Ziv complexity can effectively reflect the changes in texture in the image. However, for complex textures with small differences between pixels, the proposed two-dimensional Lempel–Ziv complexity would be affected by the background texture. Therefore, the application of the proposed method to the defect detection of complex textures deserves further research.

Author Contributions

Conceptualization, J.Y. and Y.S.; methodology, J.Y. and X.Z.; software, J.Y. and Y.S.; validation, W.S. and Y.L.; formal analysis, J.Y. and W.S.; writing—original draft preparation, J.Y.; writing—review and editing, J.Y., W.S., X.Z., Y.S. and Y.L.; visualization, Y.L.; project administration, X.Z.; funding acquisition, J.Y. All authors have read and agreed to the published version of the manuscript.

Funding

This research was supported by the National Natural Science Foundation of China, [No. 52502531], the Natural Science Foundation of Shandong Province, China, [Grant No. ZR2023QE214 and No. ZR2025MS765].

Data Availability Statement

The data in the manuscript is a publicly available dataset. “Type-I RSDDs dataset” at https://gitcode.com/open-source-toolkit/1c98b (accessed on 1 December 2023). “AITEX dataset” at https://www.aitex.es/afid/ (accessed on 1 December 2023).

Conflicts of Interest

The authors declare no conflicts of interest.

References

  1. Wang, S.; Li, Y.B.; Noman, K.; Li, Z.X.; Feng, K.; Liu, Z.; Deng, Z.C. Multivariate multiscale dispersion Lempel-Ziv complexity for fault diagnosis of machinery with multiple channels. Inf. Fusion 2024, 104, 102152. [Google Scholar] [CrossRef]
  2. Muchnik, A.A.; Positselsky, S.Y. Kolmogorov entropy in the context of computability theory. Theor. Comput. Sci. 2002, 271, 15–35. [Google Scholar] [CrossRef]
  3. Bauwens, B.; Gács, P.; Romashchenko, A.; Shen, A. Inequalities for space-bounded Kolmogorov complexity. Computability 2022, 11, 165–185. [Google Scholar] [CrossRef]
  4. Zamora, J.; Sublime, J. An Ensemble and Multi-View Clustering Method Based on Kolmogorov Complexity. Entropy 2023, 25, 371. [Google Scholar] [CrossRef] [PubMed]
  5. Lempel, A.; Ziv, J. On the Complexity of Finite Sequences. IEEE Trans. Inf. Theory 1976, 22, 75–81. [Google Scholar] [CrossRef]
  6. Rantalainen, T.; Koivunen, K.; Portegijs, E.; Rantanen, T.; Palmberg, L.; Karavirta, L.; Chastin, S. Is Complexity of Daily Activity Associated with Physical Function and Life-Space Mobility among Older Adults? Med. Sci. Sports Exerc. 2022, 54, 1210–1217. [Google Scholar] [CrossRef]
  7. Barile, C.; Casavola, C.; Pappalettera, G.; Kannan, V.P. Interpreting the Lempel-Ziv complexity of acoustic emission signals for identifying damage modes in composite materials. Struct. Health Monit. 2022, 22, 1708–1720. [Google Scholar] [CrossRef]
  8. Zhu, L.J.; Wang, D.M.; Yue, J.K.; Lu, J.Y.; Li, G.F. Leakage detection method of natural gas pipeline combining improved variational mode decomposition and Lempel-Ziv complexity analysis. Trans. Inst. Meas. Control 2022, 44, 2865–2876. [Google Scholar] [CrossRef]
  9. Zhang, M.Y.; Zhang, D.; Fu, S.S.; Kujala, P.; Hirdaris, S. A predictive analytics method for maritime traffic flow complexity estimation in inland waterways. Reliab. Eng. Syst. Safe 2022, 220, 108317. [Google Scholar] [CrossRef]
  10. Ren, Z.; Yue, M.Y.; Han, X.; Zhao, Z.Y.; Wang, B.; Hong, Y.; Zhao, T.; Wang, N.; Zhao, P.; Hong, Y.X.; et al. The potential of the Lempel-Ziv complexity of the EEG in diagnosing cognitive impairment in patients with temporal lobe epilepsy. Eplileptic Disord. 2023, 25, 331–342. [Google Scholar] [CrossRef]
  11. Biggs, D.; Boncompte, G.; Pedemonte, J.C.; Fuentes, C.; Cortinez, L.I. The effect of age on electroencephalogram measures of anesthesia hypnosis: A comparison of BIS, Alpha Power, Lempel-Ziv complexity and permutation entropy during propofol induction. Front. Aging Neurosci. 2022, 14, 910886. [Google Scholar] [CrossRef]
  12. Aamodt, A.; Nilsen, A.S.; Markhus, R.; Kusztor, A.; HasanzadehMoghadam, F.; Kauppi, N.; Thürer, B.; Storm, J.F.; Juel, B.E. EEG Lempel-Ziv complexity varies with sleep stage, but does not seem to track dream experience. Front. Hum. Neurosci. 2023, 16, 987714. [Google Scholar] [CrossRef]
  13. Yin, J.C.; Zhuang, X.Y.; Sui, W.T.; Sheng, Y.L. Manifold learning and Lempel-Ziv complexity-based fault severity recognition method for bearing. Measurement 2023, 213, 112714. [Google Scholar] [CrossRef]
  14. Li, Y.J.; Tan, L.; Xiao, M.; Xiong, Q. Hierarchical dispersion Lempel-Ziv complexity for fault diagnosis of rolling bearing. Meas. Sci. Technol. 2023, 34, 035015. [Google Scholar] [CrossRef]
  15. Zhang, Y.T.; Wei, S.S.; Liu, H.; Zhao, L.N.; Liu, C.Y. A novel encoding Lempel-Ziv complexity algorithm for quantifying the irregularity of physiological time series. Comput. Methods Programs Biomed. 2016, 133, 7–15. [Google Scholar] [CrossRef] [PubMed]
  16. Zhang, Y.T.; Ma, Z.G.; Dong, W.T. Nonlinear Quality Indices Based on a Novel Lempel-Ziv Complexity for Assessing Quality of Multi-Lead ECGs Collected in Real Time. J. Inf. Process. Syst. 2020, 16, 508–521. [Google Scholar] [CrossRef]
  17. Yin, J.; Xu, M.; Zheng, H. Fault diagnosis of bearing based on Symbolic Aggregate approXimation and Lempel-Ziv. Measurement 2019, 138, 206–216. [Google Scholar] [CrossRef]
  18. Bai, Y.; Liang, Z.H.; Li, X.L. A permutation Lempel-Ziv complexity measure for EEG analysis. Biomed. Signal Process. 2015, 19, 102–114. [Google Scholar] [CrossRef]
  19. Bai, Y.; Liang, Z.H.; Li, X.L.; Voss, L.J.; Sleigh, J.W. Permutation Lempel-Ziv complexity measure of electroencephalogram in GABAergic anaesthetics. Physiol. Meas. 2015, 36, 2483–2501. [Google Scholar] [CrossRef]
  20. Shumbayawonda, E.; Tosun, P.D.; Fernández, A.; Hughes, M.P.; Abásolo, D. Complexity Changes in Brain Activity in Healthy Ageing: A Permutation Lempel-Ziv Complexity Study of Magnetoencephalograms. Entropy 2018, 20, 506. [Google Scholar] [CrossRef]
  21. Li, Y.X.; Geng, B.; Jiao, S.B. Dispersion entropy-based Lempel-Ziv complexity: A new metric for signal analysis. Chaos Solitons Fract. 2022, 161, 112400. [Google Scholar] [CrossRef]
  22. Jiao, S.; Geng, B.; Li, Y.; Zhang, Q.; Wang, Q.; Li, Y.; Wang, W. Comparative study of feature extraction and classification based on dispersion Lempel-Ziv complexity. Int. J. Numer. Model. 2022, 35, e2949. [Google Scholar] [CrossRef]
  23. Costa, M.; Goldberger, A.L.; Peng, C.K. Multiscale entropy analysis: A new measure of complexity loss in heart failure. J. Electrocardiol. 2003, 36, 39–40. [Google Scholar] [CrossRef]
  24. Jiang, Y.; Peng, C.K.; Xu, Y. Hierarchical entropy analysis for biological signals. J. Comput. Appl. Math. 2011, 236, 728–742. [Google Scholar] [CrossRef]
  25. Li, Y.B.; Liu, F.L.; Wang, S.; Yin, J.C. Multiscale Symbolic Lempel-Ziv: An Effective Feature Extraction Approach for Fault Diagnosis of Railway Vehicle Systems. IEEE Trans. Ind. Inf. 2021, 17, 199–208. [Google Scholar] [CrossRef]
  26. Yi, Y.M.; Li, Y.X.; Wu, J.X. Multi-scale permutation Lempel-Ziv complexity and its application in feature extraction for Ship-radiated noise. Front. Mar. Sci. 2022, 9, 1047332. [Google Scholar] [CrossRef]
  27. Borowska, M. Multiscale Permutation Lempel-Ziv Complexity Measure for Biomedical Signal Analysis: Interpretation and Application to Focal EEG Signals. Entropy 2021, 23, 832. [Google Scholar] [CrossRef] [PubMed]
  28. Li, Y.X.; Jiang, X.R.; Tang, B.Z.; Ning, F.Y.; Lou, Y.L. Feature extraction methods of ship-radiated noise: From single feature of multi-scale dispersion Lempel-Ziv complexity to mixed double features. Appl. Acoust. 2022, 199, 109032. [Google Scholar] [CrossRef]
  29. Mao, X.G.; Shang, P.J.; Xu, M.; Peng, C.K. Measuring time series based on multiscale dispersion Lempel-Ziv complexity and dispersion entropy plane. Chaos Solitons Fract. 2020, 137, 109868. [Google Scholar] [CrossRef]
  30. Xiao, L.L. A New Feature Extraction Method of Marine Ambient Noise Based on Multiscale Dispersion Entropy. Math. Probl. Eng. 2022, 2022, 7618380. [Google Scholar] [CrossRef]
  31. Han, B.; Wang, S.; Zhu, Q.Q.; Yang, X.H.; Li, Y.B. Intelligent Fault Diagnosis of Rotating Machinery Using Hierarchical Lempel-Ziv Complexity. Appl. Sci. 2020, 10, 4221. [Google Scholar] [CrossRef]
  32. Li, Y.B.; Wang, S.; Deng, Z.C. Intelligent fault identification of rotary machinery using refined composite multi-scale Lempel-Ziv complexity. J. Manuf. Syst. 2021, 61, 725–735. [Google Scholar] [CrossRef]
  33. Li, Y.; Jiao, S.; Geng, B. Refined composite multiscale fluctuation-based dispersion Lempel-Ziv complexity for signal analysis. ISA Trans. 2022, 133, 273–284. [Google Scholar] [CrossRef]
  34. Li, Y.X.; Yi, Y.M.; Wu, J.X.; Gu, Y.P. A novel feature extraction method for ship-radiated noise based on hierarchical refined composite multi-scale dispersion entropy-based Lempel-Ziv complexity. Deep Sea Res. Part I Oceanogr. Res. Pap. 2023, 199, 104111. [Google Scholar] [CrossRef]
  35. Li, Y.X.; Wu, J.X.; Yi, Y.M.; Gu, Y.P. Unequal-step multiscale integrated mapping dispersion Lempel-Ziv complexity: A novel complexity metric for signal analysis. Chaos Solitons Fract. 2023, 175, 113945. [Google Scholar] [CrossRef]
  36. Li, Y.J.; Tan, L.; Li, P.; Xiong, Q. Refined time-shift multiscale dispersion Lempel-Ziv complexity to diagnose rolling bearing faults. J. Mech. Sci. Technol. 2023, 9, 4557–4566. [Google Scholar] [CrossRef]
  37. Hong, H.; Liang, M. Fault severity assessment for rolling element bearings using the Lempel–Ziv complexity and continuous wavelet transform. J. Sound Vib. 2009, 320, 452–468. [Google Scholar] [CrossRef]
  38. Cui, L.; Gong, X.; Zhang, J.; Wang, H. Double-dictionary matching pursuit for fault extent evaluation of rolling bearing based on the Lempel-Ziv complexity. J. Sound Vib. 2016, 385, 372–388. [Google Scholar] [CrossRef]
  39. Cui, L.; Li, B.; Ma, J.; Jin, Z. Quantitative trend fault diagnosis of a rolling bearing based on Sparsogram and Lempel-Ziv. Measurement 2018, 128, 410–418. [Google Scholar] [CrossRef]
  40. Du, J.; Cui, L.; Zhang, J.; Li, J.; Huang, J.; Adam, G.; Glowacz, A. The Method of Quantitative Trend Diagnosis of Rolling Bearing Fault Based on Protrugram and Lempel–Ziv. Shock Vib. 2018, 2018, 4303109. [Google Scholar] [CrossRef]
  41. Dang, P.F.; Yang, Z.X.; Wen, B.G.; Wang, M.G.; Han, Q.K. Fault severity assessment of rolling bearing based on optimized multi-dictionaries matching pursuit and Lempel-Ziv complexity. ISA Trans. 2021, 116, 191–202. [Google Scholar] [CrossRef]
  42. Yin, J.; Lei, M.; Zheng, H.; Yang, Y.; Li, Y.; Xu, M. The Average Coding Length of Huffman Coding Based Signal Processing and Its Application in Fault Severity Recognition. Appl. Sci. 2019, 9, 5051. [Google Scholar] [CrossRef]
  43. Noman, K.; Li, Y.B.; Si, S.B.; Wang, S.; Mao, G. Oscillatory Lempel-Ziv Complexity Calculation as a Nonlinear Measure for Continuous Monitoring of Bearing Health. IEEE Trans. Reliab. 2022, 72, 151–165. [Google Scholar] [CrossRef]
  44. Wang, H.; Yang, T.; Han, Q.; Luo, Z. Approach to the Quantitative Diagnosis of Rolling Bearings Based on Optimized VMD and Lempel–Ziv Complexity under Varying Conditions. Sensors 2023, 23, 4044. [Google Scholar] [CrossRef] [PubMed]
  45. Altintop, C.G.; Latifoglu, F.; Akin, A.K.; Bayram, A.; Ciftci, M. Classification of Depth of Coma Using Complexity Measures and Nonlinear Features of Electroencephalogram Signals. Int. J. Neural Syst. 2022, 32, 2250018. [Google Scholar] [CrossRef] [PubMed]
  46. Golesorkhi, M.; Gomez-Pilar, J.; Catal, Y.; Tumati, S.; Yagoub, M.; Stamatakis, E.A.; Northoff, G. From temporal to spatial topography: Hierarchy of neural dynamics in higher- and lower-order networks shapes their complexity. Cereb. Cortex. 2022, 32, 5637–5653. [Google Scholar] [CrossRef] [PubMed]
  47. Barile, C.; Casavola, C.; Pappalettera, G.; Kannan, V.P.; Renna, G. Investigation of Interlaminar Shear Properties of CFRP Composites at Elevated Temperatures Using the Lempel-Ziv Complexity of Acoustic Emission Signals. Materials 2022, 15, 4252. [Google Scholar] [CrossRef]
  48. Luo, L.; Wang, X.F.; Lu, J.S.; Chen, G.P.; Luan, G.M.; Li, W.; Wang, Q.; Fang, F. Local field potentials, spiking activity, and receptive fields in human visual cortex. Sci. China Life Sci. 2023, 67, 614–617. [Google Scholar] [CrossRef]
  49. Turcsany, D.; Bargiela, A.; Maul, T. Local receptive field constrained deep networks. Inf. Sci. 2016, 349, 229–247. [Google Scholar] [CrossRef]
  50. Gan, J.R.; Li, Q.T.; Wang, J.Z.; Yu, H.M. A Hierarchical Extractor-Based Visual Rail Surface Inspection System. IEEE Sens. J. 2017, 17, 7935–7944. [Google Scholar] [CrossRef]
  51. Al-Kadi, O.; Watson, D. Texture analysis of aggressive and nonaggressive lung tumor CE CT images. IEEE Trans. Bio-Med. Eng. 2008, 55, 1822–1830. [Google Scholar] [CrossRef] [PubMed]
  52. Gonzalez, R.C.; Woods, R.E.; Eddins, S.L. Digital Image Processing Using MATLAB, 2nd ed.; Gatesmark Publishing: Knoxville, TN, USA, 2007. [Google Scholar]
  53. Machado, P.; Romero, J.; Nadal, M.; Santos, A.; Correia, J.; Carballal, A. Computerized measures of visual complexity. Acta Psychol. 2015, 160, 43–57. [Google Scholar] [CrossRef] [PubMed]
  54. Forsythe, A.; Nadal, M.; Sheehy, N.; Cela-Conde, C.J.; Sawey, M. Predicting beauty: Fractal dimension and visual complexity in art. Brit. J. Psychol. 2011, 102, 49–70. [Google Scholar] [CrossRef] [PubMed]
  55. Mengiste, E.; Mannem, K.R.; Prieto, S.A.; de Soto, B.G. Transfer-Learning and Texture Features for Recognition of the Conditions of Construction Materials with Small Data Sets. J. Comput. Civ. Eng. 2024, 38, 04023036. [Google Scholar] [CrossRef]
  56. Silvestre-Blanes, J.; Albero-Albero, T.; Miralles, I.; Pérez-Llorens, R.; Moreno, J. A Public Fabric Database for Defect Detection Methods and Results. Autex Res. J. 2019, 19, 363–374. [Google Scholar] [CrossRef]
  57. Yang, C.C. Finest image sharpening by use of the modified mask filter dealing with highest spatial frequencies. Optik 2014, 125, 1942–1944. [Google Scholar] [CrossRef]
  58. Wei, Y.Z.; Xu, M. Detection of lane line based on Robert operator. J. Meas. Eng. 2021, 9, 156–166. [Google Scholar] [CrossRef]
  59. Chang, Q.; Li, X.; Li, Y.; Miyazaki, J. Multi-directional Sobel operator kernel on GPUs. J. Parallel Distrib. Comput. 2023, 177, 160–170. [Google Scholar] [CrossRef]
  60. Lee, H.G.; Ham, S.; Kim, J. Isotropic Finite Difference Discretization of Laplacian Operator. Appl. Comput. Math. 2023, 22, 259–274. [Google Scholar] [CrossRef]
  61. Zhou, B.; Qin, L.; Gong, W. Stereo-Matching Algorithm Using Weighted Guided Image Filtering Based on Laplacian of Gaussian Operator. Laser Optoelectron. Prog. 2019, 56, 101502. [Google Scholar] [CrossRef]
Figure 1. Schematic diagram of the proposed method. The calculation process of the proposed method is briefly described as follows: First, image preprocessing is performed. Then, image encoding is carried out. Finally, the LZC of the image is calculated.
Figure 1. Schematic diagram of the proposed method. The calculation process of the proposed method is briefly described as follows: First, image preprocessing is performed. Then, image encoding is carried out. Finally, the LZC of the image is calculated.
Entropy 27 01014 g001
Figure 2. The one-dimensional simulation signal. (a) One frequency component in the signal. (b) Two frequency components in the signal.
Figure 2. The one-dimensional simulation signal. (a) One frequency component in the signal. (b) Two frequency components in the signal.
Entropy 27 01014 g002
Figure 3. The two-dimensional simulation signal. (a) I1. (b) I2. (c) I3. (d) I4. (e) I5. (f) I6. (g) I7. (h) I8.
Figure 3. The two-dimensional simulation signal. (a) I1. (b) I2. (c) I3. (d) I4. (e) I5. (f) I6. (g) I7. (h) I8.
Entropy 27 01014 g003
Figure 4. The images of Type-I RSDDs datasets. (a) Original images. (b) Divided images. The red box indicates the location of the defect in the image.
Figure 4. The images of Type-I RSDDs datasets. (a) Original images. (b) Divided images. The red box indicates the location of the defect in the image.
Entropy 27 01014 g004
Figure 5. Calculation results under different methods. For the calculation results of LZ, FD, EN, MA, JP, and GL, the minimum value indicates the location of the defect.
Figure 5. Calculation results under different methods. For the calculation results of LZ, FD, EN, MA, JP, and GL, the minimum value indicates the location of the defect.
Entropy 27 01014 g005
Figure 6. The images of AITEX datasets. (a) Original images. (b) Divided images. The red box indicates the location of the defect in the image.
Figure 6. The images of AITEX datasets. (a) Original images. (b) Divided images. The red box indicates the location of the defect in the image.
Entropy 27 01014 g006
Figure 7. Calculation results achieved using different methods. For the calculation results of LZ, FD, EN, MA, JP, and GL, the minimum value indicates the location of the defect.
Figure 7. Calculation results achieved using different methods. For the calculation results of LZ, FD, EN, MA, JP, and GL, the minimum value indicates the location of the defect.
Entropy 27 01014 g007
Figure 8. The image under different brightness and the result of two-dimensional Lempel–Ziv complexity: (a) 1; (b) 0.8; (c) 0.6; (d) 0.4; and (e) 0.2. (f) The result of two-dimensional Lempel–Ziv complexity.
Figure 8. The image under different brightness and the result of two-dimensional Lempel–Ziv complexity: (a) 1; (b) 0.8; (c) 0.6; (d) 0.4; and (e) 0.2. (f) The result of two-dimensional Lempel–Ziv complexity.
Entropy 27 01014 g008
Figure 9. The image under different contrast ratios and the result of two-dimensional Lempel–Ziv complexity: (a) 1; (b) 0.8; (c) 0.6; (d) 0.4; (e) 0.2. (f) The result of two-dimensional Lempel–Ziv complexity.
Figure 9. The image under different contrast ratios and the result of two-dimensional Lempel–Ziv complexity: (a) 1; (b) 0.8; (c) 0.6; (d) 0.4; (e) 0.2. (f) The result of two-dimensional Lempel–Ziv complexity.
Entropy 27 01014 g009
Figure 10. The image under different sharpening method and the result of two-dimensional Lempel–Ziv complexity. (a) Vertical sharpening. (b) Robert operator sharpening. (c) Sobel operator sharpening. (d) Laplacian operator sharpening. (e) LoG operator sharpening. (f) The result of two-dimensional Lempel–Ziv complexity.
Figure 10. The image under different sharpening method and the result of two-dimensional Lempel–Ziv complexity. (a) Vertical sharpening. (b) Robert operator sharpening. (c) Sobel operator sharpening. (d) Laplacian operator sharpening. (e) LoG operator sharpening. (f) The result of two-dimensional Lempel–Ziv complexity.
Entropy 27 01014 g010
Figure 11. The image under different brightness and the result of two-dimensional Lempel–Ziv complexity: (a) 1; (b) 0.8; (c) 0.6; (d) 0.4; (e) 0.2. (f) The result of two-dimensional Lempel–Ziv complexity.
Figure 11. The image under different brightness and the result of two-dimensional Lempel–Ziv complexity: (a) 1; (b) 0.8; (c) 0.6; (d) 0.4; (e) 0.2. (f) The result of two-dimensional Lempel–Ziv complexity.
Entropy 27 01014 g011
Table 1. The constructed two-dimensional signal information.
Table 1. The constructed two-dimensional signal information.
Serial Number of 2D SignalDescription
I1zeros (128, 128)
I2ones (128, 128)
I3zeros (128, 128) and the 10th row is 1
I4zeros (128, 128) and the 10th column is 1
I5zeros (128, 128) and the 10th, 11th, 12th, 13th, 14th, and 15th rows are 1
I6zeros (128, 128) and the 10th and 20th row are 1
I7zeros (128, 128) and the 10th and 21st rows are 1
I8zeros (128, 128) and the 10th, 21st, and 43rd rows are 1
Disclaimer/Publisher’s Note: The statements, opinions and data contained in all publications are solely those of the individual author(s) and contributor(s) and not of MDPI and/or the editor(s). MDPI and/or the editor(s) disclaim responsibility for any injury to people or property resulting from any ideas, methods, instructions or products referred to in the content.

Share and Cite

MDPI and ACS Style

Yin, J.; Sui, W.; Zhuang, X.; Sheng, Y.; Li, Y. Two-Dimensional Image Lempel–Ziv Complexity Calculation Method and Its Application in Defect Detection. Entropy 2025, 27, 1014. https://doi.org/10.3390/e27101014

AMA Style

Yin J, Sui W, Zhuang X, Sheng Y, Li Y. Two-Dimensional Image Lempel–Ziv Complexity Calculation Method and Its Application in Defect Detection. Entropy. 2025; 27(10):1014. https://doi.org/10.3390/e27101014

Chicago/Turabian Style

Yin, Jiancheng, Wentao Sui, Xuye Zhuang, Yunlong Sheng, and Yongbo Li. 2025. "Two-Dimensional Image Lempel–Ziv Complexity Calculation Method and Its Application in Defect Detection" Entropy 27, no. 10: 1014. https://doi.org/10.3390/e27101014

APA Style

Yin, J., Sui, W., Zhuang, X., Sheng, Y., & Li, Y. (2025). Two-Dimensional Image Lempel–Ziv Complexity Calculation Method and Its Application in Defect Detection. Entropy, 27(10), 1014. https://doi.org/10.3390/e27101014

Note that from the first issue of 2016, this journal uses article numbers instead of page numbers. See further details here.

Article Metrics

Back to TopTop