CN118067114A - Map construction method and device, electronic equipment and storage medium - Google Patents
Map construction method and device, electronic equipment and storage medium Download PDFInfo
- Publication number
- CN118067114A CN118067114A CN202410496267.8A CN202410496267A CN118067114A CN 118067114 A CN118067114 A CN 118067114A CN 202410496267 A CN202410496267 A CN 202410496267A CN 118067114 A CN118067114 A CN 118067114A
- Authority
- CN
- China
- Prior art keywords
- map
- coordinate system
- matching
- under
- local
- Prior art date
- Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
- Granted
Links
- 238000010276 construction Methods 0.000 title claims abstract description 51
- 238000003860 storage Methods 0.000 title claims abstract description 12
- 238000001514 detection method Methods 0.000 claims abstract description 120
- 238000000034 method Methods 0.000 claims abstract description 44
- 238000005457 optimization Methods 0.000 claims description 22
- 238000004590 computer program Methods 0.000 claims description 16
- 238000012545 processing Methods 0.000 claims description 7
- 238000006243 chemical reaction Methods 0.000 claims description 6
- 238000013507 mapping Methods 0.000 claims 1
- 238000010586 diagram Methods 0.000 description 16
- 230000008569 process Effects 0.000 description 12
- 238000005259 measurement Methods 0.000 description 6
- 238000006073 displacement reaction Methods 0.000 description 5
- 238000001914 filtration Methods 0.000 description 5
- 239000011159 matrix material Substances 0.000 description 5
- 238000004422 calculation algorithm Methods 0.000 description 4
- 230000006870 function Effects 0.000 description 4
- 230000004927 fusion Effects 0.000 description 4
- 230000009471 action Effects 0.000 description 3
- 238000004364 calculation method Methods 0.000 description 3
- 238000000605 extraction Methods 0.000 description 3
- 230000001133 acceleration Effects 0.000 description 2
- 238000005516 engineering process Methods 0.000 description 2
- 230000010354 integration Effects 0.000 description 2
- 238000004519 manufacturing process Methods 0.000 description 2
- 238000012986 modification Methods 0.000 description 2
- 230000004048 modification Effects 0.000 description 2
- 239000007787 solid Substances 0.000 description 2
- 230000009466 transformation Effects 0.000 description 2
- 230000004075 alteration Effects 0.000 description 1
- 230000005540 biological transmission Effects 0.000 description 1
- 230000003287 optical effect Effects 0.000 description 1
- 230000000750 progressive effect Effects 0.000 description 1
- HOWHQWFXSLOJEF-MGZLOUMQSA-N systemin Chemical compound NCCCC[C@H](N)C(=O)N[C@@H](CCSC)C(=O)N[C@@H](CCC(N)=O)C(=O)N[C@@H]([C@@H](C)O)C(=O)N[C@@H](CC(O)=O)C(=O)OC(=O)[C@@H]1CCCN1C(=O)[C@H]1N(C(=O)[C@H](CC(O)=O)NC(=O)[C@H](CCCN=C(N)N)NC(=O)[C@H](CCCCN)NC(=O)[C@H](CO)NC(=O)[C@H]2N(CCC2)C(=O)[C@H]2N(CCC2)C(=O)[C@H](CCCCN)NC(=O)[C@H](CO)NC(=O)[C@H](CCC(N)=O)NC(=O)[C@@H](NC(=O)[C@H](C)N)C(C)C)CCC1 HOWHQWFXSLOJEF-MGZLOUMQSA-N 0.000 description 1
- 108010050014 systemin Proteins 0.000 description 1
- 238000013519 translation Methods 0.000 description 1
Classifications
-
- G—PHYSICS
- G01—MEASURING; TESTING
- G01C—MEASURING DISTANCES, LEVELS OR BEARINGS; SURVEYING; NAVIGATION; GYROSCOPIC INSTRUMENTS; PHOTOGRAMMETRY OR VIDEOGRAMMETRY
- G01C21/00—Navigation; Navigational instruments not provided for in groups G01C1/00 - G01C19/00
- G01C21/38—Electronic maps specially adapted for navigation; Updating thereof
- G01C21/3804—Creation or updating of map data
- G01C21/3833—Creation or updating of map data characterised by the source of data
- G01C21/3841—Data obtained from two or more sources, e.g. probe vehicles
-
- G—PHYSICS
- G01—MEASURING; TESTING
- G01C—MEASURING DISTANCES, LEVELS OR BEARINGS; SURVEYING; NAVIGATION; GYROSCOPIC INSTRUMENTS; PHOTOGRAMMETRY OR VIDEOGRAMMETRY
- G01C21/00—Navigation; Navigational instruments not provided for in groups G01C1/00 - G01C19/00
- G01C21/26—Navigation; Navigational instruments not provided for in groups G01C1/00 - G01C19/00 specially adapted for navigation in a road network
- G01C21/28—Navigation; Navigational instruments not provided for in groups G01C1/00 - G01C19/00 specially adapted for navigation in a road network with correlation of data from several navigational instruments
- G01C21/30—Map- or contour-matching
-
- G—PHYSICS
- G06—COMPUTING; CALCULATING OR COUNTING
- G06T—IMAGE DATA PROCESSING OR GENERATION, IN GENERAL
- G06T7/00—Image analysis
- G06T7/30—Determination of transform parameters for the alignment of images, i.e. image registration
- G06T7/33—Determination of transform parameters for the alignment of images, i.e. image registration using feature-based methods
- G06T7/337—Determination of transform parameters for the alignment of images, i.e. image registration using feature-based methods involving reference images or patches
-
- G—PHYSICS
- G06—COMPUTING; CALCULATING OR COUNTING
- G06T—IMAGE DATA PROCESSING OR GENERATION, IN GENERAL
- G06T7/00—Image analysis
- G06T7/70—Determining position or orientation of objects or cameras
- G06T7/73—Determining position or orientation of objects or cameras using feature-based methods
- G06T7/74—Determining position or orientation of objects or cameras using feature-based methods involving reference images or patches
-
- G—PHYSICS
- G06—COMPUTING; CALCULATING OR COUNTING
- G06V—IMAGE OR VIDEO RECOGNITION OR UNDERSTANDING
- G06V10/00—Arrangements for image or video recognition or understanding
- G06V10/70—Arrangements for image or video recognition or understanding using pattern recognition or machine learning
- G06V10/74—Image or video pattern matching; Proximity measures in feature spaces
- G06V10/75—Organisation of the matching processes, e.g. simultaneous or sequential comparisons of image or video features; Coarse-fine approaches, e.g. multi-scale approaches; using context analysis; Selection of dictionaries
- G06V10/751—Comparing pixel values or logical combinations thereof, or feature values having positional relevance, e.g. template matching
-
- Y—GENERAL TAGGING OF NEW TECHNOLOGICAL DEVELOPMENTS; GENERAL TAGGING OF CROSS-SECTIONAL TECHNOLOGIES SPANNING OVER SEVERAL SECTIONS OF THE IPC; TECHNICAL SUBJECTS COVERED BY FORMER USPC CROSS-REFERENCE ART COLLECTIONS [XRACs] AND DIGESTS
- Y02—TECHNOLOGIES OR APPLICATIONS FOR MITIGATION OR ADAPTATION AGAINST CLIMATE CHANGE
- Y02T—CLIMATE CHANGE MITIGATION TECHNOLOGIES RELATED TO TRANSPORTATION
- Y02T10/00—Road transport of goods or passengers
- Y02T10/10—Internal combustion engine [ICE] based vehicles
- Y02T10/40—Engine management systems
Landscapes
- Engineering & Computer Science (AREA)
- Remote Sensing (AREA)
- Radar, Positioning & Navigation (AREA)
- General Physics & Mathematics (AREA)
- Physics & Mathematics (AREA)
- Theoretical Computer Science (AREA)
- Computer Vision & Pattern Recognition (AREA)
- Automation & Control Theory (AREA)
- Computing Systems (AREA)
- Software Systems (AREA)
- Medical Informatics (AREA)
- General Health & Medical Sciences (AREA)
- Evolutionary Computation (AREA)
- Multimedia (AREA)
- Databases & Information Systems (AREA)
- Artificial Intelligence (AREA)
- Health & Medical Sciences (AREA)
- Navigation (AREA)
Abstract
The invention provides a map construction method, a map construction device, electronic equipment and a storage medium, and relates to the technical field of online map construction. The method comprises the following steps: acquiring the pose of a self-vehicle under a first coordinate system at the current moment and a local map under the first coordinate system at the previous moment; acquiring a detection map under a second coordinate system at the current moment; according to the pose of the vehicle at the current moment, converting the detection map under the second coordinate system to obtain the detection map under the first coordinate system at the current moment; and matching the detection map at the current moment with the local map at the previous moment under the first coordinate system, correcting the vehicle pose at the current moment, obtaining the updated detection map at the current moment, matching the updated detection map with the local map at the previous moment, and updating the positions of map elements in the local map at the previous moment according to the second matching result, so that the local map is optimized at each moment, the accurate construction of the online map is realized, and the accuracy of the real-time constructed online map is improved.
Description
Technical Field
The present invention relates to the field of online map construction technologies, and in particular, to a map construction method, a map construction device, an electronic device, and a storage medium.
Background
At present, an automatic driving lane-level map construction and positioning technology relates to realizing high-precision, stable and reliable map transmission and positioning of a mass-production automatic driving vehicle on a drivable road, and mainly relates to the following aspects: offline high-precision maps, crowdsourcing maps, online maps, etc.
However, the current end-to-end online vector map construction method can effectively solve the modeling and matching problems of map elements, and greatly improve the precision, but the fluctuation is still great, and the precision of the online real-time constructed map is not high, for example, the position of the map elements is inaccurate. Therefore, how to improve the accuracy of the real-time constructed online map is a technical problem to be solved by the invention.
Disclosure of Invention
Based on the technical problems, the invention provides a map construction method, a map construction device, electronic equipment and a storage medium, so as to improve the accuracy of an online map constructed in real time.
The first aspect of the invention provides a map construction method, which comprises the following steps:
Acquiring the pose of a vehicle under a first coordinate system at the current moment, and acquiring a local map under the first coordinate system at the previous moment; the meaning of "self-vehicle" in the present invention is: a current vehicle;
Obtaining a detection map under a second coordinate system at the current moment according to the sensor data at the current moment;
According to the pose of the self-vehicle at the current moment under the first coordinate system, converting the detection map under the second coordinate system at the current moment into the first coordinate system to obtain the detection map under the first coordinate system at the current moment;
Matching the detection map under the first coordinate system at the current moment with the local map under the first coordinate system at the previous moment to obtain a first matching result;
correcting the pose of the self-propelled vehicle at the current moment under a first coordinate system according to the first matching result to obtain an updated pose of the self-propelled vehicle at the current moment under the first coordinate system;
According to the updated pose of the vehicle under the first coordinate system at the current moment, an updated detection map under the first coordinate system at the current moment is obtained, and then the updated detection map is matched with the local map under the first coordinate system at the previous moment, so that a second matching result is obtained;
and updating the position of the map element in the local map under the first coordinate system at the previous moment according to the second matching result.
A second aspect of the present invention provides a map construction apparatus, the apparatus comprising:
The acquisition module is used for acquiring the pose of the vehicle under the first coordinate system at the current moment and acquiring the local map under the first coordinate system at the previous moment;
The detection module is used for obtaining a detection map under a second coordinate system at the current moment according to the sensor data at the current moment;
The conversion module is used for converting the detection map under the second coordinate system at the current moment into the first coordinate system according to the pose of the self-vehicle under the first coordinate system at the current moment to obtain the detection map under the first coordinate system at the current moment;
The first matching module is used for matching the detection map under the first coordinate system at the current moment with the local map under the first coordinate system at the previous moment to obtain a first matching result;
The pose updating module is used for correcting the pose of the current self-propelled vehicle under the first coordinate system according to the first matching result to obtain the updated pose of the current self-propelled vehicle under the first coordinate system;
The second matching module is used for obtaining an updated detection map under the first coordinate system at the current moment according to the updated pose of the self-vehicle under the first coordinate system at the current moment, and then matching the updated detection map with the local map under the first coordinate system at the previous moment to obtain a second matching result;
And the map updating module is used for updating the position of the map element in the local map under the first coordinate system at the previous moment according to the second matching result.
A third aspect of the present invention provides an electronic device comprising: comprising a memory, a processor and a computer program stored on the memory and executable on the processor, which computer program, when executed by the processor, implements the map construction method as in the first aspect of the invention.
A fourth aspect of the present invention provides a computer readable storage medium having stored thereon a computer program which when executed by a processor implements the map construction method of the first aspect of the present invention.
By the map construction method, the vehicle pose and the detection map of each moment are obtained in real time, and the local map of the last moment is obtained; after converting the detection map at the current moment into the same coordinate system based on the vehicle position, the detection map at the current moment in the same coordinate system can be matched with the local map at the previous moment for the first time, so that the vehicle position is optimized based on a first matching result; then, the detection map is converted into the same coordinate system again based on the optimized vehicle pose, the updated detection map is matched with the local map for the second time, and the local map is updated based on the second matching result, so that the local map is optimized at each moment, accurate construction of the online map is realized, and the accuracy of the online map constructed in real time is improved.
Drawings
In order to more clearly illustrate the technical solutions of the embodiments of the present invention, the drawings that are needed in the description of the embodiments of the present invention will be briefly described below, it being obvious that the drawings in the following description are only some embodiments of the present invention, and that other drawings may be obtained according to these drawings without inventive effort for a person skilled in the art.
FIG. 1 is a flow chart of a map construction method according to an embodiment of the present invention;
fig. 2 is a schematic diagram of a residual calculation process in map element matching according to an embodiment of the present invention;
FIG. 3 is a diagram of a topological relation optimization model provided by an embodiment of the invention;
FIG. 4 is a simplified schematic diagram of a model between map elements for map optimization matching provided by an embodiment of the present invention;
FIG. 5 is a flow chart of a map construction and positioning method according to an embodiment of the invention;
FIG. 6 is a block diagram of a map construction apparatus according to an embodiment of the present invention;
fig. 7 is a schematic diagram of an electronic device according to an embodiment of the present invention.
Detailed Description
The following description of the embodiments of the present invention will be made clearly and fully with reference to the accompanying drawings, in which it is evident that the embodiments described are some, but not all embodiments of the invention. All other embodiments, which can be made by those skilled in the art based on the embodiments of the invention without making any inventive effort, are intended to be within the scope of the invention.
Referring to fig. 1, fig. 1 is a flowchart illustrating a map construction method according to an embodiment of the present invention. As shown in fig. 1, the method may include the steps of:
Step S11: and acquiring the pose of the own vehicle at the current moment under the first coordinate system, and acquiring the local map at the first coordinate system at the previous moment.
In this embodiment, during driving of the vehicle, for example, during automatic driving, the pose of the own vehicle at each moment may be inferred under the first coordinate system according to real-time driving information of the own vehicle, so as to obtain the pose of the own vehicle at the current moment under the first coordinate system. The own vehicle is a current vehicle and can be an automatic driving vehicle, and the own vehicle of the embodiment can display the map constructed by the embodiment; the first coordinate system is a coordinate system based on the absolute position of the real physical world, and the track estimation is to estimate the position information of the current moment of the vehicle according to the course and speed information by utilizing the position of the carrier at a certain moment.
For example, in one embodiment, the position of the vehicle in the first coordinate system at the current moment may be determined by a method of computing the relative displacement (i.e., vehicle pose) by fusion of an IMU (Inertial Measurement Unit ) and a wheel speed sensor kalman filter. Firstly, the inertial measurement unit IMU can provide acceleration and angular velocity information of the own vehicle at the current moment, and can acquire the speed and displacement of the own vehicle at the current moment by integrating the acceleration and angular velocity information of the own vehicle. And the wheel speed sensor can directly measure the rotating speed of the wheel of the vehicle, and can obtain the actual driving distance of the vehicle at the current moment through the radius and the rotating speed of the wheel.
However, since the integration process of the inertial measurement unit IMU accumulates errors, the displacement information obtained after integration for a long time may have a large deviation. And, the measurement of the wheel speed sensor is relatively accurate, but its measurement may be affected in the event of wheel slip or tire wear, etc. Based on this, in this embodiment, in order to comprehensively utilize the advantages of the IMU and the wheel speed sensor, a kalman filtering algorithm may be used to perform data fusion. Kalman filtering is a highly efficient recursive filter that can obtain optimal state estimates through fusion of multiple observations in the presence of uncertainty.
When the pose of the vehicle is fused and calculated, the speed and the displacement provided by the IMU are used as state variables of Kalman filtering, the actual driving distance provided by the wheel speed sensor is used as an observation value, and the pose of the vehicle under the first coordinate system at the current moment, in which the IMU and the wheel speed sensor information are fused, is obtained through a recursion process of Kalman filtering.
Assuming that the current time is t time, the track estimation result at t time is: pose of self-vehicle at current moment under first coordinate systemError of own vehicle/>Wherein/>R is a rotation matrix, and t is a translation vector.
In this embodiment, for determining the pose of the vehicle, continuous displacement information can be provided by using high frequency data of the IMU, and an integral error of the IMU can be corrected by using a measured value of the wheel speed sensor, so that a more accurate pose of the vehicle is obtained.
In this embodiment, a local map in the first coordinate system at the previous time is also acquired. The partial map of the present embodiment is a map constructed based on previously detected map elements, and can be understood as a true value. In this embodiment, the local map in the first coordinate system at the previous time is a local map obtained by updating and optimizing the detection map at the previous time. Wherein the local map coordinate system is a first coordinate system. If the current time is the first time (i.e. the first frame), the local map may be initialized.
Step S12: and obtaining a detection map under a second coordinate system at the current moment according to the sensor data at the current moment.
In this embodiment, during the running of the vehicle, the real-time map element is extracted according to the sensor data at the current time, so as to obtain the detection map under the second coordinate system at the current time. The second coordinate system is a vehicle coordinate system, an equipment coordinate system or a BEV space coordinate system.
The detection of map elements based on sensor data, for example, in some embodiments, lane line detection and map element extraction may be accomplished by end-to-end online vector map construction models, reference maptr/maptrv2, and BEV-transducer solutions. Meanwhile, multi-mode data (such as camera images and laser radar point clouds) can be integrated, and key point prediction in map elements can be performed through a transducer network structure. Wherein, the keypoints in the map element may refer to 2D keypoints or 3D keypoints.
And the topological connection relation between the key points can be generated by using the attention module modeling, so that the extraction precision and efficiency of the map elements can be further improved. In some embodiments, a time sequence frame can be added to improve the extraction accuracy of map elements. Note that, the map elements of the present embodiment include, but are not limited to: lane center line, lane line type, lane marking, stop line, sidewalk, shaft. And finally, constructing a detection map based on the detected map element instance (namely, the map element) set, wherein the detection map is an ordered key point set, and each map element is an ordered point set.
In an alternative example, assuming that the current time is t, the kth key point result in the jth map element example detected at the t time is: of a second coordinate systemIn this embodiment, the 2D key point is exemplified, (x, y, 0) refers to a 2D plane with a z-axis of 0 as the detection result. And, can set up the correspondent error/> of key point according to confidence and distance from car(The greater the confidence s, the smaller the error, the greater the distance d from the host vehicle, the greater the error), for example: ; where s is confidence and d is distance from the vehicle; k. b is respectively an experience value set so as to meet the condition that the larger the confidence coefficient s is, the smaller the error is; the larger the distance d from the own vehicle, the larger the error.
Further, in this embodiment, the line judgment can be performed on three continuous key points obtained by detection, when the distance from the middle key point to the front and rear key point line segments is smaller than a preset threshold, the middle point is deleted, so as to obtain a map element for eliminating the middle point, and a detection map is constructed, so that the points close to the line are deleted, the number of the key points is reduced, and the calculation amount is reduced in the subsequent optimization process.
Step S13: and converting the detection map under the second coordinate system of the current moment into the first coordinate system according to the pose of the self-vehicle under the first coordinate system of the current moment, and obtaining the detection map under the first coordinate system of the current moment.
In this embodiment, since the detection map is in the second coordinate system, the detection map in the second coordinate system needs to be converted into the first coordinate system, and then the detection map and the local map need to be matched. Specifically, according to the pose of the own vehicle at the current moment under the first coordinate system, the detection map at the second coordinate system at the current moment is converted into the first coordinate system, so as to obtain the detection map at the first coordinate system at the current moment.
For example, the current time is t time, and the pose of the kth key point in the jth map element example at the t time under the first coordinate system isError/>Based on the pose/>, of the own vehicle in the first coordinate system at the moment tError of own vehicle/>The conversion process may be referred to by the following formula:
,/>;
wherein, For rotation matrix,/>Is/>Error of/>Is a rotation matrix/>Lie algebra of/>Is/>Error of/>,/>And/>One-to-one correspondence,/>And/>Is also corresponding to,/>、Pose and error of kth key point in jth map element example under second coordinate system,/>, respectivelyIs thatIs an antisymmetric matrix of (a); the error of the key points of the map elements in the detection map in the first coordinate system is,Where T is the transpose.
Step S14: and matching the detection map under the first coordinate system at the current moment with the local map under the first coordinate system at the previous moment to obtain a first matching result.
In this embodiment, after obtaining the detection map under the first coordinate system at the current time, the detection map under the first coordinate system at the current time may be first matched with the local map under the first coordinate system at the previous time to obtain the first matching result.
Step S15: and correcting the pose of the self-vehicle at the current moment under the first coordinate system according to the first matching result to obtain the updated pose of the self-vehicle at the current moment under the first coordinate system.
In this embodiment, according to the first matching result obtained by the first matching, the pose of the own vehicle at the current moment under the first coordinate system may be corrected based on the first matching result, so as to obtain the updated pose of the own vehicle at the current moment under the first coordinate system.
Step S16: and according to the updated pose of the vehicle at the current moment under the first coordinate system, acquiring an updated detection map at the current moment under the first coordinate system, and then matching with the local map at the previous moment under the first coordinate system to acquire a second matching result.
In this embodiment, after obtaining the updated pose of the own vehicle at the current time under the first coordinate system, the detection map at the second coordinate system at the current time may be reconverted to the first coordinate system according to the updated pose of the own vehicle at the current time under the first coordinate system, so as to obtain the updated detection map at the first coordinate system at the current time.
After obtaining the updated detection map under the first coordinate system at the current moment, the updated detection map under the first coordinate system at the current moment can be matched with the local map under the first coordinate system at the previous moment for the second time, so that a second matching result is obtained. In this step, the method of reconversion is the same as or similar to the method of step S13, and the method of second matching is the same as or similar to the method of first matching, which will not be described again.
Step S17: and updating the position of the map element in the local map under the first coordinate system at the previous moment according to the second matching result.
In this embodiment, after the second matching result is obtained, the position of the map element in the local map in the first coordinate system at the previous moment may be updated according to the second matching result, so as to generate the local map in the first coordinate system at the current moment, thereby completing the update of the local map and realizing the real-time construction of the online map. And, the local map in the first coordinate system at the current time can be used for the map construction at the next time.
In the embodiment, the self-vehicle pose and the detection map at each moment are acquired in real time, and the local map at the last moment is acquired; after converting the detection map at the current moment into the same coordinate system based on the vehicle position, the detection map at the current moment in the same coordinate system can be matched with the local map at the previous moment for the first time, so that the vehicle position is optimized based on a first matching result; then, the detection map is converted into the same coordinate system again based on the optimized vehicle position, the updated detection map is matched with the local map for the second time, the local map is updated based on the second matching result, so that the local map is optimized at each moment, the accurate construction of the online map is realized, the precision of the online map constructed in real time is improved, the front and rear sensing result (detection result) and other sensor odometers are fused, the accuracy of the constructed map and the vehicle positioning (vehicle position) is improved, and the accuracy of decision planning in an intelligent driving system is further improved.
In combination with the above embodiment, in an implementation manner, the invention further provides a map construction method. In this method, the step S14 may specifically include a step S21, and the step S15 may specifically include a step S22:
step S21: and matching the map elements in the detection map under the first coordinate system at the current moment with the map elements in the local map under the first coordinate system at the previous moment to obtain the first matching result.
In this embodiment, for the first matching, the map elements in the detected map in the first coordinate system at the current time may be matched with the map elements in the local map in the first coordinate system at the previous time to obtain the first matching result. It can be understood that the matching purpose is that the map elements of the detection map of the same type are matched with the map elements in the local map one by one, so that the condition of missing detection and false detection is screened out as much as possible.
Wherein, the first matching result at least comprises: the first matching map element is matched with the residual error corresponding to the first matching map element. And in this embodiment, the method of the second matching is still the same as or similar to the method of the first matching.
Step S22: and correcting the pose of the current-moment self-vehicle under the first coordinate system by taking the residual error corresponding to the minimized first matching map element as a target, so as to obtain the updated pose of the current-moment self-vehicle under the first coordinate system.
In this embodiment, after the first matching map element and the residual error corresponding to the first matching map element that are matched are obtained, when the vehicle pose is updated, the pose of the vehicle at the current moment under the first coordinate system may be corrected with the residual error corresponding to the first matching map element as a target, so as to obtain the updated pose of the vehicle at the current moment under the first coordinate system.
For example, the residual error corresponding to the first matching map element may be as small as possible, and when the residual error reaches a certain value (a preset residual error threshold value), the corresponding position of the own vehicle is the updated pose of the own vehicle in the first coordinate system at the current moment.
In an alternative example, the rays from the current key point to the next key point in the map elements of the local map are calculated, and the key point positions are as followsError is/>The direction vector is l and the error delta l, wherein the error delta l can be calculated through an error propagation model in a three-dimensional space, so that the distance d between the nearest key point ray in the map element of the detection map and the error delta d can be calculated, and the pose of the detection map is corrected to enable/>Minimum, where j is a map element, k is a key point,/>For the ray distance from the kth key point to the nearest key point in the jth map element example, weight is a weight value, and is influenced by δd, the observation model in the voxelmap medium-plane uncertainty estimation and the iekf pose estimation can be referred to.
In combination with the above embodiment, in an implementation manner, the present invention further provides a map construction method, where the method further includes step S31 before step S21, and step S21 may specifically include step S32:
Step S31: and removing map elements with the first probability smaller than a first threshold value from the local map under the first coordinate system at the previous moment to obtain the residual map elements.
In this embodiment, each map element in the local map corresponds to a first probability, and the first probability represents a probability that the map element in the local map actually exists. In this embodiment, the track is used to infer and predict the pose of the vehicle, and the difference between the positions of the map elements of the detected map and the local map is not too large, so that the map elements with the first probability smaller than the first threshold value can be removed from the local map under the first coordinate system at the previous moment, and the remaining map elements in the local map under the first coordinate system at the previous moment are obtained. The first threshold in this embodiment is a threshold that is freely set according to requirements or experience, and the value of the first threshold is not limited.
Step S32: and matching map elements in the detection map under the first coordinate system at the current moment with the residual map elements to obtain the first matching result.
In this embodiment, when matching the local map with the detected map, the map elements in the detected map in the first coordinate system at the current moment are first matched with the remaining map elements in the local map in the first coordinate system at the previous moment, so as to obtain a first matching result. Similarly, in this embodiment, the second matching is performed by matching the updated map elements in the first coordinate system at the current time with the remaining map elements to obtain a second matching result.
In combination with the above embodiment, the present invention also provides a map construction method, in which, in addition to the above steps, steps S41 to S43 may be included:
Step S41: and increasing the first probability corresponding to the second matching map element in the local map based on the residual error corresponding to the second matching map element.
In this embodiment, map elements in the local map all correspond to a first probability, and the first probability characterizes a probability that the map elements in the local map actually exist. The second matching result of this embodiment includes: and the residual errors corresponding to the second matched map elements, the map elements with no matching of the local map and the map elements with no matching of the detection map are matched. Wherein, the map elements of the local map without matching represent that the map elements are in the local map and are not matched with the map elements in the detection map; map elements of the detection map that do not match characterize the map elements in the detection map and do not match map elements in the local map.
It is to be understood that the first matching result in this embodiment includes, in addition to: the first matching map element and the residual error corresponding to the first matching map element which are matched can further comprise: the first matched local map has no matched map elements and the first matched detected map has no matched map elements. This example performed two matches except that there was: besides the matching map elements which are successfully matched and the residual errors corresponding to the matching map elements, the matching map elements which are not successfully matched also comprise: the local map has no matching map elements and the map has no matching map elements detected. Map elements of the partial map which are obtained by matching in the front and the back times and map elements of the detection map which are not matched can be the same or different and are related to the actual matching situation.
In this embodiment, after the second matching result is obtained, the first probability corresponding to the second matching map element in the local map under the first coordinate system at the previous moment may be increased according to the residual error corresponding to the second matching map element in the second matching result. For example, a probability may be calculated according to the residual error size corresponding to the second matching map element, and the calculated probability is added to the first probability corresponding to the previous matching map element, so that the first probability corresponding to the second matching map element is increased, and the smaller the residual error, the larger the probability is; the calculated probability can be directly used as the first probability corresponding to the second matching map element, so that the first probability corresponding to the second matching map element is increased, and the smaller the residual error is, the larger the probability is.
Step S42: and reducing the first probability that the local map in the local map does not have the matched map elements.
In this embodiment, after determining that the local map in the second matching result has no matching map element, the first probability corresponding to the local map in the first coordinate system at the previous time and having no matching map element may be reduced.
Step S43: and adding map elements which are not matched with the detection map into the local map, and initializing a first probability corresponding to the map elements which are not matched with the detection map.
In this embodiment, for map elements that are not matched with the detected map in the second matching result, the map elements that are not matched with the detected map may be added to the local map in the first coordinate system at the previous moment, and the first probability corresponding to the map elements that are not matched with the detected map that are newly added to the local map may be initialized.
In this embodiment, for the second matching result at the current time, the first probability of each map element in the local map is updated for matching between map elements at the next time.
In combination with the above embodiment, the present invention further provides a map construction method, in which the step S21 may specifically include steps S51 to S56:
Step S51: a second keypoint closest to the first keypoint in the first map element in the detected map is determined.
In this embodiment, the second key point closest to the first key point in the first map element of the detection map may be determined first. The map elements which are matched in the detection map under the first coordinate system at the current moment are first map elements; the map elements matched in the local map under the first coordinate system at the previous moment are second map elements; the first map element and the second map element are two map elements which are matched. The key points in the first map element are first key points; the second key point is the key point closest to the first key point in the second map element of the local map in the first coordinate system at the previous time.
Step S52: and determining a linear distance between the first key point and the second key point.
In this embodiment, after determining the second key point corresponding to the first key point, that is, the second key point closest to the first key point, the linear distance D between the first key point and the second key point may be determined.
Step S53: and traversing all the first key points in the first map element to obtain the respective corresponding straight line distances of all the first key points.
In this embodiment, there are multiple first key points in the first map element, and all the first key points in the first map element may be traversed, and the second key points corresponding to all the first key points are determined, so as to obtain the straight line distances corresponding to all the first key points. Wherein, the straight line distance that all first key points correspond respectively is: and the linear distances respectively corresponding to all the first key points and the second key points respectively corresponding to the first key points.
Step S54: and obtaining corresponding residual errors between the first map elements and the second map elements based on the respective corresponding straight line distances of all the first key points.
In this embodiment, after obtaining the straight line distances corresponding to all the first key points in the first map element, the residuals corresponding to the first map element and the second map element may be determined based on the straight line distances corresponding to all the first key points. In an alternative example, the straight line distances corresponding to all the first key points may be averaged to obtain a residual error corresponding to the first map element and the second map element.
Step S55: and reserving the matching relation between the first map element and the second map element when the residual error is smaller than a second threshold value.
In this embodiment, a second threshold value is preset, and the second threshold value may be set arbitrarily according to requirements or experience, which is not limited. When the residual corresponding to the first map element and the second map element is determined to be smaller than the second threshold value, the matching relation between the first map element and the second map element can be reserved.
Step S56: and eliminating redundant matching relations in the matching relations to obtain matching map elements matched one to one and residual errors corresponding to the matching map elements matched one to one.
In this embodiment, after the matching relationship between the first map element and the second map element is preserved, since one first map element may have a matching relationship with a plurality of second map elements, and one second map element may have a matching relationship with a plurality of first map elements. Based on this, the embodiment eliminates redundant matching relations in the reserved matching relations by adopting the hungarian matching algorithm, so as to obtain matching map elements matched one to one and residuals corresponding to the matching map elements matched one to one.
It can be understood that, when matching for the first time, the map elements are matched one to one, and the residuals corresponding to the map elements matched one to one are: the first matched map element is matched with the residual error corresponding to the first matched map element; in the second matching, the matching map elements matched one by one and the residuals corresponding to the matching map elements matched one by one are: the matched second matching map element and the residual corresponding to the second matching map element.
For example, in an embodiment, as shown in fig. 2, fig. 2 is a schematic diagram illustrating a residual calculation process in map element matching according to an embodiment of the present invention. In fig. 2, the upper solid curve is a map element in the detected map, the lower dotted curve is a map element in the local map, points on the curve are ordered points in the map element, that is, ordered key points in the map element, and a connecting line between two curves is a distance from the nearest line segment of the map element of the local map to the key point in the map element of the detected map.
In combination with the above embodiment, the present invention further provides a map construction method, in which the step S17 may specifically include steps S61 to S69:
Step S61: and determining the key points to be optimized based on the second matching result and the local map under the first coordinate system at the last moment.
In this embodiment, after the second matching result is determined, the key point to be optimized, which is a key point in the map element that needs to be updated in position, may be determined based on the second matching result and the local map in the first coordinate system at the previous time.
In this embodiment, for optimizing the topological relation between map elements and optimizing the curve shape of each map element, since the local map and the key points of the map elements in the detection map are not in a one-to-one matching relation, and on a curve, the intersecting points in each map element are fixed, the topological relation in the local map is a good choice by using the intersecting points and the points in the matched map elements as constraints.
Step S62: and determining the head and tail points of the map elements in the key points to be optimized as first class points, and determining the head and tail points of each map element as first class point pairs.
In this embodiment, the head and tail points of the map elements among the key points to be optimized may be determined as first class points, and the head and tail points of each map element may be determined as a first class point pair. Taking a map element as a lane line as an example, the head and tail points of the map element are two vertexes of the lane line.
Step S63: and determining the key points, of the key points to be optimized, of which the head and tail points of the map elements are overlapped with the intersection points as second class points.
In this embodiment, the intersection points in each map element in the key points to be optimized may be determined first: traversing the head and tail points in all map elements, searching the nearest points in other map elements within a distance threshold value (a threshold value arbitrarily specified according to requirements or experience) according to the head and tail points, possibly finding the nearest points in a plurality of map elements, and taking the nearest points closest to the head and tail points in the nearest points in the plurality of map elements as crossing points.
After the intersection point is determined, the key points, of the key points to be optimized, of which the head and tail points of the map elements are coincident with the intersection point, can be determined to be the second type points. For example, as shown in fig. 3, fig. 3 is a topological relation optimization model diagram provided by an embodiment of the present invention. In fig. 3, the dots on the uppermost rectangle are the cross points within the threshold of the head and tail points, the transverse elliptical dots on the lowest row are the head and tail points, the vertical elliptical dots on the middle row and the vertical elliptical dots on the fifth column line segment are the key points where the head and tail points coincide with the cross points.
Step S64: and determining the intersection points within a third threshold value from the head and tail points of the map element in the key points to be optimized as third class points, and determining the intersection points in the third class points and the head and tail points of the corresponding map element as third class point pairs.
In this embodiment, an intersection within a third threshold from the head and tail points of the map element in the key points to be optimized may be determined as a third class point, and the head and tail points and the intersection are a third class point pair. The third threshold may be set arbitrarily according to requirements or experience, and specific values are not limited. That is, the intersection point in the third class of points and the head-to-tail point of the map element corresponding thereto are the third class of point pairs.
It should be noted that, in the present embodiment, "point pair" in the first type of point pair and the third type of point pair refers to a pair of points, which is composed of two points; the first class of point pairs consists of two head and tail points of each map element, and the third class of point pairs consists of crossing points in the third class of points and head and tail points of the map elements corresponding to the crossing points in the third class of points.
Step S65: and determining the key point with the nearest own vehicle in each map element as a fourth type point.
In this embodiment, among the key points to be optimized, the key point with the nearest own vehicle in each map element is determined as the fourth type point.
Step S66: and determining the key points except the first class point, the second class point, the third class point and the fourth class point in the key points to be optimized as fifth class points, and determining the fifth class points in the same map element as a fifth class point set.
In this embodiment, after the first class point, the second class point, the third class point and the fourth class point are determined, the key points except for the first class point, the second class point, the third class point and the fourth class point in the key points to be optimized are determined as the fifth class point; and determining the fifth class of points in the same map element as a fifth class of point set, wherein the fifth class of point set is a sequential set.
Step S67: and defining the key points to be optimized as nodes in a graph optimization model, defining two key points in the first class of point pairs as edges, defining two key points in the third class of point pairs as edges, defining two adjacent key points in the fifth class of point sets as edges, and establishing a priori edge for the nodes of the third class of points.
In this embodiment, a graph optimization model may be built, where all the key points (the first class point, the second class point, the third class point, the fourth class point, and the fifth class point) in the key points to be optimized are defined as nodes in the graph optimization model, two key points in the first class point pair are defined as edges, two key points in the third class point pair are defined as edges, two adjacent key points in the fifth class point set are defined as edges, and the nodes in the third class point set are built as a priori edges.
Step S68: and taking the distance and the direction of the two adjacent key points as observation, taking the prior edge of a first node in front of the vehicle pose as the observation by the position of the first node in a detection map at the current moment, and taking the prior edge of a second node behind the vehicle pose as the observation by the position of the second node in a local map at the last moment, and processing the key points to be optimized through the graph optimization model to obtain the position and the error of the key points after optimization.
In this embodiment, the distance and direction of two adjacent key points may be used as the observation. The second matching map elements that are matched include: and defining all key points of the map elements in the local map in the matched second matched map elements and the map elements in the local map as edges, taking the distance from the key points in the map elements in the detected map in the matched second matched map elements to the nearest line segment as observation, and deducing the observation and the error of the length and the direction of the line segment according to the positions and the errors of the two key points of the nearest line segment.
And observing the prior edge of the first node in front of the vehicle position by the position of the first node in the detection map at the current moment, wherein the first node is a node in front of the vehicle position in the detection map. The prior edge of the second node behind the vehicle position is used as observation by the position of the second node in the local map at the last moment, wherein the second node is the node behind the vehicle position in the local map. In this embodiment, the observation is to make the observed value as unchanged as possible in the optimization process.
After determining the nodes, edges and observations, the embodiment can process the key points to be optimized through a graph optimization model to obtain the positions and errors of the key points after optimization, namely the positions and errors of all the nodes after optimization.
As shown in fig. 4, fig. 4 is a simple schematic diagram of a model between map elements for optimizing matching in a map according to an embodiment of the present invention. In fig. 4, the dotted line connected with the largest dot is the prior side in the local map and the detected map, the other ellipse vertex connected with the prior side is the third class of dot, the upper dotted rectangular frame is the map element in the local map, the lower solid rectangular frame is the map element in the detected map, the dots in the two rectangular frames are ordered dots (fifth class of dots) in the map element, the connection line between the fifth class of dots is the side of the length and direction between the dots, and the short line between the two rectangular frames is the side between the map elements.
Step S69: and updating the positions of map elements in the local map under the first coordinate system at the previous moment based on the positions and errors of the optimized key points, and generating the local map under the first coordinate system at the current moment.
In this embodiment, after the position and error of the optimized key point are obtained, the position of the map element in the local map under the first coordinate system at the previous time may be updated based on the position and error of the optimized key point, so as to generate the local map under the first coordinate system at the current time, and implement the map construction at the current time.
In an alternative example, specifically, the positions and errors of all the nodes may be obtained based on optimization, the key points in the detected map are inserted between two key points of the nearest line segment in the local map, then straight line judgment is performed through three adjacent key points (the same or similar to the straight line judgment in the step S12), and the redundant key points in the middle are deleted to form a new key point set, so that the local map under the first coordinate system at the current moment is formed based on the new key point set.
The map construction method provided by the embodiment can be used for finding vehicle end deployment, is used for intelligent driving without a map, and reduces cost; the method can also be used for constructing cloud crowd-sourced maps (vector maps with map element probability and point errors), and the vector map matching and positioning method with errors at the vehicle end can be rapidly popularized for intelligent driving of L3 and above.
In combination with the above embodiment, the present invention further provides a map construction method, in which the step S61 may specifically include a step S71 and a step S72:
step S71: and determining a key point with the error larger than a fourth threshold value corresponding to the key point in the map element in the local map under the first coordinate system at the previous moment as a third key point.
In this embodiment, the method may determine, by performing a threshold value determination on an error corresponding to a key point in a map element in a local map in a first coordinate system at a previous time, comparing the error corresponding to the key point in the map element in the local map with a preset fourth threshold value (which may be arbitrarily specified according to requirements or experience), and determining, as a third key point, a key point in the local map in which the error corresponding to the key point in the map element is greater than the fourth threshold value.
Step S72: and determining at least the key points of the map elements, which are detected to be unmatched in the map, in the second matching result and the third key points as key points to be optimized.
In this embodiment, the map element that the detected map does not match is a map element that appears in the detected map but does not appear in the local map, which may be a newly detected map element; map elements of the local map that are not matched are map elements that appear in the local map but not in the detected map, which may be false-detected, which are all map elements that are not matched successfully, requiring further optimization.
Therefore, the embodiment may determine at least the key point of the map element, which detects that the map is not matched, and the determined third key point in the second matching result as the key point to be optimized; and determining the key points of the map elements, which are detected to be unmatched by the map, in the second matching result, the key points of the map elements, which are detected to be unmatched by the local map, in the second matching result and the determined third key points as the key points to be optimized so as to optimize the positions of the key points to be optimized.
In this embodiment, the key points with smaller errors are eliminated from the key points to be optimized, and it can be understood that the key points with smaller errors are already accurate and do not need to be optimized, so in order to further save computing resources, the key points with errors greater than a certain threshold value, and the key points in map elements which are not successfully matched before are determined as the key points to be optimized, and the position is optimized.
In one embodiment, as shown in fig. 5, fig. 5 is a flow chart of a map construction and positioning method according to an embodiment of the invention. In fig. 5, after starting, first, a first coordinate system is set in the absolute position of the vehicle in the physical world, and a vehicle state filter is built, for example, a kalman filter is built on the vehicle to predict and update the vehicle pose. For example, IEKF kalman filtering may be used in the fusion positioning algorithm of the reference lidar and the inertial measurement unit IMU.
And secondly, obtaining the self-vehicle pose transformation and error based on the track inference under the first coordinate system, and assuming that the result of the track inference at the time t is the self-vehicle pose and error. And detecting the map elements under the second coordinate system at each moment, so as to detect the map elements under the second coordinate system at the moment t, and obtain the map elements of the detection map under the second coordinate system at the moment t. Wherein, the self-vehicle coordinate system, the equipment coordinate system or the BEV space are collectively called as a second coordinate system, and the transformation matrix of the first coordinate system and the second coordinate system is as follows at the beginning. And initializing the local map when the time t is the first frame.
And then, carrying out coordinate conversion on the map elements in the detection map under the second coordinate system at the t moment based on the self-vehicle pose and the error obtained by the track estimation at the t moment, and obtaining the pose and the error of the map elements in the detection map at the t moment in the first coordinate system.
Then, based on the pose and the error of the map elements in the map in the first coordinate system at the time t, and the map elements in the local map updated at the time t-1, performing matching detection through a Hungary algorithm, and determining a first matching result of the map elements of the detected map and the map elements of the local map.
Finally, optimizing and updating a vehicle state filter according to the pose residual error of the map element successfully matched in the first matching result to obtain the optimized pose and error of the vehicle, so that the pose and error of the map element in the detection map under the second coordinate system at the moment t are subjected to coordinate conversion again based on the optimized pose and error of the vehicle, the pose and error of the map element in the first coordinate system at the moment t are updated, finally, the pose and error of the map element in the first coordinate system of the detection map at the moment t are re-matched with the local map element based on the pose and error of the map element which is not matched in the second matching result and the map element with large error in the local map, and the local map at the moment t is updated.
In this embodiment, map elements in the current frame are detected, the map elements in the current detected map and the map elements in the local map in the same coordinate system are subjected to hungarian matching, the matched detected map elements are used as observations that the probability in the local map is larger than that of a threshold map element, the odometer information of other sensors is fused, the vehicle positioning is optimized, the first probability of the map elements in the local map and the positions and errors of key points are corrected, and unmatched detected map instances are added into the local map to be managed, so that a cycle is formed, and finally a convergence state is achieved.
It should be noted that, for simplicity of description, the method embodiments are shown as a series of acts, but it should be understood by those skilled in the art that the embodiments are not limited by the order of acts, as some steps may occur in other orders or concurrently in accordance with the embodiments. Further, those skilled in the art will appreciate that the embodiments described in the specification are presently preferred embodiments, and that the acts are not necessarily required by the embodiments of the invention.
Based on the same inventive concept, an embodiment of the present invention provides a map construction apparatus 600. Referring to fig. 6, fig. 6 is a block diagram illustrating a map construction apparatus according to an embodiment of the present invention. As shown in fig. 6, the apparatus 600 includes:
the acquiring module 601 is configured to acquire a pose of a vehicle in a first coordinate system at a current moment, and acquire a local map in the first coordinate system at a previous moment;
The detection module 602 is configured to obtain a detection map under a second coordinate system at the current time according to the sensor data at the current time;
The conversion module 603 is configured to convert the detection map in the second coordinate system at the current time into the first coordinate system according to the pose of the own vehicle in the first coordinate system at the current time, so as to obtain the detection map in the first coordinate system at the current time;
the first matching module 604 is configured to match the detection map in the first coordinate system at the current time with the local map in the first coordinate system at the previous time to obtain a first matching result;
The pose updating module 605 is configured to correct the pose of the own vehicle at the current moment under the first coordinate system according to the first matching result, so as to obtain an updated pose of the own vehicle at the current moment under the first coordinate system;
The second matching module 606 is configured to obtain an updated detection map in the first coordinate system at the current moment according to the updated pose of the vehicle in the first coordinate system at the current moment, and then match the updated detection map with the local map in the first coordinate system at the previous moment to obtain a second matching result;
And a map updating module 607, configured to update the position of the map element in the local map under the first coordinate system at the previous time according to the second matching result.
Optionally, the first matching module 604 includes:
The first matching sub-module is configured to match a map element in the detected map under the first coordinate system at the current moment with a map element in the local map under the first coordinate system at the previous moment to obtain the first matching result; the first matching result at least comprises: the method comprises the steps of matching a first matching map element with a residual error corresponding to the first matching map element;
The pose update module 605 includes:
And the pose updating sub-module is used for correcting the pose of the current-moment self-vehicle under the first coordinate system by taking the residual error corresponding to the minimized first matching map element as a target to obtain the updated pose of the current-moment self-vehicle under the first coordinate system.
Optionally, the map elements in the local map correspond to a first probability, and the first probability characterizes a probability that the map elements in the local map actually exist; the apparatus 600 further comprises:
The rejecting module is used for rejecting the map elements in the detected map under the first coordinate system at the current moment and the map elements in the local map under the first coordinate system at the previous moment before the first matching result is obtained, wherein the map elements with the first probability smaller than a first threshold value in the local map under the first coordinate system at the previous moment are rejected to obtain the rest map elements;
The first matching sub-module comprises:
and the map element matching sub-module is used for matching the map elements in the detection map under the first coordinate system at the current moment with the residual map elements to obtain the first matching result.
Optionally, the map elements in the local map correspond to a first probability, and the first probability characterizes a probability that the map elements in the local map actually exist; the second matching result includes: the residual error corresponding to the second matched map element, the map element with no matching of the local map and the map element with no matching of the detection map are matched; the map elements of the local map, which are not matched, represent that the map elements are in the local map and are not matched with the map elements in the detection map; the map elements of the detection map, which are not matched, represent that the map elements are in the detection map and are not matched with the map elements in the local map;
The apparatus 600 further comprises:
The first probability updating module is used for increasing the first probability corresponding to the second matching map element in the local map based on the residual error corresponding to the second matching map element;
The second probability updating module is used for reducing the first probability corresponding to map elements, which are not matched with the local map, in the local map;
And the third probability updating module is used for adding map elements which are not matched with the detection map into the local map and initializing a first probability corresponding to the map elements which are not matched with the detection map.
Optionally, the first matching sub-module includes:
A key point determining submodule, configured to determine a second key point closest to a first key point in a first map element in the detected map, where the second key point is in a second map element in the local map; the first map element and the second map element are map elements for matching;
the linear distance determining submodule is used for determining the linear distance between the first key point and the second key point;
The traversing submodule is used for traversing all the first key points in the first map element to obtain the respective corresponding straight line distances of all the first key points;
the residual determination submodule is used for obtaining corresponding residual between the first map element and the second map element based on the linear distances corresponding to all the first key points;
a preserving relationship sub-module, configured to preserve a matching relationship between the first map element and the second map element when the residual error is smaller than a second threshold;
And the eliminating sub-module is used for eliminating redundant matching relations in the matching relations to obtain one-to-one matching map elements and residual errors corresponding to the one-to-one matching map elements.
Optionally, the map updating module 607 includes:
The optimization key point determining submodule is used for determining key points to be optimized based on the second matching result and the local map under the first coordinate system at the previous moment;
The first class point determining submodule is used for determining the head and tail points of the map elements as first class points and determining the head and tail points of each map element as first class point pairs;
a second class point determining sub-module, configured to determine, as a second class point, a key point where the head and tail points of the map element overlap with the intersection point, from the key points to be optimized;
a third class point determining submodule, configured to determine, as a third class point, an intersection point within a third threshold value from the head point and the tail point of the map element in the key points to be optimized, and determine, as a third class point pair, the intersection point in the third class point and the head point and the tail point of the corresponding map element;
a fourth class point determining sub-module, configured to determine, as a fourth class point, a key point closest to the vehicle in each map element among the key points to be optimized;
A fifth class point determining sub-module, configured to determine, as a fifth class point, a critical point other than the first class point, the second class point, the third class point, and the fourth class point, and determine, as a fifth class point set, a fifth class point in the same map element;
An edge determination submodule, configured to define the key points to be optimized as nodes in a graph optimization model, define two key points in the first class of point pairs as edges, define two key points in the third class of point pairs as edges, define two adjacent key points in the fifth class of point sets as edges, and establish a priori edges for the nodes of the third class of points;
The observation determining submodule is used for taking the distance and the direction of the two adjacent key points as observation, taking the prior edge of a first node in front of the vehicle pose as observation by the position of the first node in a detection map at the current moment, and taking the prior edge of a second node behind the vehicle pose as observation by the position of the second node in a local map at the last moment, and processing the key points to be optimized through the graph optimization model to obtain the position and the error of the key points after optimization;
And the position updating sub-module is used for updating the position of the map element in the local map under the first coordinate system at the previous moment based on the position and the error of the optimized key point, and generating the local map under the first coordinate system at the current moment.
Optionally, the optimizing key point determining submodule includes:
A third key point determining submodule, configured to determine, as a third key point, a key point in the local map in the first coordinate system at the previous time, where an error corresponding to the key point in the map element is greater than a fourth threshold;
And the key point to be optimized determining submodule is used for determining at least the key points of the map elements, which are detected to be unmatched in the map, in the second matching result and the third key points as key points to be optimized.
Based on the same inventive concept, another embodiment of the present invention provides a computer readable storage medium, on which a computer program is stored, which when executed by a processor, implements the steps of the map construction method according to any of the above embodiments of the present invention.
Based on the same inventive concept, another embodiment of the present invention provides an electronic device 700, as shown in fig. 7. Fig. 7 is a schematic diagram of an electronic device according to an embodiment of the present invention. The electronic device comprises a memory 702, a processor 701 and a computer program stored on the memory and executable on the processor, which when executed implements the steps of the map construction method according to any of the above embodiments of the invention.
For the device embodiments, since they are substantially similar to the method embodiments, the description is relatively simple, and reference is made to the description of the method embodiments for relevant points.
In this specification, each embodiment is described in a progressive manner, and each embodiment is mainly described by differences from other embodiments, and identical and similar parts between the embodiments are all enough to be referred to each other.
It will be apparent to those skilled in the art that embodiments of the present invention may be provided as a method, apparatus, or computer program product. Accordingly, embodiments of the present invention may take the form of an entirely hardware embodiment, an entirely software embodiment or an embodiment combining software and hardware aspects. Furthermore, embodiments of the invention may take the form of a computer program product on one or more computer-usable storage media (including, but not limited to, disk storage, CD-ROM, optical storage, etc.) having computer-usable program code embodied therein.
Embodiments of the present invention are described with reference to flowchart illustrations and/or block diagrams of methods, terminal devices (systems), and computer program products according to embodiments of the invention. It will be understood that each flow and/or block of the flowchart illustrations and/or block diagrams, and combinations of flows and/or blocks in the flowchart illustrations and/or block diagrams, can be implemented by computer program instructions. These computer program instructions may be provided to a processor of a general purpose computer, special purpose computer, embedded processor, or other programmable data processing terminal device to produce a machine, such that the instructions, which execute via the processor of the computer or other programmable data processing terminal device, create means for implementing the functions specified in the flowchart flow or flows and/or block diagram block or blocks.
These computer program instructions may also be stored in a computer-readable memory that can direct a computer or other programmable data processing apparatus to function in a particular manner, such that the instructions stored in the computer-readable memory produce an article of manufacture including instruction means which implement the function specified in the flowchart flow or flows and/or block diagram block or blocks.
These computer program instructions may also be loaded onto a computer or other programmable data processing apparatus to cause a series of operational steps to be performed on the computer or other programmable apparatus to produce a computer implemented process such that the instructions which execute on the computer or other programmable apparatus provide steps for implementing the functions specified in the flowchart flow or flows and/or block diagram block or blocks.
While preferred embodiments of the present invention have been described, additional variations and modifications in those embodiments may occur to those skilled in the art once they learn of the basic inventive concepts. It is therefore intended that the following claims be interpreted as including the preferred embodiment and all such alterations and modifications as fall within the scope of the embodiments of the invention.
Finally, it is further noted that relational terms such as first and second, and the like are used solely to distinguish one entity or action from another entity or action without necessarily requiring or implying any actual such relationship or order between such entities or actions. Moreover, the terms "comprises," "comprising," or any other variation thereof, are intended to cover a non-exclusive inclusion, such that a process, method, article, or terminal that comprises a list of elements does not include only those elements but may include other elements not expressly listed or inherent to such process, method, article, or terminal. Without further limitation, an element defined by the phrase "comprising one … …" does not exclude the presence of other like elements in a process, method, article, or terminal device that comprises the element.
The map construction method, the map construction device, the electronic equipment and the storage medium provided by the invention are described in detail, and specific examples are applied to illustrate the principle and the implementation mode of the invention, and the description of the above examples is only used for helping to understand the method and the core idea of the invention; meanwhile, as those skilled in the art will have variations in the specific embodiments and application scope in accordance with the ideas of the present invention, the present description should not be construed as limiting the present invention in view of the above.
Claims (10)
1.A method of map construction, the method comprising:
Acquiring the pose of a vehicle under a first coordinate system at the current moment, and acquiring a local map under the first coordinate system at the previous moment;
Obtaining a detection map under a second coordinate system at the current moment according to the sensor data at the current moment;
According to the pose of the self-vehicle at the current moment under the first coordinate system, converting the detection map under the second coordinate system at the current moment into the first coordinate system to obtain the detection map under the first coordinate system at the current moment;
Matching the detection map under the first coordinate system at the current moment with the local map under the first coordinate system at the previous moment to obtain a first matching result;
correcting the pose of the self-propelled vehicle at the current moment under a first coordinate system according to the first matching result to obtain an updated pose of the self-propelled vehicle at the current moment under the first coordinate system;
According to the updated pose of the vehicle under the first coordinate system at the current moment, an updated detection map under the first coordinate system at the current moment is obtained, and then the updated detection map is matched with the local map under the first coordinate system at the previous moment, so that a second matching result is obtained;
and updating the position of the map element in the local map under the first coordinate system at the previous moment according to the second matching result.
2. The map construction method according to claim 1, wherein matching the detected map in the first coordinate system at the present time with the local map in the first coordinate system at the previous time to obtain a first matching result includes:
Matching map elements in the detection map under the first coordinate system at the current moment with map elements in the local map under the first coordinate system at the previous moment to obtain a first matching result; the first matching result at least comprises: the method comprises the steps of matching a first matching map element with a residual error corresponding to the first matching map element;
according to the first matching result, correcting the pose of the self-vehicle at the current moment under the first coordinate system to obtain the updated pose of the self-vehicle at the current moment under the first coordinate system, including:
and correcting the pose of the current-moment self-vehicle under the first coordinate system by taking the residual error corresponding to the minimized first matching map element as a target, so as to obtain the updated pose of the current-moment self-vehicle under the first coordinate system.
3. The map construction method according to claim 2, wherein the map elements in the local map correspond to a first probability that characterizes a probability that the map elements in the local map are actually present; before matching the map elements in the detected map in the first coordinate system at the current moment with the map elements in the local map in the first coordinate system at the previous moment to obtain the first matching result, the method further comprises:
Removing map elements with the first probability smaller than a first threshold value from the local map under the first coordinate system at the previous moment to obtain residual map elements;
Matching the map elements in the detected map under the first coordinate system at the current moment with the map elements in the local map under the first coordinate system at the previous moment to obtain the first matching result, wherein the first matching result comprises the following steps:
And matching map elements in the detection map under the first coordinate system at the current moment with the residual map elements to obtain the first matching result.
4. The map construction method according to claim 1, wherein the map elements in the local map correspond to a first probability that characterizes a probability that the map elements in the local map are actually present; the second matching result includes: the residual error corresponding to the second matched map element, the map element with no matching of the local map and the map element with no matching of the detection map are matched; the map elements of the local map, which are not matched, represent that the map elements are in the local map and are not matched with the map elements in the detection map; the map elements of the detection map, which are not matched, represent that the map elements are in the detection map and are not matched with the map elements in the local map;
the method further comprises the steps of:
Based on the residual error corresponding to the second matching map element, increasing the first probability corresponding to the second matching map element in the local map;
reducing a first probability that the local map in the local map does not have a matched map element correspondence;
And adding map elements which are not matched with the detection map into the local map, and initializing a first probability corresponding to the map elements which are not matched with the detection map.
5. The map construction method according to claim 2, wherein matching the map elements in the detected map in the first coordinate system at the present time with the map elements in the local map in the first coordinate system at the previous time to obtain the first matching result includes:
determining a second key point nearest to a first key point in a first map element in the detection map, wherein the second key point is in a second map element in the local map; the first map element and the second map element are map elements for matching;
Determining a linear distance between the first key point and the second key point;
Traversing all first key points in the first map element to obtain respective corresponding straight line distances of all first key points;
obtaining corresponding residual errors between the first map elements and the second map elements based on the respective corresponding straight line distances of all the first key points;
When the residual error is smaller than a second threshold value, the matching relation between the first map element and the second map element is reserved;
and eliminating redundant matching relations in the matching relations to obtain matching map elements matched one to one and residual errors corresponding to the matching map elements matched one to one.
6. The map construction method according to any one of claims 1 to 5, wherein updating the position of the map element in the local map in the first coordinate system at the previous time according to the second matching result comprises:
determining key points to be optimized based on the second matching result and the local map under the first coordinate system at the last moment;
Determining the head and tail points of the map elements in the key points to be optimized as first class points, and determining the head and tail points of each map element as first class point pairs;
determining the key points, of the key points to be optimized, of which the head and tail points of the map elements are overlapped with the intersection points as second class points;
Determining the crossing points within a third threshold value from the head point to the tail point of the map element in the key points to be optimized as third class points, and determining the crossing points in the third class points and the head point to the tail point of the corresponding map element as third class point pairs;
determining the key point with the nearest vehicle in each map element as a fourth type point;
Determining the key points except the first class point, the second class point, the third class point and the fourth class point in the key points to be optimized as fifth class points, and determining the fifth class points in the same map element as a fifth class point set;
Defining the key points to be optimized as nodes in a graph optimization model, defining two key points in the first class of point pairs as edges, defining two key points in the third class of point pairs as edges, defining two adjacent key points in the fifth class of point sets as edges, and establishing prior edges for the nodes of the third class of points;
Taking the distance and the direction of the two adjacent key points as observation, taking the prior edge of a first node in front of the vehicle pose as the observation by the position of the first node in a detection map at the current moment, and taking the prior edge of a second node behind the vehicle pose as the observation by the position of the second node in a local map at the last moment, and processing the key points to be optimized through the graph optimization model to obtain the position and the error of the key points after optimization;
And updating the positions of map elements in the local map under the first coordinate system at the previous moment based on the positions and errors of the optimized key points, and generating the local map under the first coordinate system at the current moment.
7. The map construction method according to claim 6, wherein the determining the key point to be optimized based on the second matching result and the local map in the first coordinate system at the previous time includes:
Determining a key point with the error larger than a fourth threshold value corresponding to the key point in the map element in the local map under the first coordinate system at the previous moment as a third key point;
and determining at least the key points of the map elements, which are detected to be unmatched in the map, in the second matching result and the third key points as key points to be optimized.
8. A map construction apparatus, characterized in that the apparatus comprises:
The acquisition module is used for acquiring the pose of the vehicle under the first coordinate system at the current moment and acquiring the local map under the first coordinate system at the previous moment;
The detection module is used for obtaining a detection map under a second coordinate system at the current moment according to the sensor data at the current moment;
The conversion module is used for converting the detection map under the second coordinate system at the current moment into the first coordinate system according to the pose of the self-vehicle under the first coordinate system at the current moment to obtain the detection map under the first coordinate system at the current moment;
The first matching module is used for matching the detection map under the first coordinate system at the current moment with the local map under the first coordinate system at the previous moment to obtain a first matching result;
The pose updating module is used for correcting the pose of the current self-propelled vehicle under the first coordinate system according to the first matching result to obtain the updated pose of the current self-propelled vehicle under the first coordinate system;
The second matching module is used for obtaining an updated detection map under the first coordinate system at the current moment according to the updated pose of the self-vehicle under the first coordinate system at the current moment, and then matching the updated detection map with the local map under the first coordinate system at the previous moment to obtain a second matching result;
And the map updating module is used for updating the position of the map element in the local map under the first coordinate system at the previous moment according to the second matching result.
9. An electronic device comprising a memory, a processor and a computer program stored on the memory and executable on the processor, wherein the computer program when executed by the processor implements the mapping method of any of claims 1 to 7.
10. A computer-readable storage medium, on which a computer program is stored, characterized in that the computer program, when being executed by a processor, implements the map construction method according to any one of claims 1 to 7.
Priority Applications (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN202410496267.8A CN118067114B (en) | 2024-04-24 | 2024-04-24 | Map construction method and device, electronic equipment and storage medium |
Applications Claiming Priority (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN202410496267.8A CN118067114B (en) | 2024-04-24 | 2024-04-24 | Map construction method and device, electronic equipment and storage medium |
Related Child Applications (1)
Application Number | Title | Priority Date | Filing Date |
---|---|---|---|
CN202410984881.9A Division CN118960716A (en) | 2024-04-24 | Map construction method and device, electronic equipment and storage medium |
Publications (2)
Publication Number | Publication Date |
---|---|
CN118067114A true CN118067114A (en) | 2024-05-24 |
CN118067114B CN118067114B (en) | 2024-07-26 |
Family
ID=91097633
Family Applications (1)
Application Number | Title | Priority Date | Filing Date |
---|---|---|---|
CN202410496267.8A Active CN118067114B (en) | 2024-04-24 | 2024-04-24 | Map construction method and device, electronic equipment and storage medium |
Country Status (1)
Country | Link |
---|---|
CN (1) | CN118067114B (en) |
Citations (12)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN110887493A (en) * | 2019-11-29 | 2020-03-17 | 上海有个机器人有限公司 | Trajectory estimation method, medium, terminal and device based on local map matching |
CN112380317A (en) * | 2021-01-18 | 2021-02-19 | 腾讯科技(深圳)有限公司 | High-precision map updating method and device, electronic equipment and storage medium |
WO2021057743A1 (en) * | 2019-09-27 | 2021-04-01 | Oppo广东移动通信有限公司 | Map fusion method, apparatus, device and storage medium |
CN113537208A (en) * | 2021-05-18 | 2021-10-22 | 杭州电子科技大学 | Visual positioning method and system based on semantic ORB-SLAM technology |
WO2021233452A1 (en) * | 2020-05-22 | 2021-11-25 | 杭州海康机器人技术有限公司 | Map updating method and apparatus |
CN114255323A (en) * | 2021-12-22 | 2022-03-29 | 深圳市普渡科技有限公司 | Robot, map construction method, map construction device and readable storage medium |
CN115355904A (en) * | 2022-07-25 | 2022-11-18 | 之江实验室 | Slam method for Lidar-IMU fusion of ground mobile robot |
CN115638787A (en) * | 2022-12-23 | 2023-01-24 | 安徽蔚来智驾科技有限公司 | Digital map generation method, computer readable storage medium and electronic device |
CN115861567A (en) * | 2022-11-25 | 2023-03-28 | 深圳市凌云视迅科技有限责任公司 | Point cloud vector matching method and device based on graph optimization |
CN116148808A (en) * | 2023-04-04 | 2023-05-23 | 江苏集萃清联智控科技有限公司 | Automatic driving laser repositioning method and system based on point cloud descriptor |
CN117011457A (en) * | 2023-06-07 | 2023-11-07 | 深圳市其域创新科技有限公司 | Three-dimensional drawing construction method and device, electronic equipment and storage medium |
CN117870702A (en) * | 2023-12-07 | 2024-04-12 | 浙江华睿科技股份有限公司 | Robot-based map construction method, apparatus and storage medium |
-
2024
- 2024-04-24 CN CN202410496267.8A patent/CN118067114B/en active Active
Patent Citations (12)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
WO2021057743A1 (en) * | 2019-09-27 | 2021-04-01 | Oppo广东移动通信有限公司 | Map fusion method, apparatus, device and storage medium |
CN110887493A (en) * | 2019-11-29 | 2020-03-17 | 上海有个机器人有限公司 | Trajectory estimation method, medium, terminal and device based on local map matching |
WO2021233452A1 (en) * | 2020-05-22 | 2021-11-25 | 杭州海康机器人技术有限公司 | Map updating method and apparatus |
CN112380317A (en) * | 2021-01-18 | 2021-02-19 | 腾讯科技(深圳)有限公司 | High-precision map updating method and device, electronic equipment and storage medium |
CN113537208A (en) * | 2021-05-18 | 2021-10-22 | 杭州电子科技大学 | Visual positioning method and system based on semantic ORB-SLAM technology |
CN114255323A (en) * | 2021-12-22 | 2022-03-29 | 深圳市普渡科技有限公司 | Robot, map construction method, map construction device and readable storage medium |
CN115355904A (en) * | 2022-07-25 | 2022-11-18 | 之江实验室 | Slam method for Lidar-IMU fusion of ground mobile robot |
CN115861567A (en) * | 2022-11-25 | 2023-03-28 | 深圳市凌云视迅科技有限责任公司 | Point cloud vector matching method and device based on graph optimization |
CN115638787A (en) * | 2022-12-23 | 2023-01-24 | 安徽蔚来智驾科技有限公司 | Digital map generation method, computer readable storage medium and electronic device |
CN116148808A (en) * | 2023-04-04 | 2023-05-23 | 江苏集萃清联智控科技有限公司 | Automatic driving laser repositioning method and system based on point cloud descriptor |
CN117011457A (en) * | 2023-06-07 | 2023-11-07 | 深圳市其域创新科技有限公司 | Three-dimensional drawing construction method and device, electronic equipment and storage medium |
CN117870702A (en) * | 2023-12-07 | 2024-04-12 | 浙江华睿科技股份有限公司 | Robot-based map construction method, apparatus and storage medium |
Also Published As
Publication number | Publication date |
---|---|
CN118067114B (en) | 2024-07-26 |
Similar Documents
Publication | Publication Date | Title |
---|---|---|
CN114812581B (en) | Cross-country environment navigation method based on multi-sensor fusion | |
CN112734852B (en) | Robot mapping method and device and computing equipment | |
CN109509210B (en) | Obstacle tracking method and device | |
JP6595182B2 (en) | Systems and methods for mapping, locating, and attitude correction | |
JP6197393B2 (en) | Lane map generation device and program | |
CN114323033B (en) | Positioning method and equipment based on lane lines and feature points and automatic driving vehicle | |
CN114526745B (en) | Drawing construction method and system for tightly coupled laser radar and inertial odometer | |
CN111932887B (en) | Method and equipment for generating lane-level track data | |
CN112380312B (en) | Laser map updating method based on grid detection, terminal and computer equipment | |
CN111915675B (en) | Particle drift-based particle filtering point cloud positioning method, device and system thereof | |
CN115690338A (en) | Map construction method, map construction device, map construction equipment and storage medium | |
US20230071794A1 (en) | Method and system for building lane-level map by using 3D point cloud map | |
CN115435798A (en) | Unmanned vehicle high-precision map road network generation system and method | |
CN113325389A (en) | Unmanned vehicle laser radar positioning method, system and storage medium | |
CN113379915B (en) | Driving scene construction method based on point cloud fusion | |
CN114889606A (en) | Low-cost high-precision positioning method based on multi-sensor fusion | |
CN118067114B (en) | Map construction method and device, electronic equipment and storage medium | |
CN118960716A (en) | Map construction method and device, electronic equipment and storage medium | |
CN115326068B (en) | Design method and system for laser radar-inertial measurement unit fusion odometer | |
CN114705180B (en) | Data correction method, device and equipment for high-precision map and storage medium | |
CN116929363A (en) | Mining vehicle autonomous navigation method based on passable map | |
Gallazzi et al. | Clothoidal mapping of road line markings for autonomous driving high-definition maps | |
KR20210098534A (en) | Methods and systems for creating environmental models for positioning | |
CN115795082A (en) | Distributed pose optimization method and system based on graph algorithm | |
CN115773747A (en) | High-precision map generation method, device, equipment and storage medium |
Legal Events
Date | Code | Title | Description |
---|---|---|---|
PB01 | Publication | ||
PB01 | Publication | ||
SE01 | Entry into force of request for substantive examination | ||
SE01 | Entry into force of request for substantive examination | ||
GR01 | Patent grant | ||
GR01 | Patent grant |