WO2022110451A1 - 机器人定位方法、装置、计算机可读存储介质及机器人 - Google Patents
机器人定位方法、装置、计算机可读存储介质及机器人 Download PDFInfo
- Publication number
- WO2022110451A1 WO2022110451A1 PCT/CN2020/139894 CN2020139894W WO2022110451A1 WO 2022110451 A1 WO2022110451 A1 WO 2022110451A1 CN 2020139894 W CN2020139894 W CN 2020139894W WO 2022110451 A1 WO2022110451 A1 WO 2022110451A1
- Authority
- WO
- WIPO (PCT)
- Prior art keywords
- pose
- robot
- data
- grid map
- laser data
- Prior art date
- Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
- Ceased
Links
Images
Classifications
-
- G—PHYSICS
- G05—CONTROLLING; REGULATING
- G05D—SYSTEMS FOR CONTROLLING OR REGULATING NON-ELECTRIC VARIABLES
- G05D1/00—Control of position, course, altitude or attitude of land, water, air or space vehicles, e.g. using automatic pilots
- G05D1/02—Control of position or course in two dimensions
- G05D1/021—Control of position or course in two dimensions specially adapted to land vehicles
- G05D1/0257—Control of position or course in two dimensions specially adapted to land vehicles using a radar
-
- G—PHYSICS
- G05—CONTROLLING; REGULATING
- G05D—SYSTEMS FOR CONTROLLING OR REGULATING NON-ELECTRIC VARIABLES
- G05D1/00—Control of position, course, altitude or attitude of land, water, air or space vehicles, e.g. using automatic pilots
- G05D1/02—Control of position or course in two dimensions
- G05D1/021—Control of position or course in two dimensions specially adapted to land vehicles
- G05D1/0212—Control of position or course in two dimensions specially adapted to land vehicles with means for defining a desired trajectory
- G05D1/0214—Control of position or course in two dimensions specially adapted to land vehicles with means for defining a desired trajectory in accordance with safety or protection criteria, e.g. avoiding hazardous areas
-
- G—PHYSICS
- G05—CONTROLLING; REGULATING
- G05D—SYSTEMS FOR CONTROLLING OR REGULATING NON-ELECTRIC VARIABLES
- G05D1/00—Control of position, course, altitude or attitude of land, water, air or space vehicles, e.g. using automatic pilots
- G05D1/02—Control of position or course in two dimensions
- G05D1/021—Control of position or course in two dimensions specially adapted to land vehicles
- G05D1/0212—Control of position or course in two dimensions specially adapted to land vehicles with means for defining a desired trajectory
- G05D1/0221—Control of position or course in two dimensions specially adapted to land vehicles with means for defining a desired trajectory involving a learning process
-
- G—PHYSICS
- G05—CONTROLLING; REGULATING
- G05D—SYSTEMS FOR CONTROLLING OR REGULATING NON-ELECTRIC VARIABLES
- G05D1/00—Control of position, course, altitude or attitude of land, water, air or space vehicles, e.g. using automatic pilots
- G05D1/02—Control of position or course in two dimensions
- G05D1/021—Control of position or course in two dimensions specially adapted to land vehicles
- G05D1/0276—Control of position or course in two dimensions specially adapted to land vehicles using signals provided by a source external to the vehicle
Definitions
- the present application belongs to the field of robotics, and in particular, relates to a robot positioning method, a device, a computer-readable storage medium, and a robot.
- the robot navigation and positioning technology is based on the map that the robot has established, obtains the laser data of the currently detected obstacles through the sensor, and locates the robot's pose according to the laser data and the obstacles on the map, so that the subsequent robot can move.
- the accuracy of the positioning results is often low, and it is difficult to adapt to various complex and diverse application environments.
- the embodiments of the present application provide a robot positioning method, device, computer-readable storage medium and robot, in order to solve the problem that the accuracy of the positioning results in the existing methods is often low, and it is difficult to adapt to various complex and diverse application environments. question.
- a first aspect of the embodiments of the present application provides a method for positioning a robot, which may include:
- the second pose is iteratively updated according to the transformed laser data and the obstacle distance information in the grid map to obtain the positioning result of the robot at the current moment.
- the transforming the laser data into a grid map according to the second pose may include:
- ⁇ is the second pose
- (p x , p y ) is the position coordinate in the second pose
- S i ( ⁇ ) is the position coordinate of the i-th laser point transformed into the grid map
- i is the serial number of the laser point in the laser data
- 1 ⁇ i ⁇ n is the number of laser spots in the laser data.
- the iteratively updating the second pose according to the transformed laser data and the obstacle distance information in the grid map may include:
- the pose update amount is greater than the preset threshold, return to the step of calculating the pose update amount according to the transformed laser data and the obstacle distance information in the grid map and its subsequent steps, until the pose update amount is less than or equal to the threshold;
- the second pose after the last update is determined as the positioning result of the robot at the current moment.
- the calculation of the pose update amount according to the transformed laser data and the obstacle distance information in the grid map may include:
- the pose update amount is calculated according to the following formula:
- M(S i ( ⁇ )) is a preset function regarding the distance between Si ( ⁇ ) and the nearest obstacle, and ⁇ is the pose update amount.
- the preset function can be set according to the following formula:
- the updating of the second pose according to the pose update amount may include:
- the second pose is updated according to the following formula:
- ⁇ is the second pose
- ⁇ is the pose update amount
- ⁇ ′ is the updated second pose
- the setting process of the obstacle distance information in the grid map may include:
- a second aspect of the embodiments of the present application provides a robot positioning device, which may include:
- the pose increment calculation module is used to obtain the first odometer data of the robot at the previous moment and the second odometer data at the current moment, and calculate according to the first odometer data and the second odometer data the pose increment of the robot;
- a pose calculation module configured to obtain the first pose of the robot at the previous moment, and calculate the second pose of the robot at the current moment according to the first pose and the pose increment;
- a data transformation module configured to acquire the laser data collected by the robot at the current moment, and transform the laser data into a grid map according to the second pose to obtain the transformed laser data
- a pose iterative update module is configured to iteratively update the second pose according to the transformed laser data and the obstacle distance information in the grid map, so as to obtain the positioning result of the robot at the current moment.
- the data transformation module is specifically configured to transform the laser data into the grid map according to the following formula:
- ⁇ is the second pose
- (p x , p y ) is the position coordinate in the second pose
- S i ( ⁇ ) is the position coordinate of the i-th laser point transformed into the grid map
- i is the serial number of the laser point in the laser data
- 1 ⁇ i ⁇ n is the number of laser spots in the laser data.
- the pose iterative update module may include:
- a pose update amount calculation unit configured to calculate the pose update amount according to the transformed laser data and the obstacle distance information in the grid map
- a pose updating unit configured to update the second pose according to the pose update amount to obtain an updated second pose
- a positioning result determination unit configured to determine the second pose after the last update as the positioning result of the robot at the current moment if the update amount of the pose is less than or equal to the threshold.
- the pose update amount calculation unit is specifically configured to calculate the pose update amount according to the following formula:
- M(S i ( ⁇ )) is a preset function regarding the distance between Si ( ⁇ ) and the nearest obstacle, and ⁇ is the pose update amount.
- the preset function can be set according to the following formula:
- the pose updating unit is specifically configured to update the second pose according to the following formula:
- ⁇ is the second pose
- ⁇ is the pose update amount
- ⁇ ′ is the updated second pose
- the robot positioning device may also include:
- the obstacle distance information setting module is used to traverse each grid in the grid map by using the region growing method, insert the index of each grid into the preset priority queue in turn, and determine the closest distance to the grid.
- the position coordinates of the obstacles in the grid map are obtained until the priority queue is empty, and a grid map with obstacle distance information is obtained.
- a third aspect of the embodiments of the present application provides a computer-readable storage medium, where the computer-readable storage medium stores a computer program, and when the computer program is executed by a processor, implements the steps of any of the foregoing robot positioning methods.
- a fourth aspect of the embodiments of the present application provides a robot, including a memory, a processor, and a computer program stored in the memory and executable on the processor, and the processor implements the computer program when the processor executes the computer program. The steps of any one of the above robot positioning methods.
- a fifth aspect of the embodiments of the present application provides a computer program product, which, when the computer program product runs on a robot, causes the robot to perform the steps of any one of the above robot positioning methods.
- the embodiment of the present application has the following beneficial effects: the embodiment of the present application obtains the first odometer data of the robot at the previous moment and the second odometer data at the current moment, and according to the first odometer data Calculate the pose increment of the robot according to the odometer data and the second odometer data; obtain the first pose of the robot at the last moment, and calculate the pose increment based on the first pose and the pose increment The second pose of the robot at the current moment; obtain the laser data collected by the robot at the current moment, and transform the laser data into a grid map according to the second pose to obtain the transformed laser data ; Iteratively update the second pose according to the transformed laser data and the obstacle distance information in the grid map to obtain the positioning result of the robot at the current moment.
- the positioning accuracy of the robot during navigation and positioning can be significantly improved, so that the robot has more robust and robust positioning performance in various complex and diverse application environments.
- FIG. 1 is a flowchart of an embodiment of a robot positioning method in an embodiment of the application
- Fig. 2 is a schematic flow chart of iteratively updating the pose of the robot
- FIG. 3 is a structural diagram of an embodiment of a robot positioning device in an embodiment of the application.
- FIG. 4 is a schematic block diagram of a robot in an embodiment of the present application.
- the term “if” may be contextually interpreted as “when” or “once” or “in response to determining” or “in response to detecting” .
- the phrases “if it is determined” or “if the [described condition or event] is detected” may be interpreted, depending on the context, to mean “once it is determined” or “in response to the determination” or “once the [described condition or event] is detected. ]” or “in response to detection of the [described condition or event]”.
- a correlation matching or a matching method based on the gradient of an obstacle probability map may be used to locate the robot.
- the correlation matching positioning method is to calculate the matching scores of the laser points and the obstacles on the map under each array pose along the array in each direction of the pose near the initial pose estimate value of the robot, and calculate the highest matching score obtained.
- the pose corresponding to the score is used as the current pose of the robot. This method is similar to the exhaustive traversal method, with a large amount of calculation, and the positioning accuracy depends on the accuracy of the above-mentioned arrays in each direction.
- the matching and positioning method based on the probability map gradient of the obstacle is to calculate the gradient of the probability change of the obstacle on the map where the laser point is located, and iteratively move along the gradient direction. Since the change of the probability gradient of the obstacles on the map has a large change only in the vicinity of the obstacle, after a certain distance from the obstacle, the probability gradient of the obstacles on the map changes very little or even zero.
- the localization method of gradient change cannot output high-precision localization results. Therefore, this method relies on the initial pose accuracy of the robot, and it is necessary to make the laser point as close to the map obstacles as possible.
- a residual equation based on the distance between the laser point and the nearest obstacle may be constructed to optimize the robot pose.
- the robot pose optimization algorithm can perform higher-precision robot positioning.
- this method overcomes the problem that the positioning algorithm is sensitive to the initial pose of the robot and the problem of a large amount of calculation, and the positioning operation is more stable. Efficient. In this process, the nearest obstacle information at any position in the map can be quickly and efficiently calculated based on the combination of priority queue and region growing method.
- an embodiment of a robot positioning method in the embodiment of the present application may include:
- Step S101 Obtain the first odometry data of the robot at the previous moment and the second odometer data at the current moment, and calculate the pose of the robot according to the first odometer data and the second odometer data Increment.
- the odometer data used in the embodiments of the present application may be data measured by a wheeled odometer of the robot, or data measured by an inertial measurement unit (Inertial Measurement Unit, IMU) of the robot.
- IMU Inertial Measurement Unit
- the robot may perform an update of the positioning result at regular intervals.
- the timings for updating the positioning result are sequentially recorded as: time 1, time 2, ..., time t-1, time t, time t+ 1, ..., and so on. If the current time is time t, the previous time is time t-1, and the odometer data of the robot at the previous time (denoted as the first odometry data) and the odometer data at the current time ( Denoted as the second odometer data), the pose increment of the robot can be estimated according to the difference between the two.
- Step S102 Obtain the first pose of the robot at the previous moment, and calculate the second pose of the robot at the current moment according to the first pose and the pose increment.
- the second pose can be calculated according to the following formula:
- ⁇ t-1 is the pose of the robot at the previous moment, that is, the first pose
- ⁇ t-1, t is the pose increment
- ⁇ t is the current moment of the robot. pose, that is, the second pose.
- the calculated ⁇ t is only an estimated value, not an accurate value. It needs to be matched according to the laser data and the raster map to further optimize the robot pose , to get a more accurate pose.
- Step S103 Acquire the laser data collected by the robot at the current moment, and transform the laser data into a grid map according to the second pose to obtain the transformed laser data.
- the grid map divides the environment where the robot is located into a series of grids, and records the states of each grid in them, and the states can include occupied states (that is, occupied by obstacles), free states ( i.e. not occupied by obstacles) and unknown state.
- the robot can detect the surrounding environment through lidar, and its working principle is to transmit a detection signal (laser) to the target, and then compare the received signal reflected from the target with the detection signal, and after proper processing, it can be obtained. information about the target, so as to detect, track and identify the target.
- the robot can collect laser data according to a preset data collection frequency, and collect a frame of laser data at a certain time interval.
- the specific data collection frequency may be set according to the actual situation, which is not specifically limited in this embodiment of the present application.
- the laser data After acquiring the laser data collected by the robot at the current moment, the laser data can be transformed into the grid map according to the following formula:
- ⁇ is the second pose
- (p x , p y ) is the position coordinate in the second pose
- S i ( ⁇ ) is the position coordinate of the i-th laser point transformed into the grid map
- i is the serial number of the laser point in the laser data
- 1 ⁇ i ⁇ n n is the number of laser spots in the laser data.
- Step S104 Iteratively update the second pose according to the transformed laser data and the obstacle distance information in the grid map to obtain the positioning result of the robot at the current moment.
- step S104 may specifically include the following processes:
- Step S1041 Calculate the pose update amount according to the transformed laser data and the obstacle distance information in the grid map.
- a residual equation based on the distance between the laser point and the nearest obstacle can be constructed to optimize the robot pose.
- the pose of the robot is iteratively calculated by the Gauss-Newton method, so that the distance sum of each laser point under the pose at the current moment to the nearest obstacle at the point in the map is the smallest.
- the pose at this time is the ideal pose of the robot.
- the following optimization function can be constructed, and the precise pose of the robot can be calculated by iteratively solving it:
- M(S i ( ⁇ )) is a preset function about the distance between Si ( ⁇ ) and the nearest obstacle, which can be set according to the following formula:
- ⁇ is the position coordinate of the obstacle closest to S i ( ⁇ ) in the grid map
- ⁇ is a preset coefficient, and its specific value can be set according to the actual situation, which is not specified in the embodiment of the present application. limited.
- the pose update amount ⁇ can be calculated according to the following formula:
- Step S1042 Update the second pose according to the pose update amount to obtain an updated second pose.
- the second pose can be updated according to the following formula:
- ⁇ ′ is the updated second pose.
- Step S1043 judging whether the pose update amount is greater than a preset threshold.
- the specific value of the threshold may be set according to the actual situation, which is not specifically limited in this embodiment of the present application. If the pose update amount is greater than the threshold, return to step S1041 and its subsequent steps, that is, calculate the pose update amount again. It should be noted that at this time, the ⁇ used in the calculation process is replaced with the updated ⁇ ′, iterative calculation is performed repeatedly until the pose update amount is less than or equal to the threshold; if the pose update amount is less than or equal to the threshold, the iterative process is ended, and the last update The second pose is determined as the positioning result of the robot at the current moment.
- a priority queue and an area growing method can be combined to set the obstacle distance information in the grid map. That is, use the region growing method to traverse each grid in the grid map, insert the index of each grid into the preset priority queue in turn, and determine that the obstacle closest to the grid is in the grid position coordinates in the map, until the priority queue is empty, a grid map with obstacle distance information is obtained.
- the priority queue compares and sorts the inserted elements with the existing elements in the queue, and inserts them into appropriate positions.
- the element of the priority queue is the index of the grid.
- the element compares the distance of the element to the nearest obstacle with the elements already in the queue in turn.
- the specific setting process of the obstacle distance information in the grid map is as follows:
- Neighbor_cells ⁇ UpCell, DownCell, LeftCell, RightCell ⁇ .
- step (7) is performed; if the traversal is completed, step (10) is performed.
- step (8) If yes, go back to step (6); if not, go to step (8).
- Neighbor_cell.obs_distance
- Neighbor_cell.pose is the position coordinate of the element in the grid map
- Neighbor_cell.obs_pose is the position coordinate of the nearest obstacle to the element in the grid map. The obstacle is approximately equivalent to the obstacle closest to Current_cell, then:
- Neighbor_cell.obs_pose Current_cell.obs_pose
- Current_cell.obs_pose is the position coordinate of the nearest obstacle to Current_cell in the grid map, which is a known quantity
- Neighbor_cell.obs_distance
- the nearest obstacle grid corresponding to the grid can be quickly obtained
- this setting process is only calculated once when the map is initialized, and the map information will not be updated in the subsequent navigation and positioning process, so for any point on the map, the nearest obstacles will not change, and the information can be directly queried during the navigation process.
- the distance between all laser points and the nearest obstacle can be obtained, and the matching optimization is carried out. There is no dependence on the initial optimized pose of the robot, which solves the problem based on the probability map gradient matching algorithm.
- the embodiment of the present application adopts the index-based closest distance evaluation function M(S i ( ⁇ )), a small change in the pose of the robot can cause a large output change in M(S i ( ⁇ )), so in the In the iterative process, higher positioning accuracy can be obtained.
- the embodiment of the present application obtains the first odometer data of the robot at the previous moment and the second odometer data at the current moment, and calculates according to the first odometer data and the second odometer data
- the pose increment of the robot obtain the first pose of the robot at the previous moment, and calculate the second pose of the robot at the current moment according to the first pose and the pose increment ;
- According to the transformed laser data and all The second pose is iteratively updated using the obstacle distance information in the grid map to obtain the positioning result of the robot at the current moment.
- FIG. 3 shows a structural diagram of an embodiment of a robot positioning device provided by an embodiment of the present application.
- a robot positioning device may include:
- the pose increment calculation module 301 is used to obtain the first odometer data of the robot at the previous moment and the second odometer data of the current moment, and according to the first odometer data and the second odometer data calculating the pose increment of the robot;
- the pose calculation module 302 is used to obtain the first pose of the robot at the previous moment, and calculate the second pose of the robot at the current moment according to the first pose and the pose increment;
- a data transformation module 303 configured to acquire the laser data collected by the robot at the current moment, and transform the laser data into a grid map according to the second pose to obtain the transformed laser data;
- the pose iterative update module 304 is used to iteratively update the second pose according to the transformed laser data and the obstacle distance information in the grid map, so as to obtain the positioning result of the robot at the current moment .
- the data transformation module is specifically configured to transform the laser data into the grid map according to the following formula:
- ⁇ is the second pose
- (p x , p y ) is the position coordinate in the second pose
- S i ( ⁇ ) is the position coordinate of the i-th laser point transformed into the grid map
- i is the serial number of the laser point in the laser data
- 1 ⁇ i ⁇ n is the number of laser spots in the laser data.
- the pose iterative update module may include:
- a pose update amount calculation unit configured to calculate the pose update amount according to the transformed laser data and the obstacle distance information in the grid map
- a pose updating unit configured to update the second pose according to the pose update amount to obtain an updated second pose
- a positioning result determination unit configured to determine the second pose after the last update as the positioning result of the robot at the current moment if the update amount of the pose is less than or equal to the threshold.
- the pose update amount calculation unit is specifically configured to calculate the pose update amount according to the following formula:
- M(S i ( ⁇ )) is a preset function regarding the distance between Si ( ⁇ ) and the nearest obstacle, and ⁇ is the pose update amount.
- the preset function can be set according to the following formula:
- the pose updating unit is specifically configured to update the second pose according to the following formula:
- ⁇ is the second pose
- ⁇ is the pose update amount
- ⁇ ′ is the updated second pose
- the robot positioning device may also include:
- the obstacle distance information setting module is used to traverse each grid in the grid map by using the region growing method, insert the index of each grid into the preset priority queue in turn, and determine the closest distance to the grid.
- the position coordinates of the obstacles in the grid map are obtained until the priority queue is empty, and a grid map with obstacle distance information is obtained.
- FIG. 4 shows a schematic block diagram of a robot provided by an embodiment of the present application. For convenience of description, only parts related to the embodiment of the present application are shown.
- the robot 4 of this embodiment includes a processor 40 , a memory 41 , and a computer program 42 stored in the memory 41 and executable on the processor 40 .
- the processor 40 executes the computer program 42
- the steps in each of the above embodiments of the robot positioning method are implemented, for example, steps S101 to S104 shown in FIG. 1 .
- the processor 40 executes the computer program 42
- the functions of the modules/units in each of the foregoing apparatus embodiments such as the functions of the modules 301 to 304 shown in FIG. 3, are implemented.
- the computer program 42 may be divided into one or more modules/units, and the one or more modules/units are stored in the memory 41 and executed by the processor 40 to complete the this application.
- the one or more modules/units may be a series of computer program instruction segments capable of performing specific functions, and the instruction segments are used to describe the execution process of the computer program 42 in the robot 4 .
- FIG. 4 is only an example of the robot 4, and does not constitute a limitation to the robot 4. It may include more or less components than the one shown in the figure, or combine some components, or different components, such as
- the robot 4 may also include input and output devices, network access devices, buses, and the like.
- the processor 40 may be a central processing unit (Central Processing Unit, CPU), or other general-purpose processors, digital signal processors (Digital Signal Processor, DSP), application specific integrated circuits (Application Specific Integrated Circuit, ASIC), Field-Programmable Gate Array (FPGA) or other programmable logic devices, discrete gate or transistor logic devices, discrete hardware components, etc.
- a general purpose processor may be a microprocessor or the processor may be any conventional processor or the like.
- the memory 41 may be an internal storage unit of the robot 4 , such as a hard disk or a memory of the robot 4 .
- the memory 41 can also be an external storage device of the robot 4, such as a plug-in hard disk equipped on the robot 4, a smart memory card (Smart Media Card, SMC), a secure digital (Secure Digital, SD) card, Flash card (Flash Card) and so on.
- the memory 41 may also include both an internal storage unit of the robot 4 and an external storage device.
- the memory 41 is used to store the computer program and other programs and data required by the robot 4 .
- the memory 41 can also be used to temporarily store data that has been output or will be output.
- the disclosed apparatus/robot and method 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 shown or discussed mutual coupling or direct coupling or communication connection may be through some interfaces, indirect coupling or communication connection of devices or units, and may be in electrical, mechanical or other forms.
- the units described as separate components may or may not be physically separated, and components displayed as units may or may not be physical units, that is, may be located in one place, or may be distributed to multiple network units. Some or all of the units may be selected according to actual needs to achieve the purpose of the solution in this embodiment.
- each functional unit in each embodiment of the present application may be integrated into one processing unit, or each unit may exist physically alone, or two or more units may be integrated into one unit.
- the above-mentioned integrated units may be implemented in the form of hardware, or may be implemented in the form of software functional units.
- the integrated modules/units if implemented in the form of software functional units and sold or used as independent products, may be stored in a computer-readable storage medium.
- the present application can implement all or part of the processes in the methods of the above embodiments, and can also be completed by instructing the relevant hardware through a computer program.
- the computer program can be stored in a computer-readable storage medium, and the computer When the program is executed by the processor, the steps of the foregoing method embodiments can be implemented.
- 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, and the like.
- the computer-readable storage medium may include: any entity or device capable of carrying the computer program code, a recording medium, a U disk, a removable hard disk, a magnetic disk, an optical disk, a computer memory, a read-only memory (ROM, Read-Only Memory) ), random access memory (RAM, Random Access Memory), electrical carrier signals, telecommunication signals, and software distribution media, etc. It should be noted that the content contained in the computer-readable storage medium may be appropriately increased or decreased according to the requirements of legislation and patent practice in the jurisdiction, for example, in some jurisdictions, according to legislation and patent practice, computer-readable Storage media exclude electrical carrier signals and telecommunications signals.
Landscapes
- Engineering & Computer Science (AREA)
- Radar, Positioning & Navigation (AREA)
- Remote Sensing (AREA)
- Aviation & Aerospace Engineering (AREA)
- Physics & Mathematics (AREA)
- General Physics & Mathematics (AREA)
- Automation & Control Theory (AREA)
- Control Of Position, Course, Altitude, Or Attitude Of Moving Bodies (AREA)
Abstract
提供了一种机器人定位方法、装置、计算机可读存储介质及机器人,属于机器人技术领域。其中该机器人定位方法包括:获取机器人在上一时刻的第一里程计数据以及在当前时刻的第二里程计数据,并根据第一里程计数据和第二里程计数据计算机器人的位姿增量(S101);获取机器人在上一时刻的第一位姿,并根据第一位姿和位姿增量计算机器人在当前时刻的第二位姿(S102);获取机器人在当前时刻采集的激光数据,并根据第二位姿将激光数据变换至栅格地图中,得到变换后的激光数据(S103);根据变换后的激光数据和栅格地图中的障碍物距离信息对第二位姿进行迭代更新,得到机器人在当前时刻的定位结果(S104)。该定位方法显著提高了定位精度。
Description
本申请要求于2020年11月25日在中国专利局提交的、申请号为202011335627.4的中国专利申请的优先权,其全部内容通过引用结合在本申请中。
本申请属于机器人技术领域,尤其涉及一种机器人定位方法、装置、计算机可读存储介质及机器人。
机器人导航定位技术是根据机器人已经建立好的地图基础上,通过传感器获取当前检测到障碍物的激光数据,并根据激光数据与地图上的障碍物匹配定位出机器人的位姿,以便后续机器人移动。但是,在现有的机器人定位方法中,定位结果的精度往往较低,难以适应各种复杂多样的应用环境。
有鉴于此,本申请实施例提供了一种机器人定位方法、装置、计算机可读存储介质及机器人,以解决现有方法中定位结果的精度往往较低,难以适应各种复杂多样的应用环境的问题。
本申请实施例的第一方面提供了一种机器人定位方法,可以包括:
获取机器人在上一时刻的第一里程计数据以及在当前时刻的第二里程计数据,并根据所述第一里程计数据和所述第二里程计数据计算所述机器人的位姿增量;
获取所述机器人在上一时刻的第一位姿,并根据所述第一位姿和所述位姿增量计算所述机器人在当前时刻的第二位姿;
获取所述机器人在当前时刻采集的激光数据,并根据所述第二位姿将所述激光数据变换至栅格地图中,得到变换后的激光数据;
根据所述变换后的激光数据和所述栅格地图中的障碍物距离信息对所述第二位姿进行迭代更新,得到所述机器人在当前时刻的定位结果。
进一步地,所述根据所述第二位姿将所述激光数据变换至栅格地图中,可以包括:
根据下式将所述激光数据变换至所述栅格地图中:
其中,ξ为所述第二位姿,(p
x,p
y)为所述第二位姿中的位置坐标,
为所述第二位姿中的姿态角,
为第i个激光点的位置坐标,S
i(ξ)为第i个激光点变换至所述栅格地图中的位置坐标,i为所述激光数据中的激光点的序号,1≤i≤n,n为所述激光数据中的激光点的数目。
进一步地,所述根据所述变换后的激光数据和所述栅格地图中的障碍物距离信息对所述第二位姿进行迭代更新,可以包括:
根据所述变换后的激光数据和所述栅格地图中的障碍物距离信息计算位姿更新量;
根据所述位姿更新量对所述第二位姿进行更新,得到更新后的第二位姿;
若所述位姿更新量大于预设的阈值,则返回执行所述根据所述变换后的激光数据和所述栅格地图中的障碍物距离信息计算位姿更新量的步骤及其后续步骤,直至所述位姿更新量小于或等于所述阈值为止;
若所述位姿更新量小于或等于所述阈值,则将最后一次更新后的第二位姿确定为所述机器人在当前时刻的定位结果。
进一步地,所述根据所述变换后的激光数据和所述栅格地图中的障碍物距离信息计算位姿更新量,可以包括:
根据下式计算所述位姿更新量:
Δξ=H
-1dTr
其中,M(S
i(ξ))为关于S
i(ξ)距最近障碍物距离的预设函数,Δξ为所述位姿更新量。
进一步地,所述预设函数可以根据下式进行设置:
进一步地,所述根据所述位姿更新量对所述第二位姿进行更新,可以包括:
根据下式对所述第二位姿进行更新:
ξ′=ξ+Δξ
其中,ξ为所述第二位姿,Δξ为所述位姿更新量,ξ′为所述更新后的第二位姿。
进一步地,所述栅格地图中的障碍物距离信息的设置过程可以包括:
使用区域生长法遍历所述栅格地图中的每个栅格,将每个栅格的索引依次插入到预设的优先队列中,确定与该栅格距离最近的障碍物在所述栅格地图中的位置坐标,直至所述优先队列为空为止,得到具有障碍物距离信息的栅格地图。
本申请实施例的第二方面提供了一种机器人定位装置,可以包括:
位姿增量计算模块,用于获取机器人在上一时刻的第一里程计数据以及在当前时刻的第二里程计数据,并根据所述第一里程计数据和所述第二里程计数据计算所述机器人的位姿增量;
位姿计算模块,用于获取所述机器人在上一时刻的第一位姿,并根据所述第一位姿和所述位姿增量计算所述机器人在当前时刻的第二位姿;
数据变换模块,用于获取所述机器人在当前时刻采集的激光数据,并根据所述第二位姿将所述激光数据变换至栅格地图中,得到变换后的激光数据;
位姿迭代更新模块,用于根据所述变换后的激光数据和所述栅格地图中的障碍物距离信息对所述第二位姿进行迭代更新,得到所述机器人在当前时刻的定位结果。
进一步地,所述数据变换模块具体用于根据下式将所述激光数据变换至所述栅格地图中:
其中,ξ为所述第二位姿,(p
x,p
y)为所述第二位姿中的位置坐标,
为所述第二位姿中的姿态角,
为第i个激光点的位置坐标,S
i(ξ)为第i个激光点变换至所述栅格地图中的位置坐标,i为所述激光数据中的激光点的序号,1≤i≤n,n为所述激光数据中的激光点的数目。
进一步地,所述位姿迭代更新模块可以包括:
位姿更新量计算单元,用于根据所述变换后的激光数据和所述栅格地图中的障碍物距离信息计算位姿更新量;
位姿更新单元,用于根据所述位姿更新量对所述第二位姿进行更新,得到更新后的第二位姿;
定位结果确定单元,用于若所述位姿更新量小于或等于所述阈值,则将最后一次更新后的第二位姿确定为所述机器人在当前时刻的定位结果。
进一步地,所述位姿更新量计算单元具体用于根据下式计算所述位姿更新量:
Δξ=H
-1dTr
其中,M(S
i(ξ))为关于S
i(ξ)距最近障碍物距离的预设函数,Δξ为所述位姿更新量。
所述预设函数可以根据下式进行设置:
进一步地,所述位姿更新单元具体用于根据下式对所述第二位姿进行更新:
ξ′=ξ+Δξ
其中,ξ为所述第二位姿,Δξ为所述位姿更新量,ξ′为所述更新后的第二位姿。
进一步地,所述机器人定位装置还可以包括:
障碍物距离信息设置模块,用于使用区域生长法遍历所述栅格地图中的每个栅格,将每个栅格的索引依次插入到预设的优先队列中,确定与该栅格距离最近的障碍物在所述栅格地图中的位置坐标,直至所述优先队列为空为止,得到具有障碍物距离信息的栅格地图。
本申请实施例的第三方面提供了一种计算机可读存储介质,所述计算机可读存储介质存储有计算机程序,所述计算机程序被处理器执行时实现上述任一种机器人定位方法的步骤。
本申请实施例的第四方面提供了一种机器人,包括存储器、处理器以及存储在所述存储器中并可在所述处理器上运行的计算机程序,所述处理器执行所述计算机程序时实现上述任一种机器人定位方法的步骤。
本申请实施例的第五方面提供了一种计算机程序产品,当计算机程序产品在机器人上运行时,使得机器人执行上述任一种机器人定位方法的步骤。
本申请实施例与现有技术相比存在的有益效果是:本申请实施例获取机器人在上一时刻的第一里程计数据以及在当前时刻的第二里程计数据,并根据所述第一里程计数据和所述第二里程计数据计算所述机器人的位姿增量;获取所述机器人在上一时刻的第一位姿,并根据所述第一位姿和所述位姿增量计算所述机器人在当前时刻的第二位姿;获取所述机器人在当前时刻采集的激光数据,并根据所述第二位姿将所述激光数据变换至栅格地图中,得到变换后的激光数据;根据所述变换后的激光数据和所述栅格地图中的障碍物距离信息对所述第二位姿进行迭代更新,得到所述机器人在当前时刻的定位结果。通过本申请实施例,能够显著提高机器人在导航定位时的定位精度,让机器人在各种复杂多样的应用环境中具有更加稳健鲁棒的定位性能。
为了更清楚地说明本申请实施例中的技术方案,下面将对实施例或现有技术描述中所需要使用的附图作简单地介绍,显而易见地,下面描述中的附图仅仅是本申请的一些实施例,对于本领域普通技术人员来讲,在不付出创造性劳动的前提下,还可以根据这些附图获得其它的附图。
图1为本申请实施例中一种机器人定位方法的一个实施例流程图;
图2为对机器人的位姿进行迭代更新的示意流程图;
图3为本申请实施例中一种机器人定位装置的一个实施例结构图;
图4为本申请实施例中一种机器人的示意框图。
为使得本申请的发明目的、特征、优点能够更加的明显和易懂,下面将结合本申请实施例中的附图,对本申请实施例中的技术方案进行清楚、完整地描述,显然,下面所描述的实施例仅仅是本申请一部分实施例,而非全部的实施例。基于本申请中的实施例,本领域普通技术人员在没有做出创造性劳动前提下所获得的所有其它实施例,都属于本申请保护的范围。
应当理解,当在本说明书和所附权利要求书中使用时,术语“包括”指示所描述特征、整体、步骤、操作、元素和/或组件的存在,但并不排除一个或多个其它特征、整体、步骤、操作、元素、组件和/或其集合的存在或添加。
还应当理解,在此本申请说明书中所使用的术语仅仅是出于描述特定实施例的目的而并不意在限制本申请。如在本申请说明书和所附权利要求书中所使用的那样,除非上下文清楚地指明其它情况,否则单数形式的“一”、“一个”及“该”意在包括复数形式。
还应当进一步理解,在本申请说明书和所附权利要求书中使用的术语“和/或”是指相关联列出的项中的一个或多个的任何组合以及所有可能组合,并且包括这些组合。
如在本说明书和所附权利要求书中所使用的那样,术语“如果”可以依据上下文被解释为“当...时”或“一旦”或“响应于确定”或“响应于检测到”。类似地,短语“如果确定”或“如果检测到[所描述条件或事件]”可以依据上下文被解释为意指“一旦确定”或“响应于确定”或“一旦检测到[所描述条件或事件]”或“响应于检测到[所描述条件或事件]”。
另外,在本申请的描述中,术语“第一”、“第二”、“第三”等仅用于区分描述,而不能理解为指示或暗示相对重要性。
在本申请实施例的一种具体实现中,可以采用相关性匹配或者基于障碍物概率地图梯 度的匹配方式进行机器人定位。
相关性匹配定位方法是在机器人初始位姿估计值附近,沿该位姿的各个方向阵列,依次计算在各个阵列位姿下激光点与地图的障碍物的匹配分数,并将计算得到的最高匹配分数对应的位姿作为机器人的当前位姿。该方法类似于穷举遍历法,计算量较大,且定位精度取决于上述各个方向阵列的精度。
基于障碍物概率地图梯度的匹配定位方法则是计算激光点所在的地图上的障碍物概率变化梯度,并沿梯度方向迭代移动。由于地图障碍物概率梯度变化只有在靠近障碍物附近的地方才有较大的变化,在离障碍物一定距离之后,地图障碍物概率梯度变化很小,甚至为零,此时该基于地图障碍物梯度变化的定位方法无法输出高精度的定位结果。因此该方法依赖机器人的初始位姿精度,需要使得激光点尽可能地靠近地图障碍物。
在本申请实施例的另一种具体实现中,可以构建出基于激光点距最近障碍物的距离的残差方程来优化机器人位姿。该机器人位姿优化算法能够进行更高精度的机器人定位,同时相比其它激光定位算法,该方法克服了定位算法对机器人初始位姿敏感的问题和计算量较大的问题,使用定位运行更加稳定高效。在这一过程中,还可以基于优先队列和区域生长法相结合的方法来快速高效地计算出地图中任一位置的最近障碍物信息。
请参阅图1,本申请实施例中一种机器人定位方法的一个实施例可以包括:
步骤S101、获取机器人在上一时刻的第一里程计数据以及在当前时刻的第二里程计数据,并根据所述第一里程计数据和所述第二里程计数据计算所述机器人的位姿增量。
在本申请实施例中所使用的里程计数据可以为所述机器人的轮式里程计测量得到的数据,或所述机器人的惯性测量单元(Inertial Measurement Unit,IMU)测量得到的数据。
所述机器人可以每隔一定的时间间隔即执行一次定位结果的更新,此处将进行定位结果更新的时刻依次记为:时刻1、时刻2、…、时刻t-1、时刻t、时刻t+1、…,以此类推。若当前时刻为时刻t,则其上一时刻即为时刻t-1,分别获取所述机器人在上一时刻的里程计数据(记为第一里程计数据)以及在当前时刻的里程计数据(记为第二里程计数据),根据两者之间的差值即可估算得到所述机器人的位姿增量。
步骤S102、获取所述机器人在上一时刻的第一位姿,并根据所述第一位姿和所述位姿增量计算所述机器人在当前时刻的第二位姿。
具体地,可以根据下式计算所述第二位姿:
ξ
t=ξ
t-1+Δξ
t-1,t
其中,ξ
t-1为所述机器人在上一时刻的位姿,也即所述第一位姿,Δξ
t-1,t为所述位姿增量,ξ
t为所述机器人在当前时刻的位姿,也即所述第二位姿。
需要注意的是,由于传感器误差和机器人位姿误差的存在,这样计算得到的ξ
t只是一个估算值,并不是一个精确值,需要根据激光数据和栅格地图进行匹配,来进一步优化机器人位姿,得到更加准确的位姿。
步骤S103、获取所述机器人在当前时刻采集的激光数据,并根据所述第二位姿将所述激光数据变换至栅格地图中,得到变换后的激光数据。
所述栅格地图是将所述机器人所在的环境划分为一系列的栅格,并在其中记录了各个栅格的状态,所述状态可以包括占据状态(即被障碍物占据)、自由状态(即未被障碍物占据)和未知状态。
所述机器人可以通过激光雷达来探测周边环境,其工作原理是向目标发射探测信号(激光),然后将接收到的从目标反射回来的信号与探测信号进行比较,作适当处理后,就可获得目标的有关信息,从而对目标进行探测、跟踪和识别。一般地,所述机器人可以 按照预先设定的一个数据采集频率来进行激光数据的采集,每隔一定的时间间隔即采集一帧激光数据。具体的数据采集频率可以根据实际情况进行设置,本申请实施例对此不作具体限定。
在获取所述机器人在当前时刻采集的激光数据之后,可以根据下式将所述激光数据变换至所述栅格地图中:
其中,ξ为所述第二位姿,(p
x,p
y)为所述第二位姿中的位置坐标,
为所述第二位姿中的姿态角,
为第i个激光点的位置坐标,S
i(ξ)为第i个激光点变换至所述栅格地图中的位置坐标,i为所述激光数据中的激光点的序号,1≤i≤n,n为所述激光数据中的激光点的数目。根据上式将i从1遍历到n,即可得到所述激光数据中的各个激光点变换至所述栅格地图中的位置坐标,也即所述变换后的激光数据。
步骤S104、根据所述变换后的激光数据和所述栅格地图中的障碍物距离信息对所述第二位姿进行迭代更新,得到所述机器人在当前时刻的定位结果。
如图2所示,步骤S104具体可以包括如下过程:
步骤S1041、根据所述变换后的激光数据和所述栅格地图中的障碍物距离信息计算位姿更新量。
为了更加精确高效地进行激光数据与地图之间的匹配,在本申请实施例中可以构建出基于激光点距最近障碍物的距离的残差方程来优化机器人位姿。在这一过程中,通过高斯牛顿法来迭代计算所述机器人的位姿,使得在当前时刻的位姿下的各个激光点距地图中的该点最近障碍物的距离和最小。当激光数据中的所有激光点均与地图中障碍物重合(即该点距离最近的障碍物距离为0)时,则此时的位姿即为所述机器人的理想位姿。
通过上述分析,在本申请实施例中可以构造出如下优化函数,通过对其的迭代求解即可计算出机器人的精确位姿:
其中,M(S
i(ξ))为关于S
i(ξ)距最近障碍物距离的预设函数,可以根据下式进行设置:
当距离越小,则可以认为激光数据与地图匹配的越好,机器人的位姿就越准确,误差越趋近于0,即:
对其进行一阶泰勒展开,可得:
接着,再对上式求导,可得:
令:
那么,则可以根据下式计算得到位姿更新量Δξ:
Δξ=H
-1dTr
步骤S1042、根据所述位姿更新量对所述第二位姿进行更新,得到更新后的第二位姿。
具体地,可以根据下式对所述第二位姿进行更新:
ξ′=ξ+Δξ
其中,ξ′为所述更新后的第二位姿。
步骤S1043、判断所述位姿更新量是否大于预设的阈值。
所述阈值的具体取值可以根据实际情况进行设置,本申请实施例对此不做具体限定。若所述位姿更新量大于所述阈值,则返回执行步骤S1041及其后续步骤,即再次计算位姿更新量,需要注意的是,此时计算过程中所使用到的ξ均替换为更新后的ξ′,如此反复地进行迭代计算,直至所述位姿更新量小于或等于所述阈值为止;若所述位姿更新量小于或等于所述阈值,则结束迭代过程,并将最后一次更新后的第二位姿确定为所述机器人在当前时刻的定位结果。
在上述过程中,需要计算与激光点S
i(ξ)距离最近的障碍物在所述栅格地图中的位置坐标
在本申请实施例中,可以结合采用优先队列和区域生长法来在所述栅格地图中进行障碍物距离信息的设置。即使用区域生长法遍历所述栅格地图中的每个栅格,将每个栅格的索引依次插入到预设的优先队列中,确定与该栅格距离最近的障碍物在所述栅格地图中的位置坐标,直至所述优先队列为空为止,得到具有障碍物距离信息的栅格地图。其中,优先队列会对插入的元素与队列中已有的元素进行比较并排序,并将插入到合适的位置中,本实施例中优先队列的元素即为栅格的索引,对新插入队列的元素,依次比较该元素与列队中已有元素的距最近障碍物的距离。距离越小,该元素在队列中的位置越靠前, 越先出队列;距离越大,该元素在队列中的位置越靠后,越后出队列。这样保证从优先队列前端取出的元素是整个队列中距最近障碍物的距离最小的栅格的索引。
所述栅格地图中的障碍物距离信息的具体设置过程为:
(1)遍历所述栅格地图,将其中所有栅格的距最近障碍物的距离(记为obs_distance)初始化为一固定值(记为max_distance),并将所述栅格地图中被障碍物占据的栅格的索引记为集合:Obs_cells={obs_1,obs_2,…,obs_i,…,obs_n}。
(2)依次将Obs_cells中的所有元素的距最近障碍物的距离设置为0,即:obs_i.obs_distance=0,并将这些元素插入优先队列(记为Priority_quene)中。
(3)判断Priority_quene是否为空;
若为空,则结束设置过程;若不为空,则执行步骤(4)。
(4)取出Priority_quene最前端元素,并将其作为当前元素(记为Current_cell)。
(5)依次获取Current_cell在栅格地图中前后左右的元素,记为集合:Neighbor_cells={UpCell,DownCell,LeftCell,RightCell}。
(6)判断是否遍历完Neighbor_cells中的各元素;
若未遍历完,则执行步骤(7);若遍历完,则执行步骤(10)。
(7)从Neighbor_cells中选取一个元素,并判断该元素的标志位(记为Neighbor_cell.is_marked)是否已被置为真(true);
若是,则返回执行步骤(6);若否,则执行步骤(8)。
(8)根据下式计算该元素的距最近障碍物的距离(记为Neighbor_cell.obs_distance):
Neighbor_cell.obs_distance=||Neighbor_cell.pose-Neighbor_cell.obs_pose||
其中,Neighbor_cell.pose为该元素在栅格地图中的位置坐标,Neighbor_cell.obs_pose为距该元素最近的障碍物在栅格地图中的位置坐标,在本申请实施例中,可以将距该元素最近的障碍物近似等价为距Current_cell最近的障碍物,则有:
Neighbor_cell.obs_pose=Current_cell.obs_pose
其中,Current_cell.obs_pose即为距Current_cell最近的障碍物在栅格地图中的位置坐标,为一已知量;
综合以上两式,则有:
Neighbor_cell.obs_distance=||Neighbor_cell.pose-Current_cell.obs_pose||。
(9)将该元素的标志位置为真,即:Neighbor_cell.is_marked=true,并将该元素插入到Priority_quene中;然后返回执行步骤(6)。
(10)从Priority_quene中删除Current_cell;然后返回执行步骤(3),直至Priority_quene为空,结束整个设置过程。
通过本申请实施例,给定地图中任一栅格坐标S
i(ξ),即可快速得到该栅格对应的最近障碍物栅格
且这一设置过程只在初始化地图时计算一次,后续导航定位过程中地图信息不再更新,故对于地图中任一点,最近障碍物也不会发生变化,导航过程中该信息可直接查询得到,无需进行任何计算,极大提升了定位效率。同时无论机器人提供的初始位姿精度如何,都能得到所有激光点距最近障碍物的距离,并进行匹配优化,对机器人初始优化位姿不存在依赖,解决了基于概率地图梯度匹配算法的问题。并且由于本申请实施例采用了基于指数的最近距离评价函数M(S
i(ξ)),机器人的位姿的微小变化即可引起M(S
i(ξ))较大的输出变化,因此在迭代过程中可以得到更高的定位精度。
综上所述,本申请实施例获取机器人在上一时刻的第一里程计数据以及在当前时刻的第二里程计数据,并根据所述第一里程计数据和所述第二里程计数据计算所述机器人的位 姿增量;获取所述机器人在上一时刻的第一位姿,并根据所述第一位姿和所述位姿增量计算所述机器人在当前时刻的第二位姿;获取所述机器人在当前时刻采集的激光数据,并根据所述第二位姿将所述激光数据变换至栅格地图中,得到变换后的激光数据;根据所述变换后的激光数据和所述栅格地图中的障碍物距离信息对所述第二位姿进行迭代更新,得到所述机器人在当前时刻的定位结果。通过本申请实施例,能够显著提高机器人在导航定位时的定位精度,让机器人在各种复杂多样的应用环境中具有更加稳健鲁棒的定位性能。
应理解,上述实施例中各步骤的序号的大小并不意味着执行顺序的先后,各过程的执行顺序应以其功能和内在逻辑确定,而不应对本申请实施例的实施过程构成任何限定。
对应于上文实施例所述的一种机器人定位方法,图3示出了本申请实施例提供的一种机器人定位装置的一个实施例结构图。
本实施例中,一种机器人定位装置可以包括:
位姿增量计算模块301,用于获取机器人在上一时刻的第一里程计数据以及在当前时刻的第二里程计数据,并根据所述第一里程计数据和所述第二里程计数据计算所述机器人的位姿增量;
位姿计算模块302,用于获取所述机器人在上一时刻的第一位姿,并根据所述第一位姿和所述位姿增量计算所述机器人在当前时刻的第二位姿;
数据变换模块303,用于获取所述机器人在当前时刻采集的激光数据,并根据所述第二位姿将所述激光数据变换至栅格地图中,得到变换后的激光数据;
位姿迭代更新模块304,用于根据所述变换后的激光数据和所述栅格地图中的障碍物距离信息对所述第二位姿进行迭代更新,得到所述机器人在当前时刻的定位结果。
进一步地,所述数据变换模块具体用于根据下式将所述激光数据变换至所述栅格地图中:
其中,ξ为所述第二位姿,(p
x,p
y)为所述第二位姿中的位置坐标,
为所述第二位姿中的姿态角,
为第i个激光点的位置坐标,S
i(ξ)为第i个激光点变换至所述栅格地图中的位置坐标,i为所述激光数据中的激光点的序号,1≤i≤n,n为所述激光数据中的激光点的数目。
进一步地,所述位姿迭代更新模块可以包括:
位姿更新量计算单元,用于根据所述变换后的激光数据和所述栅格地图中的障碍物距离信息计算位姿更新量;
位姿更新单元,用于根据所述位姿更新量对所述第二位姿进行更新,得到更新后的第二位姿;
定位结果确定单元,用于若所述位姿更新量小于或等于所述阈值,则将最后一次更新后的第二位姿确定为所述机器人在当前时刻的定位结果。
进一步地,所述位姿更新量计算单元具体用于根据下式计算所述位姿更新量:
Δξ=H
-1dTr
其中,M(S
i(ξ))为关于S
i(ξ)距最近障碍物距离的预设函数,Δξ为所述位姿更新量。
所述预设函数可以根据下式进行设置:
进一步地,所述位姿更新单元具体用于根据下式对所述第二位姿进行更新:
ξ′=ξ+Δξ
其中,ξ为所述第二位姿,Δξ为所述位姿更新量,ξ′为所述更新后的第二位姿。
进一步地,所述机器人定位装置还可以包括:
障碍物距离信息设置模块,用于使用区域生长法遍历所述栅格地图中的每个栅格,将每个栅格的索引依次插入到预设的优先队列中,确定与该栅格距离最近的障碍物在所述栅格地图中的位置坐标,直至所述优先队列为空为止,得到具有障碍物距离信息的栅格地图。
所属领域的技术人员可以清楚地了解到,为描述的方便和简洁,上述描述的装置,模块和单元的具体工作过程,可以参考前述方法实施例中的对应过程,在此不再赘述。
在上述实施例中,对各个实施例的描述都各有侧重,某个实施例中没有详述或记载的部分,可以参见其它实施例的相关描述。
图4示出了本申请实施例提供的一种机器人的示意框图,为了便于说明,仅示出了与本申请实施例相关的部分。
如图4所示,该实施例的机器人4包括:处理器40、存储器41以及存储在所述存储器41中并可在所述处理器40上运行的计算机程序42。所述处理器40执行所述计算机程序42时实现上述各个机器人定位方法实施例中的步骤,例如图1所示的步骤S101至步骤S104。或者,所述处理器40执行所述计算机程序42时实现上述各装置实施例中各模块/单元的功能,例如图3所示模块301至模块304的功能。
示例性的,所述计算机程序42可以被分割成一个或多个模块/单元,所述一个或者多个模块/单元被存储在所述存储器41中,并由所述处理器40执行,以完成本申请。所述一个或多个模块/单元可以是能够完成特定功能的一系列计算机程序指令段,该指令段用于描述所述计算机程序42在所述机器人4中的执行过程。
本领域技术人员可以理解,图4仅仅是机器人4的示例,并不构成对机器人4的限定,可以包括比图示更多或更少的部件,或者组合某些部件,或者不同的部件,例如所述机器人4还可以包括输入输出设备、网络接入设备、总线等。
所述处理器40可以是中央处理单元(Central Processing Unit,CPU),还可以是其它通用处理器、数字信号处理器(Digital Signal Processor,DSP)、专用集成电路(Application Specific Integrated Circuit,ASIC)、现场可编程门阵列(Field-Programmable Gate Array,FPGA)或者其它可编程逻辑器件、分立门或者晶体管逻辑器件、分立硬件组件等。通用处理器可以是微处理器或者该处理器也可以是任何常规的处理器等。
所述存储器41可以是所述机器人4的内部存储单元,例如机器人4的硬盘或内存。 所述存储器41也可以是所述机器人4的外部存储设备,例如所述机器人4上配备的插接式硬盘,智能存储卡(Smart Media Card,SMC),安全数字(Secure Digital,SD)卡,闪存卡(Flash Card)等。进一步地,所述存储器41还可以既包括所述机器人4的内部存储单元也包括外部存储设备。所述存储器41用于存储所述计算机程序以及所述机器人4所需的其它程序和数据。所述存储器41还可以用于暂时地存储已经输出或者将要输出的数据。
所属领域的技术人员可以清楚地了解到,为了描述的方便和简洁,仅以上述各功能单元、模块的划分进行举例说明,实际应用中,可以根据需要而将上述功能分配由不同的功能单元、模块完成,即将所述装置的内部结构划分成不同的功能单元或模块,以完成以上描述的全部或者部分功能。实施例中的各功能单元、模块可以集成在一个处理单元中,也可以是各个单元单独物理存在,也可以两个或两个以上单元集成在一个单元中,上述集成的单元既可以采用硬件的形式实现,也可以采用软件功能单元的形式实现。另外,各功能单元、模块的具体名称也只是为了便于相互区分,并不用于限制本申请的保护范围。上述系统中单元、模块的具体工作过程,可以参考前述方法实施例中的对应过程,在此不再赘述。
在上述实施例中,对各个实施例的描述都各有侧重,某个实施例中没有详述或记载的部分,可以参见其它实施例的相关描述。
本领域普通技术人员可以意识到,结合本文中所公开的实施例描述的各示例的单元及算法步骤,能够以电子硬件、或者计算机软件和电子硬件的结合来实现。这些功能究竟以硬件还是软件方式来执行,取决于技术方案的特定应用和设计约束条件。专业技术人员可以对每个特定的应用来使用不同方法来实现所描述的功能,但是这种实现不应认为超出本申请的范围。
在本申请所提供的实施例中,应该理解到,所揭露的装置/机器人和方法,可以通过其它的方式实现。例如,以上所描述的装置/机器人实施例仅仅是示意性的,例如,所述模块或单元的划分,仅仅为一种逻辑功能划分,实际实现时可以有另外的划分方式,例如多个单元或组件可以结合或者可以集成到另一个系统,或一些特征可以忽略,或不执行。另一点,所显示或讨论的相互之间的耦合或直接耦合或通讯连接可以是通过一些接口,装置或单元的间接耦合或通讯连接,可以是电性,机械或其它的形式。
所述作为分离部件说明的单元可以是或者也可以不是物理上分开的,作为单元显示的部件可以是或者也可以不是物理单元,即可以位于一个地方,或者也可以分布到多个网络单元上。可以根据实际的需要选择其中的部分或者全部单元来实现本实施例方案的目的。
另外,在本申请各个实施例中的各功能单元可以集成在一个处理单元中,也可以是各个单元单独物理存在,也可以两个或两个以上单元集成在一个单元中。上述集成的单元既可以采用硬件的形式实现,也可以采用软件功能单元的形式实现。
所述集成的模块/单元如果以软件功能单元的形式实现并作为独立的产品销售或使用时,可以存储在一个计算机可读存储介质中。基于这样的理解,本申请实现上述实施例方法中的全部或部分流程,也可以通过计算机程序来指令相关的硬件来完成,所述的计算机程序可存储于一计算机可读存储介质中,该计算机程序在被处理器执行时,可实现上述各个方法实施例的步骤。其中,所述计算机程序包括计算机程序代码,所述计算机程序代码可以为源代码形式、对象代码形式、可执行文件或某些中间形式等。所述计算机可读存储介质可以包括:能够携带所述计算机程序代码的任何实体或装置、记录介质、U盘、移动硬盘、磁碟、光盘、计算机存储器、只读存储器(ROM,Read-Only Memory)、随机存取存储器(RAM,Random Access Memory)、电载波信号、电信信号以及软件分发介质等。需要说明的是,所述计算机可读存储介质包含的内容可以根据司法管辖区内立法和专利实践的要求进行适当的增减,例如在某些司法管辖区,根据立法和专利实践,计算机可读存储介质不包括电载波信号和电信信号。
以上所述实施例仅用以说明本申请的技术方案,而非对其限制;尽管参照前述实施例 对本申请进行了详细的说明,本领域的普通技术人员应当理解:其依然可以对前述各实施例所记载的技术方案进行修改,或者对其中部分技术特征进行等同替换;而这些修改或者替换,并不使相应技术方案的本质脱离本申请各实施例技术方案的精神和范围,均应包含在本申请的保护范围之内。
Claims (10)
- 一种机器人定位方法,其特征在于,包括:获取机器人在上一时刻的第一里程计数据以及在当前时刻的第二里程计数据,并根据所述第一里程计数据和所述第二里程计数据计算所述机器人的位姿增量;获取所述机器人在上一时刻的第一位姿,并根据所述第一位姿和所述位姿增量计算所述机器人在当前时刻的第二位姿;获取所述机器人在当前时刻采集的激光数据,并根据所述第二位姿将所述激光数据变换至栅格地图中,得到变换后的激光数据;根据所述变换后的激光数据和所述栅格地图中的障碍物距离信息对所述第二位姿进行迭代更新,得到所述机器人在当前时刻的定位结果。
- 根据权利要求2所述的机器人定位方法,其特征在于,所述根据所述变换后的激光数据和所述栅格地图中的障碍物距离信息对所述第二位姿进行迭代更新,包括:根据所述变换后的激光数据和所述栅格地图中的障碍物距离信息计算位姿更新量;根据所述位姿更新量对所述第二位姿进行更新,得到更新后的第二位姿;若所述位姿更新量大于预设的阈值,则返回执行所述根据所述变换后的激光数据和所述栅格地图中的障碍物距离信息计算位姿更新量的步骤及其后续步骤,直至所述位姿更新量小于或等于所述阈值为止;若所述位姿更新量小于或等于所述阈值,则将最后一次更新后的第二位姿确定为所述机器人在当前时刻的定位结果。
- 根据权利要求3所述的机器人定位方法,其特征在于,所述根据所述位姿更新量对所述第二位姿进行更新,包括:根据下式对所述第二位姿进行更新:ξ′=ξ+Δξ其中,ξ为所述第二位姿,Δξ为所述位姿更新量,ξ′为所述更新后的第二位姿。
- 根据权利要求1至6中任一项所述的机器人定位方法,其特征在于,所述栅格地图中的障碍物距离信息的设置过程包括:使用区域生长法遍历所述栅格地图中的每个栅格,将每个栅格的索引依次插入到预设的优先队列中,确定与该栅格距离最近的障碍物在所述栅格地图中的位置坐标,直至所述优先队列为空为止,得到具有障碍物距离信息的栅格地图。
- 一种机器人定位装置,其特征在于,包括:位姿增量计算模块,用于获取机器人在上一时刻的第一里程计数据以及在当前时刻的第二里程计数据,并根据所述第一里程计数据和所述第二里程计数据计算所述机器人的位姿增量;位姿计算模块,用于获取所述机器人在上一时刻的第一位姿,并根据所述第一位姿和所述位姿增量计算所述机器人在当前时刻的第二位姿;数据变换模块,用于获取所述机器人在当前时刻采集的激光数据,并根据所述第二位姿将所述激光数据变换至栅格地图中,得到变换后的激光数据;位姿迭代更新模块,用于根据所述变换后的激光数据和所述栅格地图中的障碍物距离信息对所述第二位姿进行迭代更新,得到所述机器人在当前时刻的定位结果。
- 一种计算机可读存储介质,所述计算机可读存储介质存储有计算机程序,其特征在于,所述计算机程序被处理器执行时实现如权利要求1至7中任一项所述的机器人定位方法的步骤。
- 一种机器人,包括存储器、处理器以及存储在所述存储器中并可在所述处理器上运行的计算机程序,其特征在于,所述处理器执行所述计算机程序时实现如权利要求1至7中任一项所述的机器人定位方法的步骤。
Applications Claiming Priority (2)
| Application Number | Priority Date | Filing Date | Title |
|---|---|---|---|
| CN202011335627.4A CN112462769A (zh) | 2020-11-25 | 2020-11-25 | 机器人定位方法、装置、计算机可读存储介质及机器人 |
| CN202011335627.4 | 2020-11-25 |
Publications (1)
| Publication Number | Publication Date |
|---|---|
| WO2022110451A1 true WO2022110451A1 (zh) | 2022-06-02 |
Family
ID=74799000
Family Applications (1)
| Application Number | Title | Priority Date | Filing Date |
|---|---|---|---|
| PCT/CN2020/139894 Ceased WO2022110451A1 (zh) | 2020-11-25 | 2020-12-28 | 机器人定位方法、装置、计算机可读存储介质及机器人 |
Country Status (2)
| Country | Link |
|---|---|
| CN (1) | CN112462769A (zh) |
| WO (1) | WO2022110451A1 (zh) |
Cited By (4)
| Publication number | Priority date | Publication date | Assignee | Title |
|---|---|---|---|---|
| CN115112125A (zh) * | 2022-07-15 | 2022-09-27 | 智道网联科技(北京)有限公司 | 自动驾驶车辆的定位方法、装置及电子设备、存储介质 |
| CN117021078A (zh) * | 2023-07-28 | 2023-11-10 | 浙江华睿科技股份有限公司 | 一种机器人校准方法、装置及设备 |
| CN117420830A (zh) * | 2023-10-23 | 2024-01-19 | 浙江大学 | 环境探索方法、大鼠机器人及存储介质 |
| CN118913294A (zh) * | 2024-10-12 | 2024-11-08 | 青岛港国际股份有限公司 | Igv导航预警方法、系统、终端及存储介质 |
Families Citing this family (11)
| Publication number | Priority date | Publication date | Assignee | Title |
|---|---|---|---|---|
| CN115246118A (zh) * | 2021-04-25 | 2022-10-28 | 广东博智林机器人有限公司 | 一种机器人定位方法、装置、机器人及存储介质 |
| CN115507836B (zh) * | 2021-06-23 | 2024-02-02 | 同方威视技术股份有限公司 | 用于确定机器人位置的方法以及机器人 |
| CN113510703B (zh) * | 2021-06-25 | 2022-09-16 | 深圳市优必选科技股份有限公司 | 机器人位姿的确定方法、装置、机器人及存储介质 |
| CN113671523B (zh) * | 2021-08-18 | 2024-11-01 | Oppo广东移动通信有限公司 | 机器人定位方法、装置、存储介质及机器人 |
| CN116263505A (zh) * | 2021-12-14 | 2023-06-16 | 深圳市普渡科技有限公司 | 基于激光雷达的建图方法及相关装置 |
| CN116409565B (zh) * | 2021-12-31 | 2026-02-13 | 深圳市海柔创新科技有限公司 | 机器人定位方法、装置、调度设备、介质及程序产品 |
| CN114211173B (zh) * | 2022-01-27 | 2024-05-31 | 上海电气集团股份有限公司 | 一种确定焊接位置的方法、装置及系统 |
| CN114740854A (zh) * | 2022-04-11 | 2022-07-12 | 北京京东乾石科技有限公司 | 一种机器人避障控制方法和装置 |
| CN116954203A (zh) * | 2022-04-13 | 2023-10-27 | 广州视源电子科技股份有限公司 | 栅格地图构建方法、装置、设备及存储介质 |
| WO2023231003A1 (zh) * | 2022-06-02 | 2023-12-07 | 深圳市正浩创新科技股份有限公司 | 地图更新方法、计算机设备和存储介质 |
| CN116182834A (zh) * | 2022-12-27 | 2023-05-30 | 上海擎朗智能科技有限公司 | 移动设备的定位方法、装置、机器人及存储介质 |
Citations (10)
| Publication number | Priority date | Publication date | Assignee | Title |
|---|---|---|---|---|
| JP2012255705A (ja) * | 2011-06-08 | 2012-12-27 | Fujitsu Ltd | 位置姿勢出力装置、位置姿勢出力プログラム及び位置姿勢出力方法 |
| CN108332758A (zh) * | 2018-01-26 | 2018-07-27 | 上海思岚科技有限公司 | 一种移动机器人的走廊识别方法及装置 |
| CN110174894A (zh) * | 2019-05-27 | 2019-08-27 | 小狗电器互联网科技(北京)股份有限公司 | 机器人及其重定位方法 |
| CN110515382A (zh) * | 2019-08-28 | 2019-11-29 | 锐捷网络股份有限公司 | 一种智能设备及其定位方法 |
| CN110858076A (zh) * | 2018-08-22 | 2020-03-03 | 杭州海康机器人技术有限公司 | 一种设备定位、栅格地图构建方法及移动机器人 |
| CN110895408A (zh) * | 2018-08-22 | 2020-03-20 | 杭州海康机器人技术有限公司 | 一种自主定位方法、装置及移动机器人 |
| CN111113422A (zh) * | 2019-12-30 | 2020-05-08 | 深圳市优必选科技股份有限公司 | 机器人定位方法、装置、计算机可读存储介质及机器人 |
| CN111190191A (zh) * | 2019-12-11 | 2020-05-22 | 杭州电子科技大学 | 一种基于激光slam的扫描匹配方法 |
| US20200164508A1 (en) * | 2018-11-28 | 2020-05-28 | Mitsubishi Electric Research Laboratories, Inc. | System and Method for Probabilistic Multi-Robot Positioning |
| CN111536964A (zh) * | 2020-07-09 | 2020-08-14 | 浙江大华技术股份有限公司 | 机器人定位方法及装置、存储介质 |
Family Cites Families (2)
| Publication number | Priority date | Publication date | Assignee | Title |
|---|---|---|---|---|
| CN111486842B (zh) * | 2019-01-29 | 2022-04-15 | 深圳市优必选科技有限公司 | 重定位方法及装置、机器人 |
| CN111708047B (zh) * | 2020-06-16 | 2023-02-28 | 浙江华睿科技股份有限公司 | 机器人定位评估方法、机器人及计算机存储介质 |
-
2020
- 2020-11-25 CN CN202011335627.4A patent/CN112462769A/zh active Pending
- 2020-12-28 WO PCT/CN2020/139894 patent/WO2022110451A1/zh not_active Ceased
Patent Citations (10)
| Publication number | Priority date | Publication date | Assignee | Title |
|---|---|---|---|---|
| JP2012255705A (ja) * | 2011-06-08 | 2012-12-27 | Fujitsu Ltd | 位置姿勢出力装置、位置姿勢出力プログラム及び位置姿勢出力方法 |
| CN108332758A (zh) * | 2018-01-26 | 2018-07-27 | 上海思岚科技有限公司 | 一种移动机器人的走廊识别方法及装置 |
| CN110858076A (zh) * | 2018-08-22 | 2020-03-03 | 杭州海康机器人技术有限公司 | 一种设备定位、栅格地图构建方法及移动机器人 |
| CN110895408A (zh) * | 2018-08-22 | 2020-03-20 | 杭州海康机器人技术有限公司 | 一种自主定位方法、装置及移动机器人 |
| US20200164508A1 (en) * | 2018-11-28 | 2020-05-28 | Mitsubishi Electric Research Laboratories, Inc. | System and Method for Probabilistic Multi-Robot Positioning |
| CN110174894A (zh) * | 2019-05-27 | 2019-08-27 | 小狗电器互联网科技(北京)股份有限公司 | 机器人及其重定位方法 |
| CN110515382A (zh) * | 2019-08-28 | 2019-11-29 | 锐捷网络股份有限公司 | 一种智能设备及其定位方法 |
| CN111190191A (zh) * | 2019-12-11 | 2020-05-22 | 杭州电子科技大学 | 一种基于激光slam的扫描匹配方法 |
| CN111113422A (zh) * | 2019-12-30 | 2020-05-08 | 深圳市优必选科技股份有限公司 | 机器人定位方法、装置、计算机可读存储介质及机器人 |
| CN111536964A (zh) * | 2020-07-09 | 2020-08-14 | 浙江大华技术股份有限公司 | 机器人定位方法及装置、存储介质 |
Cited By (4)
| Publication number | Priority date | Publication date | Assignee | Title |
|---|---|---|---|---|
| CN115112125A (zh) * | 2022-07-15 | 2022-09-27 | 智道网联科技(北京)有限公司 | 自动驾驶车辆的定位方法、装置及电子设备、存储介质 |
| CN117021078A (zh) * | 2023-07-28 | 2023-11-10 | 浙江华睿科技股份有限公司 | 一种机器人校准方法、装置及设备 |
| CN117420830A (zh) * | 2023-10-23 | 2024-01-19 | 浙江大学 | 环境探索方法、大鼠机器人及存储介质 |
| CN118913294A (zh) * | 2024-10-12 | 2024-11-08 | 青岛港国际股份有限公司 | Igv导航预警方法、系统、终端及存储介质 |
Also Published As
| Publication number | Publication date |
|---|---|
| CN112462769A (zh) | 2021-03-09 |
Similar Documents
| Publication | Publication Date | Title |
|---|---|---|
| WO2022110451A1 (zh) | 机器人定位方法、装置、计算机可读存储介质及机器人 | |
| CN111536964B (zh) | 机器人定位方法及装置、存储介质 | |
| US11776217B2 (en) | Method for planning three-dimensional scanning viewpoint, device for planning three-dimensional scanning viewpoint, and computer readable storage medium | |
| Segal et al. | Generalized-icp. | |
| CN111862163B (zh) | 一种轨迹优化方法及装置 | |
| WO2024197815A1 (zh) | 一种工程机械的建图、方法、设备、及可读存储介质 | |
| CN113933818A (zh) | 激光雷达外参的标定的方法、设备、存储介质及程序产品 | |
| CN110930495A (zh) | 基于多无人机协作的icp点云地图融合方法、系统、装置及存储介质 | |
| CN111113422A (zh) | 机器人定位方法、装置、计算机可读存储介质及机器人 | |
| CN111486842A (zh) | 重定位方法及装置、机器人 | |
| CN110458083B (zh) | 一种车道线矢量化方法、装置及存储介质 | |
| CN111707279B (zh) | 一种激光点云与地图的匹配评价方法、介质、终端和装置 | |
| CN109583505A (zh) | 一种多传感器的物体关联方法、装置、设备及介质 | |
| CN111275748B (zh) | 动态环境下基于激光雷达的点云配准方法 | |
| CN114022552B (zh) | 一种融合激光雷达和相机的目标定位方法及相关装置 | |
| CN110135439A (zh) | 一种自动识别货架的方法及装置、移动机器人 | |
| CN116255992A (zh) | 一种同时定位与建图的方法和装置 | |
| WO2023202157A1 (zh) | 铲斗坐标标定方法和装置、更新方法和设备、挖掘机 | |
| CN112097772A (zh) | 机器人及其地图构建方法和装置 | |
| CN115164868A (zh) | 机器人定位方法、装置、机器人及存储介质 | |
| CN114565670A (zh) | 一种位姿优化方法及装置 | |
| CN115424097B (zh) | 三维目标检测算法的评估方法、系统、电子设备及介质 | |
| CN115047486B (zh) | 基于最大似然估计平滑的激光里程计方法、系统、装置 | |
| CN116793354A (zh) | 车辆定位初始化方法、装置、设备及存储介质 | |
| CN120800360A (zh) | 一种基于合并概率体素地图的紧耦合激光惯性视觉融合方法 |
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: 20963339 Country of ref document: EP Kind code of ref document: A1 |
|
| NENP | Non-entry into the national phase |
Ref country code: DE |
|
| 122 | Ep: pct application non-entry in european phase |
Ref document number: 20963339 Country of ref document: EP Kind code of ref document: A1 |




