Mobile robot relocalization method and device based on whale algorithm and ensemble learning
Through the method based on the whale algorithm and integrated learning, the position and attitude jump and local optimization problems in laser SLAM positioning are solved, and high-precision and robust positioning of mobile robots in dynamic environments are achieved.
Patent Information
- Application Number
- CN202410875654.2
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2024-07-02
- Publication Date
- 2024-09-27
- Estimated Expiration
- 2044-07-02
AI Technical Summary
Existing laser SLAM positioning methods can easily cause IMU noise to increase when the mobile robot encounters bumps or turns with large curvatures, resulting in position or attitude jumps. In addition, the NDT point cloud matching algorithm is prone to local optimization, making it difficult to obtain the best matching state.
Using a method based on the whale algorithm and integrated learning, the three-dimensional point cloud data of the global map is loaded into sub-graphs, and an inter-frame depth residual image is constructed to filter out dynamic targets. The whale optimization algorithm is used to improve NDT matching, and the integrated learning model is combined to achieve real-time positioning. pose estimation.
It improves the positioning accuracy and robustness of mobile robots in dynamic and complex environments, avoids local optimization problems and the impact of increased IMU noise, and ensures optimal pose matching.
Smart Images

Figure CN118411415B
Abstract
Description
Technical Field
[0001] The present invention relates to the technical field of mobile robot positioning, and in particular to a limited environment mobile robot repositioning method and device based on a whale algorithm and ensemble learning. Background Art
[0002] Positioning is the key technology to solve the problem of where the mobile robot is, and it is the core functional module of the mobile robot. At present, the positioning methods of mobile robots mainly include satellite navigation, UWB positioning, magnetic navigation positioning, and SLAM positioning. Among them, the satellite navigation positioning method is mainly used in large-scale open outdoor scenes, such as driverless cars, but in occluded environments, multipath effects are very likely to occur, resulting in position drift, especially in closed scenes such as indoors, where positioning is unavailable due to the lack of satellite signals. Although the positioning accuracy of UWB positioning can reach 10cm level, its power factor directly limits its effective range. For larger structured scenes, multiple UWB base stations need to be installed to build a positioning network, which increases the cost. Magnetic navigation positioning requires a preset magnetic guide belt, which restricts the mobility and flexibility of the mobile robot. At present, most mobile robots are equipped with equipment such as laser radar and IMU. The laser SLAM positioning method based on the existing sensor equipment of the mobile robot has gradually become the main positioning method for mobile robots such as inspection and service due to its flexibility, high precision, and cost saving.
[0003] Since the operating areas of robots such as inspection and service are relatively fixed, the currently commonly used positioning process is mainly to build a global map through the coupling of LiDAR and IMU. On the basis of the global map, the radar point cloud data collected in real time during the operation is matched with the global map or local map to achieve accurate repositioning. The normal distribution transformation algorithm (NDT) is the current mainstream point cloud matching algorithm. The applicant found that in the process of repositioning using NDT, scenes such as bumps in the mobile robot or large curvature turns are likely to cause increased IMU noise, resulting in position or posture jumps, leading to repositioning failure. In addition, the NDT point cloud matching algorithm is prone to local optimization, resulting in the posture obtained not being the best matching state when the iteration is completed.
[0004] Therefore, it is urgent to improve the existing positioning methods to improve the accuracy and efficiency of positioning. Summary of the invention
[0005] In view of the above defects and improvement needs of the existing methods, the purpose of the present invention is to provide a limited environment mobile robot relocalization method and device based on whale algorithm and ensemble learning, which is used to overcome the position and posture jump problems that are prone to occur in the existing laser SLAM relocalization process.
[0006] According to the purpose of the present invention, the present invention proposes a limited environment mobile robot relocalization method based on whale algorithm and ensemble learning, and the method specifically comprises the following steps:
[0007] Step S1. Loading three-dimensional point cloud data of a global map in a work scene, and dividing the global map into a plurality of sub-maps based on a first preset condition;
[0008] Step S2. Obtaining the motion trajectory of the mobile robot after real-time local planning, and mapping it onto the plurality of subgraphs to match the matching subgraphs that meet the preset matching rules;
[0009] Step S3. constructing an inter-frame depth residual image, and obtaining real-time point cloud data with dynamic targets filtered out by using pixel information of the depth residual image as a judgment condition;
[0010] Step S4. Performing whale algorithm adaptation on the real-time point cloud data domain and the matching subgraph to determine the precise position and posture of the mobile robot;
[0011] Step S5. Input the precise posture into a pre-built integrated learning model to output the real-time optimal posture of the mobile robot.
[0012] As a further solution of the present invention, the specific steps of step S1 are as follows:
[0013] Step S11. Loading the job scene globally Figure 3 Dimensional point cloud data, downsampling the original map point cloud data;
[0014] Step S12. Set the global map XY plane of the mobile robot's operating area parallel to the ground, and the Z axis coordinate is the scene elevation; according to the first preset condition, set the global map XY plane The area is divided into several sub-graphs , where the first preset condition is:
[0015] ;
[0016] in, For subgraph Index in width and length direction, Indicates the width of the overlapping interval between two adjacent sub-graphs in the length and width directions; , Sub-graphs The width and length, , Global Map width and length.
[0017] As a further solution of the present invention, the specific steps of step S2 are as follows:
[0018] Step S21. Obtain the motion trajectory of the mobile robot after real-time local planning, and select the motion distance ahead of the motion trajectory The trajectory points in the , from the point set The extraction distance interval is The discrete point set ;
[0019] Step S22. The discrete point set The trajectory points in are mapped to several divided subgraphs in sequence, and matching subgraphs are matched according to preset matching rules;
[0020] The preset matching rule is: if a trajectory point corresponds to a subgraph, the subgraph is the area that the mobile robot must pass through, and the subgraph is the matching subgraph; if a trajectory point corresponds to multiple subgraphs, the number of trajectory points corresponding to the associated subgraphs is counted, and the subgraph with the largest number is selected as the subgraph area that the mobile robot must pass through and as the matching subgraph;
[0021] Step S23. Construct a one-way subgraph linked list of the matched subgraphs according to the sequence of sampling points of the mobile robot's planned trajectory;
[0022] The update process of the one-way subgraph linked list is as follows: when the mobile robot completes the current subgraph path, it enters the next subgraph , then delete the current head node and move the next subgraph As the head node; if the mobile robot moves forward, the subsequent trajectory has a new subgraph For a must-pass area, Insert the tail node to update the one-way subgraph linked list.
[0023] As a further solution of the present invention, the specific steps of step S3 are as follows:
[0024] Step S31. The current time Real-time collection of LiDAR 3D point cloud data Convert to scene depth image ;
[0025] Step S32. The laser radar 3D point cloud data collected at time t-1 By transforming the pose coordinates to the coordinate system at the current time t, the transformed point cloud data is obtained , and based on the process of step S3.1, the point cloud data Convert to depth image ;
[0026] Step S33. Construct the residual image according to the following formula :
[0027] ;
[0028] Traversing the residual image , if the residual image The peak-to-valley value If the peak value is greater than the set threshold, The corresponding spatial points are marked as dynamic target points;
[0029] Step S34. The depth image obtained at the current time t Reverse mapping to the 3D point cloud, filtering out the dynamic target points according to the marked dynamic target attributes, and obtaining the real-time point cloud data without dynamic targets .
[0030] As a further solution of the present invention, step S3.1 specifically includes:
[0031] For the current moment Spatial points in the 3D point cloud , calculate its spatial distance to the radar coordinate system ,
[0032] ;
[0033] The space point Mapped into the depth image, which is in the depth map The corresponding pixel coordinates in are , the pixel value is set to ,
[0034] ;
[0035] ;
[0036] ;
[0037] in, Indicates the number of laser radar beams, Indicates the number of laser points on each beam of the laser radar, ang t andang b Represents the vertical field of view angles of the top and bottom bundles, respectively.
[0038] As a further solution of the present invention, the real-time posture matching in step S4 mainly utilizes the whale optimization algorithm to improve the NDT matching algorithm and solve the problem of falling into local optimization. The specific steps are as follows:
[0039] Step S41. Calculate real-time point cloud data With target point cloud data The relative position transformation relationship between the real-time three-dimensional point cloud data With target point cloud data The matching result calculated in each iteration is calculated through the relative pose vector Defined as an individual in the whale group in the whale algorithm, the optimal pose Defined as target prey, To represent the real-time pose coordinates of the mobile robot in the scene;
[0040] No. The matching pose calculated by the iteration is recorded as ,
[0041] ;
[0042] In the formula, and Respectively represent k The relative displacements in the lateral and longitudinal directions obtained by the iterations are: Indicates k The relative heading angle obtained by the iteration.
[0043] Therefore, the coordinate transformation relationship between the matching point cloud and the target point cloud is:
[0044] ;
[0045] In the formula, and The three-dimensional space points in the real-time point cloud are transformed to obtain coordinates in the map coordinate system.
[0046] Step S42. Calculate the normal distribution of each matching point in the grid of the whale algorithm:
[0047] ;
[0048] In the formula, Indicates that the point cloud after coordinate transformation falls into the point of the normal distribution transformation algorithm NDT grid, ; represents the adjustment factor; m represents the mean of the spatial points falling into the grid, represents the covariance of the spatial points within the grid, that is,
[0049] ;
[0050] ;
[0051] ;
[0052] In the formula, d represents the point spatial dimension.
[0053] Step S43. Calculate the matching factor of each individual whale :
[0054] ;
[0055] like If the current matching position is less than the set threshold, the current matching position is updated as the precise position of the mobile robot. If it is greater than or equal to the set threshold, the process returns to step S41 and continues iterating until the condition of being less than the set threshold is met or the maximum number of iterations is reached.
[0056] As a further solution of the present invention, the specific steps of step S5 are as follows:
[0057] Step S51. Generate an integrated learning training set, use a variety of pose estimation algorithms to obtain real-time pose results based on the point cloud data and IMU data collected by the mobile robot in real time, use preset indicators to evaluate the pose estimation results at the same time, use the evaluation indicators as feature values, and construct training samples;
[0058] Step S52. Construct an integrated learner, design three weak learners based on decision trees respectively, combine the weighted voting algorithm, take the output of the weak classifier as input, and construct a strong learner to achieve accurate pose estimation;
[0059] Step S53. Ensemble learner training: random resampling with replacement is performed on the originally constructed training set to obtain three sub-samples with crossover, and three weak learners are trained respectively. The output results are input into the strong learner. The strong learner predicts the source of the best pose estimation, i.e., the sequence number and probability of the corresponding source, through ensemble learning and weighted voting.
[0060] As a further scheme of the present invention, the preset indicators include: the relative translation error with the preview point of the planned trajectory, the relative rotation error with the preview point of the planned trajectory, the absolute value of the ratio of the mobile robot's turning angle between adjacent frames to the maximum turning angle of the mobile robot, the ratio of the movement speed between adjacent collected data frames to the real-time planning speed of the mobile robot, and the ratio of the relative displacement between adjacent frames to the maximum displacement.
[0061] As a further solution of the present invention, the weighted voting formula in the weighted voting method is as follows:
[0062] ;
[0063] ;
[0064] ;
[0065] ;
[0066] in, Indicates The probability output after ensemble learning of pose estimation sources, Indicates The weak classifier The probability value of the pose estimate source.
[0067] The present invention also provides a mobile robot device, comprising a memory, a processor, and a computer program stored in the memory and executable on the processor, wherein the processor implements the above method when executing the program.
[0068] Compared with the prior art, the present invention has the following beneficial technical effects:
[0069] The present invention mainly uses 3D laser radar and inertial measurement unit IMU (Inertial Measurement Unit) as the main equipment, and realizes real-time robust positioning of mobile robots based on a priori constructed global scene map. Since mobile robots are easily affected by dynamic target interference, jitter, sharp turns and other factors, the repositioning accuracy is reduced or even fails. In order to solve the problem of dynamic target interference in the scene, the inter-frame residual is constructed based on the laser point cloud depth map to filter out the dynamic targets in the scene; in order to solve the problem that the NDT algorithm is prone to fall into local optimization and it is difficult to obtain the best match, the whale optimization algorithm is used to optimize the NDT matching process by introducing adaptive inertia weights and genetic factors; in order to solve the problem of NDT matching failure caused by increased IMU noise under robot jitter and sharp turn conditions, an integrated learning model is constructed to achieve the best prediction of multiple real-time pose estimates and obtain the best pose.
[0070] This method can greatly improve the accuracy and robustness of mobile robot relocalization based on prior maps in dynamic and complex limited environments, and can be widely used in mobile robot operation scenarios such as AGV, cleaning, inspection, and parking lot power supply. BRIEF DESCRIPTION OF THE DRAWINGS
[0071] The accompanying drawings are used to provide a further understanding of the technical solution of the present invention and constitute a part of the specification. Together with the embodiments of the present application, they are used to explain the technical solution of the present invention and do not constitute a limitation on the technical solution of the present invention.
[0072] Figure 1 It is a flow chart of a mobile robot relocalization method based on a whale algorithm and integrated learning provided in one embodiment of the present invention.
[0073] Figure 2 It is a basic flow chart of a mobile robot relocalization method based on a whale algorithm and integrated learning provided by an embodiment of the present invention.
[0074] Figure 3 This is a schematic diagram of sub-graph division provided by an embodiment of the present invention.
[0075] Figure 4 It is a schematic diagram of a basic flow of matching a matching subgraph that meets a preset matching rule provided by an embodiment of the present invention.
[0076] Figure 5 It is a schematic diagram of an integrated learning architecture provided by an embodiment of the present invention.
[0077] Figure 6 It is a schematic diagram of the mobile robot repositioning device proposed by the present invention. DETAILED DESCRIPTION
[0078] The present application is further described in detail below in conjunction with the accompanying drawings. It is necessary to point out here that the following specific implementation methods are only used to further illustrate the present application and cannot be understood as limiting the scope of protection of the present application. Technical personnel in this field can make some non-essential improvements and adjustments to the present application based on the above application content.
[0079] Please refer to Figure 1-3 In the example of the present invention, a mobile robot relocation method based on the whale algorithm and ensemble learning is provided. It should be noted that the present invention improves the whale algorithm to obtain a mobile robot relocation method in a limited environment by combining the whale optimization algorithm with ensemble learning. The method specifically includes:
[0080] Step S1. Loading the three-dimensional point cloud data of the global map in the operation scene, and dividing the global map into a plurality of sub-maps based on a first preset condition, the specific steps include:
[0081] Step S11. Load the constructed scene prior map, and downsample the original map point cloud data. The downsampling adopts a voxel grid size of 0.2m*0.2m*0.2m;
[0082] Step S12. Set the global map XY plane of the mobile robot's operating area parallel to the ground, and the Z axis coordinate is the scene elevation; according to the first preset condition, set the global map XY plane The area is divided into several sub-graphs of 100m*100m , there is an intersection area with a width of 10m between adjacent subgraphs, where the first preset condition is:
[0083] ;
[0084] in, For subgraph Index in width and length direction, Indicates the width of the overlapping interval between two adjacent sub-graphs in the length and width directions; , Sub-graphs The width and length, , Global Map width and length.
[0085] Step S2. Obtain the motion trajectory of the mobile robot after real-time local planning, and after mapping it onto the plurality of subgraphs, match the matching subgraphs that meet the preset matching rules, such as Figure 4 As shown, the specific steps include:
[0086] Step S21. Obtain the motion trajectory of the mobile robot after real-time local planning, and select the motion distance ahead of the motion trajectory The trajectory points within (such as the trajectory of 50m forward in the direction of motion) are used to construct the point set , from the point set The extraction distance interval is The discrete point set (For example, discretization into distance accuracy The discrete accuracy of the trajectory point is 0.5m. Determined according to the movement speed of the mobile robot and the sampling frequency of the laser radar);
[0087] Step S22: The discrete point set The trajectory points in are mapped to several divided subgraphs in sequence, and matching subgraphs are matched according to preset matching rules;
[0088] The preset matching rule is: if a trajectory point corresponds to a subgraph, the subgraph is the area that the mobile robot must pass through, and the subgraph is the matching subgraph; if a trajectory point corresponds to multiple subgraphs, the number of trajectory points corresponding to the associated subgraphs is counted, and the subgraph with the largest number is selected as the subgraph area that the mobile robot must pass through and as the matching subgraph;
[0089] Step S23. Construct a one-way subgraph linked list from the matched subgraphs according to the sequence of sampling points of the planned trajectory of the mobile robot;
[0090] The update process of the one-way subgraph linked list is as follows: when the mobile robot completes the current subgraph path, it enters the next subgraph , then delete the current head node and move the next subgraph As the head node; if the mobile robot moves forward, the subsequent trajectory has a new subgraph For a must-pass area, Insert the tail node to update the one-way subgraph linked list.
[0091] Step S3: constructing an inter-frame depth residual image, and obtaining real-time point cloud data with dynamic targets filtered out by using the pixel information of the depth residual image as a judgment condition. The specific steps include:
[0092] Step S31. Set the current time The collected 3D laser point cloud Map to The depth image of For the laser radar harness, is the laser point on each beam of the laser radar; this implementation case uses a 16-line RoboSense laser radar, so the size of the constructed depth image is 16*1800;
[0093] Obtained through coordinate mapping The depth map at the moment is recorded as .
[0094] For the current moment Spatial points in the 3D point cloud , calculate its spatial distance to the radar coordinate system ,
[0095] ;
[0096] The space point Mapped into the depth image, which is in the depth map The corresponding pixel coordinates in are , the pixel value is set to ,
[0097] ;
[0098] ;
[0099] ;
[0100] in, Indicates the number of laser radar beams, Indicates the number of laser points on each beam of the laser radar, ang t andang b denote the vertical field of view angles of the top and bottom bundles, respectively;
[0101] Step S32. To ensure Moment and The coordinate consistency of the moment, the laser point cloud collected at time t-1 Through coordinate transformation , that is, for each spatial point, there is
[0102] ;
[0103] in, for Move the robot relative to The rotation matrix at time, for Move the robot relative to The translation matrix at time.
[0104] According to step S31, the 3D space point cloud obtained by coordinate transformation is mapped to the depth image, which is recorded as ;
[0105] Step S33. Traverse the depth image and ,Will Subtract the pixel value in The pixel value of the corresponding coordinate in is taken and then removed The pixel value of the pixel in constructs the residual image ;
[0106] ;
[0107] Traversing the residual image , if the residual image The peak-to-valley value If the peak value is greater than the set threshold, The corresponding spatial points are marked as dynamic target points;
[0108] Step S34: The depth image obtained at the current time t Reverse mapping to the 3D point cloud, filtering out the dynamic target points according to the marked dynamic target attributes, and obtaining the real-time point cloud data without dynamic targets .
[0109] Step S4: performing whale algorithm adaptation on the real-time point cloud data domain and the matching subgraph to determine the precise position and posture of the mobile robot. The specific steps include:
[0110] Step S41. Calculate real-time point cloud data With target point cloud data The relative position transformation relationship between the real-time three-dimensional point cloud data With target point cloud data The matching results calculated in each iteration are calculated through relative pose Defined as an individual in the whale group in the whale algorithm, the optimal pose Defined as target prey, To represent the real-time pose coordinates of the mobile robot in the scene, is the heading angle, Indicates that the mobile robot is The real-time x coordinate after iterations, Indicates that the mobile robot is Real-time after iteration coordinate;
[0111] No. The matching pose calculated by the iteration is recorded as ,
[0112] ;
[0113] In the formula, T represents a vector, and Respectively represent k The relative displacements in the lateral and longitudinal directions obtained by the iterations are: Indicates k The relative heading angle obtained by the iteration.
[0114] Then the coordinate transformation relationship between the matching point cloud and the target point cloud is:
[0115] ;
[0116] In the formula, and The three-dimensional space points in the real-time point cloud are transformed to obtain coordinates in the map coordinate system.
[0117] Step S42. Calculate the normal distribution of each matching point in the grid of the whale algorithm (WOA):
[0118] ;
[0119] In the formula, Indicates that the point cloud after coordinate transformation falls into the point of the Normal Distributions Transform (NDT) grid. ; represents the adjustment factor; m represents the mean of the spatial points falling into the grid, represents the covariance of the spatial points within the grid, that is,
[0120] ;
[0121] ;
[0122] ;
[0123] In the formula, d represents the point spatial dimension.
[0124] Step S43. Calculate the matching factor of each individual whale :
[0125] ;
[0126] like If the current matching position is less than the set threshold, the current matching position is updated as the precise position of the mobile robot. If it is greater than or equal to the set threshold, the process returns to step S41 and performs matching update, and continues iterating until the condition is met or the maximum number of iterations is reached.
[0127] Step S5: Input the precise position and posture into the pre-built integrated learning model to output the real-time optimal position and posture of the mobile robot. The specific steps include:
[0128] Step S51. Generate an ensemble learning training set. First, the mobile robot pose estimation sources are designed as follows:
[0129] The preprocessed three-dimensional point cloud The real-time pose obtained by WOA-NDT matching with the local sub-image is denoted as ;
[0130] 3D point cloud and The relative pose obtained by WOA-NDT matching is compared with The pose at the moment is obtained by rotating and translating the spatial coordinates, and is recorded as ;
[0131] The position and posture predicted in real time by the error state Kalman filter constructed by tight coupling of IMU and radar is denoted as ;
[0132] Secondly, for the above three different pose sources, the positioning accuracy is evaluated by five indicators, including relative translation error, relative rotation error, angle ratio, speed ratio, and displacement ratio:
[0133] Relative translation error: relative translation error with the preview point of the planned trajectory;
[0134] Relative rotation error: relative rotation error with the preview point of the planned trajectory;
[0135] Turn angle ratio: the absolute value of the ratio of the turning angle of the mobile robot between adjacent frames to the maximum turning angle of the mobile robot;
[0136] Speed ratio: the ratio of the movement speed between adjacent acquired data frames to the real-time planning speed of the mobile robot;
[0137] Displacement ratio: the ratio of the relative displacement between adjacent frames to the maximum displacement;
[0138] The above five evaluation indicators are used as the feature values of the training samples, and the pose estimation source labels 1, 2, and 3 are used as output values.
[0139] For three independent pose estimation sources, the input of the weak classifier is 15 evaluation indicators and the corresponding serial numbers to construct the initial training set.
[0140] Step S52. Construct an integrated learner, such as Figure 5 As shown in the figure, three decision tree-based learning models (i.e., weak learners) are constructed respectively, and the outputs of the three decision tree models are used as input to the ensemble learner (i.e., strong learner). The optimal prediction is achieved through the weighted voting method. The weighted voting formula is as follows:
[0141] ;
[0142] ;
[0143] ;
[0144] ;
[0145] in, Indicates The probability output after ensemble learning of pose estimation sources, Indicates The weak classifier The probability value of each pose estimation source;
[0146] Step S53. The original training set is randomly resampled with replacement to obtain three sub-samples with crossover. The three weak learners are trained respectively, and the output results are input into the strong learner. The strong learner predicts the source of the best pose estimation, that is, the sequence number and probability of the corresponding source, through ensemble learning and weighted voting algorithm. Then the model is output, and the real-time best pose of the mobile robot is obtained by using the output results of the trained ensemble learning model.
[0147] The present invention adopts the above technical solution, and the above method can filter out the interference of dynamic factors in the scene in real time, and improve the accuracy and speed of positioning during the movement of the robot as a whole. Among them, the NDT matching algorithm based on whale optimization can effectively avoid falling into the local optimal problem, and the integrated learner can efficiently output the optimal posture, avoiding the positioning failure problem caused by a single factor due to the instantaneous and violent movement of the mobile robot.
[0148] like Figure 6As shown, the present invention also provides a corresponding mobile robot repositioning device 600, including a memory 601, a processor 602 and a computer program stored in the memory and executable on the processor. When the memory executes the program, the steps in the above embodiment are implemented, so that the mobile robot repositioning device 600 is configured to execute the corresponding Figure 1 The various steps in the method are not described in detail here. The present invention also provides various types of programmable processors (FPGA, ASIC or other integrated circuits), which are used to run programs, wherein the steps in the above embodiments are executed when the program is running.
[0149] In the present invention, unless otherwise clearly specified and limited, the terms "installed", "connected", "connected", "fixed" and the like should be understood in a broad sense, for example, it can be a fixed connection, a detachable connection, or an integral connection; it can be a mechanical connection or an electrical connection; it can be a direct connection or an indirect connection through an intermediate medium, it can be the internal connection of two elements or the interaction relationship between two elements. For ordinary technicians in this field, the specific meanings of the above terms in the present invention can be understood according to specific circumstances.
[0150] In the present invention, unless otherwise clearly specified and limited, a first feature being "above" or "below" a second feature may mean that the first and second features are in direct contact, or the first and second features are in indirect contact through an intermediate medium. Moreover, a first feature being "above", "above" or "above" a second feature may mean that the first feature is directly above or obliquely above the second feature, or simply means that the first feature is higher in level than the second feature. A first feature being "below", "below" or "below" a second feature may mean that the first feature is directly below or obliquely below the second feature, or simply means that the first feature is lower in level than the second feature.
[0151] The above-mentioned embodiments only express several implementation methods of the present invention, and the description thereof is relatively specific and detailed, but it cannot be understood as limiting the scope of the present invention. It should be pointed out that, for ordinary technicians in this field, several variations and improvements can be made without departing from the concept of the present invention, which all belong to the protection scope of the present invention.
Claims
1. Mobile robot relocalization method based on whale algorithm and ensemble learning, It is characterized in that The method comprises the following steps: Step S1. Loading three-dimensional point cloud data of a global map in a work scene, and dividing the global map into a plurality of sub-maps based on a first preset condition; Step S2. Obtaining the motion trajectory of the mobile robot after real-time local planning, and mapping it onto the plurality of subgraphs to match the matching subgraphs that meet the preset matching rules; Step S3. constructing an inter-frame depth residual image, and obtaining real-time point cloud data with dynamic targets filtered out by using pixel information of the depth residual image as a judgment condition; Step S4. Performing whale algorithm adaptation on the real-time point cloud data and the matching subgraph to determine the precise position and posture of the mobile robot; Step S5. Inputting the precise posture into a pre-built integrated learning model to output the real-time optimal posture of the mobile robot; The step S4 specifically includes: Step S41. Calculate real-time point cloud data With target point cloud data The relative position transformation relationship between the real-time point cloud data With target point cloud data The matching result calculated in each iteration is calculated through the relative pose vector Defined as an individual in the whale group in the whale algorithm, the optimal pose Defined as target prey, To represent the real-time pose coordinates of the mobile robot in the scene; No. The matching pose calculated by the iteration is recorded as , ; In the formula, and denote the lateral and longitudinal relative displacements obtained at the kth iteration, respectively. represents the relative heading angle obtained at the kth iteration; Therefore, the coordinate transformation relationship between the matching point cloud and the target point cloud is: ; In the formula, and The three-dimensional space points in the real-time point cloud are transformed into coordinates in the map coordinate system; Step S42. Calculate the normal distribution of each matching point in the grid of the whale algorithm: ; In the formula, Indicates that the point cloud after coordinate transformation falls into the point of the normal distribution transformation algorithm NDT grid, ; represents the adjustment factor; m represents the mean of the spatial points falling into the grid, represents the covariance of spatial points within the grid; in, ; In the formula, d represents the point The spatial dimension of Step S43. Calculate the matching factor of each individual whale : ; like If the current matching position is less than the set threshold, the current matching position is updated as the precise position of the mobile robot. If the value is greater than or equal to the set threshold, the process returns to step S41 and continues to iterate until the value is satisfied. The condition is less than the set threshold or the maximum number of iterations is reached.
2. The mobile robot relocalization method based on whale algorithm and ensemble learning according to claim 1, It is characterized in that The step S1 specifically includes: Step S11. Loading the three-dimensional point cloud data of the global map of the operation scene, and downsampling the original map point cloud data; Step S12. Set the global map XY plane of the mobile robot's operating area parallel to the ground, and the Z axis coordinate is the scene elevation; according to the first preset condition, set the global map XY plane The area is divided into several sub-graphs , where the first preset condition is: ; in, For subgraph Index in width and length direction, Indicates the width of the overlapping interval between two adjacent sub-graphs in the length and width directions; , Sub-graphs The width and length, , Global Map width and length.
3. The mobile robot relocalization method based on whale algorithm and ensemble learning according to claim 2, It is characterized in that The step S2 specifically includes: Step S21. Obtain the motion trajectory of the mobile robot after real-time local planning, and select the motion distance ahead of the motion trajectory The trajectory points in the , from the point set The extraction distance interval is The discrete point set ; Step S22. The discrete point set The trajectory points in are mapped to several divided subgraphs in sequence, and matching subgraphs are matched according to preset matching rules; The preset matching rule is: if a trajectory point corresponds to a subgraph, the subgraph is the area that the mobile robot must pass through, and the subgraph is the matching subgraph; if a trajectory point corresponds to multiple subgraphs, the number of trajectory points corresponding to the associated subgraphs is counted, and the subgraph with the largest number is selected as the subgraph area that the mobile robot must pass through and as the matching subgraph; Step S23. Construct a one-way subgraph linked list of the matched subgraphs according to the sequence of sampling points of the mobile robot's planned trajectory; The update process of the one-way subgraph linked list is as follows: when the mobile robot completes the current subgraph path, it enters the next subgraph , then delete the current head node and move the next subgraph As the head node; if the mobile robot moves forward, the subsequent trajectory has a new subgraph For a must-pass area, Insert the tail node to update the one-way subgraph linked list.
4. The mobile robot relocalization method based on whale algorithm and ensemble learning according to claim 3, It is characterized in that The step S3 specifically includes: Step S31. The current time Real-time collection of LiDAR 3D point cloud data Convert to scene depth image ; Step S32. The laser radar 3D point cloud data collected at time t-1 By transforming the pose coordinates to the coordinate system at the current time t, the transformed point cloud data is obtained , and based on the process of step S3.1, the point cloud data Convert to depth image ; Step S33. Construct the residual image according to the following formula : ; Traversing the residual image , if the residual image The peak-to-valley value If the peak value is greater than the set threshold, The corresponding spatial points are marked as dynamic target points; Step S34. The depth image obtained at the current time t Reverse mapping to the 3D point cloud, filtering out the dynamic target points according to the marked dynamic target attributes, and obtaining the real-time point cloud data without dynamic targets .
5. The mobile robot relocalization method based on whale algorithm and ensemble learning according to claim 4, It is characterized in that The step S31 specifically includes: For the current moment Spatial points in the 3D point cloud , calculate its spatial distance to the radar coordinate system , ; The space point Mapped into the depth image, which is in the depth map The corresponding pixel coordinates in are , the pixel value is set to , ; ; ; in, Indicates the number of laser radar beams, Indicates the number of laser points on each beam of the laser radar, ang t andang b Represents the vertical field of view angles of the top and bottom bundles, respectively.
6. The mobile robot relocalization method based on whale algorithm and ensemble learning according to claim 5, It is characterized in that The step S5 specifically includes: Step S51. Generate an integrated learning training set: Based on the point cloud data and IMU data collected by the mobile robot in real time, use a variety of pose estimation algorithms to obtain real-time pose results, use preset indicators to evaluate the pose estimation results at the same time, use the evaluation indicators as feature values, and construct training samples; Step S52. Constructing an ensemble learner: designing three weak learners based on decision trees respectively, combining a weighted voting algorithm, taking the output of the weak classifier as input, and constructing a strong learner to achieve accurate pose estimation; Step S53. Ensemble learner training: The original constructed training set is subjected to random resampling with replacement to obtain three sub-samples with crossover, and three weak learners are trained respectively. The output results are input into the strong learner, which predicts the source of the best pose estimation, i.e., the sequence number and probability of the corresponding source, through ensemble learning and weighted voting algorithm.
7. The mobile robot relocalization method based on whale algorithm and ensemble learning according to claim 6, It is characterized in that The preset indicators include: the relative translation error with the preview point of the planned trajectory, the relative rotation error with the preview point of the planned trajectory, the absolute value of the ratio of the mobile robot's turning angle between adjacent frames to the mobile robot's maximum turning angle, the ratio of the movement speed between adjacent acquired data frames to the real-time planning speed of the mobile robot, and the ratio of the relative displacement between adjacent frames to the maximum displacement.
8. The mobile robot relocalization method based on whale algorithm and ensemble learning according to claim 7, It is characterized in that The weighted voting formula in the weighted voting algorithm is as follows: ; ; ; ; in, Indicates The probability output after ensemble learning of pose estimation sources, Indicates The weak classifier The probability value of the pose estimate source.
9. A mobile robot device comprising a memory, a processor and a computer program stored in the memory and executable on the processor, It is characterized in that When the processor executes the program, the method described in any one of claims 1 to 8 is implemented.
