A method and system for image recognition of the spacing of liquid crystal texture stripes

By processing liquid crystal texture images through image segmentation, gradient calculation, and adaptive decomposition algorithms, the accuracy and robustness issues of liquid crystal texture stripe spacing recognition are solved, achieving high-precision recognition under low-quality conditions.

CN117218417BActive Publication Date: 2025-11-14WUHAN UNIV
View PDF 2 Cites 0 Cited by

Patent Information

Application Number
CN202311137925.6
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2023-09-05
Publication Date
2025-11-14
Estimated Expiration
2043-09-05

AI Technical Summary

Technical Problem

Existing methods for identifying the spacing of liquid crystal texture stripes cannot efficiently and accurately identify the stripe spacing when the image quality is poor, the stripe direction is irregular, or the texture has defects.

Method used

By acquiring liquid crystal texture images, performing image segmentation and grayscale processing, calculating image gradient information, using gradient direction matrix transformation and directional gradient histogram to determine the main direction of the stripes, rotating the image and dividing sampling lines, and combining adaptive decomposition algorithm and Fourier transform, the stripe spacing and pitch are calculated.

Benefits of technology

It improves the accuracy and robustness of image recognition results under conditions of low-quality photos and defects, effectively filters noise, eliminates uneven brightness, and accurately identifies stripe spacing and pitch.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN117218417B_ABST
    Figure CN117218417B_ABST
Patent Text Reader

Abstract

A method and system for image recognition of stripe spacing in liquid crystal textures, relating to the field of liquid crystal texture experimental data processing technology, includes: segmenting and grayscale processing a liquid crystal texture image to obtain multiple sub-images; calculating the gradient of each sub-image to obtain image gradient information; transforming the gradient direction matrix by treating gradient directions differing by 180° as the same direction to obtain a transformed direction matrix; statistically analyzing the gradient directions corresponding to gradients greater than a first multiple of the maximum gradient value in the gradient magnitude matrix in the transformed direction matrix to obtain an directional gradient histogram; and, when determining that stripes in a sub-image have a main direction, dividing multiple horizontal sampling lines and extracting their grayscale data signals to calculate the corresponding stripe spacing. This application only statistically analyzes the gradient directions corresponding to gradients greater than a first multiple of the maximum gradient value in the gradient magnitude matrix to obtain the directional gradient histogram, which can filter noise, eliminate brightness unevenness, and improve the accuracy of image recognition results.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This application relates to the field of liquid crystal texture experimental data processing technology, specifically to an image recognition method and system for the spacing of liquid crystal texture stripes. Background Technology

[0002] Some substances, after being molten or dissolved in a solvent, lose the rigidity of solid matter but gain the fluidity of liquid, and retain the anisotropic ordered arrangement of some crystalline molecules, forming an intermediate state that combines some properties of crystals and liquids. This oriented ordered fluid that exists during the transition from solid to liquid is called liquid crystal.

[0003] Liquid crystals can be broadly classified into three phases: nematic, smectic, and cholesteric. Some liquid crystal molecules possess chirality and, under suitable surface anchoring conditions, can exhibit a layered structure, such as the smectic C phase and the cholesteric phase. Under a polarizing microscope (POM), these phases display a striped structure, and the period of these stripes reflects the fine structure of the corresponding liquid crystal phase, such as the pitch information of the cholesteric phase. Early methods involved manually reading the data from images, but this method proved to be inaccurate and difficult to implement. Later, a method was proposed to read the image brightness information and measure the bright and dark bands separately, avoiding defects. However, this method is highly inaccurate when the stripes are not clear enough, when there are many liquid crystal defects, and when dealing with high-viscosity polymers.

[0004] Therefore, there is a need for a fast and simple image recognition method that can still achieve high-precision results even when the image quality is poor, the stripe direction is irregular, and there are many defects in the texture. Summary of the Invention

[0005] This application provides an image recognition method for the spacing of liquid crystal texture stripes, which can solve the technical problem that the spacing of liquid crystal texture stripes cannot be efficiently recognized in the prior art.

[0006] In a first aspect, embodiments of this application provide an image recognition method for the spacing of liquid crystal texture stripes, the method comprising:

[0007] Acquire a liquid crystal texture image, and perform image segmentation and grayscale processing to obtain multiple sub-images;

[0008] For each sub-image, its gradient is calculated to obtain image gradient information, which includes a gradient direction matrix G1 and a gradient magnitude matrix G2. Gradient directions that differ by 180° are treated as the same direction and the gradient direction matrix G1 is transformed to obtain a transformed direction matrix G1′. The gradient directions corresponding to the gradients in the gradient magnitude matrix G2 that are greater than the first multiple T1 of the maximum gradient value are counted in the transformed direction matrix G1′. Based on all the gradient directions, the orientation gradient histogram corresponding to the sub-image is obtained.

[0009] When determining the main direction of the stripes in a sub-image based on the directional gradient histogram, the sub-image is rotated so that the main direction of the stripes is vertical, and multiple horizontal sampling lines are divided on the sub-image. The grayscale data signals of all sampling lines are extracted, and the corresponding stripe spacing is calculated. The stripe spacing distribution of the liquid crystal texture image is obtained by statistically analyzing the stripe spacing of all sub-images.

[0010] In conjunction with the first aspect, in one embodiment, the liquid crystal texture image is an image captured by a polarizing microscope.

[0011] In conjunction with the first aspect, in one embodiment, before performing the image segmentation and grayscale processing, the liquid crystal texture image is adjusted according to a preset scale.

[0012] After calculating the stripe spacing of the sampling line, the stripe spacing is adjusted according to a preset scale.

[0013] In conjunction with the first aspect, in one embodiment, the step of transforming the gradient direction matrix G1 by treating gradient directions that differ by 180° as the same direction to obtain the transformed direction matrix G1′ specifically includes the following steps:

[0014] Transform the gradient direction matrix G1 by treating gradient directions that are 180° apart as the same direction, so that all gradient directions in the gradient direction matrix G1 are mapped to the range of -90° to 90°.

[0015] In conjunction with the first aspect, in one implementation, determining whether there is a main direction for the stripes in the sub-image based on the directional gradient histogram specifically includes the following steps:

[0016] Extract the highest frequency and average frequency from the directional gradient histogram. When the highest frequency is greater than the second multiple T2 of the average frequency, it is determined that there is a main direction in the sub-image, and the main direction is the gradient direction corresponding to the highest frequency.

[0017] In conjunction with the first aspect, in one implementation, the step of extracting the grayscale data signals of all sampling lines in the sub-image and calculating the corresponding stripe spacing specifically includes the following steps:

[0018] For each sampling line, an adaptive decomposition algorithm is used to decompose the grayscale data signal to obtain multiple intrinsic mode functions;

[0019] After removing the highest frequency intrinsic mode function, the sum of all remaining intrinsic mode functions is used to obtain the stripe spacing signal;

[0020] The fringe spacing signal is subjected to Fourier transform to obtain the fringe spacing spectrum;

[0021] Extract the first frequency f1 corresponding to the highest component and the second frequency f2 corresponding to the second highest component in the fringe spacing spectrum. When the ratio of the first frequency f1 to the second frequency f2 is greater than a third multiple T3, it is determined that the sampling line has a concentrated fringe distribution and the fringe spacing is the reciprocal of the first frequency f1.

[0022] In conjunction with the first aspect, in one implementation, the step of calculating the stripe spacing of all sub-images specifically includes the following steps:

[0023] The fringe spacing of a sub-image is obtained by statistically analyzing the fringe spacing of the sample lines with a concentrated fringe distribution in all sub-images.

[0024] In conjunction with the first aspect, in one implementation, the adaptive decomposition algorithm includes empirical mode decomposition, singular spectral analysis, intrinsic timescale decomposition, and variations thereof.

[0025] In conjunction with the first aspect, in one embodiment, the method further includes:

[0026] The pitch is obtained from the stripe spacing of the sampling lines; the pitch distribution of the liquid crystal texture image is obtained by statistically analyzing the pitch of all sub-images.

[0027] Secondly, embodiments of this application provide an image recognition system for the spacing of liquid crystal texture stripes, the image recognition system comprising:

[0028] The image acquisition module is used to perform image segmentation and grayscale processing on the liquid crystal texture image to obtain multiple sub-images;

[0029] The image processing module is used to calculate the gradient of each sub-image to obtain image gradient information, which includes a gradient direction matrix G1 and a gradient magnitude matrix G2. Gradient directions differing by 180° are treated as the same direction to transform the gradient direction matrix G1, resulting in a transformed direction matrix G1′. The module also counts the gradient directions in the transformed direction matrix G1′ corresponding to gradients in the gradient magnitude matrix G2 that are greater than the first multiple T1 of the maximum gradient value, and obtains the orientation gradient histogram for each sub-image based on all the gradient directions. Furthermore, when the orientation gradient histogram indicates the presence of a main direction for the stripes in a sub-image, the module rotates the sub-image so that the main direction of the stripes is vertical, divides the sub-image into multiple horizontal sampling lines, extracts the grayscale data signals of all sampling lines, and calculates the corresponding stripe spacing. Finally, the module counts the stripe spacing of all sub-images to obtain the stripe spacing distribution of the liquid crystal texture image.

[0030] The beneficial effects of the technical solutions provided in this application include at least the following:

[0031] By calculating the gradient direction in the transformed direction matrix corresponding to only the gradients that are greater than the first multiple of the maximum gradient value in the gradient magnitude matrix, the directional gradient histogram is obtained. This solves the technical problem of inefficient identification of liquid crystal texture stripe spacing in related technologies. It can filter noise, eliminate uneven brightness, and improve the accuracy of image recognition results when the image quality is poor, the stripe direction is irregular, and there are many defects in the texture. Attached Figure Description

[0032] Figure 1 A flowchart illustrating an embodiment of the image recognition method for liquid crystal texture stripe spacing in this application;

[0033] Figure 2 This is a liquid crystal texture image and a segmentation diagram of a cyanoethyl cellulose lyotropic liquid crystal introduced in a specific embodiment of this application.

[0034] Figure 3 This is the histogram of the directional gradient of sub-image 10 in a specific embodiment of this application;

[0035] Figure 4 This is a schematic diagram of the green channel grayscale data signal and sampling line distribution of sub-image number 10 in a specific embodiment of this application.

[0036] Figure 5 This is the original signal diagram of the grayscale data signal of sampling line 5 in a specific embodiment of this application.

[0037] Figure 6 The image shows the IMF1-4 and residual signals obtained after EMD decomposition of sampling line 5 in a specific embodiment of this application, as well as the spectrum obtained by their corresponding Fourier transforms.

[0038] Figure 7 The pitch distribution histogram and corresponding probability density curve are obtained from the final results of a specific implementation of this application.

[0039] Figure 8 This is a quantile-quantile plot corresponding to the generalized extreme value distribution obtained from experimental images in a specific embodiment of this application. Detailed Implementation

[0040] To enable those skilled in the art to better understand the present application, the technical solutions in the embodiments of the present application will be clearly and completely described below with reference to the accompanying drawings. Obviously, the described embodiments are only some embodiments of the present application, and not all embodiments. Based on the embodiments in the present application, all other embodiments obtained by those of ordinary skill in the art without creative effort are within the scope of protection of the present application.

[0041] The terms "comprising" and "having," and any variations thereof, in the specification, claims, and accompanying drawings of this application are intended to cover non-exclusive inclusion. For example, a process, method, system, product, or apparatus that includes a series of steps or units is not limited to the listed steps or units, but may optionally include steps or units not listed, or may optionally include other steps or units inherent to such process, method, product, or apparatus. The terms "first," "second," and "third," etc., are used to distinguish different objects, etc., and do not indicate a sequence, nor do they limit "first," "second," and "third" to different types.

[0042] In the description of the embodiments of this application, terms such as "exemplary," "for example," or "for instance" are used to indicate examples, illustrations, or explanations. Any embodiment or design described as "exemplary," "for example," or "for instance" in the embodiments of this application should not be construed as being more preferred or advantageous than other embodiments or designs. Specifically, the use of terms such as "exemplary," "for example," or "for instance" is intended to present the relevant concepts in a concrete manner.

[0043] In the description of the embodiments of this application, unless otherwise stated, " / " means "or". For example, A / B can mean A or B. The "and / or" in the text is merely a description of the relationship between related objects, indicating that there can be three relationships. For example, A and / or B can mean: A exists alone, A and B exist simultaneously, and B exists alone. In addition, in the description of the embodiments of this application, "multiple" means two or more.

[0044] In some processes described in the embodiments of this application, multiple operations or steps are included in a specific order. However, it should be understood that these operations or steps may not be executed in the order they appear in the embodiments of this application, or they may be executed in parallel. The sequence number of the operation is only used to distinguish different operations, and the sequence number itself does not represent any execution order. In addition, these processes may include more or fewer operations, and these operations or steps may be executed sequentially or in parallel, and these operations or steps may be combined.

[0045] To make the objectives, technical solutions, and advantages of this application clearer, the embodiments of this application will be described in further detail below with reference to the accompanying drawings.

[0046] In a first aspect, embodiments of this application provide an image recognition method for the spacing of liquid crystal texture stripes, including:

[0047] A liquid crystal texture image is acquired, and then image segmentation and grayscale processing are performed to obtain multiple sub-images.

[0048] For each sub-image, its gradient is calculated to obtain image gradient information, which includes a gradient direction matrix G1 and a gradient magnitude matrix G2. Gradient directions that differ by 180° are treated as the same direction and transformed into a transformed direction matrix G1′. The gradient directions in the transformed direction matrix G1′ of the gradient magnitude matrix G2 that are greater than the first multiple T1 of the maximum gradient value are counted. Based on all the above gradient directions, the directional gradient histogram corresponding to the sub-image is obtained.

[0049] When determining the dominant direction of the stripes in a sub-image based on the directional gradient histogram, the sub-image is rotated so that the dominant stripe direction is vertical. Multiple horizontal sampling lines are then divided on the sub-image, and the grayscale data signals of all sampling lines are extracted. The corresponding stripe spacing is then calculated. The stripe spacing distribution of the liquid crystal texture image is obtained by statistically analyzing the stripe spacing of all sub-images.

[0050] In this embodiment, T1 is set, and only the gradient values ​​in G1 that are greater than T1 times the maximum value of G2 are counted to obtain the directional gradient histogram. This operation can filter noise, eliminate brightness inhomogeneities caused by birefringence under stress on the sample, and extract more useful information when the image quality is low.

[0051] This application obtains the directional gradient histogram by only counting the gradients in the gradient magnitude matrix that are greater than the first multiple of the maximum gradient value in the transformed direction matrix. This solves the technical problem of inefficient recognition of the spacing of liquid crystal texture stripes in related technologies. It can filter noise, eliminate uneven brightness, and improve the accuracy of image recognition results when the image quality is poor, the stripe direction is irregular, and there are many defects in the texture.

[0052] Furthermore, in one embodiment, the liquid crystal texture image is an image captured by a polarizing microscope.

[0053] In this embodiment, the imported liquid crystal texture image is the original image captured by a polarizing microscope. The original image is an M×N×3 RGB image, and the brightness range of each color channel is 0 to 255.

[0054] Image segmentation refers to splitting an original image into several smaller images, which can then be reassembled into the original image.

[0055] Image grayscale conversion transforms the original M×N×3 RGB matrix into an M×N matrix, resulting in k m×n two-dimensional matrices ranging from 0 to 255. The grayscale conversion process involves extracting one of the three color channels or performing a weighted average of the three color channels to obtain a grayscale image. Grayscale conversion of the aforementioned small image yields a sub-image.

[0056] Image processing efficiency can be improved by segmenting the liquid crystal textured image.

[0057] Furthermore, in one embodiment, before performing the above image segmentation and grayscale processing, the liquid crystal texture image is adjusted according to a preset scale.

[0058] After calculating the stripe spacing of the above sampling lines, the stripe spacing is adjusted according to the preset scale.

[0059] In this embodiment, after acquiring the liquid crystal texture image, it needs to be scaled according to the scale bar.

[0060] Furthermore, in one embodiment, the gradient direction matrix G1 is transformed by treating gradient directions that differ by 180° as the same direction to obtain the transformed direction matrix G1′, specifically including the following steps:

[0061] Transform the gradient direction matrix G1 by treating gradient directions that are 180° apart as the same direction, so that all gradient directions in the gradient direction matrix G1 are mapped to the range of -90° to 90°.

[0062] In this embodiment, the gradient is calculated for each m×n matrix to obtain the gradient direction matrix G1 and the gradient magnitude matrix G2. The value of G1 is -180 to 180°. Since gradients that differ by 180° are also opposite gradients, they represent the same direction. The gradient direction in G1 is mapped to a range of magnitude 180° to obtain the transformed direction matrix G1′.

[0063] By setting a first multiple T1, only the gradient values ​​in G1 corresponding to positions in G2 that are greater than T1 times the maximum value of G2 are counted. This means only the gradient directions corresponding to positions with gradient values ​​higher than T1 times the maximum value of G2 are counted, resulting in a directional gradient histogram. This operation can filter noise, eliminate brightness inhomogeneities caused by birefringence under stress on the sample, and extract more useful information even with low-quality images.

[0064] Furthermore, in one embodiment, the above-mentioned determination of whether there is a main direction for the stripes in the sub-image based on the directional gradient histogram specifically includes the following steps:

[0065] Extract the highest frequency and average frequency from the directional gradient histogram. When the highest frequency is greater than the second multiple T2 of the average frequency, it is determined that there is a main direction in the sub-image, and the main direction is the gradient direction corresponding to the highest frequency.

[0066] In this embodiment, a second multiple T2 is set, and the highest frequency GM1 and the average frequency GM2 are read from the gradient orientation distribution. Only when GM1 / GM2>T2 is it considered that the stripes in this sub-image have a clear main direction A, where A is the angle value corresponding to GM1. Otherwise, it is considered that this sub-image does not have a main direction of the stripe structure, and the stripe spacing cannot be calculated.

[0067] Furthermore, in one embodiment, the sub-image is rotated by a certain angle while maintaining the image, such that the main direction of the stripes in the sub-image is rotated to 90°, i.e., the vertical direction. The image rotation is performed while maintaining the relative distance between any two pixels in the image before rotation.

[0068] After rotating the sub-image, when dividing the sampling lines, the sampling line direction is perpendicular to the main direction of the stripes. A horizontal sampling line is set so that the sampling line can be perpendicular to the main direction and obtain the brightness information of each pixel, that is, the grayscale data signal. The grayscale data signal is a one-dimensional array D, which is a non-stationary signal.

[0069] Furthermore, in one embodiment, the extraction of grayscale data signals from all sampling lines in the sub-image and the calculation of the corresponding stripe spacing specifically includes the following steps:

[0070] For each sampling line, an adaptive decomposition algorithm is used to decompose the grayscale data signal to obtain multiple Intrinsic Mode Functions (IMFs).

[0071] After removing the highest frequency intrinsic mode function, the sum of all remaining intrinsic mode functions is used to obtain the stripe spacing signal.

[0072] The fringe spacing signal is subjected to Fourier transform to obtain the fringe spacing spectrum.

[0073] Extract the first frequency f1 corresponding to the highest component and the second frequency f2 corresponding to the second highest component in the fringe spacing spectrum. When the ratio of the first frequency f1 to the second frequency f2 is greater than a third multiple T3, it is determined that the sampling line has a concentrated fringe distribution and the fringe spacing is the reciprocal of the first frequency f1.

[0074] Furthermore, in one embodiment, the above-mentioned method of calculating the stripe spacing of all sub-images specifically includes the following steps:

[0075] The fringe spacing of a sub-image is obtained by statistically analyzing the fringe spacing of the sample lines with a concentrated fringe distribution in all sub-images.

[0076] In this embodiment, an adaptive decomposition algorithm for non-stationary signals is used when decomposing the signal, such as Empirical Mode Decomposition (EMD), singular spectrum analysis, intrinsic timescale decomposition and its variants.

[0077] Taking Empirical Mode Decomposition (EMD) as an example, EMD is performed on the grayscale data signal. The iteration count is set to n ≥ 4, resulting in n intrinsic mode functions (IMF1 ~ n) and a residual Res. IMF1 represents high-frequency noise information in the grayscale data signal, while IMF4 and Res represent low-frequency noise information caused by uneven background brightness. The signal stripe spacing S, representing the stripe spacing information of this sampling line, is extracted: S = IMF2 + IMF3. A Fourier transform is performed on S to obtain the corresponding spectrum, and the frequency f1 corresponding to the highest component and the frequency f2 corresponding to the second highest component are calculated. A third multiple T3 is set. When f1 / f2 > T3, the stripes are considered to have a relatively concentrated spacing distribution, and the stripe spacing x = 1 / f1 at this time is obtained, in pixels.

[0078] The final stripe spacing X is obtained based on the scale information.

[0079] The above process is repeated for other sampling locations in the current sub-image to obtain all stripe spacings in the same sub-image. This process is repeated for each sub-image to obtain the stripe spacing distribution of the liquid crystal texture image. The distribution obtained from the stripe spacing statistics is a generalized extreme value distribution.

[0080] Furthermore, in one embodiment, the above method further includes:

[0081] The pitch is obtained based on the stripe spacing of the sampling lines. The pitch distribution of the liquid crystal texture image is obtained by statistically analyzing the pitch of all sub-images.

[0082] In this embodiment, all sampling lines and sub-images are calculated iteratively to obtain the pitch distribution.

[0083] In one specific embodiment, refer to Figure 1 , Figure 1 This is a schematic flowchart of the first embodiment of the image recognition method for liquid crystal texture stripe spacing according to this application. Figure 1As shown, the image recognition method for the stripe spacing of liquid crystal texture includes importing the original RGB image, performing image segmentation and grayscale conversion to obtain multiple sub-images, calculating the gradient of each sub-image, mapping the gradient direction to a range of 180°, determining whether the sub-image has a principal direction, and if the result is negative, jumping to the next sub-image to determine whether it has a principal direction. When a principal direction is determined in a sub-image, the sub-image is rotated and sampled lines are divided to obtain sampled line data. The sampled line data is then decomposed using the EMD method to obtain stripe signals. Fourier transform is performed on the stripe signals to determine whether the sampled line has a concentrated stripe distribution. If the result is negative, jumping to the next stripe to determine whether it has a concentrated stripe distribution. When a concentrated stripe distribution is determined in a sampled line, the stripe spacing of the next sampled line is calculated. The stripe spacing of all sampled lines with stripe distributions in the sub-images is calculated iteratively, and the stripe distribution of all sub-images is statistically analyzed to obtain the stripe spacing distribution of the liquid crystal texture image.

[0084] The image recognition method for liquid crystal texture stripe spacing of the present invention is simple, accurate, and robust. It can effectively read stripe information when the image quality is poor, the stripe direction is irregular, and there are many defects in the texture. It can also effectively distinguish images without stripe structure and sub-images, which greatly improves its robustness and obtains high-precision results. It is simple, accurate, and robust.

[0085] Secondly, embodiments of this application also provide an image recognition system for the spacing of liquid crystal texture stripes, including an image acquisition module and an image processing module.

[0086] The image acquisition module is used to segment and grayscale the image to obtain multiple sub-images.

[0087] The image processing module calculates the gradient of each sub-image to obtain image gradient information, including a gradient direction matrix G1 and a gradient magnitude matrix G2. Gradient directions differing by 180° are treated as the same direction to transform the gradient direction matrix G1, resulting in a transformed direction matrix G1′. The gradient directions corresponding to the gradients in the gradient magnitude matrix G2 that are greater than the first multiple T1 of the maximum gradient value are identified in the transformed direction matrix G1′. Based on all these gradient directions, a histogram of oriented gradients for each sub-image is obtained.

[0088] The image processing module is also used to rotate the sub-image so that the main direction of the stripes is vertical when the stripes in the sub-image are determined to have a main direction based on the orientation gradient histogram. It then divides the sub-image into multiple horizontal sampling lines, extracts the grayscale data signals of all sampling lines, and calculates the corresponding stripe spacing. The stripe spacing distribution of the liquid crystal texture image is obtained by statistically analyzing the stripe spacing of all sub-images.

[0089] In one specific embodiment, for a large-pitch cholesteric phase fingerprint texture of cyanoethyl cellulose lyotropic liquid crystal, a liquid crystal texture stripe spacing image recognition method is used to statistically determine its pitch (twice the stripe spacing). The process is as follows: Figure 1 .

[0090] First, import the RGB image of the cholesteric phase texture of cyanoethyl cellulose taken by a polarizing microscope, and set the scale bar to 343px corresponding to 20μm.

[0091] The image is divided into 25 sub-images, such as Figure 2 As shown, the data from the green channel is then converted to grayscale.

[0092] Calculate the gradient for each sub-image to obtain the gradient direction matrix G1 and the gradient magnitude matrix G2, and map them to the range of -90° to 90°.

[0093] Setting the threshold T1 = 0.70, the directional gradient histogram is obtained. Taking the 10th sub-image as an example, as follows... Figure 3 As shown.

[0094] Read the highest value GM1 and the average value GM2 of the corresponding angle in the frequency distribution map, set the threshold T2 = 1.30, GM1 / GM2 = 3.72, and determine that the main direction is 45°.

[0095] Rotate the sub-image so that its principal direction is aligned with a 90° angle, and divide the sampling lines, such as... Figure 4 As shown.

[0096] Taking sampling line number 5 as an example, its grayscale data signal is as follows: Figure 5 As shown, EMD decomposition was performed on it using piecewise cubic Hermite interpolation. Its IMF1-4, residuals, and corresponding spectrograms are shown below. Figure 6 As shown.

[0097] Perform a Fourier transform on IMF2+IMF3, set the threshold T3=1.1, and find its highest frequency of 2.77×10-2Hz. The ratio of the highest frequency to the second highest frequency is 1.36. The fringe spacing of this sampling line is 36.10px and the pitch is 4.21μm.

[0098] The pitch distribution is obtained by iteratively calculating all sampling lines and sub-images. The distribution obtained by this method conforms to the generalized extreme value distribution, such as... Figure 7 As shown, its parameters are: k = 0.3325, μ = 3.8535, σ = 0.4548. The quantile-quantile plot of the distribution is shown below. Figure 8 As shown, the distribution fits well.

[0099] The above examples demonstrate that the method used in this example has good accuracy and robustness, and can quickly measure the pitch information in texture photographs.

[0100] The functions of each module in the above image recognition system correspond to the steps in the above image recognition method embodiments, and their functions and implementation processes will not be described in detail here.

[0101] It should be noted that the sequence numbers of the embodiments in this application are for descriptive purposes only and do not represent the superiority or inferiority of the embodiments.

[0102] Through the above description of the embodiments, those skilled in the art can clearly understand that the methods of the above embodiments can be implemented by means of software plus necessary general-purpose hardware platforms. Of course, they can also be implemented by hardware, but in many cases the former is a better implementation method. Based on this understanding, the technical solution of this application, in essence, or the part that contributes to the prior art, can be embodied in the form of a software product. This computer software product is stored in a storage medium (such as ROM / RAM, magnetic disk, optical disk) as described above, and includes several instructions to cause a terminal device to execute the methods described in the various embodiments of this application.

[0103] The above are merely preferred embodiments of this application and do not limit the patent scope of this application. Any equivalent structural or procedural transformations made using the content of this application's specification and drawings, or direct or indirect applications in other related technical fields, are similarly included within the patent protection scope of this application.

Claims

1. An image recognition method for the spacing of liquid crystal texture stripes, characterized in that, The image recognition method includes: Acquire a liquid crystal texture image, and perform image segmentation and grayscale processing to obtain multiple sub-images; For each sub-image, its gradient is calculated to obtain image gradient information, which includes a gradient direction matrix G1 and a gradient magnitude matrix G2. Gradient directions that differ by 180° are treated as the same direction and the gradient direction matrix G1 is transformed to obtain a transformed direction matrix G1′. The gradient directions corresponding to the gradients in the gradient magnitude matrix G2 that are greater than the first multiple T1 of the maximum gradient value are counted in the transformed direction matrix G1′. Based on all the gradient directions, the orientation gradient histogram corresponding to the sub-image is obtained. When determining the main direction of the stripes in a sub-image based on the directional gradient histogram, the sub-image is rotated so that the main direction of the stripes is vertical, and multiple horizontal sampling lines are divided on the sub-image. The grayscale data signals of all sampling lines are extracted, and the corresponding stripe spacing is calculated. The stripe spacing distribution of the liquid crystal texture image is obtained by statistically analyzing the stripe spacing of all sub-images.

2. The image recognition method for the spacing of liquid crystal texture stripes as described in claim 1, characterized in that, The liquid crystal texture image is an image captured using a polarizing microscope.

3. The image recognition method for the spacing of liquid crystal texture stripes as described in claim 1, characterized in that, Before performing the image segmentation and grayscale processing, the liquid crystal texture image is adjusted according to a preset scale. After calculating the stripe spacing of the sampling line, the stripe spacing is adjusted according to a preset scale.

4. The image recognition method for the spacing of liquid crystal texture stripes as described in claim 1, characterized in that, The step of transforming the gradient direction matrix G1 by treating gradient directions that are 180° apart as the same direction to obtain the transformed direction matrix G1′ specifically includes the following steps: Transform the gradient direction matrix G1 by treating gradient directions that are 180° apart as the same direction, so that all gradient directions in the gradient direction matrix G1 are mapped to the range of -90° to 90°.

5. The image recognition method for the spacing of liquid crystal texture stripes as described in claim 1, characterized in that, The step of determining whether there is a main direction for the stripes in a sub-image based on the directional gradient histogram specifically includes the following steps: Extract the highest frequency and average frequency from the directional gradient histogram. When the highest frequency is greater than the second multiple T2 of the average frequency, it is determined that there is a main direction in the sub-image, and the main direction is the gradient direction corresponding to the highest frequency.

6. The image recognition method for the spacing of liquid crystal texture stripes as described in claim 1, characterized in that, The extraction of grayscale data signals from all sampling lines in the sub-image and the calculation of the corresponding stripe spacing specifically include the following steps: For each sampling line, an adaptive decomposition algorithm is used to decompose the grayscale data signal to obtain multiple intrinsic mode functions; After removing the highest frequency intrinsic mode function, the sum of all remaining intrinsic mode functions is used to obtain the stripe spacing signal; The fringe spacing signal is subjected to Fourier transform to obtain the fringe spacing spectrum; Extract the first frequency f1 corresponding to the highest component and the second frequency f2 corresponding to the second highest component in the fringe spacing spectrum. When the ratio of the first frequency f1 to the second frequency f2 is greater than a third multiple T3, it is determined that the sampling line has a concentrated fringe distribution and the fringe spacing is the reciprocal of the first frequency f1.

7. The image recognition method for liquid crystal texture stripe spacing as described in claim 6, characterized in that, The step of calculating the stripe spacing of all sub-images specifically includes the following steps: The fringe spacing of a sub-image is obtained by statistically analyzing the fringe spacing of the sample lines with a concentrated fringe distribution in all sub-images.

8. The image recognition method for liquid crystal texture stripe spacing as described in claim 6, characterized in that, The adaptive decomposition algorithm includes empirical mode decomposition, singular spectral analysis, intrinsic timescale decomposition, and its variants.

9. The image recognition method for the spacing of liquid crystal texture stripes as described in claim 1, characterized in that, The method further includes: The pitch is obtained from the stripe spacing of the sampling lines; the pitch distribution of the liquid crystal texture image is obtained by statistically analyzing the pitch of all sub-images.

10. An image recognition system for the spacing of liquid crystal textured stripes, characterized in that, The image recognition system includes: The image acquisition module is used to perform image segmentation and grayscale processing on the liquid crystal texture image to obtain multiple sub-images; The image processing module is used to calculate the gradient of each sub-image to obtain image gradient information, which includes a gradient direction matrix G1 and a gradient magnitude matrix G2. Gradient directions differing by 180° are treated as the same direction to transform the gradient direction matrix G1, resulting in a transformed direction matrix G1′. The module also counts the gradient directions in the transformed direction matrix G1′ corresponding to gradients in the gradient magnitude matrix G2 that are greater than the first multiple T1 of the maximum gradient value, and obtains the orientation gradient histogram for each sub-image based on all the gradient directions. Furthermore, when the orientation gradient histogram indicates the presence of a main direction for the stripes in a sub-image, the module rotates the sub-image so that the main direction of the stripes is vertical, divides the sub-image into multiple horizontal sampling lines, extracts the grayscale data signals of all sampling lines, and calculates the corresponding stripe spacing. Finally, the module counts the stripe spacing of all sub-images to obtain the stripe spacing distribution of the liquid crystal texture image.

Citation Information

Patent Citations

  • Method for detecting straight lines in images

    CN111445510A

  • Fringe detector, sensing drum inspection device thereof, liquid crystal panel inspection device thereof, fringe detection method and recording medium for recording fringe detection program

    JP2002098615A