WO2022257332A1 - 机器人建图方法、装置、机器人及计算机可读存储介质 - Google Patents

机器人建图方法、装置、机器人及计算机可读存储介质 Download PDF

Info

Publication number
WO2022257332A1
WO2022257332A1 PCT/CN2021/126707 CN2021126707W WO2022257332A1 WO 2022257332 A1 WO2022257332 A1 WO 2022257332A1 CN 2021126707 W CN2021126707 W CN 2021126707W WO 2022257332 A1 WO2022257332 A1 WO 2022257332A1
Authority
WO
WIPO (PCT)
Prior art keywords
robot
map
laser
laser data
laser radar
Prior art date
Application number
PCT/CN2021/126707
Other languages
English (en)
French (fr)
Inventor
谷雨隆
张思民
赵云
Original Assignee
深圳市优必选科技股份有限公司
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by 深圳市优必选科技股份有限公司 filed Critical 深圳市优必选科技股份有限公司
Publication of WO2022257332A1 publication Critical patent/WO2022257332A1/zh

Links

Images

Classifications

    • GPHYSICS
    • G01MEASURING; TESTING
    • G01CMEASURING DISTANCES, LEVELS OR BEARINGS; SURVEYING; NAVIGATION; GYROSCOPIC INSTRUMENTS; PHOTOGRAMMETRY OR VIDEOGRAMMETRY
    • G01C21/00Navigation; Navigational instruments not provided for in groups G01C1/00 - G01C19/00
    • G01C21/26Navigation; Navigational instruments not provided for in groups G01C1/00 - G01C19/00 specially adapted for navigation in a road network
    • G01C21/28Navigation; Navigational instruments not provided for in groups G01C1/00 - G01C19/00 specially adapted for navigation in a road network with correlation of data from several navigational instruments
    • G01C21/30Map- or contour-matching
    • G01C21/32Structuring or formatting of map data
    • GPHYSICS
    • G01MEASURING; TESTING
    • G01CMEASURING DISTANCES, LEVELS OR BEARINGS; SURVEYING; NAVIGATION; GYROSCOPIC INSTRUMENTS; PHOTOGRAMMETRY OR VIDEOGRAMMETRY
    • G01C21/00Navigation; Navigational instruments not provided for in groups G01C1/00 - G01C19/00
    • G01C21/26Navigation; Navigational instruments not provided for in groups G01C1/00 - G01C19/00 specially adapted for navigation in a road network
    • G01C21/34Route searching; Route guidance
    • GPHYSICS
    • G01MEASURING; TESTING
    • G01CMEASURING DISTANCES, LEVELS OR BEARINGS; SURVEYING; NAVIGATION; GYROSCOPIC INSTRUMENTS; PHOTOGRAMMETRY OR VIDEOGRAMMETRY
    • G01C21/00Navigation; Navigational instruments not provided for in groups G01C1/00 - G01C19/00
    • G01C21/38Electronic maps specially adapted for navigation; Updating thereof
    • G01C21/3804Creation or updating of map data
    • GPHYSICS
    • G01MEASURING; TESTING
    • G01CMEASURING DISTANCES, LEVELS OR BEARINGS; SURVEYING; NAVIGATION; GYROSCOPIC INSTRUMENTS; PHOTOGRAMMETRY OR VIDEOGRAMMETRY
    • G01C21/00Navigation; Navigational instruments not provided for in groups G01C1/00 - G01C19/00
    • G01C21/38Electronic maps specially adapted for navigation; Updating thereof
    • G01C21/3804Creation or updating of map data
    • G01C21/3833Creation or updating of map data characterised by the source of data
    • G01C21/3844Data obtained from position sensors only, e.g. from inertial navigation
    • GPHYSICS
    • G01MEASURING; TESTING
    • G01SRADIO DIRECTION-FINDING; RADIO NAVIGATION; DETERMINING DISTANCE OR VELOCITY BY USE OF RADIO WAVES; LOCATING OR PRESENCE-DETECTING BY USE OF THE REFLECTION OR RERADIATION OF RADIO WAVES; ANALOGOUS ARRANGEMENTS USING OTHER WAVES
    • G01S17/00Systems using the reflection or reradiation of electromagnetic waves other than radio waves, e.g. lidar systems
    • G01S17/88Lidar systems specially adapted for specific applications
    • G01S17/89Lidar systems specially adapted for specific applications for mapping or imaging

Definitions

  • the present application belongs to the technical field of robots, and in particular relates to a robot mapping method, device, robot and computer-readable storage medium.
  • Simultaneous localization and mapping (SLAM) technology is an important method for robots to create navigation maps based on laser data, which can provide an important basis for real-time positioning and navigation planning in subsequent navigation of robots.
  • robots generally use SLAM technology to build maps while autonomously exploring unknown areas. That is, they need to solve the two difficulties of map building and exploration at the same time to complete map building, resulting in poor stability of robot map building.
  • Embodiments of the present application provide a robot mapping method, device, robot, and computer-readable storage medium, which can effectively improve the stability of robot mapping.
  • the embodiment of the present application provides a robot mapping method, which is applied to a robot including a first laser radar and a second laser radar, and the position of the first laser radar in the robot is higher than that of the second laser radar. 2.
  • the location of the laser radar in the robot the method may include:
  • the first laser data is the laser data collected by the first laser radar when the robot rotates in the target area
  • the second laser data is the laser data collected by the robot in the target area When the target area rotates, the laser data collected by the second laser radar
  • the third laser data is the laser data collected by the second laser radar when the robot moves to the target position in the initial map
  • the generating the first map corresponding to the first laser radar according to the first laser data may include:
  • the generating the second map corresponding to the second laser radar according to the first laser data and the second laser data may include:
  • the generating the initial map of the target area according to the first map and the second map may include:
  • the first origin being the first map
  • the origin of the corresponding world coordinate system, the second origin is the origin of the world coordinate system corresponding to the second map;
  • the aligned first map and the second map are combined to obtain the initial map of the target area.
  • the method may further include:
  • An inflection point in the first moving path is acquired, and the inflection point is determined as a target position in the initial map.
  • the target location includes multiple, and the method may also include:
  • the robot is controlled to move to each of the target positions.
  • controlling the robot to move to each of the target positions may include:
  • the robot is controlled to move to the target position according to the second moving path.
  • the embodiment of the present application provides a robot mapping device, which is applied to a robot including a first laser radar and a second laser radar, and the position of the first laser radar in the robot is higher than that of the second laser radar.
  • the device may include:
  • the first laser data acquisition module is configured to acquire first laser data and second laser data, the first laser data is the laser data collected by the first laser radar when the robot rotates in the target area, and the first laser data is collected by the first laser radar.
  • the second laser data is the laser data collected by the second laser radar when the robot rotates in the target area;
  • a first map generating module configured to generate a first map corresponding to the first laser radar according to the first laser data
  • a second map generating module configured to generate a second map corresponding to the second laser radar according to the first laser data and the second laser data;
  • an initial map generating module configured to generate an initial map of the target area according to the first map and the second map
  • a third laser data acquisition module configured to acquire third laser data, where the third laser data is the laser data collected by the second laser radar when the robot moves to the target position in the initial map;
  • An initial map updating module configured to update the initial map according to the third laser data to obtain a target map of the target area.
  • the embodiment of the present application provides a robot, including a memory, a processor, and a computer program stored in the memory and operable on the processor, and the computer program is implemented when the processor executes the computer program.
  • an embodiment of the present application provides a computer-readable storage medium, the computer-readable storage medium stores a computer program, and when the computer program is executed by a processor, it implements any one of the above-mentioned first aspects.
  • the robot mapping method when the computer program is executed by a processor, it implements any one of the above-mentioned first aspects.
  • an embodiment of the present application provides a computer program product, which enables the robot to execute the robot mapping method described in any one of the above first aspects when the computer program product is run on a robot.
  • the robot can be controlled to rotate in the target area first, and the first laser data collected by the first laser radar and the second laser data collected by the second laser radar can be obtained, so that the first laser data and the second laser data can be The data generates an initial map of the target area. Then, on the basis of the initial map, the robot can be controlled to move to the target position, and at the same time, the initial map can be updated according to the third laser data collected by the second laser radar at a lower position, so as to refresh the obstacles in the target area to the initial map , to get the target map of the target area.
  • the initial map constructed by combining the first laser data collected by the first laser radar can construct the outline of the target area, reducing the number of target positions to be explored , reduce the difficulty of robot exploration, and can provide stable positioning results, so that when the robot moves to the target position, the second laser radar at a lower position can accurately update the obstacles to the initial map, so as to effectively improve the robot's autonomous mapping. efficiency, stability and robustness.
  • Fig. 1 is a schematic flowchart of a robot mapping method provided by an embodiment of the present application
  • Fig. 2 is a schematic diagram of a scene where the first map and the second map are merged according to an embodiment of the present application;
  • FIG. 3 is a schematic diagram of a scene where a robot moves to a target position provided by an embodiment of the present application
  • Fig. 4 is a schematic structural diagram of a robot mapping device provided by an embodiment of the present application.
  • Fig. 5 is a schematic structural diagram of a robot provided by an embodiment of the present application.
  • the term “if” may be construed, depending on the context, as “when” or “once” or “in response to determining” or “in response to detecting “.
  • the phrase “if determined” or “if [the described condition or event] is detected” may be construed, depending on the context, to mean “once determined” or “in response to the determination” or “once detected [the described condition or event] ]” or “in response to detection of [described condition or event]”.
  • references to "one embodiment” or “some embodiments” or the like in the specification of the present application means that a particular feature, structure, or characteristic described in connection with the embodiment is included in one or more embodiments of the present application.
  • appearances of the phrases “in one embodiment,” “in some embodiments,” “in other embodiments,” “in other embodiments,” etc. in various places in this specification are not necessarily All refer to the same embodiment, but mean “one or more but not all embodiments” unless specifically stated otherwise.
  • the terms “including”, “comprising”, “having” and variations thereof mean “including but not limited to”, unless specifically stated otherwise.
  • the existing autonomous mapping technology mainly solves the exploration problem, such as the boundary exploration method and the global detection method based on rapidly expanding random tree (rapidly exploring random tree, RRT).
  • the boundary exploration method extracts the boundary between the known area and the unknown area in the local grid map based on image segmentation technology, and then controls the robot to move to the boundary area to obtain new environmental information to expand the map creation.
  • the RRT global detection method uses the RRT algorithm to calculate unknown area points. If a point calculated by RRT is in an unknown area, the point is released, and then the cluster center is obtained through the global unknown area point. The obtained cluster center is the robot.
  • the target location to explore That is to say, in the existing robot autonomous mapping, it is more difficult to explore unknown areas, the robot needs to explore more target positions, and the stability of robot mapping is poor, resulting in poor subsequent positioning effect of the robot and affecting user experience.
  • the embodiment of the present application provides a robot mapping method, which can first control the robot to rotate in the target area, and obtain the first laser data collected by the first laser radar and the data collected by the second laser radar.
  • second laser data so that an initial map of the target area can be generated according to the first laser data and the second laser data.
  • the robot can be controlled to move to the target position, and at the same time, the initial map can be updated according to the third laser data collected by the second laser radar at a lower position, so as to refresh the obstacles in the target area to the initial map , to get the target map of the target area.
  • the initial map constructed by combining the first laser data collected by the first laser radar can construct the outline of the target area, effectively reducing the number of targets to be explored.
  • the quantity reduces the exploration difficulty of the robot, and can provide stable positioning results, so that when the robot moves to the target position, the second laser radar at a lower position can accurately update the obstacles to the initial map, which can effectively improve the robot's autonomous mapping capability. Efficiency, stability and robustness, improve user experience, and have strong ease of use and practicality.
  • the target area in this embodiment of the present application may be a closed area such as a room or a ward.
  • the robot provided by the embodiment of the present application may include a first laser radar and a second laser radar, the position of the first laser radar in the robot may be higher than that of the second laser radar in the robot, and the scanning distance of the first laser radar may be Farther than the scanning distance of the second lidar.
  • the first laser radar can be installed at a position about 1.7 meters away from the bottom of the robot
  • the second laser radar can be installed at a position about 1.2 meters away from the bottom of the robot.
  • the first lidar located at a higher position can not be blocked by these movable objects, and because the first lidar has a longer Therefore, according to the first laser data collected by the first laser radar, the overall outline of the target area can be constructed, which can reduce the difficulty of the robot's exploration of the target area, reduce the number of target positions that the robot needs to explore, and improve the robot's autonomous construction. Graph efficiency, stability and robustness.
  • the second laser radar located at a lower position can accurately update these movable objects on the initial map, so that these movable objects can be bypassed when navigating in the target area, which greatly improves the stability of positioning and navigation.
  • FIG. 1 shows a schematic flowchart of a robot mapping method provided by an embodiment of the present application.
  • the robot mapping method can be applied to the above-mentioned robot including the first laser radar and the second laser radar.
  • the robot mapping method may include:
  • the first laser data is the laser data collected by the first laser radar when the robot rotates in the target area
  • the second laser data is the laser data collected by the robot Laser data collected by the second laser radar when the target area rotates.
  • the robot when the robot receives an autonomous mapping instruction, the robot can turn on the automatic mapping mode, and can rotate within the target area, for example, can rotate once in the center of the target area.
  • the robot can acquire the first laser data collected by the first laser radar and the second laser data collected by the second laser radar.
  • the robot can collect laser data according to a preset data collection frequency, that is, a frame of first laser data and a frame of second laser data can be collected at regular time intervals.
  • the specific frequency of data collection can be set according to the actual situation, which is not limited in this embodiment of the present application.
  • the autonomous mapping instruction can be generated based on the user clicking or touching a specific button on the display interface of the robot, or based on the user's voice input of keywords such as "mapping", and can also be sent to the robot by other terminal devices. and many more.
  • the robot can be controlled within the target area Rotate anywhere.
  • the embodiment of the present application can also control the degree of rotation of the robot according to the scanning angle of the lidar, for example, the robot can be controlled to rotate only half a circle or 90 degrees, and so on.
  • the robot can simultaneously locate and build a map through the first laser radar, that is, the robot can obtain the first laser data collected by the first laser radar in real time, and determine the first pose of the robot in real time according to the first laser data , and a first map corresponding to the first lidar can be generated according to the first pose and the first laser data. Since the scanning distance of the first laser radar is relatively long and the first laser radar is at a relatively high position, the first map can basically scan out the entire outline of the target area. Wherein, in the embodiment of the present application, the first pose of the robot can be determined based on the first laser data by any existing method, for example, it can be determined based on any algorithm such as a particle filter algorithm or a Kalman filter algorithm.
  • the robot may construct a second map corresponding to the second laser radar based on the first pose positioned by the first laser radar. That is, the robot can determine the first pose of the robot according to the first laser data, and can generate a second map corresponding to the second laser radar according to the first pose and the second laser data. Since the second laser radar is at a lower position, obstacles such as beds, tables and chairs near the robot can be constructed on the second map.
  • the second laser radar may collect the second laser data of the 10.1 second, that is, the first pose of the robot determined based on the first laser radar is the 10th second. seconds, and the pose required to generate the second map corresponding to the second lidar is the pose of the robot at 10.1 seconds.
  • the robot can combine the odometer and the first pose to determine the second lidar
  • the third pose of the robot when the second laser data is collected that is, the third pose of the robot can be determined according to the odometer difference at these two moments and the first pose.
  • the specific determination manner of the third pose may be any existing determination manner, which is not limited in this embodiment of the present application.
  • the robot can use the difference between the odometer at the 10th second and the 10.1 second, plus the robot’s pose at the 10th second, to get the third pose of the robot at the 10.1 second , that is, to obtain the positioning of the robot when the second laser radar collects the second laser data, so as to generate a second map corresponding to the second laser radar according to the third pose and the second laser data.
  • S104 Generate an initial map of the target area according to the first map and the second map.
  • the robot may acquire the first coordinates of the first origin corresponding to the first map in the pixel coordinate system and the second coordinates of the second origin corresponding to the second map in the pixel coordinate system.
  • the first origin is the origin of the world coordinate system corresponding to the first map
  • the second origin is the origin of the world coordinate system corresponding to the second map.
  • the robot can align the first map and the second map according to the first coordinates and the second coordinates, and can merge the aligned first map and the second map to obtain an initial map of the target area.
  • FIG. 2 which shows a schematic diagram of a scene where the first map and the second map are merged according to an embodiment of the present application.
  • the robot can combine the first map and the second map to obtain an initial map as shown in FIG. 2 .
  • both the first map and the second map can be grid maps, therefore, the initial map can also be grid maps.
  • the origins of the world coordinate system (or physical coordinate system) where the first lidar and the second lidar are located are the same, that is, the first origin corresponding to the first map is the second origin corresponding to the second map.
  • the origins should be coincident, but their origins may be in different positions on the map coordinate system (or pixel coordinate system).
  • the first origin may be (300,200), and the second origin may be (200,100).
  • the robot can translate the obstacle information in the second map through the coincidence relationship between the first origin and the second origin, and can project the information of the obstacle in the second map after translation to the first map to get an initial map of the target area.
  • the initial map of the target area is a rough map.
  • the robot can save and publish the initial map.
  • the robot can also turn on the navigation and mapping mode, that is, it can generate the target position corresponding to the initial map, and control the robot to move to the target position, so as to update the initial map according to the third laser data collected by the second laser radar during the movement of the robot , to get the target map of the target area.
  • the target position is the position that the robot needs to explore.
  • the robot may use a preset path coverage algorithm to determine the first moving path of the robot in the initial map. Then, the robot can obtain an inflection point in the first movement path, and can determine the inflection point as a target position in the initial map.
  • the path coverage algorithm may be any existing path coverage algorithm, which is not specifically limited in this embodiment of the present application.
  • the size of the robot in the initial map and the expansion area of obstacles can be enlarged so that the first moving path will not be very dense, and at the same time It can be far away from obstacles, reduce the number of target positions, and effectively improve the efficiency and robustness of the robot's autonomous mapping.
  • the expanded size of the robot and the expanded area of the obstacle may be specifically determined according to actual conditions, which are not specifically limited in this embodiment of the present application.
  • the robot can use the first laser radar to locate on the initial map, and use the third laser data collected by the second laser radar to update the initial map, so that the second laser Obstacles detected by the radar are registered on the initial map. That is to say, when the robot is moving to any target position, the robot can obtain the fourth laser data collected by the first laser radar, and can determine the second pose of the robot according to the fourth laser data; then, the robot can according to The second pose and the target position determine the second moving path of the robot, so as to control the robot to move to the target position according to the second moving path. At the same time, the robot can acquire the third laser data collected by the second laser radar.
  • the robot needs to explore multiple target positions.
  • the robot can obtain the first distance between each target position and the robot and the distance between each target position The second distance, and according to each first distance and each second distance, determine the movement sequence corresponding to each target position, so that the robot can be controlled to move to each target position sequentially according to the movement sequence.
  • the robot may determine the target position closest to the robot as the first target position, determine the target position closest to the first target position as the second target position, and determine the target position closest to the second target position except the first target position Determine the target position of the third target position as the third target position, determine the target position closest to the third target position except the first target position and the second target position as the fourth target position, and so on until all target positions are obtained
  • the movement sequence is to control the robot to move to each target position in an orderly manner according to the movement sequence. For example, the robot can move to each target position according to the movement sequence shown in FIG. 3 .
  • the robot when the robot navigates to a certain target position, if the target position is not reachable (for example, after the second laser radar refreshes the obstacle, some target positions may coincide with the obstacle), or the movement path cannot be generated (for example, when the target position is blocked by obstacles), the robot can skip the target position and continue to navigate to the next target position until all target positions have been traversed, and a target map containing all ground obstacle information is obtained. At this time, the robot can Save the target map, and return to the initial position of the original rotating map, and end the autonomous map building process.
  • the robot in the process of moving the robot to the target position, can obtain the third laser data collected by the second laser radar at a lower position, and can update the initial map according to the third laser data, so that the second laser radar
  • the scanned obstacles such as beds, tables and chairs are registered on the initial map, and the target map of the target area is obtained, so that the robot can avoid these obstacles when navigating in the target area, which greatly improves the stability of the robot's positioning and navigation.
  • the robot can be controlled to rotate in the target area first, and the first laser data collected by the first laser radar and the second laser data collected by the second laser radar can be obtained, so that the first laser data and the second laser data can be The data generates an initial map of the target area. Then, on the basis of the initial map, the robot is controlled to move to the target point, and at the same time, the initial map is updated according to the third laser data collected by the second laser radar at a lower position, so as to update the obstacles in the target area to the initial map. A target map of the target area.
  • the initial map constructed by combining the first laser data collected by the first laser radar can construct the outline of the target area, which can reduce the number of target points to be explored.
  • the quantity can reduce the exploration difficulty of the robot, and can provide stable positioning results, so that when the robot moves to the target position, the second laser radar at a lower position can accurately update the obstacles to the initial map, so as to effectively improve the autonomous construction of the robot. Graph efficiency, stability and robustness.
  • FIG. 4 shows a structural block diagram of a robot mapping device provided by the embodiment of the present application. For the convenience of description, only the parts related to the embodiment of the present application are shown.
  • the robot mapping device is applied to a robot including a first laser radar and a second laser radar, and the position of the first laser radar in the robot is higher than that of the second laser radar in the position in the robot, the robot mapping device may include:
  • the first laser data acquisition module 401 is configured to acquire first laser data and second laser data, the first laser data is the laser data collected by the first laser radar when the robot rotates in the target area, the The second laser data is the laser data collected by the second laser radar when the robot rotates in the target area;
  • the second map generating module 403 is configured to generate a second map corresponding to the second laser radar according to the first laser data and the second laser data;
  • An initial map generating module 404 configured to generate an initial map of the target area according to the first map and the second map;
  • the third laser data acquisition module 405 is configured to acquire third laser data, where the third laser data is the laser data collected by the second laser radar when the robot moves to the target position in the initial map;
  • An initial map update module 406, configured to update the initial map according to the third laser data to obtain a target map of the target area.
  • the first map generating module 402 may include:
  • a first pose determining unit configured to determine a first pose of the robot according to the first laser data
  • a first map generating unit configured to generate a first map corresponding to the first laser radar according to the first pose and the first laser data.
  • the second map generation module 403 may include:
  • a first pose determining unit configured to determine a first pose of the robot according to the first laser data
  • a second map generating unit configured to generate a second map corresponding to the second laser radar according to the first pose and the second laser data.
  • the initial map generation module 504 may include:
  • a coordinate acquiring unit configured to acquire the first coordinates of the first origin corresponding to the first map in the pixel coordinate system and the second coordinates of the second origin corresponding to the second map in the pixel coordinate system, the first origin is the origin of the world coordinate system corresponding to the first map, and the second origin is the origin of the world coordinate system corresponding to the second map;
  • a map alignment unit configured to align the first map and the second map according to the first coordinates and the second coordinates
  • the initial map generating unit is configured to combine the aligned first map and the second map to obtain the initial map of the target area.
  • the robot mapping device may further include:
  • a first path determination module configured to determine a first movement path of the robot in the initial map by using a preset path coverage algorithm
  • a target position determining module configured to obtain an inflection point in the first moving path, and determine the inflection point as the target position in the initial map.
  • the target location includes multiple, and the device may also include:
  • a distance acquiring module configured to acquire a first distance between each of the target positions and the robot and a second distance between each of the target positions
  • a movement sequence determination module configured to determine a movement sequence corresponding to each of the target positions according to each of the first distances and each of the second distances;
  • a moving module configured to control the robot to move to each of the target positions according to the moving sequence.
  • the mobile module may include:
  • a second pose determining unit configured to acquire fourth laser data collected by the first laser radar, and determine a second pose of the robot according to the fourth laser data;
  • a first path determination unit configured to determine a second movement path of the robot according to the second pose and the target position
  • a moving unit configured to control the robot to move to the target position according to the second moving path.
  • Fig. 5 is a schematic structural diagram of a robot provided by an embodiment of the present application.
  • the robot 5 of this embodiment includes: at least one processor 50 (only one is shown in Figure 5 ), a memory 51, stored in the memory 51 and available on the at least one processor 50
  • the robot may include, but not limited to, a processor 50 and a memory 51 .
  • a processor 50 and a memory 51 .
  • Fig. 5 is only an example of the robot 5, and does not constitute a limitation to the robot 5, and may include more or less components than those shown in the illustration, or combine certain components, or different components, for example It may also include input and output devices, network access devices, etc.
  • processor 50 can be central processing unit (central processing unit, CPU), and this processor 50 can also be other general processors, digital signal processor (digital signal processor, DSP), application specific integrated circuit (application specific integrated circuit) , ASIC), field-programmable gate array (field-programmable gate array, FPGA) or other programmable logic devices, discrete gate or transistor logic devices, discrete hardware components, etc.
  • DSP digital signal processor
  • ASIC application specific integrated circuit
  • FPGA field-programmable gate array
  • a general-purpose processor may be a microprocessor, or the processor may be any conventional processor, and the like.
  • the memory 51 may be an internal storage unit of the robot 5 in some embodiments, such as a hard disk or memory of the robot 5 .
  • the memory 51 can also be an external storage device of the robot 5 in other embodiments, such as a plug-in hard disk equipped on the robot 5, a smart media card (smart media card, SMC), a secure digital (secure digital, SD) card, flash card (flash card), etc.
  • the memory 51 may also include both an internal storage unit of the robot 5 and an external storage device.
  • the memory 51 is used to store operating systems, application programs, boot loaders (BootLoader), data, and other programs, such as program codes of the computer programs.
  • the memory 51 can also be used to temporarily store data that has been output or will be output.
  • the embodiment of the present application also provides a computer-readable storage medium, the computer-readable storage medium stores a computer program, and when the computer program is executed by a processor, the steps in the above-mentioned embodiments of the robot mapping method can be realized.
  • An embodiment of the present application provides a computer program product.
  • the robot can implement the steps in the above-mentioned embodiments of the robot mapping method.
  • the integrated unit is realized in the form of a software function unit and sold or used as an independent product, it can be stored in a computer-readable storage medium. Based on this understanding, all or part of the procedures in the methods of the above embodiments in the present application can be completed by instructing related hardware through computer programs, and the computer programs can be stored in a computer-readable storage medium.
  • the computer program When executed by a processor, the steps in the above-mentioned various method embodiments can be realized.
  • the computer program includes computer program code, and the computer program code may be in the form of source code, object code, executable file or some intermediate form.
  • the computer-readable storage medium may at least include: any entity or device capable of carrying computer program codes to a device/robot, a recording medium, a computer memory, a read-only memory (ROM, ROM), a random access memory (random access memory, RAM,), electrical carrier signals, telecommunication signals, and software distribution media.
  • ROM read-only memory
  • RAM random access memory
  • electrical carrier signals telecommunication signals
  • software distribution media Such as U disk, mobile hard disk, magnetic disk or optical disk, etc.
  • computer readable storage media may not be electrical carrier signals and telecommunication signals based on legislation and patent practice.
  • the disclosed devices/robots and methods may be implemented in other ways.
  • the device/robot embodiments described above are only illustrative.
  • the division of the modules or units is only a logical function division.
  • the mutual coupling or direct coupling or communication connection shown or discussed may be through some interfaces, and the indirect coupling or communication connection of devices or units may be in electrical, mechanical or other forms.
  • the units described as separate components may or may not be physically separated, and the components shown as units may or may not be physical units, that is, they may be located in one place, or may be distributed to multiple network units. Part or all of the units can be selected according to actual needs to achieve the purpose of the solution of this embodiment.

Landscapes

  • Engineering & Computer Science (AREA)
  • Radar, Positioning & Navigation (AREA)
  • Remote Sensing (AREA)
  • Physics & Mathematics (AREA)
  • General Physics & Mathematics (AREA)
  • Automation & Control Theory (AREA)
  • Computer Networks & Wireless Communication (AREA)
  • Electromagnetism (AREA)
  • Control Of Position, Course, Altitude, Or Attitude Of Moving Bodies (AREA)

Abstract

一种机器人建图方法、装置、机器人及计算机可读存储介质。该方法获取第一激光数据和第二激光数据,第一激光数据为机器人在目标区域旋转时,第一激光雷达采集的激光数据,第二激光数据为机器人在目标区域旋转时,第二激光雷达采集的激光数据(S101);根据第一激光数据,生成第一激光雷达对应的第一地图(S102);根据第一激光数据和第二激光数据,生成第二激光雷达对应的第二地图(S103);根据第一地图和第二地图,生成目标区域的初始地图(S104);获取第三激光数据,第三激光数据为机器人向初始地图中的目标位置移动时,第二激光雷达采集的激光数据(S105);根据第三激光数据更新初始地图,得到目标区域的目标地图(S106)。

Description

机器人建图方法、装置、机器人及计算机可读存储介质
本申请要求于2021年06月09日在中国专利局提交的、申请号为202110645968.X的中国专利申请的优先权,其全部内容通过引用结合在本申请中。
技术领域
本申请属于机器人技术领域,尤其涉及一种机器人建图方法、装置、机器人及计算机可读存储介质。
背景技术
同时定位与建图(simultaneous localization and mapping,SLAM)技术是机器人根据激光数据创建导航地图的重要方法,可以为机器人后续导航中的实时定位和导航规划提供重要基础。目前,机器人一般是通过SLAM技术一边建图一边自主探索未知区域,即需要同时解决建图和探索两大难点才可以完成建图,导致机器人建图的稳定性较差。
技术问题
本申请实施例提供了一种机器人建图方法、装置、机器人及计算机可读存储介质,可以有效提高机器人建图的稳定性。
技术解决方案
第一方面,本申请实施例提供了一种机器人建图方法,应用于包含第一激光雷达和第二激光雷达的机器人,所述第一激光雷达在所述机器人中的位置高于所述第二激光雷达在所述机器人中的位置,所述方法可以包括:
获取第一激光数据和第二激光数据,所述第一激光数据为所述机器人在目标区域旋转时,所述第一激光雷达采集的激光数据,所述第二激光数据为所述机器人在所述目标区域旋转时,所述第二激光雷达采集的激光数据;
根据所述第一激光数据,生成所述第一激光雷达对应的第一地图;
根据所述第一激光数据和所述第二激光数据,生成所述第二激光雷达对应的第二地图;
根据所述第一地图和所述第二地图,生成所述目标区域的初始地图;
获取第三激光数据,所述第三激光数据为所述机器人向所述初始地图中的目标位置移动时,所述第二激光雷达采集的激光数据;
根据所述第三激光数据更新所述初始地图,得到所述目标区域的目标地图。
示例性的,所述根据所述第一激光数据,生成所述第一激光雷达对应的第一地图,可以包括:
根据所述第一激光数据确定所述机器人的第一位姿;
根据所述第一位姿和所述第一激光数据,生成所述第一激光雷达对应的第一地图。
示例性的,所述根据所述第一激光数据和所述第二激光数据,生成所述第二激光雷达对应的第二地图,可以包括:
根据所述第一激光数据确定所述机器人的第一位姿;
根据所述第一位姿和所述第二激光数据,生成所述第二激光雷达对应的第二地图。
在第一方面的一种可能的实现方式中,所述根据所述第一地图和所述第二地图,生成所述目标区域的初始地图,可以包括:
获取所述第一地图对应的第一原点在像素坐标系的第一坐标和所述第二地图对应的第二原点在像素坐标系的第二坐标,所述第一原点为所述第一地图对应的世界坐标系的原点,所述第二原点为所述第二地图对应的世界坐标系的原点;
根据所述第一坐标和所述第二坐标,对齐所述第一地图和所述第二地图;
将对齐后的第一地图和第二地图进行合并,得到所述目标区域的初始地图。
在第一方面的一种可能的实现方式中,所述方法还可以包括:
利用预设的路径覆盖算法确定所述机器人在所述初始地图中的第一移动路径;
获取所述第一移动路径中的拐点,并将所述拐点确定为所述初始地图中的目标位置。
可选地,所述目标位置包括多个,所述方法还可以包括:
获取各所述目标位置与所述机器人之间的第一距离以及各所述目标位置之间的第二距离;
根据各所述第一距离和各所述第二距离,确定各所述目标位置对应的移动顺序;
根据所述移动顺序,控制所述机器人向各所述目标位置移动。
具体地,所述控制所述机器人向各所述目标位置移动,可以包括:
获取所述第一激光雷达采集的第四激光数据,并根据所述第四激光数据确定所述机器人的第二位姿;
根据所述第二位姿和所述目标位置,确定所述机器人的第二移动路径;
根据所述第二移动路径,控制所述机器人向所述目标位置移动。
第二方面,本申请实施例提供了一种机器人建图装置,应用于包含第一激光雷达和第二激光雷达的机器人,所述第一激光雷达在所述机器人中的位置高于所述第二激光雷达在所述机器人中的位置,所述装置可以包括:
第一激光数据获取模块,用于获取第一激光数据和第二激光数据,所述第一激光数据为所述机器人在目标区域旋转时,所述第一激光雷达采集的激光数据,所述第二激光数据为所述机器人在所述目标区域旋转时,所述第二激光雷达采集的激光数据;
第一地图生成模块,用于根据所述第一激光数据,生成所述第一激光雷达对应的第一地图;
第二地图生成模块,用于根据所述第一激光数据和所述第二激光数据,生成所述第二激光雷达对应的第二地图;
初始地图生成模块,用于根据所述第一地图和所述第二地图,生成所述目标区域的初始地图;
第三激光数据获取模块,用于获取第三激光数据,所述第三激光数据为所述机器人向所述初始地图中的目标位置移动时,所述第二激光雷达采集的激光数据;
初始地图更新模块,用于根据所述第三激光数据更新所述初始地图,得到所述目标区域的目标地图。
第三方面,本申请实施例提供了一种机器人,包括存储器、处理器以及存储在所述存储器中并可在所述处理器上运行的计算机程序,所述处理器执行所述计算机程序时实现上述第一方面中任一项所述的机器人建图方法。
第四方面,本申请实施例提供了一种计算机可读存储介质,所述计算机可读存储介质存储有计算机程序,所述计算机程序被处理器执行时实现上述第一方面中任一项所述的机器人建图方法。
第五方面,本申请实施例提供了一种计算机程序产品,当计算机程序产品在机器人上运行时,使得机器人执行上述第一方面中任一项所述的机器人建图方法。
有益效果
本申请实施例与现有技术相比存在的有益效果是:
本申请实施例中,可以先控制机器人在目标区域旋转,并获取第一激光雷达采集的第一激光数据和第二激光雷达采集的第二激光数据,从而可以根据第一激光数据和第二激光数据生成目标区域的初始地图。然后,在初始地图的基础上可以控制机器人向目标位置移动,并可以同时根据较低位置的第二激光雷达采集的第三激光数据更新初始地图,以将目标区域内的障碍物刷新至初始地图,得到目标区域的目标地图。由于第一激光雷达的位置较高,可以不受障碍物遮挡,因此结合第一激光雷达采集的第一激光数据构建的初始地图 可以把目标区域的轮廓构建出来,减少待探索的目标位置的数量,降低机器人的探索难度,并且可以提供稳定的定位结果,从而使得机器人向目标位置移动时,较低位置的第二激光雷达可以将障碍物准确刷新至初始地图上,以有效提高机器人自主建图的效率、稳定性和鲁棒性。
附图说明
为了更清楚地说明本申请实施例中的技术方案,下面将对实施例或现有技术描述中所需要使用的附图作简单地介绍,显而易见地,下面描述中的附图仅仅是本申请的一些实施例,对于本领域普通技术人员来讲,在不付出创造性劳动的前提下,还可以根据这些附图获得其他的附图。
图1是本申请一实施例提供的机器人建图方法的流程示意图;
图2是本申请一实施例提供的第一地图与第二地图合并的场景示意图;
图3是本申请一实施例提供的机器人向目标位置移动的场景示意图;
图4是本申请一实施例提供的机器人建图装置的结构示意图;
图5是本申请一实施例提供的机器人的结构示意图。
本发明的实施方式
以下描述中,为了说明而不是为了限定,提出了诸如特定系统结构、技术之类的具体细节,以便透彻理解本申请实施例。然而,本领域的技术人员应当清楚,在没有这些具体细节的其它实施例中也可以实现本申请。在其它情况中,省略对众所周知的系统、装置、电路以及方法的详细说明,以免不必要的细节妨碍本申请的描述。
应当理解,当在本申请说明书和所附权利要求书中使用时,术语“包括”指示所描述特征、整体、步骤、操作、元素和/或组件的存在,但并不排除一个或多个其它特征、整体、步骤、操作、元素、组件和/或其集合的存在或添加。
还应当理解,在本申请说明书和所附权利要求书中使用的术语“和/或”是指相关联列出的项中的一个或多个的任何组合以及所有可能组合,并且包括这些组合。
如在本申请说明书和所附权利要求书中所使用的那样,术语“如果”可以依据上下文被解释为“当...时”或“一旦”或“响应于确定”或“响应于检测到”。类似地,短语“如果确定”或“如果检测到[所描述条件或事件]”可以依据上下文被解释为意指“一旦确定”或“响应于确定”或“一旦检测到[所描述条件或事件]”或“响应于检测到[所描述条件或事件]”。
另外,在本申请说明书和所附权利要求书的描述中,术语“第一”、“第二”、“第三”等仅用于区分描述,而不能理解为指示或暗示相对重要性。
在本申请说明书中描述的参考“一个实施例”或“一些实施例”等意味着在本申请的一个或多个实施例中包括结合该实施例描述的特定特征、结构或特点。由此,在本说明书中的不同之处出现的语句“在一个实施例中”、“在一些实施例中”、“在其他一些实施例中”、“在另外一些实施例中”等不是必然都参考相同的实施例,而是意味着“一个或多个但不是所有的实施例”,除非是以其他方式另外特别强调。术语“包括”、“包含”、“具有”及它们的变形都意味着“包括但不限于”,除非是以其他方式另外特别强调。
在防疫消杀机器人或者扫地机器人等领域,都需要让机器人在房间内自主建图,以根据所构建的地图进行实时定位和导航规划,来完成相应的消杀或者清扫等任务。其中,传统的机器人都是单激光雷达,机器人可以通过SLAM技术一边建图一边自主探索未知区域,这需要同时解决建图和探索这两个难点才可以完成建图。
现有的自主建图技术主要解决的是探索问题,例如边界探索法和基于快速扩展随机树(rapidly exploring random tree,RRT)的全局检测法。边界探索法基于图像分割技术提取局部栅格地图中已知区域和未知区域之间的边界,然后控制机器人向边界区域运动,以获取新环境信息,来扩大地图创建。RRT全局检测法是利用RRT算法计算未知区域点, 如果RRT计算的某点在未知区域则将该点发布出去,再通过全局的未知区域点获取聚类中心,所获取的聚类中心即为机器人要去探索的目标位置。即现有的机器人自主建图中,未知区域的探索难度较大,机器人需要探索的目标位置较多,机器人建图的稳定性较差,导致机器人后续的定位效果较差,影响用户体验。
为了解决上述技术问题,本申请实施例提供了一种机器人建图方法,该方法可以先控制机器人在目标区域内旋转,并获取第一激光雷达采集的第一激光数据和第二激光雷达采集的第二激光数据,从而可以根据第一激光数据和第二激光数据生成目标区域的初始地图。然后,在初始地图的基础上可以控制机器人向目标位置移动,并可以同时根据较低位置的第二激光雷达采集的第三激光数据更新初始地图,以将目标区域内的障碍物刷新至初始地图,得到目标区域的目标地图。由于第一激光雷达的位置较高,可以不受障碍物遮挡,因此结合第一激光雷达采集的第一激光数据构建的初始地图可以把目标区域的轮廓构建出来,有效减少待探索的目标位置的数量,降低机器人的探索难度,并可以提供稳定的定位结果,使得机器人向目标位置移动时,较低位置的第二激光雷达可以将障碍物准确刷新至初始地图,可以有效提高机器人自主建图的效率、稳定性和鲁棒性,提高用户体验,具有较强的易用性和实用性。
应理解,本申请实施例中的目标区域可以为房间、病房等封闭区域。
本申请实施例提供的机器人可以包括第一激光雷达和第二激光雷达,第一激光雷达在机器人中的位置可以高于第二激光雷达在机器人中的位置,且第一激光雷达的扫描距离可远于第二激光雷达的扫描距离。例如,第一激光雷达可以安装于距离机器人的底部1.7米左右的位置,第二激光雷达可以安装于距离机器人的底部1.2米左右的位置。由于目标区域中的床、桌椅等可移动物体通常是在1.5米以下,即位于较高位置的第一激光雷达可以不受这些可移动物体的遮挡,且由于第一激光雷达具有较长的扫描距离,因此根据第一激光雷达采集的第一激光数据可以将目标区域的整体轮廓构建出来,从而可以减少机器人对目标区域的探索难度,减少机器人需要探索的目标位置的数量,提高机器人自主建图的效率、稳定性和鲁棒性。而位于较低位置的第二激光雷达可以准确地将这些可移动物体更新至初始地图上,以使得在目标区域进行导航时能绕开这些可移动物体,极大提高了定位导航的稳定性。
请参阅图1,图1示出了本申请实施例提供的机器人建图方法的示意性流程图。所述机器人建图方法可以应用于上述所述的包括第一激光雷达和第二激光雷达的机器人。如图1所示,所述机器人建图方法可以包括:
S101、获取第一激光数据和第二激光数据,所述第一激光数据为所述机器人在目标区域旋转时,所述第一激光雷达采集的激光数据,所述第二激光数据为所述机器人在所述目标区域旋转时,所述第二激光雷达采集的激光数据。
本申请实施例中,当机器人接收到自主建图指令时,机器人可以开启自动建图模式,并可以在目标区域内旋转,例如,可以在目标区域的中央位置旋转一圈。在旋转过程中,机器人可以获取第一激光雷达采集的第一激光数据和第二激光雷达采集的第二激光数据。可选地,机器人可以按照预先设定的数据采集频率来进行激光数据的采集,即可以每隔一定的时间间隔采集一帧第一激光数据和一帧第二激光数据。具体的数据采集频率可以根据实际情况设置,本申请实施例对此不作限定。
应理解,所述自主建图指令可以基于用户点击或者触摸机器人显示界面中的特定按钮生成,也可以基于用户语音输入“建图”等关键词生成,还可以为其他终端设备向机器人发送的,等等。
需要说明的是,上述所述的“在目标区域的中央位置旋转一圈”仅作示意性解释,不应理解为对本申请实施例的限制,本申请实施例中,可以控制机器人在目标区域内的任意位置旋转。同时,本申请实施例也可以根据激光雷达所具有的扫描角度,来控制机器人的旋转程度,例如可以控制机器人仅旋转半圈或者旋转90度,等等。
S102、根据所述第一激光数据,生成所述第一激光雷达对应的第一地图。
本申请实施例中,机器人可以通过第一激光雷达进行同时定位与建图,即机器人可以实时获取第一激光雷达采集的第一激光数据,并根据第一激光数据实时确定机器人的第一位姿,并可以根据第一位姿和第一激光数据,生成第一激光雷达对应的第一地图。由于第一激光雷达的扫描距离较长,且第一激光雷达处于较高的位置,因此,第一地图基本上可以把目标区域的整个轮廓扫描出来。其中,本申请实施例中可以通过现有的任一方式来基于第一激光数据确定机器人的第一位姿,例如可以基于粒子滤波算法或者卡尔曼滤波算法等任一算法来确定。
S103、根据所述第一激光数据和所述第二激光数据,生成所述第二激光雷达对应的第二地图。
具体地,机器人可以以第一激光雷达定位的第一位姿为基准,来构建第二激光雷达对应的第二地图。即机器人可以根据第一激光数据确定机器人的第一位姿,并可以根据第一位姿和第二激光数据,生成第二激光雷达对应的第二地图。由于第二激光雷达处于较低的位置,因此第二地图上可以将机器人附近的床、桌椅等障碍物构建出来。
需要说明的是,由于第一激光雷达和第二激光雷达的时间不同步,因此第一激光雷达和第二激光雷达进行激光数据采集时,也会存在不同步的问题。例如,在第一激光雷达采集第10秒的第一激光数据时,第二激光雷达可能采集第10.1秒的第二激光数据,即基于第一激光雷达确定的机器人的第一位姿为第10秒的位姿,而生成第二激光雷达对应的第二地图所需要的位姿为机器人处于第10.1秒的位姿,此时,机器人可以结合里程计和第一位姿来确定第二激光雷达采集第二激光数据时机器人的第三位姿,即可以根据这两时刻的里程计差和第一位姿来确定机器人的第三位姿。第三位姿的具体确定方式可以为现有的任一确定方式,本申请实施例对此不作限定。
例如,在第一激光雷达采集的第一激光数据为第10秒的激光数据,第二激光雷达采集的第二激光数据为第10.1秒的激光数据时,基于第一激光雷达得到的机器人的定位是第10秒的,此时机器人可以通过里程计在第10秒和第10.1秒之间的差,再加上机器人在第10秒的位姿,来得到第10.1秒时机器人的第三位姿,即获得第二激光雷达采集第二激光数据时机器人的定位,以根据第三位姿和第二激光数据,生成第二激光雷达对应的第二地图。
S104、根据所述第一地图和所述第二地图,生成所述目标区域的初始地图。
可选地,机器人可以获取第一地图对应的第一原点在像素坐标系的第一坐标和第二地图对应的第二原点在像素坐标系的第二坐标。其中,第一原点为第一地图对应的世界坐标系的原点,第二原点为第二地图对应的世界坐标系的原点。然后,机器人可以根据第一坐标和第二坐标,对齐第一地图和第二地图,并可以将对齐后的第一地图和第二地图进行合并,以此得到目标区域的初始地图。例如,请参阅图2,图2示出了本申请实施例提供的第一地图与第二地图合并的场景示意图。如图2所示,机器人可以将第一地图和第二地图合并得到如图2所示的初始地图。
可以理解的是,第一地图和第二地图均可以为栅格地图,因此,初始地图也可以为栅格地图。在建图过程中,第一激光雷达和第二激光雷达所在的世界坐标系(或者称物理坐标系)的原点是一样的,即第一地图对应的第一原点与第二地图对应的第二原点应该是重合的,但在地图坐标系(或者称像素坐标系)上他们的原点可能分别在不同的位置,例如,第一原点可能为(300,200),第二原点可能为(200,100)。此时,机器人可以通过第一原点与第二原点之间的重合关系对第二地图中障碍物的信息进行平移,并可以将平移后的第二地图中的障碍物的信息投射到第一地图上,以得到目标区域的初始地图。其中,横轴的平移距离x和纵轴的平移距离y可以根据第一原点对应的第一坐标和第二原点对应的第二坐标来确定。例如,在第一原点为(300,200),第二原点为(200,100)时,横轴的平移距离x可以根据x:300-200=100来确定,纵轴的平移距离y可以根据y:200-100 =100来确定。
S105、获取第三激光数据,所述第三激光数据为所述机器人向所述初始地图中的目标位置移动时,所述第二激光雷达采集的激光数据。
本申请实施例中,目标区域的初始地图为一个粗略地图,为提高机器人所构建的地图的准确性,在生成初始地图后,机器人可以保存并发布该初始地图。同时,机器人还可以开启导航建图模式,即可以生成该初始地图对应的目标位置,并控制机器人向目标位置移动,以根据机器人移动过程中,第二激光雷达采集的第三激光数据更新初始地图,得到目标区域的目标地图。其中,目标位置为机器人需要去探索的位置。
具体地,机器人可以利用预设的路径覆盖算法确定机器人在初始地图中的第一移动路径。然后,机器人可以获取第一移动路径中的拐点,并可以将拐点确定为初始地图中的目标位置。其中,路径覆盖算法可以为现有的任一路径覆盖算法,本申请实施例对此不作具体限定。在利用预设的路径覆盖算法确定机器人在初始地图中的第一移动路径时,可以扩大机器人在初始地图中的大小以及扩大障碍物的膨胀面积,使得第一移动路径不会很密集,同时也可以离障碍物较远,减少目标位置的数量,有效提高机器人自主建图的效率和鲁棒性。在此,机器人的扩大大小和障碍物的膨胀面积可以根据实际情况具体确定,本申请实施例对此不作具体限定。
可以理解的是,在导航建图模式中,机器人可以使用第一激光雷达在初始地图上进行定位,并使用第二激光雷达采集的第三激光数据来进行初始地图的更新,以将第二激光雷达扫描到的障碍物注册到初始地图上。也就是说,在机器人向任一目标位置移动的过程中,机器人可以获取第一激光雷达采集的第四激光数据,并可以根据第四激光数据确定机器人的第二位姿;然后,机器人可以根据第二位姿和该目标位置,确定机器人的第二移动路径,以控制机器人根据第二移动路径向该目标位置移动,与此同时,机器人可以获取第二激光雷达采集的第三激光数据。
在一种可能的实现方式中,机器人需要探索的目标位置可以包括多个,此时为提高机器人的探索效率,机器人可以获取各目标位置与机器人之间的第一距离以及各目标位置之间的第二距离,并根据各第一距离和各第二距离,确定各目标位置对应的移动顺序,从而可以根据移动顺序,控制机器人依次向各目标位置移动。
例如,机器人可以将距离机器人最近的目标位置确定为第一目标位置,将距离第一目标位置最近的目标位置确定为第二目标位置,将距离第二目标位置最近的除第一目标位置之外的目标位置确定为第三目标位置,将距离第三目标位置最近的除第一目标位置、第二目标位置之外的目标位置确定为第四目标位置,以此类推,直至得到所有目标位置的移动顺序,以根据移动顺序控制机器人有序地向各目标位置移动,例如,机器人可以根据图3所示的移动顺序向各目标位置移动。
需要说明的是,在机器人导航至某一目标位置时,若该目标位置不可达(例如在第二激光雷达刷新障碍物后,有的目标位置可能和障碍物重合),或者移动路径无法生成(例如目标位置被障碍物挡住时),机器人则可以略过该目标位置并继续导航至下一目标位置,直至所有的目标位置遍历完毕,得到包含所有地面障碍物信息的目标地图,此时机器人可以保存目标地图,并回到最初旋转建图的初始位置,结束自主建图过程。
S106、根据所述第三激光数据更新所述初始地图,得到所述目标区域的目标地图。
可以理解的是,在机器人向目标位置移动的过程中,机器人可以获取较低位置的第二激光雷达采集的第三激光数据,并可以根据第三激光数据更新初始地图,以将第二激光雷达扫描到的床、桌椅等障碍物注册到初始地图上,得到目标区域的目标地图,从而使得机器人在目标区域内导航时可以绕开这些障碍物,极大提高了机器人定位导航的稳定性。
本申请实施例中,可以先控制机器人在目标区域旋转,并获取第一激光雷达采集的第一激光数据和第二激光雷达采集的第二激光数据,从而可以根据第一激光数据和第二激光数据生成目标区域的初始地图。然后,在初始地图的基础上控制机器人向目标点移动,并 同时根据较低位置的第二激光雷达采集的第三激光数据更新初始地图,以将目标区域内的障碍物刷新至初始地图,得到目标区域的目标地图。由于第一激光雷达的位置较高,可以不受障碍物遮挡,因此结合第一激光雷达采集的第一激光数据构建的初始地图可以把目标区域的轮廓构建出来,可以减少待探索的目标点的数量,降低机器人的探索难度,并且可以提供稳定的定位结果,使得在机器人向目标位置移动时,较低位置的第二激光雷达可以将障碍物准确刷新至初始地图上,以有效提高机器人自主建图的效率、稳定性和鲁棒性。
应理解,上述实施例中各步骤的序号的大小并不意味着执行顺序的先后,各过程的执行顺序应以其功能和内在逻辑确定,而不应对本申请实施例的实施过程构成任何限定。
对应于上文实施例所述的机器人建图方法,图4示出了本申请实施例提供的机器人建图装置的结构框图,为了便于说明,仅示出了与本申请实施例相关的部分。
参照图4,所述机器人建图装置,应用于包含第一激光雷达和第二激光雷达的机器人,所述第一激光雷达在所述机器人中的位置高于所述第二激光雷达在所述机器人中的位置,所述机器人建图装置可以包括:
第一激光数据获取模块401,用于获取第一激光数据和第二激光数据,所述第一激光数据为所述机器人在目标区域旋转时,所述第一激光雷达采集的激光数据,所述第二激光数据为所述机器人在所述目标区域旋转时,所述第二激光雷达采集的激光数据;
第一地图生成模块402,用于根据所述第一激光数据,生成所述第一激光雷达对应的第一地图;
第二地图生成模块403,用于根据所述第一激光数据和所述第二激光数据,生成所述第二激光雷达对应的第二地图;
初始地图生成模块404,用于根据所述第一地图和所述第二地图,生成所述目标区域的初始地图;
第三激光数据获取模块405,用于获取第三激光数据,所述第三激光数据为所述机器人向所述初始地图中的目标位置移动时,所述第二激光雷达采集的激光数据;
初始地图更新模块406,用于根据所述第三激光数据更新所述初始地图,得到所述目标区域的目标地图。
示例性的,所述第一地图生成模块402,可以包括:
第一位姿确定单元,用于根据所述第一激光数据确定所述机器人的第一位姿;
第一地图生成单元,用于根据所述第一位姿和所述第一激光数据,生成所述第一激光雷达对应的第一地图。
示例性的,所述第二地图生成模块403,可以包括:
第一位姿确定单元,用于根据所述第一激光数据确定所述机器人的第一位姿;
第二地图生成单元,用于根据所述第一位姿和所述第二激光数据,生成所述第二激光雷达对应的第二地图。
在一种可能的实现方式中,所述初始地图生成模块504,可以包括:
坐标获取单元,用于获取所述第一地图对应的第一原点在像素坐标系的第一坐标和所述第二地图对应的第二原点在像素坐标系的第二坐标,所述第一原点为所述第一地图对应的世界坐标系的原点,所述第二原点为所述第二地图对应的世界坐标系的原点;
地图对齐单元,用于根据所述第一坐标和所述第二坐标,对齐所述第一地图和所述第二地图;
初始地图生成单元,用于将对齐后的第一地图和第二地图进行合并,得到所述目标区域的初始地图。
在一种可能的实现方式中,所述机器人建图装置还可以包括:
第一路径确定模块,用于利用预设的路径覆盖算法确定所述机器人在所述初始地图中的第一移动路径;
目标位置确定模块,用于获取所述第一移动路径中的拐点,并将所述拐点确定为所述 初始地图中的目标位置。
可选地,所述目标位置包括多个,所述装置还可以包括:
距离获取模块,用于获取各所述目标位置与所述机器人之间的第一距离以及各所述目标位置之间的第二距离;
移动顺序确定模块,用于根据各所述第一距离和各所述第二距离,确定各所述目标位置对应的移动顺序;
移动模块,用于根据所述移动顺序,控制所述机器人向各所述目标位置移动。
具体地,所述移动模块,可以包括:
第二位姿确定单元,用于获取所述第一激光雷达采集的第四激光数据,并根据所述第四激光数据确定所述机器人的第二位姿;
第一路径确定单元,用于根据所述第二位姿和所述目标位置,确定所述机器人的第二移动路径;
移动单元,用于根据所述第二移动路径,控制所述机器人向所述目标位置移动。
需要说明的是,上述装置/单元之间的信息交互、执行过程等内容,由于与本申请方法实施例基于同一构思,其具体功能及带来的技术效果,具体可参见方法实施例部分,此处不再赘述。
所属领域的技术人员可以清楚地了解到,为了描述的方便和简洁,仅以上述各功能单元、模块的划分进行举例说明,实际应用中,可以根据需要而将上述功能分配由不同的功能单元、模块完成,即将所述装置的内部结构划分成不同的功能单元或模块,以完成以上描述的全部或者部分功能。实施例中的各功能单元、模块可以集成在一个处理单元中,也可以是各个单元单独物理存在,也可以两个或两个以上单元集成在一个单元中,上述集成的单元既可以采用硬件的形式实现,也可以采用软件功能单元的形式实现。另外,各功能单元、模块的具体名称也只是为了便于相互区分,并不用于限制本申请的保护范围。上述系统中单元、模块的具体工作过程,可以参考前述方法实施例中的对应过程,在此不再赘述。
图5为本申请一实施例提供的机器人的结构示意图。如图5所示,该实施例的机器人5包括:至少一个处理器50(图5中仅示出一个)、存储器51、存储在所述存储器51中并可在所述至少一个处理器50上运行的计算机程序52以及第一激光雷达53和第二激光雷达54,所述处理器50执行所述计算机程序52时实现上述任意各个机器人建图方法实施例中的步骤。
该机器人可以包括,但不仅限于,处理器50、存储器51。本领域技术人员可以理解,图5仅仅是机器人5的举例,并不构成对机器人5的限定,可以包括比图示更多或更少的部件,或者组合某些部件,或者不同的部件,例如还可以包括输入输出设备、网络接入设备等。
所述处理器50可以是中央处理单元(central processing unit,CPU),该处理器50还可以是其他通用处理器、数字信号处理器(digital signal processor,DSP)、专用集成电路(application specific integrated circuit,ASIC)、现场可编程门阵列(field-programmable gate array,FPGA)或者其他可编程逻辑器件、分立门或者晶体管逻辑器件、分立硬件组件等。通用处理器可以是微处理器或者该处理器也可以是任何常规的处理器等。
所述存储器51在一些实施例中可以是所述机器人5的内部存储单元,例如机器人5的硬盘或内存。所述存储器51在另一些实施例中也可以是所述机器人5的外部存储设备,例如所述机器人5上配备的插接式硬盘,智能存储卡(smart media card,SMC),安全数字(secure digital,SD)卡,闪存卡(flash card)等。进一步地,所述存储器51还可以既包括所述机器人5的内部存储单元也包括外部存储设备。所述存储器51用于存储操作系统、应用程序、引导装载程序(BootLoader)、数据以及其他程序等,例如所述计算机程序 的程序代码等。所述存储器51还可以用于暂时地存储已经输出或者将要输出的数据。
本申请实施例还提供了一种计算机可读存储介质,所述计算机可读存储介质存储有计算机程序,所述计算机程序被处理器执行时可实现上述各个机器人建图方法实施例中的步骤。
本申请实施例提供了一种计算机程序产品,当计算机程序产品在机器人上运行时,使得机器人执行时可实现上述各个机器人建图方法实施例中的步骤。
所述集成的单元如果以软件功能单元的形式实现并作为独立的产品销售或使用时,可以存储在一个计算机可读存储介质中。基于这样的理解,本申请实现上述实施例方法中的全部或部分流程,可以通过计算机程序来指令相关的硬件来完成,所述的计算机程序可存储于一计算机可读存储介质中,该计算机程序在被处理器执行时,可实现上述各个方法实施例的步骤。其中,所述计算机程序包括计算机程序代码,所述计算机程序代码可以为源代码形式、对象代码形式、可执行文件或某些中间形式等。所述计算机可读存储介质至少可以包括:能够将计算机程序代码携带到装置/机器人的任何实体或装置、记录介质、计算机存储器、只读存储器(read-only memory,ROM,)、随机存取存储器(random access memory,RAM,)、电载波信号、电信信号以及软件分发介质。例如U盘、移动硬盘、磁碟或者光盘等。在某些司法管辖区,根据立法和专利实践,计算机可读存储介质不可以是电载波信号和电信信号。
在上述实施例中,对各个实施例的描述都各有侧重,某个实施例中没有详述或记载的部分,可以参见其它实施例的相关描述。
本领域普通技术人员可以意识到,结合本文中所公开的实施例描述的各示例的单元及算法步骤,能够以电子硬件、或者计算机软件和电子硬件的结合来实现。这些功能究竟以硬件还是软件方式来执行,取决于技术方案的特定应用和设计约束条件。专业技术人员可以对每个特定的应用来使用不同方法来实现所描述的功能,但是这种实现不应认为超出本申请的范围。
在本申请所提供的实施例中,应该理解到,所揭露的装置/机器人和方法,可以通过其它的方式实现。例如,以上所描述的装置/机器人实施例仅仅是示意性的,例如,所述模块或单元的划分,仅仅为一种逻辑功能划分,实际实现时可以有另外的划分方式,例如多个单元或组件可以结合或者可以集成到另一个系统,或一些特征可以忽略,或不执行。另一点,所显示或讨论的相互之间的耦合或直接耦合或通讯连接可以是通过一些接口,装置或单元的间接耦合或通讯连接,可以是电性,机械或其它的形式。
所述作为分离部件说明的单元可以是或者也可以不是物理上分开的,作为单元显示的部件可以是或者也可以不是物理单元,即可以位于一个地方,或者也可以分布到多个网络单元上。可以根据实际的需要选择其中的部分或者全部单元来实现本实施例方案的目的。
以上所述实施例仅用以说明本申请的技术方案,而非对其限制;尽管参照前述实施例对本申请进行了详细的说明,本领域的普通技术人员应当理解:其依然可以对前述各实施例所记载的技术方案进行修改,或者对其中部分技术特征进行等同替换;而这些修改或者替换,并不使相应技术方案的本质脱离本申请各实施例技术方案的精神和范围,均应包含在本申请的保护范围之内。

Claims (10)

  1. 一种机器人建图方法,其特征在于,应用于包含第一激光雷达和第二激光雷达的机器人,所述第一激光雷达在所述机器人中的位置高于所述第二激光雷达在所述机器人中的位置,所述方法包括:
    获取第一激光数据和第二激光数据,所述第一激光数据为所述机器人在目标区域旋转时,所述第一激光雷达采集的激光数据,所述第二激光数据为所述机器人在所述目标区域旋转时,所述第二激光雷达采集的激光数据;
    根据所述第一激光数据,生成所述第一激光雷达对应的第一地图;
    根据所述第一激光数据和所述第二激光数据,生成所述第二激光雷达对应的第二地图;
    根据所述第一地图和所述第二地图,生成所述目标区域的初始地图;
    获取第三激光数据,所述第三激光数据为所述机器人向所述初始地图中的目标位置移动时,所述第二激光雷达采集的激光数据;
    根据所述第三激光数据更新所述初始地图,得到所述目标区域的目标地图。
  2. 如权利要求1所述的方法,其特征在于,所述根据所述第一激光数据,生成所述第一激光雷达对应的第一地图,包括:
    根据所述第一激光数据确定所述机器人的第一位姿;
    根据所述第一位姿和所述第一激光数据,生成所述第一激光雷达对应的第一地图。
  3. 如权利要求1所述的方法,其特征在于,所述根据所述第一激光数据和所述第二激光数据,生成所述第二激光雷达对应的第二地图,包括:
    根据所述第一激光数据确定所述机器人的第一位姿;
    根据所述第一位姿和所述第二激光数据,生成所述第二激光雷达对应的第二地图。
  4. 如权利要求1所述的方法,其特征在于,所述根据所述第一地图和所述第二地图,生成所述目标区域的初始地图,包括:
    获取所述第一地图对应的第一原点在像素坐标系的第一坐标和所述第二地图对应的第二原点在像素坐标系的第二坐标,所述第一原点为所述第一地图对应的世界坐标系的原点,所述第二原点为所述第二地图对应的世界坐标系的原点;
    根据所述第一坐标和所述第二坐标,对齐所述第一地图和所述第二地图;
    将对齐后的第一地图和第二地图进行合并,得到所述目标区域的初始地图。
  5. 如权利要求1所述的方法,其特征在于,所述方法还包括:
    利用预设的路径覆盖算法确定所述机器人在所述初始地图中的第一移动路径;
    获取所述第一移动路径中的拐点,并将所述拐点确定为所述初始地图中的目标位置。
  6. 如权利要求1至5中任一项所述的方法,其特征在于,所述目标位置包括多个,所述方法还包括:
    获取各所述目标位置与所述机器人之间的第一距离以及各所述目标位置之间的第二距离;
    根据各所述第一距离和各所述第二距离,确定各所述目标位置对应的移动顺序;
    根据所述移动顺序,控制所述机器人向各所述目标位置移动。
  7. 如权利要求6所述的方法,其特征在于,所述控制所述机器人向各所述目标位置移动,包括:
    获取所述第一激光雷达采集的第四激光数据,并根据所述第四激光数据确定所述机器人的第二位姿;
    根据所述第二位姿和所述目标位置,确定所述机器人的第二移动路径;
    根据所述第二移动路径,控制所述机器人向所述目标位置移动。
  8. 一种机器人建图装置,其特征在于,应用于包含第一激光雷达和第二激光雷达的机器人,所述第一激光雷达在所述机器人中的位置高于所述第二激光雷达在所述机器人中的 位置,所述装置包括:
    第一激光数据获取模块,用于获取第一激光数据和第二激光数据,所述第一激光数据为所述机器人在目标区域旋转时,所述第一激光雷达采集的激光数据,所述第二激光数据为所述机器人在所述目标区域旋转时,所述第二激光雷达采集的激光数据;
    第一地图生成模块,用于根据所述第一激光数据,生成所述第一激光雷达对应的第一地图;
    第二地图生成模块,用于根据所述第一激光数据和所述第二激光数据,生成所述第二激光雷达对应的第二地图;
    初始地图生成模块,用于根据所述第一地图和所述第二地图,生成所述目标区域的初始地图;
    第三激光数据获取模块,用于获取第三激光数据,所述第三激光数据为所述机器人向所述初始地图中的目标位置移动时,所述第二激光雷达采集的激光数据;
    初始地图更新模块,用于根据所述第三激光数据更新所述初始地图,得到所述目标区域的目标地图。
  9. 一种机器人,包括存储器、处理器以及存储在所述存储器中并可在所述处理器上运行的计算机程序,其特征在于,所述处理器执行所述计算机程序时实现如权利要求1至7任一项所述的机器人建图方法。
  10. 一种计算机可读存储介质,所述计算机可读存储介质存储有计算机程序,其特征在于,所述计算机程序被处理器执行时实现如权利要求1至7任一项所述的机器人建图方法。
PCT/CN2021/126707 2021-06-09 2021-10-27 机器人建图方法、装置、机器人及计算机可读存储介质 WO2022257332A1 (zh)

Applications Claiming Priority (2)

Application Number Priority Date Filing Date Title
CN202110645968.XA CN113390427B (zh) 2021-06-09 2021-06-09 机器人建图方法、装置、机器人及计算机可读存储介质
CN202110645968.X 2021-06-09

Publications (1)

Publication Number Publication Date
WO2022257332A1 true WO2022257332A1 (zh) 2022-12-15

Family

ID=77620174

Family Applications (1)

Application Number Title Priority Date Filing Date
PCT/CN2021/126707 WO2022257332A1 (zh) 2021-06-09 2021-10-27 机器人建图方法、装置、机器人及计算机可读存储介质

Country Status (2)

Country Link
CN (1) CN113390427B (zh)
WO (1) WO2022257332A1 (zh)

Cited By (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN116182840A (zh) * 2023-04-28 2023-05-30 科大讯飞股份有限公司 地图构建方法、装置、设备及存储介质

Families Citing this family (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN113390427B (zh) * 2021-06-09 2023-03-24 深圳市优必选科技股份有限公司 机器人建图方法、装置、机器人及计算机可读存储介质

Citations (7)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN105928505A (zh) * 2016-04-19 2016-09-07 深圳市神州云海智能科技有限公司 移动机器人的位姿确定方法和设备
US20180364045A1 (en) * 2015-01-06 2018-12-20 Discovery Robotics Robotic platform with mapping facility
CN110861087A (zh) * 2019-11-22 2020-03-06 深圳市优必选科技股份有限公司 机器人初始化定位方法、装置、移动机器人及存储介质
CN112015187A (zh) * 2020-09-11 2020-12-01 北京洛必德科技有限公司 一种用于智能移动机器人的语义地图构建方法及系统
CN112462758A (zh) * 2020-11-06 2021-03-09 深圳市优必选科技股份有限公司 一种建图方法、装置、计算机可读存储介质及机器人
CN112731337A (zh) * 2020-12-30 2021-04-30 杭州海康机器人技术有限公司 地图构建方法、装置和设备
CN113390427A (zh) * 2021-06-09 2021-09-14 深圳市优必选科技股份有限公司 机器人建图方法、装置、机器人及计算机可读存储介质

Family Cites Families (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN106681320A (zh) * 2016-12-15 2017-05-17 浙江大学 一种基于激光数据的移动机器人导航控制方法

Patent Citations (7)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US20180364045A1 (en) * 2015-01-06 2018-12-20 Discovery Robotics Robotic platform with mapping facility
CN105928505A (zh) * 2016-04-19 2016-09-07 深圳市神州云海智能科技有限公司 移动机器人的位姿确定方法和设备
CN110861087A (zh) * 2019-11-22 2020-03-06 深圳市优必选科技股份有限公司 机器人初始化定位方法、装置、移动机器人及存储介质
CN112015187A (zh) * 2020-09-11 2020-12-01 北京洛必德科技有限公司 一种用于智能移动机器人的语义地图构建方法及系统
CN112462758A (zh) * 2020-11-06 2021-03-09 深圳市优必选科技股份有限公司 一种建图方法、装置、计算机可读存储介质及机器人
CN112731337A (zh) * 2020-12-30 2021-04-30 杭州海康机器人技术有限公司 地图构建方法、装置和设备
CN113390427A (zh) * 2021-06-09 2021-09-14 深圳市优必选科技股份有限公司 机器人建图方法、装置、机器人及计算机可读存储介质

Cited By (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN116182840A (zh) * 2023-04-28 2023-05-30 科大讯飞股份有限公司 地图构建方法、装置、设备及存储介质
CN116182840B (zh) * 2023-04-28 2023-07-25 科大讯飞股份有限公司 地图构建方法、装置、设备及存储介质

Also Published As

Publication number Publication date
CN113390427A (zh) 2021-09-14
CN113390427B (zh) 2023-03-24

Similar Documents

Publication Publication Date Title
Murali et al. Indoor Scan2BIM: Building information models of house interiors
Taketomi et al. Visual SLAM algorithms: A survey from 2010 to 2016
WO2022257332A1 (zh) 机器人建图方法、装置、机器人及计算机可读存储介质
Yousif et al. An overview to visual odometry and visual SLAM: Applications to mobile robotics
Lu et al. Visual navigation using heterogeneous landmarks and unsupervised geometric constraints
US7643966B2 (en) Identification of 3D surface points using context-based hypothesis testing
US11295522B2 (en) Three-dimensional (3D) model creation and incremental model refinement from laser scans
CN105844631A (zh) 一种目标定位方法及装置
WO2022095257A1 (zh) 一种建图方法、装置、计算机可读存储介质及机器人
WO2022087916A1 (zh) 定位方法、装置、电子设备和存储介质
Kim et al. Interactive acquisition of residential floor plans
Hübner et al. Automatic voxel-based 3D indoor reconstruction and room partitioning from triangle meshes
Nguyen et al. Structural modeling from depth images
Khurana et al. Extrinsic calibration methods for laser range finder and camera: A systematic review
Xiao et al. Coupling point cloud completion and surface connectivity relation inference for 3D modeling of indoor building environments
Guo et al. Line-based 3d building abstraction and polygonal surface reconstruction from images
CN112419482B (zh) 深度点云融合的矿井液压支架群位姿三维重建方法
Guerra et al. New validation algorithm for data association in SLAM
CN113375657A (zh) 电子地图的更新方法、装置和电子设备
Elkhrachy Feature extraction of laser scan data based on geometric properties
CN113532421B (zh) 一种基于子图更新和反光板优化的动态激光slam方法
Heredia et al. Fast and robust feature matching for rgb-d based localization
Ma et al. Semantic geometric fusion multi-object tracking and lidar odometry in dynamic environment
Gruen et al. An Operable System for LoD3 Model Generation Using Multi-Source Data and User-Friendly Interactive Editing
Strobl et al. Portable 3-D modeling using visual pose tracking

Legal Events

Date Code Title Description
121 Ep: the epo has been informed by wipo that ep was designated in this application

Ref document number: 21944831

Country of ref document: EP

Kind code of ref document: A1

NENP Non-entry into the national phase

Ref country code: DE