TWI838022B - Ground plane fitting method, vehicle-mounted device, and storage medium - Google Patents

Ground plane fitting method, vehicle-mounted device, and storage medium Download PDF

Info

Publication number
TWI838022B
TWI838022B TW111148798A TW111148798A TWI838022B TW I838022 B TWI838022 B TW I838022B TW 111148798 A TW111148798 A TW 111148798A TW 111148798 A TW111148798 A TW 111148798A TW I838022 B TWI838022 B TW I838022B
Authority
TW
Taiwan
Prior art keywords
ground
camera
ground plane
target image
vehicle
Prior art date
Application number
TW111148798A
Other languages
Chinese (zh)
Inventor
楊榮浩
郭錦斌
盧志德
Original Assignee
鴻海精密工業股份有限公司
Filing date
Publication date
Application filed by 鴻海精密工業股份有限公司 filed Critical 鴻海精密工業股份有限公司
Application granted granted Critical
Publication of TWI838022B publication Critical patent/TWI838022B/en

Links

Images

Abstract

The present application provides a ground plane fitting method, a vehicle-mounted device, and a storage medium. The method includes: obtaining point clouds and a target image towards a travelling direction of a vehicle, based on the point clouds and the target image; determining a geographic point cloud set corresponding to the target image; correcting a plurality of normal vectors of a camera that obtains the target image, and obtaining a plurality of ground normal vectors; according to the geographic point cloud set and the ground normal vectors, fitting a ground plane of the travelling direction of the vehicle and obtaining a fitting ground plane. This application can improve the fitting accuracy of the ground plane based on the image processing, and realize the safe driving of auxiliary autonomous vehicle.

Description

地面平面擬合方法、車載裝置及儲存介質 Ground plane fitting method, vehicle-mounted device and storage medium

本發明涉及安全駕駛技術領域,特別是指一種地面平面擬合方法、車載裝置及儲存介質。 The present invention relates to the field of safe driving technology, and in particular to a ground plane fitting method, a vehicle-mounted device, and a storage medium.

在自動駕駛技術中,對車輛前方的地面進行平面擬合是不可缺少的一部分。可以根據擬合得到的地面平面控制自動駕駛車輛的行駛,例如當地面平面指示前方地面為下坡且坡度較大時,控制自動駕駛車輛減速行駛。現有的地面平面擬合方法中存在著擬合精度不高等問題。 In the autonomous driving technology, plane fitting of the ground in front of the vehicle is an indispensable part. The driving of the autonomous vehicle can be controlled according to the fitted ground plane. For example, when the ground plane indicates that the ground in front is downhill and the slope is large, the autonomous vehicle is controlled to slow down. The existing ground plane fitting method has problems such as low fitting accuracy.

鑒於以上內容,有必要提供一種地面平面擬合方法、車載裝置及儲存介質,能夠有效提高擬合地面平面的精度,輔助車輛進行安全駕駛。 In view of the above, it is necessary to provide a ground plane fitting method, a vehicle-mounted device and a storage medium that can effectively improve the accuracy of fitting the ground plane and assist the vehicle in safe driving.

所述地面平面擬合方法包括:基於獲取的車輛行進方向的點雲與目標圖像,確定所述目標圖像對應的地面點雲集合;對獲取所述目標圖像的相機的多個相機法向量進行校正,獲得多個地面法向量;根據所述地面點雲集合與所述多個地面法向量,對所述車輛行進方向的地面平面進行擬合,得到擬合地面平面。 The ground plane fitting method includes: determining a ground point cloud set corresponding to the target image based on the point cloud and target image obtained in the direction of vehicle travel; correcting multiple camera normal vectors of the camera that obtains the target image to obtain multiple ground normal vectors; fitting the ground plane in the direction of vehicle travel according to the ground point cloud set and the multiple ground normal vectors to obtain a fitting ground plane.

可選地,所述基於獲取的車輛行進方向的點雲與目標圖像,確定所述目標圖像對應的地面點雲集合,包括:確定所述目標圖像中的地面區域;將所述點雲投影至所述目標圖像,將所述地面區域對應的點雲的集合 作為所述地面點雲集合。 Optionally, the method of determining a ground point cloud set corresponding to the target image based on the obtained point cloud of the vehicle's travel direction and the target image includes: determining a ground area in the target image; projecting the point cloud to the target image, and taking a set of point clouds corresponding to the ground area as the ground point cloud set.

可選地,所述確定所述目標圖像中的地面區域包括:利用語義分割演算法識別所述目標圖像中的所述地面區域。 Optionally, determining the ground area in the target image includes: identifying the ground area in the target image using a semantic segmentation algorithm.

可選地,所述對獲取所述目標圖像的相機的多個相機法向量進行校正,獲得多個地面法向量,包括:獲取所述相機的包含時間戳記的多個相機法向量;獲取所述相機的移動資料,利用所述移動資料對所述多個相機法向量進行校正,得到所述多個地面法向量。 Optionally, the step of correcting multiple camera normal vectors of a camera that obtains the target image to obtain multiple ground normal vectors includes: obtaining multiple camera normal vectors of the camera including a timestamp; obtaining motion data of the camera, and correcting the multiple camera normal vectors using the motion data to obtain the multiple ground normal vectors.

可選地,所述獲取所述相機的包含時間戳記的多個相機法向量包括:將所述相機的相機座標系中指向天空的座標軸作為所述相機法向量。 Optionally, the step of obtaining multiple camera normal vectors containing time stamps of the camera includes: using the coordinate axis pointing to the sky in the camera coordinate system of the camera as the camera normal vector.

可選地,所述方法還包括:獲取所述相機拍攝的多張圖像,所述多張圖像包括所述目標圖像,且所述多張圖像中的每張圖像對應一個時間戳記;獲取每張圖像對應的相機座標系。 Optionally, the method further includes: obtaining multiple images taken by the camera, the multiple images including the target image, and each image in the multiple images corresponds to a timestamp; obtaining a camera coordinate system corresponding to each image.

可選地,所述相機的移動資料包括重力加速度;所述利用所述移動資料對所述多個相機法向量進行校正,得到所述多個地面法向量,包括:利用所述重力加速度的方向校正所述相機的相機位姿中的旋轉矩陣,將所述相機法向量校正為所述地面法向量。 Optionally, the movement data of the camera includes gravity acceleration; the use of the movement data to correct the multiple camera normal vectors to obtain the multiple ground normal vectors includes: using the direction of the gravity acceleration to correct the rotation matrix in the camera posture of the camera, and correcting the camera normal vector to the ground normal vector.

可選地,所述根據所述地面點雲集合與所述多個地面法向量,對所述車輛行進方向的地面平面進行擬合,得到擬合地面平面,包括:將所述地面點雲集合與所述多個地面法向量作為擬和地面平面方程的約束條件,基於所述約束條件使用最小二乘法擬合得到所述地面對應的所述地面平面。 Optionally, fitting the ground plane in the direction of travel of the vehicle according to the ground point cloud set and the multiple ground normal vectors to obtain a fitted ground plane includes: using the ground point cloud set and the multiple ground normal vectors as constraints for fitting a ground plane equation, and fitting the ground plane corresponding to the ground using the least squares method based on the constraints.

所述電腦可讀儲存介質儲存有至少一個指令,所述至少一個指令被處理器執行時實現所述地面平面擬合方法或所述地面平面擬合方法。 The computer-readable storage medium stores at least one instruction, and when the at least one instruction is executed by the processor, the ground plane fitting method or the ground plane fitting method is implemented.

所述車載裝置包括儲存器和至少一個處理器,所述儲存器中儲存有至少一個指令,所述至少一個指令被所述至少一個處理器執行時實現所述地面平面擬合方法。 The vehicle-mounted device includes a memory and at least one processor, wherein at least one instruction is stored in the memory, and when the at least one instruction is executed by the at least one processor, the ground plane fitting method is implemented.

相較於習知技術,本申請實施例提供的地面平面擬合方法,根據車輛行進方向的點雲與目標圖像確定目標圖像對應的地面點雲集合;對獲取所述目標圖像的相機的多個相機法向量進行校正,獲得多個地面法向量;根據所述地面點雲集合與所述多個地面法向量,對所述車輛行進方向的地面平面進行擬合,得到擬合地面平面,能夠提高獲得的地面法向量的精度,從而有效提高擬合地面平面的精度,輔助自動駕駛車輛的安全駕駛。 Compared with the prior art, the ground plane fitting method provided in the embodiment of the present application determines the ground point cloud set corresponding to the target image according to the point cloud of the vehicle's traveling direction and the target image; calibrates multiple camera normal vectors of the camera that obtains the target image to obtain multiple ground normal vectors; and fits the ground plane of the vehicle's traveling direction according to the ground point cloud set and the multiple ground normal vectors to obtain a fitted ground plane, which can improve the accuracy of the obtained ground normal vector, thereby effectively improving the accuracy of the fitted ground plane and assisting the safe driving of the autonomous vehicle.

3:車載裝置 3: Vehicle-mounted device

30:地面平面擬合系統 30: Ground plane fitting system

31:儲存器 31: Storage

32:處理器 32: Processor

33:雷達裝置 33: Radar device

34:相機 34: Camera

S1~S3:步驟 S1~S3: Steps

S11~S12:步驟 S11~S12: Steps

S21~S22:步驟 S21~S22: Steps

S211~S212:步驟 S211~S212: Steps

為了更清楚地說明本申請實施例或習知技術中的技術方案,下面將對實施例或習知技術描述中所需要使用的附圖作簡單地介紹,顯而易見地,下面描述中的附圖僅僅是本申請的實施例,對於本領域普通技術人員來講,在不付出創造性勞動的前提下,還可以根據提供的附圖獲得其他的附圖。 In order to more clearly illustrate the technical solutions in the embodiments of this application or the known technology, the drawings required for the embodiments or the known technology description will be briefly introduced below. Obviously, the drawings described below are only embodiments of this application. For ordinary technicians in this field, other drawings can be obtained based on the provided drawings without creative labor.

圖1是本申請實施例提供的地面平面擬合方法的流程圖。 Figure 1 is a flow chart of the ground plane fitting method provided by the embodiment of this application.

圖2是本申請實施例提供的確定目標圖像對應的地面點雲集合的流程圖。 Figure 2 is a flow chart of determining the ground point cloud set corresponding to the target image provided by the embodiment of this application.

圖3是本申請實施例提供的獲取多個地面法向量的流程圖。 Figure 3 is a flowchart of obtaining multiple ground normal vectors provided by the embodiment of this application.

圖4是本申請實施例提供的獲取相機座標系的流程圖。 Figure 4 is a flow chart of obtaining the camera coordinate system provided by the embodiment of this application.

圖5是本申請實施例提供的車載裝置的架構圖。 Figure 5 is a structural diagram of the vehicle-mounted device provided in the embodiment of this application.

為了能夠更清楚地理解本申請的上述目的、特徵和優點,下面結合附圖和具體實施例對本申請進行詳細描述。需要說明的是,在不衝突的情況下,本申請的實施例及實施例中的特徵可以相互組合。 In order to more clearly understand the above-mentioned purpose, features and advantages of this application, the following is a detailed description of this application in conjunction with the attached drawings and specific embodiments. It should be noted that the embodiments of this application and the features in the embodiments can be combined with each other without conflict.

在下面的描述中闡述了很多具體細節以便於充分理解本申請,所描述的實施例僅僅是本申請一部分實施例,而不是全部的實施例。基於本 申請中的實施例,本領域普通技術人員在沒有做出創造性勞動前提下所獲得的所有其他實施例,都屬於本申請保護的範圍。 In the following description, many specific details are explained to facilitate a full understanding of this application. The embodiments described are only part of the embodiments of this application, not all of them. Based on the embodiments in this application, all other embodiments obtained by ordinary technicians in this field without creative labor are within the scope of protection of this application.

除非另有定義,本文所使用的所有的技術和科學術語與屬於本申請的技術領域的技術人員通常理解的含義相同。本文中在本申請的說明書中所使用的術語只是為了描述具體的實施例的目的,不是旨在於限制本申請。 Unless otherwise defined, all technical and scientific terms used herein have the same meaning as those commonly understood by technicians in the technical field of this application. The terms used in this specification of this application are only for the purpose of describing specific embodiments and are not intended to limit this application.

在一個實施例中,在自動駕駛技術中,對車輛前方的地面進行平面擬合是不可缺少的一部分。可以根據擬合得到的地面平面控制自動駕駛車輛的行駛,例如當地面平面指示前方地面為下坡且坡度較大時,控制自動駕駛車輛減速行駛。現有的地面平面擬合方法中存在著擬合精度不高等問題。 In one embodiment, in the automatic driving technology, plane fitting of the ground in front of the vehicle is an indispensable part. The driving of the automatic driving vehicle can be controlled according to the ground plane obtained by fitting. For example, when the ground plane indicates that the ground in front is downhill and the slope is large, the automatic driving vehicle is controlled to slow down. The existing ground plane fitting method has problems such as low fitting accuracy.

為了解決上述問題,本申請實施例提供的地面平面擬合方法,根據車輛行進方向的點雲與目標圖像確定目標圖像對應的地面點雲集合;對獲取所述目標圖像的相機的多個相機法向量進行校正,獲得多個地面法向量;根據所述地面點雲集合與所述多個地面法向量,對所述車輛行進方向的地面平面進行擬合,得到擬合地面平面,能夠提高獲得的地面法向量的精度,從而有效提高擬合地面平面的精度,輔助自動駕駛車輛的安全駕駛。 In order to solve the above problems, the ground plane fitting method provided in the embodiment of the present application determines the ground point cloud set corresponding to the target image according to the point cloud in the direction of vehicle travel and the target image; calibrates the multiple camera normal vectors of the camera that obtains the target image to obtain multiple ground normal vectors; and fits the ground plane in the direction of vehicle travel according to the ground point cloud set and the multiple ground normal vectors to obtain a fitted ground plane, which can improve the accuracy of the obtained ground normal vector, thereby effectively improving the accuracy of the fitted ground plane and assisting the safe driving of the autonomous vehicle.

參閱圖1所示,為本申請較佳實施例的地面平面擬合方法的流程圖。 Refer to Figure 1, which is a flow chart of the ground plane fitting method of the preferred embodiment of this application.

在本實施例中,所述地面平面擬合方法可以應用於安裝在車輛中的車載裝置中(例如圖5所示的車載裝置3),對於需要進行地面平面擬合的車載裝置,可以直接在車載裝置上集成本申請實施例的方法所提供的地面平面擬合的功能,或者以軟體開發套件(Software Development Kit,SDK)的形式運行在車載裝置上。 In this embodiment, the ground plane fitting method can be applied to a vehicle-mounted device installed in a vehicle (e.g., the vehicle-mounted device 3 shown in FIG. 5 ). For a vehicle-mounted device that needs to perform ground plane fitting, the ground plane fitting function provided by the method of the embodiment of the present application can be directly integrated on the vehicle-mounted device, or run on the vehicle-mounted device in the form of a software development kit (SDK).

如圖1所示,所述地面平面擬合方法具體包括以下步驟,根據不同的需求,該流程圖中步驟的順序可以改變,某些步驟可以省略。 As shown in Figure 1, the ground plane fitting method specifically includes the following steps. According to different requirements, the order of the steps in the flowchart can be changed, and some steps can be omitted.

步驟S1,基於獲取的車輛行進方向的點雲與目標圖像,確定所述目標圖像對應的地面點雲集合。 Step S1, based on the obtained point cloud of the vehicle's travel direction and the target image, determine the ground point cloud set corresponding to the target image.

在一個實施例中,車載裝置可以包括多個感測器設備,例如點雲獲取裝置和圖像獲取裝置。具體地,所述點雲獲取裝置可以包括雷達裝置(例如毫米波雷達),所述圖像獲取裝置可以包括相機(例如單目相機)。在本申請實施例中,車載裝置可以是車輛中配置的設備,安裝在車輛中且具有相應的軟體系統以執行各項指令;也可以是獨立的電子設備,例如,能夠與車輛透過通訊連接的外部設備(例如,手機、電腦、平板電腦等設備),以實現對車輛資料的獲取與對車輛的控制。 In one embodiment, the vehicle-mounted device may include multiple sensor devices, such as a point cloud acquisition device and an image acquisition device. Specifically, the point cloud acquisition device may include a radar device (such as a millimeter wave radar), and the image acquisition device may include a camera (such as a monocular camera). In the embodiment of the present application, the vehicle-mounted device may be a device configured in the vehicle, installed in the vehicle and having a corresponding software system to execute various instructions; or it may be an independent electronic device, for example, an external device (such as a mobile phone, computer, tablet computer, etc.) that can be connected to the vehicle through communication to achieve the acquisition of vehicle data and control of the vehicle.

所述雷達裝置可以安裝在所述車輛中,例如車輛的前擋風玻璃等位置,用於獲取車輛行進方向的點雲(例如,三維點雲);所述相機可以安裝在所述車輛的前擋風玻璃等位置,用於獲取車輛行進方向的圖像(例如,二維圖像)。所述相機可以是安裝在車輛中的行車記錄器,也可以是一個或多個攝像頭,攝像頭可安裝於車輛上,也可以是獨立的設備與車載裝置透過網路等方式進行連線。實際應用中並不局限於上述舉例。 The radar device can be installed in the vehicle, such as the front windshield of the vehicle, to obtain a point cloud (e.g., a three-dimensional point cloud) in the direction of the vehicle's travel; the camera can be installed in the front windshield of the vehicle, to obtain an image (e.g., a two-dimensional image) in the direction of the vehicle's travel. The camera can be a dash cam installed in the vehicle, or one or more cameras, which can be installed on the vehicle, or an independent device connected to the vehicle-mounted device through a network or other means. The actual application is not limited to the above examples.

在一個實施例中,按照所述相機的幀率,所述相機獲得的每張圖像包含對應的時間戳記。例如,所述相機的幀率為30幀/秒,那麼所述相機獲得的相鄰的兩張圖像對應的兩個時間戳記之間的時間間隔為1/30秒。 In one embodiment, each image obtained by the camera contains a corresponding timestamp according to the frame rate of the camera. For example, if the frame rate of the camera is 30 frames per second, then the time interval between two timestamps corresponding to two adjacent images obtained by the camera is 1/30 second.

在一個實施例中,所述目標圖像可以表示所述相機獲得的任一張所述車輛行進方向的二維圖像,所述目標圖像對應的時間戳記可以表示為目標時間戳記。本申請實施例提供的地面平面擬合方法,用於對所述目標時間戳記對應的所述車輛行進方向的地面平面進行擬合,從而根據擬合得到的地面平面控制自動駕駛車輛的行駛。 In one embodiment, the target image may represent any two-dimensional image of the vehicle's traveling direction obtained by the camera, and the timestamp corresponding to the target image may be represented as the target timestamp. The ground plane fitting method provided in the embodiment of the present application is used to fit the ground plane of the vehicle's traveling direction corresponding to the target timestamp, thereby controlling the driving of the autonomous vehicle according to the fitted ground plane.

在一個實施例中,結合圖2所示的流程圖,對步驟S1進行詳細說明。圖2為本申請實施例提供的確定目標圖像對應的地面點雲集合的流程圖,具體包括如下步驟: In one embodiment, step S1 is described in detail in conjunction with the flowchart shown in FIG2. FIG2 is a flowchart for determining the ground point cloud set corresponding to the target image provided in the embodiment of the present application, which specifically includes the following steps:

步驟S11,確定所述目標圖像中的地面區域。 Step S11, determine the ground area in the target image.

在一個實施例中,確定所述目標圖像中的地面區域的圖像識別方法有很多,包括但不限於:利用語義分割演算法識別所述目標圖像中的所述地面區域。 In one embodiment, there are many image recognition methods for determining the ground area in the target image, including but not limited to: using a semantic segmentation algorithm to identify the ground area in the target image.

在一個實施例中,語義分割演算法可以按照所述目標圖像中的圖元點表達語義類別(例如,地面、車輛)的不同,對所述目標圖像中的圖元點進行逐點分類,從而實現對所述目標圖像中的圖元點進行分組或分割,得到所述目標圖像中的不同類的物體所在區域(例如,地面區域)。 In one embodiment, the semantic segmentation algorithm can classify the primitive points in the target image point by point according to the different semantic categories (e.g., ground, vehicle) expressed by the primitive points in the target image, thereby grouping or segmenting the primitive points in the target image to obtain the regions where objects of different types are located in the target image (e.g., ground regions).

在一個實施例中,還可以獲取訓練樣本,預先訓練語義分割模型,從而直接將所述目標圖像輸入所述語義分割模型,得到所述目標圖像的地面區域。其中,所述語義分割模型可以包括基於全卷積的擴張卷積語義分割模型,例如,RefineNet模型。 In one embodiment, a training sample can also be obtained to pre-train a semantic segmentation model, so that the target image is directly input into the semantic segmentation model to obtain the ground region of the target image. The semantic segmentation model can include a dilated convolution semantic segmentation model based on full convolution, for example, a RefineNet model.

具體地,RefineNet模型網路由獨立的RefineNet模組組成,每個RefineNet模組包括:剩餘卷積單元(RCU)塊,多解析度融合(MRF)層與鏈剩餘池(CRP)層。其中,RCU塊由一個自我調整塊組成卷積集,用於基於ResNet權重對圖像進行分割;MRF層融合不同的啟動物使用卷積和上採樣層提高圖像的解析度;CRP層池中使用多種大小的內核從較大的圖像區域中獲得全域的感受野。 Specifically, the RefineNet model network consists of independent RefineNet modules, each of which includes: residual convolutional unit (RCU) block, multi-resolution fusion (MRF) layer and chained residual pooling (CRP) layer. Among them, the RCU block consists of a self-adjusting block to form a convolution set, which is used to segment the image based on the ResNet weight; the MRF layer fuses different activations to use convolution and upsampling layers to improve the resolution of the image; the CRP layer uses kernels of various sizes in the pool to obtain the global receptive field from a larger image area.

步驟S12,將所述點雲投影至所述目標圖像,將所述地面區域對應的點雲的集合作為所述地面點雲集合。 Step S12, projecting the point cloud to the target image, and taking the set of point clouds corresponding to the ground area as the ground point cloud set.

在一個實施例中,所述將所述點雲投影至所述目標圖像包括:對獲取所述點雲的雷達裝置與獲取所述目標圖像的相機進行聯合標定;將所述點雲與所述目標圖像進行融合。 In one embodiment, projecting the point cloud onto the target image includes: jointly calibrating a radar device for acquiring the point cloud and a camera for acquiring the target image; and fusing the point cloud with the target image.

在所述雷達裝置與所述相機構成的多感測器探測系統中,進行所述點雲與所述目標圖像融合前需要對兩種感測器進行聯合標定,從而獲得點雲的點(point)和目標圖像的圖元點(pixel)之間的對應關係,將三維 點雲對應投影至二維圖像中,完成雷達資訊與圖像資訊的融合。 In the multi-sensor detection system composed of the radar device and the camera, the two sensors need to be jointly calibrated before the point cloud and the target image are fused, so as to obtain the correspondence between the point of the point cloud and the pixel of the target image, and project the three-dimensional point cloud into the two-dimensional image to complete the fusion of radar information and image information.

在一個實施例中,聯合標定並融合雷達資訊與圖像資訊的基本原理包括:分別獲取雷達裝置與相機的外參(旋轉矩陣、平移向量等),基於所述外參獲得雷達裝置所在的世界座標系與相機所在的相機座標系的轉換矩陣(例如,基於Perspective-n-Point演算法計算得到的座標轉換關係矩陣);基於所述轉換矩陣將三維點雲座標系下的點(point)投影至相機座標系中;透過對相機進行相機標定獲得相機的內參(焦距、主點、傾斜係數、畸變係數等),基於所述內參消除相機的凸透鏡的畸變效應,將投影至相機所在的三維座標系中的點(point)投影到二維圖像中。具體地,可以使用多種標定工具實現上述過程,例如,APOLLO的感測器設備標定工具、AUTOWARE的CalibrationTookit模組等。 In one embodiment, the basic principle of jointly calibrating and fusing radar information and image information includes: obtaining external parameters (rotation matrix, translation vector, etc.) of the radar device and the camera respectively, and obtaining a transformation matrix between the world coordinate system of the radar device and the camera coordinate system of the camera based on the external parameters (for example, a coordinate transformation relationship matrix calculated based on the Perspective-n-Point algorithm); projecting points in the three-dimensional point cloud coordinate system into the camera coordinate system based on the transformation matrix; obtaining the intrinsic parameters of the camera (focal length, principal point, tilt coefficient, distortion coefficient, etc.) by calibrating the camera, eliminating the distortion effect of the convex lens of the camera based on the intrinsic parameters, and projecting the points in the three-dimensional coordinate system where the camera is located into a two-dimensional image. Specifically, a variety of calibration tools can be used to implement the above process, such as APOLLO's sensor equipment calibration tool, AUTOWARE's CalibrationTookit module, etc.

在一個實施例中,將所述點雲投影至所述目標圖像後,所述目標圖像的所述地面區域對應的點雲的集合即為所述點雲中的所述地面點雲集合。 In one embodiment, after the point cloud is projected onto the target image, the set of point clouds corresponding to the ground area of the target image is the ground point cloud set in the point cloud.

步驟S2,對獲取所述目標圖像的相機的多個相機法向量進行校正,獲得多個地面法向量。 Step S2, calibrating multiple camera normal vectors of the camera that obtains the target image to obtain multiple ground normal vectors.

在一個實施例中,由於自動駕駛車輛行駛的地面會有坡度,所以當所述車輛由於地面坡度導致有位置傾斜時,安裝在所述車輛中的相機的參考的世界座標系的偏轉角度會出現變化。此時,若是一直按照原本的世界座標系確定所述相機的相機位姿,將所述相機位姿對應的相機法向量作為地面法向量的話,擬合得到的地面平面會出現較大的誤差,因此,需要對所述相機法向量進行校正。 In one embodiment, since the ground on which the autonomous vehicle is driving may have a slope, when the vehicle is tilted due to the ground slope, the deflection angle of the world coordinate system referenced by the camera installed in the vehicle will change. At this time, if the camera posture of the camera is always determined according to the original world coordinate system, and the camera normal vector corresponding to the camera posture is used as the ground normal vector, the fitted ground plane will have a large error, so the camera normal vector needs to be corrected.

在一個實施例中,結合圖3說明步驟S2的詳細流程。圖3所示為本申請實施例提供的獲取多個地面法向量的流程圖,具體包括如下步驟: In one embodiment, the detailed process of step S2 is described in conjunction with FIG3. FIG3 is a flowchart of obtaining multiple ground normal vectors provided in the embodiment of the present application, which specifically includes the following steps:

步驟S21,獲取所述相機的包含時間戳記的多個相機法向量。 Step S21, obtaining multiple camera normal vectors of the camera including time stamps.

在一個實施例中,可以將所述相機的相機法向量的偏轉角度作為所述相機的參考的世界座標系的偏轉角度。在確定所述相機法向量時,可以先確定相機的相機座標系。 In one embodiment, the deflection angle of the camera normal vector of the camera can be used as the deflection angle of the world coordinate system referenced by the camera. When determining the camera normal vector, the camera coordinate system of the camera can be determined first.

其中,在本申請一實施例中,對相機座標系的獲取流程圖可參考如圖4所示的流程,具體包括如下步驟: Among them, in an embodiment of the present application, the flowchart for obtaining the camera coordinate system can refer to the process shown in Figure 4, which specifically includes the following steps:

步驟S211,獲取所述相機拍攝的多張圖像,所述多張圖像包括所述目標圖像,且所述多張圖像中的每張圖像對應一個時間戳記。 Step S211, obtaining multiple images taken by the camera, wherein the multiple images include the target image, and each of the multiple images corresponds to a timestamp.

在一個實施例中,所述多張圖像可以是以所述目標圖像為最後一張圖像的多張連續圖像,例如,在確定所述目標圖像後,從所述目標圖像反推得到3張連續圖像,其中所述目標圖像是所述3張連續圖像中的最後一張圖像。對於時間戳記的描述可以參考步驟S1中的對應記載。 In one embodiment, the multiple images may be multiple continuous images with the target image as the last image. For example, after determining the target image, three continuous images are obtained by inferring from the target image, wherein the target image is the last image of the three continuous images. For the description of the timestamp, reference may be made to the corresponding record in step S1.

由於所述相機的幀率較大,所以所述多張圖像的實際時間跨度很小,可以視作是所述車輛對同一地面拍攝得到的一組圖像。例如,當所述多張圖像為3張時,所述相機的幀率為30幀/秒時,實際對應的時間跨度僅為(3-1)×1/30=1/15秒,所述車輛在1/15秒內前進的距離很小,所以可以所述多張圖像視作是所述車輛對同一地面拍攝得到的一組圖像。 Since the frame rate of the camera is relatively large, the actual time span of the multiple images is very small, and can be regarded as a set of images taken by the vehicle of the same ground. For example, when the multiple images are 3, and the frame rate of the camera is 30 frames/second, the actual corresponding time span is only (3-1)×1/30=1/15 seconds. The distance traveled by the vehicle in 1/15 seconds is very small, so the multiple images can be regarded as a set of images taken by the vehicle of the same ground.

步驟S212,獲取每張圖像對應的相機座標系。 Step S212, obtain the camera coordinate system corresponding to each image.

在一個實施例中,由於地面坡度的改變,每張圖像對應的相機座標系可能會發生微小的變化,因此,可以獲取每張圖像對應的相機座標系。具體地,可以參考步驟S1中的相機的內參與外參,確定相機與所參考的世界座標系之間的旋轉矩陣與平移矩陣,得到相機座標系。確定相機座標系的方法為本領域常用的技術手段,不再進行詳細描述。 In one embodiment, due to the change of the ground slope, the camera coordinate system corresponding to each image may change slightly, so the camera coordinate system corresponding to each image can be obtained. Specifically, the rotation matrix and translation matrix between the camera and the referenced world coordinate system can be determined by referring to the intrinsic and extrinsic parameters of the camera in step S1 to obtain the camera coordinate system. The method for determining the camera coordinate system is a commonly used technical means in this field and will not be described in detail.

在一個實施例中,當獲得所述相機座標系後,所述獲取所述相機的包含時間戳記的多個相機法向量包括:將所述相機的相機座標系中指向天空的座標軸作為所述相機法向量。例如,所述相機座標系為根據右手法則確定的OXYZ座標系時,所述相機法向量表示指向天空的Z軸。 In one embodiment, after obtaining the camera coordinate system, obtaining multiple camera normal vectors containing time stamps of the camera includes: using the coordinate axis pointing to the sky in the camera coordinate system of the camera as the camera normal vector. For example, when the camera coordinate system is an OXYZ coordinate system determined according to the right-hand rule, the camera normal vector represents the Z axis pointing to the sky.

在一個實施例中,上述實施例中獲得了多張圖像對應的多個相機法向量,可以在後續步驟中提高校正得到的地面法向量的精凖度。 In one embodiment, multiple camera normal vectors corresponding to multiple images are obtained in the above embodiment, which can improve the accuracy of the corrected ground normal vector in the subsequent steps.

步驟S22,獲取所述相機的移動資料,利用所述移動資料對所述多個相機法向量進行校正,得到所述多個地面法向量。 Step S22, obtaining the motion data of the camera, and using the motion data to calibrate the multiple camera normal vectors to obtain the multiple ground normal vectors.

在一個實施例中,為了對所述相機法向量進行校正,所述車載裝置還包括慣性運動單元(inertial motion unit,IMU)感測器。所述IMU感測器可以安裝在所述相機的內部或外部,所述IMU感測器包含加速度計和陀螺儀感測器,可以用於檢測所述相機的每時每刻的移動資料(例如加速度和角速度等),從而獲得包含時間戳記的所述移動資料。 In one embodiment, in order to correct the normal vector of the camera, the vehicle-mounted device further includes an inertial motion unit (IMU) sensor. The IMU sensor can be installed inside or outside the camera. The IMU sensor includes an accelerometer and a gyroscope sensor, which can be used to detect the movement data of the camera at all times (such as acceleration and angular velocity, etc.), thereby obtaining the movement data including a timestamp.

進一步地,所述IMU感測器的時間精度大於所述相機的幀率對應的時間精度,例如,所述相機每隔1/30秒獲取一張圖片,而所述IMU感測器每隔1/60秒獲取一次所述移動資料。因此,每張圖像對應的時間戳記都可以對應到同一個時間戳記的移動資料,從而每張圖像對應的每個相機法向量都可以對應到同一個時間戳記的移動資料,其中,所述移動資料包括重力加速度。 Furthermore, the time accuracy of the IMU sensor is greater than the time accuracy corresponding to the frame rate of the camera. For example, the camera acquires a picture every 1/30 second, and the IMU sensor acquires the motion data every 1/60 second. Therefore, the timestamp corresponding to each image can correspond to the motion data of the same timestamp, so that each camera normal vector corresponding to each image can correspond to the motion data of the same timestamp, wherein the motion data includes gravity acceleration.

在一個實施例中,所述利用所述移動資料對所述多個相機法向量進行校正,得到所述多個地面法向量,包括:利用所述重力加速度的方向校正所述相機的相機位姿中的旋轉矩陣,將所述相機法向量校正為所述地面法向量。 In one embodiment, the method of correcting the multiple camera normal vectors using the movement data to obtain the multiple ground normal vectors includes: correcting the rotation matrix in the camera posture of the camera using the direction of the gravity acceleration to correct the camera normal vector to the ground normal vector.

在一個實施例中,重力加速度的方向為指向地心的方向,是不會在短時間內發生改變的,因此所述多個相機法向量對應的重力加速度的方向統一,所以可以利用所述重力加速度的方向校正所述相機的相機位姿中的旋轉矩陣。其中,所述相機位姿表示所述相機相對於世界座標系的位置和姿態,所述相機位姿包括所述相機座標系與世界座標系的旋轉矩陣,所述旋轉矩陣包括三個矩陣,其中一個為所述相機法向量與世界座標系的指向天空的縱軸的方向的偏轉角度對應的法向量旋轉矩陣。 In one embodiment, the direction of gravity acceleration is toward the center of the earth and will not change in a short time. Therefore, the directions of gravity acceleration corresponding to the multiple camera normal vectors are unified, so the direction of gravity acceleration can be used to correct the rotation matrix in the camera posture of the camera. The camera posture represents the position and posture of the camera relative to the world coordinate system. The camera posture includes the rotation matrix of the camera coordinate system and the world coordinate system. The rotation matrix includes three matrices, one of which is the normal vector rotation matrix corresponding to the deflection angle of the camera normal vector and the longitudinal axis of the world coordinate system pointing to the sky.

具體地,利用所述重力加速度的方向校正所述相機的相機位姿中的旋轉矩陣包括:確定所述重力加速度的方向的反方向與世界座標系的指向天空的縱軸的方向的偏轉角度,根據所述偏轉角度確定所述反方向與世界座標系的指向天空的縱軸的方向的偏轉矩陣,利用所述偏轉矩陣與所述相機位姿中所述法向量旋轉矩陣相乘,得到校正後的法向量旋轉矩陣,從而獲得由所述校正後的法向量旋轉矩陣構成的所述相機位姿的校正後的旋轉矩陣。其中,根據偏轉角度或旋轉角度確定世界座標系的旋轉矩陣的方法,可以採用本技術領域的常用方法,不再進行描述。 Specifically, using the direction of the gravitational acceleration to correct the rotation matrix in the camera posture of the camera includes: determining the deflection angle between the opposite direction of the gravitational acceleration and the direction of the longitudinal axis of the world coordinate system pointing to the sky, determining the deflection matrix between the opposite direction and the direction of the longitudinal axis of the world coordinate system pointing to the sky according to the deflection angle, and multiplying the deflection matrix with the normal vector rotation matrix in the camera posture to obtain the corrected normal vector rotation matrix, thereby obtaining the corrected rotation matrix of the camera posture composed of the corrected normal vector rotation matrix. Among them, the method of determining the rotation matrix of the world coordinate system according to the deflection angle or the rotation angle can adopt the common method in the technical field, which will not be described again.

在一個實施例中,得到所述相機位姿的校正後的旋轉矩陣後,可以得到所述相機的校正後的相機座標系,從而得到校正後的相機法向量作為所述地面法向量。 In one embodiment, after obtaining the corrected rotation matrix of the camera posture, the corrected camera coordinate system of the camera can be obtained, thereby obtaining the corrected camera normal vector as the ground normal vector.

步驟S3,根據所述地面點雲集合與所述多個地面法向量,對所述車輛行進方向的地面平面進行擬合,得到擬合地面平面。 Step S3, fitting the ground plane in the direction of travel of the vehicle according to the ground point cloud set and the multiple ground normal vectors to obtain a fitted ground plane.

在一個實施例中,所述根據所述地面點雲集合與所述多個地面法向量,對所述車輛行進方向的地面平面進行擬合,得到擬合地面平面,包括:將所述地面點雲集合與所述多個地面法向量作為擬和地面平面方程的約束條件,基於所述約束條件使用最小二乘法擬合得到所述地面對應的所述地面平面。 In one embodiment, the ground plane in the direction of travel of the vehicle is fitted according to the ground point cloud set and the multiple ground normal vectors to obtain a fitted ground plane, including: using the ground point cloud set and the multiple ground normal vectors as constraints for fitting a ground plane equation, and fitting the ground plane corresponding to the ground using the least squares method based on the constraints.

在一個實施例中,通常使用一個地面法向量與地面點雲集合作為約束條件或者只使用包含深度資訊的地面點雲集合作為約束條件,使用最小二乘法擬合地面平面,但是通常擬合得到的地面平面的精度難以保證。因此,本申請實施例中使用上述實施例獲得的多個地面法向量,可以得到更為精凖的地面平面。 In one embodiment, a ground normal vector and a ground point cloud set are usually used as a constraint condition or only a ground point cloud set containing depth information is used as a constraint condition, and the ground plane is fitted using the least squares method, but the accuracy of the fitted ground plane is usually difficult to guarantee. Therefore, in the embodiment of the present application, multiple ground normal vectors obtained in the above embodiment are used to obtain a more accurate ground plane.

在一個實施例中,最小二乘法擬合平面方程的方法為本領域常用技術,其基本原理包括利用多個資料(例如,多個地面法向量或地面點雲集合)之間最小化誤差的平方和尋找多個資料的最佳函數匹配,不再進行 描述。 In one embodiment, the method of least squares fitting plane equations is a common technique in this field, and its basic principle includes minimizing the sum of squares of errors between multiple data (for example, multiple ground normal vectors or ground point cloud sets) to find the best function match for multiple data, which will not be described further.

在一個實施例中,得到所述地面平面後,可以控制自動駕駛車輛根據所述地面平面的進行行駛,例如,地面平面指示前方地面為坡度較大的上坡時,控制自動駕駛車輛的速度提升。 In one embodiment, after obtaining the ground plane, the automatic driving vehicle can be controlled to drive according to the ground plane. For example, when the ground plane indicates that the ground ahead is an uphill slope with a large slope, the speed of the automatic driving vehicle is controlled to increase.

此外,還可以在上述實施例中,將所述地面區域劃分為多個子區域,根據多個子區域對應的多個地面點雲集合擬合得到多個地面平面,從而可以進一步提高擬合得到的前方地面的精度,為自動駕駛車輛指示更為精凖的行進方向,為車內用戶提高乘車體驗。例如,某個子區域對應的地面平面指示有塌陷,可以控制所述車輛避開塌陷地面行駛,防止車內乘客感到顛簸。 In addition, in the above embodiment, the ground area can be divided into multiple sub-areas, and multiple ground planes can be obtained by fitting multiple ground point cloud sets corresponding to the multiple sub-areas, so as to further improve the accuracy of the fitted front ground, indicate a more accurate direction of travel for the self-driving vehicle, and improve the riding experience for the users in the car. For example, if the ground plane corresponding to a certain sub-area indicates collapse, the vehicle can be controlled to avoid the collapsed ground to prevent the passengers in the car from feeling bumpy.

在一個實施例中,本申請提供的地面平面擬合方法,根據車輛行進方向的點雲與目標圖像確定目標圖像對應的地面點雲集合;對獲取所述目標圖像的相機的多個相機法向量進行校正,獲得多個地面法向量;根據所述地面點雲集合與所述多個地面法向量,對所述車輛行進方向的地面平面進行擬合,得到擬合地面平面,能夠提高獲得的地面法向量的精度,從而有效提高擬合地面平面的精度,輔助自動駕駛車輛的安全駕駛。 In one embodiment, the ground plane fitting method provided by the present application determines a ground point cloud set corresponding to a target image according to a point cloud in the direction of vehicle travel and a target image; calibrates multiple camera normal vectors of a camera that obtains the target image to obtain multiple ground normal vectors; and fits the ground plane in the direction of vehicle travel according to the ground point cloud set and the multiple ground normal vectors to obtain a fitted ground plane, which can improve the accuracy of the obtained ground normal vector, thereby effectively improving the accuracy of the fitted ground plane and assisting the safe driving of autonomous vehicles.

上述圖1詳細介紹了本申請的地面平面擬合方法,下面結合圖5,對實現所述地面平面擬合方法的軟體系統的功能模組以及實現所述地面平面擬合方法的硬體裝置架構進行介紹。 The above FIG1 introduces the ground plane fitting method of the present application in detail. The following introduces the functional modules of the software system for implementing the ground plane fitting method and the hardware device architecture for implementing the ground plane fitting method in conjunction with FIG5.

應該瞭解,所述實施例僅為說明之用,在專利申請範圍上並不受此結構的限制。 It should be understood that the embodiments described are for illustrative purposes only and are not limited to this structure in the scope of the patent application.

參閱圖5所示,為本申請較佳實施例提供的車載裝置的結構示意圖。 See Figure 5, which is a schematic diagram of the structure of the vehicle-mounted device provided in the preferred embodiment of this application.

在本申請較佳實施例中,所述車載裝置3包括儲存器31、至少一個處理器32、至少一個雷達裝置33、至少一個相機34。本領域技術人員應該瞭解,圖5示出的車載裝置的結構並不構成本申請實施例的限定,既 可以是匯流排型結構,也可以是星形結構,所述車載裝置3還可以包括比圖示更多或更少的其他硬體或者軟體,或者不同的部件配置。 In the preferred embodiment of the present application, the vehicle-mounted device 3 includes a storage device 31, at least one processor 32, at least one radar device 33, and at least one camera 34. Those skilled in the art should understand that the structure of the vehicle-mounted device shown in FIG. 5 does not constitute a limitation of the present application embodiment, and it can be a bus structure or a star structure. The vehicle-mounted device 3 can also include more or less other hardware or software than shown in the figure, or different component configurations.

在一些實施例中,所述車載裝置3包括一種能夠按照事先設定或儲存的指令,自動進行數值計算和/或資訊處理的終端,其硬體包括但不限於微處理器、專用積體電路、可程式化邏輯閘陣列、數位訊號處理器及嵌入式設備等。 In some embodiments, the vehicle-mounted device 3 includes a terminal capable of automatically performing numerical calculations and/or information processing according to pre-set or stored instructions, and its hardware includes but is not limited to a microprocessor, a dedicated integrated circuit, a programmable logic gate array, a digital signal processor, and an embedded device, etc.

需要說明的是,所述車載裝置3僅為舉例,其他現有的或今後可能出現的電子產品如可適應於本申請,也應包含在本申請的保護範圍以內,並以引用方式包含於此。 It should be noted that the vehicle-mounted device 3 is only an example. Other existing or future electronic products that are suitable for this application should also be included in the protection scope of this application and included here by reference.

在一些實施例中,所述儲存器31用於儲存程式碼和各種資料。例如,所述儲存器31可以用於儲存安裝在所述車載裝置3中的地面平面擬合系統30,並在車載裝置3的運行過程中實現高速、自動地完成程式或資料的存取。所述儲存器31包括唯讀記憶體(Read-Only Memory,ROM)、可程式設計唯讀記憶體(Programmable Read-Only Memory,PROM)、可抹除可程式設計唯讀記憶體(Erasable Programmable Read-Only Memory,EPROM)、一次可程式設計唯讀記憶體(One-time Programmable Read-Only Memory,OTPROM)、電子抹除式可複寫唯讀記憶體(Electrically-Erasable Programmable Read-Only Memory,EEPROM)、唯讀光碟(Compact Disc Read-Only Memory,CD-ROM)或其他光碟儲存器、磁碟儲存器、磁帶儲存器、或者任何其他能夠用於攜帶或儲存資料的電腦可讀的儲存介質。 In some embodiments, the memory 31 is used to store program codes and various data. For example, the memory 31 can be used to store the ground plane simulation system 30 installed in the vehicle-mounted device 3, and realize high-speed and automatic access to programs or data during the operation of the vehicle-mounted device 3. The storage device 31 includes a read-only memory (ROM), a programmable read-only memory (PROM), an erasable programmable read-only memory (EPROM), a one-time programmable read-only memory (OTPROM), an electronically erasable programmable read-only memory (EEPROM), a compact disc read-only memory (CD-ROM) or other optical disc storage, a magnetic disk storage, a magnetic tape storage, or any other computer-readable storage medium that can be used to carry or store data.

在一些實施例中,所述至少一個處理器32可以由積體電路組成,例如可以由單個封裝的積體電路所組成,也可以是由多個相同功能或不同功能封裝的積體電路所組成,包括一個或者多個中央處理器、微處理器、數位訊號處理晶片、圖形處理器及各種控制晶片的組合等。所述至少一個處理器32是所述車載裝置3的控制核心(Control Unit),利用各種介面和線路連接整個車載裝置3的各個部件,透過運行或執行儲存在所述儲存器 31內的程式或者模組,以及調用儲存在所述儲存器31內的資料,以執行車載裝置3的各種功能和處理資料,例如執行圖1所示的地面平面擬合的功能。 In some embodiments, the at least one processor 32 may be composed of an integrated circuit, for example, a single packaged integrated circuit, or a plurality of packaged integrated circuits with the same or different functions, including one or more central processing units, microprocessors, digital signal processing chips, graphics processors, and combinations of various control chips. The at least one processor 32 is the control core (Control Unit) of the vehicle-mounted device 3, and uses various interfaces and lines to connect various components of the entire vehicle-mounted device 3, and executes or runs programs or modules stored in the memory 31, and calls data stored in the memory 31 to execute various functions of the vehicle-mounted device 3 and process data, such as executing the ground plane fitting function shown in Figure 1.

在一些實施例中,所述地面平面擬合系統30運行於車載裝置3中。所述地面平面擬合系統30可以包括多個由程式碼段所組成的功能模組。所述地面平面擬合系統30中的各個程式段的程式碼可以儲存於車載裝置3的儲存器31中,並由至少一個處理器32所執行,以實現圖1所示的地面平面擬合的功能。 In some embodiments, the ground plane fitting system 30 runs in the vehicle-mounted device 3. The ground plane fitting system 30 may include a plurality of functional modules composed of program code segments. The program code of each program segment in the ground plane fitting system 30 may be stored in the memory 31 of the vehicle-mounted device 3 and executed by at least one processor 32 to realize the ground plane fitting function shown in FIG. 1.

本實施例中,所述地面平面擬合系統30根據其所執行的功能,可以被劃分為多個功能模組。本申請所稱的模組是指一種能夠被至少一個處理器所執行並且能夠完成固定功能的一系列電腦程式段,其儲存在儲存器中。 In this embodiment, the ground plane simulation system 30 can be divided into multiple functional modules according to the functions it performs. The module referred to in this application refers to a series of computer program segments that can be executed by at least one processor and can complete fixed functions, which are stored in a memory.

儘管未示出,所述車載裝置3還可以包括給各個部件供電的電源(比如電池),優選的,電源可以透過電源管理裝置與所述至少一個處理器32邏輯相連,從而透過電源管理裝置實現管理充電、放電、以及功耗管理等功能。電源還可以包括一個或一個以上的直流或交流電源、再充電裝置、電源故障測試電路、電源轉換器或者逆變器、電源狀態指示器等任意元件。所述車載裝置3還可以包括多種感測器、藍牙模組、Wi-Fi模組等,在此不再贅述。 Although not shown, the vehicle-mounted device 3 may also include a power source (such as a battery) for supplying power to various components. Preferably, the power source may be logically connected to the at least one processor 32 through a power management device, so as to manage charging, discharging, and power consumption through the power management device. The power source may also include one or more DC or AC power sources, recharging devices, power fault test circuits, power converters or inverters, power status indicators, and other arbitrary components. The vehicle-mounted device 3 may also include a variety of sensors, Bluetooth modules, Wi-Fi modules, etc., which will not be elaborated here.

應該瞭解,所述實施例僅為說明之用,在專利申請範圍上並不受此結構的限制。 It should be understood that the embodiments described are for illustrative purposes only and are not limited to this structure in the scope of the patent application.

上述以軟體功能模組的形式實現的集成的單元,可以儲存在一個電腦可讀取儲存介質中。上述軟體功能模組儲存在一個儲存介質中,包括若干指令用以使得一台車載裝置(可以是伺服器、個人電腦等)或處理器執行本申請各個實施例所述方法的部分。 The above-mentioned integrated unit implemented in the form of a software function module can be stored in a computer-readable storage medium. The above-mentioned software function module is stored in a storage medium, including several instructions for enabling a vehicle-mounted device (which can be a server, a personal computer, etc.) or a processor to execute a part of the method described in each embodiment of the present application.

所述儲存器31中儲存有程式碼,且所述至少一個處理器32可調 用所述儲存器31中儲存的程式碼以執行相關的功能。儲存在所述儲存器31中的程式碼可以由所述至少一個處理器32所執行,從而實現所述各個模組的功能以達到地面平面擬合的目的。 The memory 31 stores program codes, and the at least one processor 32 can call the program codes stored in the memory 31 to execute related functions. The program codes stored in the memory 31 can be executed by the at least one processor 32, thereby realizing the functions of each module to achieve the purpose of ground plane fitting.

在本申請所提供的幾個實施例中,應該理解到,所揭露的裝置和方法,可以透過其它的方式實現。例如,以上所描述的裝置實施例僅僅是示意性的,例如,所述模組的劃分,僅僅為一種邏輯功能劃分,實際實現時可以有另外的劃分方式。 In the several embodiments provided in this application, it should be understood that the disclosed devices and methods can be implemented in other ways. For example, the device embodiments described above are only schematic. For example, the division of the modules is only a logical function division, and there may be other division methods in actual implementation.

所述作為分離部件說明的模組可以是或者也可以不是物理上分開的,作為模組顯示的部件可以是或者也可以不是物理單元,即可以位於一個地方,或者也可以分佈到多個網路單元上。可以根據實際的需要選擇其中的部分或者全部模組來實現本實施例方案的目的。 The modules described as separate components may or may not be physically separated, and the components shown as modules may or may not be physical units, that is, they may be located in one place or distributed on multiple network units. Some or all of the modules may be selected according to actual needs to achieve the purpose of this embodiment.

另外,在本申請各個實施例中的各功能模組可以集成在一個處理單元中,也可以是各個單元單獨物理存在,也可以兩個或兩個以上單元集成在一個單元中。上述集成的單元既可以採用硬體的形式實現,也可以採用硬體加軟體功能模組的形式實現。 In addition, each functional module in each embodiment of the present application can be integrated into a processing unit, or each unit can exist physically separately, or two or more units can be integrated into one unit. The above-mentioned integrated unit can be implemented in the form of hardware or in the form of hardware plus software functional modules.

對於本領域技術人員而言,顯然本申請不限於上述示範性實施例的細節,而且在不背離本申請的精神或基本特徵的情況下,能夠以其他的具體形式實現本申請。因此,無論從哪一點來看,均應將實施例看作是示範性的,而且是非限制性的,本申請的範圍由所附請求項而不是上述說明限定,因此旨在將落在請求項的等同要件的含義和範圍內的所有變化涵括在本申請內。不應將請求項中的任何附圖標記視為限制所涉及的請求項。此外,顯然“包括”一詞不排除其他單元或,單數不排除複數。裝置請求項中陳述的多個單元或裝置也可以由一個單元或裝置透過軟體或者硬體來實現。第一,第二等詞語用來表示名稱,而並不表示任何特定的順序。 It is obvious to those skilled in the art that the present application is not limited to the details of the above exemplary embodiments and that the present application can be implemented in other specific forms without departing from the spirit or basic characteristics of the present application. Therefore, no matter from which point of view, the embodiments should be regarded as exemplary and non-restrictive, and the scope of the present application is defined by the attached claims rather than the above description, and it is intended that all changes falling within the meaning and scope of the equivalent elements of the claims are included in the present application. Any figure marks in the claims should not be regarded as limiting the claims involved. In addition, it is obvious that the word "including" does not exclude other units or, and the singular does not exclude the plural. Multiple units or devices stated in the device claim may also be implemented by one unit or device through software or hardware. The words first, second, etc. are used to indicate names, not to indicate any particular order.

最後所應說明的是,以上實施例僅用以說明本申請的技術方案而非限制,儘管參照以上較佳實施例對本申請進行了詳細說明,本領域的普 通技術人員應當理解,可以對本申請的技術方案進行修改或等同替換,而不脫離本申請技術方案的精神和範圍。 Finally, it should be noted that the above embodiments are only used to illustrate the technical solution of this application and are not limiting. Although this application is described in detail with reference to the above preferred embodiments, ordinary technicians in this field should understand that the technical solution of this application can be modified or replaced by equivalents without departing from the spirit and scope of the technical solution of this application.

S1~S3:步驟 S1~S3: Steps

Claims (10)

一種地面平面擬合方法,應用於車載裝置,其中,所述方法包括:基於獲取的車輛行進方向的點雲與目標圖像,確定所述目標圖像對應的地面點雲集合;對獲取所述目標圖像的相機的多個相機法向量進行校正,獲得多個地面法向量;根據所述地面點雲集合與所述多個地面法向量,對所述車輛行進方向的地面平面進行擬合,得到擬合地面平面。 A ground plane fitting method is applied to a vehicle-mounted device, wherein the method includes: determining a ground point cloud set corresponding to the target image based on a point cloud and a target image obtained in the direction of vehicle travel; correcting multiple camera normal vectors of a camera that obtains the target image to obtain multiple ground normal vectors; fitting the ground plane in the direction of vehicle travel according to the ground point cloud set and the multiple ground normal vectors to obtain a fitted ground plane. 如請求項1所述的地面平面擬合方法,其中,所述基於獲取的車輛行進方向的點雲與目標圖像,確定所述目標圖像對應的地面點雲集合,包括:確定所述目標圖像中的地面區域;將所述點雲投影至所述目標圖像,將所述地面區域對應的點雲的集合作為所述地面點雲集合。 The ground plane fitting method as described in claim 1, wherein the method of determining the ground point cloud set corresponding to the target image based on the obtained point cloud of the vehicle's travel direction and the target image comprises: determining the ground area in the target image; projecting the point cloud to the target image, and taking the set of point clouds corresponding to the ground area as the ground point cloud set. 如請求項2所述的地面平面擬合方法,其中,所述確定所述目標圖像中的地面區域包括:利用語義分割演算法識別所述目標圖像中的所述地面區域。 The ground plane fitting method as described in claim 2, wherein determining the ground area in the target image includes: identifying the ground area in the target image using a semantic segmentation algorithm. 如請求項1所述的地面平面擬合方法,其中,所述對獲取所述目標圖像的相機的多個相機法向量進行校正,獲得多個地面法向量,包括:獲取所述相機的包含時間戳記的多個相機法向量;獲取所述相機的移動資料,利用所述移動資料對所述多個相機法向量進行校正,得到所述多個地面法向量。 As described in claim 1, the method for fitting a ground plane, wherein the correction of multiple camera normal vectors of a camera that obtains the target image to obtain multiple ground normal vectors includes: obtaining multiple camera normal vectors containing time stamps of the camera; obtaining motion data of the camera, and correcting the multiple camera normal vectors using the motion data to obtain the multiple ground normal vectors. 如請求項4所述的地面平面擬合方法,其中,所述獲取所述相機的包含時間戳記的多個相機法向量包括:將所述相機的相機座標系中指向天空的座標軸作為所述相機法向量。 The ground plane fitting method as described in claim 4, wherein the step of obtaining multiple camera normal vectors of the camera including a timestamp includes: using the coordinate axis pointing to the sky in the camera coordinate system of the camera as the camera normal vector. 如請求項5所述的地面平面擬合方法,其中,所述方法還包括:獲取所述相機拍攝的多張圖像,所述多張圖像包括所述目標圖像,且所述多張圖像中的每張圖像對應一個時間戳記;獲取每張圖像對應的相機座標系。 The ground plane fitting method as described in claim 5, wherein the method further comprises: obtaining multiple images taken by the camera, the multiple images including the target image, and each of the multiple images corresponds to a timestamp; obtaining the camera coordinate system corresponding to each image. 如請求項4所述的地面平面擬合方法,其中,所述相機的移動資料包括重力加速度;所述利用所述移動資料對所述多個相機法向量進行校正,得到所述多個地面法向量,包括:利用所述重力加速度的方向校正所述相機的相機位姿中的旋轉矩陣,將所述相機法向量校正為所述地面法向量。 The ground plane fitting method as described in claim 4, wherein the movement data of the camera includes gravity acceleration; the use of the movement data to correct the multiple camera normal vectors to obtain the multiple ground normal vectors includes: using the direction of the gravity acceleration to correct the rotation matrix in the camera posture of the camera, and correcting the camera normal vector to the ground normal vector. 如請求項1所述的地面平面擬合方法,其中,所述根據所述地面點雲集合與所述多個地面法向量,對所述車輛行進方向的地面平面進行擬合,得到擬合地面平面,包括:將所述地面點雲集合與所述多個地面法向量作為擬和地面平面方程的約束條件,基於所述約束條件使用最小二乘法擬合得到所述地面對應的所述地面平面。 The ground plane fitting method as described in claim 1, wherein the ground plane in the direction of vehicle travel is fitted according to the ground point cloud set and the multiple ground normal vectors to obtain the fitted ground plane, including: using the ground point cloud set and the multiple ground normal vectors as constraints for fitting the ground plane equation, and fitting the ground plane corresponding to the ground using the least squares method based on the constraints. 一種電腦可讀儲存介質,其中,所述電腦可讀儲存介質儲存有至少一個指令,所述至少一個指令被處理器執行時實現如請求項1至8中任意一項所述的地面平面擬合方法。 A computer-readable storage medium, wherein the computer-readable storage medium stores at least one instruction, and when the at least one instruction is executed by a processor, the ground plane fitting method as described in any one of claims 1 to 8 is implemented. 一種車載裝置,其中,該車載裝置包括儲存器和至少一個處理器,所述儲存器中儲存有至少一個指令,所述至少一個指令被所述至少一個處理器執行時實現如請求項1至8中任意一項所述的地面平面擬合方法。 A vehicle-mounted device, wherein the vehicle-mounted device includes a memory and at least one processor, wherein at least one instruction is stored in the memory, and when the at least one instruction is executed by the at least one processor, the ground plane fitting method as described in any one of claims 1 to 8 is implemented.
TW111148798A 2022-12-19 Ground plane fitting method, vehicle-mounted device, and storage medium TWI838022B (en)

Publications (1)

Publication Number Publication Date
TWI838022B true TWI838022B (en) 2024-04-01

Family

ID=

Citations (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN115273038A (en) 2022-08-04 2022-11-01 北京晓智若余智能科技有限公司 Pavement element recognition method and system, electronic device and storage medium

Patent Citations (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN115273038A (en) 2022-08-04 2022-11-01 北京晓智若余智能科技有限公司 Pavement element recognition method and system, electronic device and storage medium

Similar Documents

Publication Publication Date Title
US20210208597A1 (en) Sensor aggregation framework for autonomous driving vehicles
US20210365750A1 (en) Systems and methods for estimating future paths
US11531110B2 (en) LiDAR localization using 3D CNN network for solution inference in autonomous driving vehicles
US11364931B2 (en) Lidar localization using RNN and LSTM for temporal smoothness in autonomous driving vehicles
EP3620959B1 (en) Image data acquisition logic of an autonomous driving vehicle for capturing image data using cameras
JP2023507695A (en) 3D Intersection Structure Prediction for Autonomous Driving Applications
CN110531750A (en) The embedded LQR of PID for automatic driving vehicle
US10809736B2 (en) ST-graph learning based decision for autonomous driving vehicle
CN110388931A (en) The two-dimentional bounding box of object is converted into the method for the three-dimensional position of automatic driving vehicle
CN110386142A (en) Pitch angle calibration method for automatic driving vehicle
US20180137628A1 (en) Image data extraction apparatus and image data extraction method
US11282164B2 (en) Depth-guided video inpainting for autonomous driving
CN111959495B (en) Vehicle control method and device and vehicle
CN108136867A (en) The vehicle location point retransmission method of automatic driving vehicle
CN111316285A (en) Object detection method, electronic device, and computer storage medium
US20220277193A1 (en) Ground truth data generation for deep neural network perception in autonomous driving applications
US20230135088A1 (en) 3d surface reconstruction with point cloud densification using deep neural networks for autonomous systems and applications
US20230135234A1 (en) Using neural networks for 3d surface structure estimation based on real-world data for autonomous systems and applications
US20230136235A1 (en) 3d surface reconstruction with point cloud densification using artificial intelligence for autonomous systems and applications
TWI838022B (en) Ground plane fitting method, vehicle-mounted device, and storage medium
US20230196619A1 (en) Validation of virtual camera models
JP2023066377A (en) Three-dimensional surface reconfiguration with point cloud densification using artificial intelligence for autonomous systems and applications
US20230136860A1 (en) 3d surface structure estimation using neural networks for autonomous systems and applications
US20220198714A1 (en) Camera to camera calibration
KR102225321B1 (en) System and method for building road space information through linkage between image information and position information acquired from a plurality of image sensors