Map construction method and device

By obtaining the timestamp of multi-frame point cloud data of the lidar and the pose of the pose acquisition module, and combining the timestamp and target pose change information, the problem of inaccurate association between point cloud data and pose is solved, and more accurate three-dimensional image construction is achieved.

CN114219908BActive Publication Date: 2025-09-09BEIJING JINGWEI HIRAIN TECH CO INC
View PDF 2 Cites 0 Cited by

Patent Information

Application Number
CN202111525329.6
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2021-12-14
Publication Date
2025-09-09
Estimated Expiration
2041-12-14

AI Technical Summary

Technical Problem

In the existing technology, since the laser radar posture acquisition module is not synchronized with the point cloud data acquisition frequency, the association between point cloud data and posture is inaccurate, which in turn affects the accuracy of three-dimensional image construction.

Method used

By obtaining the timestamps of multi-frame point cloud data and multiple poses of the pose acquisition module, and combining the timestamps and target pose change information, the associated pose of the point cloud data is determined, and the weight formula and feature point matching method are used to improve the accuracy of pose association.

Benefits of technology

The relative pose accuracy between point cloud data is improved to ensure that the constructed 3D images are more accurate.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN114219908B_ABST
    Figure CN114219908B_ABST
Patent Text Reader

Abstract

The present application provides a map construction method and device. In the process of establishing an association between point cloud data and posture, for any frame of point cloud data, multiple postures of the laser radar collected by the posture acquisition module in the process of collecting the point cloud data and the timestamps corresponding to the multiple postures are obtained; the target posture change information of the laser radar in the process of collecting the frame of point cloud data is obtained; based on the multiple postures, the timestamps corresponding to the multiple postures, the target posture change information and the timestamp of the point cloud data, the posture associated with the point cloud data is determined to be more accurate, so that the relative posture between two adjacent frames of point cloud data is more accurate, and based on the relative posture between two adjacent frames of point cloud data in the multiple frames of point cloud data and the multiple frames of point cloud data, the three-dimensional image of the object to be measured is constructed to be more accurate.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present application relates to the field of positioning and navigation technology, and more specifically, to a map construction method and device. Background Art

[0002] The principle of SLAM (simultaneous localization and mapping) technology is to use a laser radar (LiDAR) to emit light toward an object and receive reflected light. The distance traveled by the light beam is calculated to determine the distance between the object and the LiDAR. A LiDAR consists of multiple laser sensors. Using multiple laser sensors to emit light generates multiple points. The information collected for each point includes the location of the corresponding laser sensor within the LiDAR, the order of light emitted by the corresponding laser sensor, and the corresponding distance. A frame of point cloud data, representing the multiple points obtained after a complete scan by each laser sensor in the LiDAR, is called a point cloud. By matching and comparing two frames of point cloud data at different times, the relative pose of the LiDAR at those two times is calculated. Using the pose of the first frame as the initial pose, each subsequent frame of point cloud data is transformed to the coordinate system of the first frame based on the relative pose, thereby constructing a point cloud map. A three-dimensional image of the object is then constructed based on the point cloud map.

[0003] In the process of matching and comparing two frames of point cloud data, since the acquisition frequency of the posture acquisition module that collects the posture of the lidar is different from the frequency of collecting point cloud data by the lidar, the number of postures collected by the posture acquisition module is different from the number of frames of point cloud data obtained by the lidar. Therefore, it is necessary to establish an association between each frame of point cloud data and the posture based on the timestamp of each frame of point cloud data and the timestamp of each posture.

[0004] Currently, the method of associating each frame of point cloud data with the posture based on the timestamp of each frame of point cloud data and the timestamp of each posture is inaccurate, resulting in inaccurate relative posture of the lidar between the two moments, inaccurate point cloud map, and ultimately inaccurate three-dimensional image of the object being measured constructed based on the point cloud map. Summary of the Invention

[0005] In view of this, the present application provides a map construction method and device.

[0006] To achieve the above objectives, this application provides the following technical solutions:

[0007] According to a first aspect of an embodiment of the present disclosure, a map construction method is provided, comprising:

[0008] Acquire multiple frames of point cloud data corresponding to the measured object and timestamps corresponding to the multiple frames of point cloud data;

[0009] For any frame of point cloud data in the multiple frames of point cloud data, obtaining multiple poses of the laser radar collected by the pose collection module in the process of collecting the point cloud data and timestamps corresponding to the multiple poses;

[0010] Obtaining target pose change information of the laser radar during the process of collecting the point cloud data, wherein the target pose change information is obtained based on pose change information whose timestamp collected by the pose acquisition module is closest to the timestamp of the frame of point cloud data;

[0011] Determining a pose associated with the point cloud data based on the multiple poses, the timestamps corresponding to the multiple poses, the target pose change information, and the timestamp of the point cloud data to obtain poses associated with the multiple frames of point cloud data;

[0012] For any frame of point cloud data in the multiple frames of point cloud data, determining a relative pose between the two frames of point cloud data based on a pose associated with the point cloud data and a pose associated with a previous frame of point cloud data, so as to obtain a relative pose between two adjacent frames of point cloud data in the multiple frames of point cloud data;

[0013] A three-dimensional image of the object to be measured is constructed based on the relative postures between two adjacent frames of point cloud data in the multiple frames of point cloud data and the multiple frames of point cloud data.

[0014] In conjunction with the first aspect, in a first possible implementation manner, obtaining target pose change information of the laser radar during the process of collecting the point cloud data includes:

[0015] Determining first position change information of the laser radar based on the timestamps respectively corresponding to the multiple position poses and the multiple position poses;

[0016] Obtaining second posture change information of the laser radar collected by the posture acquisition module, wherein the timestamp corresponding to the second posture change information collected by the posture acquisition module is the timestamp closest to the timestamp corresponding to the point cloud data;

[0017] Target posture change information is determined based on the first posture change information, the second posture change information, and a first set weight, where the first set weight is used to represent the accuracy of the second posture change information.

[0018] In combination with the first aspect, in a second possible implementation manner, determining the target posture change information based on the first posture change information, the second posture change information, and the first set weight includes:

[0019] The target pose change information is determined based on the following formula:

[0020] V=λV rtk / imu +(1-λ)V slam

[0021] Among them, V is the target posture change information, V rtk / imu is the second posture change information, V slam is the first posture change information, λ is the first set weight, and the first set weight is obtained based on the number of satellites for calculating the second posture change information and the velocity covariance matrix of the lidar.

[0022] In combination with the first aspect, in a third possible implementation, λ=a*V_xyzcov+b*GPS_num, where V_xyzcov is the velocity covariance matrix of the lidar, GPS_num is the number of satellites, and a and b are calibration parameters.

[0023] In combination with the first aspect, in a fourth possible implementation manner, determining the relative pose between two frames of point cloud data based on the pose associated with the point cloud data and the pose associated with a previous frame of point cloud data includes:

[0024] Acquire an edge feature point set and a plane feature point set from the point cloud data, wherein the edge feature point set includes one or more edge points, and the plane feature point set includes one or more surface points;

[0025] Mapping the edge feature point set of the previous frame of point cloud data to the target coordinate system of the point cloud data based on the first undetermined relative pose to form a first candidate edge feature point set;

[0026] Mapping the plane feature point set of the previous frame point cloud data to the target coordinate system based on the first undetermined relative pose to form a first candidate plane feature point set;

[0027] determining a first error based on the first candidate edge feature point set and a set of edge feature points located in the target coordinate system;

[0028] determining a second error based on the first candidate plane feature point set and the plane feature point set located in the target coordinate system;

[0029] Determine the first undetermined relative pose that minimizes the sum of the first error and the second error, which is the relative pose of the two frames of point cloud data;

[0030] The sum of the first error and the second error is an error function f(R, T), and the formula of the error function is as follows: Pi is the coordinate of a point in the point cloud data that belongs to a plane feature point set or an edge feature point set. If Pi belongs to a plane feature point set, then Qi belongs to a point in the first candidate plane feature point set. If Pi belongs to an edge feature point set, then Qi belongs to a point in the first candidate edge feature point set. R is the relative rotation matrix between the point cloud data and the previous frame point cloud data. T is the relative translation matrix between the point cloud data and the previous frame point cloud data. The first undetermined relative pose that minimizes the error function is the relative pose (R, T) between the point cloud data and the previous frame point cloud data.

[0031] In combination with the first aspect, in a fifth possible implementation manner, obtaining an edge feature point set and a plane feature point set from the point cloud data includes:

[0032] Dividing the points obtained by the laser sensor located in the same plane in the point cloud data into multiple areas;

[0033] For any area of ​​the multiple areas, if there is a first target point with a smoothness less than a first threshold value among the first number of points with the smallest smoothness in the area, determining the first target point as a surface point;

[0034] For any area in the multiple areas, if there is a second target point with a smoothness greater than a second threshold among the second number of points with the highest smoothness in the area, determining the second target point as an edge point;

[0035] Dividing the surface points determined from the plurality of regions into the plane feature point set;

[0036] The edge points determined from the plurality of regions are divided into the edge feature point set.

[0037] In combination with the first aspect, in a sixth possible implementation, the calculation formula for the smoothness c of each point is as follows:

[0038]

[0039] Wherein, k represents the serial number of the laser sensor located on the kth plane, wherein the laser sensor serial number corresponds to the plane serial number one by one, X k,i is the distance corresponding to the point corresponding to the i-th light emitted by the laser sensor located on the k-th plane, X k,j is the distance corresponding to point j within the polar angle range of the point corresponding to the i-th light ray emitted by the laser sensor located in the k-th plane.

[0040] In combination with the first aspect, in a seventh possible implementation manner, constructing the three-dimensional image of the object under test based on the relative poses between two adjacent frames of point cloud data in the multiple frames of point cloud data and the multiple frames of point cloud data includes:

[0041] For any frame of point cloud data in the multiple frames of point cloud data, if a distance between the point cloud data and a previous key frame is greater than or equal to a third threshold, determining the point cloud data as a key frame;

[0042] Obtaining a first relative pose of the point cloud data relative to the first frame of point cloud data based on the relative pose of the point cloud data and the previous frame of point cloud data and the relative poses of any two adjacent point cloud data from the previous frame of point cloud data to the first frame of point cloud data;

[0043] Mapping the edge feature point set of the point cloud data to the constructed point cloud map based on the second undetermined relative pose to form a second set of candidate edge feature points, wherein the coordinate system of the point cloud map is the coordinate system corresponding to the first frame of point cloud data;

[0044] determining a third error based on the second candidate edge feature point set and the point cloud map;

[0045] Mapping the plane feature point set of the point cloud data to the point cloud map based on the second undetermined relative pose to form a second candidate plane feature point set;

[0046] determining a fourth error based on the second candidate plane feature point set and the point cloud map;

[0047] Determine the second undetermined relative pose that minimizes the sum of the third error and the fourth error, as the second relative pose between the point cloud data and the point cloud map;

[0048] Obtaining a target relative pose of the point cloud data relative to the point cloud map based on the first relative pose and the second relative pose;

[0049] If the distance between the point cloud data and the previous key frame is less than the third threshold, determining that the point cloud data is a non-key frame;

[0050] Determining a target relative pose of the point cloud data relative to the point cloud map based on a relative pose between the point cloud data and a previous key frame and a relative pose between the previous key frame and the point cloud map;

[0051] Based on the relative position of the target, mapping the surface points and edge points in the point cloud data to the point cloud map to obtain a point cloud map including the edge points and surface points in the multi-frame point cloud data;

[0052] A three-dimensional image of the measured object is constructed based on the point cloud map.

[0053] With reference to the first aspect, in an eighth possible implementation manner, obtaining a target relative pose of the point cloud data relative to the point cloud map based on the first relative pose and the second relative pose includes:

[0054] Acquire a third relative pose of the point cloud data collected by the pose collection module relative to the point cloud map;

[0055] The target relative posture is obtained based on the first relative posture, the second relative posture, the third relative posture and a second set weight, where the second set weight is used to represent the accuracy of the third relative posture.

[0056] According to a second aspect of an embodiment of the present disclosure, there is provided a map construction device, comprising:

[0057] A first acquisition module is used to acquire multiple frames of point cloud data corresponding to the measured object and timestamps corresponding to the multiple frames of point cloud data;

[0058] A second acquisition module is configured to acquire, for any frame of point cloud data in the multiple frames of point cloud data, a plurality of postures of the laser radar acquired by the posture acquisition module in the process of acquiring the point cloud data and timestamps corresponding to the plurality of postures;

[0059] a third acquisition module, configured to acquire target posture change information of the laser radar during the process of acquiring the point cloud data, wherein the target posture change information is obtained based on posture change information whose timestamp acquired by the posture acquisition module is closest to the timestamp of the frame point cloud data;

[0060] a first determining module, configured to determine a pose associated with the point cloud data based on the multiple poses, the timestamps corresponding to the multiple poses, the target pose change information, and the timestamp of the point cloud data, so as to obtain poses associated with the multiple frames of point cloud data;

[0061] a second determining module, configured to determine, for any frame of point cloud data in the multiple frames of point cloud data, a relative pose between two frames of point cloud data based on a pose associated with the point cloud data and a pose associated with a previous frame of point cloud data, so as to obtain a relative pose between two adjacent frames of point cloud data in the multiple frames of point cloud data;

[0062] A construction module is used to construct a three-dimensional image of the object under test based on the relative posture between two adjacent frames of point cloud data in the multiple frames of point cloud data and the multiple frames of point cloud data.

[0063] According to a third aspect of an embodiment of the present disclosure, there is provided an electronic device, including:

[0064] processor;

[0065] a memory for storing instructions executable by the processor;

[0066] The processor is configured to execute the instructions to implement the map construction method as described in the first aspect.

[0067] According to a fourth aspect of an embodiment of the present disclosure, a computer-readable storage medium is provided. When instructions in the storage medium are executed by a processor of an electronic device, the electronic device is enabled to execute the map construction method as described in the first aspect.

[0068] According to a fifth aspect of an embodiment of the present disclosure, a computer program product is provided, comprising a computer program / instruction, which implements the map construction method described in the first aspect when executed by a processor.

[0069] Through the above technical solutions, it can be seen that in the map construction method provided by the present application, in the process of establishing the association relationship between point cloud data and posture, for any frame of point cloud data, multiple postures of the laser radar collected by the posture acquisition module in the process of collecting the point cloud data and the timestamps corresponding to the multiple postures are obtained; the target posture change information of the laser radar in the process of collecting the frame of point cloud data is obtained; based on the multiple postures, the timestamps corresponding to the multiple postures, the target posture change information and the timestamp of the point cloud data, the posture associated with the point cloud data is determined to be more accurate, so that the relative posture between two adjacent frames of point cloud data is more accurate, and based on the relative posture between two adjacent frames of point cloud data in the multiple frames of point cloud data and the multiple frames of point cloud data, the three-dimensional image of the object under test is constructed to be more accurate. BRIEF DESCRIPTION OF THE DRAWINGS

[0070] In order to more clearly illustrate the embodiments of the present application or the technical solutions in the prior art, the following briefly introduces the drawings required for use in the embodiments or the description of the prior art. Obviously, the drawings described below are merely embodiments of the present application. For ordinary technicians in this field, other drawings can be obtained based on the provided drawings without any creative work.

[0071] Figure 1 A schematic diagram of the hardware architecture involved in the embodiments of the present application;

[0072] Figure 2 A schematic structural diagram of an implementation method of the laser radar provided in an embodiment of the present application;

[0073] Figure 3 A schematic diagram of a two-dimensional graph provided in an embodiment of the present application;

[0074] Figure 4 A schematic diagram showing the relationship between point cloud data and pose for related technologies;

[0075] Figure 5 A flowchart of a map construction method provided in an embodiment of the present application;

[0076] Figure 6 A schematic diagram of the integration of high-frequency high-precision positioning and low-frequency high-precision positioning provided in an embodiment of the present application;

[0077] Figure 7 A structural diagram of a map construction device provided in an embodiment of the present application;

[0078] Figure 8 The present invention is a block diagram showing a device for an electronic device according to an exemplary embodiment. DETAILED DESCRIPTION

[0079] The following will be combined with the drawings in the embodiments of this application to clearly and completely describe the technical solutions in the embodiments of this application. Obviously, the embodiments described are only part of the embodiments of this application, not all of the embodiments. Based on the embodiments in this application, all other embodiments obtained by ordinary technicians in this field without making creative efforts are within the scope of protection of this application.

[0080] The embodiments of the present application provide a map construction method and device. Before introducing the technical solution provided by the present application, the relevant technologies and hardware architecture involved in the present application are first described.

[0081] First, the hardware architecture involved in this application is described.

[0082] like Figure 1 FIG2 is a schematic diagram of the hardware architecture involved in the embodiment of the present application. The hardware architecture may include: a laser radar 11, a posture acquisition module 12, a carrying device 13 carrying the laser radar 11, and an electronic device 14.

[0083] The laser radar 11 can be carried by a movable carrying device 13, for example, the carrying device 13 can be a vehicle, a robot or a drone. Figure 1 The vehicle is used as an example for explanation.

[0084] Exemplarily, the laser radar 11 includes a plurality of laser sensors, which are arranged in sequence in a vertical direction. Each laser sensor can emit a beam of light at a preset angle (for example, 0.1° or 0.2°).

[0085] like Figure 2 The figure shows a schematic diagram of the structure of an implementation method of the laser radar provided in an embodiment of the present application.

[0086] Figure 2 This is only an example and does not limit the structure of the laser radar. Figure 2 As shown, the laser radar includes a fixing member 21 and a plurality of laser sensors 22 arranged on the fixing member 21.

[0087] For example, the layout of the plurality of laser sensors 22 may be as follows: Figure 2 As shown, the multiple laser sensors can be arranged on different sides of the fixing member 21. For example, the multiple laser sensors can be arranged on the same side of the fixing member 21.

[0088] Exemplarily, on the same plane (i.e., a plane perpendicular to the Z-axis), a laser sensor 22 is provided on the fixing member 21; exemplary, on the same plane, a plurality of laser sensors 22 located on different sides of the fixing member are provided on the fixing member 21.

[0089] In the embodiment of the present application, if the laser sensor 22 located on a certain plane scans one circle (that is, the sum of the rotation angles of the laser sensors 22 located on the same plane is 360°), the laser sensors located on different planes in the laser radar 11 all scan one circle, that is, the laser radar 11 scans one circle.

[0090] For example, the fixing member 21 may be controlled to rotate around the Z axis, thereby allowing the laser sensor to rotate.

[0091] It is understandable that the laser sensor 22 can emit a beam of light to a certain part of the object to be measured at the same time, and can obtain the reflected light of the part with respect to the beam of light.

[0092] The laser sensor 22 can emit a beam of light at intervals of a preset angle (e.g., 0.1° or 0.2°). Light emitted at different angles is different light. Light emitted by different laser sensors 22 is different light.

[0093] For example, the distance between the portion of the object to be measured and the laser sensor can be determined based on the emission time of the beam of light and the reflection time of the reflected light.

[0094] It is understood that the specific three-dimensional coordinates of the part of the object being measured are not only related to the distance, but also to the position of the laser sensor in the laser radar and the order of the light emitted by the laser sensor. This is because the laser sensor emits a beam of light at every preset angle. If the order of the emitted light is different, the laser sensor will rotate due to the fixed part 21, so the laser sensor's emission angle will be different, the laser sensor's emission time will be different, and the three-dimensional coordinates of the part of the object being measured will be different. If the position of the laser sensor in the laser radar is different (i.e., different heights in the Z-axis direction), the height of the part of the object being measured will be different, that is, the three-dimensional coordinates will be different.

[0095] Therefore, when a laser sensor i emits a beam of light, a point can be obtained. The collected information of this point includes: the position N of the laser sensor i at the laser radar i _SCAN, the order of light emitted by laser sensor i H j _SCAN, the distance between the laser sensor i and the corresponding part of the object being measured (that is, the order of the laser sensor i emitting is H j _SCAN beam corresponding to the point of distance).

[0096] The laser radar 11 scans a circle, and can obtain multiple points, and multiple points are called a frame of point cloud data. Because the laser radar 11 is constantly scanning, that is, the laser radar 11 can scan multiple circles, it can obtain multiple frames of point cloud data.

[0097] In an optional implementation, a two-dimensional graph may be constructed for each frame of point cloud data.

[0098] like Figure 3 , which is a schematic diagram of a two-dimensional graph provided in an embodiment of the present application.

[0099] Figure 3 In the figure, a laser sensor 22 is arranged on the same plane as an example for explanation.

[0100] like Figure 3 The left side of the diagram shows a schematic diagram of a laser radar 11 scanning one circle. Assuming that a total of N laser sensors 22 are arranged in the Z-axis direction, with one laser sensor 22 arranged in each plane, i ranges from 1 to N. If the laser sensor emits a beam of light every 0.2 degrees, a laser sensor 22 scans one circle and obtains 1800 points. Therefore, j ranges from 1 to 1800. Since there are N laser sensors 22, N*1800 points can be obtained, meaning that each frame of point cloud data contains N*1800 points.

[0101] like Figure 3 As shown on the right side of , for example, the horizontal axis of the two-dimensional graph is H j _SCAN, vertical coordinate is N i_SCAN. Each 2D coordinate corresponds to a point, and the value corresponding to each 2D coordinate is the distance corresponding to the point.

[0102] Assume that the two-dimensional coordinates (H j _SCAN, N i _SCAN) corresponds to the distance j,i, then the two-dimensional graph is as follows Figure 3 shown. Figure 3 This is just an example.

[0103] The carrier device 13 may be provided with a posture acquisition module 12 .

[0104] Exemplarily, the posture acquisition module 12 is used to acquire the posture of the lidar 11 .

[0105] It is understandable that as time goes by, the carrier device 13 will keep moving and the laser radar 11 will keep rotating. The posture acquisition module 12 can collect the posture of the laser radar 11 in the coordinate system where the carrier device is located.

[0106] Exemplarily, the posture includes the three-dimensional coordinates (X, Y, Z) and three-dimensional angles (angle 1, angle 2, angle 3) of the lidar in the coordinate system where the carrier device is located, where the angles are the angles relative to the X-axis, Y-axis and Z-axis of the coordinate system where the carrier device is located.

[0107] Exemplarily, the posture acquisition module 12 includes an IMU (Inertial measurement unit) module and an RTK (Real-time kinematic) module.

[0108] The IMU module is responsible for collecting and processing the three-axis acceleration signals of the carrier device 13 in the coordinate system where the carrier device is located, as well as the three-axis angular velocity signals relative to the navigation coordinate system.

[0109] The RTK module detects GNSS (Global Navigation Satellite System) satellite signals. If more than a preset number of satellite signals can be received simultaneously, the satellite signal is determined to be good.

[0110] The real-time position and heading of the lidar can be calculated based on the signals obtained from the RTK module and the IMU module, that is, the three-dimensional coordinates (X, Y, Z) and three-dimensional angles (angle 1, angle 2, angle 3) of the lidar.

[0111] As time goes by, the carrier device 13 keeps moving, so the posture acquisition module 12 needs to obtain the posture of the laser radar once every set time.

[0112] In an optional implementation, the electronic device 14 may be a server, a server cluster consisting of multiple servers, or a cloud computing server center. The electronic device 14 may include a processor, a memory, a network interface, and the like.

[0113] In an optional implementation, the electronic device 14 can be any electronic product that can interact with a user through one or more methods such as a keyboard, touchpad, touch screen, remote control, voice interaction or handwriting device, such as a mobile phone, laptop computer, tablet computer, PDA, personal computer, wearable device, smart TV, PAD, etc.

[0114] The electronic device 14 can receive multiple frames of point cloud data collected by the laser radar 11 and multiple positions of the laser radar collected by the position acquisition module 12, thereby executing the map construction method provided in the embodiment of the present application.

[0115] Next, the related technologies involved in this application are described.

[0116] In related technologies, after the electronic device 14 receives multiple frames of point cloud data collected by the laser radar 11 and multiple postures of the laser radar collected by the posture acquisition module 12, it is necessary to establish an association between the point cloud data and the posture.

[0117] It's understood that the multiple frames of point cloud data obtained by the LiDAR are timestamped. Each frame of point cloud data corresponds to the initial acquisition moment, which can be the initial moment of a LiDAR scan. It's also understood that acquiring a frame of point cloud data requires a time period, and during this time period, the carrier device is constantly moving and the LiDAR is constantly rotating.

[0118] It can be understood that the posture of the laser radar obtained by the posture acquisition module has a timestamp, and the timestamp corresponding to the posture of the laser radar is the acquisition moment of the posture.

[0119] In related technologies, the process of establishing the association between pose and point cloud data is as follows: Figure 4 As shown, it is a schematic diagram of the relationship between point cloud data and posture established by related technologies.

[0120] Assume that the lidar obtains two frames of point cloud data, namely the first frame point cloud data 41 (corresponding to timestamp T_lidar1) and the second frame point cloud data 42 (corresponding to timestamp T_lidar2); the pose acquisition module obtains 12 poses, namely: pose 401 (corresponding to timestamp T_imu1), pose 402 (corresponding to timestamp T_imu2), ..., pose 412 (corresponding to timestamp T_imu12).

[0121] If the 12 postures are sorted from early to late, the timestamps corresponding to them are: T_imu1, T_imu2, ..., T_imu12.

[0122] When establishing the association relationship between point cloud data and pose in the related technology, the association relationship is established based on the timestamp of the pose and the timestamp of the point cloud data. If the timestamp T_lidar1 is between the timestamp T_imu1 and the timestamp T_imu2, and if the timestamp T_lidar2 is between the timestamp T_imu11 ​​and the timestamp T_imu12, then it can be obtained Figure 4 The figure shown.

[0123] Since the timestamp T_lidar1 is between the timestamp T_imu1 and the timestamp T_imu2, the pose A corresponding to T_lidar1 is obtained based on the pose 401 and the pose 402 to establish the association relationship between the first frame point cloud data 41 and the pose A; since the timestamp T_lidar2 is between the timestamp T_imu11 ​​and the timestamp T_imu12, the pose B corresponding to T_lidar2 can be obtained based on the pose 411 and the pose 412 to establish the association relationship between the second frame point cloud data 42 and the pose B.

[0124] It is understandable that it takes a period of time to collect a frame of point cloud data, and during this period of time, the carrier device is constantly moving and the laser radar is constantly rotating. The timestamp corresponding to the point cloud data is the initial moment. For example, assuming that the point cloud data includes N*1800 points, since N laser sensors each obtain a point at the same moment, that is, N points can be obtained at each moment, that is, N*1 points. The timestamp of the point cloud data may be the moment when the first group of N*1 points is obtained. The time when the 1000th group of N*1 points is obtained may be later than the timestamp T_imu2, or later than the timestamp T_imu3. Therefore, for the first frame of point cloud data 41, it may be necessary to obtain the pose associated with the actual timestamp T_lidar1 based on pose 401, pose 402, pose 403, pose 404, etc. Therefore, the method of establishing the association between pose and point cloud data in the related art is inaccurate.

[0125] Because the method used in related technologies to establish the relationship between pose and point cloud data is inaccurate, the relative pose between two frames of point cloud data is inaccurate. The point cloud map constructed based on the relative pose of two adjacent frames of point cloud data is also inaccurate, resulting in an inaccurate 3D image of the object being measured based on the point cloud map.

[0126] To address this, an embodiment of the present application provides a map construction method, which improves the way of establishing the association relationship between posture and point cloud data, making the association relationship between posture and point cloud data more accurate.

[0127] The map construction method provided in the embodiment of the present application is described below in combination with the above hardware architecture and related technologies.

[0128] like Figure 5 , which is a flow chart of a map construction method provided in an embodiment of the present application. The method can be applied to the above-mentioned electronic device 14 , and the method includes the following steps S51 to S56 during implementation.

[0129] Step S51: Acquire multiple frames of point cloud data corresponding to the measured object and timestamps corresponding to the multiple frames of point cloud data.

[0130] For example, in different application scenarios, the measured objects are different. For example, the measured objects can be any one or more of the environment, mountains, canyons, tables, chairs, people, animals, etc.

[0131] Exemplarily, the multi-frame point cloud data is collected by a lidar.

[0132] Steps S52 to S55 are executed for any frame of point cloud data.

[0133] Step S52: Acquire multiple postures of the laser radar collected by the posture acquisition module in the process of collecting the point cloud data and the timestamps corresponding to the multiple postures.

[0134] It is understandable that different postures correspond to different coordinate systems. Figure 1 As shown, when the carrier device 13 moves to a certain position, a coordinate system is established with the current position as the center point. Therefore, different postures correspond to different coordinate systems.

[0135] Exemplarily, the implementation of step S52 includes the following steps: determining a time range based on the timestamp of the point cloud data and the duration of the point cloud data; obtaining multiple poses whose timestamps belong to the time range; obtaining a pose whose timestamp is earlier than the time range and is closest to the earliest time in the time range.

[0136] by Figure 4 For example, assuming that the point cloud data in step S52 is the first frame of point cloud data 41, and assuming that the acquisition duration of each frame of point cloud data is duration 1, based on the timestamp T_lidar1 corresponding to the first frame of point cloud data 41 and duration 1, it can be determined that the time range for acquiring the first frame of point cloud data 41 is [T_lidar1, T_lidar1+duration 1].

[0137] Get multiple poses whose timestamps fall within the time range [T_lidar1, T_lidar1+duration 1]. Assume that the timestamps of poses 402, 403, and 404 fall within this time range.

[0138] The timestamp of pose 401 is closest to the earliest time T_lidar1 in the time range [T_lidar1, T_lidar1+duration1].

[0139] In summary, in the process of collecting the first frame of point cloud data 41, the multiple postures of the laser radar collected by the posture collection module are: posture 401, posture 402, posture 403 and posture 404.

[0140] Step S53: Obtain target posture change information of the laser radar during the process of collecting the point cloud data.

[0141] The target posture change information is obtained based on the posture change information whose timestamp collected by the posture acquisition module is closest to the timestamp of the frame point cloud data.

[0142] In an optional implementation, if the carrying equipment is traveling at a non-uniform speed, that is, the target posture change information may change over time, then the target posture change information is collected in real time by the posture acquisition module, that is, the target position change information includes the posture change information whose timestamp collected by the posture acquisition module is closest to the timestamp of the frame point cloud data.

[0143] In an optional implementation, since the carrier device generally travels at a constant speed, the target posture change information can be the posture change information whose timestamp collected by the posture acquisition module is closest to the timestamp of the frame point cloud data.

[0144] In an optional implementation, regardless of whether the carrier is traveling at a constant speed, target pose change information can be calculated based on the multiple poses, their timestamps, and the timestamp of the point cloud data. It is understood that the multiple poses include pose A whose timestamp, acquired by the pose acquisition module, is closest to the timestamp of the frame of point cloud data. Therefore, pose change information for the closest timestamp, acquired by the pose acquisition module, is obtained based on the multiple poses and their timestamps.

[0145] Step S54: Determine the pose associated with the point cloud data based on the multiple poses, the timestamps corresponding to the multiple poses, the target pose change information, and the timestamp of the point cloud data.

[0146] In an optional implementation, the points contained in each frame of point cloud data correspond to the same pose.

[0147] It is understandable that as time goes by, the carrier device is constantly moving. For the same laser sensor, it emits a beam of light at every preset angle, so the time of emitting different light rays is different. When the same laser sensor emits different light rays, the coordinate system of the carrier device is different, that is, the postures corresponding to different points obtained by the same laser sensor in each frame of point cloud data may be different.

[0148] For each target point in each frame of point cloud data (a target point is any point in that frame of point cloud data), the duration 2 of that target point relative to the first point emitted by the laser sensor can be calculated based on the order of light emitted by the laser sensor. Based on the pose of the first point emitted by the laser sensor, the target pose change information of the laser sensor, and the duration 2, the corresponding pose of the target point can be determined. In other words, the pose associated with each point in that frame of point cloud data can be determined. Based on the pose associated with each point in that frame of point cloud data, the pose associated with that frame of point cloud data can be determined.

[0149] For each frame of point cloud data, the poses associated with the multiple frames of point cloud data can be obtained through steps S52 to S54.

[0150] Step S55: Based on the posture associated with the point cloud data and the posture associated with the previous frame of point cloud data, determine the relative posture between two frames of point cloud data to obtain the relative posture between two adjacent frames of point cloud data in the multi-frame point cloud data.

[0151] It can be understood that since different poses correspond to different coordinate systems, based on the relative pose between the two frames of point cloud data, the coordinate systems of the poses associated with the two frames of point cloud data can be unified.

[0152] Still Figure 4 For example, assuming that two adjacent frames of point cloud data are the first frame point cloud data 41 (corresponding to timestamp T_lidar1) and the second frame point cloud data 42 (corresponding to timestamp T_lidar2), the relative pose between these two frames of point cloud data is the relative pose between the pose associated with the first frame point cloud data 41 and the pose associated with the second frame point cloud data 42.

[0153] Step S56: constructing a three-dimensional image of the object under test based on the relative poses between two adjacent frames of point cloud data in the multi-frame point cloud data and the multi-frame point cloud data.

[0154] It can be understood that based on the relative posture between two adjacent frames of point cloud data in the multi-frame point cloud data, the coordinate systems of the postures respectively associated with the multi-frame point cloud data can be unified, so that the multi-frame point cloud data can be mapped to the same point cloud map, so that a three-dimensional image of the object under test can be obtained based on the point cloud map.

[0155] In the map construction method provided in the embodiment of the present application, in the process of establishing the association relationship between point cloud data and posture, for any frame of point cloud data, based on the multiple postures of the laser radar collected by the posture acquisition module in the process of collecting the point cloud data and the timestamps corresponding to the multiple postures; the target posture change information of the laser radar in the process of collecting the frame of point cloud data is obtained; based on the multiple postures, the timestamps corresponding to the multiple postures, the target posture change information and the timestamp of the point cloud data, the posture associated with the point cloud data is determined to be more accurate, so that the relative posture between two adjacent frames of point cloud data is more accurate, and based on the relative posture between two adjacent frames of point cloud data in the multiple frames of point cloud data and the multiple frames of point cloud data, the three-dimensional image of the object under test is constructed to be more accurate.

[0156] In an optional implementation, there are multiple implementations of step S53. The embodiment of the present application provides but is not limited to the following method, which includes the following steps A11 to A13.

[0157] Step A11: Determine the first position change information of the laser radar based on the timestamps corresponding to the multiple position postures and the multiple position postures.

[0158] It can be understood that since the position and posture of the lidar at different timestamps are known, the first position change information of the lidar can be determined.

[0159] Exemplarily, the posture includes three-dimensional coordinates and three-dimensional angles in the corresponding coordinate system, and the first posture change information includes: change information of the three-dimensional coordinates (ie, speed and driving direction) and change information of the three-dimensional angle, ie, angular velocity.

[0160] For example, the posture change information between two adjacent time stamps can be calculated based on the posture of the two adjacent time stamps. In order to obtain the posture change information corresponding to each of the two adjacent time stamps, that is, the first posture change information includes the posture change information corresponding to each of the two adjacent time stamps, that is, the first posture change information includes multiple posture change information. Figure 4 For example, based on the posture 401 and the posture 402, the posture change information between the timestamp T_imu1 and the timestamp T_imu2 can be calculated.

[0161] Exemplarily, the first pose change information may be calculated based on the multiple poses and the earliest timestamp and the latest timestamp in the multiple poses.

[0162] Step A12: Obtain the second posture change information of the laser radar collected by the posture collection module.

[0163] It is understandable that the posture acquisition module can acquire the second posture change information of the laser radar.

[0164] Exemplarily, the posture acquisition module can acquire the second posture change information at a timestamp corresponding to the point cloud data.

[0165] Exemplarily, the timestamp corresponding to the second pose change information collected by the pose acquisition module is the timestamp closest to the timestamp corresponding to the point cloud data. It is understood that the pose acquisition module can collect pose change information at different times. The second pose change information closest to the timestamp of the point cloud data is closer to the pose change information when the lidar collected the frame of point cloud data.

[0166] It is understandable that, in general, the speed and angular velocity of the carrier device 13 change uniformly. Therefore, the obtained second posture change information can represent the change of the laser radar posture over a period of time.

[0167] Exemplarily, the posture acquisition module can acquire the second posture change information in real time.

[0168] Step A13: Determine target posture change information based on the first posture change information, the second posture change information and a first set weight, where the first set weight is used to characterize the accuracy of the second posture change information.

[0169] For example, a larger first set weight indicates a more accurate second posture change information, and thus, when determining the target posture change information, the second posture change information accounts for a larger proportion than the first posture change information. A smaller first set weight indicates a less accurate second posture change information, and thus, when determining the target posture change information, the second posture change information accounts for a smaller proportion than the first posture change information.

[0170] For example, the first set weight may be determined based on actual conditions.

[0171] Exemplarily, the first set weight λ is obtained based on the number of satellites for calculating the second posture change information and the velocity covariance matrix of the lidar. For example, the formula is as follows:

[0172] λ = a*V_xyzcov + b*GPS_num, where V_xyzcov is the velocity covariance matrix of the lidar. GPS_num is the number of satellites. a and b are calibration parameters, obtained through testing and calibration based on the accuracy of the pose acquisition module itself.

[0173] In an optional implementation, step A13 may calculate the target pose change information based on the following formula:

[0174] V=λV rtk / imu +(1-λ)V slam , where V is the target posture change information, V rtk / imu is the second posture change information, V slam is the first posture change information, and λ is the first set weight.

[0175] In an optional implementation, there are multiple implementations of step S55. The embodiment of the present application provides but is not limited to the following method. The method includes the following steps B1 to B6 during implementation.

[0176] Step B1: Acquire an edge feature point set and a plane feature point set from the point cloud data, wherein the edge feature point set includes one or more edge points, and the plane feature point set includes one or more surface points.

[0177] It is understandable that when constructing a three-dimensional image of the object under test, the three-dimensional image of the object under test can be constructed through the edge points and surface points of the object under test, so it is necessary to obtain the edge feature point set and the plane feature point set from the point cloud data.

[0178] In an optional implementation, there are multiple implementations of step B1. The embodiment of the present application provides but is not limited to the following method, which includes steps B11 to B13 during implementation.

[0179] Step B11: clustering the multiple points contained in the point cloud data to obtain multiple clusters, each cluster including multiple points.

[0180] In an optional implementation, there are multiple implementations of step B11. The embodiments of the present application provide but are not limited to the following two implementations.

[0181] The first step B11 is to use the Euclidean clustering method to Figure 3 The point cloud data shown is clustered and segmented. Euclidean clustering is a method for clustering points in point cloud data based on Euclidean distance. The cluster radius setting is related to the distance between the measured object and the lidar. Using this method with a variable cluster radius threshold can achieve better results in clustering 3D point cloud data based on scan lines. The setting rules are as follows: The relationship between the setting method of cluster radius r and distance d is:

[0182]

[0183] Where r is the cluster radius, and d is the distance from the part of the object scanned by the beam to the laser sensor.

[0184] The second implementation method of step B11 is: clustering the points in the point cloud data using a breadth-first search algorithm.

[0185] Multiple clusters can be obtained through the first or second method, each cluster including one or more points.

[0186] Step B12: A cluster whose number of points is greater than or equal to the threshold A is called a valid cluster.

[0187] If the number of points in a cluster is less than the threshold A, it means that the points in the cluster are likely to be noise points, that is, the points in the cluster do not correspond to any part of the object being measured. If the number of points in a cluster is greater than or equal to the threshold A, it means that the points in the cluster should correspond to a part of the object being measured.

[0188] Step B13: Acquire an edge feature point set and a plane feature point set from the valid cluster.

[0189] In an optional implementation, there are multiple implementations of step B13, and the embodiments of the present application provide but are not limited to the following four.

[0190] The first implementation method of step B13 includes the following steps C11 to C15.

[0191] Step C11: Divide the points in the point cloud data obtained by the laser sensor and located in the same plane into multiple areas.

[0192] Exemplarily, step C11 is to divide the points obtained by the laser sensor located in the same plane from the valid clusters in the point cloud data into multiple areas.

[0193] Assuming that the laser sensor emits a beam of light every 0.2° and the number of laser sensors located on the same plane is 1, the laser sensors located on the same plane can obtain 1800 points by scanning a circle.

[0194] Exemplarily, step C11 may divide the points obtained by the laser sensors located on the same plane into multiple areas on an even basis. Assuming that the number of the multiple areas is 6, each area contains 300 points.

[0195] For example, step C11 can evenly divide the valid points obtained by the laser sensors located on the same plane into multiple regions. Assuming that the number of the multiple regions is 6, each region contains less than 300 points. For example, the points contained in the valid cluster are called valid points.

[0196] Exemplarily, step C11 may divide the points obtained by the laser sensors located on the same plane unevenly to obtain multiple areas, and the number of points included in different areas may be different.

[0197] Steps C12 to C14 are performed for any one of the multiple areas.

[0198] Step C12: If there is a first target point with a smoothness less than a first threshold value among the first number of points with the smallest smoothness in the region, determine that the first target point is a surface point.

[0199] For example, the calculation formula for the smoothness c of each point is as follows:

[0200] Where k represents the position on the kth plane (e.g. Figure 3 N shown K _SCAN) laser sensor serial number, wherein the laser sensor serial number corresponds to the plane serial number one by one, X k,i is the distance corresponding to the point corresponding to the i-th light emitted by the laser sensor located on the k-th plane, X k,j is the distance corresponding to point j within the polar angle range of the point corresponding to the i-th light ray emitted by the laser sensor located in the k-th plane.

[0201] Assuming that the j points in the polar angle range of the point corresponding to the i-th light ray emitted by the laser sensor located in the k-th plane are the 1st point, the 3rd point, and the 4th point respectively, then the values ​​of j are 1, 3, and 4.

[0202] Step C13: If there is a second target point with a smoothness greater than a second threshold value among the second number of points with the highest smoothness in the area, determine the second target point as an edge point.

[0203] Assuming that the smoothness of the first number of points with the smallest smoothness in the region is greater than or equal to a first threshold, there are no face points in the region. If the smoothness of the second number of points with the largest smoothness in the region is less than or equal to a second threshold, there are no edge points in the region. In this way, edge points and face points can be obtained from the multiple regions.

[0204] Step C14: Divide the surface points determined from the multiple regions into the plane feature point set.

[0205] Step C15: Divide the edge points determined in the multiple regions into the edge feature point set.

[0206] Exemplarily, if the laser radar includes N laser sensors, the number of laser sensors located in the same plane is 1, and the points obtained by the laser sensors located in the same plane are divided into L areas, then the multiple areas in step C14 and step C15 are N*L areas.

[0207] The second implementation method of step B13 includes the following steps C21 to C25.

[0208] Step C21: Divide the points obtained by the laser sensors located on the same plane in the valid cluster into multiple areas.

[0209] Steps C22 to C23 are performed for any one of the multiple areas.

[0210] Step C22: Determine the points in the region whose smoothness is less than the first threshold as surface points.

[0211] Step C23: Determine the points in the region whose smoothness is higher than the second threshold as edge points.

[0212] In this way, edge points and surface points can be obtained from the multiple regions.

[0213] Step C24: Divide the surface points determined from the multiple regions into the plane feature point set.

[0214] Step C25: Divide the edge points determined in the multiple regions into the edge feature point set.

[0215] For the description of the number of the multiple regions in step C24 and step C25 , reference may be made to the description of the number of the multiple regions in step C14 and step C15 .

[0216] The third implementation method of step B13 includes the following steps C31 to C32.

[0217] Step C31: If there is a first target point whose smoothness is less than a first threshold value among the third number of points with the smallest smoothness in the point cloud data, determine that the first target point is a surface point to obtain a plane feature point set including the surface point.

[0218] Step C32: If there is a second target point whose smoothness is greater than a second threshold among the fourth number of points with the highest smoothness in the point cloud data, determine the second target point as an edge point to obtain an edge feature point set including the edge point.

[0219] The fourth implementation method of step B13 includes the following steps C41 to C42.

[0220] Step C41: points in the point cloud data with a smoothness less than a first threshold are determined as surface points to obtain a plane feature point set including the surface points.

[0221] Step C42: points in the point cloud data with a smoothness higher than a second threshold are determined as edge points to obtain an edge feature point set including the edge points.

[0222] The first implementation method is different from the third implementation method in that the first implementation method divides the points obtained by the laser sensor located on the same plane into regions, so that the layout of the obtained edge points and surface points is more uniform, making the constructed point cloud map more accurate.

[0223] The second implementation method is different from the fourth implementation method in that the second implementation method divides the points obtained by the laser sensors located on the same plane into regions, so that the layout of the obtained edge points and surface points is more uniform, making the constructed point cloud map more accurate.

[0224] The first implementation method is compared with the second implementation method in that in the first implementation method, the smoothness of the first number of points with the smallest smoothness is compared with the first threshold, and the smoothness of the second number of points with the highest smoothness is compared with the second threshold, so that the surface points and edge points obtained are more accurate.

[0225] Step B2: Based on the first undetermined relative pose, the edge feature point set of the previous frame point cloud data is mapped to the target coordinate system where the point cloud data is located to form a first candidate edge feature point set.

[0226] It can be understood that the first undetermined relative pose is unknown.

[0227] Step B3: Mapping the plane feature point set of the previous frame point cloud data to the target coordinate system based on the first undetermined relative pose to form a first candidate plane feature point set.

[0228] Step B4: determining a first error based on the first candidate edge feature point set and the edge feature point set located in the target coordinate system.

[0229] The edge feature point set in the target coordinate system is the edge feature point set of the point cloud data of the current frame.

[0230] Exemplarily, step B4 includes: for any point in the set of edge feature points in the point cloud data, obtaining two first points closest to the point from the first set of candidate edge feature points, obtaining first distances between the point and the first point, and determining the sum of the first distances corresponding to each point in the set of plane feature points as a first error.

[0231] Step B5: Determine a second error based on the first candidate plane feature point set and the plane feature point set located in the target coordinate system.

[0232] The set of plane feature points in the target coordinate system is the set of plane feature points of the point cloud data of the current frame.

[0233] Exemplarily, step B5 includes: for any point in the plane feature point set in the point cloud data, obtaining second distances between the point and the second point from three second points in the first candidate plane feature point set that are closest to the point; and determining the sum of the second distances corresponding to each point in the plane feature point set as the second error.

[0234] Step B6: Determine the first undetermined relative pose that minimizes the sum of the first error and the second error, which is the relative pose of the two frames of point cloud data.

[0235] Exemplarily, the sum of the first error and the second error is an error function f(R, T), and the formula of the error function is as follows: Where pi is the coordinate of a point in the current frame's point cloud data that belongs to the plane feature point set or edge feature point set. If pi belongs to the plane feature point set, then qi belongs to the second point in the first candidate plane feature set. If pi belongs to the edge feature point set, then qi belongs to the first point in the first candidate edge feature set. R is the relative rotation matrix between the two frames of point cloud data, and T is the relative translation matrix between the two frames of point cloud data.

[0236] The first undetermined relative pose that minimizes the error function is the relative pose (R, T) between the two frames of point cloud data.

[0237] In an optional implementation, there are multiple implementations of step S56, and the embodiments of the present application provide but are not limited to the following three.

[0238] The first implementation of step S56 includes steps D11 to D13.

[0239] For any frame of point cloud data in the multiple frames of point cloud data, step D11 to step D12 are executed.

[0240] Step D11: Based on the relative pose of the point cloud data and the previous frame point cloud data and the relative pose between any two adjacent point cloud data from the previous frame point cloud data to the first frame point cloud data, obtain the first relative pose of the point cloud data relative to the first frame point cloud data.

[0241] Assuming that the point cloud data of the current frame is the 6th frame point cloud data, the first relative pose of the 6th frame point cloud data relative to the 1st frame point cloud data can be calculated based on the relative pose of the 6th frame point cloud data and the 5th frame point cloud data, the relative pose of the 5th frame point cloud data and the 4th frame point cloud data, the relative pose of the 4th frame point cloud data and the 3rd frame point cloud data, the relative pose of the 3rd frame point cloud data and the 2nd frame point cloud data, and the relative pose of the 2nd frame point cloud data and the 1st frame point cloud data.

[0242] Step D12: Based on the first relative posture, map the edge points and surface points of the point cloud data into a point cloud map.

[0243] Steps D11 to D12 are performed for each frame of point cloud data to obtain a final point cloud map.

[0244] Step D13: Construct a three-dimensional image of the object to be measured based on the point cloud map.

[0245] For example, if the coordinate system corresponding to the pose associated with the first frame of point cloud data is the coordinate system of the point cloud map, then the first relative pose is the mapping relationship between the coordinate system corresponding to the point cloud data and the coordinate system of the point cloud map. Therefore, the edge points and surface points of the point cloud data can be mapped to the point cloud map based on the first relative pose.

[0246] It is understandable that the relative pose between two adjacent frames of point cloud data may have a certain error, and the first relative pose is calculated based on the relative pose between the two adjacent frames of point cloud data. This is equivalent to accumulating the relative pose errors between the two adjacent frames of point cloud data. In other words, the accumulated error is large, and the obtained first relative pose is inaccurate. Based on this, the present application provides a second implementation method of step S56.

[0247] The second implementation of step S56 includes steps D21 to D27.

[0248] For any frame of point cloud data in the multiple frames of point cloud data, steps D21 to D26 are executed.

[0249] Step D21: Mapping the edge feature point set in the point cloud data to the constructed point cloud map based on the second relative pose to be determined to form a second candidate edge feature point set.

[0250] It can be understood that the second undetermined relative pose is unknown.

[0251] Step D22: Determine a third error based on the second candidate edge feature point set and the point cloud map.

[0252] Exemplarily, step D22 includes: for any point in the edge feature point set in the point cloud map, obtaining two third points closest to the point from the second candidate edge feature point set; obtaining the third distances between the point and the third point respectively; and determining the sum of the third distances corresponding to each point in the edge feature point set in the point cloud map as the third error.

[0253] Exemplarily, the edge feature point set in the point cloud map is the union of the edge feature point sets of each frame of point cloud data that has been mapped to the point cloud map.

[0254] Step D23: Mapping the plane feature point set of the point cloud data to the point cloud map based on the second undetermined relative pose to form a second candidate plane feature point set.

[0255] Step D24: Determine a fourth error based on the second candidate plane feature point set and the point cloud map.

[0256] Exemplarily, step D24 includes: for any point in the plane feature point set in the point cloud map, three fourth points closest to the point in the second candidate plane feature point set; obtaining the fourth distances between the point and the fourth point respectively; and determining the sum of the fourth distances corresponding to each point in the plane feature point set in the point cloud map as the fourth error.

[0257] Exemplarily, the planar feature point set in the point cloud map is the union of the planar feature point sets of each frame of point cloud data that has been mapped to the point cloud map.

[0258] Step D25: Determine the second undetermined relative pose that minimizes the sum of the third error and the fourth error, which is the second relative pose between the point cloud data and the point cloud map.

[0259] Step D26: Based on the second relative posture, the edge points and surface points of the point cloud data are mapped to a point cloud map.

[0260] Steps D21 to D26 are executed for each frame of point cloud data to obtain a final point cloud map.

[0261] Step D27: Construct a three-dimensional image of the object to be measured based on the point cloud map.

[0262] It can be understood that in the second implementation method, the second relative pose of the frame point cloud data and the point cloud map is calculated for each frame of point cloud data. Although the calculated second relative pose is more accurate than the above-mentioned first relative pose, the time to calculate the second relative pose is longer, which makes the time to construct the three-dimensional image of the object under test longer. Based on this, the present application provides a third implementation method.

[0263] The third implementation of step S56 includes steps D301 to D311.

[0264] For any frame of point cloud data in the multiple frames of point cloud data, steps D301 to D310 are executed.

[0265] Step D301: Determine whether the distance between the point cloud data and the previous key frame is greater than or equal to a third threshold. If so, determine that the point cloud data is a key frame and execute step D302. If not, execute step D309.

[0266] Step D302: Based on the relative pose of the point cloud data and the previous frame point cloud data and the relative pose between each two adjacent point cloud data from the previous frame point cloud data to the first frame point cloud data, obtain the first relative pose of the point cloud data relative to the first frame point cloud data.

[0267] It can be understood that if the distance between the point cloud data and the previous key frame is greater than or equal to the third threshold, it means that the point cloud data and the previous key frame are not repeated key frames.

[0268] A keyframe is a frame of point cloud data.

[0269] Step D303: Mapping the edge feature point set of the point cloud data to the constructed point cloud map based on the second relative pose to be determined to form a second candidate edge feature point set.

[0270] Step D304: Determine a third error based on the second candidate edge feature point set and the point cloud map.

[0271] Step D305: Mapping the plane feature point set of the point cloud data to the point cloud map based on the second undetermined relative pose to form a second candidate plane feature point set.

[0272] Step D306: Determine a fourth error based on the second candidate plane feature point set and the point cloud map.

[0273] Step D307: Determine the second undetermined relative pose that minimizes the sum of the third error and the fourth error, which is the second relative pose between the point cloud data and the point cloud map.

[0274] Step D308: Based on the first relative pose and the second relative pose, obtain a target relative pose of the point cloud data relative to the point cloud map.

[0275] Step D309: Determine the target relative pose of the point cloud data relative to the point cloud map based on the relative pose between the point cloud data and the previous key frame and the relative pose between the previous key frame and the point cloud map.

[0276] Step D310: Based on the relative position of the target, map the surface points and edge points in the point cloud data to the point cloud map.

[0277] By executing steps D301 to D310 for each frame of point cloud data, a point cloud map including edge points and surface points in the multiple frames of point cloud data can be obtained.

[0278] Step D311: constructing a three-dimensional image of the measured object based on the point cloud map.

[0279] It is understood that in the embodiment of the present application, the process of obtaining the target relative posture in step D309 and the process of obtaining the first relative posture in step D302 are referred to as high-frequency high-precision positioning. The process of obtaining the second relative posture is referred to as low-frequency high-precision positioning. In the embodiment of the present application, high-frequency high-precision positioning and low-frequency high-precision positioning are integrated.

[0280] In order for those skilled in the art to better understand the second implementation method provided in the embodiment of the present application, it is described below with reference to the accompanying drawings.

[0281] like Figure 6 As shown, it is a schematic diagram of the integration of high-frequency high-precision positioning and low-frequency high-precision positioning provided in an embodiment of the present application.

[0282] like Figure 6 As shown, if 6 frames of point cloud data are included, namely: point cloud data 61, point cloud data 62, point cloud data 63, point cloud data 64 and point cloud data 65, it is assumed that point cloud data 61, point cloud data 63 and point cloud data 65 are key frames, and point cloud data 62 and point cloud data 64 are non-key frames.

[0283] Since the point cloud data 61 is the first frame of point cloud data, the coordinate system of the point cloud data 61 is the coordinate system of the point cloud map. That is, for the point cloud data 61, the pose obtained by high-frequency precision positioning is the same as the pose obtained by low-frequency precision positioning.

[0284] For point cloud data 62, since it is a non-key frame, low-frequency high-precision positioning is not performed on point cloud data 62. In the process of performing high-frequency high-precision positioning, the target relative posture of point cloud data 62 and point cloud map can be obtained based on the relative posture of itself (i.e. point cloud data 62) and the previous frame key frame (i.e. point cloud data 61), and the relative posture of the previous frame key frame (i.e. point cloud data 61) and the point cloud map (i.e. point cloud data 61).

[0285] For the point cloud data 63, since it is a key frame, the first relative pose and the second relative pose of the point cloud data 63 are obtained for the point cloud data 63, thereby obtaining the target relative pose of the point cloud data 63 relative to the point cloud map.

[0286] For point cloud data 64, since it is a non-key frame, low-frequency and high-precision positioning is not performed on point cloud data 62. In the process of performing high-frequency and high-precision positioning, the target relative posture of point cloud data 64 and the point cloud map can be obtained based on the relative posture of itself (i.e., point cloud data 64) and the previous frame key frame (i.e., point cloud data 63), and the relative posture of the previous frame key frame (i.e., point cloud data 63) and the point cloud map (i.e., point cloud data 61).

[0287] In an optional implementation, if ΔT tk0_ok0is the first relative pose O of the point cloud data 63 K0 and the second relative pose T K0 The transformation matrix of ΔT ok0_o1 is the relative pose between point cloud data 64 and point cloud data 63; (ΔT tk0_ok0 )^-1 is ΔT tk0_ok0 The inverse of , the calculation formula of the target relative pose T1 of the point cloud data 64 relative to the point cloud map is as follows:

[0288] T1=T k0 *ΔT tk0_Ok0 *ΔT Ok0_O1 *(ΔT tk0_Ok0 )^-1.

[0289] In the third implementation method, for key frames, the target relative pose of the key frames relative to the point cloud map obtained using the second implementation method is relatively accurate; for non-key frames, the relative pose between the key frame and the previous frame, as well as the relative pose between the key frame and the point cloud map, can be used to determine the target relative pose between the key frame and the point cloud map. Since the relative pose between the key frame and the point cloud map of the previous frame is obtained using the second implementation method, that is, the relative pose between the key frame and the point cloud map of the previous frame is accurate, the target relative pose of the key frame and the point cloud map is determined to be relatively accurate based on the relative pose between the key frame and the previous frame and the relative pose between the key frame and the point cloud map of the previous frame, that is, the cumulative error in the first implementation method is eliminated.

[0290] In an optional implementation, there are multiple implementations of step D308, and the embodiments of the present application provide but are not limited to the following two.

[0291] The first implementation of step D308 includes the following steps E11 to E12.

[0292] Step E11: Acquire a third relative pose of the point cloud data collected by the pose collection module relative to the point cloud map.

[0293] Step E12: Obtain the target relative posture based on the first relative posture, the second relative posture, the third relative posture and a second set weight, where the second set weight is used to represent the accuracy of the third relative posture.

[0294] Exemplarily, the second set weight is the same as the first set weight.

[0295] Illustratively, the second set weight is different from the first set weight.

[0296] For example, if the second set weight is larger, it means that the third relative posture is more accurate, then in the process of obtaining the target relative posture, the third relative posture contributes more than the first relative posture and the second relative posture; if the second set weight is smaller, it means that the third relative posture is less accurate, then in the process of obtaining the target relative posture, the third relative posture contributes less than the first relative posture and the second relative posture.

[0297] The second implementation method of step D308 includes the following steps E21 to E24.

[0298] Step E21: Obtain loop constraint information corresponding to the point cloud data.

[0299] Exemplarily, the loop constraint information includes a noise value of loop detection. Exemplarily, the noise value is Among them, β is related to the angular covariance matrix of the carrier equipment and the number of satellites.

[0300] Exemplarily, β = d*Pose_cov+e*GPS_num, where d and e are set values, and Pose_cov is the angle covariance matrix of the carrier device.

[0301] Step E22: Acquire a third relative pose of the point cloud data collected by the pose collection module relative to the point cloud map.

[0302] Step E23: Obtain the target relative pose based on the loop constraint information, the first relative pose, the second relative pose, the third relative pose and a second set weight, where the second set weight is used to characterize the accuracy of the third relative pose.

[0303] For example, for key frames, since the loop constraint information, the first relative pose, the second relative pose, and the third relative pose are used as constraint conditions, the obtained target relative pose is more accurate, thereby eliminating the cumulative error.

[0304] The above embodiments disclosed in the present application describe the method in detail. The method of the present application can be implemented using various devices. Therefore, the present application also discloses a device, and a specific embodiment is given below for detailed description.

[0305] like Figure 7 , which is a structural diagram of a map construction device provided in an embodiment of the present application, includes: a first acquisition module 71, a second acquisition module 72, a third acquisition module 73, a first determination module 74, a second determination module 75, and a construction module 76, wherein:

[0306] A first acquisition module 71 is configured to acquire multiple frames of point cloud data corresponding to the measured object and timestamps corresponding to the multiple frames of point cloud data;

[0307] A second acquisition module 72 is configured to acquire, for any frame of point cloud data in the multiple frames of point cloud data, a plurality of postures of the laser radar acquired by the posture acquisition module during the process of acquiring the point cloud data and timestamps corresponding to the plurality of postures;

[0308] A third acquisition module 73 is configured to acquire target pose change information of the laser radar during the process of acquiring the point cloud data, wherein the target pose change information is acquired based on pose change information whose timestamp acquired by the pose acquisition module is closest to the timestamp of the frame of point cloud data;

[0309] a first determining module 74 for determining a pose associated with the point cloud data based on the multiple poses, the timestamps corresponding to the multiple poses, the target pose change information, and the timestamp of the point cloud data, so as to obtain poses associated with the multiple frames of point cloud data;

[0310] a second determining module 75 for determining, for any frame of point cloud data in the multiple frames of point cloud data, a relative pose between two frames of point cloud data based on a pose associated with the point cloud data and a pose associated with a previous frame of point cloud data, so as to obtain a relative pose between two adjacent frames of point cloud data in the multiple frames of point cloud data;

[0311] The construction module 76 is used to construct a three-dimensional image of the object under test based on the relative posture between two adjacent frames of point cloud data in the multiple frames of point cloud data and the multiple frames of point cloud data.

[0312] In an optional implementation, the third acquisition module includes:

[0313] A first determining unit is configured to determine first pose change information of the laser radar based on the timestamps corresponding to the multiple poses and the multiple poses;

[0314] A first acquisition unit is configured to obtain second posture change information of the laser radar collected by the posture acquisition module, wherein the timestamp corresponding to the second posture change information collected by the posture acquisition module is the timestamp closest to the timestamp corresponding to the point cloud data;

[0315] The second determining unit is used to determine the target posture change information based on the first posture change information, the second posture change information and a first set weight, where the first set weight is used to represent the accuracy of the second posture change information.

[0316] In an optional implementation, the second determining unit is specifically configured to:

[0317] The target pose change information is determined based on the following formula:

[0318] V=λV rtk / imu +(1-λ)V slam , where V is the target posture change information, V rtk / imu is the second posture change information, V slam is the first posture change information, λ is the first set weight, and the first set weight is obtained based on the number of satellites for calculating the second posture change information and the velocity covariance matrix of the lidar.

[0319] In an optional implementation, λ=a*V_xyzcov+b*GPS_num, where V_xyzcov is the velocity covariance matrix of the lidar, GPS_num is the number of satellites, and a and b are calibration parameters.

[0320] In an optional implementation, the second determining module includes:

[0321] A second acquisition unit is configured to acquire an edge feature point set and a plane feature point set from the point cloud data, wherein the edge feature point set includes one or more edge points, and the plane feature point set includes one or more surface points;

[0322] A first mapping unit is configured to map the edge feature point set of the previous frame of point cloud data to a target coordinate system where the point cloud data is located based on a first relative pose to be determined, to form a first candidate edge feature point set;

[0323] A second mapping unit is configured to map the plane feature point set of the previous frame point cloud data to the target coordinate system based on the first undetermined relative pose to form a first candidate plane feature point set;

[0324] a third determining unit, configured to determine a first error based on the first candidate edge feature point set and the edge feature point set located in the target coordinate system;

[0325] a fourth determining unit, configured to determine a second error based on the first candidate plane feature point set and the plane feature point set located in the target coordinate system;

[0326] a fifth determining unit, configured to determine the first undetermined relative pose that minimizes the sum of the first error and the second error, the first relative pose being the relative pose of two frames of point cloud data;

[0327] The sum of the first error and the second error is an error function f(R, T), and the formula of the error function is as follows: Pi is the coordinate of a point in the point cloud data that belongs to a plane feature point set or an edge feature point set. If Pi belongs to a plane feature point set, then Qi belongs to a point in the first candidate plane feature point set. If Pi belongs to an edge feature point set, then Qi belongs to a point in the first candidate edge feature point set. R is the relative rotation matrix between the point cloud data and the previous frame point cloud data. T is the relative translation matrix between the point cloud data and the previous frame point cloud data. The first undetermined relative pose that minimizes the error function is the relative pose (R, T) between the point cloud data and the previous frame point cloud data.

[0328] In an optional implementation, the second obtaining unit includes:

[0329] A first division subunit is configured to divide the points obtained by the laser sensor and located in the same plane in the point cloud data into a plurality of regions;

[0330] a first determining subunit, configured to, for any area of ​​the plurality of areas, determine that, if a first target point having a smoothness less than a first threshold value exists among a first number of points having the smallest smoothness in the area, the first target point is a surface point;

[0331] a second determining subunit, configured to, for any area of ​​the plurality of areas, determine that, if a second target point having a smoothness greater than a second threshold value exists among a second number of points having the highest smoothness in the area, the second target point is an edge point;

[0332] A second division subunit is configured to divide the surface points determined in the plurality of regions into the plane feature point set;

[0333] The third division subunit is configured to divide the edge points determined in the plurality of regions into the edge feature point set.

[0334] In an optional implementation, the calculation formula for the smoothness c of each point is as follows:

[0335] Wherein, k represents the serial number of the laser sensor located on the kth plane, wherein the laser sensor serial number corresponds to the plane serial number one by one, X k,i is the distance corresponding to the point corresponding to the i-th light emitted by the laser sensor located on the k-th plane, X k,j is the distance corresponding to point j within the polar angle range of the point corresponding to the i-th light ray emitted by the laser sensor located in the k-th plane.

[0336] In an optional implementation, the building blocks include:

[0337] a sixth determining unit, configured to, for any frame of point cloud data among the multiple frames of point cloud data, determine that the point cloud data is a key frame if a distance between the point cloud data and a previous key frame is greater than or equal to a third threshold;

[0338] a third acquiring unit, configured to acquire a first relative pose of the point cloud data relative to the first frame of point cloud data based on the relative pose of the point cloud data and the previous frame of point cloud data and the relative poses of any two adjacent point cloud data from the previous frame of point cloud data to the first frame of point cloud data;

[0339] a third mapping unit, configured to map the edge feature point set of the point cloud data to the constructed point cloud map based on the second undetermined relative pose to form a second set of candidate edge feature points, wherein the coordinate system of the point cloud map is the coordinate system corresponding to the first frame of point cloud data;

[0340] a seventh determining unit, configured to determine a third error based on the second candidate edge feature point set and the point cloud map;

[0341] a fourth mapping unit, configured to map the plane feature point set of the point cloud data to the point cloud map based on the second undetermined relative pose to form a second candidate plane feature point set;

[0342] an eighth determining unit, configured to determine a fourth error based on the second candidate plane feature point set and the point cloud map;

[0343] a ninth determining unit, configured to determine the second undetermined relative pose that minimizes the sum of the third error and the fourth error, the second relative pose between the point cloud data and the point cloud map;

[0344] a fourth acquiring unit, configured to acquire a target relative pose of the point cloud data relative to the point cloud map based on the first relative pose and the second relative pose;

[0345] a tenth determining unit, configured to determine that the point cloud data is a non-key frame if the distance between the point cloud data and a previous key frame is less than the third threshold;

[0346] an eleventh determining unit, configured to determine a target relative pose of the point cloud data relative to the point cloud map based on a relative pose between the point cloud data and a previous key frame and a relative pose between the previous key frame and the point cloud map;

[0347] a fifth mapping unit, configured to map the surface points and edge points in the point cloud data to the point cloud map based on the relative position of the target, so as to obtain a point cloud map including the edge points and surface points in the multi-frame point cloud data;

[0348] A construction unit is used to construct a three-dimensional image of the object under test based on the point cloud map.

[0349] In an optional implementation, the fourth obtaining unit includes:

[0350] A first acquisition subunit is configured to acquire a third relative pose of the point cloud data collected by the pose acquisition module relative to the point cloud map;

[0351] The second acquisition subunit is configured to obtain the target relative posture based on the first relative posture, the second relative posture, the third relative posture, and a second set weight, wherein the second set weight is used to characterize the accuracy of the third relative posture.

[0352] Regarding the apparatus in the above embodiment, the specific manner in which each module performs operations has been described in detail in the embodiment of the method, and will not be elaborated here.

[0353] Figure 8 The present invention is a block diagram showing a device for an electronic device according to an exemplary embodiment.

[0354] The electronic device includes, but is not limited to, a processor 81 , a memory 82 , a network interface 83 , an I / O controller 84 , and a communication bus 85 .

[0355] It should be noted that those skilled in the art can understand that Figure 8 The structure of the electronic device shown in the figure does not constitute a limitation on the electronic device, and the electronic device may include Figure 8 More or fewer components may be shown, or certain components may be combined, or the components may be arranged differently.

[0356] The following combination Figure 8 A detailed introduction to the various components of electronic equipment:

[0357] The processor 81 is the control center of the electronic device. It connects all parts of the electronic device using various interfaces and circuits. By running or executing software programs and / or modules stored in memory 82 and accessing data stored in memory 82, it performs various functions of the electronic device and processes data, thereby providing overall monitoring of the electronic device. The processor 81 may include one or more processing units; illustratively, the processor 81 may integrate an application processor and a modem processor. The application processor primarily handles the operating system, user interface, and application programs, while the modem processor primarily handles wireless communications. It is understood that the modem processor may not be integrated into the processor 81.

[0358] The processor 81 may be a central processing unit (CPU), an application specific integrated circuit (ASIC), or one or more integrated circuits configured to implement the embodiments of the present invention;

[0359] The memory 82 may include a memory, such as a high-speed random-access memory (RAM) 821 and a read-only memory (ROM) 822, and may also include a large-capacity storage device 823, such as at least one disk storage device. Of course, the electronic device may also include hardware required for other services.

[0360] The memory 82 is used to store instructions executable by the processor 81. The processor 81 has the function of executing the map construction method.

[0361] A wired or wireless network interface 83 is configured to connect the electronic device to a network.

[0362] The processor 81, memory 82, network interface 83, and I / O controller 84 can be interconnected via a communication bus 85, which can be an ISA (Industry Standard Architecture) bus, a PCI (Peripheral Component Interconnect) bus, or an EISA (Extended Industry Standard Architecture) bus. The bus can be divided into an address bus, a data bus, a control bus, etc.

[0363] In an exemplary embodiment, the electronic device may be implemented by one or more application-specific integrated circuits (ASICs), digital signal processors (DSPs), digital signal processing devices (DSPDs), programmable logic devices (PLDs), field programmable gate arrays (FPGAs), controllers, microcontrollers, microprocessors, or other electronic components to perform the above-mentioned map construction method.

[0364] In an exemplary embodiment, the present disclosure provides a storage medium including instructions, such as a memory 82 including instructions, which can be executed by a processor 81 of an electronic device to perform the above method. Alternatively, the storage medium can be a non-transitory computer-readable storage medium, such as a ROM, a random access memory (RAM), a CD-ROM, a magnetic tape, a floppy disk, an optical data storage device, etc.

[0365] In an exemplary embodiment, a computer-readable storage medium is also provided, which can be directly loaded into the internal memory of a computer, such as the above-mentioned memory 82, and contains software code. After being loaded and executed by a computer, the computer program can implement the steps shown in any embodiment of the above-mentioned map construction method.

[0366] In an exemplary embodiment, a computer program product is also provided, which can be directly loaded into the internal memory of a computer, such as the memory contained in the electronic device, and contains software code. After being loaded and executed by the computer, the computer program can implement the steps shown in any embodiment of the map construction method described above.

[0367] It should be noted that the features described in the various embodiments of this specification can be replaced or combined with each other. For device or system embodiments, since they are basically similar to method embodiments, the description is relatively simple, and the relevant parts can be referred to the partial description of the method embodiment.

[0368] It should also be noted that, in this document, relational terms such as first and second, etc., are used only to distinguish one entity or operation from another entity or operation, and do not necessarily require or imply any such actual relationship or order between these entities or operations. Moreover, the terms "comprises," "comprising," or any other variations thereof are intended to cover non-exclusive inclusion, such that a process, method, article, or device comprising a series of elements includes not only those elements, but also other elements not explicitly listed, or elements inherent to such process, method, article, or device. In the absence of further limitations, an element defined by the phrase "comprising a ..." does not exclude the presence of additional identical elements in the process, method, article, or device comprising the element.

[0369] The steps of the methods or algorithms described in conjunction with the embodiments disclosed herein may be implemented directly using hardware, a software module executed by a processor, or a combination of the two. The software module may be placed in a random access memory (RAM), internal memory, read-only memory (ROM), electrically programmable ROM, electrically erasable programmable ROM, registers, a hard disk, a removable disk, a CD-ROM, or any other form of storage medium known in the art.

[0370] The above description of the disclosed embodiments is intended to enable one skilled in the art to implement or use the present application. Various modifications to these embodiments will be readily apparent to one skilled in the art, and the general principles defined herein may be implemented in other embodiments without departing from the spirit or scope of the present application. Therefore, the present application is not limited to the embodiments shown herein, but is intended to conform to the widest scope consistent with the principles and novel features disclosed herein.

Claims

1. A map construction method, characterized in that: include: Obtaining multiple frames of point cloud data corresponding to the measured object and timestamps corresponding to the multiple frames of point cloud data; For any frame of point cloud data in the multiple frames of point cloud data, obtaining multiple poses of the laser radar collected by the pose collection module in the process of collecting the point cloud data and timestamps corresponding to the multiple poses; Obtaining target pose change information of the laser radar during the process of collecting the point cloud data, wherein the target pose change information is obtained based on pose change information whose timestamp collected by the pose acquisition module is closest to the timestamp of the frame of point cloud data; Determining a pose associated with the point cloud data based on the multiple poses, the timestamps corresponding to the multiple poses, the target pose change information, and the timestamp of the point cloud data to obtain poses associated with the multiple frames of point cloud data; For any frame of point cloud data in the multiple frames of point cloud data, determining a relative pose between the two frames of point cloud data based on a pose associated with the point cloud data and a pose associated with a previous frame of point cloud data, so as to obtain a relative pose between two adjacent frames of point cloud data in the multiple frames of point cloud data; A three-dimensional image of the object to be measured is constructed based on the relative postures between two adjacent frames of point cloud data in the multiple frames of point cloud data and the multiple frames of point cloud data.

2. The map construction method according to claim 1, characterized in that: The acquiring of target pose change information of the laser radar during the process of collecting the point cloud data includes: Determining first position change information of the laser radar based on the timestamps respectively corresponding to the multiple position poses and the multiple position poses; Obtaining second posture change information of the laser radar collected by the posture acquisition module, wherein the timestamp corresponding to the second posture change information collected by the posture acquisition module is the timestamp closest to the timestamp corresponding to the point cloud data; Target posture change information is determined based on the first posture change information, the second posture change information, and a first set weight, where the first set weight is used to represent the accuracy of the second posture change information.

3. The map construction method according to claim 2, characterized in that: The determining of the target posture change information based on the first posture change information, the second posture change information, and the first set weight includes: The target pose change information is determined based on the following formula: V=λV rtk / imu +(1-λ)V slam Among them, V is the target posture change information, V rtk / imu is the second posture change information, V slam is the first posture change information, λ is the first set weight, and the first set weight is obtained based on the number of satellites for calculating the second posture change information and the velocity covariance matrix of the lidar.

4. The map construction method according to claim 3, characterized in that: λ=a*V_xyzcov+b*GPS_num Where V_xyzcov is the velocity covariance matrix of the lidar, GPS_num is the number of satellites, and a and b are calibration parameters.

5. The map construction method according to any one of claims 1 to 4, characterized in that: Determining the relative pose between two frames of point cloud data based on the pose associated with the point cloud data and the pose associated with a previous frame of point cloud data comprises: Acquire an edge feature point set and a plane feature point set from the point cloud data, wherein the edge feature point set includes one or more edge points, and the plane feature point set includes one or more surface points; Mapping the edge feature point set of the previous frame of point cloud data to the target coordinate system of the point cloud data based on the first undetermined relative pose to form a first candidate edge feature point set; Mapping the plane feature point set of the previous frame point cloud data to the target coordinate system based on the first undetermined relative pose to form a first candidate plane feature point set; determining a first error based on the first candidate edge feature point set and a set of edge feature points located in the target coordinate system; determining a second error based on the first candidate plane feature point set and the plane feature point set located in the target coordinate system; Determine the first undetermined relative pose that minimizes the sum of the first error and the second error, which is the relative pose of the two frames of point cloud data; The sum of the first error and the second error is an error function f(R, T), and the formula of the error function is as follows: Pi is the coordinate of a point in the point cloud data that belongs to a plane feature point set or an edge feature point set. If Pi belongs to a plane feature point set, then Qi belongs to a point in the first candidate plane feature point set. If Pi belongs to an edge feature point set, then Qi belongs to a point in the first candidate edge feature point set. R is the relative rotation matrix between the point cloud data and the previous frame point cloud data. T is the relative translation matrix between the point cloud data and the previous frame point cloud data. The first undetermined relative pose that minimizes the error function is the relative pose (R, T) between the point cloud data and the previous frame point cloud data.

6. The map construction method according to claim 5, characterized in that: The acquiring of an edge feature point set and a plane feature point set from the point cloud data comprises: Dividing the points obtained by the laser sensor located in the same plane in the point cloud data into multiple areas; For any area of ​​the multiple areas, if there is a first target point with a smoothness less than a first threshold value among the first number of points with the smallest smoothness in the area, determining the first target point as a surface point; For any area in the multiple areas, if there is a second target point with a smoothness greater than a second threshold among the second number of points with the highest smoothness in the area, determining the second target point as an edge point; Dividing the surface points determined from the plurality of regions into the plane feature point set; The edge points determined from the plurality of regions are divided into the edge feature point set.

7. The map construction method according to claim 6, characterized in that: The calculation formula for the smoothness c of each point is as follows: Wherein, k represents the serial number of the laser sensor located on the kth plane, wherein the laser sensor serial number corresponds to the plane serial number one by one, X k,i is the distance corresponding to the point corresponding to the i-th light emitted by the laser sensor located on the k-th plane, X k,j is the distance corresponding to point j within the polar angle range of the point corresponding to the i-th light ray emitted by the laser sensor located in the k-th plane.

8. The map construction method according to claim 5, characterized in that: The constructing of the three-dimensional image of the object under test based on the relative poses between two adjacent frames of point cloud data in the multiple frames of point cloud data and the multiple frames of point cloud data includes: For any frame of point cloud data in the multiple frames of point cloud data, if a distance between the point cloud data and a previous key frame is greater than or equal to a third threshold, determining the point cloud data as a key frame; Obtaining a first relative pose of the point cloud data relative to the first frame of point cloud data based on the relative pose of the point cloud data and the previous frame of point cloud data and the relative poses of any two adjacent point cloud data from the previous frame of point cloud data to the first frame of point cloud data; Mapping the edge feature point set of the point cloud data to the constructed point cloud map based on the second undetermined relative pose to form a second set of candidate edge feature points, wherein the coordinate system of the point cloud map is the coordinate system corresponding to the first frame of point cloud data; determining a third error based on the second candidate edge feature point set and the point cloud map; Mapping the plane feature point set of the point cloud data to the point cloud map based on the second undetermined relative pose to form a second candidate plane feature point set; determining a fourth error based on the second candidate plane feature point set and the point cloud map; Determine the second undetermined relative pose that minimizes the sum of the third error and the fourth error, as the second relative pose between the point cloud data and the point cloud map; Obtaining a target relative pose of the point cloud data relative to the point cloud map based on the first relative pose and the second relative pose; If the distance between the point cloud data and the previous key frame is less than the third threshold, determining that the point cloud data is a non-key frame; Determining a target relative pose of the point cloud data relative to the point cloud map based on a relative pose between the point cloud data and a previous key frame and a relative pose between the previous key frame and the point cloud map; Based on the relative position of the target, mapping the surface points and edge points in the point cloud data to the point cloud map to obtain a point cloud map including the edge points and surface points in the multi-frame point cloud data; A three-dimensional image of the measured object is constructed based on the point cloud map.

9. The map construction method according to claim 8, characterized in that: The obtaining, based on the first relative pose and the second relative pose, a target relative pose of the point cloud data relative to the point cloud map includes: Acquire a third relative pose of the point cloud data collected by the pose collection module relative to the point cloud map; The target relative posture is obtained based on the first relative posture, the second relative posture, the third relative posture and a second set weight, where the second set weight is used to represent the accuracy of the third relative posture.

10. A map construction device, characterized in that: include: A first acquisition module is used to acquire multiple frames of point cloud data corresponding to the measured object and timestamps corresponding to the multiple frames of point cloud data; A second acquisition module is configured to acquire, for any frame of point cloud data in the multiple frames of point cloud data, a plurality of postures of the laser radar acquired by the posture acquisition module in the process of acquiring the point cloud data and timestamps corresponding to the plurality of postures; a third acquisition module, configured to acquire target posture change information of the laser radar during the process of acquiring the point cloud data, wherein the target posture change information is obtained based on posture change information whose timestamp acquired by the posture acquisition module is closest to the timestamp of the frame point cloud data; a first determining module, configured to determine a pose associated with the point cloud data based on the multiple poses, the timestamps corresponding to the multiple poses, the target pose change information, and the timestamp of the point cloud data, so as to obtain poses associated with the multiple frames of point cloud data; a second determining module, configured to determine, for any frame of point cloud data in the multiple frames of point cloud data, a relative pose between two frames of point cloud data based on a pose associated with the point cloud data and a pose associated with a previous frame of point cloud data, so as to obtain a relative pose between two adjacent frames of point cloud data in the multiple frames of point cloud data; A construction module is used to construct a three-dimensional image of the object under test based on the relative posture between two adjacent frames of point cloud data in the multiple frames of point cloud data and the multiple frames of point cloud data.

Citation Information

Patent Citations

  • Point cloud map generation method and device, and electronic equipment

    CN111784834A

  • Multi-Camera / Lidar / IMU-based multi-sensor SLAM method

    CN111983639A