A method, system, device, and medium for extracting image edge features.

By combining nonmaximum suppression and multi-scale edge detection with noise reduction processing, the problem of existing edge detection algorithms being sensitive to noise and illumination changes is solved, thereby improving the accuracy and stability of image edge detection.

CN116740109BActive Publication Date: 2026-01-30SHANDONG YUNHAI GUOCHUANG CLOUD COMPUTING EQUIP IND INNOVATION CENT CO LTD
View PDF 1 Cites 0 Cited by

Patent Information

Application Number
CN202310692820.0
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2023-06-12
Publication Date
2026-01-30
Estimated Expiration
2043-06-12

AI Technical Summary

Technical Problem

Existing edge detection algorithms are sensitive to noise and lighting changes in images, making it difficult to accurately extract image edge features when the external environment changes or there is a lot of noise.

Method used

The non-maximum suppression method is adopted to generate multiple edge feature images by suppressing neighborhoods of different scales. The most suitable edge feature image is determined by range comparison, and noise reduction is performed by combining median filtering and histogram equalization algorithms.

Benefits of technology

It improves the accuracy and noise resistance of image edge detection, enhances the resistance to interference from changes in illumination, and ensures the stability of edge detection.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN116740109B_ABST
    Figure CN116740109B_ABST
Patent Text Reader

Abstract

This invention belongs to the field of computer science, specifically relating to a method, system, device, and medium for extracting image edge features. The method includes: preprocessing an image to obtain an image of a predetermined format; calculating edge feature images of the image of the predetermined format based on non-maximum suppression and according to different suppression neighborhoods; comparing the edge feature images corresponding to different suppression neighborhoods according to a predetermined method to obtain the final edge feature image of the image; or extracting the final edge feature image of the image of the predetermined format through predetermined suppression neighborhoods. This invention provides an image edge feature extraction method that, by adding bidirectional traceability detection between edge detection maps of different scales, not only improves the detection accuracy of image edges but also increases the anti-interference ability of image edge detection against factors such as noise and illumination changes, ensuring the stability of image edge detection.
Need to check novelty before this filing date? Find Prior Art

Description

TECHNICAL FIELD

[0001] The present application belongs to the field of computer, and particularly relates to an image edge feature image extraction method, system, device and medium. BACKGROUND

[0002] In life, human beings recognize the objective world through the human eye, while computers recognize the world through images, and images are an important source of external information for computers. In particular, the processing of images by computers cannot directly process all the contents of the pixels of the image, and usually the image is simplified, and image edge feature extraction is one of the common simplification methods. Image edge features are a summary of the entire image information and contain a large amount of important information, and are the basic features of the image. Image edges are usually defined as the places with the most dramatic changes in gray scale (the places with the most dramatic changes in image gray scale values), which, from a mathematical point of view, is the differentiation (for digital images, it is the difference) of the image gray scale values, and for signal processing, it is to retain high-frequency signals through filtering. Image edges are particularly important information, and in theory, the entire information of the original image can be restored through edge information, so edge detection is an important part of image processing.

[0003] Edge detection technology is widely used in many fields such as medicine, robots, meteorology, and pattern recognition systems. Most current edge detection algorithms are designed based only on the changes in gradient vectors, and in general, the degree of change in gradient vectors is sensitive to noise and changes in light in the image, so in the case of changes in the external environment or large noise, the current edge detection algorithm cannot guarantee the correct extraction of edge feature information in the image.

[0004] Therefore, there is an urgent need for an effective solution to solve the above problems. SUMMARY

[0005] To solve the above problems, the present application provides an image edge feature image extraction method, comprising:

[0006] preprocessing the image to obtain an image in a predetermined format;

[0007] calculating the edge feature image of the image in the predetermined format based on the non-maximum suppression method and according to different suppression neighborhoods, and comparing the edge feature images corresponding to different suppression neighborhoods according to a predetermined manner to obtain the final edge feature image of the image; or

[0008] extracting the final edge feature image of the image in the predetermined format through a predetermined suppression neighborhood.

[0009] In some embodiments of the present application, the edge feature images of the image in the predetermined format are calculated based on the non-maximum suppression method and according to different suppression neighborhoods, and the final edge feature image of the image is obtained by comparison according to the edge feature images corresponding to different suppression neighborhoods in a predetermined manner, which comprises:

[0010] According to the size order of the suppression neighborhoods, the edge feature images corresponding to different suppression neighborhoods are compared one by one based on the range detection method to obtain the candidate edge feature image, taking the high-scale suppression neighborhood as the reference.

[0011] In some embodiments of the present application, according to the size order of the suppression neighborhoods, the edge feature images corresponding to different suppression neighborhoods are compared one by one based on the range detection method to obtain the candidate edge feature image, taking the high-scale suppression neighborhood as the reference.

[0012] The edge feature image corresponding to the high-scale suppression neighborhood is taken as the reference edge feature image.

[0013] And a first pixel point set is formed by selecting corresponding elements at a certain interval from the set composed of the pixel points in each edge in the edge feature image corresponding to the high-scale suppression neighborhood.

[0014] The coordinates of the pixel points in the first pixel point set are taken as the circle points, and the range formed by a predetermined radius is taken as the detection range according to the predetermined radius.

[0015] Based on the detection range, the edges in the edge feature image corresponding to the low suppression neighborhood that exist in the detection range are taken as the candidate edges, and the edge feature image composed of all the candidate edges in the low suppression neighborhood is taken as the reference edge feature image applied to the comparison of the edge feature image corresponding to the next low suppression neighborhood.

[0016] In some embodiments of the present application, the edge feature images of the image in the predetermined format are calculated based on the non-maximum suppression method and according to different suppression neighborhoods, and the final edge feature image of the image is obtained by comparison according to the edge feature images corresponding to different suppression neighborhoods in a predetermined manner, which further comprises:

[0017] Taking the candidate edge feature image as the reference, the candidate edge feature image is compared according to the order of the suppression neighborhoods from low to high and the high-scale suppression neighborhood by the range detection method, and the edges in the candidate edge feature image that do not exist in the edge feature image corresponding to the high-scale suppression neighborhood are discarded to obtain the final edge feature image.

[0018] In some embodiments of the present application, the final edge feature image of the image in the predetermined format is extracted by the predetermined suppression neighborhood, which comprises:

[0019] The edge feature images corresponding to different inhibition neighborhoods are compared with the manually labeled edge feature images based on range detection, and the inhibition neighborhood corresponding to the edge feature image with the highest edge number is taken as the predetermined inhibition neighborhood according to the edge number obtained through the comparison;

[0020] The edge feature extraction is performed on the image in the predetermined format based on the predetermined inhibition neighborhood according to the non-maximum suppression method to obtain a final edge feature image.

[0021] In some embodiments of the present application, the pre-processing of the image to obtain the image in the predetermined format comprises:

[0022] It is judged whether the image is a gray-scale image, and the image is converted into a gray-scale image through an image conversion algorithm in response to the image not being a gray-scale image.

[0023] In some embodiments of the present application, the method further comprises:

[0024] The gray-scale image is subjected to noise reduction processing through a median filter algorithm and a histogram equalization algorithm to obtain a noise-reduced image in the predetermined format.

[0025] Another aspect of the present application further provides an image edge feature image extraction system, comprising:

[0026] An image pre-processing module configured to pre-process an image to obtain an image in a predetermined format;

[0027] A first edge extraction module configured to calculate edge feature images of the image in the predetermined format based on the non-maximum suppression method and according to different inhibition neighborhoods, and to obtain a final edge feature image of the image based on the comparison of the edge feature images corresponding to different inhibition neighborhoods according to a predetermined manner; or

[0028] A second edge extraction module configured to extract a final edge feature image of the image in the predetermined format through a predetermined inhibition neighborhood.

[0029] Still another aspect of the present application further provides a computer device, comprising:

[0030] At least one processor; and

[0031] A memory storing computer instructions executable on the processor, the instructions being executed by the processor to implement the steps of the method according to any one of the above embodiments.

[0032] Still another aspect of the present application provides a computer readable storage medium storing a computer program, which, when executed by a processor, implements the steps of the method according to any one of the above embodiments.

[0033] The image edge feature image extraction method provided by the present application generates multiple edge feature images from multiple inhibition neighborhoods on the basis of the traditional edge detection algorithm, and determines the most suitable edge from the edge feature images corresponding to the multiple inhibition neighborhoods by range comparison to form the final edge feature image. The bidirectional tracing detection between edge detection images of different scales improves the detection accuracy of image edges, increases the anti-interference ability of image edge detection to noise and light changes, and ensures the stability of image edge detection. BRIEF DESCRIPTION OF DRAWINGS

[0034] In order to more clearly illustrate the technical solutions in the embodiments of the present application or the prior art, the drawings needed in the embodiments or prior art description will be briefly introduced below. Obviously, the drawings in the following description are only some embodiments of the present application, and other drawings can be obtained by those skilled in the art without creative effort on the basis of these drawings.

[0035] Figure 1 A flowchart of an image edge feature image extraction method provided by an embodiment of the present application;

[0036] Figure 2 A structural diagram of an image edge feature image extraction system provided by an embodiment of the present application;

[0037] Figure 3 A structural diagram of a computer device provided by an embodiment of the present application;

[0038] Figure 4 A structural diagram of a computer readable storage medium provided by an embodiment of the present application;

[0039] Figure 5 An implementation diagram of an embodiment of the image edge feature image extraction method provided by an embodiment of the present application. DETAILED DESCRIPTION

[0040] In order to make the objects, technical solutions and advantages of the present application clearer, the embodiments of the present application will be further described in detail below with reference to the drawings.

[0041] It should be noted that all the expressions of "first" and "second" in the embodiments of the present application are used to distinguish two same name different entities or different parameters, and the "first" and "second" are only for the convenience of description, and should not be understood as the limitation of the embodiments of the present application, and the subsequent embodiments will not be described one by one.

[0042] The present application aims to solve the problem that the change degree of gradient vector is more sensitive to noise and illumination change in the traditional image edge feature extraction. And in the case of large noise or external environment change, the traditional edge detection algorithm cannot guarantee the correct extraction of edge feature information in the image.

[0043] As shown in Figure 1 To solve the above problems, the present application provides an image edge feature image extraction method, comprising:

[0044] Step S1, pre-processing the image to obtain an image in a predetermined format;

[0045] Step S2, calculating the edge feature image of the image in the predetermined format based on the non-maximum suppression method and according to different suppression neighborhoods, and comparing the edge feature images corresponding to different suppression neighborhoods according to a predetermined manner to obtain the final edge feature image of the image; or

[0046] Step S3, extracting the final edge feature image of the image in the predetermined format through the predetermined suppression neighborhood.

[0047] In the embodiments of the present application, the image in the predetermined format refers to a gray image, and the suppression neighborhood refers to the range of the image calculated when the non-maximum suppression method is used to process the image. The implementation principle of the maximum suppression algorithm is to set the highest value in the image pixels in a square range to 1, and set the values of other pixels that are not the highest to 0. The range of the suppression field is usually a two-dimensional matrix, for example, a 3*3 matrix, a 4*4 matrix, …, a 9*9 matrix, etc. In step S1, the image that needs to be extracted for edge feature image is obtained by a predetermined algorithm to obtain a gray image.

[0048] In step S2, the gray image obtained in step S1 is calculated by the maximum suppression algorithm according to a plurality of suppression neighborhoods set in advance to obtain an edge feature image in the form of 0 and 1. The continuous curve or straight line formed by the pixels with value 1 in the edge feature image is the edge. Therefore, a plurality of edge feature images of the same size can be obtained by different suppression neighborhoods.

[0049] Further, the suppression neighborhood sizes are ranked in order, and the edge feature images corresponding to the higher-ranked suppression neighborhoods are used as reference to compare the edge feature images corresponding to the lower-ranked suppression neighborhoods. Specifically, an edge (a continuous curve or a straight line) is selected from the edge feature image corresponding to the higher-ranked suppression neighborhood, and then it is determined whether there is an edge feature in the edge feature image corresponding to the lower-ranked suppression neighborhood within a certain range of the edge. That is, assuming that the edge feature image corresponding to the higher-ranked suppression neighborhood is A, and the edge feature image corresponding to the lower-ranked suppression neighborhood is B, it is determined whether there is an edge in the edge feature image B within a certain range of the edge in the edge feature image A. It should be noted that the edge feature images A and B have the same size or are corresponding in the edge region.

[0050] Further, if there is a corresponding edge in the edge feature image corresponding to the lower-ranked suppression neighborhood, the edge is recorded as a candidate edge. After the comparison between the edge feature image corresponding to the higher-ranked suppression neighborhood and the edge feature image corresponding to the lower-ranked suppression neighborhood is completed, the candidate edges obtained through the comparison are recorded to form a candidate edge feature image. The candidate edge feature image is used to compare the edge range with the edge feature image corresponding to the next-ranked suppression neighborhood. In this way, the corresponding edge feature images corresponding to different suppression neighborhoods are added to the candidate edge feature image.

[0051] The above process is a comparison in the direction from the higher-ranked suppression neighborhood to the lower-ranked suppression neighborhood. Finally, the candidate edge feature image is obtained after the comparison in the edge feature image corresponding to the lowest-ranked suppression neighborhood. The candidate edge feature image can be referred to as a final candidate edge feature image.

[0052] Further, the edge feature image corresponding to the higher-ranked suppression neighborhood is compared with the candidate edge feature image in the same way according to the candidate edge feature image obtained in the above process. Specifically, the edge feature image corresponding to the lowest-ranked suppression neighborhood is compared with the candidate edge feature image in the above way, and the corresponding edge in the final candidate edge feature image that does not exist in the edge feature image corresponding to the higher-ranked suppression neighborhood is discarded from the candidate edge feature image.

[0053] The edge feature image corresponding to the lowest-ranked suppression neighborhood is used as a starting point to compare with the edge feature image corresponding to the highest-ranked suppression neighborhood one by one according to the candidate edge feature image. The edge features in the candidate edge feature image that do not match the edge features in the multiple suppression neighborhoods are removed. Finally, a final edge feature image is formed.

[0054] In step S3, a preset suppression neighborhood can be set to calculate the edge features in the image by the maximum suppression algorithm, and the calculated edge features are used as the final edge feature image.

[0055] In some embodiments of the present invention, the edge feature images of the image in the predetermined format are calculated based on the non-maximum suppression method and according to different suppression neighborhoods, and the final edge feature images of the image are obtained by comparing the edge feature images corresponding to different suppression neighborhoods in a predetermined manner.

[0056] Based on the size order of the suppression neighborhood, and taking the high-scale suppression neighborhood as a benchmark, the edge feature images corresponding to different neighborhoods are compared one by one using a range detection method to obtain candidate edge feature images.

[0057] In some embodiments of the present invention, candidate edge feature images are obtained by comparing the edge feature images corresponding to different neighborhoods one by one based on the size order of the suppression neighborhoods and taking the high-scale suppression neighborhoods as a benchmark, using a range detection method.

[0058] The edge feature image corresponding to the high-scale suppressed neighborhood is used as the reference edge feature image;

[0059] Then, select corresponding elements at certain intervals from the set of pixels in each edge of the edge feature image corresponding to the high-scale suppressed neighborhood to form the first pixel set;

[0060] Using the coordinates of the pixels in the first pixel set as the center, the area formed by the preset radius is taken as the detection range.

[0061] Based on the detection range, edges existing within the detection range in the edge feature image corresponding to the low-suppression neighborhood are taken as candidate edges, and the edge feature image composed of all candidate edges in the low-suppression neighborhood is taken as the reference edge feature image for comparison with the edge feature image corresponding to the next low-suppression neighborhood.

[0062] In this embodiment, after edge feature images corresponding to different suppression domains have been calculated using the maximum suppression algorithm and according to different suppression domains, forward tracing detection is performed on the edge feature images corresponding to the high suppression domains, using them as a benchmark, towards the edge feature images corresponding to the low suppression domains. Specifically, pixels are uniformly selected from each edge in the edge feature image corresponding to the high suppression domain as the corresponding first pixel detection point set. Then, using the pixels corresponding to the pixels in the first pixel detection point set as the center and a first preset parameter as the radius, all edges corresponding to the edge pixels in the corresponding region are found in the edge feature image corresponding to the low suppression domain. These edges are determined as candidate edges, resulting in a candidate feature image composed of candidate edges. Here, the first preset parameter is a parameter in pixels, and its size can be set to n pixels. By using the high-scale edge image as a benchmark and searching for candidate edges in the low-scale edge image, the accuracy of edge detection can be improved.

[0063] In some embodiments of the present application, the edge feature images of the image in the predetermined format are calculated based on the non-maximum suppression method and according to different suppression neighborhoods, and the final edge feature image of the image is obtained by comparing the edge feature images corresponding to the different suppression neighborhoods in a predetermined manner, further comprising:

[0064] According to the range detection method, the candidate edge feature image is compared with the edge feature images corresponding to the suppression neighborhoods in order from low to high, and the edges in the candidate edge feature image that do not exist in the edge feature images corresponding to the high-scale suppression neighborhoods are removed to obtain the final edge feature image.

[0065] In this embodiment, the candidate edge feature image is taken as the reference, and the edge pixels in the edge feature image corresponding to the high suppression neighborhood are searched and the candidate edge is corrected in the reverse direction. The method can refer to the method for determining the first pixel detection point set mentioned above, and the second pixel detection point set corresponding to each candidate edge in the candidate edge feature image is determined. Then, the pixels in the second pixel detection point set are taken as the center, and the second preset parameter is taken as the radius, and the edge pixels in the corresponding region in the edge feature image corresponding to the high suppression neighborhood are searched. The second preset parameter can be the same as the first preset parameter mentioned above, or can be different. The candidate edge in which there is no edge pixel in the candidate edge feature image is discarded, and the bidirectional backtracking edge detection correction image, i.e., the final edge feature image, is obtained.

[0066] In this process, by performing reverse correction detection in the target high-scale edge detection image, false response edges can be discarded, and the anti-noise capability can be improved. This operation can be iterated based on different scale edge detection images, and the edge image iterated to the lowest scale is determined as the final output. In this way, the anti-interference of image edge detection can be improved while ensuring the edge accuracy, and the image edge detection performance is effectively improved.

[0067] In some embodiments of the present application, the final edge feature image of the image in the predetermined format is extracted by the predetermined suppression neighborhood, comprising:

[0068] The edge feature images corresponding to the different suppression neighborhoods are compared with the manually labeled edge feature image based on the range detection method, and according to the number of edges obtained by comparison, the suppression neighborhood corresponding to the edge feature image with the highest number of edges is taken as the predetermined suppression neighborhood.

[0069] The final edge feature image of the image in the predetermined format is obtained by performing edge feature extraction on the image in the predetermined format based on the non-maximum suppression method according to the predetermined suppression neighborhood.

[0070] In the implementation of the fixed application scenario in the embodiment, the corresponding edge feature can be manually labeled, a plurality of edge feature images are obtained by using different suppression neighborhoods, and it is compared which edge feature image in the plurality of edge feature images has the most coincidences (that is, whether there is a corresponding edge pixel point within a preset radius range with the pixel of a certain edge as the center in the comparison mode described above) with the manually labeled edge, and the suppression neighborhood corresponding to the edge feature image with the most coincidences is taken as the predetermined suppression neighborhood, and is used for subsequent edge feature extraction of the image.

[0071] In some embodiments of the application, the pre-processing of the image to obtain an image in a predetermined format comprises:

[0072] It is determined whether the image is a grayscale image, and in response to the image not being a grayscale image, the image is converted into a grayscale image by an image conversion algorithm.

[0073] Further, as shown in Figure 5 When the corresponding image is obtained, it is necessary to determine whether the corresponding image is a grayscale image, and if it is a grayscale image, the subsequent process is directly performed, and if it is not a grayscale image, the image is converted into a grayscale image.

[0074] In some embodiments of the application, the method further comprises:

[0075] The grayscale image is subjected to noise reduction processing by a median filtering algorithm and a histogram equalization algorithm to obtain a noise-reduced image in a predetermined format.

[0076] In the embodiment, the grayscale image is subjected to noise reduction processing by a median filtering algorithm and a histogram equalization algorithm to improve the definition of the image.

[0077] The image edge feature image extraction method proposed by the application generates a plurality of edge feature images based on a plurality of suppression neighborhoods on the basis of the traditional edge detection algorithm, and determines the most suitable edge from the edge feature images corresponding to the plurality of suppression neighborhoods by range comparison to form the final edge feature image. By increasing the bidirectional tracing detection between edge detection images of different scales, the detection accuracy of the image edge is improved, and the anti-interference ability of the image edge detection to noise and light changes and other factors is increased, thereby ensuring the stability of the image edge detection.

[0078] As shown in Figure 2 Another aspect of the application further proposes an image edge feature image extraction system, comprising:

[0079] An image pre-processing module 1 configured to pre-process an image to obtain an image in a predetermined format;

[0080] a first edge extraction module 2 configured to calculate edge feature images of the image of the predetermined format based on a non-maxima suppression method and according to different suppression neighborhoods, and to obtain a final edge feature image of the image by comparison according to the edge feature images corresponding to the different suppression neighborhoods in a predetermined manner; or

[0081] a second edge extraction module 3 configured to extract a final edge feature image of the image of the predetermined format by a predetermined suppression neighborhood.

[0082] As shown in Figure 3 a further aspect of the present application also provides a computer device comprising:

[0083] at least one processor 2001; and

[0084] a memory 2002 storing computer instructions 2003 executable on the processor 2001, the instructions 2003 being executed by the processor 2001 to implement an image edge feature image extraction method comprising:

[0085] preprocessing the image to obtain an image of a predetermined format;

[0086] calculating edge feature images of the image of the predetermined format based on a non-maxima suppression method and according to different suppression neighborhoods, and obtaining a final edge feature image of the image by comparison according to the edge feature images corresponding to the different suppression neighborhoods in a predetermined manner; or

[0087] extracting a final edge feature image of the image of the predetermined format by a predetermined suppression neighborhood.

[0088] In some embodiments of the present application, the step of calculating edge feature images of the image of the predetermined format based on a non-maxima suppression method and according to different suppression neighborhoods, and obtaining a final edge feature image of the image by comparison according to the edge feature images corresponding to the different suppression neighborhoods in a predetermined manner comprises:

[0089] comparing the edge feature images corresponding to the different suppression neighborhoods one by one according to the size order of the suppression neighborhoods, taking a high-scale suppression neighborhood as a reference, to obtain a candidate edge feature image based on a range detection manner.

[0090] In some embodiments of the present application, the step of comparing the edge feature images corresponding to the different suppression neighborhoods one by one according to the size order of the suppression neighborhoods, taking a high-scale suppression neighborhood as a reference, to obtain a candidate edge feature image based on a range detection manner comprises:

[0091] taking the edge feature image corresponding to the high-scale suppression neighborhood as a reference edge feature image;

[0092] and from the set of pixels in each edge in the edge feature image corresponding to the high scale inhibition neighborhood, elements are selected at certain intervals to form a first set of pixels;

[0093] with the coordinates of the pixels in the first set of pixels as the center, a detection range is formed according to a preset radius, and based on the detection range;

[0094] the edges in the edge feature image corresponding to the low inhibition neighborhood that exist within the detection range are taken as candidate edges, and the edge feature image formed by all the candidate edges in the low inhibition neighborhood is taken as a reference edge feature image for comparison with the edge feature image corresponding to the next low inhibition neighborhood.

[0095] In some embodiments of the present application, the edge feature images of the image in the predetermined format are calculated based on the non-maximum suppression method and according to different inhibition neighborhoods, and the final edge feature image of the image is obtained by comparing the edge feature images corresponding to different inhibition neighborhoods in a predetermined manner, which further comprises:

[0096] based on the reference candidate edge feature image, the candidate edge feature images are compared in order from low to high according to the order of the inhibition neighborhoods, and the edges in the candidate edge feature images that do not exist in the edge feature images corresponding to the high scale inhibition neighborhood are removed to obtain the final edge feature image.

[0097] In some embodiments of the present application, the final edge feature image of the image in the predetermined format is extracted by a predetermined inhibition neighborhood, which comprises:

[0098] the edge feature images corresponding to different inhibition neighborhoods are compared with the manually labeled edge feature image based on the range detection method, and according to the number of edges obtained by comparison, the inhibition neighborhood corresponding to the edge feature image with the highest number of edges is taken as the predetermined inhibition neighborhood;

[0099] the final edge feature image of the image in the predetermined format is obtained by performing edge feature extraction on the image based on the non-maximum suppression method according to the predetermined inhibition neighborhood.

[0100] In some embodiments of the present application, the image is preprocessed to obtain the image in the predetermined format, which comprises:

[0101] determining whether the image is a grayscale image, and in response to the image not being a grayscale image, converting the image to a grayscale image by an image conversion algorithm.

[0102] In some embodiments of the present application, the method further comprises:

[0103] The gray-scale image is subjected to noise reduction processing by a median filtering algorithm and a histogram equalization algorithm to obtain a predetermined format image after noise reduction.

[0104] As shown in Figure 4 Another aspect of the present application further provides a computer readable storage medium 401 storing a computer program 402, which, when executed by a processor, implements an image edge feature image extraction method, comprising:

[0105] preprocessing the image to obtain a predetermined format image;

[0106] calculating edge feature images of the predetermined format image based on a non-maximum suppression method and different suppression neighborhoods, and comparing the edge feature images corresponding to the different suppression neighborhoods in a predetermined manner to obtain a final edge feature image of the image; or

[0107] extracting the final edge feature image of the predetermined format image by a predetermined suppression neighborhood.

[0108] In some embodiments of the present application, calculating edge feature images of the predetermined format image based on a non-maximum suppression method and different suppression neighborhoods, and comparing the edge feature images corresponding to the different suppression neighborhoods in a predetermined manner to obtain a final edge feature image of the image comprises:

[0109] comparing the edge feature images corresponding to the different suppression neighborhoods in a range detection manner according to the size order of the suppression neighborhoods, taking a high-scale suppression neighborhood as a reference to obtain a candidate edge feature image.

[0110] In some embodiments of the present application, comparing the edge feature images corresponding to the different suppression neighborhoods in a range detection manner according to the size order of the suppression neighborhoods, taking a high-scale suppression neighborhood as a reference to obtain a candidate edge feature image comprises:

[0111] taking the edge feature image corresponding to the high-scale suppression neighborhood as a reference edge feature image;

[0112] and selecting corresponding elements from a set of pixel points in each edge of the edge feature image corresponding to the high-scale suppression neighborhood at a certain interval to form a first pixel point set;

[0113] taking the coordinates of the pixel points in the first pixel point set as the center of a circle, and taking the range formed by a predetermined radius as a detection range according to the predetermined radius;

[0114] Based on the detection range, edges existing in the detection range in the edge feature image corresponding to the low-suppression neighborhood are taken as candidate edges, and an edge feature image composed of all the candidate edges in the low-suppression neighborhood is taken as a reference edge feature image applied to comparison of an edge feature image corresponding to a next low-suppression neighborhood.

[0115] In some embodiments of the present application, edge feature images of the image in the predetermined format are calculated based on the non-maximum suppression method and according to different suppression neighborhoods, and obtaining the final edge feature image of the image based on comparison of the edge feature images corresponding to the different suppression neighborhoods in a predetermined manner further comprises:

[0116] Based on the reference candidate edge feature image, the candidate edge feature images are compared according to the order of the suppression neighborhoods from low to high and the high-scale suppression neighborhood by the range detection method, and edges in the candidate edge feature images that do not exist in the edge feature image corresponding to the high-scale suppression neighborhood are removed to obtain the final edge feature image.

[0117] In some embodiments of the present application, extracting the final edge feature image of the image in the predetermined format by the predetermined suppression neighborhood comprises:

[0118] The edge feature images corresponding to the different suppression neighborhoods are compared with the manually-labeled edge feature image based on the range detection method, and according to the number of edges obtained by the comparison, the suppression neighborhood corresponding to the edge feature image with the highest number of edges is taken as the predetermined suppression neighborhood.

[0119] Based on the predetermined suppression neighborhood, the edge feature of the image in the predetermined format is extracted by the non-maximum suppression method to obtain the final edge feature image.

[0120] In some embodiments of the present application, pre-processing the image to obtain the image in the predetermined format comprises:

[0121] It is judged whether the image is a grayscale image, and in response to the image not being a grayscale image, the image is converted into a grayscale image by an image conversion algorithm.

[0122] In some embodiments of the present application, the method further comprises:

[0123] The grayscale image is subjected to noise reduction processing by a median filtering algorithm and a histogram equalization algorithm to obtain a noise-reduced image in the predetermined format.

[0124] The above are exemplary embodiments disclosed by the present application, but it should be noted that various changes and modifications can be made without departing from the scope of the embodiments disclosed by the present application defined by the claims. The functions, steps and / or actions of the method claims described herein need not be performed in any particular order. Furthermore, although elements of the embodiments disclosed by the present application can be described or claimed in individual forms, they can also be implemented together with a plurality of them, unless explicitly limited as singular.

[0125] It should be understood that, as used herein, the singular forms "a", "an" and "the" are intended to include the plural forms as well, unless the context clearly indicates otherwise. It will be further understood that the terms "comprises" and / or "comprising", or "includes" and / or "including" when used herein, specify the presence of stated features, integers, steps, operations, elements, and / or components, but do not preclude the presence or addition of one or more other features, integers, steps, operations, elements, components, and / or groups thereof.

[0126] The above-mentioned embodiment number of the embodiments of the present application is only for description, not representing the advantages or disadvantages of the embodiments.

[0127] Those skilled in the art can understand that all or part of the steps of the above-mentioned embodiments can be completed by hardware, or by program instructing relevant hardware to complete, and the program can be stored in a computer readable storage medium, and the storage medium mentioned above can be read-only memory, magnetic disk or optical disk, etc.

[0128] Those skilled in the art should understand that the above discussion of any embodiment is only exemplary, and is not intended to imply that the scope of the embodiments disclosed by the present application (including claims) is limited to these examples; under the idea of the embodiments of the present application, the above embodiments or technical features in different embodiments can also be combined, and there are many other changes of different aspects of the embodiments of the present application as described above, and for the sake of brevity, they are not provided in details. Therefore, any omission, modification, equivalent replacement, improvement, etc. made within the spirit and principles of the embodiments of the present application shall be included in the protection scope of the embodiments of the present application.

Claims

1. An image edge feature image extraction method characterized by, The method comprises: preprocessing the image to obtain an image in a predetermined format; calculating edge feature images of the image in the predetermined format based on a non-maximum suppression method and different suppression neighborhoods, and comparing the edge feature images corresponding to the different suppression neighborhoods in a predetermined manner to obtain a final edge feature image of the image; wherein the calculating the edge feature images of the image in the predetermined format based on the non-maximum suppression method and the different suppression neighborhoods, and the comparing the edge feature images corresponding to the different suppression neighborhoods in the predetermined manner to obtain the final edge feature image of the image comprise: taking the edge feature image corresponding to a high-scale suppression neighborhood as a reference edge feature image, selecting corresponding elements from a set of pixel points in each edge in the edge feature image corresponding to the high-scale suppression neighborhood at a certain interval to form a first pixel point set, taking the coordinates of the pixel points in the first pixel point set as the center of a circle, and taking the range formed by a predetermined radius as a detection range; taking the edges in the edge feature image corresponding to a low-scale suppression neighborhood that exist within the detection range as candidate edges, and taking the edge feature image composed of all the candidate edges in the low-scale suppression neighborhood as a reference edge feature image for comparison with the edge feature image corresponding to the next low-scale suppression neighborhood; taking the candidate edge feature image as the reference, comparing the candidate edge feature image with the edge feature images corresponding to the suppression neighborhoods in order from low to high by the range detection method, and removing the edges in the candidate edge feature image that do not exist in the edge feature image corresponding to the high-scale suppression neighborhood to obtain the final edge feature image.

2. The method of claim 1, wherein, The preprocessing the image to obtain an image in a predetermined format comprises: determining whether the image is a grayscale image, and converting the image into a grayscale image by an image conversion algorithm in response to the image not being a grayscale image.

3. The method of claim 2, wherein, The method further comprises: performing noise reduction processing on the grayscale image by a median filter algorithm and a histogram equalization algorithm to obtain a denoised image in the predetermined format.

4. An image edge feature image extraction system characterized by comprising: The method comprises: an image preprocessing module configured to preprocess an image to obtain an image in a predetermined format; The first edge extraction module is configured to calculate edge feature images of the image of the predetermined format based on a non-maximum suppression method and according to different suppression neighborhoods, and to obtain a final edge feature image of the image according to a predetermined manner based on the edge feature images corresponding to the different suppression neighborhoods; the first edge extraction module is further configured to take the edge feature image corresponding to a high-scale suppression neighborhood as a reference edge feature image; and to select corresponding elements at certain intervals from a set of pixel points in each edge in the edge feature image corresponding to the high-scale suppression neighborhood to form a first pixel point set; to take the coordinates of the pixel points in the first pixel point set as a circle point, and to take a range formed by a predetermined radius as a detection range according to the predetermined radius; to take edges in the edge feature image corresponding to a low-scale suppression neighborhood that exist within the detection range as candidate edges based on the detection range, and to take an edge feature image composed of all the candidate edges in the low-scale suppression neighborhood as a reference edge feature image applied to comparison of the edge feature image corresponding to a next low-scale suppression neighborhood; and to take the candidate edge feature image as a reference, to compare the candidate edge feature image according to the ordering of the suppression neighborhoods from low to high and the high-scale suppression neighborhood by a range detection method, and to discard edges in the candidate edge feature image that do not exist in the edge feature image corresponding to the high-scale suppression neighborhood to obtain a final edge feature image.

5. A computer device, characterized by Comprise: at least one processor; and a memory, the memory storing computer instructions executable on the processor, the instructions being executed by the processor to implement the steps of the method of any one of claims 1-3. 6.A computer readable storage medium, the computer readable storage medium storing a computer program, the computer program being executed by a processor to implement the steps of the method of any one of claims 1-3.

Citation Information

Patent Citations

  • Real-time image edge detection algorithm

    CN111223050A