Corner detection methods, devices, electronic equipment and storage media
By acquiring 3D corner feature maps during structural reconstruction and performing NMS processing, combined with clustering and intermediate point feature elimination, the problem of difficult adjacent corner detection is solved, improving the accuracy and precision of corner detection.
Patent Information
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2022-12-09
- Publication Date
- 2026-03-06
AI Technical Summary
In structural reconstruction, the detection of adjacent corner points is difficult, resulting in low accuracy of corner point detection results. Existing technologies cannot effectively prevent adjacent corner points from being merged or integrated.
By acquiring 3D corner feature maps and performing NMS processing on each channel dimension, and combining clustering to correct corner data, or by using intermediate point feature maps to eliminate intermediate point features in the corner feature maps, and then performing NMS processing, adjacent corner points are dispersed and errors are avoided.
It improves the accuracy and precision of corner detection, effectively avoids the merging or merging of adjacent corners, and enhances the edge detection accuracy in structural reconstruction.
Smart Images

Figure CN116091760B_ABST
Abstract
Description
Technical Field
[0001] This disclosure relates to a corner detection method, apparatus, electronic device, and storage medium. Background Technology
[0002] Corner detection is a fundamental task in image-based detection tasks. Tasks such as lane line detection, human key point detection, line segment detection, and structural reconstruction, which require the detection of basic semantics of corners to complete the overall work, all include corner detection.
[0003] Currently, corner detection has targeted solutions in various fields. In lane detection, adjacent corners can be regressed to their respective lanes based on the independent nature of each lane. In human keypoint detection, it is known prior to the fact that each human keypoint has five locations, allowing for the design of targeted corner detection models. However, in image-based structural reconstruction, detecting adjacent corners remains challenging.
[0004] Figures 1a-1c An example diagram of corner detection in structural reconstruction is shown. Figure 1a This is a schematic diagram of the actual corner points in the image. Figure 1b This is a schematic diagram of intermediate results from corner detection. Figure 1c This is a schematic diagram of corner points obtained after Non-Maximum Suppression (NMS) processing. (The diagram is presented in the original text.) Figures 1a-1c As can be seen, since the corner detection task uses a Gaussian kernel to amplify the real corners of the structure's edges as a target detection method, after NMS, the corners will be merged into one corner due to their close proximity, causing corner detection deviation and resulting in low accuracy of corner detection results. Summary of the Invention
[0005] To address at least one of the aforementioned technical problems, this disclosure provides a corner detection method, apparatus, electronic device, and storage medium.
[0006] According to a first aspect of this disclosure, a corner detection method is provided, comprising:
[0007] Get the first image;
[0008] A 3D corner feature map of a first image is obtained using a first corner detection model. The 3D corner feature map has two or more channels, and the feature map of each channel dimension contains a corner feature in a predetermined direction, wherein the predetermined direction represents the orientation of the corner along the edge of the structure.
[0009] NMS processing is performed on the feature maps of each channel dimension in the 3D corner feature map to obtain the first corner data of the first image;
[0010] The first corner data is corrected by clustering to obtain the second corner data of the first image.
[0011] In some embodiments, in the 3D corner feature map, the pixel value of a pixel in the feature map of each channel dimension indicates the probability that the pixel belongs to a predetermined corner, and the orientation of the predetermined corner along the edge of the structure is the same as the predetermined direction corresponding to the channel dimension.
[0012] In some embodiments, the predetermined direction includes: a first direction indicating the corner point moving upward along the edge of the structure; a second direction indicating the corner point moving downward along the edge of the structure; a third direction indicating the corner point moving to the left along the edge of the structure; and a fourth direction indicating the corner point moving to the right along the edge of the structure.
[0013] In some embodiments, the first corner data of the first image is corrected by clustering, including: performing clustering processing on the first corner data to obtain one or more clusters, each cluster corresponding to a corner and the number of pixels in each cluster being less than or equal to a first predetermined value; and determining the position information of the corner corresponding to the cluster based on the position information of the pixels in the cluster.
[0014] In some embodiments, the cluster center spacing of different clusters is greater than a second predetermined value.
[0015] In some embodiments, the first corner detection model is trained on a second image, and the labeled data of the second image includes the position and orientation information of the real corner points in the second image, wherein the orientation information of the real corner points indicates the orientation of the real corner points along the edge of the structure.
[0016] According to a second aspect of this disclosure, a corner detection method is provided, comprising:
[0017] Obtain the third image;
[0018] The second corner detection model is used to obtain the first corner feature map and the midpoint feature map of the third image. The pixel value of the pixel in the first corner feature map indicates the probability that the pixel belongs to the corner, and the pixel value of the pixel in the midpoint feature map indicates the probability that the pixel belongs to a predetermined midpoint cluster.
[0019] The intermediate point feature map is used to eliminate the intermediate point feature in the first corner point feature map to obtain the second corner point feature map.
[0020] NMS processing is performed on the second corner feature map to obtain corner data for the third image.
[0021] In some embodiments, the pixel value of the pixel belonging to the predetermined intermediate point cluster in the second corner feature map is less than or equal to a third predetermined value.
[0022] In some embodiments, eliminating the intermediate point features in the first corner feature map using the intermediate point feature map includes: performing pixel-by-pixel subtraction on the first corner feature map and the intermediate point feature map to obtain the second corner feature map.
[0023] In some embodiments, before using the intermediate point feature map to eliminate the intermediate point features in the first corner feature map, the method further includes: preprocessing the intermediate point feature map to enhance the intermediate point features in the intermediate point feature map.
[0024] In some embodiments, preprocessing the intermediate point feature map to enhance the intermediate point features in the intermediate point feature map includes: adjusting the pixel values of each pixel in the intermediate point feature map whose pixel value is greater than a fourth predetermined value to a predetermined maximum value; and / or adjusting the pixel values of each pixel in the intermediate point feature map whose pixel value is less than or equal to the fourth predetermined value to a predetermined minimum value.
[0025] In some embodiments, the predetermined intermediate point cluster conforms to a non-standard normal distribution, the major axis of the predetermined intermediate point cluster is perpendicular to the line segment of the structural edge, the minor axis of the predetermined intermediate point cluster lies on the line segment of the structural edge, the center of the predetermined intermediate point cluster is a predetermined intermediate point of the line segment of the structural edge, and the distance between the endpoint of the minor axis of the predetermined intermediate point cluster and its adjacent corner point is greater than a fifth predetermined value.
[0026] In some embodiments, the second corner detection model is trained on a fourth image, the labeled data of which includes the location information of the true midpoint cluster and the location information of the true corner points.
[0027] According to a third aspect of this disclosure, a corner detection device is provided, comprising:
[0028] The first acquisition unit is used to acquire the first image;
[0029] The first corner detection unit is used to obtain a 3D corner feature map of the first image using a first corner detection model. The 3D corner feature map has two or more channels, and the feature map of each channel dimension contains a corner feature in a predetermined direction. The predetermined direction indicates the orientation of the corner along the edge of the structure.
[0030] The first NMS processing unit is used to perform NMS processing on the feature maps of each channel dimension in the 3D corner feature map to obtain the first corner data of the first image.
[0031] The data correction unit is used to correct the first corner point data through clustering to obtain the second corner point data of the first image.
[0032] In some embodiments, in the 3D corner feature map, the pixel value of a pixel in the feature map of each channel dimension indicates the probability that the pixel belongs to a predetermined corner, and the orientation of the predetermined corner along the edge of the structure is the same as the predetermined direction corresponding to the channel dimension.
[0033] In some embodiments, the predetermined direction includes: a first direction indicating the corner point moving upward along the edge of the structure; a second direction indicating the corner point moving downward along the edge of the structure; a third direction indicating the corner point moving to the left along the edge of the structure; and a fourth direction indicating the corner point moving to the right along the edge of the structure.
[0034] In some embodiments, the data correction unit is configured to: perform clustering processing on the first corner data to obtain one or more clusters, each cluster corresponding to a corner and the number of pixels in each cluster being less than or equal to a first predetermined value; and determine the position information of the corner corresponding to the cluster based on the position information of the pixels in the cluster.
[0035] In some embodiments, the first corner detection model is trained on a second image, and the labeled data of the second image includes the position and orientation information of the real corner points in the second image, wherein the orientation information of the real corner points indicates the orientation of the real corner points along the edge of the structure.
[0036] According to a fourth aspect of this disclosure, a corner detection device is provided, comprising:
[0037] The second acquisition unit is used to acquire the third image;
[0038] The second corner detection unit is used to obtain a first corner feature map and a midpoint feature map of the third image using a second corner detection model. The pixel value of a pixel in the first corner feature map indicates the probability that the pixel belongs to a corner, and the pixel value of a pixel in the midpoint feature map indicates the probability that the pixel belongs to a predetermined midpoint cluster.
[0039] An elimination unit is used to eliminate the midpoint features in the first corner feature map using the midpoint feature map to obtain a second corner feature map.
[0040] The second NMS processing unit performs NMS processing on the second corner feature map to obtain corner data of the third image.
[0041] In some embodiments, the pixel value of the pixel belonging to the predetermined intermediate point cluster in the second corner feature map is less than or equal to a third predetermined value.
[0042] In some embodiments, the elimination unit is specifically used to: perform pixel-by-pixel subtraction on the first corner feature map and the midpoint feature map to obtain the second corner feature map.
[0043] In some embodiments, the elimination unit is further configured to preprocess the intermediate point feature map to enhance the intermediate point features in the intermediate point feature map before eliminating the intermediate point features in the first corner feature map using the intermediate point feature map.
[0044] In some embodiments, the elimination unit is configured to: adjust the pixel values of each pixel in the intermediate point feature map whose pixel value is greater than a fourth predetermined value to a predetermined maximum value; and / or adjust the pixel values of each pixel in the intermediate point feature map whose pixel value is less than or equal to the fourth predetermined value to a predetermined minimum value.
[0045] In some embodiments, the predetermined intermediate point cluster conforms to a non-standard normal distribution, the major axis of the predetermined intermediate point cluster is perpendicular to the line segment of the structural edge, the minor axis of the predetermined intermediate point cluster lies on the line segment of the structural edge, the center of the predetermined intermediate point cluster is a predetermined intermediate point of the line segment of the structural edge, and the distance between the endpoint of the minor axis of the predetermined intermediate point cluster and its adjacent corner point is greater than a fifth predetermined value.
[0046] In some embodiments, the second corner detection model is trained on a fourth image, the labeled data of which includes the location information of the true midpoint cluster and the location information of the true corner points.
[0047] According to a fifth aspect of this disclosure, an electronic device is provided, comprising:
[0048] Memory, the memory storing execution instructions; and
[0049] A processor that executes the execution instructions stored in the memory, causing the processor to perform the corner detection method of the first aspect and / or the corner detection method of the second aspect described above.
[0050] According to a sixth aspect of this disclosure, a readable storage medium is provided, wherein executable instructions are stored therein, which, when executed by a processor, are used to implement the corner detection method of the first aspect and / or the corner detection method of the second aspect described above.
[0051] According to the seventh aspect of this disclosure, a computer program product is provided, including a computer program / instructions that, when executed by a processor, implement the corner detection method of the first aspect and / or the corner detection method of the second aspect described above.
[0052] The embodiments disclosed herein can effectively avoid the merging or merging of adjacent corner points without changing the NMS algorithm, thereby improving the accuracy and precision of corner point detection. Attached Figure Description
[0053] The accompanying drawings illustrate exemplary embodiments of the present disclosure and, together with the description thereof, serve to explain the principles of the present disclosure. These drawings are included to provide a further understanding of the present disclosure and are incorporated in and constitute a part of this specification.
[0054] Figure 1a This is an example image of the actual corner points in the image;
[0055] Figure 1b It corresponds Figure 1a A schematic diagram of corner points predicted by a corner detection algorithm;
[0056] Figure 1c It corresponds Figure 1a A schematic diagram of the corner points after NMS processing.
[0057] Figure 2 This is a schematic flowchart of a corner detection method according to one embodiment of the present disclosure.
[0058] Figures 3a-3d This is an example diagram of a 3D corner feature map on four channels according to one embodiment of the present disclosure.
[0059] Figure 4 This is an example diagram of corner detection results according to one embodiment of the present disclosure.
[0060] Figure 5 This is a schematic flowchart of a corner detection method according to another embodiment of the present disclosure.
[0061] Figure 6 This is an example diagram of a first corner feature map according to another embodiment of the present disclosure.
[0062] Figure 7 This is an example diagram of an intermediate point feature map according to another embodiment of the present disclosure.
[0063] Figure 8 This is an example diagram of a second corner feature map according to another embodiment of the present disclosure.
[0064] Figure 9 This is an example corner image obtained by performing NMS processing on a second corner feature map according to another embodiment of this disclosure.
[0065] Figure 10 This is an example corner image obtained by directly performing NMS processing on the first corner feature map according to another embodiment of this disclosure.
[0066] Figure 11 This is a schematic block diagram of a corner detection device implemented using a hardware processing system according to one embodiment of the present disclosure.
[0067] Figure 12 This is a schematic block diagram of a corner detection device implemented in hardware using a processing system, according to another embodiment of this disclosure. Detailed Implementation
[0068] The present disclosure will now be described in further detail with reference to the accompanying drawings and embodiments. It should be understood that the specific embodiments described herein are for illustrative purposes only and are not intended to limit the scope of the disclosure. Furthermore, it should be noted that, for ease of description, only the parts relevant to the present disclosure are shown in the accompanying drawings.
[0069] It should be noted that, where there is no conflict, the embodiments and features described in this disclosure can be combined with each other. The technical solutions of this disclosure will now be described in detail with reference to the accompanying drawings and embodiments.
[0070] Unless otherwise stated, the exemplary implementations / embodiments shown are to be understood as providing exemplary features of various details that provide ways in which the technical concepts of this disclosure can be implemented in practice. Therefore, unless otherwise stated, the features of various implementations / embodiments may be additionally combined, separated, interchanged and / or rearranged without departing from the technical concepts of this disclosure.
[0071] The use of crosshairs and / or shading in the accompanying drawings is generally used to clarify the boundaries between adjacent components. Thus, unless otherwise stated, the presence or absence of crosshairs or shading does not convey or indicate any preference or requirement for the specific material, material properties, dimensions, proportions, commonalities between the illustrated components, or any other characteristics, properties, etc., of the components. Furthermore, in the accompanying drawings, the dimensions and relative dimensions of components may be exaggerated for clarity and / or descriptive purposes. When exemplary embodiments can be implemented differently, a specific process sequence may be performed in a different order than that described. For example, two consecutively described processes may be performed substantially simultaneously or in the reverse order of their description. Furthermore, the same reference numerals denote the same components.
[0072] When a component is referred to as being "on" or "above" another component, "connected to," or "joined to" another component, the component may be directly on, directly connected to, or directly joined to the other component, or there may be intermediate components. However, when a component is referred to as being "directly on" another component, "directly connected to," or "directly joined to" another component, there are no intermediate components. Therefore, the term "connection" can refer to a physical connection, an electrical connection, etc., and may or may not have intermediate components.
[0073] The terminology used herein is for the purpose of describing particular embodiments and is not intended to be limiting. As used herein, unless the context clearly indicates otherwise, the singular forms “a” and “the” are intended to include the plural forms as well. Furthermore, when the terms “comprising” and / or “including” and variations thereof are used in this specification, it indicates the presence of the stated features, integrals, steps, operations, parts, components, and / or groups thereof, but does not exclude the presence or addition of one or more other features, integrals, steps, operations, parts, components, and / or groups thereof. It should also be noted that, as used herein, the terms “substantially,” “about,” and other similar terms are used as approximate terms rather than as terms of degree, thus explaining the inherent biases in measurements, calculated values, and / or provided values that would be recognized by one of ordinary skill in the art.
[0074] Figure 2 A flowchart illustrating some embodiments of the corner detection method of this disclosure is shown. For example... Figure 2 As shown, in one embodiment of this disclosure, the corner detection method may include the following steps S202 to S208.
[0075] Step S202: Obtain the first image;
[0076] Step S204: Obtain the 3D corner feature map of the first image using the first corner detection model;
[0077] The 3D corner feature map has two or more channels, and each channel dimension represents the orientation information of a predetermined direction, which represents the orientation of the corner point along the edge of the structure.
[0078] In the 3D corner feature map, each channel dimension contains an angular feature in a predetermined direction. Specifically, in the 3D corner feature map, the pixel value of a pixel in each channel dimension indicates the probability that the pixel belongs to a predetermined corner, and the orientation of the predetermined corner along the edge of the structure is the same as the predetermined direction corresponding to that channel dimension.
[0079] In some implementations, the predetermined direction may include, but is not limited to, the following four: 1) a first direction representing the corner point pointing upwards along the structural edge; 2) a second direction representing the corner point pointing downwards along the structural edge; 3) a third direction representing the corner point pointing to the left along the structural edge; and 4) a fourth direction representing the corner point pointing to the right along the structural edge. These four directions not only separate adjacent corner points on the same horizontal line in the first image into different channels, but also adjacent corner points on the same vertical line into different channels, thereby dispersing all adjacent corner points in the first image across different channels of the 3D corner feature map based on the direction of the corner points along the structural edge.
[0080] In practical applications, the predetermined direction can be flexibly selected according to requirements. For example, the predetermined direction may include upward, downward, upper left, lower left, upper right, lower right, etc. As another example, the predetermined direction may include upward and downward. Yet another example is that the predetermined direction may include left and right. This disclosure does not limit the specific selection of the predetermined direction.
[0081] In some implementations, the 3D corner feature map may have, but is not limited to, four channels, each corresponding to one of the predetermined directions described above. That is, the 3D corner feature map may have a first channel corresponding to a first direction, a second channel corresponding to a second direction, a third channel corresponding to a third direction, and a fourth channel corresponding to a fourth direction.
[0082] The 2D feature map on the first channel of the 3D corner feature map contains corner features pointing upwards along the edge of the structure. That is, the pixel value of each pixel in the 2D feature map indicates the probability that the pixel belongs to a corner pointing upwards along the edge of the structure.
[0083] The 2D feature map on the second channel of the 3D corner feature map contains corner features pointing downwards along the edge of the structure. That is, the pixel value of each pixel in the 2D feature map indicates the probability that the pixel belongs to a corner pointing downwards along the edge of the structure.
[0084] The 2D feature map on the third channel of the 3D corner feature map contains corner features along the left side of the structure edge. That is, the pixel value of each pixel in the 2D feature map indicates the probability that the pixel belongs to the corner along the left side of the structure edge.
[0085] The 2D feature map on the fourth channel of the 3D corner feature map contains corner features along the right edge of the structure. That is, the pixel value of each pixel in the 2D feature map indicates the probability that the pixel belongs to the right corner along the right edge of the structure.
[0086] Figures 3a-3d An example diagram of the feature map for each channel when the 3D corner feature map has four channels is shown. Figures 3a-3d The dark dots in the image represent the corner points initially determined by the first corner point detection model.
[0087] Figure 3a In the example, the structural edge segment to which the corner point belongs is located to the right of the corner point, that is, the corner point is on the left side of the structural edge segment along the structural edge, and its corresponding predetermined direction is the aforementioned third direction. This 2D feature map contains corner point feature data along the structural edge to the left, that is, the pixel value of each pixel in this 2D feature map indicates the probability that the pixel belongs to a corner point along the structural edge to the left.
[0088] Figure 3bIn the example, the structural edge segment to which the corner point belongs is located to the left of the corner point, that is, the corner point is along the structural edge towards the right of the structural edge segment, and its corresponding predetermined direction is the aforementioned fourth direction. This 2D feature map contains corner point feature data along the structural edge to the right, that is, the pixel value of each pixel in this 2D feature map indicates the probability that the pixel belongs to a corner point along the structural edge to the right.
[0089] Figure 3c In the example, the structural edge segment to which the corner point belongs is located below the corner point, that is, the corner point is along the structural edge towards the upper side of the structural edge segment, and its corresponding predetermined direction is the aforementioned first direction. This 2D feature map contains corner point feature data along the structural edge upwards, that is, the pixel value of each pixel in this 2D feature map indicates the probability that the pixel belongs to a corner point along the structural edge upwards.
[0090] Figure 3d In the example, the structural edge segment to which the corner point belongs is located above the corner point, that is, the corner point is along the structural edge towards the lower side of the structural edge segment, and its corresponding predetermined direction is the aforementioned second direction. This 2D feature map contains corner point feature data along the structural edge downwards, that is, the pixel value of each pixel in this 2D feature map indicates the probability that the pixel belongs to a corner point along the structural edge downwards.
[0091] Step S206: Perform NMS processing on the feature maps of each channel in the 3D corner feature map to obtain the first corner data of the first image.
[0092] Specifically, the corner data obtained by merging the feature maps of each channel in the 3D corner feature map through NMS processing can be used to obtain the first corner data of the first image.
[0093] by Figures 3a-3d For example, we can target them separately. Figure 3a , Figure 3b , Figure 3c and Figure 3d Perform NMS processing to obtain corner data of feature maps in four channels. Merge the corner data of feature maps in these four channels to obtain the first corner data of the first image.
[0094] A single corner point may lie on more than one structural edge segment. Figures 3a-3d For example, each corner point lies on at least two structural edge segments, giving each corner point two or more orientations along the structural edges. For a corner point with two or more orientations along the structural edges, its corresponding pixels are distributed across two or more feature maps. After NMS processing, these feature maps yield two sets of data corresponding to the corner point. Thus, the first corner point data will contain two sets of data for the same corner point; that is, duplicate corner points will exist in the first corner point data.
[0095] Furthermore, due to the limited accuracy of the first corner detection model, it is possible that some corners will be detected incorrectly, resulting in the same corner feature appearing in the feature map of more than one channel. In this case, after NMS processing, the feature maps of each channel may also show a situation where one corner corresponds to two sets of data.
[0096] To avoid potential errors such as duplicate corner points in the first corner point data, after step S106, Figure 2 The corner detection method may further include: step S208, correcting the first corner data of the first image through clustering to obtain the second corner data of the first image. This eliminates errors such as duplicate corners in the first corner data, improving the accuracy and precision of corner detection.
[0097] In some implementations, a hierarchical clustering algorithm can be used in step S208 to correct the first corner data of the first image, thereby obtaining the second corner data of the first image.
[0098] In some implementations, the first corner data includes the position information of each pixel initially identified as a corner. The second corner data includes the position information of the pixels ultimately identified as corners.
[0099] In some implementations, step S208 may include:
[0100] Step a1: Perform clustering processing on the first corner point data to obtain one or more clusters, each cluster corresponding to a corner point and the number of pixels in each cluster being less than or equal to a first predetermined value;
[0101] In some implementations, step a1 may include: calculating the distance between each pixel in the first corner data, and performing clustering processing on the pixels in the first corner data based on the distance between each pixel to form one or more clusters, wherein the distance between the cluster centers of different clusters is greater than a second predetermined value. The distance may be, but is not limited to, Euclidean distance, Manhattan distance, cosine distance, etc.
[0102] In some implementations, the specific value of the second predetermined value can be flexibly set. For example, if the feature map resolution of the 3D corner feature map on each channel is 256... At 256, the second predetermined value can be set to 5 pixels.
[0103] In some implementations, clusters obtained through clustering correspond to corner points, with one cluster corresponding to one corner point. To ensure that the obtained clusters correspond to the corner points, only clusters with a number of pixels less than or equal to a first predetermined value can be retained, while clusters with a number of pixels greater than the first predetermined value can be discarded. For example, if the 3D corner feature map has 256 features in each channel... At 256, the first predetermined value can be 4, 5 or other empirical values.
[0104] Step a2: Determine the position information of the corner points corresponding to the cluster based on the position information of the pixels in the cluster.
[0105] For example, the position information of pixels in a cluster can be represented by the coordinates of the pixel in the pixel coordinate system. Specifically, the position information of each pixel in the cluster can include the horizontal and vertical coordinates of the pixel in the pixel coordinate system.
[0106] In some implementations, step a2 can be performed by using the position information of each pixel in the cluster to calculate the position information of the corner point corresponding to the cluster, for example, by averaging or other similar methods. For example, the average of the x-coordinates of all pixels in the cluster can be used as the x-coordinate of the corner point corresponding to the cluster, and the average of the y-coordinates of all pixels in the cluster can be used as the y-coordinate of the corner point corresponding to the cluster.
[0107] In some implementations, step a2 may further include: filtering the pixels in the cluster before determining the position information of the corner points corresponding to the cluster. For example, deleting pixels in the cluster whose distance from the cluster center (e.g., Euclidean distance) exceeds a predetermined threshold. In this way, the position information of the filtered pixels can be used to calculate the position information of the corner points corresponding to the cluster, thereby reducing computational complexity and improving the accuracy of the corner point position information.
[0108] Figure 4 It shows Figures 3a-3d Example image of corner detection results corresponding to the example. Figure 4 As can be seen, the embodiments of this disclosure Figure 2 The corner detection method shown can effectively avoid the merging or fusion of adjacent corners. Applying the corner detection results to structural reconstruction can further improve the accuracy of edge detection and obtain accurate positioning of structural edge segments in the first image.
[0109] In some implementations, the first corner detection model can be trained on a second image. The labeled data of the second image may include the position and orientation information of the real corner points in the second image, where the orientation information of the real corner points indicates the direction of the real corner points along the edge of the structure. Therefore, the first corner detection model trained on the second image can directly generate the aforementioned 3D corner feature map.
[0110] The specific training method for the first corner detection model is not limited in the embodiments disclosed herein.
[0111] This disclosure embodiment Figure 2The corner detection method shown disperses adjacent corners into different channels of a 3D corner feature map according to semantics (i.e., the orientation of the corners along the structural edge). NMS processing is then performed on the feature maps of different channels separately. Simultaneously, the corner data obtained from the NMS processing is corrected to avoid errors such as duplicate corners. Therefore, the corner detection method described in this embodiment can effectively avoid the merging or merging of adjacent corners without changing the NMS algorithm, while improving the accuracy and precision of corner detection.
[0112] Figure 5 This is a schematic flowchart illustrating another embodiment of the corner detection method of this disclosure. Figure 5 As shown, another embodiment of the corner detection method of this disclosure may include:
[0113] Step S502: Obtain the third image;
[0114] Step S504: Use the second corner detection model to obtain the first corner feature map and the midpoint feature map of the third image;
[0115] The pixel value of a pixel in the first corner feature map indicates the probability that the pixel belongs to a corner point, while the pixel value of a pixel in the middle point feature map indicates the probability that the pixel belongs to a predetermined middle point cluster.
[0116] In some implementations, the predetermined intermediate point cluster conforms to a non-standard normal distribution, the major axis of the predetermined intermediate point cluster is perpendicular to the line segment of the structure edge, the minor axis of the predetermined intermediate point cluster lies on the line segment of the structure edge, the center of the predetermined intermediate point cluster is the predetermined intermediate point of the line segment of the structure edge, and the distance between the endpoint of the minor axis of the predetermined intermediate point cluster and its adjacent corner point is greater than a fifth predetermined value.
[0117] The fifth predetermined value can be slightly greater than or equal to the radius of the Gaussian kernel corresponding to the corner feature, that is, the radius of the circular point cluster representing a single corner feature. By setting the distance between the endpoint of the predetermined intermediate point cluster on the structural edge segment and its neighboring corner points to be greater than the fifth predetermined value, the problem of corner detection accuracy being affected by the overlap between the predetermined intermediate point cluster and the corner feature can be effectively solved.
[0118] For example, the predetermined intermediate point cluster can be an elliptical cluster, that is, the pixel distribution of the predetermined intermediate point cluster is elliptical. The major axis of the ellipse is perpendicular to the line segment of the structural edge, the minor axis of the ellipse lies on the line segment of the structural edge, the center of the ellipse is the predetermined intermediate point of the structural edge line segment, and the distance between the endpoint of the minor axis of the ellipse and its adjacent corner point is greater than a fifth predetermined value. Therefore, the Gaussian kernel commonly used in corner detection can be used to detect intermediate points, facilitating the acquisition of intermediate point feature maps through the corner detection model. Furthermore, in cases where the structural edge line segment is short, it can avoid the overlap between some pixels of the predetermined intermediate point cluster on the structural edge line segment and some pixels of the corner feature map, thus improving the accuracy of corner detection. Simultaneously, by lengthening the portion of the predetermined intermediate point cluster perpendicular to the structural edge line segment, the balance of positive and negative sampling points during the training of the first corner detection model can be ensured, improving the performance of the first corner detection model and increasing the accuracy of the intermediate point feature map.
[0119] In practical applications, the predetermined intermediate point cluster can also adopt other shapes of point clusters. For example, the predetermined intermediate point cluster can adopt a rectangle, trapezoid, etc., with its long side perpendicular to the edge line segment of the structure. The present disclosure does not limit the specific shape of the predetermined intermediate point cluster, that is, the pixel distribution area of the predetermined intermediate point cluster.
[0120] In some implementations, the center of the predetermined intermediate point cluster can be, but is not limited to, a selected intermediate point of the corresponding structural edge segment. This selected intermediate point can be the center point, one-third point, one-quarter point, etc. of the structural edge segment.
[0121] Step S506: Use the intermediate point feature map to eliminate the intermediate point features in the first corner point feature map to obtain the second corner point feature map;
[0122] In the second corner feature map, the pixel value of a pixel belonging to a predetermined intermediate point cluster is less than a third predetermined value. For example, when the pixel value ranges from 0 to 1, the third predetermined value can be, but is not limited to, 0, or a positive value close to 0.
[0123] In some implementations, step S506 may include: performing pixel-by-pixel subtraction on the first corner feature map and the midpoint feature map to obtain the second corner feature map. Thus, the midpoint features of the first corner feature map can be eliminated with low-complexity processing, thereby breaking up adjacent corners in the first corner feature map.
[0124] It should be noted that the elimination in step S506 can also be achieved through other processing methods, such as weighted subtraction, weighted multiplication, etc. This disclosure does not limit the specific implementation method of the elimination in step S506.
[0125] To achieve better elimination results and avoid situations where inaccurate detection of some intermediate points in the intermediate point feature map leads to incomplete elimination of intermediate point features in the first corner point feature map, some embodiments may include, before step S506, preprocessing the intermediate point feature map to enhance the intermediate point features in the intermediate point feature map. In this way, the elimination effect of step S506 can be improved by enhancing the intermediate point features in the intermediate point feature map.
[0126] In some implementations, preprocessing the intermediate point feature map to enhance the intermediate point features in the intermediate point feature map may include: adjusting the pixel values of each pixel in the intermediate point feature map whose pixel value is greater than a fourth predetermined value to a predetermined maximum value; and / or adjusting the pixel values of each pixel in the intermediate point feature map whose pixel value is less than or equal to the fourth predetermined value to a predetermined minimum value.
[0127] For example, when the pixel value ranges from 0 to 1, the fourth predetermined value can be set to values such as 0.5, 0.6, 0.7, etc. The predetermined maximum value can be set to 1, and the predetermined minimum value can be set to 0. After preprocessing, the pixel values of all pixels in the intermediate point feature map whose pixel values are greater than the fourth predetermined value will be adjusted to 1, and the pixel values of all pixels in the intermediate point feature map whose pixel values are less than or equal to the fourth predetermined value will be adjusted to 0. Thus, the pixel values of pixels belonging to the predetermined intermediate point cluster in the intermediate point feature map will be adjusted to 1, and the pixel values of pixels not belonging to the predetermined intermediate point cluster in the intermediate point feature map will be adjusted to 0, thereby enhancing the intermediate point features of the intermediate point feature map while weakening other features in the intermediate point feature map. In this way, when eliminating the intermediate point features in the first corner point feature map in step S506 by means such as subtracting pixel values point by point, not only can the elimination effect be improved, but the weakening of the corner point features in the first corner point feature map can also be avoided.
[0128] In practical applications, intermediate point feature map preprocessing can also be implemented using any other applicable methods.
[0129] Step S508: Perform NMS processing on the second corner feature map to obtain the corner data of the third image.
[0130] The NMS processing procedure in this embodiment is the same as that in related technologies, and will not be described again.
[0131] In some implementations, the second corner detection model can be trained using a fourth image. The labeled data of the fourth image may include the position information of the true midpoint clusters and the position information of the true corner points. In specific applications, the specific training method of the second corner detection model is not limited in this embodiment.
[0132] In some implementations, the location information of the true intermediate point cluster can be determined as follows: determine the structural edge segments, find the selected intermediate points and extension directions of each structural edge segment, give the shape parameters of the elliptical point cluster (e.g., the ratio of the major and minor axes of the ellipse), use tools to determine the elliptical point cluster regions of each structural edge segment, and the pixels in the elliptical point cluster regions of each structural edge segment are the sampling points of each structural edge segment in the intermediate point feature map. The location information of these pixels is the location information of the true intermediate point cluster.
[0133] This disclosure embodiment Figure 5 The corner detection method shown utilizes the intermediate point feature map to eliminate the intermediate point features in the corner feature map, thereby truncating the Gaussian blur of adjacent corner points in the corner feature map. After the Gaussian blur of adjacent corner points in the corner feature map is truncated, NMS processing is performed on the corner feature map, which can suppress adjacent corner points into two corner points. Thus, without changing the NMS algorithm, it can effectively avoid the merging or fusion of adjacent corner points, thereby improving the accuracy and precision of corner detection.
[0134] Figure 6 An example image of the first corner feature map is shown. Figure 7 An example image of the midpoint feature map is shown. Figure 8 An example diagram of the second corner feature map is shown. Figure 6 and Figure 8 In the diagram, filled dots represent corner features. Each filled dot represents a Gaussian blur of a corner, that is, each filled dot represents a feature of a corner. Figure 7 The filled ellipse in the text represents the midpoint feature. Each ellipse represents a predetermined cluster of midpoints of a structural edge segment. The major axis of the ellipse is perpendicular to the structural edge segment, the center of the ellipse is the center point of the structural edge segment, and the minor axis of the ellipse lies on the structural edge segment. Figure 8 In the diagram, the ellipse represents the eliminated midpoint feature. (Through...) Figure 6 and Figure 8 It can be seen that by eliminating the midpoint features between adjacent corner points, the Gaussian blur of adjacent corner points can be truncated.
[0135] Figure 9 It shows the Figure 8 The example corner image shown is obtained by performing NMS processing on the second corner feature map. Figure 10 It shows a direct pair Figure 6 The example image shows a corner point obtained by performing NMS processing on the first corner point feature map shown. Figure 9 All adjacent corner points in the data can be detected, and Figure 10 The adjacent corner points are merged due to NMS processing.
[0136] Figures 11 to 12This is a schematic block diagram of a corner detection device implemented using a hardware processing system according to one embodiment of the present disclosure.
[0137] The apparatus may include corresponding modules that perform one or more steps in the flowchart above. Therefore, each or more steps in the flowchart above can be performed by a corresponding module, and the apparatus may include one or more of these modules. A module may be one or more hardware modules specifically configured to perform a corresponding step, or implemented by a processor configured to perform a corresponding step, or stored in a computer-readable medium for implementation by a processor, or implemented through some combination thereof.
[0138] This hardware architecture can be implemented using a bus architecture. The bus architecture can include any number of interconnect buses and bridges, depending on the specific application and overall design constraints of the hardware. Bus 1300 connects various circuits including one or more processors 1400, memory 1500, and / or hardware modules. Bus 1300 can also connect various other circuits 1600 such as peripherals, voltage regulators, power management circuits, external antennas, etc.
[0139] Bus 1300 can be an Industry Standard Architecture (ISA) bus, a Peripheral Component Interconnect (PCI) bus, or an Extended Industry Standard Component (EISA) bus, etc. Buses can be categorized as address buses, data buses, control buses, etc. For ease of representation, only one connection line is used in this diagram, but this does not imply that there is only one bus or one type of bus.
[0140] Any process or method description in the flowcharts or otherwise herein can be understood as representing a module, segment, or portion of code comprising one or more executable instructions for implementing a particular logical function or process, and the scope of the preferred embodiments of this disclosure includes additional implementations in which functions may be performed not in the order shown or discussed, including substantially simultaneously or in reverse order depending on the functions involved, as will be understood by those skilled in the art to which embodiments of this disclosure pertain. The processor performs the various methods and processes described above. For example, the method embodiments of this disclosure may be implemented as software programs tangibly contained in a machine-readable medium, such as memory. In some embodiments, part or all of the software program may be loaded and / or installed via memory and / or a communication interface. When the software program is loaded into memory and executed by the processor, one or more steps of the methods described above may be performed. Alternatively, in other embodiments, the processor may be configured to perform one of the methods described above by any other suitable means (e.g., by means of firmware).
[0141] The logic and / or steps represented in the flowchart or otherwise described herein may be specifically implemented in any readable storage medium for use by, or in conjunction with, an instruction execution system, apparatus or device (such as a computer-based system, a processor-included system or other system that can fetch and execute instructions from, an instruction execution system, apparatus or device).
[0142] For the purposes of this specification, a "readable storage medium" can be any means capable of containing, storing, communicating, propagating, or transmitting a program for use by or in conjunction with an instruction execution system, apparatus, or device. More specific examples (a non-exhaustive list) of readable storage media include: an electrical connection having one or more wires (electronic device), a portable computer disk drive (magnetic device), random access memory (RAM), read-only memory (ROM), erasable and programmable read-only memory (EPROM or flash memory), fiber optic devices, and portable read-only memory (CDROM). Furthermore, a readable storage medium can even be paper or other suitable media on which a program can be printed, since a program can be obtained electronically, for example, by optically scanning the paper or other medium, followed by editing, interpreting, or otherwise processing as necessary, and then stored in memory.
[0143] It should be understood that various parts of this disclosure can be implemented in hardware, software, or a combination thereof. In the above embodiments, multiple steps or methods can be implemented in software stored in memory and executed by a suitable instruction execution system. For example, if implemented in hardware, as in another embodiment, it can be implemented using any one or a combination of the following techniques known in the art: discrete logic circuits having logic gates for implementing logical functions on data signals, application-specific integrated circuits (ASICs) having suitable combinational logic gates, programmable gate arrays (PGAs), field-programmable gate arrays (FPGAs), etc.
[0144] Those skilled in the art will understand that all or part of the steps of the methods described above can be implemented by a program instructing related hardware. The program can be stored in a readable storage medium, and when executed, the program includes one or a combination of the steps of the method implementation.
[0145] Furthermore, the functional units in the various embodiments of this disclosure can be integrated into a single processing module, or each unit can exist physically separately, or two or more units can be integrated into a single module. The integrated module can be implemented in hardware or as a software functional module. If the integrated module is implemented as a software functional module and sold or used as an independent product, it can also be stored in a readable storage medium. The storage medium can be a read-only memory, a disk, or an optical disk, etc.
[0146] Figure 11 This is a schematic diagram of the corner detection device 1100 according to one embodiment of the present disclosure. Figure 11 As shown, the corner detection device 1100 of this disclosure may include:
[0147] The first acquisition unit 1102 is used to acquire the first image;
[0148] The first corner detection unit 1104 is used to obtain a 3D corner feature map of the first image using a first corner detection model. The 3D corner feature map has two or more channels, and the feature map of each channel dimension contains a corner feature in a predetermined direction. The predetermined direction indicates the orientation of the corner along the edge of the structure.
[0149] The first NMS processing unit 1106 is used to perform NMS processing on the feature maps of each channel dimension in the 3D corner feature map to obtain the first corner data of the first image.
[0150] The data correction unit 1108 is used to correct the first corner data by clustering to obtain the second corner data of the first image.
[0151] In some implementations, in the 3D corner feature map, the pixel value of a pixel in the feature map of each channel dimension indicates the probability that the pixel belongs to a predetermined corner, and the orientation of the predetermined corner along the edge of the structure is the same as the predetermined direction corresponding to the channel dimension.
[0152] In some implementations, the predetermined directions include: a first direction indicating the corner point moving upwards along the edge of the structure; a second direction indicating the corner point moving downwards along the edge of the structure; a third direction indicating the corner point moving to the left along the edge of the structure; and a fourth direction indicating the corner point moving to the right along the edge of the structure.
[0153] In some implementations, the data correction unit 1108 is configured to: perform clustering processing on the first corner data to obtain one or more clusters, each cluster corresponding to a corner and the number of pixels in each cluster being less than or equal to a first predetermined value; and determine the position information of the corner corresponding to the cluster based on the position information of the pixels in the cluster.
[0154] In some implementations, the first corner detection model is trained on a second image. The labeled data of the second image includes the position and orientation information of the real corner points in the second image. The orientation information of the real corner points indicates the orientation of the real corner points along the edge of the structure.
[0155] Figure 12 This is a schematic diagram of the corner detection device 1200 according to one embodiment of the present disclosure. Figure 12 As shown, the corner detection device 1200 of this disclosure may include:
[0156] The second acquisition unit 1202 is used to acquire the third image;
[0157] The second corner detection unit 1204 is used to obtain the first corner feature map and the middle point feature map of the third image using the second corner detection model. The pixel value of the pixel in the first corner feature map indicates the probability that the pixel belongs to the corner, and the pixel value of the pixel in the middle point feature map indicates the probability that the pixel belongs to a predetermined middle point cluster.
[0158] Elimination unit 1206 is used to eliminate the midpoint feature in the first corner feature map using the midpoint feature map to obtain the second corner feature map;
[0159] The second NMS processing unit 1208 performs NMS processing on the second corner feature map to obtain corner data of the third image.
[0160] In some implementations, the pixel value of a pixel belonging to a predetermined intermediate point cluster in the second corner feature map is less than or equal to a third predetermined value.
[0161] In some implementations, the elimination unit 1206 is used to: perform pixel-by-pixel subtraction on the first corner feature map and the midpoint feature map to obtain the second corner feature map.
[0162] In some embodiments, the elimination unit 1206 is further configured to preprocess the intermediate point feature map to enhance the intermediate point features in the intermediate point feature map before eliminating the intermediate point features in the first corner point feature map using the intermediate point feature map.
[0163] In some implementations, the elimination unit 1206 is used to: adjust the pixel values of each pixel in the intermediate point feature map whose pixel value is greater than a fourth predetermined value to a predetermined maximum value; and / or adjust the pixel values of each pixel in the intermediate point feature map whose pixel value is less than or equal to the fourth predetermined value to a predetermined minimum value.
[0164] In some embodiments, the predetermined intermediate point cluster is an elliptical point cluster, the major axis of the elliptical point cluster is perpendicular to the line segment of the structure edge, the minor axis of the elliptical point cluster lies on the line segment of the structure edge, the center of the elliptical point cluster is the predetermined intermediate point of the line segment of the structure edge, and the distance between the endpoint of the minor axis of the elliptical point cluster and its adjacent corner point is greater than a fifth predetermined value.
[0165] In some implementations, the second corner detection model is trained on a fourth image, and the labeled data of the fourth image includes the location information of the true midpoint cluster and the location information of the true corner points.
[0166] This disclosure also provides an electronic device, including: a memory storing execution instructions; and a processor or other hardware module that executes the execution instructions stored in the memory, causing the processor or other hardware module to perform the corner detection method shown in FIG1 above and / or Figure 2 The corner detection method shown.
[0167] This disclosure also provides a readable storage medium storing executable instructions, which, when executed by a processor, are used to implement the corner detection method shown in FIG1 above and / or Figure 2 The corner detection method shown.
[0168] This disclosure also provides a computer program product, including a computer program / instructions, which, when executed by a processor, implement the corner detection method shown in Figure 1 above and / or Figure 2 The corner detection method shown.
[0169] In the description of this specification, the references to terms such as "one embodiment / mode," "some embodiments / modes," "example," "specific example," or "some examples," etc., indicate that a specific feature, structure, material, or characteristic described in connection with that embodiment / mode or example is included in at least one embodiment / mode or example of this application. In this specification, the illustrative expressions of the above terms do not necessarily refer to the same embodiment / mode or example. Furthermore, the specific features, structures, materials, or characteristics described may be combined in any suitable manner in one or more embodiments / modes or examples. Moreover, without contradiction, those skilled in the art can combine and integrate the different embodiments / modes or examples described in this specification, as well as the features of different embodiments / modes or examples.
[0170] Furthermore, the terms "first" and "second" are used for descriptive purposes only and should not be construed as indicating or implying relative importance or implicitly specifying the number of technical features indicated. Thus, a feature defined as "first" or "second" may explicitly or implicitly include at least one of that feature. In the description of this application, "multiple" means at least two, such as two, three, etc., unless otherwise explicitly specified.
[0171] Those skilled in the art should understand that the above embodiments are merely for illustrating the present disclosure and are not intended to limit the scope of the disclosure. Those skilled in the art can make other changes or modifications based on the above disclosure, and these changes or modifications still fall within the scope of the present disclosure.
Claims
1. A corner point detection method characterized by, The method comprises: obtaining a first image; obtaining a 3D corner feature map of the first image by using a first corner detection model, the 3D corner feature map having two or more channels, each channel dimension feature map containing a corner feature of a predetermined direction, the predetermined direction representing the orientation of the corner along the structure edge; performing NMS processing on each channel dimension feature map in the 3D corner feature map to obtain first corner data of the first image; correcting the first corner data by clustering to obtain second corner data of the first image, comprising: clustering the first corner data to obtain one or more clusters, each cluster corresponding to a corner and the number of pixel points in each cluster being less than or equal to a first predetermined value; determining the position information of the corner corresponding to the cluster according to the position information of the pixel points in the cluster; the first corner detection model is obtained by training a second image, and the annotation data of the second image includes the position information and direction information of the real corner in the second image, and the direction information of the real corner represents the orientation of the real corner along the structure edge.
2. The corner point detection method according to claim 1, characterized in that, In the 3D corner feature map, the pixel value of each pixel point in each channel dimension feature map indicates the probability that the pixel point belongs to a predetermined corner, and the orientation of the predetermined corner along the structure edge is the same as the predetermined direction corresponding to the channel dimension.
3. The corner point detection method according to claim 1, characterized in that, The predetermined direction includes: a first direction representing that the corner is upward along the structure edge; a second direction representing that the corner is downward along the structure edge; a third direction representing that the corner is left along the structure edge; a fourth direction representing that the corner is right along the structure edge.
4. The corner point detection method of claim 1, wherein The cluster center distance between different clusters is greater than a second predetermined value.
5. A corner point detection method characterized by, The method comprises: obtaining a third image; obtaining a first corner feature map and an intermediate point feature map of the third image by using a second corner detection model, the pixel value of each pixel point in the first corner feature map indicating the probability that the pixel point belongs to a corner, and the pixel value of each pixel point in the intermediate point feature map indicating the probability that the pixel point belongs to a predetermined intermediate point cluster; eliminating the intermediate point feature in the first corner feature map by using the intermediate point feature map to obtain a second corner feature map, comprising: performing point-by-point pixel value subtraction on the first corner feature map and the intermediate point feature map to obtain the second corner feature map; performing NMS processing on the second corner feature map to obtain corner data of the third image; the second corner detection model is obtained by training a fourth image, and the annotation data of the fourth image includes the position information of the real intermediate point cluster and the position information of the real corner in the fourth image.
6. The corner point detection method according to claim 5, characterized in that, The pixel value of the pixel point belonging to the predetermined intermediate point cluster in the second corner feature map is less than or equal to a third predetermined value.
7. The corner point detection method of claim 5, wherein Before eliminating the intermediate point feature in the first corner feature map by using the intermediate point feature map, the method further comprises: preprocessing the intermediate point feature map to enhance the intermediate point feature in the intermediate point feature map.
8. The corner point detection method of claim 7, wherein, The preprocessing of the intermediate point feature map to enhance the intermediate point feature in the intermediate point feature map comprises: adjusting the pixel value of each pixel point in the intermediate point feature map whose pixel value is greater than a fourth predetermined value to a predetermined maximum value; and / or, Adjust pixel values of each pixel point in the intermediate point feature map whose pixel value is less than or equal to a fourth predetermined value to a predetermined minimum value.
9. The corner point detection method of claim 5, wherein, The predetermined intermediate point cluster conforms to a non-standard normal distribution, a long axis of the predetermined intermediate point cluster is perpendicular to a line segment of the structure edge, a short axis of the predetermined intermediate point cluster is on the line segment of the structure edge, a center of the predetermined intermediate point cluster is a predetermined intermediate point of the structure edge line segment, and distances between end points of the short axis of the predetermined intermediate point cluster and adjacent corner points thereof are greater than a fifth predetermined value.
10. A corner point detection apparatus characterized by comprising: The method comprises: A first acquisition unit is configured to acquire a first image. A first corner point detection unit is configured to acquire a 3D corner point feature map of the first image by using a first corner point detection model, the 3D corner point feature map has two or more channels, each channel dimension feature map contains a corner point feature of a predetermined direction, and the predetermined direction represents the orientation of the corner point along the structure edge. A first NMS processing unit is configured to perform NMS processing on each channel dimension feature map in the 3D corner point feature map to obtain first corner point data of the first image. A data correction unit is configured to correct the first corner point data by clustering to obtain second corner point data of the first image. The data correction unit performs clustering processing on the first corner point data to obtain one or more clusters, each cluster corresponds to a corner point, and the number of pixel points in each cluster is less than or equal to a first predetermined value. The position information of the corner point corresponding to the cluster is determined according to the position information of the pixel points in the cluster. The first corner point detection model is obtained by training a second image, and the annotation data of the second image includes the position information and the direction information of the real corner point in the second image, and the direction information of the real corner point represents the orientation of the real corner point along the structure edge.
11. The corner point detection apparatus according to claim 10, characterized by In the 3D corner point feature map, the pixel value of each pixel point in each channel dimension feature map indicates the probability that the pixel point belongs to a predetermined corner point, and the orientation of the predetermined corner point along the structure edge is the same as the predetermined direction corresponding to the channel dimension.
12. The corner point detection apparatus according to claim 10, characterized by The predetermined direction includes: a first direction representing that the corner point is upward along the structure edge; a second direction representing that the corner point is downward along the structure edge; a third direction representing that the corner point is left along the structure edge; and a fourth direction representing that the corner point is right along the structure edge.
13. A corner point detection apparatus characterized by comprising: The method comprises: A second acquisition unit is configured to acquire a third image. A second corner point detection unit is configured to acquire a first corner point feature map and an intermediate point feature map of the third image by using a second corner point detection model, the pixel value of each pixel point in the first corner point feature map indicates the probability that the pixel point belongs to a corner point, and the pixel value of each pixel point in the intermediate point feature map indicates the probability that the pixel point belongs to a predetermined intermediate point cluster. An elimination unit is configured to eliminate intermediate point features in the first corner point feature map by using the intermediate point feature map to obtain a second corner point feature map. A second NMS processing unit is configured to perform NMS processing on the second corner point feature map to obtain corner point data of the third image. The elimination unit is specifically configured to perform point-by-point pixel value subtraction on the first corner point feature map and the intermediate point feature map to obtain the second corner point feature map. The second corner point detection model is trained by a fourth image, and the annotation data of the fourth image includes position information of a real intermediate point cluster and position information of a real corner point of the fourth image.
14. The corner point detection apparatus according to claim 13, characterized by The pixel value of each pixel point belonging to the predetermined intermediate point cluster in the second corner point feature map is less than or equal to a third predetermined value.
15. The corner point detection apparatus according to claim 13, characterized by The elimination unit is further configured to preprocess the intermediate point feature map to enhance the intermediate point features in the intermediate point feature map before eliminating the intermediate point features in the first corner point feature map by using the intermediate point feature map.
16. The corner point detection apparatus according to claim 15, characterized by The elimination unit is configured to: adjust the pixel value of each pixel point in the intermediate point feature map whose pixel value is greater than a fourth predetermined value to a predetermined maximum value; and / or adjust the pixel value of each pixel point in the intermediate point feature map whose pixel value is less than or equal to the fourth predetermined value to a predetermined minimum value.
17. The corner point detection apparatus according to claim 13, characterized by The predetermined intermediate point cluster conforms to a non-standard normal distribution, a long axis of the predetermined intermediate point cluster is perpendicular to a line segment of a structure edge, a short axis of the predetermined intermediate point cluster is on the line segment of the structure edge, a center of the predetermined intermediate point cluster is a predetermined intermediate point of the line segment of the structure edge, and a distance between an end point of the short axis of the predetermined intermediate point cluster and a neighboring corner point thereof is greater than a fifth predetermined value.
18. An electronic device, comprising: comprise: a memory storing execution instructions; and a processor executing the execution instructions stored in the memory, so that the processor executes the corner point detection method in any one of claims 1 to 4 and / or the corner point detection method in any one of claims 5 to 9.
19. A readable storage medium, characterized by, The readable storage medium stores execution instructions, and the execution instructions are executed by the processor to implement the corner point detection method in any one of claims 1 to 4 and / or the corner point detection method in any one of claims 5 to 9.
20. A computer program product comprising a computer program, characterized in that, The computer program is executed by the processor to implement the corner point detection method in any one of claims 1 to 4 and / or the corner point detection method in any one of claims 5 to 9.
Citation Information
Patent Citations
Corner detection method based on neural network, storage medium and image processing system
CN109118473A
Image processing method and device, computer readable storage medium and computer equipment
CN110163193A