A method, device, and readable storage medium for detecting track obstacles.
By segmenting the detection area from the scene point cloud and fitting the trajectory height change curve, combined with point cloud clustering and grid division, the problem of low obstacle detection accuracy in existing technologies is solved, and efficient obstacle recognition is achieved in low-light environments.
Patent Information
- Application Number
- CN202010663884.4
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2020-07-10
- Publication Date
- 2025-10-31
- Estimated Expiration
- 2040-07-10
AI Technical Summary
In the current technology, the methods for detecting obstacles in front of trains in the rail transit field mainly rely on image deep learning or traditional feature extraction, which are not very effective, especially in low-light scenes where the accuracy is low and it is difficult to effectively detect unknown obstacles.
By segmenting the area to be detected from the collected scene point cloud, fitting the track height change curve, and determining obstacles based on the distance between the candidate point cloud and the track height change curve, the detection accuracy is improved by using point cloud clustering and grid division.
It improves the accuracy and ease of obstacle detection, especially in low-light scenes, effectively identifying obstacles and reducing the impact of light on detection.
Smart Images

Figure CN113989765B_ABST
Abstract
Description
Technical Field
[0001] This application relates to the field of rail transit technology, and in particular to a method, device and readable storage medium for detecting rail obstacles. Background Technology
[0002] During vehicle operation, it is necessary to obtain road information in real time in order to determine a more suitable driving plan. Among these, obstacle detection is a key type of road information. Obstacles often affect vehicle operation, especially in railway transportation, where obstacles on the tracks can greatly affect train speed and even pose a danger to train operation.
[0003] Currently, the main methods for detecting obstacles in front of trains in the rail transit field are to use images and perform detection through deep learning or traditional feature extraction. However, these methods are not very effective for detecting unknown obstacles, and the camera imaging is easily affected by lighting conditions. In low-light environments such as tunnels and parking garages, the results are unstable and the accuracy of obstacle detection is low. Summary of the Invention
[0004] In view of this, the purpose of this application is to provide a method, device and readable storage medium for detecting track obstacles, which uses the track height change curve fitted from the collected point cloud as a reference to directly determine the obstacle based on the distance between the candidate point cloud and the track height change curve, which helps to improve the accuracy and simplicity of obstacle determination.
[0005] This application provides a method for detecting track obstacles, the method comprising:
[0006] The point cloud to be detected within the area to be detected is segmented from the collected scene point cloud;
[0007] Based on the track region indicated in the scene image corresponding to the scene point cloud and the point cloud to be detected, a track height change curve is fitted within the detection region.
[0008] The region to be detected is divided into multiple sub-detection regions according to the determined grid grid.
[0009] Cluster the point cloud to be detected within each sub-detection region to identify multiple candidate point clouds;
[0010] Obstacles are identified based on the distance between each candidate point cloud and the plane containing the corresponding point cloud on the track height change curve.
[0011] Furthermore, the step of segmenting the point cloud to be detected within the detection area from the acquired scene point cloud includes:
[0012] Obtain two pre-defined boundary lines;
[0013] The area enclosed by the two boundary lines is defined as the area to be detected.
[0014] The scene point cloud included in the area to be detected is determined as the point cloud to be detected.
[0015] Furthermore, the step of fitting a track height variation curve within the detection region based on the track region indicated in the scene image corresponding to the scene point cloud and the point cloud to be detected includes:
[0016] Based on the track region indicated in the scene image, determine multiple pixel coordinates corresponding to the track in the pixel coordinate system;
[0017] The multiple pixel coordinates are transformed into the radar coordinate system to determine multiple radar coordinates;
[0018] The point cloud to be detected located at the position indicated by the radar coordinates is identified as the orbital point cloud;
[0019] Based on the identified multiple orbital point clouds, an orbital height variation curve is fitted within the region to be detected.
[0020] Furthermore, the step of fitting an orbital height variation curve within the detection region based on the determined multiple orbital point clouds includes:
[0021] The track region is divided into segments according to a preset distance interval to determine multiple sub-fitting regions;
[0022] For each sub-fitting region, the height curve of the track to be stitched is fitted based on at least one track point cloud included in each sub-fitting region;
[0023] The track height curves to be spliced within each sub-fitting region are combined to fit the track height variation curve.
[0024] Furthermore, the step of stitching together the track height curves to be stitched within each sub-fitting region to fit the track height variation curve includes:
[0025] Each sub-fit region is sorted according to the scanning direction of the acquisition device when acquiring the point cloud of the scene;
[0026] Correct the height curve of the track to be spliced in the sub-fitting region that is ranked behind by the height curve of the track to be spliced in the sub-fitting region that is ranked ahead.
[0027] According to the arrangement order of each sub-fitting region, the corrected height curves of multiple tracks to be spliced are stitched together.
[0028] The resulting track change curve after splicing is determined as the track height change curve.
[0029] Furthermore, for each sub-fitting region, fitting the height curve of the track to be stitched based on at least one track point cloud included in each sub-fitting region includes:
[0030] Based on the slope height change within the sub-fitting region, fit the track slope change curve within the sub-fitting region;
[0031] Based on the track slope change curve, track point clouds that are not on the track slope change curve are identified as abnormal point clouds, and multiple identified abnormal point clouds are filtered out from the track point clouds in the sub-fitting region.
[0032] Connect multiple orbit point clouds within the sub-fitting region after filtering out abnormal point clouds to fit the resulting orbit height curve to be stitched together.
[0033] Furthermore, multiple dividing grids are determined through the following steps:
[0034] Determine the density variation trend information of the point cloud to be detected in the region to be detected along the extension direction of the orbital region;
[0035] Based on the density change trend information of the point cloud to be detected, the length of each grid cell is determined;
[0036] Multiple grids are obtained based on the length of each grid and the preset grid width.
[0037] Furthermore, the process of determining obstacles based on the distance between each candidate point cloud and the plane containing the corresponding orbital point cloud on the orbital height change curve includes:
[0038] Determine the standard distance between the location of each candidate point cloud and the plane containing the corresponding orbit point cloud on the orbital height change curve;
[0039] Candidate point clouds whose distance from the plane containing the corresponding orbit point cloud on the orbital height change curve is greater than the corresponding standard distance are identified as obstacles.
[0040] Furthermore, after determining the obstacle based on the distance between each candidate point cloud and the plane containing the corresponding orbital point cloud on the orbital height change curve, the detection method further includes:
[0041] The obstacle is labeled, and its attribute information is labeled at a preset location.
[0042] This application embodiment also provides a track obstacle detection device, the detection device comprising:
[0043] The region segmentation module is used to segment the point cloud to be detected within the region to be detected from the acquired scene point cloud;
[0044] The curve fitting module is used to fit a curve of track height change within the detection area based on the track region indicated in the scene image corresponding to the scene point cloud and the point cloud to be detected.
[0045] The grid division module is used to divide the area to be detected into multiple sub-detection areas according to the determined grid division.
[0046] The point cloud clustering module is used to cluster the point clouds to be detected in each sub-detection region and identify multiple candidate point clouds;
[0047] The obstacle determination module is used to determine obstacles based on the distance between each candidate point cloud and the plane containing the corresponding track point cloud on the track height change curve.
[0048] Furthermore, when the region segmentation module is used to segment the point cloud to be detected within the region to be detected from the acquired scene point cloud, the region segmentation module is used to:
[0049] Obtain two pre-defined boundary lines;
[0050] The area enclosed by the two boundary lines is defined as the area to be detected.
[0051] The scene point cloud included in the area to be detected is determined as the point cloud to be detected.
[0052] Furthermore, when the curve fitting module fits a track height change curve within the detection region based on the track region indicated in the scene image corresponding to the scene point cloud and the point cloud to be detected, the curve fitting module is used to:
[0053] Based on the track region indicated in the scene image, determine multiple pixel coordinates corresponding to the track in the pixel coordinate system;
[0054] The multiple pixel coordinates are transformed into the radar coordinate system to determine multiple radar coordinates;
[0055] The point cloud to be detected located at the position indicated by the radar coordinates is identified as the orbital point cloud;
[0056] Based on the identified multiple orbital point clouds, an orbital height variation curve is fitted within the region to be detected.
[0057] Furthermore, when the curve fitting module is used to fit an orbital height variation curve within the detection region based on multiple determined orbital point clouds, the curve fitting module is used to:
[0058] The track region is divided into segments according to a preset distance interval to determine multiple sub-fitting regions;
[0059] For each sub-fitting region, the height curve of the track to be stitched is fitted based on at least one track point cloud included in each sub-fitting region;
[0060] The track height curves to be spliced within each sub-fitting region are combined to fit the track height variation curve.
[0061] Furthermore, when the curve fitting module is used to stitch together the track height curves to be stitched within each sub-fitting region and fit the track height variation curve, the curve fitting module is used to:
[0062] Each sub-fit region is sorted according to the scanning direction of the acquisition device when acquiring the point cloud of the scene;
[0063] Correct the height curve of the track to be spliced in the sub-fitting region that is ranked behind by the height curve of the track to be spliced in the sub-fitting region that is ranked ahead.
[0064] According to the arrangement order of each sub-fitting region, the corrected height curves of multiple tracks to be spliced are stitched together.
[0065] The resulting track change curve after splicing is determined as the track height change curve.
[0066] Furthermore, when the curve fitting module fits a curve for the height of the track to be stitched based on at least one track point cloud included in each sub-fitting region, the curve fitting module is used to:
[0067] Based on the slope height change within the sub-fitting region, fit the track slope change curve within the sub-fitting region;
[0068] Based on the track slope change curve, track point clouds that are not on the track slope change curve are identified as abnormal point clouds, and multiple identified abnormal point clouds are filtered out from the track point clouds in the sub-fitting region.
[0069] Connect multiple orbit point clouds within the sub-fitting region after filtering out abnormal point clouds to fit the resulting orbit height curve to be stitched together.
[0070] Furthermore, the grid division module is used to determine multiple division grids through the following steps:
[0071] Determine the density variation trend information of the point cloud to be detected in the region to be detected along the extension direction of the orbital region;
[0072] Based on the density change trend information of the point cloud to be detected, the length of each grid cell is determined;
[0073] Multiple grids are obtained based on the length of each grid and the preset grid width.
[0074] Furthermore, when the obstacle determination module determines obstacles based on the distance between each candidate point cloud and the plane containing the corresponding orbital point cloud on the orbital height change curve, the obstacle determination module is used to:
[0075] Determine the standard distance between the location of each candidate point cloud and the plane containing the corresponding orbit point cloud on the orbital height change curve;
[0076] Candidate point clouds whose distance from the plane containing the corresponding orbit point cloud on the orbital height change curve is greater than the corresponding standard distance are identified as obstacles.
[0077] Furthermore, the detection device also includes a labeling module, which is used for:
[0078] The obstacle is labeled, and its attribute information is labeled at a preset location.
[0079] This application also provides an electronic device, including: a processor, a memory, and a bus. The memory stores machine-readable instructions executable by the processor. When the electronic device is running, the processor communicates with the memory via the bus. When the machine-readable instructions are executed by the processor, the steps of the track obstacle detection method described above are performed.
[0080] This application also provides a computer-readable storage medium storing a computer program, which, when executed by a processor, performs the steps of the above-described method for detecting track obstacles.
[0081] The method, apparatus, and readable storage medium for detecting track obstacles provided in this application segment a point cloud to be detected within a detection area from a collected scene point cloud; based on the track region indicated in the scene image corresponding to the scene point cloud and the point cloud to be detected, a track height change curve is fitted within the detection area; the detection area is divided into multiple sub-detection areas according to multiple determined dividing grids; the point cloud to be detected within each sub-detection area is clustered to determine multiple candidate point clouds; and obstacles are determined based on the distance between each candidate point cloud and the plane where the corresponding track point cloud on the track height change curve is located.
[0082] In this way, the point cloud to be detected within the detection area is segmented from the acquired scene point cloud, and the track height change curve is fitted based on the position of the track in the scene image. Based on multiple preset division grids, the detection area is divided into multiple sub-detection areas. Within each sub-detection area, the point cloud to be detected is clustered to determine multiple candidate point clouds. Obstacles are determined based on the distance between each candidate point cloud and the plane where the corresponding track point cloud on the track height change curve is located. This helps to improve the accuracy and simplicity of obstacle determination.
[0083] To make the above-mentioned objectives, features and advantages of this application more apparent and understandable, preferred embodiments are described below in detail with reference to the accompanying drawings. Attached Figure Description
[0084] To more clearly illustrate the technical solutions of the embodiments of this application, 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 this application and should not be regarded as a limitation of the scope. For those skilled in the art, other related drawings can be obtained based on these drawings without creative effort.
[0085] Figure 1 This is a system architecture diagram for a possible application scenario;
[0086] Figure 2 A flowchart illustrating a method for detecting track obstacles provided in an embodiment of this application;
[0087] Figure 3 A flowchart illustrating a method for detecting track obstacles, provided in another embodiment of this application;
[0088] Figure 4 This is one of the structural schematic diagrams of a track obstacle detection device provided in an embodiment of this application;
[0089] Figure 5This is a second schematic diagram of the structure of a track obstacle detection device provided in an embodiment of this application;
[0090] Figure 6 This is a schematic diagram of the structure of an electronic device provided in an embodiment of this application. Detailed Implementation
[0091] To make the objectives, technical solutions, and advantages of the embodiments of this application clearer, the technical solutions of the embodiments of this application will be clearly and completely described below with reference to the accompanying drawings. Obviously, the described embodiments are only some embodiments of this application, and not all embodiments. The components of the embodiments of this application described and shown in the accompanying drawings can generally be arranged and designed in various different configurations. Therefore, the following detailed description of the embodiments of this application provided in the accompanying drawings is not intended to limit the scope of the claimed application, but merely represents selected embodiments of this application. Based on the embodiments of this application, every other embodiment obtained by those skilled in the art without inventive effort falls within the scope of protection of this application.
[0092] First, the applicable scenarios of this application are introduced. This application can be applied to the field of rail transit technology. It segments the point cloud to be detected within a region from the acquired scene point cloud, fits a track height change curve based on the track position in the scene image, and divides the region to be detected into multiple sub-detection regions based on multiple preset grids. Within each sub-detection region, the point cloud to be detected is clustered to determine multiple candidate point clouds. Obstacles are then identified based on the distance between each candidate point cloud and the plane containing the corresponding track point cloud on the track height change curve. This helps improve the accuracy and simplicity of obstacle identification. Please refer to [link to relevant documentation]. Figure 1 , Figure 1 Here is a system architecture diagram for a possible application scenario, such as Figure 1 As shown, the system includes a data acquisition device and a detection device. The data acquisition device acquires the scene point cloud in front of the train during the train's operation and transmits the acquired scene point cloud to the detection device. The detection device uses the track height change curve fitted by the acquired scene point cloud as a guideline within the detection area to identify obstacles.
[0093] Research has found that current methods for detecting obstacles in front of trains in the rail transit field mainly rely on images and deep learning or traditional feature extraction. These methods are ineffective for detecting unknown obstacles, and camera imaging is easily affected by lighting conditions. In low-light environments such as tunnels and parking garages, the results are unstable, leading to low accuracy in obstacle detection.
[0094] Based on this, the purpose of this application is to provide a method for detecting track obstacles, which uses the track height change curve fitted from the collected point cloud as a reference to directly determine the obstacle based on the distance between the candidate point cloud and the track height change curve, which helps to improve the accuracy and simplicity of obstacle determination.
[0095] Please see Figure 2 , Figure 2 This is a flowchart illustrating a method for detecting track obstacles provided in an embodiment of this application. Figure 2 As shown in the figure, the method for detecting track obstacles provided in this application includes:
[0096] S201. Segment the point cloud to be detected within the area to be detected from the collected scene point cloud.
[0097] In this step, the point cloud to be detected within the area to be detected is segmented from the collected point cloud of the current scene.
[0098] Scene point cloud refers to the point cloud of the scene in front of the train during the current train's movement.
[0099] Here, the device for collecting point clouds can be a 3D LiDAR, installed in front of the train's cab, to collect real-time images of the scene in front of the train.
[0100] In this way, by segmenting the area to be detected from the scene point cloud and processing the point cloud within the area to be detected during the candidate process, the amount of subsequent point cloud processing can be effectively reduced, which helps to improve the detection efficiency of track obstacles.
[0101] S202. Based on the track region indicated in the scene image corresponding to the scene point cloud and the point cloud to be detected, fit a track height change curve within the detection region.
[0102] In this step, based on the scene image captured by the camera, the track area indicated in the scene image is aligned with the scene point cloud captured by the radar to determine the track point cloud located within the track area, and the track height change curve is fitted based on the track point cloud.
[0103] Here, while the radar is acquiring scene point clouds, a camera is simultaneously set up on the train to acquire scene images that are identical to those acquired by the radar. The scene images will specifically show the positions of the two tracks where the train is located. The tracks in the scene images are aligned with their positions in the three-dimensional space under the radar coordinate system to determine the track regions in the scene point cloud.
[0104] Here, since the road surface is not always flat when the track is laid, there will be some slope undulations. It is necessary to fit a track height change curve with the slope undulations so that the accuracy of the obstacle can be determined according to the fitted track height change curve.
[0105] S203. Divide the area to be detected into multiple sub-detection areas according to the determined multiple dividing grids.
[0106] In this step, the area to be detected is divided into multiple sub-detection areas according to multiple pre-defined grids of equal width but different lengths.
[0107] Here, the width of each grid is consistent. The length of the grid is determined by the density of the point cloud in the direction of the track extension. In areas with high point cloud density, the grid length is set to be relatively short, and in areas with low point cloud density, the grid length is set to be relatively long. This ensures that the number of point clouds included in each grid is roughly the same, so that when the point clouds are aggregated later, the number of point clouds in each grid is on the same order of magnitude.
[0108] S204. Cluster the point clouds to be detected in each sub-detection region to identify multiple candidate point clouds.
[0109] In this step, the point clouds to be detected included in each sub-detection region divided in step S203 are further clustered according to the corresponding attribute information to determine multiple candidate point clouds.
[0110] Here, clustering is performed using the feature attributes of point clouds, which may include texture, normal vector, color information, Euclidean distance, and point density, etc.
[0111] S205. Based on the distance between each candidate point cloud and the plane containing the corresponding track point cloud on the track height change curve, the obstacle is determined.
[0112] In this step, the distance between each candidate point cloud in step S204 and the plane containing the corresponding point cloud on the track height change curve is determined. Candidate point clouds with a distance greater than the standard distance are identified as obstacle point clouds, thereby identifying obstacles.
[0113] Here, after determining the track height variation curve, the track height will be marked in three-dimensional space. The track height variation curve will be used as a reference line for determining obstacles based on distance differences.
[0114] In the case of track environments, some obstacles may not be located directly above the track, but may be between two rails. In this case, simply using the track height change curve as a reference will no longer be accurate. It is necessary to determine the plane where the point corresponding to the track height change curve is located, and to determine the vertical distance between the obstacle and the track height, so as to determine the distance between the obstacle and the track height plane.
[0115] The method for detecting track obstacles provided in this application involves segmenting a point cloud to be detected from a collected scene point cloud; fitting a track height change curve within the detection area based on the track region indicated in the scene image corresponding to the scene point cloud and the point cloud to be detected; dividing the detection area into multiple sub-detection areas according to a determined grid; clustering the point cloud to be detected within each sub-detection area to determine multiple candidate point clouds; and determining obstacles based on the distance between each candidate point cloud and the plane containing the corresponding track point cloud on the track height change curve.
[0116] In this way, the point cloud to be detected within the detection area is segmented from the acquired scene point cloud, and the track height change curve is fitted based on the position of the track in the scene image. Based on multiple preset division grids, the detection area is divided into multiple sub-detection areas. Within each sub-detection area, the point cloud to be detected is clustered to determine multiple candidate point clouds. Obstacles are determined based on the distance between each candidate point cloud and the plane where the corresponding track point cloud on the track height change curve is located. This helps to improve the accuracy and simplicity of obstacle determination.
[0117] Please see Figure 3 , Figure 3 A flowchart illustrating a method for detecting track obstacles, provided as another embodiment of this application. Figure 3 As shown in the figure, the method for detecting track obstacles provided in this application includes:
[0118] S301. Segment the point cloud to be detected within the area to be detected from the collected scene point cloud.
[0119] S302. Based on the track region indicated in the scene image corresponding to the scene point cloud and the point cloud to be detected, fit a track height change curve within the detection region.
[0120] S303. Divide the area to be detected into multiple sub-detection areas according to the determined multiple dividing grids.
[0121] S304. Cluster the point clouds to be detected in each sub-detection region to identify multiple candidate point clouds.
[0122] S305. Based on the distance between each candidate point cloud and the plane containing the corresponding track point cloud on the track height change curve, the obstacle is determined.
[0123] S306. Mark the obstacle and mark the attribute information of the obstacle at a preset position.
[0124] In this step, after the obstacle is identified in step S305, the location of the obstacle (obstacle point cloud) is marked with different colors in the radar image, and the attribute information of the obstacle is marked at the preset position of the obstacle, so as to indicate the location of the obstacle and alert the train driver.
[0125] Here, after identifying obstacles in the radar image, when marking the location of the obstacles, red (or other colors that can be distinguished from the point cloud) can be used for conspicuous marking. After the clustering has clarified the attribute information of the obstacles, after marking the obstacles, the attribute information of the obstacles is marked at the preset position of the obstacles, which can be around the obstacles (top left corner, bottom right corner, etc.) or on the obstacles themselves.
[0126] The obstacle's attribute information may include the obstacle type, the obstacle's volume, and the obstacle clearing method.
[0127] The descriptions of S301 to S305 can be referred to those of S201 to S205, and the same technical effects can be achieved, so they will not be elaborated further.
[0128] Furthermore, step S301 includes: acquiring two pre-set boundary lines; determining the area enclosed by the two boundary lines as the area to be detected; and determining the scene point cloud included in the area to be detected as the point cloud to be detected.
[0129] In this step, based on the concentrated areas of the point cloud to be detected during the historical processing, two boundary lines are determined. The area enclosed by the two boundary lines is determined as the area to be detected for point cloud detection this time, and the scene point cloud included in the determined area to be detected is determined as the point cloud to be detected.
[0130] Here, in order to reduce the number of subsequent point cloud processing and improve detection efficiency, it is necessary to filter out some scene point clouds that do not need to be processed before processing, and determine the area to be detected in the exit point cloud. Since this embodiment is for detecting track obstacles, the two pre-set boundary lines can be set as the locations of the two tracks on which the train travels, and the middle part of the two tracks and the track surrounded by the two tracks can be determined as the area to be detected.
[0131] The determination of the positions of the two tracks in the scene point cloud can be achieved by acquiring scene images in front of the train with a camera, aligning the multiple pixel coordinates of the tracks in the scene image with radar coordinates, determining the positions of the two tracks in the radar's three-dimensional coordinates, and thus determining the detection area surrounded by the two tracks.
[0132] Here, the two pre-set boundary lines can be either the two tracks on which the train travels, or two pre-set boundary lines outside the two tracks. The reason for this is that objects within a certain distance outside the tracks can also have a certain impact on the train during its operation, and obstacle identification is also required.
[0133] Further, step S302 includes: determining multiple pixel coordinates corresponding to the track in the pixel coordinate system based on the track region indicated in the scene image; transforming the multiple pixel coordinates to the radar coordinate system to determine multiple radar coordinates; determining the point cloud to be detected at the position indicated by the radar coordinates as the track point cloud; and fitting a track height change curve within the detection area based on the determined multiple track point clouds.
[0134] In this step, a camera device is used to capture scene images of the area in front of the train during its operation. Two track regions are identified in the scene images. Multiple pixel coordinates corresponding to the track locations are determined in camera coordinates. These pixel coordinates are then converted to radar coordinates to determine multiple radar coordinates corresponding to the track. The point cloud to be detected at the location indicated by the radar coordinates is identified as the track point cloud. Based on the identified multiple track point clouds, a track height change curve is fitted.
[0135] Here, the exact location of the track cannot be determined very precisely from the point cloud acquired by the radar. It is necessary to determine it by acquiring scene images by the camera. Furthermore, the scene images acquired by the camera should be consistent with the scene acquired by the radar. For example, if the radar acquires the scene point cloud 30 meters in front of the train, then during the scene image acquisition process, the camera's focus needs to be adjusted to acquire scene images 30 meters in front of the train.
[0136] Furthermore, the step of fitting a track height variation curve within the detection area based on the determined multiple track point clouds includes: segmenting the track area according to a preset distance interval to determine multiple sub-fitting areas; for each sub-fitting area, fitting a track height curve to be stitched based on at least one track point cloud included in each sub-fitting area; stitching the track height curves to be stitched in each sub-fitting area to fit the track height variation curve.
[0137] In this step, the track area is divided into segments according to a preset distance interval, and multiple sub-fitting regions are determined on the track. In each sub-fitting region, the height curve of the track to be spliced is fitted according to the track point cloud included in each sub-fitting region. After fitting the height curve of the track to be spliced in each sub-fitting region, the height curves of each track to be spliced are spliced to form the track height change curve corresponding to the entire track.
[0138] Here, the preset distance interval can be determined based on the point cloud included in each sub-fitting region. The preset distance can be equal or unequal. In the process of determining the sub-fitting region, the orbit point cloud included in each sub-fitting region needs to be able to completely fit a trajectory height curve to be spliced.
[0139] Here, when generating the height curve of the track to be spliced, the least squares method can be used to fit the height curve of the track to be spliced based on the slope change of the road surface.
[0140] In the process of fitting the height curve of the track to be stitched together using the track point cloud, the height data represented by the track point cloud is fitted, and the resulting curve is also the track height curve.
[0141] Furthermore, the step of stitching together the trajectory height curves to be stitched within each sub-fitting region to fit the trajectory height variation curve includes: sorting each sub-fitting region according to the scanning direction of the acquisition device when acquiring the scene point cloud; correcting the trajectory height curves to be stitched in the sub-fitting regions to be stitched in the rear based on the trajectory height curves to be stitched in the sub-fitting regions to be stitched in the front position of the sorting; stitching together the corrected multiple trajectory height curves to be stitched in the order of each sub-fitting region; and determining the obtained trajectory variation curve as the trajectory height variation curve.
[0142] In this step, each sub-fitting region is sorted according to the scanning direction of the acquisition device when collecting the scene point cloud, that is, the sub-fitting regions are sorted according to their distance from the acquisition device on the track position. The track height curve to be stitched is corrected by the track height curve to be stitched of the sub-fitting regions that are sorted later, and multiple corrected track height curves are determined. Multiple track height curves to be stitched are stitched together to fit the track height change curve.
[0143] Here, the point cloud data density in the sub-fitting area far from the acquisition device will decrease sharply. The fitted track height curve may have some error with the actual track direction. In this case, it is necessary to use the track height curve in the sub-fitting area with higher point cloud density in front, combined with the ground slope undulation, to determine the approximate direction of the track height curve to be stitched. The determined approximate direction is then used to correct the track height curve behind, and it is even possible to fit the track height change curve in the position that the scanning line of the acquisition device cannot cover.
[0144] This improves the accuracy of track fitting and fully completes the track height in areas not scanned by the laser acquisition device's scanning lines.
[0145] Furthermore, for each sub-fitting region, fitting the track height curve to be stitched based on at least one track point cloud included in each sub-fitting region includes: fitting a track slope change curve in the sub-fitting region according to the slope height change in the sub-fitting region; based on the track slope change curve, identifying track point clouds not on the track slope change curve as abnormal point clouds, and filtering out multiple identified abnormal point clouds from the track point clouds in the sub-fitting region; connecting multiple track point clouds in the sub-fitting region after filtering out abnormal point clouds to fit the track height curve to be stitched.
[0146] In this step, within each sub-fitting region, the track slope change curve within that sub-fitting region is roughly fitted according to the slope height change of the ground. Based on the track slope change curve, the track point clouds within the sub-fitting region that are not on the track slope change curve are identified as abnormal point clouds and filtered out. The remaining track point clouds are then used to fit the track height curve to be stitched together.
[0147] During the point cloud acquisition and sub-fitting region division process, there may be some incorrectly acquired or incorrectly divided point clouds. These point clouds will affect the fitting accuracy of the track height change curve. It is necessary to filter out abnormal point clouds by combining the actual road surface undulation height in order to improve the fitting accuracy of the track height curve to be spliced.
[0148] Furthermore, multiple dividing grids are determined through the following steps: determining the density variation trend information of the point cloud to be detected in the region to be detected along the extension direction of the track region; determining the length of each dividing grid based on the density variation trend information of the point cloud to be detected; and obtaining multiple dividing grids based on the length of each dividing grid and a preset grid width.
[0149] In this step, the density of the distribution of the point cloud to be detected along the extension direction of the train track is determined. Based on the density of the point cloud to be detected and the basic number of points in each grid, the ratio of the length of each grid to the total length is determined, and the length of each grid is determined based on the ratio. The grid width of each grid is consistent. Based on the determined length of each grid and the preset grid width, the grid is determined.
[0150] Here, as the track extends, the scanning lines of the acquisition device will become increasingly unable to completely cover the entire scene, and the point cloud density will gradually decrease as the distance from the acquisition device increases. Therefore, in order to ensure that the number of point clouds contained in each division is roughly the same and the fitting accuracy is roughly similar, it is necessary to appropriately increase the length of the division grid to ensure the number of point clouds in the division grid and the fitting accuracy of the track height change curve.
[0151] Further, step S305 includes: determining the standard distance between the location of each candidate point cloud and the plane where the corresponding orbital point cloud is located on the orbital height change curve; and identifying candidate point clouds whose distance to the plane where the corresponding orbital point cloud is located on the orbital height change curve is greater than the corresponding standard distance as obstacles.
[0152] Here, based on the attribute information of the point cloud and the setting of the track components on the track, the standard distance between the location of each candidate point cloud and the corresponding track point cloud plane on the track height change curve is determined, and candidate point clouds with a distance greater than the determined standard distance are identified as obstacles.
[0153] During the track setup process, some components or markers may protrude above the track itself. These components will not affect the train's operation and will not be considered obstacles. Therefore, in the process of obstacle identification, it is not possible to simply assume that an object higher than the track height is necessarily an obstacle. It is necessary to determine the acceptable object height for each part based on the corresponding attribute information and the track's own setup, so as to more accurately identify obstacles.
[0154] The method for detecting track obstacles provided in this application includes: segmenting a point cloud to be detected from a scene point cloud; fitting a track height change curve within the detection area based on the track region indicated in the scene image corresponding to the scene point cloud and the point cloud to be detected; dividing the detection area into multiple sub-detection areas according to multiple determined dividing grids; clustering the point clouds to be detected within each sub-detection area to determine multiple candidate point clouds; determining obstacles based on the distance between each candidate point cloud and the plane where the corresponding track point cloud is located on the track height change curve; labeling the obstacles and marking the attribute information of the obstacles at preset positions.
[0155] In this way, the point cloud to be detected within the detection area is segmented from the acquired scene point cloud, and the track height change curve is fitted based on the position of the track in the scene image. Based on multiple preset division grids, the detection area is divided into multiple sub-detection areas. Within each sub-detection area, the point cloud to be detected is clustered to determine multiple candidate point clouds. Obstacles are determined based on the distance between each candidate point cloud and the plane where the corresponding track point cloud on the track height change curve is located. The obstacles are then labeled, which helps to improve the accuracy and simplicity of obstacle determination.
[0156] Please see Figure 4 , Figure 5 , Figure 4 This is one of the structural schematic diagrams of a track obstacle detection device provided in the embodiments of this application. Figure 5 This is a second schematic diagram of a track obstacle detection device provided in an embodiment of this application. Figure 4 As shown, the detection device 400 includes:
[0157] The region segmentation module 410 is used to segment the point cloud to be detected within the region to be detected from the acquired scene point cloud.
[0158] The curve fitting module 420 is used to fit a curve of track height change within the detection area based on the track region indicated in the scene image corresponding to the scene point cloud and the point cloud to be detected.
[0159] The grid division module 430 is used to divide the area to be detected into multiple sub-detection areas according to the determined multiple division grids.
[0160] The point cloud clustering module 440 is used to cluster the point clouds to be detected in each sub-detection region to determine multiple candidate point clouds.
[0161] The obstacle determination module 450 is used to determine obstacles based on the distance between each candidate point cloud and the plane containing the corresponding track point cloud on the track height change curve.
[0162] Furthermore, such as Figure 5 As shown, the detection device 400 further includes a labeling module 460, which is used for:
[0163] The obstacle is labeled, and its attribute information is labeled at a preset location.
[0164] Furthermore, when the region segmentation module 410 is used to segment the point cloud to be detected within the region to be detected from the acquired scene point cloud, the region segmentation module 410 is used to:
[0165] Obtain the two pre-defined boundary lines;
[0166] The area enclosed by the two boundary lines is defined as the area to be detected.
[0167] The scene point cloud included in the area to be detected is determined as the point cloud to be detected.
[0168] Furthermore, when the curve fitting module 420 fits a track height change curve within the detection area based on the track region indicated in the scene image corresponding to the scene point cloud and the point cloud to be detected, the curve fitting module 420 is used to:
[0169] Based on the track region indicated in the scene image, determine multiple pixel coordinates corresponding to the track in the pixel coordinate system;
[0170] The multiple pixel coordinates are transformed into the radar coordinate system to determine multiple radar coordinates;
[0171] The point cloud to be detected located at the position indicated by the radar coordinates is identified as the orbital point cloud;
[0172] Based on the identified multiple orbital point clouds, an orbital height variation curve is fitted within the region to be detected.
[0173] Furthermore, when the curve fitting module 420 fits a curve representing the change in orbital height within the detection region based on multiple determined orbital point clouds, the curve fitting module 420 is used to:
[0174] The track region is divided into segments according to a preset distance interval to determine multiple sub-fitting regions;
[0175] For each sub-fitting region, the height curve of the track to be stitched is fitted based on at least one track point cloud included in each sub-fitting region;
[0176] Stitch the to-be-stitched track height curves within each sub-fitting region to fit the track height change curve.
[0177] Furthermore, when the curve fitting module 420 is used to stitch the to-be-stitched track height curves within each sub-fitting region to fit the track height change curve, the curve fitting module 420 is used for:
[0178] Sort each sub-fitting region according to the scanning direction of the acquisition device when collecting the scene point cloud;
[0179] Correct the to-be-stitched track height curve of the sub-fitting region located behind according to the to-be-stitched track height curve of the sub-fitting region located in the front position in the sorting;
[0180] Stitch the corrected multiple to-be-stitched track height curves according to the arrangement order of each sub-fitting region;
[0181] Determine the stitched track change curve as the track height change curve.
[0182] Furthermore, when the curve fitting module 420 is used to fit the to-be-stitched track height curve for each sub-fitting region based on at least one track point cloud included in each sub-fitting region, the curve fitting module 420 is used for:
[0183] Fit the track slope change curve within the sub-fitting region according to the slope height change within the sub-fitting region;
[0184] Based on the track slope change curve, determine the track point clouds not on the track slope change curve as abnormal point clouds, and filter out the determined multiple abnormal point clouds from the track point clouds within the sub-fitting region;
[0185] Connect the multiple track point clouds within the sub-fitting region after filtering out the abnormal point clouds to fit the to-be-stitched track height curve.
[0186] Furthermore, the grid division module 430 is used to determine multiple division grids through the following steps:
[0187] Determine the density change trend information of the to-be-detected point clouds in the extension direction of the track region in the to-be-detected region;
[0188] Based on the density change trend information of the to-be-detected point clouds, determine the length of each division grid;
[0189] Based on the length of each division grid and the preset grid width, obtain multiple division grids.
[0190] Furthermore, when the obstacle determination module 450 determines an obstacle based on the distance between each candidate point cloud and the plane containing the corresponding orbital point cloud on the orbital height change curve, the obstacle determination module 450 is used to:
[0191] Determine the standard distance between the location of each candidate point cloud and the plane containing the corresponding orbit point cloud on the orbital height change curve;
[0192] Candidate point clouds whose distance from the plane containing the corresponding orbit point cloud on the orbital height change curve is greater than the corresponding standard distance are identified as obstacles.
[0193] The track obstacle detection device provided in this application segmentes a point cloud to be detected within a detection area from a collected scene point cloud; based on the track area indicated in the scene image corresponding to the scene point cloud and the point cloud to be detected, a track height change curve is fitted within the detection area; the detection area is divided into multiple sub-detection areas according to multiple determined dividing grids; the point cloud to be detected within each sub-detection area is clustered to determine multiple candidate point clouds; and obstacles are determined based on the distance between each candidate point cloud and the plane where the corresponding track point cloud on the track height change curve is located.
[0194] In this way, the point cloud to be detected within the detection area is segmented from the acquired scene point cloud, and the track height change curve is fitted based on the position of the track in the scene image. Based on multiple preset division grids, the detection area is divided into multiple sub-detection areas. Within each sub-detection area, the point cloud to be detected is clustered to determine multiple candidate point clouds. Obstacles are determined based on the distance between each candidate point cloud and the plane where the corresponding track point cloud on the track height change curve is located. This helps to improve the accuracy and simplicity of obstacle determination.
[0195] Please see Figure 6 , Figure 6 This is a schematic diagram of the structure of an electronic device provided in an embodiment of this application. Figure 6 As shown, the electronic device 600 includes a processor 610, a memory 620, and a bus 630.
[0196] The memory 620 stores machine-readable instructions executable by the processor 610. When the electronic device 600 is running, the processor 610 and the memory 620 communicate via the bus 630. When the machine-readable instructions are executed by the processor 610, they can perform the operations described above. Figure 2 as well as Figure 3 The steps of the obstacle detection method in the illustrated method embodiment can be found in the method embodiment for specific implementation, and will not be repeated here.
[0197] This application also provides a computer-readable storage medium storing a computer program, which, when executed by a processor, can perform the above-described actions. Figure 2 as well as Figure 3 The steps of the obstacle detection method in the illustrated method embodiment can be found in the method embodiment for specific implementation, and will not be repeated here.
[0198] Those skilled in the art will understand that, for the sake of convenience and brevity, the specific working processes of the systems, devices, and units described above can be referred to the corresponding processes in the foregoing method embodiments, and will not be repeated here.
[0199] In the several embodiments provided in this application, it should be understood that the disclosed systems, apparatuses, and methods can be implemented in other ways. The apparatus embodiments described above are merely illustrative. For example, the division of units is only a logical functional division, and in actual implementation, there may be other division methods. Furthermore, multiple units or components may be combined or integrated into another system, or some features may be ignored or not executed. Additionally, the shown or discussed mutual couplings, direct couplings, or communication connections may be through some communication interfaces; indirect couplings or communication connections between devices or units may be electrical, mechanical, or other forms.
[0200] The units described as separate components may or may not be physically separate. The components shown as units may or may not be physical units; that is, they may be located in one place or distributed across multiple network units. Some or all of the units can be selected to achieve the purpose of this embodiment according to actual needs.
[0201] In addition, the functional units in the various embodiments of this application can be integrated into one processing unit, or each unit can exist physically separately, or two or more units can be integrated into one unit.
[0202] If the aforementioned functions are implemented as software functional units and sold or used as independent products, they can be stored in a processor-executable, non-volatile, computer-readable storage medium. Based on this understanding, the technical solution of this application, in essence, or the part that contributes to the prior art, or a portion of the technical solution, can be embodied in the form of a software product. This computer software product is stored in a storage medium and includes several instructions to cause a computer device (which may be a personal computer, server, or network device, etc.) to execute all or part of the steps of the methods described in the various embodiments of this application. The aforementioned storage medium includes various media capable of storing program code, such as USB flash drives, portable hard drives, read-only memory (ROM), random access memory (RAM), magnetic disks, or optical disks.
[0203] Finally, it should be noted that the above-described embodiments are merely specific implementations of this application, used to illustrate the technical solutions of this application, and not to limit them. The scope of protection of this application is not limited thereto. Although this application has been described in detail with reference to the foregoing embodiments, those skilled in the art should understand that any person skilled in the art can still modify or easily conceive of changes to the technical solutions described in the foregoing embodiments, or make equivalent substitutions for some of the technical features, within the scope of the technology disclosed in this application. Such modifications, changes, or substitutions do not cause the essence of the corresponding technical solutions to deviate from the spirit and scope of the technical solutions of the embodiments of this application, and should all be covered within the scope of protection of this application. Therefore, the scope of protection of this application should be determined by the scope of the claims.
Claims
1. A method for detecting track obstacles, characterized in that, The detection method includes: The point cloud to be detected within the area to be detected is segmented from the collected scene point cloud; Based on the track region indicated in the scene image corresponding to the scene point cloud and the point cloud to be detected, a track height change curve is fitted within the detection region. The region to be detected is divided into multiple sub-detection regions according to the determined multiple dividing grids; wherein, the width of each dividing grid is consistent, and the length of each dividing grid is determined by the density of the point cloud in the orbit extension direction; Cluster the point cloud to be detected within each sub-detection region to identify multiple candidate point clouds; Obstacles are determined based on the distance between each candidate point cloud and the plane containing the corresponding track point cloud on the track height change curve; wherein, the obstacles are determined by the attribute information of the candidate point clouds and the height information corresponding to the track parts; the obstacles are candidate point clouds whose distance to the plane containing the corresponding track point cloud on the track height change curve is greater than the height information corresponding to the corresponding track parts.
2. The detection method according to claim 1, characterized in that, The step of segmenting the point cloud to be detected within the detection area from the acquired scene point cloud includes: Obtain two pre-defined boundary lines; The area enclosed by the two boundary lines is defined as the area to be detected. The scene point cloud included in the area to be detected is determined as the point cloud to be detected.
3. The detection method according to claim 1, characterized in that, The step of fitting a track height variation curve within the detection region based on the track region indicated in the scene image corresponding to the scene point cloud and the point cloud to be detected includes: Based on the track region indicated in the scene image, determine multiple pixel coordinates corresponding to the track in the pixel coordinate system; The multiple pixel coordinates are transformed into the radar coordinate system to determine multiple radar coordinates; The point cloud to be detected located at the position indicated by the radar coordinates is identified as the orbital point cloud; Based on the identified multiple orbital point clouds, an orbital height variation curve is fitted within the region to be detected.
4. The detection method according to claim 3, characterized in that, The process of fitting an orbital height variation curve within the detection region based on the determined multiple orbital point clouds includes: The track region is divided into segments according to a preset distance interval to determine multiple sub-fitting regions; For each sub-fitting region, the height curve of the track to be stitched is fitted based on at least one track point cloud included in each sub-fitting region; The track height curves to be spliced within each sub-fitting region are combined to fit the track height variation curve.
5. The detection method according to claim 4, characterized in that, The process of stitching together the track height curves within each sub-fitting region to fit the track height variation curve includes: Each sub-fit region is sorted according to the scanning direction of the acquisition device when acquiring the point cloud of the scene; Correct the height curve of the track to be spliced in the sub-fitting region that is ranked behind by the height curve of the track to be spliced in the sub-fitting region that is ranked ahead. According to the arrangement order of each sub-fitting region, the corrected height curves of multiple tracks to be spliced are stitched together. The resulting track change curve after splicing is determined as the track height change curve.
6. The detection method according to claim 4, characterized in that, For each sub-fitting region, fitting the height curve of the track to be stitched based on at least one track point cloud included in each sub-fitting region includes: Based on the slope height change within the sub-fitting region, fit the track slope change curve within the sub-fitting region; Based on the track slope change curve, track point clouds that are not on the track slope change curve are identified as abnormal point clouds, and multiple identified abnormal point clouds are filtered out from the track point clouds in the sub-fitting region. Connect multiple orbit point clouds within the sub-fitting region after filtering out abnormal point clouds to fit the resulting orbit height curve to be stitched together.
7. The detection method according to claim 1, characterized in that, Multiple grid divisions are determined using the following steps: Determine the density variation trend information of the point cloud to be detected in the region to be detected along the extension direction of the orbital region; Based on the density change trend information of the point cloud to be detected, the length of each grid cell is determined; Multiple grids are obtained based on the length of each grid and the preset grid width.
8. The detection method according to claim 1, characterized in that, The method of determining obstacles based on the distance between each candidate point cloud and the plane containing the corresponding orbital point cloud on the orbital height change curve includes: Determine the standard distance between the location of each candidate point cloud and the plane containing the corresponding orbit point cloud on the orbital height change curve; Candidate point clouds whose distance from the plane containing the corresponding orbit point cloud on the orbital height change curve is greater than the corresponding standard distance are identified as obstacles.
9. The detection method according to claim 1, characterized in that, After determining the obstacle based on the distance between each candidate point cloud and the plane containing the corresponding orbital point cloud on the orbital height change curve, the detection method further includes: The obstacle is labeled, and its attribute information is labeled at a preset location.
10. A device for detecting track obstacles, characterized in that, The detection device includes: The region segmentation module is used to segment the point cloud to be detected within the region to be detected from the acquired scene point cloud; The curve fitting module is used to fit a curve of track height change within the detection area based on the track region indicated in the scene image corresponding to the scene point cloud and the point cloud to be detected. The grid division module is used to divide the area to be detected into multiple sub-detection areas according to a plurality of determined grids; wherein, the width of each grid is consistent, and the length of each grid is determined by the density of the point cloud in the orbital extension direction; The point cloud clustering module is used to cluster the point clouds to be detected in each sub-detection region and identify multiple candidate point clouds; An obstacle determination module is used to determine obstacles based on the distance between each candidate point cloud and the plane containing the corresponding track point cloud on the track height change curve; wherein, the obstacle is determined by the attribute information of the candidate point cloud and the height information corresponding to the track part; the obstacle is a candidate point cloud whose distance to the plane containing the corresponding track point cloud on the track height change curve is greater than the height information corresponding to the corresponding track part.
11. An electronic device, characterized in that, include: The device includes a processor, a memory, and a bus, wherein the memory stores machine-readable instructions executable by the processor, and when the electronic device is in operation, the processor communicates with the memory via the bus, and the machine-readable instructions, when executed by the processor, perform the steps of the track obstacle detection method as described in any one of claims 1 to 9.
12. A computer-readable storage medium, characterized in that, The computer-readable storage medium stores a computer program that, when executed by a processor, performs the steps of the method for detecting track obstacles as described in any one of claims 1 to 9.