Obstacle recognition methods, devices, electronic equipment, and computer storage media
Patent Information
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2025-07-31
- Publication Date
- 2026-08-14
AI Technical Summary
[0003]现有的障碍物识别方法由于忽略了超声波测距精度随距离衰减的特性,导致远距离检测点误差较大,影响障碍物识别的准确性和鲁棒性
本发明在对超声波传感器在同一时间采集的多个超声波点在同一预设坐标系中的空间点进行聚类时,两个空间点之间的聚类距离是根据两个空间点中每一空间点对应的超声波点的测距距离和回波强度确定的,避免了由于忽略超声波测距精度随距离衰减的特性而导致的远距离检测点误差,提高了识别的准确性和鲁棒性。
Smart Images

Figure CN120820948B_ABST
Abstract
Description
Technical Field
[0001] This invention relates to the field of ultrasonic technology, and more specifically, to an obstacle recognition method, device, electronic device, and computer storage medium. Background Technology
[0002] Currently, ultrasonic sensors are widely used in low-speed autonomous driving, parking assistance systems, and robot navigation to detect nearby obstacles. Existing obstacle recognition methods collect echo distance and signal strength information from multiple ultrasonic sensors and determine the presence of obstacles through simple threshold filtering or geometric projection.
[0003] Existing obstacle recognition methods ignore the characteristic that the accuracy of ultrasonic ranging decreases with distance, resulting in large errors at long-distance detection points, which affects the accuracy and robustness of obstacle recognition. Summary of the Invention
[0004] The present invention aims to provide an obstacle recognition method, device, electronic device, and computer storage medium, which can improve the accuracy of obstacle recognition.
[0005] The embodiments of the present invention can be implemented as follows: In a first aspect, the present invention provides an obstacle recognition method, the method comprising: Acquire multiple spatial points, including corresponding points in the same preset coordinate system of multiple ultrasonic points collected by at least one ultrasonic sensor at the same time. The plurality of spatial points are clustered to obtain at least one cluster, wherein the clustering distance between any two spatial points during the clustering process is determined based on the ranging distance and echo intensity of the ultrasonic point corresponding to each of the two spatial points. Obstacle identification is performed for each of the aforementioned clusters.
[0006] In an optional implementation, the step of clustering the plurality of spatial points to obtain at least one cluster includes: For each spatial point, the distance attenuation factor of the spatial point is determined based on the ranging distance of the ultrasonic point corresponding to the spatial point, and the intensity weighting factor of the spatial point is determined based on the echo intensity of the ultrasonic point corresponding to the spatial point. For any two spatial points among the plurality of spatial points, the clustering distance of the spatial point pair is calculated based on the distance attenuation factor and intensity weighting factor of each spatial point in the spatial point pair. Based on the clustering distance of all spatial point pairs, the plurality of spatial points are clustered to obtain at least one cluster. Two spatial points in any spatial point pair within the same cluster are considered neighbors, and the neighbor relationship is determined based on the clustering distance of the spatial point pairs and the clustering radius of each spatial point in the spatial point pair.
[0007] In an optional implementation, before the step of clustering the plurality of spatial points based on the clustering distance of all pairs of spatial points to obtain the at least one cluster, the following steps are included: For any target spatial point pair among all the spatial pairs, the adjustment radius of each spatial point of the target spatial pair is calculated according to the preset adjustment coefficient and the ranging distance of the ultrasonic point corresponding to each spatial point of the target spatial pair. Calculate the cluster radius of each spatial point of the target spatial pair based on the preset basic cluster radius and the adjustment radius of each spatial point of the target spatial pair; If the clustering distance of the target spatial pair is less than the minimum clustering radius of the spatial points in the target spatial pair, then the two spatial points of the target spatial pair are determined to be neighbors.
[0008] In an optional implementation, the step of obstacle identification for each of the clusters includes: For any target cluster, if the target cluster appears consecutively in spatial points at multiple consecutive times, then obstacle identification is performed on the target cluster based on the geometric distribution characteristics of the spatial points in the target cluster.
[0009] In an optional implementation, the geometric distribution characteristics of the spatial points in the target cluster include the total number of spatial points in the target cluster and the average distance of the measured distances of all spatial points in the target cluster. The step of identifying obstacles in the target cluster based on the geometric distribution characteristics of spatial points in the target cluster includes: If the total number is greater than or equal to the preset number and the average distance is less than the preset working distance, then the target cluster is determined to be an obstacle; otherwise, the target cluster is determined to be a non-obstacle.
[0010] In an optional implementation, after determining that the target cluster is an obstacle, the process includes: Geometric features are extracted from the spatial points of the target cluster, including the length of the bounding box of the target cluster and the density of the spatial points of the target cluster. Echo features are extracted from the echo data of the ultrasonic points corresponding to the spatial points of the target cluster. The echo features include the average echo intensity, the minimum echo distance, and the echo ratio of the first echo to the second echo. If the echo ratio is greater than or equal to a preset ratio, the average echo intensity is greater than a preset intensity, the length is greater than a preset length, the density is greater than a preset density, and the minimum echo distance is less than a preset distance, then the target cluster is determined to be a high obstacle; otherwise, the target cluster is determined to be a low obstacle.
[0011] In an optional implementation, before the step of identifying obstacles in any target cluster based on the geometric distribution characteristics of the spatial points in the target cluster, if the target cluster appears consecutively in spatial points at multiple consecutive times, the method includes: Each cluster is obtained by clustering spatial points at multiple consecutive time points, wherein the multiple consecutive time points include the target time corresponding to the target cluster. For any candidate cluster at any time other than the target time among the plurality of consecutive time moments, if the distance between the centroid of the candidate cluster and the centroid of the target cluster is less than a preset distance, and the difference between the size of the candidate cluster and the size of the target cluster is less than a preset difference, then it is determined that the target cluster appears at the time corresponding to the candidate cluster. If the number of times the target cluster appears is greater than a preset number, and the times the target cluster appears are consecutive, then it is determined that the target cluster appears consecutively in spatial points at multiple consecutive times.
[0012] In an optional implementation, the step of acquiring multiple spatial points includes: Acquire every ultrasonic point collected by at least one ultrasonic sensor at the same time. Calculate the corresponding point of each ultrasonic point in the preset coordinate system; For any target ultrasonic point, if the corresponding point of the target ultrasonic point is located within the target horizontal field of view, then the corresponding point of the target ultrasonic point is taken as the spatial point of the target ultrasonic point, and the target horizontal field of view is the horizontal field of view of the ultrasonic sensor that acquires the target ultrasonic point. Each of the ultrasonic points is used as the target ultrasonic point to obtain the plurality of spatial points.
[0013] In a second aspect, the present invention provides an obstacle recognition device, the device comprising: The acquisition module is used to acquire multiple spatial points, including corresponding points of multiple ultrasonic points collected by at least one ultrasonic sensor at the same time in the same preset coordinate system. A clustering module is used to cluster the multiple spatial points to obtain at least one cluster. The clustering distance between any two spatial points during the clustering process is determined based on the ranging distance and echo intensity of the ultrasonic point corresponding to each of the two spatial points. The identification module is used to identify obstacles for each of the clusters.
[0014] Thirdly, the present invention provides an electronic device including a processor and a memory, the memory being used to store a program, and the processor being used to implement the obstacle recognition method as described in any of the foregoing embodiments when executing the program.
[0015] Fourthly, the present invention provides a computer storage medium having a computer program stored thereon, which, when executed by a processor, implements the obstacle recognition method as described in any of the foregoing embodiments.
[0016] Compared with the prior art, the present invention has the following beneficial effects: When clustering multiple ultrasonic points collected by an ultrasonic sensor at the same time into spatial points in the same preset coordinate system, the clustering distance between two spatial points is determined based on the ranging distance and echo intensity of the ultrasonic point corresponding to each spatial point. This avoids errors in long-distance detection points caused by ignoring the characteristic of ultrasonic ranging accuracy attenuating with distance, and improves the accuracy and robustness of identification. Attached Figure Description
[0017] To more clearly illustrate the technical solutions of the embodiments of the present invention, the accompanying drawings used in the embodiments will be briefly introduced below. It should be understood that the following drawings only show some embodiments of the present invention and should not be regarded as a limitation on the scope. For those skilled in the art, other related drawings can be obtained based on these drawings without creative effort.
[0018] Figure 1 This is a flowchart illustrating the obstacle recognition method provided in this embodiment.
[0019] Figure 2 This is an example diagram illustrating the determination of spatial points using a single radar in this embodiment.
[0020] Figure 3 This is an example diagram illustrating the determination of spatial points using dual radars in this embodiment.
[0021] Figure 4This is a block diagram of the obstacle recognition device provided in this embodiment.
[0022] Figure 5 This is a block diagram of the electronic device provided in this embodiment.
[0023] Icons: 10-Electronic device; 11-Processor; 12-Memory; 13-Bus; 100-Obstacle recognition device; 110-Acquisition module; 120-Clustering module; 130-Recognition module. Detailed Implementation
[0024] To make the objectives, technical solutions, and advantages of the embodiments of the present invention clearer, the technical solutions of the embodiments of the present invention will be clearly and completely described below with reference to the accompanying drawings. Obviously, the described embodiments are only some embodiments of the present invention, and not all embodiments. The components of the embodiments of the present invention described and shown in the accompanying drawings can generally be arranged and designed in various different configurations.
[0025] Therefore, the following detailed description of the embodiments of the invention provided in the accompanying drawings is not intended to limit the scope of the claimed invention, but merely to illustrate selected embodiments of the invention. All other embodiments obtained by those skilled in the art based on the embodiments of the invention without inventive effort are within the scope of protection of the invention.
[0026] It should be noted that similar labels and letters in the following figures indicate similar items. Therefore, once an item is defined in one figure, it does not need to be further defined and explained in subsequent figures.
[0027] In the description of this invention, it should be noted that if terms such as "upper," "lower," "inner," or "outer" are used to indicate the orientation or positional relationship based on the orientation or positional relationship shown in the accompanying drawings, or the orientation or positional relationship in which the product of this invention is usually placed, they are only for the convenience of describing this invention and simplifying the description, and do not indicate or imply that the device or element referred to must have a specific orientation, or be constructed and operated in a specific orientation, and therefore should not be construed as a limitation of this invention.
[0028] Furthermore, the terms "first" and "second" are used only to distinguish descriptions and should not be interpreted as indicating or implying relative importance.
[0029] It should be noted that, where there is no conflict, the features in the embodiments of the present invention can be combined with each other.
[0030] To address the technical problem that existing technologies neglect the attenuation of ultrasonic ranging accuracy with distance, resulting in large errors at long-distance detection points and ultimately affecting the accuracy and robustness of obstacle recognition, this embodiment provides an obstacle recognition method, device, electronic device, and computer storage medium. Its core improvement lies in determining the clustering distance based on the ranging distance and echo intensity of the ultrasonic points corresponding to each spatial point in two spatial points when performing spatial clustering. This improves the rationality of the resulting clusters, ultimately enhancing the accuracy and robustness of obstacle recognition based on these clusters. A detailed description follows.
[0031] Please refer to Figure 1 , Figure 1 This is a flowchart illustrating the obstacle recognition method provided in this embodiment. The method includes the following steps: Step S101: Obtain multiple spatial points, including corresponding points in the same preset coordinate system of multiple ultrasonic points collected by at least one ultrasonic sensor at the same time.
[0032] In this embodiment, a spatial point can be represented by the position of an ultrasonic point, which is the echo of an obstacle reflected by an ultrasonic sensor, within a unified preset coordinate system. Specifically, this representation can be two-dimensional spatial coordinates. The preset coordinate system refers to a global coordinate system defined in the application system, or an absolute coordinate system set based on the ground or other reference systems. For example, the application system includes, but is not limited to, vehicle systems or robot systems. Taking a vehicle system as an example, the preset coordinate system can be a Cartesian coordinate system with the vehicle's center point as the origin. One spatial point corresponds to one ultrasonic point. The ultrasonic sensor also collects the ranging distance and echo intensity of each ultrasonic point. The ranging distance refers to the original detection distance of the ultrasonic point from the sensor to the obstacle, while the echo intensity is the signal amplitude of the echo received by the ultrasonic point, reflecting the signal quality of the ultrasonic point. Generally speaking, the larger the ranging distance, the higher the ranging error; the higher the echo intensity, the more reliable the ultrasonic point.
[0033] In this embodiment, clustering based on the spatial points of multiple ultrasonic points at the same time can avoid erroneous clustering caused by timing errors in the acquisition times of different sensors.
[0034] Step S102: Cluster multiple spatial points to obtain at least one cluster. The clustering distance between any two spatial points is determined based on the ranging distance and echo intensity of the ultrasonic point corresponding to each of the two spatial points.
[0035] In this embodiment, ultrasonic points whose echoes are reflected from the same obstacle are more likely to be grouped into the same cluster, and each cluster represents a potential target. Clustering distance is the basis for determining whether two spatial points should be grouped into the same cluster. To avoid mis-clustering and missed clustering caused by ranging errors, different weights can be assigned to different ranging distances and different echo intensities when calculating the clustering distance. This allows for more lenient clustering of distant points while maintaining high clustering accuracy for nearby points with high signal-to-noise ratios.
[0036] Step S103: Obstacle identification is performed for each cluster.
[0037] In this embodiment, each cluster represents only a potential target, but whether the target is an obstacle needs to be further identified. Specifically, the identification can be based on the distribution characteristics and echo characteristics of spatial points in the cluster.
[0038] The method provided in this embodiment, when clustering multiple ultrasonic points collected by an ultrasonic sensor at the same time into spatial points in the same preset coordinate system, determines the clustering distance between two spatial points based on the ranging distance and echo intensity of the ultrasonic point corresponding to each spatial point. This avoids errors in long-distance detection points caused by ignoring the characteristic of ultrasonic ranging accuracy attenuating with distance, and improves the accuracy and robustness of identification.
[0039] In an optional implementation, since different ultrasonic sensors have different horizontal field of view, each ultrasonic sensor's detection capability only covers a specific range of its horizontal field of view when it is working. To avoid pseudo-clustering from different horizontal field of view but close to each other, and to effectively improve the geometric consistency and physical rationality of the clustering results, this embodiment provides a method for obtaining spatial points: First, acquire each ultrasonic point collected by at least one ultrasonic sensor at the same time. In this embodiment, depending on the needs of the actual application scenario, there can be one or more ultrasonic sensors. Multiple ultrasonic sensors can be distributed in different locations on the vehicle or other mobile platform to cover a wider spatial area and improve the comprehensiveness and accuracy of obstacle recognition.
[0040] It should be noted that in an environment with high noise, in order to avoid the influence of noise data, the raw data collected by the ultrasonic sensor can be preprocessed to screen out the highly reliable ultrasonic points, and then the spatial points can be determined from the screened ultrasonic points. The preprocessing includes, but is not limited to: (1) reasonably filtering the ranging distance of the raw data to exclude abnormal data such as 0 or other over-limit values; (2) screening highly reliable ultrasonic points in combination with the signal-to-noise ratio: the signal-to-noise ratio is calculated from the echo intensity and the background noise level, and the noise can be estimated by sampling in the empty window section when the target echo is not received. For the raw data of any point, the calculation formula for its signal-to-noise ratio is: , where C is a constant. For example, C is taken as 20, Aecho is the echo intensity, and Anoise is the average value of the background noise amplitude. The highly reliable ultrasonic points simultaneously satisfy the following conditions: SNR > 10dB; the ranging distance d is within the effective range. For example, 0.2m < d < 5m, and the echo intensity is greater than the preset threshold. For example, the preset threshold is 50.
[0041] Secondly, calculate the corresponding points of each ultrasonic point in the preset coordinate system; In this embodiment, each ultrasonic point has a local coordinate relative to its所属ultrasonic sensor during acquisition. To achieve the fusion and unified analysis of the data of multiple ultrasonic sensors, these local coordinates need to be converted to a unified preset coordinate system. The conversion process usually depends on the installation position and orientation information of the ultrasonic sensor and is achieved through geometric transformation.
[0042] Thirdly, for any target ultrasonic point, if the corresponding point of the target ultrasonic point is within the target horizontal field of view angle, then the corresponding point of the target ultrasonic point is used as the spatial point of the target ultrasonic, and the target horizontal field of view angle is the horizontal field of view angle of the ultrasonic sensor that采集the target ultrasonic point; Fourthly, each ultrasonic point is taken as the target ultrasonic point one by one to obtain multiple spatial points.
[0043] In this embodiment, in order to more clearly illustrate the method for determining the spatial points, this embodiment takes the ultrasonic sensor as a radar for illustration. Please refer to Figure 2 , Figure 2 is an example diagram for determining spatial points in the case of a single radar provided in this embodiment. Figure 2 In it, point A is the position point where radar A is located, the green arc ADD` is the target horizontal field of view angle, that is, the FOV of radar A, point B is the position point where the obstacle is located, point C is the corresponding point of a certain ultrasonic point in the preset coordinate system, the line segment AC is the measured distance, the line segment AB is the distance between the radar and the obstacle. If point C is within the FOV of radar A, then point C is used as the spatial point and participates in subsequent clustering; otherwise, point C cannot be used as the spatial point.
[0044] Please refer to Figure 3 , Figure 3 This is an example diagram illustrating the determination of spatial points using dual radars provided in this embodiment. Figure 3 In the diagram, points A and F are the locations of radars A and F, respectively. The green arcs ADD` and ABB` represent the target horizontal field of view (FOV) of radars A and F, respectively. Point C is the corresponding point of a certain ultrasonic point in the preset coordinate system. Circle A is a circle with center A and radius equal to the measured distance from A. Circle B is a circle with center B and radius equal to the measured distance from B. Point C is considered a spatial point and participates in subsequent clustering only if it is within the FOV of both radars A and F. Otherwise, point C is not considered a spatial point and does not participate in clustering. Figure 3 If point C is not within the FOV of radar A but within the FOV of radar F, or if point C is neither within the FOV of radar A nor within the FOV of radar F, then point C is not considered a spatial point and does not participate in clustering.
[0045] After obtaining multiple spatial points, in order to reasonably measure the impact of ranging distance and echo intensity on clustering distance, this embodiment provides a clustering implementation method by dynamically adjusting the proximity relationship between spatial points through clustering distance: First, for each spatial point, the distance attenuation factor of the spatial point is determined based on the ranging distance of the ultrasonic point corresponding to the spatial point, and the intensity weighting factor of the spatial point is determined based on the echo intensity of the ultrasonic point corresponding to the spatial point. In this embodiment, the distance attenuation factor is used to reflect the weight of the ranging distance on the calculation of the clustering distance. Generally speaking, the distance attenuation factor increases with the ranging distance. For example, if the ultrasonic point corresponding to a certain spatial point is far away, the spatial correlation between the points is weak, and the point has low correlation with its neighbors during the clustering process, a larger distance attenuation factor is set for it. A larger distance attenuation factor applies a smaller weight to it when calculating the clustering distance, resulting in a smaller calculated clustering distance.
[0046] As a specific implementation method, the distance attenuation factor DF can be calculated using the following formula: Where d is the distance measured. This is an adjustment factor, with a value between 0.2 and 0.5. The larger the value, the more sensitive it is to the influence of the ranging distance; the larger d is, the larger DF is.
[0047] In this embodiment, echo intensity reflects the ability of an obstacle surface to reflect ultrasonic waves. Generally speaking, the greater the echo intensity, the stronger the signal and the more reliable the localization. Therefore, the intensity weighting factor is used to enhance the influence of points with higher echo intensity in the clustering process.
[0048] As a specific implementation method, the intensity weighting factor IF can be calculated using the following formula: ,in, Echo intensity The median of the expected intensity can be determined through experimental data. The intensity weighting factor is used to control the steepness trend and adjust the slope of the formula. The greater the echo intensity, the closer the IF is to 1; the smaller the echo intensity, the closer the IF is to 0. The intensity weighting factor weakens the "proximity" of spatial points participating in clustering.
[0049] Secondly, for any two spatial points among multiple spatial points, the clustering distance of the spatial point pair is calculated based on the distance decay factor and intensity weighting factor of each spatial point in the spatial point pair. In this embodiment, the clustering distance for any pair of spatial points can be calculated using the following formula: ,in, Represents the clustering distance of spatial point pairs. and These are two spatial points in a pair of spatial points. and They are spatial points and spatial coordinates, Representing a spatial point and The Euclidean distance between them and They are spatial points Distance attenuation factor and intensity weighting factor, and They are spatial points The distance attenuation factor and intensity weighting factor are used. The formula shows that, for a given pair of spatial points, if both points have high echo intensity and a relatively short range, their corresponding clustering distance will be relatively small, indicating that they are more likely to belong to the same target.
[0050] Finally, based on the clustering distance of all spatial point pairs, multiple spatial points are clustered to obtain at least one cluster. The two spatial points in any spatial point pair within the same cluster are neighbors. The neighbor relationship is determined based on the clustering distance of the spatial point pairs and the clustering radius of each spatial point in the spatial point pair.
[0051] In this embodiment, neighbor relationship refers to two spatial points that have a strong correlation in spatial distribution and are suitable to be classified into the same cluster.
[0052] It should be noted that existing clustering algorithms can also be used for clustering, except that the clustering distance used is the clustering distance determined by the ranging distance and echo intensity provided in this embodiment. The clustering algorithms include, but are not limited to, DBSCAN (Density-Based Spatial Clustering of Applications with Noise), K-Means, etc.
[0053] In an optional implementation, to reflect the different impacts of varying ultrasonic distances corresponding to different spatial points on the clustering threshold—that is, for spatial points at close range (usually less than 1.5m), the clustering threshold should be more stringent, while for spatial points at distant range (usually greater than 1.5m), the clustering threshold should be appropriately relaxed—this embodiment provides a method for determining neighbor relationships: First, for any target spatial point pair in all spatial pairs, the adjustment radius of each spatial point in the target spatial pair is calculated based on the preset adjustment coefficient and the ranging distance of the ultrasonic point corresponding to each spatial point in the target spatial pair. In this embodiment, the preset adjustment coefficient can be an empirical parameter that matches the performance and environmental interference characteristics of the ultrasonic sensor. It is used to adjust the dynamic range of the clustering radius to adapt to the accuracy requirements of obstacle recognition at different distances. For example, the preset adjustment coefficient is set to 0.05 / m. The adjustment radius changes dynamically with the measurement distance. The smaller the measurement distance, the smaller the clustering radius and the stricter the constraint. Conversely, the larger the clustering radius, the stronger the error tolerance. This allows spatial points that are farther away to have a larger clustering radius, increasing the probability that they will be identified as neighbors during the clustering process, thereby improving the robustness of detecting distant obstacles.
[0054] Secondly, based on the preset basic clustering radius and the adjustment radius of each spatial point of the target spatial pair, the clustering radius of each spatial point of the target spatial pair is calculated; In this embodiment, the preset basic clustering radius is a fixed value set in advance based on the typical detection capability of the ultrasonic sensor and the preset target. For example, the preset basic clustering radius is set to 0.1m.
[0055] In this embodiment, the cluster radius of each spatial point can be calculated using the following formula: ,in, The cluster radius of the spatial points. To preset the basic cluster radius, The preset adjustment coefficient, The distance measured between points in space. The radius is the adjustment radius for the spatial point.
[0056] Finally, if the clustering distance of the target spatial pair is less than the minimum clustering radius of the spatial points in the target spatial pair, then the two spatial points of the target spatial pair are determined to be neighbors.
[0057] In this embodiment, if the target spatial pair includes spatial point 1 and spatial point 2, the clustering radius of spatial point 1 is 0.45m, the clustering radius of spatial point 2 is 0.55m, the minimum of the two is 0.45m, and the clustering distance of the target spatial pair is 0.3m. Since 0.3m is less than 0.45m, spatial point 1 and spatial point 2 are neighbors.
[0058] In an optional implementation, to avoid false detections caused by sudden or short-term targets, this embodiment also provides an implementation method for obstacle recognition using spatial points at multiple consecutive moments: For any target cluster, if the target cluster appears consecutively in spatial points at multiple consecutive times, then obstacle identification is performed on the target cluster based on the geometric distribution characteristics of the spatial points in the target cluster.
[0059] In this embodiment, the ultrasonic sensor continuously acquires ultrasonic data in a time series. Therefore, for multiple consecutive moments, a set of spatial points is obtained at each moment. After clustering the set at each moment, a set of clusters corresponding to that moment is obtained. The set of clusters includes at least one cluster formed by clustering the spatial points at that moment. For the same cluster, if the cluster appears at a predetermined number of moments in multiple moments, and these predetermined number of moments are consecutive, then the cluster is considered not a sudden, short-lived target, but a stable target.
[0060] In this embodiment, geometric distribution features characterize the distribution characteristics of spatial points in their respective clusters, and can reflect the structure and stability of the target cluster from the spatial distribution concentration of spatial points.
[0061] In this embodiment, the method of using spatial points at multiple consecutive moments for obstacle identification can effectively filter out false clusters caused by occasional noise, signal interference, or sensor false detections, while retaining the true obstacle clustering results with persistent characteristics.
[0062] In an optional implementation, to improve the reliability of determining whether target clusters appear consecutively, this embodiment also provides a specific determination method: First, obtain each cluster by clustering spatial points at multiple consecutive time points, where multiple consecutive time points include the target time corresponding to the target cluster. In this embodiment, multiple consecutive moments refer to a set of time points arranged in chronological order, including the target moment corresponding to the target cluster, and several other moments that are adjacent or close to the target moment in time, so as to facilitate dynamic tracking and judgment of the existence status of the target cluster in the time dimension. For example, if the time corresponding to the target cluster is 10:00:00 AM on a certain day, and the ultrasonic sensor collects echo data every 5 seconds, then the consecutive moments can be 9:59:50 AM, 9:59:55 AM, 10:00:00 AM, 10:00:05 AM, 10:00:10 AM, and 10:00:15 AM on the same day.
[0063] Secondly, for any candidate cluster at any time other than the target time in multiple consecutive time periods, if the distance between the centroid of the candidate cluster and the centroid of the target cluster is less than a preset distance, and the difference between the size of the candidate cluster and the size of the target cluster is less than a preset difference, then it is determined that the target cluster appears at the time corresponding to the candidate cluster. In this embodiment, the centroid of a cluster refers to the geometric center of all spatial points in the cluster, representing the approximate location of the cluster in space. It is typically obtained by weighted averaging or arithmetic averaging the coordinates of all spatial points in a preset coordinate system. The size of a cluster refers to the extent of its spatial footprint, usually characterized by calculating the distribution of all spatial points relative to the centroid. In this embodiment, the size of a cluster may include, but is not limited to, one or more combinations of geometric parameters such as the maximum extension length of the cluster in each spatial dimension, the area of the bounding box, and the maximum distance between spatial points. For example, the spatial extent of a cluster can be described using a bounding box approach. This involves determining the maximum and minimum values of all spatial points in the cluster in the x and y directions, constructing a minimum square or rectangle enclosing the cluster, and using the lengths of its sides as the size parameters.
[0064] In this embodiment, by comparing the centroid distance and size difference between the target cluster at the target time and the candidate clusters at other times, it is possible to effectively determine whether the two have spatial structural consistency, thereby identifying clusters that persist in the time dimension. When the distance between the centroids is less than a preset distance and the size difference is less than a preset difference, it is determined that the candidate cluster is highly similar to the target cluster in terms of spatial structure, and thus it is considered that the target cluster still exists at the time corresponding to the candidate cluster.
[0065] Finally, if the number of times the target cluster appears is greater than the preset number, and the times the target cluster appears are consecutive, then it is determined that the target cluster appears consecutively in spatial points at multiple consecutive times.
[0066] In this embodiment, the preset number can be set according to actual needs; for example, the preset number can be set to 3.
[0067] As another specific implementation method for trajectory tracking of target clusters, it can perform trajectory tracking through a historical sliding window mechanism. The specific implementation method is as follows: (1) Assign a unique representation to the clusters generated for spatial points in each frame (each frame corresponds to a time point); (2) Match the current frame cluster with the trajectory of the previous frame: the matching conditions include, but are not limited to: centroid distance < preset distance, and the difference between sizes is less than the preset difference; if the match is successful, update the trajectory and record the frame information; otherwise, generate a new trajectory record.
[0068] (3) Maintain a sliding window for each trajectory (e.g., the most recent 3 to 5 frames). If the cluster appears consecutively, increase the confidence level by stepping up (e.g., +10). If it appears in the current frame but is consecutive in historical frames, decrease the confidence level by stepping down (e.g., -5). If the confidence level is greater than or equal to the set threshold (e.g., 30), then the cluster is considered a stable cluster.
[0069] (4) If the target is not found in 1 to 2 frames, interpolation prediction can be used, that is, the historical position can be used to predict the possible position of the current frame.
[0070] (5) If the number of consecutive missing frames of the target trajectory is greater than the threshold frame (e.g., 3 frames), it is determined that the target corresponding to its cluster has disappeared.
[0071] In an optional implementation, for stable clusters, in order to effectively evaluate the density and spatial distribution concentration of spatial points, this embodiment also provides an implementation method for obstacle recognition of target clusters based on geometric distribution characteristics: If the total number is greater than or equal to the preset number and the average distance is less than the preset working distance, the target cluster is determined to be an obstacle; otherwise, the target cluster is determined to be a non-obstacle.
[0072] In this embodiment, the geometric distribution characteristics of spatial points in the target cluster include the total number of spatial points in the target cluster and the average distance of the measured distance of all spatial points in the target cluster. The total number and the average distance can be used to determine the distribution concentration of spatial points. The higher the distribution concentration, the greater the probability that it is an obstacle.
[0073] In this embodiment, the preset quantity can be set according to the possibility of obstacles reflecting ultrasonic waves in the actual application scenario. The preset working distance can be the effective working distance of the ultrasonic sensor, for example, 5m.
[0074] In an optional implementation, since obstacles of different heights may have different geometric and echo characteristics, after determining that the target cluster is an obstacle, the category of the target cluster can be further determined based on its geometric and echo characteristics. One determination method is as follows: First, geometric features are extracted from the spatial points of the target cluster. These geometric features include the length of the bounding box of the target cluster and the density of the spatial points of the target cluster. In this embodiment, geometric morphological features characterize the spatial structural properties of the target cluster, providing a geometric description of its physical form. The bounding box is the smallest rectangle capable of completely containing all spatial points within the target cluster; its length refers to the extension of the bounding box along a primary direction. This length is typically calculated as the side length of the bounding box in the corresponding direction, reflecting the scale occupied by the obstacle in space. The density of spatial points is the number of spatial points contained per unit area, obtained by dividing the total number of spatial points in the cluster by the area of the bounding box, and is used to characterize the density of the spatial point distribution within the cluster.
[0075] Secondly, echo features are extracted from the echo data of the ultrasonic points corresponding to the spatial points of the target cluster. The echo features include the average echo intensity, the minimum echo distance, and the echo ratio of the first echo to the second echo. In this embodiment, echo characteristics characterize the ultrasonic reflection properties of the target cluster. The average echo intensity is the average of the echo intensities of the ultrasonic points corresponding to all spatial points in the target cluster, reflecting the strength of the surface reflection capability of the object corresponding to the target cluster. The minimum echo distance is defined as the distance with the shortest echo return time among the ultrasonic points corresponding to all spatial points in the target cluster, representing the distance between the point closest to the ultrasonic sensor in the cluster and the sensor. The echo ratio of the first and second echoes is defined as the intensity ratio of the first echo to the second echo at the same ultrasonic point, and this ratio is statistically analyzed at the cluster level to reflect whether the object corresponding to the cluster has multiple reflection characteristics, such as a metallic surface or a multi-layered structure.
[0076] Finally, if the echo ratio is greater than or equal to the preset ratio, the average echo intensity is greater than the preset intensity, the length is greater than the preset length, the density is greater than the preset density, and the minimum echo distance is less than the preset distance, then the target cluster is determined to be a high obstacle; otherwise, the target cluster is determined to be a low obstacle.
[0077] In this embodiment, tall obstacles are generally more likely to have multiple reflections, have higher average echo intensity, more reflection points, higher density, and are more likely to be detected at close range. This judgment method fully considers the salience of the obstacle's geometric shape, the salience of its reflection intensity, and its proximity to the ultrasonic sensor, thereby achieving a fine classification of obstacle height categories.
[0078] In this embodiment, the preset ratio, preset intensity, preset length, preset density, and preset distance can all be set according to the needs of the actual scenario. For example, the preset ratio can be set to 2 times, the preset length to 1m, the preset density to 10, and the preset distance to 50cm.
[0079] As another implementation method, machine learning can be used to convert geometric features and echo features into feature vectors. The feature vectors include, but are not limited to: (1) geometric dimensions: length, width, number of points, area, and ratio of the first and second echoes; (2) density: number of points / area; (3) echo intensity: average echo intensity, maximum echo intensity, and echo intensity variance. The feature vectors are input into a pre-trained obstacle recognition and classification model, and the category of the obstacle is output, namely: high obstacle / low obstacle. For example, high obstacles are walls, cars, people, etc., and low obstacles are limit blocks, closed ground locks, etc.
[0080] To perform the corresponding steps in the above embodiments and various possible implementations, an implementation of the obstacle recognition device 100 is given below. Please refer to... Figure 4 , Figure 4 This is a block diagram of the obstacle recognition device provided in this embodiment. It should be noted that the obstacle recognition device 100 provided by the present invention has the same basic principle and technical effect as the corresponding embodiment described above. For the sake of brevity, this embodiment does not mention or specify these aspects.
[0081] The obstacle recognition device 100 includes an acquisition module 110, a clustering module 120, and a recognition module 130.
[0082] The acquisition module 110 is used to acquire multiple spatial points, including corresponding points in the same preset coordinate system of multiple ultrasonic points collected by at least one ultrasonic sensor at the same time.
[0083] Clustering module 120 is used to cluster multiple spatial points to obtain at least one cluster. The clustering distance between any two spatial points during the clustering process is determined based on the ranging distance and echo intensity of the ultrasonic point corresponding to each of the two spatial points.
[0084] The recognition module 130 is used to identify obstacles for each cluster.
[0085] In an optional implementation, the clustering module 120 is specifically used for: For each spatial point, the distance attenuation factor of the spatial point is determined based on the ranging distance of the ultrasonic point corresponding to the spatial point, and the intensity weighting factor of the spatial point is determined based on the echo intensity of the ultrasonic point corresponding to the spatial point. For any two spatial points among multiple spatial points, the clustering distance of the spatial point pair is calculated based on the distance decay factor and intensity weighting factor of each spatial point in the spatial point pair. Based on the clustering distance of all spatial point pairs, multiple spatial points are clustered to obtain at least one cluster. The two spatial points in any pair of spatial points in the same cluster are neighbors. The neighbor relationship is determined based on the clustering distance of the spatial point pairs and the clustering radius of each spatial point in the pair.
[0086] In an optional implementation, the clustering module 120 is further configured to: For any target spatial point pair in all spatial pairs, calculate the adjustment radius of each spatial point of the target spatial pair based on the preset adjustment coefficient and the ranging distance of the ultrasonic point corresponding to each spatial point of the target spatial pair. Calculate the cluster radius of each spatial point in the target space pair based on the preset basic cluster radius and the adjustment radius of each spatial point in the target space pair; If the clustering distance of the target spatial pair is less than the minimum clustering radius of the spatial points in the target spatial pair, then the two spatial points of the target spatial pair are determined to be neighbors.
[0087] In an optional implementation, the identification module 130 is specifically used for: For any target cluster, if the target cluster appears consecutively in spatial points at multiple consecutive times, then obstacle identification is performed on the target cluster based on the geometric distribution characteristics of the spatial points in the target cluster.
[0088] In an optional implementation, the geometric distribution characteristics of spatial points in the target cluster include the total number of spatial points in the target cluster and the average distance of the measured distances of all spatial points in the target cluster. When the recognition module 130 is used to identify obstacles in the target cluster based on the geometric distribution characteristics of spatial points in the target cluster, it is also specifically used for: If the total number is greater than or equal to the preset number and the average distance is less than the preset working distance, the target cluster is determined to be an obstacle; otherwise, the target cluster is determined to be a non-obstacle.
[0089] In an optional implementation, the identification module 130 is further configured to: Geometric features are extracted from the spatial points of the target cluster, including the length of the bounding box of the target cluster and the density of the spatial points of the target cluster. Echo features are extracted from the echo data of the ultrasonic points corresponding to the spatial points of the target cluster. The echo features include the average echo intensity, the minimum echo distance, and the echo ratio of the first echo to the second echo. If the echo ratio is greater than or equal to the preset ratio, the average echo intensity is greater than the preset intensity, the length is greater than the preset length, the density is greater than the preset density, and the minimum echo distance is less than the preset distance, then the target cluster is determined to be a high obstacle; otherwise, the target cluster is determined to be a low obstacle.
[0090] In an optional implementation, the identification module 130 is further configured to: Each cluster is obtained by clustering spatial points at multiple consecutive time points, where the multiple consecutive time points include the target time corresponding to the target cluster. For any candidate cluster at any time other than the target time in multiple consecutive time periods, if the distance between the centroid of the candidate cluster and the centroid of the target cluster is less than a preset distance, and the difference between the size of the candidate cluster and the size of the target cluster is less than a preset difference, then it is determined that the target cluster appears at the time corresponding to the candidate cluster. If the number of times the target cluster appears is greater than the preset number, and the times the target cluster appears are consecutive, then it is determined that the target cluster appears consecutively in spatial points at multiple consecutive times.
[0091] In an optional implementation, the acquisition module 110 is specifically used for: Acquire every ultrasonic point collected by at least one ultrasonic sensor at the same time. Calculate the corresponding point of each ultrasonic point in the preset coordinate system; For any target ultrasonic point, if the corresponding point of the target ultrasonic point is located within the target horizontal field of view, then the corresponding point of the target ultrasonic point is taken as the spatial point of the target ultrasonic point, and the target horizontal field of view is the horizontal field of view of the ultrasonic sensor that collects the target ultrasonic point. Each ultrasonic point is used as a target ultrasonic point to obtain multiple spatial points.
[0092] This invention also provides a block diagram of an electronic device 10, which implements the obstacle recognition method described in the foregoing embodiments. Please refer to... Figure 5 , Figure 5 This is a block diagram of the electronic device 10 provided in this embodiment. The electronic device 10 includes a processor 11, a memory 12 and a bus 13. The processor 11 and the memory 12 are connected through the bus 13.
[0093] The processor 11 can be an integrated circuit chip with signal processing capabilities. In implementation, each step of the obstacle recognition method described in the above embodiments can be completed by the integrated logic circuitry in the hardware of the processor 11 or by software instructions. The processor 11 can be a general-purpose processor, including a CPU (Central Processing Unit), an NP (Network Processor), etc.; it can also be a DSP (Digital Signal Processor), an ASIC (Application Specific Integrated Circuit), an FPGA (Field Programmable Logic Gate Array), or other programmable logic devices, discrete gate or transistor logic devices, or discrete hardware components.
[0094] The memory 12 is used to store the program for implementing the obstacle recognition method. The program may be a software function module stored in the memory 12 in the form of software or firmware or embedded in the OS (Operating System) of the electronic device 10.
[0095] After receiving the execution instruction, the processor 11 executes the program to implement the obstacle recognition method of the aforementioned embodiment.
[0096] This embodiment provides a computer storage medium storing a computer program that, when executed by a processor, implements the obstacle recognition method as described in the foregoing embodiments.
[0097] In summary, embodiments of the present invention provide an obstacle recognition method, device, electronic device, and computer storage medium. The method includes: acquiring multiple spatial points, including corresponding points in a preset coordinate system of multiple ultrasonic points collected simultaneously by at least one ultrasonic sensor; clustering the multiple spatial points to obtain at least one cluster, wherein the clustering distance between any two spatial points is determined based on the ranging distance and echo intensity of the ultrasonic points corresponding to each of the two spatial points; and performing obstacle recognition on each cluster. Compared with the prior art, this embodiment has at least the following advantages: (1) When multiple ultrasonic points collected by the ultrasonic sensor at the same time are clustered in the same preset coordinate system, the clustering distance between two spatial points is determined based on the ranging distance and echo intensity of the ultrasonic point corresponding to each spatial point in the two spatial points, avoiding the error of the far-distance detection point caused by ignoring the characteristic of ultrasonic ranging accuracy decaying with distance, and improving the accuracy and robustness of identification; (2) Dynamically determining the clustering radius makes the clustering of close-distance points more strict and reduces the false clustering rate, while the clustering of far-distance points is moderately relaxed to ensure the integrity of the target, and the intensity weighting factor controls the participation of the spatial points corresponding to the weaker ultrasonic points in the clustering; (3) High and low obstacles can be distinguished through geometric morphological features and echo features, effectively assisting the obstacle avoidance strategy; (4) Combining the time continuity dimension can effectively track and judge the dynamic behavior of obstacles.
[0098] The above descriptions are merely various embodiments of the present invention, but the scope of protection of the present invention is not limited thereto. Any variations or substitutions that can be easily conceived by those skilled in the art within the technical scope disclosed in the present invention should be included within the scope of protection of the present invention. Therefore, the scope of protection of the present invention should be determined by the scope of the claims.
Claims
1. An obstacle recognition method, characterized in that, The method includes: Acquire multiple spatial points, including corresponding points in the same preset coordinate system of multiple ultrasonic points collected by at least one ultrasonic sensor at the same time. The plurality of spatial points are clustered to obtain at least one cluster, wherein the clustering distance between any two spatial points during the clustering process is determined based on the ranging distance and echo intensity of the ultrasonic point corresponding to each of the two spatial points. Obstacle identification is performed for each of the aforementioned clusters; The step of clustering the plurality of spatial points to obtain at least one cluster includes: For each spatial point, the distance attenuation factor of the spatial point is determined based on the ranging distance of the ultrasonic point corresponding to the spatial point, and the intensity weighting factor of the spatial point is determined based on the echo intensity of the ultrasonic point corresponding to the spatial point. For any two spatial points among the plurality of spatial points, the clustering distance of the spatial point pair is calculated based on the distance attenuation factor and intensity weighting factor of each spatial point in the spatial point pair.
2. The method according to claim 1, characterized in that, The step of clustering the plurality of spatial points to obtain at least one cluster further includes: Based on the clustering distance of all spatial point pairs, the plurality of spatial points are clustered to obtain at least one cluster. Two spatial points in any spatial point pair within the same cluster are considered neighbors, and the neighbor relationship is determined based on the clustering distance of the spatial point pairs and the clustering radius of each spatial point in the spatial point pair.
3. The method according to claim 2, characterized in that, Before the step of clustering the plurality of spatial points based on the clustering distance of all pairs of spatial points to obtain the at least one cluster, the following steps are included: For any target spatial point pair among all the spatial pairs, the adjustment radius of each spatial point of the target spatial pair is calculated according to the preset adjustment coefficient and the ranging distance of the ultrasonic point corresponding to each spatial point of the target spatial pair. Calculate the cluster radius of each spatial point of the target spatial pair based on the preset basic cluster radius and the adjustment radius of each spatial point of the target spatial pair; If the clustering distance of the target spatial pair is less than the minimum clustering radius of the spatial points in the target spatial pair, then the two spatial points of the target spatial pair are determined to be neighbors.
4. The method according to claim 1, characterized in that, The step of obstacle identification for each of the clusters includes: For any target cluster, if the target cluster appears consecutively in spatial points at multiple consecutive times, then obstacle identification is performed on the target cluster based on the geometric distribution characteristics of the spatial points in the target cluster.
5. The method according to claim 4, characterized in that, The geometric distribution characteristics of the spatial points in the target cluster include the total number of spatial points in the target cluster and the average distance of the measured distances of all spatial points in the target cluster; The step of identifying obstacles in the target cluster based on the geometric distribution characteristics of spatial points in the target cluster includes: If the total number is greater than or equal to the preset number and the average distance is less than the preset working distance, then the target cluster is determined to be an obstacle; otherwise, the target cluster is determined to be a non-obstacle.
6. The method according to claim 5, characterized in that, After determining that the target cluster is an obstacle, the process includes: Geometric features are extracted from the spatial points of the target cluster, including the length of the bounding box of the target cluster and the density of the spatial points of the target cluster. Echo features are extracted from the echo data of the ultrasonic points corresponding to the spatial points of the target cluster. The echo features include the average echo intensity, the minimum echo distance, and the echo ratio of the first echo to the second echo. If the echo ratio is greater than or equal to a preset ratio, the average echo intensity is greater than a preset intensity, the length is greater than a preset length, the density is greater than a preset density, and the minimum echo distance is less than a preset distance, then the target cluster is determined to be a high obstacle; otherwise, the target cluster is determined to be a low obstacle.
7. The method according to claim 4, characterized in that, Before the step of identifying obstacles in any target cluster based on the geometric distribution characteristics of the spatial points in the target cluster, if the target cluster appears consecutively in spatial points at multiple consecutive times, the method includes: Each cluster is obtained by clustering spatial points at multiple consecutive time points, wherein the multiple consecutive time points include the target time corresponding to the target cluster. For any candidate cluster at any time other than the target time among the plurality of consecutive time moments, if the distance between the centroid of the candidate cluster and the centroid of the target cluster is less than a preset distance, and the difference between the size of the candidate cluster and the size of the target cluster is less than a preset difference, then it is determined that the target cluster appears at the time corresponding to the candidate cluster. If the number of times the target cluster appears is greater than a preset number, and the times the target cluster appears are consecutive, then it is determined that the target cluster appears consecutively in spatial points at multiple consecutive times.
8. The method according to claim 1, characterized in that, The steps for obtaining multiple spatial points include: Acquire every ultrasonic point collected by at least one ultrasonic sensor at the same time. Calculate the corresponding point of each ultrasonic point in the preset coordinate system; For any target ultrasonic point, if the corresponding point of the target ultrasonic point is located within the target horizontal field of view, then the corresponding point of the target ultrasonic point is taken as the spatial point of the target ultrasonic point, and the target horizontal field of view is the horizontal field of view of the ultrasonic sensor that acquires the target ultrasonic point. Each of the ultrasonic points is used as the target ultrasonic point to obtain the plurality of spatial points.
9. An obstacle recognition device, characterized in that, The device includes: The acquisition module is used to acquire multiple spatial points, including corresponding points of multiple ultrasonic points collected by at least one ultrasonic sensor at the same time in the same preset coordinate system. A clustering module is used to cluster the multiple spatial points to obtain at least one cluster. The clustering distance between any two spatial points during the clustering process is determined based on the ranging distance and echo intensity of the ultrasonic point corresponding to each of the two spatial points. An identification module is used to identify obstacles in each of the clusters. The clustering module is specifically used to: for each spatial point, determine the distance attenuation factor of the spatial point based on the ranging distance of the ultrasonic point corresponding to the spatial point, and determine the intensity weighting factor of the spatial point based on the echo intensity of the ultrasonic point corresponding to the spatial point. For any two spatial points among the plurality of spatial points, the clustering distance of the spatial point pair is calculated based on the distance attenuation factor and intensity weighting factor of each spatial point in the spatial point pair.
10. An electronic device, characterized in that, It includes a processor and a memory, the memory being used to store a program, and the processor being used to implement the obstacle recognition method as described in any one of claims 1-8 when executing the program.
11. A computer storage medium, characterized in that, It stores a computer program that, when executed by a processor, implements the obstacle recognition method as described in any one of claims 1-8.
Citation Information
Patent Citations
3D laser radar detection method based on laser intensity
CN117741694A
Device and method for clustering radar reflection point and electronic apparatus
JP2021034025A