[go: up one dir, main page]

CN115222815A - Obstacle distance detection method, device, computer equipment and storage medium - Google Patents

Obstacle distance detection method, device, computer equipment and storage medium Download PDF

Info

Publication number
CN115222815A
CN115222815A CN202210890678.6A CN202210890678A CN115222815A CN 115222815 A CN115222815 A CN 115222815A CN 202210890678 A CN202210890678 A CN 202210890678A CN 115222815 A CN115222815 A CN 115222815A
Authority
CN
China
Prior art keywords
point cloud
obstacle
ground point
contact line
cloud data
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Pending
Application number
CN202210890678.6A
Other languages
Chinese (zh)
Inventor
颜培清
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
DeepRoute AI Ltd
Original Assignee
DeepRoute AI Ltd
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by DeepRoute AI Ltd filed Critical DeepRoute AI Ltd
Priority to CN202210890678.6A priority Critical patent/CN115222815A/en
Publication of CN115222815A publication Critical patent/CN115222815A/en
Pending legal-status Critical Current

Links

Images

Classifications

    • GPHYSICS
    • G06COMPUTING OR CALCULATING; COUNTING
    • G06TIMAGE DATA PROCESSING OR GENERATION, IN GENERAL
    • G06T7/00Image analysis
    • G06T7/70Determining position or orientation of objects or cameras
    • G06T7/73Determining position or orientation of objects or cameras using feature-based methods
    • GPHYSICS
    • G06COMPUTING OR CALCULATING; COUNTING
    • G06TIMAGE DATA PROCESSING OR GENERATION, IN GENERAL
    • G06T3/00Geometric image transformations in the plane of the image
    • G06T3/08Projecting images onto non-planar surfaces, e.g. geodetic screens
    • GPHYSICS
    • G06COMPUTING OR CALCULATING; COUNTING
    • G06TIMAGE DATA PROCESSING OR GENERATION, IN GENERAL
    • G06T2207/00Indexing scheme for image analysis or image enhancement
    • G06T2207/10Image acquisition modality
    • G06T2207/10028Range image; Depth image; 3D point clouds
    • GPHYSICS
    • G06COMPUTING OR CALCULATING; COUNTING
    • G06TIMAGE DATA PROCESSING OR GENERATION, IN GENERAL
    • G06T2207/00Indexing scheme for image analysis or image enhancement
    • G06T2207/30Subject of image; Context of image processing
    • G06T2207/30248Vehicle exterior or interior
    • G06T2207/30252Vehicle exterior; Vicinity of vehicle
    • G06T2207/30261Obstacle

Landscapes

  • Engineering & Computer Science (AREA)
  • Physics & Mathematics (AREA)
  • General Physics & Mathematics (AREA)
  • Theoretical Computer Science (AREA)
  • Computer Vision & Pattern Recognition (AREA)
  • Length Measuring Devices By Optical Means (AREA)

Abstract

The application relates to an obstacle distance detection method, an obstacle distance detection device, a computer device, a storage medium and a computer program product. The method comprises the following steps: acquiring original point cloud data and image data corresponding to the original point cloud data; performing ground point cloud detection based on the original point cloud data to obtain ground point cloud data, and generating a target ground point cloud area based on the ground point cloud data; detecting a contact line between the obstacle and the ground based on the image data to obtain an obstacle contact line; projecting based on the target ground point cloud area to obtain a ground point cloud projection area, and determining an obstacle projection contact line corresponding to an obstacle contact line in the ground point cloud projection area; and determining obstacle contact line point cloud data corresponding to the obstacle projection contact line in the target ground point cloud area, and performing distance calculation based on horizontal plane coordinate information in the obstacle contact line point cloud data to obtain an obstacle distance. The method can improve the accuracy of the obstacle distance detection.

Description

障碍物距离检测方法、装置、计算机设备和存储介质Obstacle distance detection method, device, computer equipment and storage medium

技术领域technical field

本申请涉及自动驾驶技术领域,特别是涉及一种障碍物距离检测方法、装置、计算机设备、存储介质和计算机程序产品。The present application relates to the technical field of automatic driving, and in particular, to a method, apparatus, computer equipment, storage medium and computer program product for detecting distance of obstacles.

背景技术Background technique

随着自动驾驶技术的发展,需要检测自动驾驶车辆周围环境中的障碍物,并需要获得准确的距离信息来规划行驶的路线和速度。现有的障碍物测距通常是通过图像数据进行障碍物检测,但是并不能准确获得障碍物的距离信息;通过激光雷达进行障碍物检测能够获得距离信息,但是由于小物体和远距离物体的点云稀疏,导致存在障碍物距离检测准确性低的问题。With the development of autonomous driving technology, obstacles in the surrounding environment of autonomous vehicles need to be detected, and accurate distance information needs to be obtained to plan the route and speed of driving. Existing obstacle ranging usually detects obstacles through image data, but cannot accurately obtain the distance information of obstacles; obstacle detection through lidar can obtain distance information, but due to the point of small objects and long-distance objects. The clouds are sparse, which leads to the problem of low accuracy of obstacle distance detection.

发明内容SUMMARY OF THE INVENTION

基于此,有必要针对上述技术问题,提供一种能够提高障碍物距离检测准确性的障碍物距离检测方法、装置、计算机设备、计算机可读存储介质和计算机程序产品。Based on this, it is necessary to provide an obstacle distance detection method, device, computer equipment, computer readable storage medium and computer program product that can improve the accuracy of obstacle distance detection in response to the above technical problems.

第一方面,本申请提供了一种障碍物距离检测方法。所述方法包括:In a first aspect, the present application provides an obstacle distance detection method. The method includes:

获取原始点云数据和原始点云数据对应的图像数据;Obtain the original point cloud data and the image data corresponding to the original point cloud data;

基于原始点云数据进行地面点云检测,得到地面点云数据,基于地面点云数据生成目标地面点云区域;The ground point cloud detection is performed based on the original point cloud data, the ground point cloud data is obtained, and the target ground point cloud area is generated based on the ground point cloud data;

基于图像数据进行障碍物与地面的接触线检测,得到障碍物接触线;Based on the image data, the contact line between the obstacle and the ground is detected, and the obstacle contact line is obtained;

基于目标地面点云区域进行投影,得到地面点云投影区域,在地面点云投影区域中确定障碍物接触线对应的障碍物投影接触线;Projecting based on the target ground point cloud area, obtaining the ground point cloud projection area, and determining the obstacle projection contact line corresponding to the obstacle contact line in the ground point cloud projection area;

在目标地面点云区域中确定障碍物投影接触线对应的障碍物接触线点云数据,基于障碍物接触线点云数据中的水平面坐标信息进行距离计算,得到障碍物距离。Determine the obstacle contact line point cloud data corresponding to the obstacle projection contact line in the target ground point cloud area, and calculate the distance based on the horizontal plane coordinate information in the obstacle contact line point cloud data to obtain the obstacle distance.

第二方面,本申请还提供了一种障碍物距离检测装置。所述装置包括:In a second aspect, the present application also provides an obstacle distance detection device. The device includes:

获取模块,用于获取原始点云数据和原始点云数据对应的图像数据;an acquisition module for acquiring the original point cloud data and the image data corresponding to the original point cloud data;

地面检测模块,用于基于原始点云数据进行地面点云检测,得到地面点云数据,基于地面点云数据生成目标地面点云区域;The ground detection module is used to detect the ground point cloud based on the original point cloud data, obtain the ground point cloud data, and generate the target ground point cloud area based on the ground point cloud data;

接触线检测模块,用于基于图像数据进行障碍物与地面的接触线检测,得到障碍物接触线;The contact line detection module is used to detect the contact line between the obstacle and the ground based on the image data, and obtain the obstacle contact line;

投影模块,用于基于目标地面点云区域进行投影,得到地面点云投影区域,在地面点云投影区域中确定障碍物接触线对应的障碍物投影接触线;The projection module is used for projecting based on the target ground point cloud area, obtaining the ground point cloud projection area, and determining the obstacle projection contact line corresponding to the obstacle contact line in the ground point cloud projection area;

计算模块,用于在目标地面点云区域中确定障碍物投影接触线对应的障碍物接触线点云数据,基于障碍物接触线点云数据中的水平面坐标信息进行距离计算,得到障碍物距离。The calculation module is used to determine the obstacle contact line point cloud data corresponding to the obstacle projected contact line in the target ground point cloud area, and calculate the distance based on the horizontal plane coordinate information in the obstacle contact line point cloud data to obtain the obstacle distance.

第三方面,本申请还提供了一种计算机设备。所述计算机设备包括存储器和处理器,所述存储器存储有计算机程序,所述处理器执行所述计算机程序时实现以下步骤:In a third aspect, the present application also provides a computer device. The computer device includes a memory and a processor, the memory stores a computer program, and the processor implements the following steps when executing the computer program:

获取原始点云数据和原始点云数据对应的图像数据;Obtain the original point cloud data and the image data corresponding to the original point cloud data;

基于原始点云数据进行地面点云检测,得到地面点云数据,基于地面点云数据生成目标地面点云区域;The ground point cloud detection is performed based on the original point cloud data, the ground point cloud data is obtained, and the target ground point cloud area is generated based on the ground point cloud data;

基于图像数据进行障碍物与地面的接触线检测,得到障碍物接触线;Based on the image data, the contact line between the obstacle and the ground is detected, and the obstacle contact line is obtained;

基于目标地面点云区域进行投影,得到地面点云投影区域,在地面点云投影区域中确定障碍物接触线对应的障碍物投影接触线;Projecting based on the target ground point cloud area, obtaining the ground point cloud projection area, and determining the obstacle projection contact line corresponding to the obstacle contact line in the ground point cloud projection area;

在目标地面点云区域中确定障碍物投影接触线对应的障碍物接触线点云数据,基于障碍物接触线点云数据中的水平面坐标信息进行距离计算,得到障碍物距离。Determine the obstacle contact line point cloud data corresponding to the obstacle projection contact line in the target ground point cloud area, and calculate the distance based on the horizontal plane coordinate information in the obstacle contact line point cloud data to obtain the obstacle distance.

第四方面,本申请还提供了一种计算机可读存储介质。所述计算机可读存储介质,其上存储有计算机程序,所述计算机程序被处理器执行时实现以下步骤:In a fourth aspect, the present application also provides a computer-readable storage medium. The computer-readable storage medium has a computer program stored thereon, and when the computer program is executed by the processor, the following steps are implemented:

获取原始点云数据和原始点云数据对应的图像数据;Obtain the original point cloud data and the image data corresponding to the original point cloud data;

基于原始点云数据进行地面点云检测,得到地面点云数据,基于地面点云数据生成目标地面点云区域;The ground point cloud detection is performed based on the original point cloud data, the ground point cloud data is obtained, and the target ground point cloud area is generated based on the ground point cloud data;

基于图像数据进行障碍物与地面的接触线检测,得到障碍物接触线;Based on the image data, the contact line between the obstacle and the ground is detected, and the obstacle contact line is obtained;

基于目标地面点云区域进行投影,得到地面点云投影区域,在地面点云投影区域中确定障碍物接触线对应的障碍物投影接触线;Projecting based on the target ground point cloud area, obtaining the ground point cloud projection area, and determining the obstacle projection contact line corresponding to the obstacle contact line in the ground point cloud projection area;

在目标地面点云区域中确定障碍物投影接触线对应的障碍物接触线点云数据,基于障碍物接触线点云数据中的水平面坐标信息进行距离计算,得到障碍物距离。Determine the obstacle contact line point cloud data corresponding to the obstacle projection contact line in the target ground point cloud area, and calculate the distance based on the horizontal plane coordinate information in the obstacle contact line point cloud data to obtain the obstacle distance.

第五方面,本申请还提供了一种计算机程序产品。所述计算机程序产品,包括计算机程序,该计算机程序被处理器执行时实现以下步骤:In a fifth aspect, the present application also provides a computer program product. The computer program product includes a computer program that, when executed by a processor, implements the following steps:

获取原始点云数据和原始点云数据对应的图像数据;Obtain the original point cloud data and the image data corresponding to the original point cloud data;

基于原始点云数据进行地面点云检测,得到地面点云数据,基于地面点云数据生成目标地面点云区域;The ground point cloud detection is performed based on the original point cloud data, the ground point cloud data is obtained, and the target ground point cloud area is generated based on the ground point cloud data;

基于图像数据进行障碍物与地面的接触线检测,得到障碍物接触线;Based on the image data, the contact line between the obstacle and the ground is detected, and the obstacle contact line is obtained;

基于目标地面点云区域进行投影,得到地面点云投影区域,在地面点云投影区域中确定障碍物接触线对应的障碍物投影接触线;Projecting based on the target ground point cloud area, obtaining the ground point cloud projection area, and determining the obstacle projection contact line corresponding to the obstacle contact line in the ground point cloud projection area;

在目标地面点云区域中确定障碍物投影接触线对应的障碍物接触线点云数据,基于障碍物接触线点云数据中的水平面坐标信息进行距离计算,得到障碍物距离。Determine the obstacle contact line point cloud data corresponding to the obstacle projection contact line in the target ground point cloud area, and calculate the distance based on the horizontal plane coordinate information in the obstacle contact line point cloud data to obtain the obstacle distance.

上述障碍物距离检测方法、装置、计算机设备、存储介质和计算机程序产品,通过在原始点云数据中检测出地面点云数据,并根据地面点云数据生成目标地面点云区域。然后通过图像数据检测出障碍物与地面的接触线,将目标地面点云区域进行投影得到地面点云投影区域,保证了地面点云投影区域中存在障碍物接触线对应的投影数据。通过地面点云投影区域能够根据障碍物接触线准确得到障碍物接触线对应的障碍物投影接触线,进而能通过障碍物投影接触线得到准确的障碍物接触线点云数据,根据障碍物接触线点云数据计算得到准确的障碍物距离,从而提高了对障碍物距离检测的准确性。The above-mentioned obstacle distance detection method, device, computer equipment, storage medium and computer program product detect the ground point cloud data in the original point cloud data, and generate the target ground point cloud area according to the ground point cloud data. Then, the contact line between the obstacle and the ground is detected through the image data, and the target ground point cloud area is projected to obtain the ground point cloud projection area, which ensures that the projection data corresponding to the obstacle contact line exists in the ground point cloud projection area. Through the ground point cloud projection area, the obstacle projected contact line corresponding to the obstacle contact line can be accurately obtained according to the obstacle contact line, and then the accurate obstacle contact line point cloud data can be obtained through the obstacle projected contact line. The point cloud data is calculated to obtain the accurate obstacle distance, thereby improving the accuracy of obstacle distance detection.

附图说明Description of drawings

图1为一个实施例中障碍物距离检测方法的应用环境图;Fig. 1 is the application environment diagram of the obstacle distance detection method in one embodiment;

图2为一个实施例中障碍物距离检测方法的流程示意图;FIG. 2 is a schematic flowchart of a method for detecting an obstacle distance in one embodiment;

图3为一个实施例中计算目标障碍物距离的流程示意图;3 is a schematic flowchart of calculating the distance of a target obstacle in one embodiment;

图4为一个实施例中地面点云划分区域的示意图;4 is a schematic diagram of a ground point cloud division area in one embodiment;

图5为一个实施例中生成填充地面点云数据的流程示意图;5 is a schematic flowchart of generating and filling ground point cloud data in one embodiment;

图6为一个实施例中障碍物接触线的示意图;6 is a schematic diagram of an obstacle contact line in one embodiment;

图7为一个实施例中障碍物距离检测的流程示意图;7 is a schematic flowchart of obstacle distance detection in one embodiment;

图8为一个实施例中障碍物距离检测装置的结构框图;8 is a structural block diagram of an obstacle distance detection device in one embodiment;

图9为一个实施例中计算机设备的内部结构图;Fig. 9 is the internal structure diagram of the computer device in one embodiment;

图10为一个实施例中计算机设备的内部结构图。Figure 10 is a diagram of the internal structure of a computer device in one embodiment.

具体实施方式Detailed ways

为了使本申请的目的、技术方案及优点更加清楚明白,以下结合附图及实施例,对本申请进行进一步详细说明。应当理解,此处描述的具体实施例仅仅用以解释本申请,并不用于限定本申请。In order to make the purpose, technical solutions and advantages of the present application more clearly understood, the present application will be described in further detail below with reference to the accompanying drawings and embodiments. It should be understood that the specific embodiments described herein are only used to explain the present application, but not to limit the present application.

本申请实施例提供的障碍物距离检测方法,可以应用于如图1所示的应用环境中。其中,运动载体终端102通过网络与服务器104进行通信。数据存储系统可以存储服务器104需要处理的数据。数据存储系统可以集成在服务器104上,也可以放在云上或其他网络服务器上。运动载体终端获取原始点云数据和原始点云数据对应的图像数据;运动载体终端基于原始点云数据进行地面点云检测,得到地面点云数据,基于地面点云数据生成目标地面点云区域;运动载体终端基于图像数据进行障碍物与地面的接触线检测,得到障碍物接触线;运动载体终端基于目标地面点云区域进行投影,得到地面点云投影区域,在地面点云投影区域中确定障碍物接触线对应的障碍物投影接触线;运动载体终端在目标地面点云区域中确定障碍物投影接触线对应的障碍物接触线点云数据,基于障碍物接触线点云数据中的水平面坐标信息进行距离计算,得到障碍物距离。运动载体终端将障碍物距离发送到服务器104并获取运动路径,根据运动路径进行运动。其中,终端102可以但不限于是各种个人计算机、笔记本电脑、智能手机、平板电脑、物联网设备和便携式可穿戴设备,物联网设备可为智能音箱、智能电视、智能空调、智能车载设备等。便携式可穿戴设备可为智能手表、智能手环、头戴设备等。服务器104可以用独立的服务器或者是多个服务器组成的服务器集群来实现。The obstacle distance detection method provided in this embodiment of the present application can be applied to the application environment shown in FIG. 1 . Wherein, the motion carrier terminal 102 communicates with the server 104 through the network. The data storage system may store data that the server 104 needs to process. The data storage system can be integrated on the server 104, or it can be placed on the cloud or other network server. The motion carrier terminal obtains the original point cloud data and the image data corresponding to the original point cloud data; the motion carrier terminal detects the ground point cloud based on the original point cloud data, obtains the ground point cloud data, and generates the target ground point cloud area based on the ground point cloud data; The moving carrier terminal detects the contact line between the obstacle and the ground based on the image data, and obtains the obstacle contact line; the moving carrier terminal projects based on the target ground point cloud area, obtains the ground point cloud projection area, and determines the obstacle in the ground point cloud projection area The obstacle projection contact line corresponding to the object contact line; the motion carrier terminal determines the obstacle contact line point cloud data corresponding to the obstacle projection contact line in the target ground point cloud area, based on the horizontal plane coordinate information in the obstacle contact line point cloud data Perform distance calculation to get the obstacle distance. The motion carrier terminal sends the obstacle distance to the server 104 and obtains the motion path, and moves according to the motion path. The terminal 102 can be, but is not limited to, various personal computers, notebook computers, smart phones, tablet computers, IoT devices and portable wearable devices, and the IoT devices can be smart speakers, smart TVs, smart air conditioners, smart vehicle-mounted devices, etc. . The portable wearable device may be a smart watch, a smart bracelet, a head-mounted device, or the like. The server 104 can be implemented by an independent server or a server cluster composed of multiple servers.

在一个实施例中,如图2所示,提供了一种障碍物距离检测方法,以该方法应用于图1中的运动载体终端为例进行说明,可以理解的是,该方法也可以应用于服务器,还可以应用于包括终端和服务器的系统,并通过终端和服务器的交互实现。本实施例中,该方法包括以下步骤:In one embodiment, as shown in FIG. 2 , a method for detecting the distance of obstacles is provided, and the method is applied to the moving carrier terminal in FIG. 1 as an example for description. It can be understood that the method can also be applied to The server can also be applied to a system including a terminal and a server, and is realized through the interaction between the terminal and the server. In this embodiment, the method includes the following steps:

步骤202,获取原始点云数据和原始点云数据对应的图像数据。Step 202: Obtain original point cloud data and image data corresponding to the original point cloud data.

其中,原始点云数据是指采集到的运动载体周围环境的原始的点云数据,周围环境可以包括障碍物。图像数据是指采集到的运动载体周围环境的原始的图像。运动载体是指可运动的对象,该运动载体可以是无人驾驶的运动载体,也可以是有人驾驶的运动载体。The original point cloud data refers to the collected original point cloud data of the surrounding environment of the motion carrier, and the surrounding environment may include obstacles. The image data refers to the collected original images of the surrounding environment of the moving carrier. The motion carrier refers to a movable object, and the motion carrier can be an unmanned motion carrier or a manned motion carrier.

具体地,运动载体装配有点云数据采集设备和图像采集设备,云数据采集设备和图像采集设备预先进行统一坐标系,并采用相同的帧率同步采集数据,即图像数据中的一帧图像数据对应原始点云数据中的一帧点云数据。运动载体终端可以通过点云数据采集设备获取运动载体周围的原始点云数据,并通过图像采集设备获取运动载体周围的图像数据。运动载体可以是车辆、飞行器、机器人等。Specifically, the motion carrier is equipped with a point cloud data acquisition device and an image acquisition device. The cloud data acquisition device and the image acquisition device have a unified coordinate system in advance, and use the same frame rate to synchronously collect data, that is, one frame of image data in the image data corresponds to A frame of point cloud data in the original point cloud data. The motion carrier terminal can acquire the original point cloud data around the motion carrier through the point cloud data acquisition device, and acquire the image data around the motion carrier through the image acquisition device. The motion carrier can be a vehicle, an aircraft, a robot, and the like.

步骤204,基于原始点云数据进行地面点云检测,得到地面点云数据,基于地面点云数据生成目标地面点云区域。Step 204: Perform ground point cloud detection based on the original point cloud data to obtain ground point cloud data, and generate a target ground point cloud area based on the ground point cloud data.

其中,地面点云数据是指原始点云数据中表征地面的点云数据。目标地面点云区域是指对原始点云数据中地面区域进行点云数据填充得到的地面点云数据。The ground point cloud data refers to the point cloud data representing the ground in the original point cloud data. The target ground point cloud area refers to the ground point cloud data obtained by filling the ground area in the original point cloud data with point cloud data.

具体地,运动载体终端使用预设的地面点分类算法对原始点云数据进行检测,得到原始点云数据中的地面点云数据。然后运动载体终端对地面点云数据进行扫描,检测到地面点云数据之间存在空白区域时,根据已有的地面点云数据对空白区域进行点云数据填充,得到目标地面点云区域。Specifically, the motion carrier terminal uses a preset ground point classification algorithm to detect the original point cloud data, and obtains ground point cloud data in the original point cloud data. Then, the motion carrier terminal scans the ground point cloud data, and when a blank area is detected between the ground point cloud data, the blank area is filled with point cloud data according to the existing ground point cloud data, and the target ground point cloud area is obtained.

步骤206,基于图像数据进行障碍物与地面的接触线检测,得到障碍物接触线。Step 206 , detecting the contact line between the obstacle and the ground based on the image data to obtain the obstacle contact line.

其中,障碍物接触线是指障碍物与地面的接触区域,在图像数据中以线的形式显示。The obstacle contact line refers to the contact area between the obstacle and the ground, which is displayed in the form of a line in the image data.

具体地,运动载体终端使用预设的深度学习网络模型对图像数据与地面的接触区域进行检测,获取模型输出的障碍物接触线。Specifically, the motion carrier terminal uses a preset deep learning network model to detect the contact area between the image data and the ground, and obtains the obstacle contact line output by the model.

步骤208,基于目标地面点云区域进行投影,得到地面点云投影区域,在地面点云投影区域中确定障碍物接触线对应的障碍物投影接触线。Step 208 , projecting based on the target ground point cloud area to obtain the ground point cloud projection area, and determining the obstacle projection contact line corresponding to the obstacle contact line in the ground point cloud projection area.

其中,投影是指将目标地面点云区域的三维点云数据投影到二维平面来获得点云投影数据的过程,点云投影数据是指点云数据投影到二维平面的数据,点云投影数据以二维数据的形式存在。在一个实施例中,将点云数据投影到图像数据相同的二维坐标系获得对应的点云投影数据。地面点云投影区域是指目标地面点云区域进行投影后得到的点云投影区域。障碍物投影接触线是指地面点云投影区域中与障碍物接触线对应的点云投影数据。Among them, projection refers to the process of projecting the 3D point cloud data of the target ground point cloud area to a 2D plane to obtain the point cloud projection data. The point cloud projection data refers to the data projected from the point cloud data to the 2D plane, and the point cloud projection data exists in the form of two-dimensional data. In one embodiment, the corresponding point cloud projection data is obtained by projecting the point cloud data to the same two-dimensional coordinate system as the image data. The ground point cloud projection area refers to the point cloud projection area obtained after the target ground point cloud area is projected. The obstacle projection contact line refers to the point cloud projection data corresponding to the obstacle contact line in the ground point cloud projection area.

具体地,运动载体终端根据预先设置好的标定参数将目标地面点云区域中的三维坐标转换成水平面坐标,得到目标地面点云区域投影后的点云投影数据,即地面点云投影区域。然后运动载体终端根据障碍物接触线的坐标信息在地面点云投影区域中查找到对应的障碍物投影接触线。Specifically, the motion carrier terminal converts the three-dimensional coordinates in the target ground point cloud area into horizontal plane coordinates according to preset calibration parameters, and obtains the projected point cloud projection data of the target ground point cloud area, that is, the ground point cloud projection area. Then, the mobile carrier terminal finds the corresponding obstacle projection contact line in the ground point cloud projection area according to the coordinate information of the obstacle contact line.

步骤210,在目标地面点云区域中确定障碍物投影接触线对应的障碍物接触线点云数据,基于障碍物接触线点云数据中的水平面坐标信息进行距离计算,得到障碍物距离。Step 210: Determine the obstacle contact line point cloud data corresponding to the obstacle projected contact line in the target ground point cloud area, and perform distance calculation based on the horizontal plane coordinate information in the obstacle contact line point cloud data to obtain the obstacle distance.

其中,障碍物接触线点云数据是指在目标地面点云区域中与障碍物投影接触线对应的点云数据。水平面坐标信息是指点云数据的三维坐标中表征水平面的二维坐标。障碍物距离是指运动载体与障碍物之间的距离。The obstacle contact line point cloud data refers to the point cloud data corresponding to the obstacle projected contact line in the target ground point cloud area. The horizontal plane coordinate information refers to the two-dimensional coordinates representing the horizontal plane among the three-dimensional coordinates of the point cloud data. The obstacle distance refers to the distance between the motion carrier and the obstacle.

具体地,运动载体终端根据目标地面点云区域与地面点云投影区域之间的投影关系,在目标地面点云区域中查找到障碍物投影接触线对应的障碍物接触线点云数据。然后获取碍物接触线点云数据中的水平面坐标进行距离计算,得到运动载体与障碍物之间的距离。Specifically, according to the projection relationship between the target ground point cloud area and the ground point cloud projection area, the motion carrier terminal finds the obstacle contact line point cloud data corresponding to the obstacle projection contact line in the target ground point cloud area. Then, the horizontal plane coordinates in the point cloud data of the obstacle contact line are obtained to calculate the distance, and the distance between the moving carrier and the obstacle is obtained.

上述障碍物距离检测方法中,通过在原始点云数据中检测出地面点云数据,并根据地面点云数据生成目标地面点云区域。然后通过图像数据检测出障碍物与地面的接触线,将目标地面点云区域进行投影得到地面点云投影区域,保证了地面点云投影区域中存在障碍物接触线对应的投影数据。通过地面点云投影区域能够根据障碍物接触线准确得到障碍物接触线对应的障碍物投影接触线,进而能通过障碍物投影接触线得到准确的障碍物接触线点云数据,根据障碍物接触线点云数据计算得到准确的障碍物距离,从而提高了对障碍物距离检测的准确性。In the above obstacle distance detection method, the ground point cloud data is detected in the original point cloud data, and the target ground point cloud area is generated according to the ground point cloud data. Then, the contact line between the obstacle and the ground is detected through the image data, and the target ground point cloud area is projected to obtain the ground point cloud projection area, which ensures that the projection data corresponding to the obstacle contact line exists in the ground point cloud projection area. Through the ground point cloud projection area, the obstacle projected contact line corresponding to the obstacle contact line can be accurately obtained according to the obstacle contact line, and then the accurate obstacle contact line point cloud data can be obtained through the obstacle projected contact line. The point cloud data is calculated to obtain the accurate obstacle distance, thereby improving the accuracy of obstacle distance detection.

在一个实施例中,如图3所示,提供一种计算目标障碍物距离的流程示意图;所述方法,还包括:In one embodiment, as shown in FIG. 3 , a schematic flowchart of calculating the distance to a target obstacle is provided; the method further includes:

步骤302,获取障碍物接触线点云数据对应的垂直坐标信息和障碍物接触线对应的坐标信息;Step 302, obtaining the vertical coordinate information corresponding to the point cloud data of the obstacle contact line and the coordinate information corresponding to the obstacle contact line;

步骤304,基于垂直坐标信息和坐标信息进行点云坐标计算,得到障碍物接触线点云数据对应的目标水平面坐标信息;Step 304 , perform point cloud coordinate calculation based on the vertical coordinate information and the coordinate information, and obtain the target horizontal plane coordinate information corresponding to the obstacle contact line point cloud data;

步骤306,基于目标水平面坐标信息进行距离计算,得到目标障碍物距离。Step 306: Perform distance calculation based on the target horizontal plane coordinate information to obtain the target obstacle distance.

其中,垂直坐标信息是指点云数据的三维坐标中垂直方向的坐标。坐标信息是指图像数据对应的二维平面坐标。目标水平面坐标信息是指经过点云坐标计算得到的障碍物接触线点云数据对应的水平面坐标信息,包括点云数据对应的横向坐标信息和纵向坐标信息。目标障碍物距离是指使用目标水平面坐标信息进行距离计算得到的运动载体与障碍物之间的距离。The vertical coordinate information refers to the coordinates in the vertical direction in the three-dimensional coordinates of the point cloud data. The coordinate information refers to the two-dimensional plane coordinates corresponding to the image data. The target horizontal plane coordinate information refers to the horizontal plane coordinate information corresponding to the point cloud data of the obstacle contact line obtained by calculating the point cloud coordinates, including the horizontal coordinate information and the vertical coordinate information corresponding to the point cloud data. The target obstacle distance refers to the distance between the moving carrier and the obstacle obtained by using the target horizontal plane coordinate information to calculate the distance.

具体地,运动载体终端对障碍物接触线点云数据进行扫描,检测到障碍物接触线点云数据中存在填充的地面点云数据时,获取障碍物接触线点云数据对应的垂直坐标信息。然后运动载体终端获取障碍物接触线对应的坐标信息,障碍物接触线对应的坐标信息可以是运动载体终端在使用预设的深度学习网络模型对图像数据与地面的接触区域进行检测时得到的。运动载体终端获取预先存储的点云坐标计算公式,使用障碍物接触线点云数据对应的垂直坐标信息和障碍物接触线对应的坐标信息按照点云计算公式进行计算,得到障碍物接触线点云数据对应的水平面坐标信息。运动载体终端将计算得到的障碍物接触线点云数据对应的水平面坐标信息作为目标水平面坐标信息。然后运动载体终端使用目标水平面坐标信息进行距离计算,得到目标障碍物距离。Specifically, the motion carrier terminal scans the point cloud data of the obstacle contact line, and obtains vertical coordinate information corresponding to the point cloud data of the obstacle contact line when it detects that there is filled ground point cloud data in the point cloud data of the obstacle contact line. Then the moving carrier terminal obtains the coordinate information corresponding to the obstacle contact line, and the coordinate information corresponding to the obstacle contact line may be obtained when the moving carrier terminal detects the contact area between the image data and the ground using a preset deep learning network model. The motion carrier terminal obtains the pre-stored point cloud coordinate calculation formula, uses the vertical coordinate information corresponding to the obstacle contact line point cloud data and the coordinate information corresponding to the obstacle contact line to calculate according to the point cloud calculation formula, and obtains the obstacle contact line point cloud The horizontal plane coordinate information corresponding to the data. The motion carrier terminal takes the calculated horizontal plane coordinate information corresponding to the point cloud data of the obstacle contact line as the target horizontal plane coordinate information. Then the moving carrier terminal uses the target horizontal plane coordinate information to calculate the distance to obtain the target obstacle distance.

当运动载体终端检测到障碍物接触线点云数据中未存在填充的地面点云数据时,将障碍物接触线点云数据中已有的地面点云数据对应的水平面坐标信息作为目标水平面坐标信息,并使用目标水平面坐标信息进行距离计算,得到目标障碍物距离。When the motion carrier terminal detects that there is no filled ground point cloud data in the obstacle contact line point cloud data, the horizontal plane coordinate information corresponding to the existing ground point cloud data in the obstacle contact line point cloud data is used as the target horizontal plane coordinate information , and use the target horizontal plane coordinate information to calculate the distance to obtain the target obstacle distance.

在一个具体实施例中,点云数据采集设备可以是激光雷达,图像采集设备可以是单目相机,内外参矩阵可以预先通过激光雷达和单目相机的标定算法获得的。点云坐标计算公式是通过内外参矩阵进行推导得到的,内外参矩阵是预先通过标定算法获得的。通过内参矩阵将相机坐标系下的三维坐标投影到图像中的计算公式如公式(1)所示:In a specific embodiment, the point cloud data acquisition device may be a lidar, the image acquisition device may be a monocular camera, and the internal and external parameter matrices may be obtained in advance through a calibration algorithm of the lidar and the monocular camera. The calculation formula of point cloud coordinates is obtained by deriving the internal and external parameter matrix, which is obtained by the calibration algorithm in advance. The calculation formula for projecting the three-dimensional coordinates in the camera coordinate system into the image through the internal parameter matrix is shown in formula (1):

Figure BDA0003767457660000081
Figure BDA0003767457660000081

其中fx,fy为相机焦距,ox oy为原点偏移,Xc,Yc,Zc为相机坐标系下三维点,U,V为障碍物接触线的中各个点的二维坐标。Where fx, fy are the focal length of the camera, ox oy is the origin offset, Xc, Yc, Zc are the three-dimensional points in the camera coordinate system, and U, V are the two-dimensional coordinates of each point in the obstacle contact line.

通过外参矩阵将激光雷达坐标系下的三维点变换到相机坐标系中的计算公式如公式(2)所示:The calculation formula for transforming the three-dimensional point in the lidar coordinate system into the camera coordinate system through the external parameter matrix is shown in formula (2):

Figure BDA0003767457660000082
Figure BDA0003767457660000082

其中M为旋转矩阵,tx,ty,tz为平移向量,Xw,Yw,Zw为激光雷达坐标系下的三维点,Xc,Yc,Zc为相机坐标系下的三维点。Where M is the rotation matrix, tx, ty, tz are translation vectors, Xw, Yw, Zw are the three-dimensional points in the lidar coordinate system, and Xc, Yc, Zc are the three-dimensional points in the camera coordinate system.

使用公式(1)和公式(2)进行推导得到点云坐标计算公式,如公式(3)所示,Use formula (1) and formula (2) to derive the point cloud coordinate calculation formula, as shown in formula (3),

Xw=((M11-(V-oy)*(M21)/fy)*((U-ox)*(M22*Zw+tz)/fx-M02*Zw-tx)-(M01-(U-ox)*(M21)/fx)*((V-oy)*(M22*Zw+tz)/fy-M12*Zw-ty))/((M11-(V-oy)*(M21)/fy)*(M00-(U-ox)*(M20)/fx)-(M01-(U-ox)*(M21)/fx)*(M10-(V-oy)*(M20)/fy));Xw=((M11-(V-oy)*(M21)/fy)*((U-ox)*(M22*Zw+tz)/fx-M02*Zw-tx)-(M01-(U-ox) )*(M21)/fx)*((V-oy)*(M22*Zw+tz)/fy-M12*Zw-ty))/((M11-(V-oy)*(M21)/fy) *(M00-(U-ox)*(M20)/fx)-(M01-(U-ox)*(M21)/fx)*(M10-(V-oy)*(M20)/fy));

Yw=((M10-(V-oy)*(M20)/fy)*((U-ox)*(M22*Zw+tz)/fx-M02*Zw-tx)-(M00-(U-ox)*(M20)/fx)*((V-oy)*(M22*Zw+tz)/fy-M12*Zw-ty))/((M10-(V-oy)*(M20)/fy)*(M01-(U-ox)*(M21)/fx)-(M00-(U-ox)*(M20)/fx)*(M11-(V-oy)*(M21)/fy))公式(3),Yw=((M10-(V-oy)*(M20)/fy)*((U-ox)*(M22*Zw+tz)/fx-M02*Zw-tx)-(M00-(U-ox) )*(M20)/fx)*((V-oy)*(M22*Zw+tz)/fy-M12*Zw-ty))/((M10-(V-oy)*(M20)/fy) *(M01-(U-ox)*(M21)/fx)-(M00-(U-ox)*(M20)/fx)*(M11-(V-oy)*(M21)/fy)) formula (3),

其中,Xw表示障碍物接触线点云数据对应的横向坐标信息;Yw表示障碍物接触线点云数据对应的纵向坐标信息。运动载体获取障碍物接触线点云数据中对应的垂直坐标信息Zw,并获取障碍物接触线对应的坐标信息(U,V),使用Zw和(U,V)按照公式(3)进行计算,得到障碍物接触线点云数对应的模板水平面坐标信息(Xw,Yw),然后使用(Xw,Yw)计算目标障碍物距离。Among them, Xw represents the horizontal coordinate information corresponding to the point cloud data of the obstacle contact line; Yw represents the vertical coordinate information corresponding to the point cloud data of the obstacle contact line. The motion carrier obtains the corresponding vertical coordinate information Zw in the point cloud data of the obstacle contact line, and obtains the coordinate information (U, V) corresponding to the obstacle contact line, and uses Zw and (U, V) to calculate according to formula (3), Obtain the template horizontal plane coordinate information (Xw, Yw) corresponding to the point cloud number of the obstacle contact line, and then use (Xw, Yw) to calculate the target obstacle distance.

本实施例中,通过检测到障碍物接触线点云数据中存在填充的地面点云数据时,使用点云坐标计算公式计算障碍物接触线点云数据对应的水平面坐标信息,能够减小填充的地面点云数据的误差,从而提高了对障碍物距离检测的准确性。In this embodiment, when it is detected that there is filled ground point cloud data in the point cloud data of the obstacle contact line, the point cloud coordinate calculation formula is used to calculate the horizontal plane coordinate information corresponding to the point cloud data of the obstacle contact line, which can reduce the amount of filling. The error of ground point cloud data improves the accuracy of obstacle distance detection.

在一个实施例中,步骤204,基于地面点云数据生成目标地面点云区域,包括:In one embodiment, step 204, generating a target ground point cloud area based on the ground point cloud data, including:

基于预设划分规格对地面点云数据进行划分,得到地面点云划分区域,地面点云划分区域包括地面点云区域和待填充区域;Divide the ground point cloud data based on the preset division specification to obtain the ground point cloud division area, and the ground point cloud division area includes the ground point cloud area and the area to be filled;

基于地面点云区域中的区域地面点云数据生成待填充区域对应的填充地面点云数据,基于区域地面点云数据和填充地面点云数据生成目标地面点云区域。The filled ground point cloud data corresponding to the area to be filled is generated based on the regional ground point cloud data in the ground point cloud area, and the target ground point cloud area is generated based on the regional ground point cloud data and the filled ground point cloud data.

其中,预设划分规格是指预先设置好的对地面点云数据进行区域划分的规格。地面点云划分区域是指对地面点云数据进行划分后得到的划分区域,该地面点云划分区域中包括有地面点云数据。地面点云区域是指地面点云划分区域中存在地面点云数据的区域。待填充区域是指地面点云划分区域中需要填充地面点云数据的区域。填充地面点云数据是指填充到待填充区域的地面点云数据。区域地面点云数据是指地面点云区域中已存在的地面点云数据。The preset division specification refers to a preset specification for dividing the ground point cloud data into regions. The ground point cloud division area refers to the division area obtained by dividing the ground point cloud data, and the ground point cloud division area includes the ground point cloud data. The ground point cloud area refers to the area where ground point cloud data exists in the ground point cloud division area. The area to be filled refers to the area that needs to be filled with ground point cloud data in the ground point cloud division area. Filled ground point cloud data refers to the ground point cloud data filled into the area to be filled. Regional ground point cloud data refers to the existing ground point cloud data in the ground point cloud area.

具体地,运动载体终端根据预先设置好的划分规格将地面点云数据划分出固定规格的网格,比如,按照3米的划分规格将地面点云数据划分成3*3的正方形网格。然后运动载体终端查找存在地面点云数据的网格,并对查找到的网格中地面点云数据的分布状态进行扫描,将扫描的网格中分布有地面点云数据的区域作为地面点云区域,将扫描的网格中未分布有地面点云数据的区域作为待填充区域。Specifically, the motion carrier terminal divides the ground point cloud data into grids of a fixed size according to the preset division specification, for example, divides the ground point cloud data into a 3*3 square grid according to the division specification of 3 meters. Then the motion carrier terminal searches for the grid with ground point cloud data, scans the distribution state of the ground point cloud data in the found grid, and takes the area where the ground point cloud data is distributed in the scanned grid as the ground point cloud The area in the scanned grid that is not distributed with ground point cloud data is used as the area to be filled.

然后运动载体终端根据地面点云区域中的地面点云数据进行估计,将估计得到地面点云数据作为填充地面点云数据,并将填充地面点云数据填充到待填充区域。运动载体终端可以再次扫描各个存在地面点云数据的网格,检测到未存在待填充区域时,将各个存在地面点云数据的网格作为目标地面点云区域。Then, the motion carrier terminal performs estimation according to the ground point cloud data in the ground point cloud area, uses the estimated ground point cloud data as the filled ground point cloud data, and fills the filled ground point cloud data into the area to be filled. The motion carrier terminal can scan each grid with ground point cloud data again, and when detecting that there is no area to be filled, use each grid with ground point cloud data as the target ground point cloud area.

在一个具体实施例中,如图4所示,提供一种地面点云划分区域的示意图;框A表示划分得到的地面点云划分区域;框A-a表示地面点云区域;框A-b表示待填充区域。In a specific embodiment, as shown in FIG. 4, a schematic diagram of a ground point cloud division area is provided; frame A represents the divided ground point cloud area obtained by division; frame A-a represents the ground point cloud area; frame A-b represents the area to be filled .

本实施例中,通过按照预设划分规格对地面点云数据进行划分,得到各个地面点云划分区域,并将地面点云划分区域中待填充区域进行点云数据的填充,能够得到完整的地面点云数据,从而能够保证目标地面点云区域中存在障碍物接触线对应的三维坐标,避免了目标地面点云区域投影时发生数据缺失的情况,从而提高了对障碍物距离检测的准确性。In this embodiment, by dividing the ground point cloud data according to the preset division specification to obtain each ground point cloud division area, and filling the area to be filled in the ground point cloud division area with the point cloud data, a complete ground point cloud can be obtained. point cloud data, so as to ensure that there are three-dimensional coordinates corresponding to the obstacle contact line in the target ground point cloud area, avoid data loss when the target ground point cloud area is projected, and thus improve the accuracy of obstacle distance detection.

在一个实施例中,如图5所示,提供一种生成填充地面点云数据的流程示意图;基于地面点云区域中的区域地面点云数据生成待填充区域对应的填充地面点云数据,包括:In one embodiment, as shown in FIG. 5 , a schematic flowchart of generating filled ground point cloud data is provided; based on the regional ground point cloud data in the ground point cloud area, the filled ground point cloud data corresponding to the area to be filled is generated, including :

步骤502,基于区域地面点云数据建立区域点云坐标关系;Step 502, establishing a regional point cloud coordinate relationship based on the regional ground point cloud data;

步骤504,获取区域地面点云数据对应的区域水平面坐标信息,基于区域水平面坐标信息和预设水平面坐标间隔信息计算待填充区域对应的填充水平面坐标信息;Step 504: Obtain the regional horizontal plane coordinate information corresponding to the regional ground point cloud data, and calculate the filling horizontal plane coordinate information corresponding to the area to be filled based on the regional horizontal plane coordinate information and the preset horizontal plane coordinate interval information;

步骤506,基于填充平面坐标信息按照区域点云坐标关系进行计算,得到待填充区域对应的填充垂直坐标信息;Step 506: Calculate according to the coordinate relationship of the area point cloud based on the coordinate information of the filling plane, and obtain the filling vertical coordinate information corresponding to the area to be filled;

步骤508,基于填充水平面坐标信息和填充垂直坐标信息生成待填充区域对应的填充地面点云数据。Step 508: Generate filled ground point cloud data corresponding to the area to be filled based on the filled horizontal coordinate information and the filled vertical coordinate information.

其中,区域点云坐标关系是指地面点云划分区域中点云之间存在的客观物理关系。不同的地面点云划分区域对应的区域点云坐标关系不同。区域水平面坐标信息是指地面点云区域中的地面点云数据对应的水平面坐标信息。填充地面点云数据是指根据区域地面点云数据估计的地面点云数据,填充地面点云数据用于填充待填充区域。预设水平面坐标间隔信息是指预先设置好的用于估计填充地面点云数据的水平面坐标之间的间隔值。填充水平面坐标信息是指填充地面点云数据对应的水平面坐标信息。填充垂直坐标信息是指填充地面点云数据对应的垂直坐标信息。Among them, the regional point cloud coordinate relationship refers to the objective physical relationship between the point clouds in the ground point cloud division area. Different ground point cloud division areas correspond to different regional point cloud coordinate relationships. The regional horizontal plane coordinate information refers to the horizontal plane coordinate information corresponding to the ground point cloud data in the ground point cloud region. Filling the ground point cloud data refers to the ground point cloud data estimated according to the regional ground point cloud data, and the filling ground point cloud data is used to fill the area to be filled. The preset horizontal plane coordinate interval information refers to a preset interval value between horizontal plane coordinates used for estimating and filling ground point cloud data. The filled horizontal plane coordinate information refers to the horizontal plane coordinate information corresponding to the filled ground point cloud data. Filling the vertical coordinate information refers to filling the vertical coordinate information corresponding to the ground point cloud data.

具体地,运动载体终端随机获取至少两个区域地面点云数据,根据至少两个区域地面点云数据建立区域点云坐标关系,运动载体终端可以使用平面方程建立区域点云坐标关系:Ax+By+Cz+D=0,A、B、C、D表示平面方程的系数,平面方程的系数可以通过采用最小二乘法、RANSAC等算法估计得到。然后运动载体终端扫描地面点云区域中的区域地面点云数据,获取最接近待填充区域的区域地面点云数据对应的区域水平面坐标信息,然后根据预设水平面坐标间隔信息对区域水平面坐标信息进行累加,得到待填充区域对应的多个填充水平面坐标信息,比如,区域地面点云数据对应的区域水平面坐标信息为(1,1),预设水平面坐标间隔信息为0.1,则填充地面点云数据对应的多个填充水平面坐标信息分别为(1.1,1.1)、(1.2,1.2)、(1.3,1.3)等,也可以按照坐标分别进行累加,比如,(1.1,1.1)、(1.1,1.2)、(1.2,1.3)、(1.3,1.4)等,或者(1.1,1.1)、(1.2,1.1)、(1.3,1.2)、(1.4,1.3)等。运动载体终端使用估计得到的填充水平面坐标信息按照点云坐标关系进行计算,得到填充垂直坐标信息,然后运动载体终端根据填充水平面坐标信息和填充垂直坐标信息得到待填充区域对应的填充地面点云数据,并且对填充地面点云数据进行标记,以便后续对填充地面点云数据进行处理。Specifically, the motion carrier terminal randomly acquires at least two regional ground point cloud data, establishes the regional point cloud coordinate relationship according to the at least two regional ground point cloud data, and the motion carrier terminal can use the plane equation to establish the regional point cloud coordinate relationship: Ax+By +Cz+D=0, A, B, C, and D represent the coefficients of the plane equation, and the coefficients of the plane equation can be estimated by using algorithms such as least squares method and RANSAC. Then the motion carrier terminal scans the regional ground point cloud data in the ground point cloud area, obtains the regional horizontal plane coordinate information corresponding to the regional ground point cloud data closest to the area to be filled, and then performs the regional horizontal plane coordinate information according to the preset horizontal plane coordinate interval information. Accumulate to obtain multiple filling horizontal plane coordinate information corresponding to the area to be filled. For example, the regional horizontal plane coordinate information corresponding to the regional ground point cloud data is (1, 1), and the preset horizontal plane coordinate interval information is 0.1, then fill the ground point cloud data. The corresponding coordinate information of multiple filling levels are (1.1, 1.1), (1.2, 1.2), (1.3, 1.3), etc., and can also be accumulated according to the coordinates, for example, (1.1, 1.1), (1.1, 1.2) , (1.2, 1.3), (1.3, 1.4), etc., or (1.1, 1.1), (1.2, 1.1), (1.3, 1.2), (1.4, 1.3), etc. The moving carrier terminal uses the estimated filling horizontal plane coordinate information to calculate according to the point cloud coordinate relationship to obtain the filling vertical coordinate information, and then the moving carrier terminal obtains the filling ground point cloud data corresponding to the area to be filled according to the filling horizontal plane coordinate information and the filling vertical coordinate information. , and mark the filled ground point cloud data for subsequent processing of the filled ground point cloud data.

本实施例中,根据已有的地面点云数据通过预设水平面坐标间隔信息和区域点云坐标关系进行估计,能够准确得到填充地面点云数据,并且能够得到完整的地面点云数据,从而能够保证目标地面点云区域中存在障碍物接触线对应的三维坐标,避免了目标地面点云区域投影时发生数据缺失的情况,从而提高了对障碍物距离检测的准确性。In this embodiment, according to the existing ground point cloud data, the pre-set horizontal plane coordinate interval information and the regional point cloud coordinate relationship are estimated, the filled ground point cloud data can be accurately obtained, and the complete ground point cloud data can be obtained, so that the It is ensured that there are three-dimensional coordinates corresponding to the obstacle contact line in the target ground point cloud area, which avoids the situation of data missing when the target ground point cloud area is projected, thereby improving the accuracy of obstacle distance detection.

在一个实施例中,步骤208,在地面点云投影区域中确定障碍物接触线对应的障碍物投影接触线,包括:In one embodiment, step 208, determining the obstacle projection contact line corresponding to the obstacle contact line in the ground point cloud projection area, including:

基于障碍物接触线对应的接触线坐标信息在地面点云投影区域中查找与接触线坐标信息相同的投影坐标信息,得到目标投影坐标信息;Based on the contact line coordinate information corresponding to the obstacle contact line, search for the projection coordinate information that is the same as the contact line coordinate information in the ground point cloud projection area, and obtain the target projection coordinate information;

基于目标投影坐标信息得到障碍物投影接触线。The obstacle projection contact line is obtained based on the target projection coordinate information.

其中,接触线坐标信息是指在采集的图像数据中障碍物接触线对应的二维坐标信息。投影坐标信息是指地面点云投影区域对应的图像数据中的二维坐标信息。The contact line coordinate information refers to the two-dimensional coordinate information corresponding to the obstacle contact line in the collected image data. The projection coordinate information refers to the two-dimensional coordinate information in the image data corresponding to the ground point cloud projection area.

具体地,运动载体终端根据障碍物接触线对应的接触线坐标信息对地面点云投影区域中的投影坐标信息进行扫描,获取地面点云投影区域中与接触线坐标信息相同的投影坐标信息,将获取到的投影坐标信息作为目标投影坐标信息。然后运动载体终端根据目标投影坐标信息得到障碍物投影接触线。具体来说,障碍物接触线中的二维点的点数由图像数据对应的像素个数确定,则障碍物投影接触线中的二维点的点数量由障碍物接触线中的二维点的点数确定,进一步地,障碍物接触线点云数据中的三维点的点数量由障碍物投影接触线中的二维点的点数量确定。Specifically, the moving carrier terminal scans the projection coordinate information in the ground point cloud projection area according to the contact line coordinate information corresponding to the obstacle contact line, obtains the same projection coordinate information as the contact line coordinate information in the ground point cloud projection area, and sets the The obtained projection coordinate information is used as the target projection coordinate information. Then, the moving carrier terminal obtains the obstacle projected contact line according to the target projected coordinate information. Specifically, the number of two-dimensional points in the obstacle contact line is determined by the number of pixels corresponding to the image data, and the number of two-dimensional points in the obstacle projected contact line is determined by the number of two-dimensional points in the obstacle contact line. The number of points is determined. Further, the number of points of the three-dimensional points in the point cloud data of the obstacle contact line is determined by the number of points of the two-dimensional points in the projected contact line of the obstacle.

在一个具体实施例中,如图6所示,提供一种障碍物接触线的示意图;图中A表示采集到的图像数据中的障碍物;B表示采集到的图像数据中的地面区域;线L表示障碍物与地面的接触线。In a specific embodiment, as shown in FIG. 6, a schematic diagram of an obstacle contact line is provided; in the figure, A represents the obstacle in the collected image data; B represents the ground area in the collected image data; line L represents the contact line between the obstacle and the ground.

本实施例中,通过在地面点云投影区域查找与接触线坐标信息相同的目标投影坐标信息,从而得到障碍物投影接触线,能够提高障碍物投影接触线的坐标准确性,从而提高对障碍物距离检测的准确性。In this embodiment, by searching for the target projection coordinate information that is the same as the contact line coordinate information in the ground point cloud projection area, the obstacle projected contact line can be obtained, which can improve the coordinate accuracy of the obstacle projected contact line, thereby improving the accuracy of the obstacle projection contact line. The accuracy of distance detection.

在一个实施例中,步骤210,基于障碍物接触线点云数据中的水平面坐标信息进行距离计算,得到障碍物距离,包括:In one embodiment, in step 210, distance calculation is performed based on the horizontal plane coordinate information in the point cloud data of the obstacle contact line to obtain the obstacle distance, including:

获取障碍物接触线点云数据中各个三维点对应的水平面坐标信息;Obtain the horizontal plane coordinate information corresponding to each 3D point in the point cloud data of the obstacle contact line;

基于各个三维点对应的水平面坐标信息分别进行距离计算,得到各个三维点对应的点障碍物距离;Based on the horizontal plane coordinate information corresponding to each 3D point, the distance is calculated respectively to obtain the point obstacle distance corresponding to each 3D point;

将各个三维点对应的点障碍物距离中最短的点障碍物距离作为障碍物距离。The shortest point obstacle distance among the point obstacle distances corresponding to each 3D point is taken as the obstacle distance.

其中,三维点表示组成点云数据的组成单元。点障碍物距离是指运动载体与障碍物接触线中的三维点之间的距离。Among them, the three-dimensional point represents the component unit that constitutes the point cloud data. The point obstacle distance is the distance between the motion carrier and the three-dimensional point in the obstacle contact line.

具体地,运动载体终端获取障碍物接触线点云数据中各个三维点对应的水平面坐标信息,包括横向坐标信息和纵向坐标信息。分别使用各个三维点对应的水平面坐标信息进行距离计算,得到多个点障碍物距离。运动载体终端可以使用三角形斜边计算公式计算点障碍物距离:

Figure BDA0003767457660000131
D表示障碍物距离。Specifically, the moving carrier terminal acquires the horizontal plane coordinate information corresponding to each three-dimensional point in the point cloud data of the contact line of the obstacle, including the horizontal coordinate information and the vertical coordinate information. Use the horizontal plane coordinate information corresponding to each three-dimensional point to calculate the distance, and obtain the distance of multiple points of obstacles. The motion carrier terminal can use the triangle hypotenuse calculation formula to calculate the point obstacle distance:
Figure BDA0003767457660000131
D represents the obstacle distance.

然后运动载体终端将各个点障碍物距离进行比较,将距离最短的点障碍物距离作为障碍物距离。Then the motion carrier terminal compares the distances of each point obstacle, and takes the point obstacle distance with the shortest distance as the obstacle distance.

然后运动载体以运动载体正前方作为0°,逆时针为正方向,根据障碍物距离对应的横向坐标信息和纵向坐标信息进行障碍物方位计算,得到障碍物相对于运动载体的位置方位。运动终端载体可以使用角度计算公式atan2(y,x)计算障碍物的位置。比如,计算得到的障碍物位置为+45°,表示障碍物在运动载体的左前方,障碍物位置为-45°,表示碍物在运动载体的右前方。Then the motion carrier takes the front of the motion carrier as 0°, and the counterclockwise direction is the positive direction, and calculates the obstacle azimuth according to the horizontal coordinate information and vertical coordinate information corresponding to the distance of the obstacle, and obtains the position and azimuth of the obstacle relative to the motion carrier. The motion terminal carrier can use the angle calculation formula atan2(y,x) to calculate the position of the obstacle. For example, the calculated obstacle position is +45°, which means that the obstacle is in front of the left of the motion carrier, and the obstacle position is -45°, which means that the obstacle is in front of the right side of the motion carrier.

本实施例中,通过计算各个三维点的点障碍物距离,并将距离最短的点障碍物距离作为障碍物距离,能够提高障碍物距离的准确性。In this embodiment, by calculating the point obstacle distance of each three-dimensional point, and using the point obstacle distance with the shortest distance as the obstacle distance, the accuracy of the obstacle distance can be improved.

在一个具体实施例中,如图7所示,提供一种障碍物距离检测的流程示意图;自动驾驶车辆在行驶过程中,车载终端从激光雷达中获取当前帧360度范围的原始点云数据,从6个相机中获取自动驾驶车辆周围360度的图像数据,对激光雷达和相机的进行内外参数标定。In a specific embodiment, as shown in FIG. 7 , a schematic flowchart of obstacle distance detection is provided; during the driving process of the autonomous vehicle, the on-board terminal obtains the original point cloud data in the 360-degree range of the current frame from the lidar, The 360-degree image data around the autonomous vehicle is obtained from 6 cameras, and the internal and external parameters of the lidar and camera are calibrated.

车载终端使用深度学习、传统几何算法等地面点分类算法在原始点云数据中查找出地面点,得到地面点云数据。然后按照粗分辨率,比如3米每个格子网格划分场景,对具有地面点云数据的网格计算该网格的平面方程。然后确定网格中地面点云数据缺失区域,即待填充区域,车载终端根据地面点云数据缺失区域最近的已有地面点云数据对缺失的地面点云数据进行估计,通过在该网格的x,y平面上以一定间隔,比如0.1,生成填充水平面坐标信息x和y,然后车载终端根据网格的填充水平面坐标信息x和y使用该网格对应的平面方程计算填充垂直坐标信息,得到填充地面点云数据,完成地面点云估计,从而得到目标地面点云区域。The vehicle terminal uses ground point classification algorithms such as deep learning and traditional geometric algorithms to find ground points in the original point cloud data, and obtain ground point cloud data. The scene is then divided into a grid of coarse resolution, such as 3 meters per grid, and the plane equation of the grid is calculated for the grid with ground point cloud data. Then determine the missing area of the ground point cloud data in the grid, that is, the area to be filled. The vehicle terminal estimates the missing ground point cloud data according to the nearest existing ground point cloud data in the missing area of the ground point cloud data. On the x and y planes, at a certain interval, such as 0.1, the filled horizontal coordinate information x and y are generated, and then the vehicle terminal calculates the filled vertical coordinate information according to the filled horizontal coordinate information x and y of the grid using the plane equation corresponding to the grid, and obtains Fill in the ground point cloud data, complete the ground point cloud estimation, and obtain the target ground point cloud area.

车载终端于YOLO,SSD,CenterNet等目标检测模型对图像采集设备采集的图像数据进行障碍物检测,包括车辆、行人、自行车、锥桶等交通参与障碍物目标,并通过检测模型输出障碍物与地面的接触线。The on-board terminal uses YOLO, SSD, CenterNet and other target detection models to detect obstacles on the image data collected by the image acquisition device, including vehicles, pedestrians, bicycles, cones and other traffic participating obstacle targets, and outputs obstacles and ground through the detection model. contact line.

车载终端将目标地面点云区域进行投影,得到地面点云投影区域,然后在地面点云投影区域中查找与障碍物接触线的坐标信息相同的目标投影坐标信息,得到障碍物投影接触线,并根据投影关系在目标地面点云区域查找到与障碍物投影接触线对应的障碍物接触线点云数据,根据障碍物接触线点云数据中的水平面坐标信息进行距离计算得到障碍物距离。车载终端可以根据障碍物距离重新规划行驶路线和行驶速度。The vehicle-mounted terminal projects the target ground point cloud area to obtain the ground point cloud projection area, and then searches the ground point cloud projection area for the target projection coordinate information that is the same as the coordinate information of the obstacle contact line, and obtains the obstacle projected contact line. According to the projection relationship, the obstacle contact line point cloud data corresponding to the obstacle projected contact line is found in the target ground point cloud area, and the obstacle distance is calculated according to the horizontal plane coordinate information in the obstacle contact line point cloud data. The vehicle terminal can re-plan the driving route and driving speed according to the obstacle distance.

应该理解的是,虽然如上所述的各实施例所涉及的流程图中的各个步骤按照箭头的指示依次显示,但是这些步骤并不是必然按照箭头指示的顺序依次执行。除非本文中有明确的说明,这些步骤的执行并没有严格的顺序限制,这些步骤可以以其它的顺序执行。而且,如上所述的各实施例所涉及的流程图中的至少一部分步骤可以包括多个步骤或者多个阶段,这些步骤或者阶段并不必然是在同一时刻执行完成,而是可以在不同的时刻执行,这些步骤或者阶段的执行顺序也不必然是依次进行,而是可以与其它步骤或者其它步骤中的步骤或者阶段的至少一部分轮流或者交替地执行。It should be understood that, although the steps in the flowcharts involved in the above embodiments are sequentially displayed according to the arrows, these steps are not necessarily executed in the order indicated by the arrows. Unless explicitly stated herein, the execution of these steps is not strictly limited to the order, and these steps may be performed in other orders. Moreover, at least a part of the steps in the flowcharts involved in the above embodiments may include multiple steps or multiple stages, and these steps or stages are not necessarily executed and completed at the same time, but may be performed at different times The execution order of these steps or phases is not necessarily sequential, but may be performed alternately or alternately with other steps or at least a part of the steps or phases in the other steps.

基于同样的发明构思,本申请实施例还提供了一种用于实现上述所涉及的障碍物距离检测方法的障碍物距离检测装置。该装置所提供的解决问题的实现方案与上述方法中所记载的实现方案相似,故下面所提供的一个或多个障碍物距离检测装置实施例中的具体限定可以参见上文中对于障碍物距离检测方法的限定,在此不再赘述。Based on the same inventive concept, an embodiment of the present application also provides an obstacle distance detection device for implementing the above-mentioned obstacle distance detection method. The implementation solution for solving the problem provided by the device is similar to the implementation solution described in the above method, so the specific limitations in the embodiments of one or more obstacle distance detection devices provided below can refer to the above for obstacle distance detection. The limitation of the method is not repeated here.

在一个实施例中,如图8所示,提供了一种障碍物距离检测装置800,包括:获取模块802、地面检测模块804、接触线检测模块806、投影模块808和计算模块810,其中:In one embodiment, as shown in FIG. 8, an obstacle distance detection device 800 is provided, including: an acquisition module 802, a ground detection module 804, a contact line detection module 806, a projection module 808 and a calculation module 810, wherein:

获取模块802,用于获取原始点云数据和原始点云数据对应的图像数据;an acquisition module 802, configured to acquire original point cloud data and image data corresponding to the original point cloud data;

地面检测模块804,用于基于原始点云数据进行地面点云检测,得到地面点云数据,基于地面点云数据生成目标地面点云区域;The ground detection module 804 is configured to perform ground point cloud detection based on the original point cloud data, obtain ground point cloud data, and generate a target ground point cloud area based on the ground point cloud data;

接触线检测模块806,用于基于图像数据进行障碍物与地面的接触线检测,得到障碍物接触线;The contact line detection module 806 is used to detect the contact line between the obstacle and the ground based on the image data to obtain the obstacle contact line;

投影模块808,用于基于目标地面点云区域进行投影,得到地面点云投影区域,在地面点云投影区域中确定障碍物接触线对应的障碍物投影接触线;The projection module 808 is used for projecting based on the target ground point cloud area, obtaining the ground point cloud projection area, and determining the obstacle projection contact line corresponding to the obstacle contact line in the ground point cloud projection area;

计算模块810,用于在目标地面点云区域中确定障碍物投影接触线对应的障碍物接触线点云数据,基于障碍物接触线点云数据中的水平面坐标信息进行距离计算,得到障碍物距离。The calculation module 810 is used to determine the obstacle contact line point cloud data corresponding to the obstacle projection contact line in the target ground point cloud area, and perform distance calculation based on the horizontal plane coordinate information in the obstacle contact line point cloud data to obtain the obstacle distance. .

在一个实施例中,障碍物距离检测装置800,还包括:In one embodiment, the obstacle distance detection device 800 further includes:

目标障碍物距离计算单元,用于获取障碍物接触线点云数据对应的垂直坐标信息和障碍物接触线对应的坐标信息;基于垂直坐标信息和坐标信息进行点云坐标计算,得到障碍物接触线点云数据对应的目标水平面坐标信息;基于目标水平面坐标信息进行距离计算,得到目标障碍物距离。The target obstacle distance calculation unit is used to obtain the vertical coordinate information corresponding to the point cloud data of the obstacle contact line and the coordinate information corresponding to the obstacle contact line; based on the vertical coordinate information and coordinate information, the point cloud coordinate calculation is performed to obtain the obstacle contact line The target horizontal plane coordinate information corresponding to the point cloud data; the distance calculation is performed based on the target horizontal plane coordinate information to obtain the target obstacle distance.

在一个实施例中,地面检测模块804,包括:In one embodiment, the ground detection module 804 includes:

区域划分单元,用于基于预设划分规格对地面点云数据进行划分,得到地面点云划分区域,地面点云划分区域包括地面点云区域和待填充区域;基于地面点云区域中的区域地面点云数据生成待填充区域对应的填充地面点云数据,基于区域地面点云数据和填充地面点云数据生成目标地面点云区域。The area division unit is used to divide the ground point cloud data based on the preset division specifications to obtain the ground point cloud division area, and the ground point cloud division area includes the ground point cloud area and the area to be filled; based on the area ground in the ground point cloud area The point cloud data generates the filled ground point cloud data corresponding to the area to be filled, and the target ground point cloud area is generated based on the regional ground point cloud data and the filled ground point cloud data.

在一个实施例中,地面检测模块804,包括:In one embodiment, the ground detection module 804 includes:

填充点云单元,用于基于区域地面点云数据建立区域点云坐标关系;获取区域地面点云数据对应的区域水平面坐标信息,基于区域水平面坐标信息和预设水平面坐标间隔信息计算待填充区域对应的填充水平面坐标信息;基于填充平面坐标信息按照区域点云坐标关系进行计算,得到待填充区域对应的填充垂直坐标信息;基于填充水平面坐标信息和填充垂直坐标信息生成待填充区域对应的填充地面点云数据。The filling point cloud unit is used to establish the regional point cloud coordinate relationship based on the regional ground point cloud data; obtain the regional horizontal plane coordinate information corresponding to the regional ground point cloud data, and calculate the corresponding area to be filled based on the regional horizontal plane coordinate information and the preset horizontal plane coordinate interval information. Filling horizontal plane coordinate information; based on the filling plane coordinate information, calculate according to the regional point cloud coordinate relationship to obtain the filling vertical coordinate information corresponding to the area to be filled; based on the filling horizontal plane coordinate information and filling vertical coordinate information, generate the filling ground point corresponding to the area to be filled cloud data.

在一个实施例中,投影模块808,包括:In one embodiment, the projection module 808 includes:

坐标投影单元,用于基于障碍物接触线对应的接触线坐标信息在地面点云投影区域中查找与接触线坐标信息相同的投影坐标信息,得到目标投影坐标信息;基于目标投影坐标信息得到障碍物投影接触线。The coordinate projection unit is used to search for the same projection coordinate information as the contact line coordinate information in the ground point cloud projection area based on the contact line coordinate information corresponding to the obstacle contact line, and obtain the target projection coordinate information; obtain the obstacle based on the target projection coordinate information Projected contact lines.

在一个实施例中,计算模块810,包括:In one embodiment, the computing module 810 includes:

距离计算单元,用于获取障碍物接触线点云数据中各个三维点对应的水平面坐标信息;基于各个三维点对应的水平面坐标信息分别进行距离计算,得到各个三维点对应的点障碍物距离;将各个三维点对应的点障碍物距离中最短的点障碍物距离作为障碍物距离。The distance calculation unit is used to obtain the horizontal plane coordinate information corresponding to each three-dimensional point in the point cloud data of the obstacle contact line; based on the horizontal plane coordinate information corresponding to each three-dimensional point, the distance calculation is performed respectively to obtain the point obstacle distance corresponding to each three-dimensional point; The shortest point obstacle distance among the point obstacle distances corresponding to each 3D point is taken as the obstacle distance.

上述障碍物距离检测装置中的各个模块可全部或部分通过软件、硬件及其组合来实现。上述各模块可以硬件形式内嵌于或独立于计算机设备中的处理器中,也可以以软件形式存储于计算机设备中的存储器中,以便于处理器调用执行以上各个模块对应的操作。Each module in the above-mentioned obstacle distance detection device can be implemented in whole or in part by software, hardware and combinations thereof. The above modules can be embedded in or independent of the processor in the computer device in the form of hardware, or stored in the memory in the computer device in the form of software, so that the processor can call and execute the operations corresponding to the above modules.

在一个实施例中,提供了一种计算机设备,该计算机设备可以是服务器,其内部结构图可以如图9所示。该计算机设备包括处理器、存储器、输入/输出接口(Input/Output,简称I/O)和通信接口。其中,处理器、存储器和输入/输出接口通过系统总线连接,通信接口通过输入/输出接口连接到系统总线。其中,该计算机设备的处理器用于提供计算和控制能力。该计算机设备的存储器包括非易失性存储介质和内存储器。该非易失性存储介质存储有操作系统、计算机程序和数据库。该内存储器为非易失性存储介质中的操作系统和计算机程序的运行提供环境。该计算机设备的数据库用于存储原始点云数据、图像数据。该计算机设备的输入/输出接口用于处理器与外部设备之间交换信息。该计算机设备的通信接口用于与外部的终端通过网络连接通信。该计算机程序被处理器执行时以实现一种障碍物距离检测方法。In one embodiment, a computer device is provided, and the computer device may be a server, and its internal structure diagram may be as shown in FIG. 9 . The computer device includes a processor, a memory, an input/output interface (Input/Output, I/O for short) and a communication interface. Wherein, the processor, the memory and the input/output interface are connected through the system bus, and the communication interface is connected to the system bus through the input/output interface. Among them, the processor of the computer device is used to provide computing and control capabilities. The memory of the computer device includes non-volatile storage media and internal memory. The nonvolatile storage medium stores an operating system, a computer program, and a database. The internal memory provides an environment for the execution of the operating system and computer programs in the non-volatile storage medium. The database of the computer device is used for storing raw point cloud data and image data. The input/output interface of the computer device is used to exchange information between the processor and external devices. The communication interface of the computer device is used to communicate with an external terminal through a network connection. The computer program implements an obstacle distance detection method when executed by the processor.

在一个实施例中,提供了一种计算机设备,该计算机设备可以是终端,其内部结构图可以如图10所示。该计算机设备包括处理器、存储器、输入/输出接口、通信接口、显示单元和输入装置。其中,处理器、存储器和输入/输出接口通过系统总线连接,通信接口、显示单元和输入装置通过输入/输出接口连接到系统总线。其中,该计算机设备的处理器用于提供计算和控制能力。该计算机设备的存储器包括非易失性存储介质、内存储器。该非易失性存储介质存储有操作系统和计算机程序。该内存储器为非易失性存储介质中的操作系统和计算机程序的运行提供环境。该计算机设备的输入/输出接口用于处理器与外部设备之间交换信息。该计算机设备的通信接口用于与外部的终端进行有线或无线方式的通信,无线方式可通过WIFI、移动蜂窝网络、NFC(近场通信)或其他技术实现。该计算机程序被处理器执行时以实现一种障碍物距离检测方法。该计算机设备的显示单元用于形成视觉可见的画面,可以是显示屏、投影装置或虚拟现实成像装置,显示屏可以是液晶显示屏或电子墨水显示屏,该计算机设备的输入装置可以是显示屏上覆盖的触摸层,也可以是计算机设备外壳上设置的按键、轨迹球或触控板,还可以是外接的键盘、触控板或鼠标等。In one embodiment, a computer device is provided, and the computer device may be a terminal, and its internal structure diagram may be as shown in FIG. 10 . The computer device includes a processor, a memory, an input/output interface, a communication interface, a display unit, and an input device. Wherein, the processor, the memory and the input/output interface are connected through the system bus, and the communication interface, the display unit and the input device are connected to the system bus through the input/output interface. Among them, the processor of the computer device is used to provide computing and control capabilities. The memory of the computer device includes a non-volatile storage medium, an internal memory. The nonvolatile storage medium stores an operating system and a computer program. The internal memory provides an environment for the execution of the operating system and computer programs in the non-volatile storage medium. The input/output interface of the computer device is used to exchange information between the processor and external devices. The communication interface of the computer equipment is used for wired or wireless communication with an external terminal, and the wireless communication can be realized by WIFI, mobile cellular network, NFC (Near Field Communication) or other technologies. The computer program implements an obstacle distance detection method when executed by a processor. The display unit of the computer equipment is used to form a visually visible picture, which can be a display screen, a projection device or a virtual reality imaging device, the display screen can be a liquid crystal display screen or an electronic ink display screen, and the input device of the computer equipment can be a display screen The touch layer covered on the top may also be keys, trackballs or touchpads provided on the casing of the computer equipment, and may also be an external keyboard, touchpad or mouse.

本领域技术人员可以理解,图9-10中示出的结构,仅仅是与本申请方案相关的部分结构的框图,并不构成对本申请方案所应用于其上的计算机设备的限定,具体的计算机设备可以包括比图中所示更多或更少的部件,或者组合某些部件,或者具有不同的部件布置。Those skilled in the art can understand that the structures shown in FIGS. 9-10 are only block diagrams of partial structures related to the solution of the present application, and do not constitute a limitation on the computer equipment to which the solution of the present application is applied. A device may include more or fewer components than shown in the figures, or combine certain components, or have a different arrangement of components.

在一个实施例中,还提供了一种计算机设备,包括存储器和处理器,存储器中存储有计算机程序,该处理器执行计算机程序时实现上述各方法实施例中的步骤。In one embodiment, a computer device is also provided, including a memory and a processor, where a computer program is stored in the memory, and the processor implements the steps in the foregoing method embodiments when the processor executes the computer program.

在一个实施例中,提供了一种计算机可读存储介质,其上存储有计算机程序,该计算机程序被处理器执行时实现上述各方法实施例中的步骤。In one embodiment, a computer-readable storage medium is provided, on which a computer program is stored, and when the computer program is executed by a processor, implements the steps in the foregoing method embodiments.

在一个实施例中,提供了一种计算机程序产品,包括计算机程序,该计算机程序被处理器执行时实现上述各方法实施例中的步骤。In one embodiment, a computer program product is provided, including a computer program, which implements the steps in each of the foregoing method embodiments when the computer program is executed by a processor.

需要说明的是,本申请所涉及的用户信息(包括但不限于用户设备信息、用户个人信息等)和数据(包括但不限于用于分析的数据、存储的数据、展示的数据等),均为经用户授权或者经过各方充分授权的信息和数据,且相关数据的收集、使用和处理需要遵守相关国家和地区的相关法律法规和标准。It should be noted that the user information (including but not limited to user equipment information, user personal information, etc.) and data (including but not limited to data for analysis, stored data, displayed data, etc.) involved in this application are all It is the information and data authorized by the user or fully authorized by all parties, and the collection, use and processing of the relevant data need to comply with the relevant laws, regulations and standards of the relevant countries and regions.

本领域普通技术人员可以理解实现上述实施例方法中的全部或部分流程,是可以通过计算机程序来指令相关的硬件来完成,所述的计算机程序可存储于一非易失性计算机可读取存储介质中,该计算机程序在执行时,可包括如上述各方法的实施例的流程。其中,本申请所提供的各实施例中所使用的对存储器、数据库或其它介质的任何引用,均可包括非易失性和易失性存储器中的至少一种。非易失性存储器可包括只读存储器(Read-OnlyMemory,ROM)、磁带、软盘、闪存、光存储器、高密度嵌入式非易失性存储器、阻变存储器(ReRAM)、磁变存储器(Magnetoresistive Random Access Memory,MRAM)、铁电存储器(Ferroelectric Random Access Memory,FRAM)、相变存储器(Phase Change Memory,PCM)、石墨烯存储器等。易失性存储器可包括随机存取存储器(Random Access Memory,RAM)或外部高速缓冲存储器等。作为说明而非局限,RAM可以是多种形式,比如静态随机存取存储器(Static Random Access Memory,SRAM)或动态随机存取存储器(Dynamic RandomAccess Memory,DRAM)等。本申请所提供的各实施例中所涉及的数据库可包括关系型数据库和非关系型数据库中至少一种。非关系型数据库可包括基于区块链的分布式数据库等,不限于此。本申请所提供的各实施例中所涉及的处理器可为通用处理器、中央处理器、图形处理器、数字信号处理器、可编程逻辑器、基于量子计算的数据处理逻辑器等,不限于此。Those of ordinary skill in the art can understand that all or part of the processes in the methods of the above embodiments can be implemented by instructing relevant hardware through a computer program, and the computer program can be stored in a non-volatile computer-readable storage In the medium, when the computer program is executed, it may include the processes of the above-mentioned method embodiments. Wherein, any reference to a memory, a database or other media used in the various embodiments provided in this application may include at least one of a non-volatile memory and a volatile memory. Non-volatile memory may include Read-Only Memory (ROM), magnetic tape, floppy disk, flash memory, optical memory, high-density embedded non-volatile memory, resistive memory (ReRAM), magnetic variable memory (Magnetoresistive Random Memory) Access Memory, MRAM), Ferroelectric Random Access Memory (FRAM), Phase Change Memory (Phase Change Memory, PCM), graphene memory, etc. Volatile memory may include random access memory (Random Access Memory, RAM) or external cache memory, and the like. By way of illustration and not limitation, the RAM may be in various forms, such as static random access memory (Static Random Access Memory, SRAM) or dynamic random access memory (Dynamic Random Access Memory, DRAM). The database involved in the various embodiments provided in this application may include at least one of a relational database and a non-relational database. The non-relational database may include a blockchain-based distributed database, etc., but is not limited thereto. The processors involved in the various embodiments provided in this application may be general-purpose processors, central processing units, graphics processors, digital signal processors, programmable logic devices, data processing logic devices based on quantum computing, etc., and are not limited to this.

以上实施例的各技术特征可以进行任意的组合,为使描述简洁,未对上述实施例中的各个技术特征所有可能的组合都进行描述,然而,只要这些技术特征的组合不存在矛盾,都应当认为是本说明书记载的范围。The technical features of the above embodiments can be combined arbitrarily. In order to make the description simple, all possible combinations of the technical features in the above embodiments are not described. However, as long as there is no contradiction in the combination of these technical features It is considered to be the range described in this specification.

以上所述实施例仅表达了本申请的几种实施方式,其描述较为具体和详细,但并不能因此而理解为对本申请专利范围的限制。应当指出的是,对于本领域的普通技术人员来说,在不脱离本申请构思的前提下,还可以做出若干变形和改进,这些都属于本申请的保护范围。因此,本申请的保护范围应以所附权利要求为准。The above-mentioned embodiments only represent several embodiments of the present application, and the descriptions thereof are relatively specific and detailed, but should not be construed as a limitation on the scope of the patent of the present application. It should be pointed out that for those skilled in the art, without departing from the concept of the present application, several modifications and improvements can be made, which all belong to the protection scope of the present application. Therefore, the scope of protection of the present application should be determined by the appended claims.

Claims (10)

1.一种障碍物距离检测方法,其特征在于,所述方法包括:1. an obstacle distance detection method, is characterized in that, described method comprises: 获取原始点云数据和所述原始点云数据对应的图像数据;obtaining original point cloud data and image data corresponding to the original point cloud data; 基于所述原始点云数据进行地面点云检测,得到地面点云数据,基于所述地面点云数据生成目标地面点云区域;Perform ground point cloud detection based on the original point cloud data, obtain ground point cloud data, and generate a target ground point cloud area based on the ground point cloud data; 基于所述图像数据进行障碍物与地面的接触线检测,得到障碍物接触线;Detecting the contact line between the obstacle and the ground based on the image data to obtain the obstacle contact line; 基于所述目标地面点云区域进行投影,得到地面点云投影区域,在所述地面点云投影区域中确定所述障碍物接触线对应的障碍物投影接触线;Perform projection based on the target ground point cloud area to obtain a ground point cloud projection area, and determine the obstacle projection contact line corresponding to the obstacle contact line in the ground point cloud projection area; 在所述目标地面点云区域中确定所述障碍物投影接触线对应的障碍物接触线点云数据,基于所述障碍物接触线点云数据中的水平面坐标信息进行距离计算,得到障碍物距离。Determine the obstacle contact line point cloud data corresponding to the obstacle projected contact line in the target ground point cloud area, and perform distance calculation based on the horizontal plane coordinate information in the obstacle contact line point cloud data to obtain the obstacle distance . 2.根据权利要求1所述的方法,其特征在于,所述方法,还包括:2. The method according to claim 1, wherein the method further comprises: 获取所述障碍物接触线点云数据对应的垂直坐标信息和所述障碍物接触线对应的坐标信息;acquiring the vertical coordinate information corresponding to the point cloud data of the obstacle contact line and the coordinate information corresponding to the obstacle contact line; 基于所述垂直坐标信息和所述坐标信息进行点云坐标计算,得到所述障碍物接触线点云数据对应的目标水平面坐标信息;Perform point cloud coordinate calculation based on the vertical coordinate information and the coordinate information to obtain the target horizontal plane coordinate information corresponding to the obstacle contact line point cloud data; 基于所述目标水平面坐标信息进行距离计算,得到目标障碍物距离。The distance calculation is performed based on the coordinate information of the target horizontal plane to obtain the target obstacle distance. 3.根据权利要求1所述的方法,其特征在于,所述基于所述地面点云数据生成目标地面点云区域,包括:3. The method according to claim 1, wherein the generating a target ground point cloud area based on the ground point cloud data comprises: 基于预设划分规格对所述地面点云数据进行划分,得到地面点云划分区域,所述地面点云划分区域包括地面点云区域和待填充区域;Divide the ground point cloud data based on a preset division specification to obtain a ground point cloud division area, where the ground point cloud division area includes a ground point cloud area and a to-be-filled area; 基于所述地面点云区域中的区域地面点云数据生成所述待填充区域对应的填充地面点云数据,基于所述区域地面点云数据和所述填充地面点云数据生成所述目标地面点云区域。The filled ground point cloud data corresponding to the to-be-filled area is generated based on the regional ground point cloud data in the ground point cloud area, and the target ground point is generated based on the regional ground point cloud data and the filled ground point cloud data cloud area. 4.根据权利要求3所述的方法,其特征在于,所述基于所述地面点云区域中的区域地面点云数据生成所述待填充区域对应的填充地面点云数据,包括:4. The method according to claim 3, wherein generating the filled ground point cloud data corresponding to the to-be-filled area based on the regional ground point cloud data in the ground point cloud area comprises: 基于所述区域地面点云数据建立区域点云坐标关系;Establish a regional point cloud coordinate relationship based on the regional ground point cloud data; 获取所述区域地面点云数据对应的区域水平面坐标信息,基于所述区域水平面坐标信息和预设水平面坐标间隔信息计算所述待填充区域对应的填充水平面坐标信息;Obtaining the regional horizontal plane coordinate information corresponding to the regional ground point cloud data, and calculating the filling horizontal plane coordinate information corresponding to the to-be-filled area based on the regional horizontal plane coordinate information and the preset horizontal plane coordinate interval information; 基于所述填充平面坐标信息按照所述区域点云坐标关系进行计算,得到所述待填充区域对应的填充垂直坐标信息;Calculate based on the coordinate information of the filling plane according to the coordinate relationship of the point cloud of the area, and obtain the filling vertical coordinate information corresponding to the area to be filled; 基于所述填充水平面坐标信息和所述填充垂直坐标信息生成所述待填充区域对应的填充地面点云数据。The filled ground point cloud data corresponding to the area to be filled is generated based on the filled horizontal coordinate information and the filled vertical coordinate information. 5.根据权利要求1所述的方法,其特征在于,所述在所述地面点云投影区域中确定所述障碍物接触线对应的障碍物投影接触线,包括:5 . The method according to claim 1 , wherein the determining the obstacle projection contact line corresponding to the obstacle contact line in the ground point cloud projection area comprises: 5 . 基于所述障碍物接触线对应的接触线坐标信息在所述地面点云投影区域中查找与所述接触线坐标信息相同的投影坐标信息,得到目标投影坐标信息;Based on the contact line coordinate information corresponding to the obstacle contact line, search for the same projection coordinate information as the contact line coordinate information in the ground point cloud projection area to obtain target projection coordinate information; 基于所述目标投影坐标信息得到所述障碍物投影接触线。The obstacle projected contact line is obtained based on the target projected coordinate information. 6.根据权利要求1所述的方法,其特征在于,所述基于所述障碍物接触线点云数据中的水平面坐标信息进行距离计算,得到障碍物距离,包括:6. The method according to claim 1, wherein the distance calculation is performed based on the horizontal plane coordinate information in the point cloud data of the obstacle contact line to obtain the obstacle distance, comprising: 获取所述障碍物接触线点云数据中各个三维点对应的水平面坐标信息;Obtaining the horizontal plane coordinate information corresponding to each three-dimensional point in the point cloud data of the obstacle contact line; 基于所述各个三维点对应的水平面坐标信息分别进行距离计算,得到所述各个三维点对应的点障碍物距离;Based on the horizontal plane coordinate information corresponding to each of the three-dimensional points, distance calculation is performed to obtain the point obstacle distance corresponding to each of the three-dimensional points; 将所述各个三维点对应的点障碍物距离中最短的点障碍物距离作为所述障碍物距离。The shortest point obstacle distance among the point obstacle distances corresponding to the three-dimensional points is used as the obstacle distance. 7.一种障碍物距离检测装置,其特征在于,所述装置包括:7. An obstacle distance detection device, wherein the device comprises: 获取模块,用于获取原始点云数据和所述原始点云数据对应的图像数据;an acquisition module for acquiring original point cloud data and image data corresponding to the original point cloud data; 地面检测模块,用于基于所述原始点云数据进行地面点云检测,得到地面点云数据,基于所述地面点云数据生成目标地面点云区域;a ground detection module, configured to perform ground point cloud detection based on the original point cloud data, obtain ground point cloud data, and generate a target ground point cloud area based on the ground point cloud data; 接触线检测模块,用于基于所述图像数据进行障碍物与地面的接触线检测,得到障碍物接触线;a contact line detection module for detecting the contact line between the obstacle and the ground based on the image data to obtain the obstacle contact line; 投影模块,用于基于所述目标地面点云区域进行投影,得到地面点云投影区域,在所述地面点云投影区域中确定所述障碍物接触线对应的障碍物投影接触线;a projection module, configured to perform projection based on the target ground point cloud area to obtain a ground point cloud projection area, and determine the obstacle projection contact line corresponding to the obstacle contact line in the ground point cloud projection area; 计算模块,用于在所述目标地面点云区域中确定所述障碍物投影接触线对应的障碍物接触线点云数据,基于所述障碍物接触线点云数据中的水平面坐标信息进行距离计算,得到障碍物距离。A computing module, configured to determine the obstacle contact line point cloud data corresponding to the obstacle projection contact line in the target ground point cloud area, and perform distance calculation based on the horizontal plane coordinate information in the obstacle contact line point cloud data , get the obstacle distance. 8.一种计算机设备,包括存储器和处理器,所述存储器存储有计算机程序,其特征在于,所述处理器执行所述计算机程序时实现权利要求1至6中任一项所述的方法的步骤。8. A computer device, comprising a memory and a processor, wherein the memory stores a computer program, wherein the processor implements the method according to any one of claims 1 to 6 when the processor executes the computer program. step. 9.一种计算机可读存储介质,其上存储有计算机程序,其特征在于,所述计算机程序被处理器执行时实现权利要求1至6中任一项所述的方法的步骤。9. A computer-readable storage medium on which a computer program is stored, characterized in that, when the computer program is executed by a processor, the steps of the method according to any one of claims 1 to 6 are implemented. 10.一种计算机程序产品,包括计算机程序,其特征在于,该计算机程序被处理器执行时实现权利要求1至6中任一项所述的方法的步骤。10. A computer program product comprising a computer program, characterized in that the computer program implements the steps of the method according to any one of claims 1 to 6 when the computer program is executed by a processor.
CN202210890678.6A 2022-07-27 2022-07-27 Obstacle distance detection method, device, computer equipment and storage medium Pending CN115222815A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN202210890678.6A CN115222815A (en) 2022-07-27 2022-07-27 Obstacle distance detection method, device, computer equipment and storage medium

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN202210890678.6A CN115222815A (en) 2022-07-27 2022-07-27 Obstacle distance detection method, device, computer equipment and storage medium

Publications (1)

Publication Number Publication Date
CN115222815A true CN115222815A (en) 2022-10-21

Family

ID=83613226

Family Applications (1)

Application Number Title Priority Date Filing Date
CN202210890678.6A Pending CN115222815A (en) 2022-07-27 2022-07-27 Obstacle distance detection method, device, computer equipment and storage medium

Country Status (1)

Country Link
CN (1) CN115222815A (en)

Cited By (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN116993879A (en) * 2023-07-03 2023-11-03 广州极点三维信息科技有限公司 Method for automatically avoiding obstacle and distributing light, electronic equipment and storage medium

Citations (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN109472831A (en) * 2018-11-19 2019-03-15 东南大学 Obstacle identification and ranging system and method for road roller construction process
CN110673632A (en) * 2019-09-27 2020-01-10 中国船舶重工集团公司第七0九研究所 Unmanned aerial vehicle autonomous obstacle avoidance method and device based on visual SLAM
CN113759385A (en) * 2021-08-12 2021-12-07 江苏徐工工程机械研究院有限公司 A lidar and camera fusion ranging method and system
CN114359744A (en) * 2021-12-07 2022-04-15 中山大学 Depth estimation method based on fusion of laser radar and event camera

Patent Citations (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN109472831A (en) * 2018-11-19 2019-03-15 东南大学 Obstacle identification and ranging system and method for road roller construction process
CN110673632A (en) * 2019-09-27 2020-01-10 中国船舶重工集团公司第七0九研究所 Unmanned aerial vehicle autonomous obstacle avoidance method and device based on visual SLAM
CN113759385A (en) * 2021-08-12 2021-12-07 江苏徐工工程机械研究院有限公司 A lidar and camera fusion ranging method and system
CN114359744A (en) * 2021-12-07 2022-04-15 中山大学 Depth estimation method based on fusion of laser radar and event camera

Cited By (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN116993879A (en) * 2023-07-03 2023-11-03 广州极点三维信息科技有限公司 Method for automatically avoiding obstacle and distributing light, electronic equipment and storage medium
CN116993879B (en) * 2023-07-03 2024-03-12 广州极点三维信息科技有限公司 Method for automatically avoiding obstacle and distributing light, electronic equipment and storage medium

Similar Documents

Publication Publication Date Title
KR102896237B1 (en) Method and apparatus for calculating depth map
KR102126724B1 (en) Method and apparatus for restoring point cloud data
US12260575B2 (en) Scale-aware monocular localization and mapping
CN114217665B (en) Method and device for synchronizing time of camera and laser radar and storage medium
JP6031554B2 (en) Obstacle detection method and apparatus based on monocular camera
US10086955B2 (en) Pattern-based camera pose estimation system
CN110059608A (en) A kind of object detecting method, device, electronic equipment and storage medium
CN114298982B (en) Image annotation method and device, computer equipment and storage medium
KR102295809B1 (en) Apparatus for acquisition distance for all directions of vehicle
US10451403B2 (en) Structure-based camera pose estimation system
CN106940704A (en) A kind of localization method and device based on grating map
US9858669B2 (en) Optimized camera pose estimation system
Tao et al. Stereo priori RCNN based car detection on point level for autonomous driving
CN105705903A (en) 3D-shape measurement device, 3D-shape measurement method, and 3D-shape measurement program
CN117726747A (en) Three-dimensional reconstruction method, device, storage medium and equipment for complementing weak texture scene
US11842440B2 (en) Landmark location reconstruction in autonomous machine applications
CN108829116A (en) Barrier-avoiding method and equipment based on monocular cam
WO2023283929A1 (en) Method and apparatus for calibrating external parameters of binocular camera
CN111080682A (en) Method and device for registration of point cloud data
CN114663598A (en) Three-dimensional modeling method, device and storage medium
CN112836698A (en) A positioning method, device, storage medium and electronic device
CN114494589A (en) Three-dimensional reconstruction method, three-dimensional reconstruction device, electronic equipment and computer-readable storage medium
CN118675023A (en) Vehicle-road cooperative sensing method, device, equipment, storage medium and program product
CN114648639B (en) Target vehicle detection method, system and device
CN114913500B (en) Pose determination method and device, computer equipment and storage medium

Legal Events

Date Code Title Description
PB01 Publication
PB01 Publication
SE01 Entry into force of request for substantive examination
SE01 Entry into force of request for substantive examination