A method for enhanced texture feature extraction and its application in acanthosis nigricans
By combining homomorphic Gaussian filtering and Gabor filtering and adopting a detection method based on the length and size of the profile, the problems of low detection rate and high error rate in the diagnosis of black anabola are solved, achieving more efficient texture feature extraction and diagnostic accuracy.
Patent Information
- Application Number
- CN202210315431.1
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2022-03-28
- Publication Date
- 2025-04-11
- Estimated Expiration
- 2042-03-28
AI Technical Summary
The existing diagnostic methods for anabola melanoma have problems such as experience-dependent naked eye examination, equipment limitations, huge data sets and difficult collection, resulting in low detection rates and high error rates.
The combination of homomorphic Gaussian filtering and Gabor filtering is used to enhance image and texture detection on the image, and the detection method based on the length of the contour curve is reduced and the detection rate is improved.
It significantly improves the detection effect of fine textures, reduces the error rate, and improves the detection rate, which is suitable for clinical images of acanthosis black.
Smart Images

Figure CN114863139B_ABST
Abstract
Description
Technical Field
[0001] The invention relates to a method for enhancing texture feature extraction and application thereof in acanthosis nigricans, belonging to the technical field of image texture feature extraction. Background Art
[0002] At present, the main diagnostic methods for acanthosis nigricans are: dermatoscope-based inspection technology; skin fluorescence diagnosis method based on different pigmented skin lesions; and method of detecting from dermatoscope image data sets using deep learning convolutional neural networks. The dermatoscope-based inspection technology method mainly relies on naked eye recognition and is too dependent on experienced doctors. The skin fluorescence diagnosis method based on different pigmented skin lesions has great limitations because the two-photon excitation melanin fluorescence used by the equipment can only be used on the limbs, not on the head or other parts. The method of detecting from dermatoscope image data sets using deep learning convolutional neural networks has a high detection rate, but requires a very large data set and runs very slowly.
[0003] Andre Esteva published a paper in Nature that used a deep learning convolutional neural network to detect melanoma from a dermoscopic image dataset with an accuracy rate of 94%. However, the author used a very large dataset containing 120,000 dermoscopic images, which was not made public. Image preprocessing, image segmentation, image feature selection and feature extraction, and image classification and recognition are the main directions of current research on skin disease case maps. This method requires a huge dataset, and pathological images are kept confidential in medicine, so data collection is difficult.
[0004] In the study of skin diseases, feature extraction is the most important link, which usually includes the following extraction methods:
[0005] 1. Texture extraction method based on Gaussian filtering
[0006] Gaussian filtering has a very wide range of applications. It can effectively reduce Gaussian noise and has a wide range of applications in image processing and machine vision. It is usually used to reduce image noise and reduce detail levels. Gaussian filtering performs weighted averaging on each pixel value of the entire image to achieve the effect of smoothing the image. Usually, a mask or convolution kernel is used to scan each pixel value, and the weighted average grayscale value of the pixels in the neighborhood determined by the template is used to replace the value of the central pixel of the template. Gaussian filtering can be implemented in two main ways: one is discretized window sliding window convolution, and the other is through Fourier transform. Here, the former method is mainly used for Gaussian filtering. When discretizing the window sliding window convolution, the Gaussian kernel is mainly used. The Gaussian kernel is generally an odd-sized Gaussian template, which is mainly divided into two types of convolution templates: 3x3 and 5x5. Here, the convolution kernel is set to 5x5 and the standard deviation is 0. The smaller the standard deviation, the narrower the two-dimensional Gaussian image, and the smoothing effect is not obvious. Finally, the obtained image is processed as a single-channel grayscale image with a threshold of 0, so as to obtain an image with clearer texture.
[0007] The algorithm of Gaussian filtering is relatively simple. It has a good blocking effect on Gaussian noise, but it is less effective in other interferences. In addition, Gaussian filtering has a poor effect on texture recognition, large texture recognition, and cannot recognize smaller textures. It is suitable for some images polluted by Gaussian noise and with low precision requirements. If it is used alone for acanthosis nigricans, the error rate is very high.
[0008] 2. Texture feature extraction method based on Gabor filtering
[0009] Gabor filter feature is a feature that can be used to describe image texture information. The frequency and direction of Gabor filter are similar to the human visual system, which is particularly suitable for texture representation and discrimination. Gabor feature mainly relies on Gabor kernel to window the signal in the frequency domain, so as to describe the local frequency information of the signal. Gabor kernel relies on Fourier transform, so that we can convert the signal to the frequency domain and let Gabor kernel to window in the frequency domain. In the original spatial domain, a Gabor kernel is actually the result of a Gaussian kernel modulated by a sine wave, which can be regarded as the Gaussian kernel applied to the frequency domain part of the sine wave. A one-dimensional Gabor kernel is defined by the product of a Gaussian kernel and a complex wave. The response result of the input signal near a certain frequency neighborhood can be obtained by convolving the Gabor kernel with the input signal. The response result realizes frequency domain filtering and can also be used to describe the frequency information of the signal. Gabor feature uses Gabor kernel to describe the frequency information of the signal, thus serving as the feature of the signal. A two-dimensional Gaussian kernel is the product of a two-dimensional Gaussian function and a two-dimensional complex wave. A Gabor kernel can obtain the response of a certain frequency neighborhood of the image, and this response result can be regarded as a feature of the image. Then, if we use multiple Gabor kernels of different frequencies to obtain the response of the image in different frequency neighborhoods, we can finally form the characteristics of the image in each frequency band, and this feature can describe the frequency information of the image. Gabor filters are self-similar, that is, all Gabor filters can be generated from a mother wavelet through expansion and rotation. In practical applications, Gabor filters can extract relevant features at different scales and directions in the frequency domain.
[0010] In general, the Gabor filter determines the lower limit of the product of effective duration and effective frequency bandwidth, which means that it can obtain the best localization in both time domain and frequency domain. At the same time, the Gabor filter is bandpass, which is consistent with the human visual receptive field model. However, the algorithm of the Gabor filter is relatively complex, the amount of calculation is too large, and the detection of small wavelengths is too precise, which is prone to misdetection. There is a large proportion of fine textures in acanthosis nigricans. Therefore, if the Gabor filter is used alone, the probability of misdetection is particularly high.
[0011] 3. Texture extraction method based on Frangi filter bank
[0012] Frangi filter is a filter constructed by Frangi in 1998 by calculating the eigenvalue of Hessian matrix to enhance the vascular structure. Hessian filter is a filter whose kernel function is calculated based on Hessian matrix. Hessian matrix is actually a second-order partial derivative matrix. The eigenvector of the matrix plays an important role in image edge detection and can describe its local curvature. The typical filter proposed based on Hessian matrix is Frangi filter.
[0013] The Frangi filter can effectively eliminate the interference caused by fine textures or background and avoid some false detections, but it also misses many fine textures. When detecting acanthosis nigricans, fine textures account for a large proportion, so it will cause a large error rate.
[0014] In the study of acanthosis nigricans, it was found that texture extraction based on Gaussian filtering is prone to distortion when extracting large textures and cannot extract small textures; texture extraction based on Gabor filtering is too sensitive to the extraction of fine lines and is prone to errors; texture extraction based on Frangi filtering cannot extract fine lines, affecting experimental errors.
[0015] Based on this, the present invention is proposed. Summary of the invention
[0016] In view of the deficiencies in the prior art, the present invention provides a method for enhancing texture feature extraction and its application in acanthosis nigricans. The specific technical solution is as follows:
[0017] A method for enhancing texture feature extraction comprises the following steps:
[0018] Step S1, converting the input image into a grayscale image;
[0019] Step S2, performing homomorphic Gaussian filtering on the grayscale image to obtain a Gaussian filtered image, and performing Gabor filtering on the grayscale image to obtain a Gabor filtered image;
[0020] Step S3, performing normalization filtering on the Gaussian filter image and the Gabor filter image to obtain a normalized filter image;
[0021] Step S4, binarizing the normalized filtered image to obtain a binary image;
[0022] Step S5: The binary image is tested based on the size of the contour curvature, and the result is output after the test.
[0023] Further optimization of the above technical solution is to perform homomorphic Gaussian filtering on the grayscale image to obtain a Gaussian filtered image, which is represented by f t(u, v), Gabor filtering is performed on the grayscale image to obtain the Gabor filtered image, which is represented by f g (u, v);
[0024]
[0025] f′ t (u, v) = f t (u, v)-min (u,v) f t (u, v),
[0026]
[0027] f′ g (u, v) = f g (u, v)-min (u,v) f g (u, v),
[0028] min (u,v) f g (u, v) is f g The minimum value of (u, v), max (u,v) f′ t (u, v) is f′ t The maximum value of (u, v),
[0029]
[0030] GF(u, v) represents the normalized filtered image, 0<p<1.
[0031] Further optimization of the above technical solution, in step S5, the detection method based on the length of the contour is:
[0032] First, perform contour detection of the binary image using the Canny operator. Based on this, use the FindContours function to find the texture of the target detection. Finally, use the DrawContours function to set the size of the texture. The detected texture is used to detect the target texture in a loop.
[0033] The convolution operator used by the Canny operator is:
[0034]
[0035] The first-order partial derivative matrix in the x-direction is P[i, j], the first-order partial derivative matrix in the y-direction is Q[i, j], the gradient amplitude is M[i, j], and the gradient direction is θ[i, j];
[0036]
[0037]
[0038]
[0039]
[0040] Among them, f[i,j] represents the grayscale value of the image, [i,j] represents a pixel, i is the horizontal coordinate of the pixel, and j is the vertical coordinate of the pixel;
[0041] Based on P[i,j] and Q[i,j], find M[i,j] and θ[i,j].
[0042] To further optimize the above technical solution, after contour detection by the Canny operator, the FindContours function is used to retain only the external edges and compress the elements in the horizontal, vertical and diagonal directions; finally, the DrawContours function is used to set the threshold to eliminate the interference of non-target textures.
[0043] A further optimization of the above technical solution is that the threshold is set between (30, 70), and the unit of the threshold is pixel.
[0044] A further optimization of the above technical solution is that the homomorphic Gaussian filtering is to enhance the grayscale image by homomorphic filtering and then perform Gaussian filtering on the enhanced result.
[0045] Further optimization of the above technical solution, 0.1≤p≤0.3.
[0046] Further optimization of the above technical solution, the application of the method for enhanced texture feature extraction in acanthosis nigricans.
[0047] Beneficial effects of the present invention:
[0048] The present invention optimizes the detection effect at fine textures and proposes a method to reduce errors. It mainly uses a method combining homomorphic Gaussian filtering and Gabor filtering to perform image enhancement and texture detection on images. Finally, the texture is further eliminated based on the extracted image features, which greatly reduces the false detection rate of textures, thereby improving the detection rate. BRIEF DESCRIPTION OF THE DRAWINGS
[0049] Figure 1 This is a flow chart of the method for enhancing texture feature extraction according to the present invention;
[0050] Figure 2 It is a random clinical image in the image library of acanthosis nigricans collected;
[0051] Figure 3 Yes Figure 2 The effect diagram obtained by using Gaussian filtering;
[0052] Figure 4 Yes Figure 2 The effect diagram obtained by using Frangi filtering;
[0053] Figure 5 Yes Figure 2 The effect diagram obtained by using homomorphic Gaussian filtering;
[0054] Figure 6 Yes Figure 2 The effect image obtained by using Gabor filtering;
[0055] Figure 7 Yes Figure 2 The effect image obtained by combining homomorphic Gaussian filtering and Gabor filtering;
[0056] Figure 8 This is the effect diagram obtained after the detection based on the length of the contour in Example 1;
[0057] Fig. 9 This is the principle diagram of non-maximum suppression;
[0058] Fig.10 is a curve diagram of the threshold value and the target texture in Example 3;
[0059] Fig.11 is a curve diagram of the threshold value and the target texture in Example 4;
[0060] Fig.12 It is a scatter plot between detection rate and p value;
[0061] Fig.13 It is a scatter plot between false positive rate and p-value. DETAILED DESCRIPTION
[0062] In order to make the purpose, technical solution and advantages of the present invention more clearly understood, the present invention is further described in detail below in conjunction with the accompanying drawings and embodiments. It should be understood that the specific embodiments described herein are only used to explain the present invention and are not intended to limit the present invention.
[0063] Example 1
[0064] The basic process of the algorithm of the present invention is as follows Figure 1 As shown. The input image is converted into a grayscale image. The input image is a clinical image of acanthosis nigricans. Considering the detection of texture features, the detection of fine lines is mainly considered.
[0065] The grayscale image is subjected to homomorphic Gaussian filtering to obtain a Gaussian filtered image, and the grayscale image is subjected to Gabor filtering to obtain a Gabor filtered image.
[0066] The Gaussian filter image and the Gabor filter image are subjected to normalization filtering to obtain a normalized filter image.
[0067] The normalized filtered image is binarized to obtain a binary image. The purpose of binarization is to reduce noise interference.
[0068] The binary image is tested based on the size of the contour curvature, and the result is output after the test. The test based on the size of the contour curvature can reduce the error.
[0069] In the study of acanthosis nigricans, a detection method based on the length and size of contour curvature was proposed, taking into account that there are many interferences in the detected lines, such as interference from subtle wavelengths and interference from thick textures. Therefore, by adding a detection method based on the length and size of contour curvature, the length of contour curvature can be set according to different situations, thereby controlling the length and number of textures, thereby reducing the false detection rate and improving the effect of target detection.
[0070] 1.1 Homomorphic Gaussian Filtering
[0071] The definition of homomorphic Gaussian filtering is: after enhancing the image with homomorphic filtering, Gaussian filtering is performed on the enhanced result to extract texture features.
[0072] There will always be distortion when filtering. Homomorphic Gaussian filtering can greatly reduce image distortion, enhance the image, and increase the detection effect of the image. Homomorphic filtering is an image processing method that combines frequency filtering and grayscale transformation. It relies on the image illumination divided by the reflectivity model as the basis for frequency domain processing, and uses compressed brightness range and enhanced contrast to improve image quality. Using this method can make image processing conform to the nonlinear characteristics of the human eye's response to brightness, avoiding the distortion of directly performing Fourier transform processing on the image.
[0073] In this embodiment, the homomorphic Gaussian filtering is to enhance the grayscale image by homomorphic filtering, and then perform Gaussian filtering on the enhanced result to extract texture features.
[0074] 1.2 Homomorphic Filtering
[0075] Changes in illumination have always been a problem that has troubled many engineers and researchers. The color of an object is determined by its ability to reflect long-wave (red), medium-wave (green), and short-wave (blue) light, rather than by the absolute value of the intensity of the reflected light. The color of an object is not affected by illumination non-uniformity and is consistent. The ability of an object to reflect illumination is an inherent property of the object. Therefore, homomorphic filtering is a method that simultaneously compresses the image brightness range and enhances the image contrast in the frequency domain, and is based on the image imaging model.
[0076] The key to homomorphic filtering lies in the design of the filter. For an image with uneven illumination, homomorphic filtering can simultaneously adjust the brightness and enhance the contrast, thereby improving the image quality.
[0077] The filter is a high-pass filter that suppresses low-frequency brightness components and enhances high-frequency reflection components.
[0078] 1.3 Gabor filtering
[0079] Gabor filter can extract spatial local frequency features and is an effective texture detection tool. The impulse response of Gabor filter can be defined as a sine wave multiplied by a Gaussian function. Due to the multiplication and convolution properties, the Fourier transform of the impulse response of Gabor filter is the convolution of the Fourier transform of its harmonic function and the Fourier transform of the Gaussian function. The filter consists of a real part and an imaginary part, which are orthogonal to each other. A set of Gabor function arrays with different frequencies and directions is very useful for image feature extraction.
[0080] 1.4. Normalization of the two filters
[0081] In the study of acanthosis nigricans, in order to solve the adaptability problem of homomorphic Gaussian filtering and Gabor filtering to the clinical images of acanthosis nigricans, an innovative method was proposed to use a filter image combining homomorphic Gaussian filtering and Gabor filtering as an image for texture extraction. Gabor filtering can make up for the deficiency of homomorphic Gaussian filtering in extracting fine textures. At the same time, homomorphic Gaussian filtering strengthens the extraction of textures on the main road and reduces the false detection rate of Gabor filtering. Combining the two filters, which complement each other, can greatly improve the detection rate of texture features.
[0082] Specifically:
[0083] The grayscale image is subjected to homomorphic Gaussian filtering to obtain a Gaussian filtered image, which is represented by f t (u, v), Gabor filtering is performed on the grayscale image to obtain the Gabor filtered image, which is represented by f g (u, v);
[0084]
[0085] f′ t (u, v) = ft(u, v) - min (u,v) f t (u, v),
[0086]
[0087] f′ g(u, v) = f g (u, v)-min (u,v) f g (u, v)
[0088]
[0089] GF(u, v) represents the normalized filtered image, 0<p<1.
[0090] Where (u, v) represents the position of a pixel, u represents the horizontal coordinate corresponding to the pixel, and v represents the vertical coordinate corresponding to the pixel. (u,v) f g (u, v) is f g The minimum value of (u, v), max (u,v) f′ t (u, v) is f′ t The maximum value of (u, v) is mainly used to convert the linear function of the original data into the range of [0, 1].
[0091] The setting range of p is (0, 1), which can highlight the response of the Gabor filter bank to a certain extent and suppress the response of the homomorphic Gaussian filter.
[0092] 1.5. Detection method based on contour length and size
[0093] Based on the image obtained after normalizing the two filtering results, the contour detection of the binary image is first performed using the Canny operator. On this basis, the FindContours function is used to find the texture of the target detection. Finally, the DrawContours function is used to set the size of the texture. The detected texture is used to detect the target texture in a loop, thereby achieving the result of reducing the error.
[0094] The convolution operator used by the Canny operator is:
[0095]
[0096] The first-order partial derivative matrix in the x-direction is P[i,j], the first-order partial derivative matrix in the y-direction is Q[i,j], the gradient amplitude is M[i,j], and the gradient direction is θ[i,j];
[0097]
[0098]
[0099]
[0100]
[0101] Among them, f[i,j] represents the grayscale value of the image, [i,j] represents a pixel, i is the horizontal coordinate of the pixel, and j is the vertical coordinate of the pixel;
[0102] Based on P[i,j] and Q[i,j], find M[i,j] and θ[i,j].
[0103] Example 2
[0104] Comparative study of several filtering methods in acanthosis nigricans
[0105] Figure 2 It is a random clinical image in the collected image library of acanthosis nigricans, which is the original image. Figure 3 Yes Figure 2 The effect image obtained by using Gaussian filtering. Figure 4 Yes Figure 2 The effect diagram obtained by using Frangi filtering. Figure 5 Yes Figure 2 The effect image obtained by using homomorphic Gaussian filtering.
[0106] Comparative analysis, such as Figure 2 , 3 As shown in Figure 5, in the field of image processing of acanthosis nigricans, the effect obtained by using homomorphic Gaussian filtering is much better than that by using Gaussian filtering.
[0107] Figure 6 Yes Figure 2 The effect image obtained by using Gabor filtering. Figure 7 Yes Figure 2 The effect image obtained by combining homomorphic Gaussian filtering and Gabor filtering was normalized.
[0108] contrast Figure 5 , 6 ,7: The effect of combining homomorphic Gaussian filtering and Gabor filtering and performing normalization is obviously better than homomorphic Gaussian filtering or Gabor filtering.
[0109] Figure 8 is the effect diagram obtained after the detection of the contour length in Example 1. Figure 8 In , the threshold is set to (30, 70); Figure 8 In order to intuitively display the output texture effect, the background in the image is filtered out.
[0110] Example 3
[0111] Fig. 9The schematic diagram of non-maximum suppression is shown in Figure 1. The larger the element value in the gradient amplitude matrix of the image, the larger the gradient value of the point in the image, but this does not mean that the point is the edge. In the Canny algorithm, non-maximum suppression is an important step in edge detection. In a popular sense, it means finding the local maximum value of the pixel point and setting the grayscale value corresponding to the non-maximum point to 0, so that a large number of non-edge points can be eliminated.
[0112] After contour detection by the Canny operator, the FindContours function is used to retain only the external edges and compress the elements in the horizontal, vertical and diagonal directions, retaining only the key coordinates in these directions. Finally, the DrawContours function is used to set the threshold to exclude the interference of non-target textures. Experiments have found that the target detection rate is higher when the threshold is set between (30, 70), such as Fig.10 As shown, Fig.10 It is a curve graph of the threshold value and the target texture. Among them, (30, 70) refers to the area enclosed by all the pixels in each contour, in pixels.
[0113] Example 4
[0114] This embodiment combines the filtering results of Gabor filtering and Frangi filtering to normalize the two filters. Gabor filter is used to extract fine textures, while Frangi filter is used to extract coarse texture features, and textures of different thicknesses are detected.
[0115] In this embodiment, I g (x 1 , x 2 ) represents the result of Gabor filter, I f (x 1 , x 2 ) is the result of the Frangi filter. Both are normalized:
[0116] First normalize the Gabor filter:
[0117] I′(x 1 , x 2 )=I g (x 1 , x 2 )-min I g (x 1 , x 2 )
[0118]
[0119] Since there are zero values in the result of the Frangi filter,
[0120] mv=minI f (x 1 , x 2 ), I f (x 1 , x 2 )>0;
[0121] When I f (x 1 , x 2 )=0,
[0122]
[0123] When I f (x 1 , x 2 )>0,
[0124]
[0125] The result of normalizing and combining the two normalized filtering results is GF(x 1 , x 2 ),
[0126]
[0127] Among them, (x 1 , x 2 ) represents the position of a pixel, x 1 Indicates the horizontal coordinate corresponding to the pixel point, x 2 Indicates the vertical coordinate corresponding to the pixel point.
[0128] The normalized results of the two are used to perform a detection based on the contour length. The results are as follows Fig.11 , Fig.11 It is a curve diagram of the threshold value and the target texture in Example 4.
[0129] from Fig.11 It can be seen that more target textures are detected between the thresholds (30, 70). Although the normalization of Gabor filter and Frangi filter can also extract texture features, the number of target texture feature detections is not as good. After the homomorphic Gaussian filter enhances the texture and combines it with the Gabor filter, the target texture detection rate is higher than that of the former, which is especially suitable for clinical images of acanthosis nigricans.
[0130] Example 5
[0131] In the "Normalization of Two Filters" of Example 1 (hereinafter referred to as this method), detection is divided into the detection rate and false detection rate of texture features.
[0132] Detection rate:
[0133] p x is the correct texture detected by this method, p y is the texture in the original image. r is the detection rate of the correct texture, the higher the detection rate, the better.
[0134] False positive rate:
[0135] F x Indicates the texture that is misdetected compared to the original image; F y Indicates the non-texture area in the original image. f is the false detection rate, the lower the false detection rate, the better.
[0136] When changing the p value, the detection rate is obtained, such as Fig.12 As shown; when changing the p value, the false positive rate is obtained, such as Fig.13 As shown in the figure, from the perspective of detection rate and false detection rate, for acanthosis nigricans, setting p between [0.1, 0.3] has a better effect.
[0137] In other skin diseases, such as clinical images of melanoma and non-melanoma skin cancer (such as squamous cell carcinoma), the "Normalization of Two Filters" method in Example 1 is used to detect skin texture features. No matter what value p takes in (0, 1), the detection rate does not exceed 41%.
[0138] In the above embodiment, in order to achieve a better feature extraction effect, the image is first converted into a grayscale image and then the grayscale image is binarized, so that the black and white color contrast in the image is stronger and the recognition is higher.
[0139] The present invention proposes a solution combining homomorphic Gaussian filtering and Gabor filtering normalization, which solves the current situation that the detection of target texture features in acanthosis nigricans is too subtle and too general. The main texture features are enhanced by homomorphic Gaussian filtering, and the texture features are finely detected by Gabor filtering. The advantages of both are combined for normalization, and the degree of normalization is adjusted to eliminate the disadvantages of combining the two filtering methods to the maximum extent, thereby obtaining clearer target detection textures and reducing the error rate. At the same time, a method for extracting target texture features based on the size of contour length is proposed, which further eliminates some interference, greatly improves the detection rate, and reduces the false detection rate.
[0140] The above description is only a preferred embodiment of the present invention and is not intended to limit the present invention. Any modifications, equivalent substitutions and improvements made within the spirit and principles of the present invention should be included in the protection scope of the present invention.
Claims
1. A method for enhancing texture feature extraction, characterized in that The following steps are involved: Step S1, converting the input image into a grayscale image; Step S2, performing homomorphic Gaussian filtering on the grayscale image to obtain a Gaussian filtered image, and performing Gabor filtering on the grayscale image to obtain a Gabor filtered image; Step S3, performing normalization filtering on the Gaussian filter image and the Gabor filter image to obtain a normalized filter image; Step S4, binarizing the normalized filtered image to obtain a binary image; Step S5, the binary image is tested based on the size of the contour curvature, and after the test, the result is output; The grayscale image is subjected to homomorphic Gaussian filtering to obtain a Gaussian filtered image, which is expressed as , Gabor filtering is performed on the grayscale image to obtain the Gabor filtered image. The Gabor filtered image is expressed as ; , , , , for The minimum value of for The maximum value of , Represented as normalized filtered image, 0<p<1; In step S5, the detection method based on the contour length is: First, perform contour detection of the binary image using the Canny operator. Based on this, use the FindContours function to find the texture of the target detection. Finally, use the DrawContours function to set the size of the texture. The detected texture is used to detect the target texture in a loop. The convolution operator used by the Canny operator is: , ; The first-order partial derivative matrix in the x direction is P[i,j], the first-order partial derivative matrix in the y direction is Q[i,j], the gradient amplitude is M[i,j], and the gradient direction is ; , , , , Among them, f[i,j] represents the grayscale value of the image, [i,j] represents a pixel, i is the horizontal coordinate of the pixel, and j is the vertical coordinate of the pixel; According to P[i,j] and Q[i,j], find M[i,j] and .
2. The method for enhancing texture feature extraction according to claim 1, characterized in that: After contour detection by the Canny operator, the FindContours function is used to retain only the external edges and compress the elements in the horizontal, vertical and diagonal directions; finally, the DrawContours function is used to set the threshold to eliminate the interference of non-target textures.
3. The method for enhancing texture feature extraction according to claim 2, characterized in that: The threshold is set between (30, 70), and the unit of the threshold is pixel.
4. The method for enhancing texture feature extraction according to claim 1, characterized in that: The homomorphic Gaussian filtering is to enhance the grayscale image by homomorphic filtering and then perform Gaussian filtering on the enhanced result.
5. The method for enhancing texture feature extraction according to claim 1, characterized in that: 0.1≤p≤0.3。 6. Application of the method for enhanced texture feature extraction according to any one of claims 1 to 5 in acanthosis nigricans.
Citation Information
Patent Citations
Cloth defect detecting method based on machine vision
CN102706881A
Contour detection method based on variable receptive field scale global modulation
CN107767387A