Map generation method, device, system, storage medium and electronic device

By acquiring and integrating pose, point cloud and image color data, a three-dimensional point cloud map with color information is generated, which solves the problem of poor map intuitiveness in the existing technology, and improves the accuracy and scope of application of robot navigation.

CN113834479BActive Publication Date: 2025-01-14GUANGDONG OPPO MOBILE TELECOMMUNICATIONS CORP LTD
View PDF 3 Cites 0 Cited by

Patent Information

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

AI Technical Summary

Technical Problem

In the three-dimensional dense point cloud map built by existing robots, each position has only three-dimensional position coordinates and corresponding intensity information, resulting in poor intuitiveness of the map.

Method used

By obtaining pose data, point cloud data and image color data of multiple locations, a point cloud map is generated that gives color information, increasing the intuitiveness of the map, and semantic analysis is carried out to improve the degree of recognition and scope of application.

Benefits of technology

It improves the intuitiveness and recognition of point cloud maps, expands its scope of application, and enhances the accuracy of robot positioning and navigation.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN113834479B_ABST
    Figure CN113834479B_ABST
Patent Text Reader

Abstract

The present application discloses a map generation method, device, system, storage medium and electronic device, the method comprising obtaining posture data corresponding to multiple positions, and obtaining point cloud data and image color data corresponding to each of the posture data corresponding to the multiple positions; generating a map according to the posture data corresponding to the multiple positions, the point cloud data and image color data corresponding to each of the posture data corresponding to the multiple positions. The present application can give color information to the generated point cloud map according to the posture data, point cloud data and image color data corresponding to the multiple positions to increase the intuitiveness of the point cloud map, and can also perform semantic analysis on the generated point cloud map to improve the scope of application of the point cloud map.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present application relates to the field of robot vision, and in particular to a map generation method, device, system, storage medium and electronic device. Background Art

[0002] With the rapid development of science and technology, more and more industries are beginning to see robots that are convenient for providing services to users. Robots can perceive external information through their own sensors, and simultaneously perform positioning and build a three-dimensional dense point cloud map. Traditional visual technology uses cameras as sensors, uses image feature points (such as ORB, SIFT, etc.) to calculate the matching relationship between images, and builds a map by projecting these feature points into three-dimensional space. Summary of the invention

[0003] The embodiments of the present application provide a map generation method, device, system, storage medium and electronic device, which can solve the problem that in the three-dimensional dense point cloud map constructed by the existing robot, each position only has three-dimensional position coordinates and corresponding intensity information, resulting in poor intuitiveness of the map.

[0004] In a first aspect, an embodiment of the present application provides a map generation method, comprising:

[0005] Acquire posture data corresponding to the multiple positions, and acquire point cloud data and image color data corresponding to the posture data corresponding to the multiple positions;

[0006] A map is generated based on the posture data corresponding to the plurality of positions, the point cloud data corresponding to each of the posture data corresponding to the plurality of positions, and the image color data.

[0007] In a second aspect, an embodiment of the present application provides a map generation device, including:

[0008] An acquisition module, used to acquire posture data corresponding to a plurality of positions, and acquire point cloud data and image color data corresponding to each of the posture data corresponding to the plurality of positions;

[0009] The first processing module is used to generate a map according to the posture data corresponding to the multiple positions, the point cloud data corresponding to the posture data corresponding to the multiple positions, and the image color data.

[0010] In a third aspect, an embodiment of the present application provides an electronic device, including a processor and a memory;

[0011] The processor is connected to the memory;

[0012] A memory for storing executable program codes;

[0013] The processor runs the program corresponding to the executable program code by reading the executable program code stored in the memory, so as to execute the map generation method provided by the first aspect of the embodiment of the present application or any one of the implementations of the first aspect.

[0014] In a fourth aspect, an embodiment of the present application provides a map generation system, including:

[0015] A first acquisition unit, used to obtain posture data corresponding to multiple positions;

[0016] A second acquisition unit is used to obtain point cloud data corresponding to each of the posture data corresponding to the multiple positions;

[0017] A third acquisition unit is used to obtain image color data corresponding to each of the posture data corresponding to the multiple positions;

[0018] The processing unit is used to generate a map according to the posture data corresponding to the multiple positions, the point cloud data corresponding to the posture data corresponding to the multiple positions, and the image color data.

[0019] In a fifth aspect, the embodiment of the present application further provides a map generation system, including:

[0020] Motor encoder, used to obtain posture data corresponding to multiple positions;

[0021] A multi-line laser radar, used to obtain point cloud data corresponding to each of the posture data corresponding to the multiple positions;

[0022] A binocular camera, used to obtain image color data corresponding to each of the posture data corresponding to the multiple positions;

[0023] A processor is used to generate a map based on the posture data corresponding to the multiple positions, the point cloud data corresponding to each of the posture data corresponding to the multiple positions, and the image color data.

[0024] In a sixth aspect, an embodiment of the present application provides a computer storage medium, which stores a computer program. The computer program includes program instructions. When the program instructions are executed by a processor, the map generation method provided by the first aspect of the embodiment of the present application or any one of the implementation methods of the first aspect can be implemented.

[0025] In the embodiment of the present application, posture data corresponding to multiple positions are obtained, and point cloud data and image color data corresponding to each of the posture data corresponding to the multiple positions are obtained; a map is generated based on the posture data corresponding to the multiple positions, the point cloud data and image color data corresponding to each of the posture data corresponding to the multiple positions. Color information can be assigned to the generated point cloud map based on the posture data, point cloud data and image color data corresponding to the multiple positions to increase the intuitiveness of the point cloud map; at the same time, semantic analysis can be performed on the point cloud map assigned with color information to improve the recognition degree and application scope of the point cloud map. BRIEF DESCRIPTION OF THE DRAWINGS

[0026] In order to more clearly illustrate the technical solutions in the embodiments of the present application, the drawings required for use in the embodiments will be briefly introduced below. Obviously, the drawings described below are only some embodiments of the present application. For ordinary technicians in this field, other drawings can be obtained based on these drawings without paying creative work.

[0027] Figure 1 A schematic diagram of the architecture of a map generation system provided in an embodiment of the present application;

[0028] Figure 2 A schematic diagram of the structure of a legged robot based on a map generation system provided in an embodiment of the present application;

[0029] Figure 3 A flowchart of a map generation method provided in an embodiment of the present application;

[0030] Figure 4 A schematic diagram of a coordinate system rotation angle provided in an embodiment of the present application;

[0031] Figure 5 A flowchart of another map generation method provided in an embodiment of the present application;

[0032] Figure 6 A schematic diagram of motion trajectory optimization processing provided in an embodiment of the present application;

[0033] Figure 7 A flowchart of another map generation method provided in an embodiment of the present application;

[0034] Figure 8 A flowchart of another map generation method provided in an embodiment of the present application;

[0035] Fig. 9 A schematic diagram of the structure of a map generating device provided in an embodiment of the present application;

[0036] Fig.10A schematic diagram of the structure of an electronic device provided in an embodiment of the present application. DETAILED DESCRIPTION

[0037] The technical solutions in the embodiments of the present application will be clearly and completely described below in conjunction with the drawings in the embodiments of the present application.

[0038] The terms "first", "second", "third", etc. in the specification and claims of this application and the above-mentioned drawings are used to distinguish different objects, rather than to describe a specific order. In addition, the terms "including" and "having" and any variations thereof are intended to cover non-exclusive inclusions. For example, a process, method, system, product or device that includes a series of steps or units is not limited to the listed steps or units, but optionally includes steps or units that are not listed, or optionally includes other steps or units inherent to these processes, methods, products or devices.

[0039] See also Figure 1 , Figure 1 A schematic diagram of the architecture of a map generation system provided in an embodiment of the present application is shown.

[0040] like Figure 1 As shown, the map generation system 100 may include at least a first acquisition unit 101, a second acquisition unit 102, a third acquisition unit 103 and a processing unit 104, wherein:

[0041] The first acquisition unit 101 can obtain the posture data corresponding to multiple positions, and the posture data includes the coordinates of each position in the coordinate system and the corresponding attitude angle. The coordinate system of each position is different in the execution body of the map generation system 100. Here, the execution body of the map generation system 100 is a foot-type robot as an example. The first acquisition unit 101 can obtain the coordinates of each position in the foot-type robot coordinate system and the corresponding attitude angle based on the motor encoder. The foot-type robot coordinate system can be understood as a three-dimensional rectangular coordinate system established with the center of the foot-type robot as the origin. That is to say, the posture data corresponding to each position obtained can be expressed as (x, y, z, θ), x can represent the value of the position on the x-axis, y can represent the value of the position on the y-axis, z can represent the value of the position on the z-axis, and θ can represent the attitude angle of the position in the foot-type robot coordinate system, for example but not limited to the angle of rotation of the position in the foot-type robot coordinate system about the x-axis, the angle of rotation of the position in the foot-type robot coordinate system about the y-axis, or the angle of rotation of the position in the foot-type robot coordinate system about the z-axis.

[0042] It should be noted that the attitude angle error directly obtained based on the motor encoder is relatively large. The embodiment of the present application can also correct the attitude angle through sensors, for example, the attitude angle can be corrected through acceleration sensors, gyroscope sensors and magnetic sensors. The attitude angle corresponding to each position calculated can be expressed as (roll, pitch, yaw), roll can represent the angle of rotation of the position around the x-axis (also called the pitch angle), pitch can represent the angle of rotation of the position around the y-axis (also called the yaw angle), and yaw can represent the angle of rotation of the position around the z-axis (also called the roll angle). The posture data corresponding to each position obtained based on this can also be expressed as (x, y, z, roll, pitch, yaw). It can be understood that the legged robot coordinate system mentioned above is not limited to a three-dimensional rectangular coordinate system established with the center of the legged robot as the origin. For example, a coordinate system can also be established with the center of any foot of the legged robot as the origin, and the type of the coordinate system can be but is not limited to a two-dimensional rectangular coordinate system or a three-dimensional rectangular coordinate system.

[0043] It can also be understood that the first acquisition unit 101 can obtain the posture data corresponding to the multiple positions based on a preset time period, where the preset time period may include multiple timestamps, each timestamp may correspond to a position and corresponding posture data, so as to ensure the validity and real-time nature of the posture data corresponding to the multiple positions.

[0044] The second acquisition unit 102 can obtain point cloud data corresponding to the pose data corresponding to multiple positions based on the 3D scanning device. It can also be understood that each position corresponds to pose data and point cloud data. The point cloud data includes the coordinates of each position in the coordinate system, which can be expressed as (x, y, z). Among them, the coordinate system corresponding to the point cloud data obtained by the second acquisition unit 102 is not the same as the coordinate system corresponding to the pose data obtained by the first acquisition unit 101. Here, the executor of the map generation system 100 is a foot-type robot as an example. The first acquisition unit 101 can obtain the coordinates and corresponding attitude angles of each position in the foot-type robot coordinate system based on the motor encoder. The second acquisition unit 102 can obtain the coordinates of each position in the radar coordinate system based on the 3D laser radar. The foot-type robot coordinate system can be understood as a three-dimensional rectangular coordinate system established with the center of the foot-type robot as the origin. The radar coordinate system can be understood as a three-dimensional rectangular coordinate system established with the center of the 3D laser radar as the origin. There is an offset between the two coordinate systems.

[0045] It is understandable that the second acquisition unit 102 may also refer to the above-mentioned method to obtain point cloud data corresponding to multiple positions within a preset time period, wherein the preset time period may include multiple timestamps, and each timestamp may correspond to a position and corresponding point cloud data.

[0046] The third acquisition unit 103 can obtain image color data corresponding to the posture data corresponding to multiple positions based on the shooting device. It can also be understood that each position corresponds to posture data, point cloud data and image color data. The image color data includes the coordinates of each position in the coordinate system, which can be expressed as (x, y, z), x can correspond to the value of the position in the red channel (also known as the R channel), y can correspond to the value of the position in the green channel (also known as the G channel), and z can correspond to the value of the position in the blue channel (also known as the B channel). Among them, the coordinate system corresponding to the image color data obtained by the third acquisition unit 103, the coordinate system corresponding to the point cloud data obtained by the second acquisition unit 102, and the coordinate system corresponding to the posture data obtained by the first acquisition unit 101 are not the same coordinate system. Here, taking the executor of the map generation system 100 as a footed robot as an example, the first acquisition unit 101 can obtain the coordinates of each position in the footed robot coordinate system and the corresponding attitude angle based on the motor encoder, the second acquisition unit 102 can obtain the coordinates of each position in the radar coordinate system based on the 3D laser radar, and the third acquisition unit 103 can obtain the coordinates of each position in the camera coordinate system based on the camera. The footed robot coordinate system can be understood as a three-dimensional rectangular coordinate system established with the center of the footed robot as the origin, the radar coordinate system can be understood as a three-dimensional rectangular coordinate system established with the center of the 3D laser radar as the origin, and the camera coordinate system can be understood as a three-dimensional rectangular coordinate system established with the center of the camera as the origin. There is an offset between any two coordinate systems of the three coordinate systems.

[0047] It is understandable that the third acquisition unit 103 may also refer to the above-mentioned acquisition of image color data corresponding to each of the multiple positions within a preset period, wherein the preset period may include multiple timestamps, and each timestamp may correspond to a position and corresponding image color data. Here, in combination with the data respectively acquired by the first acquisition unit 101, the second acquisition unit 102, and the third acquisition unit, it can be understood that the pose data, point cloud data, and image color data corresponding to the position are acquired at each timestamp within the preset period.

[0048] The processing unit 104 can generate a map based on the posture data corresponding to the multiple positions obtained by the first acquisition unit 101, the point cloud data corresponding to each of the posture data corresponding to the multiple positions obtained by the second acquisition unit 102, and the image color data corresponding to each of the posture data corresponding to the multiple positions obtained by the third acquisition unit 103.

[0049] The posture data corresponding to the multiple positions obtained by the first acquisition unit 101 here can be used by the processing unit 104 to generate corresponding motion trajectories, so as to process the posture data corresponding to the positions with larger errors according to the loop detection results of the motion trajectory, thereby filtering out the posture data corresponding to the positions with larger errors, and then generating a more accurate point cloud map with color information based on the point cloud data and image color data corresponding to the posture data corresponding to the multiple positions after the filtering.

[0050] For example, when the processing unit 104 detects that there is a loop in the motion trajectory generated based on the posture data corresponding to multiple positions, it can perform nonlinear processing on the motion trajectory to filter out positions with large errors and the corresponding posture data, and can also filter out the point cloud data and image color data corresponding to the posture data with large errors, and then generate a point cloud map with color information based on the filtered point cloud data and image color data.

[0051] For an example of using this map generation system as part of a legged robot, see Figure 2 A schematic diagram of the structure of a legged robot based on a map generation system provided in an embodiment of the present application is shown.

[0052] like Figure 2 As shown, the legged robot 200 may include at least a multi-line laser radar 201, a binocular camera 202, a motor encoder 203, a processor 204, a robot joint 205 and a power supply 206, wherein:

[0053] The multi-line laser radar 201 can obtain the timestamp of each frame of radar data within a preset time period and obtain the point cloud data of each timestamp in the radar coordinate system, wherein the timestamp of each frame of radar data can be understood as the data collection frequency of the multi-line laser radar 201 within the preset time period. For example, 10 frames of radar data are obtained within 1 second in the preset time period, and the timestamp corresponding to each frame of radar data is 0.1 second, which can also be understood as obtaining point cloud data in the radar coordinate system every 0.1 seconds.

[0054] The binocular camera 202 can obtain image color data corresponding to each timestamp mentioned above in the camera coordinate system. For example, referring to the above-mentioned acquisition of 10 frames of radar data within a preset period of 1 second, the binocular camera 202 obtains image color data in the camera coordinate system every 0.1 seconds.

[0055] The motor encoder 203 can obtain the pose data corresponding to each timestamp mentioned above in the legged robot coordinate system, for example, referring to the above-mentioned acquisition of 10 frames of radar data within a preset period of 1 second, the binocular camera 202 acquires the pose data in the legged robot coordinate system every 0.1 seconds. The pose angle included in the pose data can also be corrected by the acceleration sensor, gyroscope sensor and magnetic sensor, and the corrected pose angle is used as the pose data.

[0056] The processor 204 can generate a three-dimensional point cloud map with color information based on the point cloud data at each time stamp in the radar coordinate system acquired by the multi-line laser radar 201, the image color data at each time stamp in the camera coordinate system acquired by the binocular camera 202, and the posture data at each time stamp in the legged robot coordinate system acquired by the motor encoder 203, and control the rotation of the robot joint 205 in combination with the operation instruction acquired by the legged robot. For example, after generating the three-dimensional point cloud map with color information, the processor 204 can send the three-dimensional point cloud map with color information to the legged robot control terminal, receive the operation instruction sent by the legged robot control terminal, and control the robot joint 205 to perform operations such as moving forward or backward according to the operation instruction.

[0057] The power supply 206 can supply power to the multi-line laser radar 201 , the binocular camera 202 , the motor encoder 203 , the processor 204 and the robot joint 205 respectively.

[0058] It is understandable that in the above Figure 2 The components of the legged robot mentioned in the description are not limited to obtaining point cloud data through the multi-line laser radar 201 and / or obtaining image color data through the binocular camera 202.

[0059] Possibly, the legged robot can also obtain point data through millimeter-wave radar and image color data through binocular camera. Compared with multi-line laser radar, millimeter-wave radar has stronger anti-interference ability, lower cost, and can be used in harsh outdoor environments. It should be noted that millimeter-wave radar can obtain point cloud data and speed information represented by (x, y, z) based on the radar coordinate system, so multi-line laser radar can be replaced by millimeter-wave radar.

[0060] Possibly, the legged robot can also obtain point cloud data through a multi-line laser radar and image color data through a monocular camera. The monocular camera has a smaller viewing angle than a binocular camera, but is cheaper. It should be noted that a monocular camera can also obtain image color data based on the camera coordinates represented by (x, y, z), so the binocular camera can be replaced by a monocular camera.

[0061] Possibly, the legged robot can also obtain point cloud data through millimeter wave radar and image color data through monocular camera. Compared with multi-line laser radar, the millimeter wave radar has stronger anti-interference ability and lower cost, and can be used in harsh outdoor environments; compared with binocular camera, the monocular camera has a smaller viewing angle, but lower cost. It should be noted that the millimeter wave radar can obtain point cloud data represented by (x, y, z) based on the radar coordinate system, and the monocular camera can also obtain image color data represented by (x, y, z) based on the camera coordinate system. Therefore, the multi-line laser radar can be replaced by the millimeter wave radar, and the binocular camera can be replaced by the monocular camera.

[0062] It should be noted that the map generation system proposed in this application is not limited to application in the above-mentioned legged robot field, for example, it can also be applied in the field of autonomous driving or visual analysis, and the following application will use the legged robot as the executor to explain the map generation method in detail.

[0063] See also Figure 3 , Figure 3 A flowchart of a map generation method provided in an embodiment of the present application is shown.

[0064] like Figure 3 As shown, the map generation method includes at least the following steps:

[0065] Step 301: Acquire posture data corresponding to a plurality of positions, and acquire point cloud data and image color data corresponding to each of the posture data corresponding to the plurality of positions.

[0066] Specifically, the legged robot can obtain the posture data of multiple positions in the legged robot coordinate system, and the legged robot coordinate system can be a three-dimensional rectangular coordinate system established with the center of the sole of the foot of the legged robot as the origin. The posture data may include the coordinates and posture angles of the multiple positions corresponding to the legged robot coordinate system, for example, it can be expressed as (x1, y1, z1, θ), and the x1, y1 and z1 can be understood as the values ​​corresponding to the x-axis, y-axis and z-axis of the multiple positions in the legged robot coordinate system, respectively, and the posture angle θ can be understood as the angle of rotation of the multiple positions compared to the legged robot coordinate system. It can be understood that the multiple positions can be multiple positions traversed by the legged robot during the movement, such as but not limited to multiple positions in the historical movement path of the legged robot or multiple positions in the real-time movement path of the legged robot.

[0067] Furthermore, after obtaining the posture data corresponding to the multiple positions, the legged robot can also obtain the point cloud data and image color data corresponding to each of the multiple positions. The point cloud data can be the coordinates of the multiple positions obtained by the 3D scanning device in the radar coordinate system, for example, it can be expressed as (x2, y2, z2), and the x2, y2 and z2 can be understood as the values ​​corresponding to the x-axis, y-axis and z-axis of the position in the radar coordinate system. The image color data can be the coordinates of the multiple positions obtained by the shooting device in the image coordinate system, for example, it can be expressed as (x3, y3, z3), and the x3, y3 and z3 can be understood as the values ​​corresponding to the position in the red channel (ie, R channel), the green channel (ie, G channel) and the blue channel (ie, B channel).

[0068] It should be noted that the legged robot coordinate system, the radar coordinate system and the image coordinate system are three different coordinate systems. There is an offset between any two coordinate systems, and the coordinates in any two coordinate systems can be converted by calculating the offset.

[0069] It can also be understood that the 3D scanning device in the present application may be a multi-line laser radar or a millimeter wave radar, and the shooting device may be a binocular camera or a monocular camera.

[0070] Step 302: Generate a map based on the posture data corresponding to the multiple positions, the point cloud data corresponding to the posture data corresponding to the multiple positions, and the image color data.

[0071] Specifically, after respectively acquiring the posture data, point cloud data and image color data corresponding to multiple positions, the legged robot can generate a three-dimensional point cloud map with color information based on the posture data, point cloud data and image color data corresponding to the multiple positions.

[0072] In the embodiment of the present application, the posture data corresponding to the multiple positions are obtained, and the point cloud data and image color data corresponding to the posture data corresponding to the multiple positions are obtained; the map is generated according to the posture data corresponding to the multiple positions, the point cloud data and image color data corresponding to the posture data corresponding to the multiple positions. According to the posture data, point cloud data and image color data corresponding to the multiple positions, the generated point cloud map can be given color information to increase the intuitiveness of the point cloud map, and the generated point cloud map can also be semantically analyzed to improve the scope of application of the point cloud map.

[0073] As an embodiment of the present application, each frame of point cloud data corresponds to a timestamp, and each frame of image color data corresponds to a timestamp;

[0074] Get the pose data corresponding to multiple positions, including:

[0075] Acquire posture data corresponding to multiple positions within a preset time period; each posture data corresponds to a timestamp;

[0076] Obtaining point cloud data and image color data corresponding to each of the pose data corresponding to multiple positions, including:

[0077] The point cloud data and image color data consistent with the timestamp of each pose data are obtained respectively.

[0078] Specifically, the legged robot can collect multiple frames of pose data within a preset time period, each frame of pose data can correspond to a position, and each frame of pose data can correspond to a timestamp within the preset time period. Taking the example that the legged robot can collect 10 frames of pose data within a preset time period of 1 second, the multiple positions can be ten positions corresponding to the 10 frames of pose data, and the timestamp corresponding to each position within the preset time period of 1 second is 0.1 seconds. Further, the legged robot can obtain the point cloud data and image color data corresponding to the timestamp of each pose data according to the timestamp of each pose data. Here, the above-mentioned timestamp that each position corresponds to the timestamp of 0.1 seconds within the preset time period of 1 second can be referred to as an example. The legged robot can obtain the corresponding point cloud data and image color data every 0.1 seconds within the preset time period.

[0079] It can be understood that before the legged robot obtains the posture data corresponding to multiple positions within a preset time period, it can first obtain the collection frequency of the posture data within the preset time period, that is, determine the number of posture data frames within the preset time period and the timestamp corresponding to each frame of posture data, and obtain point cloud data and image color data consistent with the timestamp of each posture data according to the determined timestamp.

[0080] It should be noted that the embodiments of the present application may not be limited to the above-mentioned legged robot, which may first obtain the collection frequency of the pose data within the preset time period before obtaining the pose data corresponding to multiple positions within the preset time period. For example, the collection frequency of the point cloud data within the preset time period may also be obtained first, that is, the number of point cloud data frames within the preset time period and the timestamp corresponding to each frame of point cloud data are determined, and the pose data corresponding to multiple positions within the preset time period are obtained according to the determined timestamp, and the point cloud data and image color data consistent with the timestamp of each pose data are respectively obtained.

[0081] Similarly, the embodiments of the present application may not be limited to the above-mentioned legged robot, which may first obtain the collection frequency of the posture data within the preset time period before obtaining the posture data corresponding to multiple positions within the preset time period. For example, the collection frequency of the image color data within the preset time period may also be obtained first, that is, the number of image color data frames within the preset time period and the timestamp corresponding to each frame of image color data are determined, and the posture data corresponding to multiple positions within the preset time period are obtained according to the determined timestamp, and the point cloud data and image color data consistent with the timestamp of each posture data are respectively obtained.

[0082] In an embodiment of the present application, the timestamp corresponding to each frame of pose data can be determined before acquiring the pose data, and the corresponding point cloud data and image color data within the same timestamp can be acquired based on the timestamp corresponding to each frame of pose data, so that the acquired pose data and the point cloud data and image color data have a one-to-one correspondence in terms of the timestamp, thereby ensuring the accuracy of the color information given by the generated point cloud map and a more comfortable intuitive experience.

[0083] As another embodiment of the present application, after acquiring posture data corresponding to a plurality of positions within a preset time period, before generating a map according to the posture data corresponding to the plurality of positions, the point cloud data corresponding to the posture data corresponding to the plurality of positions, and the image color data, the method further includes:

[0084] Converting the pose data corresponding to the multiple positions into multiple pose data generated based on the world coordinate system;

[0085] A map is generated according to the posture data corresponding to the plurality of positions, the point cloud data corresponding to each of the posture data corresponding to the plurality of positions, and the image color data, including:

[0086] A map is generated based on a plurality of pose data generated based on a world coordinate system, point cloud data corresponding to each of the plurality of pose data generated based on the world coordinate system, and image color data.

[0087] Specifically, before the legged robot generates a map based on the pose data corresponding to the multiple positions, the point cloud data corresponding to the pose data corresponding to the multiple positions, and the image color data, the pose data corresponding to the multiple positions generated based on the legged robot coordinate system may be converted into pose data generated based on the world coordinate system. Among them, the legged robot coordinate system may be a three-dimensional rectangular coordinate system established with the center of the sole of the foot of the legged robot as the origin, and the sole may be but is not limited to any one of the four soles of the quadruped robot, and the world coordinate system may be a three-dimensional rectangular coordinate system established with a certain point on the plane where the legged robot is located as a fixed origin. It can be understood that the legged robot coordinate system and the world coordinate system in the embodiment of the present application can be established based on the origin selected by default by the legged robot or the origin manually set by the operator.

[0088] Taking the coordinates (x, y, z, roll, pitch, yaw) generated by the pose data corresponding to a certain position in the legged robot coordinate system as an example, the coordinates (X, Y, Z) of the position in the world coordinate system can be obtained based on the following formula (1):

[0089] (1)

[0090] Among them, R is the rotation matrix, and T is the translation matrix represented by the coordinates corresponding to the origin of the legged robot coordinate system in the world coordinate system.

[0091] Here, since the coordinates generated by the position in the legged robot coordinate system are jointly controlled by the components in the x-axis, y-axis, and z-axis directions, the rotation matrix R can be obtained by the following formulas (2)-(5):

[0092] R = r1 × r2 × r3 (2)

[0093] (3)

[0094] (4)

[0095] (5)

[0096] Among them, in formula (3) It can be the angle between the plane where the y-axis and z-axis of the legged robot coordinate system are located and the plane where the Y-axis and Z-axis of the world coordinate system are located. For details, please refer to Figure 4 The schematic diagram of the rotation angle corresponding to a in the schematic diagram of the rotation angle of a coordinate system provided in an embodiment of the present application is shown. It can be the angle between the plane where the x-axis and z-axis of the legged robot coordinate system are located and the plane where the x-axis and z-axis of the world coordinate system are located. For details, please refer to Figure 4 The diagram of the rotation angle corresponding to b in the coordinate system rotation angle diagram provided in the embodiment of the present application is shown in FIG. It can be the angle between the plane where the y-axis and x-axis of the legged robot coordinate system are located and the plane where the Y-axis and X-axis of the world coordinate system are located. For details, please refer to Figure 4 A schematic diagram of the rotation angle corresponding to c in a schematic diagram of the rotation angle of a coordinate system provided in an embodiment of the present application is shown.

[0097] It is understandable that the above-mentioned conversion between the legged robot coordinate system and the world coordinate system can be implemented based on editing code, such as but not limited to Python code, which will not be elaborated here.

[0098] In an embodiment of the present application, the pose data corresponding to multiple positions can be converted into a coordinate system so as to quickly combine the pose data, point cloud data and image color data corresponding to multiple positions to generate a point cloud map with color information, thereby improving the efficiency of point cloud map generation.

[0099] As another embodiment of the present application, please refer to Figure 5 A flowchart of another map generation method provided in an embodiment of the present application is shown.

[0100] like Figure 5 As shown, the map generation method includes at least the following steps:

[0101] Step 501: Acquire posture data corresponding to a plurality of positions, and acquire point cloud data and image color data corresponding to each of the posture data corresponding to the plurality of positions.

[0102] Specifically, step 501 is consistent with step 301 and will not be described again here.

[0103] Step 502: Convert the pose data corresponding to the multiple positions into a plurality of pose data generated based on the world coordinate system.

[0104] Specifically, step 502 can refer to the above-mentioned embodiment, which will not be described in detail here.

[0105] Step 503: Generate a motion trajectory within a preset time period according to a plurality of posture data generated based on a world coordinate system.

[0106] Specifically, after obtaining posture data corresponding to multiple positions within a preset time period and converting the posture data corresponding to the multiple positions into posture data generated based on the world coordinate system, the legged robot can generate a motion trajectory within the preset time period in the world coordinate system by connecting adjacent coordinate points according to the multiple coordinate points in the world coordinate system that respectively correspond to the posture data generated based on the world coordinate system corresponding to the multiple positions.

[0107] It is understandable that the present application is not limited to the above-mentioned method of generating a motion trajectory within a preset time period by connecting coordinate points, and the motion trajectory can also be established by other models.

[0108] Step 504: perform loop detection on the motion trajectory.

[0109] Specifically, after determining the pose data corresponding to the first position among multiple positions, the pose data corresponding to each subsequent position can be calculated recursively, but the pose data corresponding to each subsequently calculated position will have errors, and the errors in the pose data corresponding to two adjacent positions will be accumulated to the error in the pose data corresponding to the next position.

[0110] In order to eliminate the error of posture data, the legged robot can perform loop detection on the motion trajectory within a preset period of time, which can be understood as detecting whether the motion trajectory is a loop trajectory (that is, whether there are two identical positions in the motion trajectory). It should be noted that the two identical positions in the motion trajectory are not necessarily limited to the first position and the last position, that is, the motion trajectory can be a loop trajectory during the motion process and its last position is not the same as the first position.

[0111] Here, the embodiment of the present application adopts loop detection for the motion trajectory by inputting the motion trajectory into the bag-of-words model, calculating the similarity between the bag-of-words vector corresponding to the motion trajectory and the loop detection vector obtained by using the reverse index, taking the one with the highest similarity as the loop pair, and verifying the loop pair to check whether it is a correct loop. Of course, the embodiment of the present application can also use other visual algorithms to perform loop detection on the motion trajectory.

[0112] Step 505: If the loop detection result shows that a loop exists, a map is generated according to the point cloud data and image color data corresponding to each of the plurality of posture data generated based on the world coordinate system corresponding to the motion trajectory.

[0113] Specifically, if the legged robot detects that the loop detection result of the motion trajectory is a loop, it indicates that there is a loop trajectory in the motion trajectory. The motion trajectory can be corrected, and a point cloud map with color information can be generated based on the corresponding multiple posture data in the corrected motion trajectory and the point cloud data corresponding to the multiple posture data and the image color data.

[0114] In an embodiment of the present application, loop detection is performed on the motion trajectory generated by the posture data corresponding to multiple positions, and the motion trajectory is corrected when a loop is detected. This can improve the accuracy of the acquired posture data, point cloud data, and image color data, so that the generated point cloud map with color information has a smaller error.

[0115] As another embodiment of the present application, a map is generated according to point cloud data and image color data corresponding to each of a plurality of posture data generated based on a world coordinate system corresponding to the motion trajectory, including:

[0116] Perform nonlinear processing on the motion trajectory to obtain an optimized motion trajectory;

[0117] A map is generated according to the point cloud data and image color data respectively corresponding to a plurality of posture data generated based on a world coordinate system corresponding to the optimized motion trajectory.

[0118] Specifically, after the motion trajectory detects a loop, the legged robot can perform nonlinear processing optimization on the motion trajectory to obtain an optimized motion trajectory. The optimized motion trajectory is smoother and has a smaller error than the motion trajectory for loop detection, and the number of multiple positions corresponding to the optimized motion trajectory is less than or equal to the number of multiple positions corresponding to the motion trajectory for loop detection. Figure 6 The schematic diagram of a motion trajectory optimization process provided by an embodiment of the present application is shown. Figure 6 In the motion trajectory of the detected loop shown in 6a, the first position coincides with the last position, and position A is taken as the first position. The motion trajectory can include position A, position a, position b, position B, position c, position d, position C, position D, position e, position E, position f, position g, and position A in the order of the trajectory. Figure 6 6b shows the motion trajectory after the motion trajectory in 6a is optimized, and the optimized motion trajectory may include position A, position B, position C, position D and position E in the order of the trajectory. It can be understood that the optimized motion trajectory shown in 6b eliminates the error influence of position a, position b, position c, position d, position e and position f on the motion trajectory compared with the motion trajectory shown in 6a.

[0119] It should be noted that after obtaining the optimized motion trajectory, the legged robot can generate a three-dimensional point cloud map with color information based on the point cloud data and image color data corresponding to the multiple posture data corresponding to the optimized motion trajectory. It can also be understood as generating a more accurate point cloud map with color information based on the optimized multiple point cloud data and the corresponding image color data.

[0120] It can also be understood that the embodiments of the present application can be, but are not limited to, optimized in a nonlinear optimization manner, such as filtering, smoothing, and the like.

[0121] In an embodiment of the present application, an optimized motion trajectory is obtained by processing the detected loop motion trajectory, and a point cloud map with color information is generated according to the optimized motion trajectory combined with corresponding optimized multiple point cloud data and image color data, thereby reducing the amount of calculation and increasing the accuracy of the generated point cloud map.

[0122] As another embodiment of the present application, the point cloud data is generated based on a radar coordinate system, the image color data is generated based on a camera coordinate system, and there are preset conversion parameters between the radar coordinate system and the camera coordinate system;

[0123] A map is generated according to point cloud data and image color data corresponding to each of a plurality of posture data generated based on a world coordinate system corresponding to the optimized motion trajectory, including:

[0124] Based on preset conversion parameters, point cloud data and image color data corresponding to multiple posture data generated based on the world coordinate system corresponding to the optimized motion trajectory are converted and processed, and a map is generated based on the converted point cloud data and image color data.

[0125] Specifically, the legged robot can obtain point cloud data consistent with the timestamp of each pose data through a 3D laser scanning device. The 3D laser scanning can be but not limited to a multi-line laser radar or a millimeter wave laser radar fixedly installed on the legged robot, and each point cloud data is generated based on the radar coordinate system. In addition, the legged robot can also obtain image color data consistent with the timestamp of each pose data through a shooting device. The shooting device can be but not limited to a monocular camera or a binocular camera fixedly installed on the legged robot, and each image color data is generated based on the camera coordinate system. It can be understood that the 3D laser scanning device for obtaining point cloud data and the shooting device for obtaining image color data are both fixedly set on the legged robot, that is, there are fixed conversion parameters between the radar coordinate system corresponding to the 3D laser scanning device and the camera coordinate system corresponding to the shooting device, and the coordinates in the radar coordinate system and the camera coordinate system can be fixedly converted by the fixed conversion parameters.

[0126] Here, the coordinates of a certain position in the radar coordinate system are (Xl, Yl, Zl), and the coordinates in the camera coordinate system are (Xc, Yc, Zc) as an example. The two coordinates can have a corresponding conversion relationship as shown in the following formula (6):

[0127] (6)

[0128] Among them, since the camera coordinate system is fixed with the radar coordinate system, the angle between the plane where the Y axis and Z axis in the camera coordinate system are located and the plane where the Y axis and Z axis in the radar coordinate system are located is fixed, the angle between the plane where the Z axis and X axis in the camera coordinate system are located and the plane where the Z axis and X axis in the radar coordinate system are located is fixed, and the angle between the plane where the Y axis and X axis in the camera coordinate system are located and the plane where the Y axis and X axis in the radar coordinate system are located is fixed. Based on this, R0 can be expressed as a fixed 3×3 rotation matrix obtained by the camera coordinate system with the radar coordinate system as the reference.

[0129] Wherein, T0 may be an offset matrix represented by the fixed coordinates of the origin of the camera coordinate system in the radar coordinate system.

[0130] It should be noted that the above formula (6) can convert the coordinates in the camera coordinate system into the coordinates in the radar coordinate system. Based on a similar principle, the coordinates in the radar coordinate system can also be converted into the coordinates in the camera coordinate system. We will not elaborate on this here.

[0131] Furthermore, after the legged robot performs nonlinear processing optimization on the motion trajectory and obtains the optimized motion trajectory, the point cloud data corresponding to each of the multiple posture data corresponding to the optimized motion trajectory can be converted into image color data, so that the multiple point cloud data and the corresponding image color data are generated based on the same coordinate system, and a point cloud map with color information is generated based on the multiple point cloud data generated based on the same coordinate system and the corresponding image color data.

[0132] In an embodiment of the present application, the multiple optimized point cloud data and image color data are converted to obtain point cloud data and image color data generated based on the same coordinate system, which can further improve the efficiency of generating a point cloud map with color information, while ensuring the accuracy of the generated point cloud map and providing users with a better operating experience.

[0133] As another embodiment of the present application, based on preset conversion parameters, point cloud data and image color data corresponding to each of multiple pose data generated based on a world coordinate system corresponding to the optimized motion trajectory are converted, and a map is generated based on the converted point cloud data and image color data, including:

[0134] Based on preset conversion parameters, image color data corresponding to a plurality of pose data generated based on a world coordinate system and corresponding to the optimized motion trajectory are converted into image color data generated based on a radar coordinate system;

[0135] A map is generated according to point cloud data corresponding to each of a plurality of posture data generated based on a world coordinate system and corresponding to the optimized motion trajectory and image color data generated based on a radar coordinate system, including:

[0136] Converting point cloud data corresponding to a plurality of pose data generated based on a world coordinate system and image color data generated based on a radar coordinate system, respectively, corresponding to the optimized motion trajectory, into point cloud data generated based on a world coordinate system and image color data generated based on a world coordinate system;

[0137] A map is generated based on the point cloud data generated based on the world coordinate system and the image color data generated based on the world coordinate system.

[0138] Specifically, taking the preset conversion parameters as an example of fixedly converting the coordinates of the camera coordinate system into the coordinates of the radar coordinate system, the legged robot can convert the image color data corresponding to each of the optimized multiple posture data into image color data generated based on the radar coordinate system according to the preset conversion parameters, and further convert the multiple point cloud data and image color data generated based on the radar coordinate system into multiple point cloud data and image color data generated based on the world coordinate system, so that the point cloud map with color information generated based on the world coordinate system has wider applicability. Among them, in the process of further converting the multiple point cloud data and image color data generated based on the radar coordinate system into multiple point cloud data and image color data generated based on the world coordinate system, the conversion parameters of the radar coordinate system and the world coordinate system corresponding to each position are inconsistent, so it is necessary to calculate the rotation matrix and translation matrix of the point cloud data and image color data generated based on the radar coordinate system corresponding to each position to convert the coordinates of the radar coordinate system into the coordinates of the world coordinate system, and convert the corresponding point cloud data and image color data based on the rotation matrix and translation matrix of each position. It should be noted that the rotation matrix converted from the radar coordinate system corresponding to each position to the world coordinate system can be calculated by referring to formulas (1) to (5) mentioned in the above embodiment. The translation matrix converted from the radar coordinate system corresponding to each position to the world coordinate system can be determined based on the coordinates of the origin of the radar coordinate system corresponding to the position in the world coordinate system. The conversion relationship between the radar coordinate system and the world coordinate system is a well-known technology and will not be elaborated here.

[0139] As another embodiment of the present application, based on preset conversion parameters, point cloud data and image color data corresponding to each of the plurality of pose data generated based on the world coordinate system corresponding to the optimized motion trajectory are converted, and a map is generated based on the converted point cloud data and image color data, including:

[0140] Based on preset conversion parameters, point cloud data corresponding to a plurality of pose data generated based on a world coordinate system and corresponding to the optimized motion trajectory are converted into point cloud data generated based on a camera coordinate system;

[0141] A map is generated according to point cloud data generated based on a camera coordinate system and image color data corresponding to a plurality of pose data generated based on a world coordinate system corresponding to the optimized motion trajectory, including:

[0142] Converting point cloud data generated based on the camera coordinate system and image color data corresponding to each of the plurality of pose data generated based on the world coordinate system corresponding to the optimized motion trajectory into point cloud data generated based on the world coordinate system and image color data generated based on the world coordinate system respectively;

[0143] A map is generated based on the point cloud data generated based on the world coordinate system and the image color data generated based on the world coordinate system.

[0144] Specifically, taking the preset conversion parameters as an example of fixedly converting the coordinates of the radar coordinate system into the coordinates of the camera coordinate system, the legged robot can convert the point cloud data corresponding to each of the optimized multiple posture data into point cloud data generated based on the camera coordinate system according to the preset conversion parameters, and further convert the multiple point cloud data and image color data generated based on the camera coordinate system into multiple point cloud data and image color data generated based on the world coordinate system, so that the point cloud map with color information generated based on the world coordinate system has wider applicability. Among them, in the process of further converting the multiple point cloud data and image color data generated based on the camera coordinate system into multiple point cloud data and image color data generated based on the world coordinate system, the conversion parameters of the camera coordinate system and the world coordinate system corresponding to each position are inconsistent, so it is necessary to calculate the rotation matrix and translation matrix of the point cloud data and image color data generated based on the camera coordinate system corresponding to each position to convert the coordinates of the camera coordinate system into the coordinates of the world coordinate system, and convert the corresponding point cloud data and image color data based on the rotation matrix and translation matrix of each position. It should be noted that the rotation matrix of the camera coordinate system corresponding to each position converted to the world coordinate system can be calculated by referring to formulas (1) to (5) mentioned in the above embodiment. The translation matrix of the camera coordinate system corresponding to each position converted to the world coordinate system can be determined based on the coordinates of the origin of the radar coordinate system corresponding to the position in the world coordinate system. The conversion relationship between the camera coordinate system and the world coordinate system is a well-known technology and will not be elaborated here.

[0145] As another embodiment of the present application, after loop closure detection is performed on the motion trajectory, the method further includes:

[0146] If the loop detection result is that there is no loop, a map is generated based on the point cloud data and image color data corresponding to each of the plurality of posture data generated based on the world coordinate system.

[0147] Specifically, if the legged robot detects that the loop detection result of the motion trajectory is that there is no loop, it means that there is no loop trajectory in the motion trajectory, for example, the motion trajectory is a straight line trajectory or a non-loop curve trajectory. Here, taking the motion trajectory as a straight line trajectory as an example, it can be seen that the posture change of each position in the straight line trajectory is small (only the corresponding coordinate value changes), and the posture error between two adjacent positions is small, so a point cloud map with color information can be directly generated based on the acquired point cloud data consistent with the timestamp of each posture data and the image color data.

[0148] In an embodiment of the present application, if the motion trajectory generated by the posture data corresponding to multiple positions does not have a loop, a point cloud map with color information can be directly generated based on the point cloud data corresponding to each posture data and the image color data, thereby effectively ensuring the generation efficiency of the point cloud map.

[0149] As another embodiment of the present application, the point cloud data is generated based on a radar coordinate system, the image color data is generated based on a camera coordinate system, and there are preset conversion parameters between the radar coordinate system and the camera coordinate system;

[0150] A map is generated based on point cloud data and image color data corresponding to each of a plurality of pose data generated based on a world coordinate system, including:

[0151] Based on preset conversion parameters, point cloud data and image color data corresponding to multiple posture data generated based on the world coordinate system are converted and processed, and a map is generated according to the converted point cloud data and image color data.

[0152] Specifically, the legged robot can obtain point cloud data consistent with the timestamp of each pose data through a 3D laser scanning device. The 3D laser scanning can be but not limited to a multi-line laser radar or a millimeter wave laser radar fixedly installed on the legged robot, and each point cloud data is generated based on the radar coordinate system. In addition, the legged robot can also obtain image color data consistent with the timestamp of each pose data through a shooting device. The shooting device can be but not limited to a monocular camera or a binocular camera fixedly installed on the legged robot, and each image color data is generated based on the camera coordinate system. It can be understood that the 3D laser scanning device for obtaining point cloud data and the shooting device for obtaining image color data are both fixedly set on the legged robot, that is, there are fixed conversion parameters between the radar coordinate system corresponding to the 3D laser scanning device and the camera coordinate system corresponding to the shooting device, and the coordinates in the radar coordinate system and the camera coordinate system can be fixedly converted by the fixed conversion parameters.

[0153] Furthermore, when the legged robot detects that the loop detection result of the motion trajectory is that there is no loop, it can directly convert the point cloud data corresponding to the multiple posture data into image color data, so that the multiple point cloud data and the corresponding image color data are generated based on the same coordinate system, and generate a point cloud map with color information based on the multiple point cloud data generated based on the same coordinate system and the corresponding image color data.

[0154] In an embodiment of the present application, the point cloud data and image color data corresponding to each of the multiple posture data are directly converted and processed to obtain point cloud data and image color data generated based on the same coordinate system, which can further improve the efficiency of generating a point cloud map with color information, while ensuring the accuracy of the generated point cloud map and providing users with a better operating experience.

[0155] As another embodiment of the present application, please refer to Figure 7 A flowchart of another map generation method provided in an embodiment of the present application is shown.

[0156] like Figure 7 As shown, the map generation method includes at least the following steps:

[0157] Step 701: Obtain posture data corresponding to multiple positions, and obtain point cloud data and image color data corresponding to each of the posture data corresponding to the multiple positions.

[0158] Specifically, step 701 is consistent with step 501 and step 301 and will not be repeated here.

[0159] Step 702: Convert the pose data corresponding to the multiple positions into a plurality of pose data generated based on the world coordinate system.

[0160] Specifically, step 702 is consistent with step 502 and will not be repeated here.

[0161] Step 703: Generate a motion trajectory within a preset time period according to a plurality of posture data generated based on a world coordinate system.

[0162] Specifically, step 703 is consistent with step 503 and will not be repeated here.

[0163] Step 704: perform loop detection on the motion trajectory.

[0164] Specifically, step 704 is consistent with step 504 and will not be described again here.

[0165] Step 705: If the loop detection result is that there is no loop, then obtain the posture data corresponding to the multiple positions in the next time period corresponding to the preset time period; each posture data corresponds to a timestamp.

[0166] Specifically, if the legged robot detects that the loop detection result of the motion trajectory is that there is no loop, it can also determine the next time period corresponding to the preset time period, and obtain the posture data corresponding to each timestamp in the next time period. Among them, the next time period can be a time period equal to the preset time period and adjacent to the preset time period. For example, taking the preset time period as 0-10 seconds and the timestamp corresponding to each frame of posture data as 0.1 seconds, it can be determined that the next time period is 10-20 seconds, and the timestamp corresponding to each frame of posture data in the next time period is also 0.1 seconds, and the values ​​corresponding to multiple positions here are 100.

[0167] Step 706: convert the posture data corresponding to the multiple positions obtained in the next time period into multiple posture data generated based on the world coordinate system.

[0168] Specifically, the legged robot can convert the posture data corresponding to multiple positions generated based on the legged robot coordinate system in the next time period into posture data generated based on the world coordinate system. Among them, the legged robot coordinate system can be a three-dimensional rectangular coordinate system established with the center of the sole of the foot of the legged robot as the origin, and the sole can be but not limited to any one of the four soles of the quadruped robot, and the world coordinate system can be a three-dimensional rectangular coordinate system established with a certain point on the plane where the legged robot is located as a fixed origin. It can be understood that the legged robot coordinate system and the world coordinate system in the embodiment of the present application can be established based on the default origin selected by the legged robot or the origin manually set by the operator.

[0169] Step 707: Generate a motion trajectory for the next time period according to multiple pose data generated based on the world coordinate system, and perform loop detection on the motion trajectory for the next time period.

[0170] Specifically, after the legged robot obtains the posture data corresponding to multiple positions in the next time period and converts the posture data corresponding to the multiple positions into posture data generated based on the world coordinate system, it can generate a motion trajectory in the next time period in the world coordinate system by connecting adjacent coordinate points according to the multiple coordinate points in the world coordinate system that respectively correspond to the posture data generated based on the world coordinate system corresponding to the multiple positions.

[0171] It is understandable that the present application may not be limited to the above-mentioned loop detection on the motion trajectory in the next time period. For example, after generating the motion trajectory in the next time period according to multiple posture data generated based on the world coordinate system, loop detection may be performed on the motion trajectory composed of the preset time period and the next time period.

[0172] Furthermore, if the legged robot detects that there is a loop in the motion trajectory within the next time period, the motion trajectory can be corrected, and a point cloud map with color information can be generated based on the corresponding multiple posture data in the corrected motion trajectory, the point cloud data corresponding to each of the multiple posture data, and the image color data.

[0173] Furthermore, if the legged robot detects that there is no loop in the motion trajectory in the next time period, it can continue to determine the time period corresponding to the next time period, obtain the posture data corresponding to multiple positions in the time period and generate the corresponding motion trajectory, and continue to perform loop detection on the corresponding motion trajectory in the time period until a loop is detected. It should be noted that when the legged robot detects the existence of a loop in a certain time period, it can correct the motion trajectory, and generate a point cloud map with color information based on the multiple posture data corresponding to the corrected motion trajectory, the point cloud data corresponding to each of the multiple posture data, and the image color data.

[0174] In an embodiment of the present application, if it is detected that there is no loop in the motion trajectory, the posture data and the corresponding motion trajectory in the next time period can be obtained based on the preset time period, and loop detection can be continued on the motion trajectory in the next time period until a loop is found and a point cloud map with color information is generated to ensure that the error of the generated map is minimized.

[0175] As another embodiment of the present application, please refer to Figure 8 A flowchart of another map generation method provided in an embodiment of the present application is shown.

[0176] like Figure 8 As shown, the map generation method includes at least the following steps:

[0177] Step 801: Obtain the timestamp of each frame of posture data within a preset time period.

[0178] Step 802: Obtain posture data corresponding to multiple positions according to the timestamp.

[0179] Step 803: respectively obtain point cloud data and image color data that are consistent with the timestamp of each pose data.

[0180] Step 804: perform loop detection on the motion trajectory generated according to the posture data corresponding to the multiple positions.

[0181] Step 805 , determine whether there is a loop in the motion trajectory, if yes, proceed to step 806 , if no, proceed to step 802 .

[0182] Step 806: Perform nonlinear processing on the motion trajectory to obtain an optimized motion trajectory.

[0183] Step 807: based on preset conversion parameters, the point cloud data corresponding to each of the plurality of pose data generated based on the world coordinate system and corresponding to the optimized motion trajectory are converted into point cloud data generated based on the camera coordinate system.

[0184] Step 808: Convert the point cloud data generated based on the camera coordinate system and the image color data corresponding to the multiple pose data generated based on the world coordinate system corresponding to the optimized motion trajectory into the point cloud data generated based on the world coordinate system and the image color data generated based on the world coordinate system respectively.

[0185] Step 809: Generate a map according to the point cloud data generated based on the world coordinate system and the image color data generated based on the world coordinate system.

[0186] Specifically, the footed robot can obtain the timestamp of each frame of pose data within a preset time period, and obtain the pose data corresponding to multiple positions, the point cloud data consistent with the timestamp of each pose data, and the image color data according to the timestamp. It can be understood that the embodiments of the present application may not be limited to obtaining the timestamp of each frame of pose data within a preset time period, for example, it can also be the timestamp of each frame of point cloud data or the timestamp of each frame of image color data within a preset time period. Further, the footed robot can generate a motion trajectory in the world coordinate system according to the pose data corresponding to multiple positions, and perform loop detection on the motion trajectory. Possibly, if the loop detection result is that there is no loop, then continue to obtain the pose data corresponding to multiple positions, the point cloud data consistent with the timestamp of each pose data, and the image color data according to the timestamp, and continue to perform loop detection on the motion trajectory generated in the world coordinate system according to the pose data corresponding to the multiple positions. Possibly, if the loop detection result is that a loop exists, the motion trajectory is processed nonlinearly to obtain an optimized motion trajectory, and based on the preset conversion parameters, the point cloud data corresponding to each of the multiple pose data generated based on the world coordinate system corresponding to the optimized motion trajectory is converted into point cloud data generated based on the camera coordinate system. It can be understood here that the preset conversion parameters may not be limited to converting the coordinates of the radar coordinate system into the coordinates of the camera coordinate system, for example, it may also be converting the coordinates of the camera coordinate system into the coordinates of the radar coordinate system. Furthermore, the legged robot can convert the point cloud data generated based on the camera coordinate system and the image color data corresponding to each of the multiple pose data generated based on the world coordinate system corresponding to the optimized motion trajectory into point cloud data generated based on the world coordinate system and image color data generated based on the world coordinate system, respectively, and generate a point cloud map with color information based on the point cloud data generated based on the world coordinate system and the image color data generated based on the world coordinate system.

[0187] See also Fig. 9 , Fig. 9A schematic structural diagram of a map generating device provided in an embodiment of the present application is shown.

[0188] like Fig. 9 As shown, the map generating device 900 may include at least an acquisition module 901 and a first processing module 902, wherein:

[0189] An acquisition module 901 is used to acquire posture data corresponding to a plurality of positions, and acquire point cloud data and image color data corresponding to the posture data corresponding to the plurality of positions;

[0190] The first processing module 902 is used to generate a map according to the posture data corresponding to the multiple positions, the point cloud data corresponding to the posture data corresponding to the multiple positions, and the image color data.

[0191] In some possible embodiments, each frame of point cloud data corresponds to a timestamp, and each frame of image color data corresponds to a timestamp;

[0192] The acquisition module 901 is used to acquire the posture data corresponding to multiple positions within a preset time period; each posture data corresponds to a timestamp; and

[0193] Used to obtain point cloud data and image color data that are consistent with the timestamp of each pose data.

[0194] In some possible embodiments, the map generating device 900 further includes:

[0195] A second processing module is used for, after acquiring the posture data corresponding to the multiple positions within a preset time period, converting the posture data corresponding to the multiple positions into a plurality of posture data generated based on a world coordinate system before generating a map according to the posture data corresponding to the multiple positions, the point cloud data corresponding to each of the posture data corresponding to the multiple positions, and the image color data;

[0196] The first processing module 902 is used to generate a map according to a plurality of posture data generated based on a world coordinate system, point cloud data corresponding to each of the plurality of posture data generated based on the world coordinate system, and image color data.

[0197] In some possible embodiments, the first processing module 902 includes:

[0198] A first processing unit, configured to generate a motion trajectory within a preset time period according to a plurality of posture data generated based on a world coordinate system;

[0199] A second processing unit, used for performing loop detection on the motion trajectory;

[0200] The third processing unit is used to generate a map according to the point cloud data and image color data corresponding to each of the plurality of posture data generated based on the world coordinate system corresponding to the motion trajectory if the loop detection result shows that a loop exists.

[0201] In some possible embodiments, the third processing unit is specifically configured to:

[0202] Perform nonlinear processing on the motion trajectory to obtain an optimized motion trajectory;

[0203] A map is generated according to the point cloud data and image color data respectively corresponding to a plurality of posture data generated based on a world coordinate system corresponding to the optimized motion trajectory.

[0204] In some possible embodiments, the point cloud data is generated based on a radar coordinate system, and the image color data is generated based on a camera coordinate system, and there are preset conversion parameters between the radar coordinate system and the camera coordinate system;

[0205] The third processing unit is specifically used for:

[0206] Based on preset conversion parameters, point cloud data and image color data corresponding to multiple posture data generated based on the world coordinate system corresponding to the optimized motion trajectory are converted and processed, and a map is generated based on the converted point cloud data and image color data.

[0207] In some possible embodiments, the third processing unit is specifically configured to:

[0208] Based on preset conversion parameters, image color data corresponding to a plurality of pose data generated based on a world coordinate system and corresponding to the optimized motion trajectory are converted into image color data generated based on a radar coordinate system;

[0209] A map is generated based on point cloud data corresponding to a plurality of posture data generated based on a world coordinate system and corresponding to the optimized motion trajectory and image color data generated based on a radar coordinate system.

[0210] In some possible embodiments, the third processing unit is specifically configured to:

[0211] Converting point cloud data corresponding to a plurality of pose data generated based on a world coordinate system and image color data generated based on a radar coordinate system, respectively, corresponding to the optimized motion trajectory, into point cloud data generated based on a world coordinate system and image color data generated based on a world coordinate system;

[0212] A map is generated based on the point cloud data generated based on the world coordinate system and the image color data generated based on the world coordinate system.

[0213] In some possible embodiments, the third processing unit is specifically configured to:

[0214] Based on preset conversion parameters, point cloud data corresponding to a plurality of pose data generated based on a world coordinate system and corresponding to the optimized motion trajectory are converted into point cloud data generated based on a camera coordinate system;

[0215] A map is generated based on point cloud data generated based on a camera coordinate system and image color data corresponding to a plurality of posture data generated based on a world coordinate system corresponding to the optimized motion trajectory.

[0216] In some possible embodiments, the third processing unit is specifically configured to:

[0217] Converting point cloud data generated based on the camera coordinate system and image color data corresponding to each of the plurality of pose data generated based on the world coordinate system corresponding to the optimized motion trajectory into point cloud data generated based on the world coordinate system and image color data generated based on the world coordinate system respectively;

[0218] A map is generated based on the point cloud data generated based on the world coordinate system and the image color data generated based on the world coordinate system.

[0219] In some possible embodiments, the first processing module 902 further includes:

[0220] The fourth processing unit is used to generate a map according to the point cloud data and image color data corresponding to each of the plurality of posture data generated based on the world coordinate system after performing loop detection on the motion trajectory, if the loop detection result is that there is no loop.

[0221] In some possible embodiments, the point cloud data is generated based on a radar coordinate system, and the image color data is generated based on a camera coordinate system, and there are preset conversion parameters between the radar coordinate system and the camera coordinate system;

[0222] The fourth processing unit is specifically used for:

[0223] Based on preset conversion parameters, point cloud data and image color data corresponding to multiple posture data generated based on the world coordinate system are converted and processed, and a map is generated according to the converted point cloud data and image color data.

[0224] In some possible embodiments, the first processing module 902 further includes:

[0225] A fifth processing unit is used for performing loop detection on the motion trajectory, and if the loop detection result is that there is no loop, obtaining posture data corresponding to multiple positions in a next time period corresponding to the preset time period; each posture data corresponds to a timestamp;

[0226] Converting the pose data corresponding to the multiple positions acquired in the next period into multiple pose data generated based on the world coordinate system;

[0227] A motion trajectory for the next period of time is generated according to a plurality of posture data generated based on a world coordinate system, and a loop detection is performed on the motion trajectory for the next period of time.

[0228] See also Fig.10 , Fig.10 A schematic structural diagram of an electronic device provided in an embodiment of the present application is shown.

[0229] like Fig.10 As shown, the electronic device 1000 may include: at least one processor 1001, at least one network interface 1004, a user interface 1003, a memory 1005, a laser radar 1006, a camera 1007, a motor encoder 1008 and at least one communication bus 1002.

[0230] The communication bus 1002 may be used to realize the connection and communication among the above-mentioned components.

[0231] The user interface 1003 may include buttons, and the optional user interface may also include a standard wired interface or a wireless interface.

[0232] The network interface 1004 may include, but is not limited to, a Bluetooth module, an NFC module, a Wi-Fi module, etc.

[0233] Among them, the processor 1001 may include one or more processing cores. The processor 1001 uses various interfaces and lines to connect the various parts of the entire electronic device 1000, and runs or executes instructions, programs, code sets or instruction sets stored in the memory 1005, and calls the data stored in the memory 1005, and the various functions and processing data of the electronic device 1000. Optionally, the processor 1001 can be implemented in at least one hardware form of DSP, FPGA, and PLA. The processor 1001 can integrate one or a combination of CPU, GPU, modem, etc. Among them, the CPU mainly processes the operating system, user interface, and application programs; the GPU is responsible for rendering and drawing the content to be displayed on the display screen; the modem is used to process wireless communications. It can be understood that the above-mentioned modem may not be integrated into the processor 1001, and it can be implemented separately through a chip.

[0234] Among them, the memory 1005 may include RAM and may also include ROM. Optionally, the memory 1005 includes a non-transitory computer-readable medium. The memory 1005 can be used to store instructions, programs, codes, code sets or instruction sets. The memory 1005 may include a program storage area and a data storage area, wherein the program storage area may store instructions for implementing an operating system, instructions for at least one function (such as a touch function, a sound playback function, an image playback function, etc.), instructions for implementing the above-mentioned various method embodiments, etc.; the data storage area may store data involved in the above-mentioned various method embodiments, etc. The memory 1005 may optionally be at least one storage device located away from the aforementioned processor 1001. As Fig.10 As shown, the memory 1005 as a computer storage medium may include an operating system, a network communication module, a user interface module, and a map generation application.

[0235] Specifically, the processor 1001 may be used to call a map generation application stored in the memory 1005, and specifically perform the following operations:

[0236] Acquire posture data corresponding to a plurality of positions, and acquire point cloud data and image color data corresponding to each of the posture data corresponding to the plurality of positions;

[0237] A map is generated according to the posture data corresponding to the multiple positions, the point cloud data corresponding to each of the posture data corresponding to the multiple positions, and the image color data.

[0238] In some possible embodiments, each frame of point cloud data corresponds to a timestamp, and each frame of image color data corresponds to a timestamp;

[0239] When the processor 1001 obtains the posture data corresponding to the multiple positions, it specifically executes:

[0240] Acquire posture data corresponding to multiple positions within a preset time period; each posture data corresponds to a timestamp;

[0241] When the processor 1001 obtains the point cloud data and image color data corresponding to the pose data corresponding to the multiple positions, it specifically executes:

[0242] The point cloud data and image color data consistent with the timestamp of each pose data are obtained respectively.

[0243] In some possible embodiments, after acquiring the posture data corresponding to the multiple positions within a preset period of time, the processor 1001 generates a map according to the posture data corresponding to the multiple positions, the point cloud data corresponding to the posture data corresponding to the multiple positions, and the image color data, and is used to perform:

[0244] Converting the pose data corresponding to the multiple positions into multiple pose data generated based on the world coordinate system;

[0245] A map is generated according to the posture data corresponding to the plurality of positions, the point cloud data corresponding to each of the posture data corresponding to the plurality of positions, and the image color data, including:

[0246] A map is generated based on a plurality of pose data generated based on a world coordinate system, point cloud data corresponding to each of the plurality of pose data generated based on the world coordinate system, and image color data.

[0247] In some possible embodiments, when the processor 1001 generates a map according to a plurality of posture data generated based on a world coordinate system, point cloud data corresponding to each of the plurality of posture data generated based on a world coordinate system, and image color data, the processor 1001 specifically executes:

[0248] Generate a motion trajectory within a preset time period according to a plurality of posture data generated based on a world coordinate system;

[0249] Perform loop detection on the motion trajectory;

[0250] If the loop detection result shows that a loop exists, a map is generated based on the point cloud data and image color data corresponding to each of the plurality of posture data generated based on the world coordinate system corresponding to the motion trajectory.

[0251] In some possible embodiments, when the processor 1001 generates a map according to the point cloud data and image color data respectively corresponding to the plurality of posture data generated based on the world coordinate system corresponding to the motion trajectory, the processor 1001 specifically performs:

[0252] Perform nonlinear processing on the motion trajectory to obtain an optimized motion trajectory;

[0253] A map is generated according to the point cloud data and image color data respectively corresponding to a plurality of posture data generated based on a world coordinate system corresponding to the optimized motion trajectory.

[0254] In some possible embodiments, the point cloud data is generated based on a radar coordinate system, and the image color data is generated based on a camera coordinate system, and there are preset conversion parameters between the radar coordinate system and the camera coordinate system;

[0255] When the processor 1001 generates a map according to the point cloud data and image color data respectively corresponding to the plurality of posture data generated based on the world coordinate system corresponding to the optimized motion trajectory, the processor 1001 specifically executes:

[0256] Based on preset conversion parameters, point cloud data and image color data corresponding to multiple posture data generated based on the world coordinate system corresponding to the optimized motion trajectory are converted and processed, and a map is generated based on the converted point cloud data and image color data.

[0257] In some possible embodiments, the processor 1001 converts point cloud data and image color data corresponding to each of the plurality of pose data generated based on the world coordinate system corresponding to the optimized motion trajectory based on preset conversion parameters, and generates a map based on the converted point cloud data and image color data, specifically executing:

[0258] Based on preset conversion parameters, image color data corresponding to a plurality of pose data generated based on a world coordinate system and corresponding to the optimized motion trajectory are converted into image color data generated based on a radar coordinate system;

[0259] A map is generated based on point cloud data corresponding to a plurality of posture data generated based on a world coordinate system and corresponding to the optimized motion trajectory and image color data generated based on a radar coordinate system.

[0260] In some possible embodiments, when the processor 1001 generates a map according to the point cloud data corresponding to each of the plurality of pose data generated based on the world coordinate system corresponding to the optimized motion trajectory and the image color data generated based on the radar coordinate system, the processor 1001 specifically executes:

[0261] Converting point cloud data corresponding to a plurality of pose data generated based on a world coordinate system and image color data generated based on a radar coordinate system, respectively, corresponding to the optimized motion trajectory, into point cloud data generated based on a world coordinate system and image color data generated based on a world coordinate system;

[0262] A map is generated based on the point cloud data generated based on the world coordinate system and the image color data generated based on the world coordinate system.

[0263] In some possible embodiments, the processor 1001 converts the point cloud data and image color data corresponding to each of the plurality of pose data generated based on the world coordinate system corresponding to the optimized motion trajectory based on preset conversion parameters, and generates a map based on the converted point cloud data and image color data, specifically executing:

[0264] Based on preset conversion parameters, point cloud data corresponding to a plurality of pose data generated based on a world coordinate system and corresponding to the optimized motion trajectory are converted into point cloud data generated based on a camera coordinate system;

[0265] A map is generated based on point cloud data generated based on a camera coordinate system and image color data corresponding to a plurality of posture data generated based on a world coordinate system corresponding to the optimized motion trajectory.

[0266] In some possible embodiments, when the processor 1001 generates a map according to the point cloud data generated based on the camera coordinate system and the image color data corresponding to the plurality of pose data generated based on the world coordinate system corresponding to the optimized motion trajectory, the processor 1001 specifically performs:

[0267] Converting point cloud data generated based on the camera coordinate system and image color data corresponding to each of the plurality of pose data generated based on the world coordinate system corresponding to the optimized motion trajectory into point cloud data generated based on the world coordinate system and image color data generated based on the world coordinate system respectively;

[0268] A map is generated based on the point cloud data generated based on the world coordinate system and the image color data generated based on the world coordinate system.

[0269] In some possible embodiments, after performing loop detection on the motion trajectory, the processor 1001 is further configured to execute:

[0270] If the loop detection result is that there is no loop, a map is generated based on the point cloud data and image color data corresponding to each of the plurality of posture data generated based on the world coordinate system.

[0271] In some possible embodiments, the point cloud data is generated based on a radar coordinate system, and the image color data is generated based on a camera coordinate system, and there are preset conversion parameters between the radar coordinate system and the camera coordinate system;

[0272] When the processor 1001 generates a map according to the point cloud data and the image color data corresponding to each of the plurality of posture data generated based on the world coordinate system, the processor 1001 specifically executes:

[0273] Based on preset conversion parameters, point cloud data and image color data corresponding to multiple posture data generated based on the world coordinate system are converted and processed, and a map is generated according to the converted point cloud data and image color data.

[0274] In some possible embodiments, after performing loop detection on the motion trajectory, the processor is further configured to execute:

[0275] If the loop detection result is that there is no loop, then the posture data corresponding to the multiple positions are obtained in the next time period corresponding to the preset time period; each posture data corresponds to a timestamp;

[0276] Converting the pose data corresponding to the multiple positions acquired in the next period into multiple pose data generated based on the world coordinate system;

[0277] A motion trajectory for the next period of time is generated according to a plurality of posture data generated based on a world coordinate system, and a loop detection is performed on the motion trajectory for the next period of time.

[0278] The embodiment of the present application also provides a computer-readable storage medium, in which instructions are stored. When the instructions are executed on a computer or a processor, the computer or the processor executes the above-mentioned Figure 3 or Figure 5 or Figure 7 or Figure 8 One or more steps in the illustrated embodiment. If the components of the electronic device described above are implemented in the form of software functional units and sold or used as independent products, they can be stored in the computer-readable storage medium.

[0279] In the above embodiments, it can be implemented in whole or in part by software, hardware, firmware or any combination thereof. When implemented using software, it can be implemented in whole or in part in the form of a computer program product. The computer program product includes one or more computer instructions. When the computer program instructions are loaded and executed on a computer, the process or function described in the embodiment of the present application is generated in whole or in part. The computer may be a general-purpose computer, a special-purpose computer, a computer network, or other programmable device. The computer instructions may be stored in a computer-readable storage medium or transmitted through the computer-readable storage medium. The computer instructions may be transmitted from a website site, computer, server or data center to another website site, computer, server or data center by wired (e.g., coaxial cable, optical fiber, digital subscriber line (DSL)) or wireless (e.g., infrared, wireless, microwave, etc.) means. The computer-readable storage medium may be any available medium that a computer can access or a data storage device such as a server or data center that includes one or more available media integrated. The available medium may be a magnetic medium (eg, a floppy disk, a hard disk, a magnetic tape), an optical medium (eg, a digital versatile disc (DVD)), or a semiconductor medium (eg, a solid state disk (SSD)), etc.

[0280] Those skilled in the art can understand that all or part of the processes in the above-mentioned embodiments can be implemented by instructing the relevant hardware through a computer program, and the program can be stored in a computer-readable storage medium. When the program is executed, it can include the processes of the embodiments of the above-mentioned methods. The aforementioned storage medium includes: ROM, RAM, magnetic disk or optical disk and other media that can store program codes. In the absence of conflict, the technical features in this embodiment and the implementation scheme can be combined arbitrarily.

[0281] The embodiments described above are merely preferred embodiments of the present application and are not intended to limit the scope of the present application. Without departing from the design spirit of the present application, various modifications and improvements made to the technical solutions of the present application by ordinary technicians in this field should fall within the scope of protection determined by the claims of the present application.

Claims

1. A map generation method, characterized in that: include: Acquire posture data corresponding to a plurality of positions within a preset time period, each of the posture data corresponding to a timestamp; Respectively obtain point cloud data and image color data consistent with the timestamp of each of the pose data, each frame of the point cloud data corresponds to a timestamp, and each frame of the image color data corresponds to a timestamp, the point cloud data is generated based on a radar coordinate system, and the image color data is generated based on a camera coordinate system, and there are preset conversion parameters between the radar coordinate system and the camera coordinate system; Converting the pose data corresponding to the multiple positions into a plurality of pose data generated based on a world coordinate system; Generating a motion trajectory within the preset time period according to the plurality of posture data generated based on the world coordinate system, wherein the generation of the motion trajectory within the preset time period comprises: determining a plurality of coordinate points in the world coordinate system corresponding to the plurality of posture data generated based on the world coordinate system, and generating the motion trajectory within the preset time period in the world coordinate system by connecting adjacent coordinate points based on the plurality of coordinate points; Performing loop detection on the motion trajectory; If the loop detection result is that a loop exists, indicating that the motion trajectory is a loop trajectory, and there are two identical positions in the motion trajectory, then nonlinear processing is performed on the motion trajectory to obtain an optimized motion trajectory, the optimized motion trajectory is smoother than the motion trajectory, and the number of multiple positions corresponding to the optimized motion trajectory is less than or equal to the number of multiple positions corresponding to the motion trajectory; Based on the preset conversion parameters, the point cloud data and image color data corresponding to each of the multiple posture data generated based on the world coordinate system corresponding to the optimized motion trajectory are converted, and a map is generated based on the converted point cloud data and image color data.

2. The method according to claim 1, characterized in that The method of converting the point cloud data and the image color data respectively corresponding to the plurality of pose data generated based on the world coordinate system corresponding to the optimized motion trajectory based on the preset conversion parameters, and generating a map based on the converted point cloud data and the image color data, comprises: Based on the preset conversion parameters, converting the image color data corresponding to each of the plurality of pose data generated based on the world coordinate system and corresponding to the optimized motion trajectory into image color data generated based on the radar coordinate system; A map is generated according to the point cloud data respectively corresponding to the plurality of posture data generated based on the world coordinate system and corresponding to the optimized motion trajectory and the image color data generated based on the radar coordinate system.

3. The method according to claim 2, characterized in that The generating a map according to the point cloud data respectively corresponding to the plurality of posture data generated based on the world coordinate system corresponding to the optimized motion trajectory and the image color data generated based on the radar coordinate system comprises: Convert the point cloud data and the image color data generated based on the radar coordinate system, respectively, corresponding to the plurality of pose data generated based on the world coordinate system and corresponding to the optimized motion trajectory, into the point cloud data and the image color data generated based on the world coordinate system; A map is generated according to the point cloud data generated based on the world coordinate system and the image color data generated based on the world coordinate system.

4. The method according to claim 1, characterized in that The method of converting the point cloud data and the image color data respectively corresponding to the plurality of pose data generated based on the world coordinate system corresponding to the optimized motion trajectory based on the preset conversion parameters, and generating a map based on the converted point cloud data and the image color data, comprises: Based on the preset conversion parameters, the point cloud data corresponding to each of the plurality of pose data generated based on the world coordinate system and corresponding to the optimized motion trajectory are converted into point cloud data generated based on the camera coordinate system; A map is generated according to the point cloud data generated based on the camera coordinate system and the image color data corresponding to each of the plurality of posture data generated based on the world coordinate system corresponding to the optimized motion trajectory.

5. The method according to claim 4, characterized in that The generating a map according to the point cloud data generated based on the camera coordinate system and the image color data corresponding to each of the plurality of pose data generated based on the world coordinate system corresponding to the optimized motion trajectory comprises: Converting the point cloud data generated based on the camera coordinate system and the image color data corresponding to each of the plurality of pose data generated based on the world coordinate system corresponding to the optimized motion trajectory into the point cloud data generated based on the world coordinate system and the image color data generated based on the world coordinate system respectively; A map is generated according to the point cloud data generated based on the world coordinate system and the image color data generated based on the world coordinate system.

6. The method according to claim 1, characterized in that After performing loop detection on the motion trajectory, the method further includes: If the loop detection result is that there is no loop, a map is generated according to the point cloud data and image color data corresponding to each of the plurality of posture data generated based on the world coordinate system.

7. The method according to claim 6, characterized in that The point cloud data is generated based on a radar coordinate system, the image color data is generated based on a camera coordinate system, and there are preset conversion parameters between the radar coordinate system and the camera coordinate system; The generating of a map according to the point cloud data and the image color data respectively corresponding to the plurality of posture data generated based on the world coordinate system comprises: The point cloud data and image color data corresponding to each of the plurality of posture data generated based on the world coordinate system are converted based on the preset conversion parameters, and a map is generated based on the converted point cloud data and image color data.

8. The method according to claim 1, characterized in that After performing loop detection on the motion trajectory, the method further includes: If the loop detection result is that there is no loop, then acquiring posture data corresponding to a plurality of positions in a next time period corresponding to the preset time period; each of the posture data corresponds to a timestamp; Converting the pose data corresponding to the multiple positions acquired in the next period of time into a plurality of pose data generated based on the world coordinate system; The motion trajectory in the next time period is generated according to the multiple posture data generated based on the world coordinate system, and loop detection is performed on the motion trajectory in the next time period.

9. A map generating device, characterized in that: include: An acquisition module, used to acquire posture data corresponding to multiple positions within a preset time period, and respectively acquire point cloud data and image color data consistent with the timestamp of each posture data; each posture data corresponds to a timestamp, each frame of the point cloud data corresponds to a timestamp, and each frame of the image color data corresponds to a timestamp, the point cloud data is generated based on a radar coordinate system, and the image color data is generated based on a camera coordinate system, and there are preset conversion parameters between the radar coordinate system and the camera coordinate system; A second processing module, used for converting the posture data corresponding to the multiple positions into a plurality of posture data generated based on a world coordinate system; A first processing unit is configured to generate a motion trajectory within the preset time period according to the plurality of posture data generated based on the world coordinate system, wherein the generation of the motion trajectory within the preset time period comprises: determining a plurality of coordinate points in the world coordinate system corresponding to the plurality of posture data generated based on the world coordinate system, and generating the motion trajectory within the preset time period in the world coordinate system by connecting adjacent coordinate points based on the plurality of coordinate points; A second processing unit, configured to perform loop detection on the motion trajectory; The third processing unit is used to perform nonlinear processing on the motion trajectory to obtain an optimized motion trajectory if the loop detection result is that a loop exists, indicating that the motion trajectory is a loop trajectory, and there are two identical positions in the motion trajectory, wherein the optimized motion trajectory is smoother than the motion trajectory, and the number of multiple positions corresponding to the optimized motion trajectory is less than or equal to the number of multiple positions corresponding to the motion trajectory; based on the preset conversion parameters, convert the point cloud data and image color data corresponding to the multiple posture data generated based on the world coordinate system corresponding to the optimized motion trajectory, and generate a map based on the converted point cloud data and image color data.

10. An electronic device, characterized in that: including a processor and a memory; The processor is connected to the memory; The memory is used to store executable program code; The processor runs a program corresponding to the executable program code by reading the executable program code stored in the memory, so as to execute the method according to any one of claims 1 to 8.

11. A map generation system, characterized in that: include: A first acquisition unit, used to obtain posture data corresponding to multiple positions within a preset time period, each of the posture data corresponds to a timestamp; A second acquisition unit is used to obtain point cloud data consistent with the timestamp of each of the pose data, each frame of the point cloud data corresponds to a timestamp, and the point cloud data is generated based on a radar coordinate system; A third acquisition unit is used to obtain image color data consistent with the timestamp of each of the pose data, each frame of the image color data corresponds to a timestamp, the image color data is generated based on a camera coordinate system, and there are preset conversion parameters between the radar coordinate system and the camera coordinate system; A processing unit, used for converting the posture data corresponding to the multiple positions into multiple posture data generated based on a world coordinate system; Generate a motion trajectory within the preset time period according to the multiple posture data generated based on the world coordinate system, and generate the motion trajectory within the preset time period including: determining multiple coordinate points in the world coordinate system corresponding to the multiple posture data generated based on the world coordinate system, and generating a motion trajectory within the preset time period in the world coordinate system by connecting adjacent coordinate points based on the multiple coordinate points; performing loop detection on the motion trajectory; if the loop detection result is that a loop exists, indicating that the motion trajectory is a loop trajectory, and there are two identical positions in the motion trajectory, then performing nonlinear processing on the motion trajectory to obtain an optimized motion trajectory, the optimized motion trajectory is smoother than the motion trajectory, and the number of multiple positions corresponding to the optimized motion trajectory is less than or equal to the number of multiple positions corresponding to the motion trajectory; Based on the preset conversion parameters, the point cloud data and image color data corresponding to each of the multiple posture data generated based on the world coordinate system corresponding to the optimized motion trajectory are converted, and a map is generated based on the converted point cloud data and image color data.

12. A map generation system, characterized in that: include: A motor encoder, used to obtain posture data corresponding to multiple positions within a preset time period, each of the posture data corresponds to a timestamp; A laser radar, used to obtain point cloud data consistent with the timestamp of each of the pose data, each frame of the point cloud data corresponds to a timestamp, and the point cloud data is generated based on a radar coordinate system; A camera, used to obtain image color data consistent with the timestamp of each of the pose data, each frame of the image color data corresponds to a timestamp, the image color data is generated based on a camera coordinate system, and there are preset conversion parameters between the radar coordinate system and the camera coordinate system; A processor, configured to convert the posture data corresponding to the plurality of positions into a plurality of posture data generated based on a world coordinate system; Generate a motion trajectory within the preset time period according to the multiple posture data generated based on the world coordinate system, and generate the motion trajectory within the preset time period including: determining multiple coordinate points in the world coordinate system corresponding to the multiple posture data generated based on the world coordinate system, and generating a motion trajectory within the preset time period in the world coordinate system by connecting adjacent coordinate points based on the multiple coordinate points; performing loop detection on the motion trajectory; if the loop detection result is that a loop exists, indicating that the motion trajectory is a loop trajectory, and there are two identical positions in the motion trajectory, then performing nonlinear processing on the motion trajectory to obtain an optimized motion trajectory, the optimized motion trajectory is smoother than the motion trajectory, and the number of multiple positions corresponding to the optimized motion trajectory is less than or equal to the number of multiple positions corresponding to the motion trajectory; Based on the preset conversion parameters, the point cloud data and image color data corresponding to each of the multiple posture data generated based on the world coordinate system corresponding to the optimized motion trajectory are converted, and a map is generated based on the converted point cloud data and image color data.

13. A computer-readable storage medium having a computer program stored thereon, characterized in that: When the computer program is executed by a processor, the method according to any one of claims 1 to 8 is implemented.

Citation Information

Patent Citations

  • RGBD camera large-scale three-dimensional scene construction method and system

    CN110163968A

  • Method and device for generating image information, and electronic equipment

    CN111260781A

  • Map construction method, device and equipment and storage medium

    CN111912417A