CN-122023517-A - Multi-size shelf detection method, electronic device, and computer-readable storage medium
Abstract
The application discloses a multi-size shelf detection method, electronic equipment and a computer readable storage medium, wherein the method comprises the steps of acquiring point cloud data acquired by a vehicle body, and clustering the point cloud data to obtain point cloud clusters corresponding to different candidate shelf legs; the method comprises the steps of selecting target combinations meeting target conditions from a plurality of candidate combinations, determining target shelf models matched with the target combinations from all shelf models according to each target combination, determining target shelves corresponding to the target combinations, performing plane fitting on point cloud clusters in the target combinations according to each target combination, determining initial pose of the target shelf corresponding to the target combination, and determining target pose of the target shelf according to the target shelf models matched with the target combinations, the initial pose of the target shelf corresponding to the target combinations and the point cloud clusters in the target combinations according to each target combination. The method can enable the vehicle body to accurately identify the position and posture information of the goods shelf.
Inventors
- HU LIZHI
- LIN LEBIN
- YIN CHUNHUI
- LU WEI
- ZHANG XINGMING
Assignees
- 浙江华睿科技股份有限公司
Dates
- Publication Date
- 20260512
- Application Date
- 20260108
Claims (18)
- 1. A method of multi-size shelf detection, the method comprising: Acquiring point cloud data acquired by a vehicle body, and clustering the point cloud data to obtain point cloud clusters corresponding to different candidate shelf legs; Screening target combinations meeting target conditions from a plurality of candidate combinations, wherein the candidate combinations comprise any preset number of the point cloud clusters of the candidate shelf legs; For each target combination, determining a target shelf model matched with the target combination from all shelf models, and determining a target shelf corresponding to the target combination; performing plane fitting on the point cloud clusters in each target combination, and determining the initial pose of the target shelf corresponding to the target combination; And determining the target pose of the target shelf according to the target shelf model matched with the target combination, the initial pose of the target shelf corresponding to the target combination and the point cloud cluster in the target combination aiming at each target combination.
- 2. The method of claim 1, wherein the step of clustering the point cloud data to obtain point cloud clusters corresponding to different candidate shelf legs comprises: Determining candidate areas of the candidate shelf legs according to the size information, the preset upper height limit and the preset lower height limit of all the shelf models; Determining a contour area of the vehicle body according to the size information of the vehicle body, the preset height upper limit and the preset height lower limit; determining point clouds which are in the candidate area but not in the outline area in the point cloud data as candidate point clouds; And clustering the candidate point clouds to obtain the point cloud clusters of the candidate shelf legs.
- 3. The method of claim 2, wherein the step of determining the candidate region of the candidate pallet leg based on the size information, the preset upper height limit, and the preset lower height limit of all the pallet models comprises: Determining the maximum value of the width of all the shelf models and the maximum value of the depth of all the shelf models according to the size information of all the shelf models; and determining the candidate region according to the maximum value of the widths of all the shelf models, the maximum value of the depths of all the shelf models, the preset upper height limit and the preset lower height limit.
- 4. The method of claim 1, wherein the step of determining the position of the substrate comprises, The number of the preset goods shelf legs is four, and the target conditions comprise that the centers of any three goods shelf legs corresponding to the candidate combinations form a right triangle.
- 5. The method of claim 4, wherein the target condition further comprises at least one of a position offset between a candidate shelf of the candidate shelf legs corresponding to the candidate combination and the candidate region not exceeding a first distance threshold, a size of a candidate shelf of the candidate shelf legs corresponding to the candidate combination not exceeding a range in which the sizes of all of the shelf models are located, and a distance error of the candidate shelf legs corresponding to the candidate combination from a center of the candidate shelf not exceeding a first error value.
- 6. The method of claim 4, wherein the step of screening target combinations from a plurality of candidate combinations for compliance with a target condition further comprises: Judging whether the four candidate shelf legs corresponding to the candidate combination have three target shelf legs with centers forming a right triangle or not according to the fact that the candidate combination does not meet the target condition; If the virtual shelf legs exist, constructing the virtual shelf legs by using the three target shelf legs; and in response to the combination of the three target shelf legs and the virtual shelf legs meeting the target condition, determining the combination of the three target shelf legs and the virtual shelf legs as the target combination.
- 7. The method of claim 1, wherein the step of determining a target shelf model that matches the target combination from all shelf models and determining a target shelf corresponding to the target combination comprises: Determining the sizes of polygons formed by the central points of the candidate shelf legs of the preset number corresponding to the target combinations, and obtaining the sizes corresponding to the target combinations; Determining the target shelf model matched with the target combination according to the size corresponding to the target combination and the sizes of all the shelf models; and determining a target shelf corresponding to the target combination according to the target shelf model matched with the target combination.
- 8. The method of claim 7, wherein the step of determining the position of the probe is performed, The step of determining the size of the polygon formed by the center points of the candidate shelf legs corresponding to the target combination, and obtaining the size corresponding to the target combination includes: sorting the candidate shelf legs of the preset number corresponding to the target combination along the circumferential direction; And determining the size of the polygon according to the positions of the candidate shelf legs after sorting.
- 9. The method of claim 8, wherein the predetermined number is four, The step of sorting the preset number of candidate shelf legs corresponding to the target combination along the circumferential direction comprises the following steps: And if the centers of the four candidate shelf legs corresponding to the candidate combination are respectively in four quadrants of a shelf coordinate system, sorting the candidate shelf legs corresponding to the candidate combination according to the center coordinates of the candidate shelf legs, otherwise sorting the candidate shelf legs corresponding to the candidate combination according to the angle of a vector formed by the vehicle body and each candidate shelf leg.
- 10. The method of claim 1, wherein the preset number is four, the step of performing plane fitting on the point cloud clusters in the target combination to determine an initial pose of a target shelf corresponding to the target combination includes: Performing plane fitting on the point cloud clusters in the target combination, and determining the initial position of the target goods shelf and the initial orientation of the target goods shelf; and determining the initial pose of the target goods shelf according to the initial position of the target goods shelf and the initial orientation of the target goods shelf.
- 11. The method of claim 10, wherein the step of performing a plane fit to the point cloud clusters in the target combination to determine an initial position of the target shelf and an initial orientation of the target shelf comprises: fitting the point cloud clusters of the four candidate shelf legs respectively to obtain a first plane and a second plane which are mutually perpendicular to each candidate shelf leg, wherein the first planes of the candidate shelf legs are mutually parallel; and determining the initial position of the target shelf according to the central positions of the first plane and the second plane of each candidate shelf leg.
- 12. The method of claim 10, wherein the step of performing a plane fit to the point cloud clusters in the target combination to determine an initial position of the target shelf and an initial orientation of the target shelf comprises: fitting the point cloud clusters of the four candidate shelf legs respectively to obtain a first plane and a second plane which are mutually perpendicular to each candidate shelf leg, wherein the first planes of the candidate shelf legs are mutually parallel; Determining a first orientation according to two first target planes corresponding to the target combination, and determining a second orientation according to two second target planes corresponding to the target combination, wherein the two first target planes are two first planes parallel to each other or two second planes parallel to each other in the target combination, the two second target planes are two first planes parallel to each other or two second planes parallel to each other in the target combination, and the first target planes and the second target planes are different; According to two sides with the largest length of a rectangle formed by the centers of the four candidate shelf legs in the target combination, respectively determining a third direction and a fourth direction; and determining the initial orientation of the candidate shelf according to the first orientation, the second orientation, the third orientation and the fourth orientation.
- 13. The method of claim 12, wherein the step of determining the position of the probe is performed, The two first target planes are two planes with the most number of added points in two parallel planes in at least part of the first planes and at least part of the second planes in the adjacent three candidate shelf legs, and the two second target planes are two planes with the most number of added points in two parallel planes in at least part of the first planes and at least part of the second planes in the two candidate shelf legs adjacent to the rest one candidate shelf leg.
- 14. The method of claim 12, wherein the step of determining the initial orientation of the candidate shelf based on the first orientation, the second orientation, the third orientation, and the fourth orientation comprises: Calculating a first product of a first weight and the first direction, calculating a second product of a second weight and the second direction, and calculating a third product of a third weight and a sum of the third direction and the fourth direction, wherein in the first weight and the second weight, the closer the candidate shelf leg is to the vehicle body, the larger the corresponding weight value is, and the first weight and the second weight are both larger than the third weight; and calculating the sum of the first product, the second product and the third product to obtain the initial orientation of the candidate shelf.
- 15. The method of claim 10, wherein the step of plane fitting the point cloud clusters in the target combination comprises: Performing plane fitting on the point cloud clusters in the target combination to obtain the first plane of each candidate shelf leg; Acquiring the inner points of all the first planes, and eliminating the inner points of all the first planes from the point cloud clusters in the target combination; and performing plane fitting on the point cloud clusters in the target combination after all the inner points of the first plane are removed, so as to obtain the second plane of each candidate shelf leg.
- 16. The method of claim 10, further comprising, prior to the steps of determining the initial position of the target shelf and the initial orientation of the target shelf, the step of: Projecting the first plane and the second plane of all the candidate shelf legs to a horizontal plane to obtain a first projection size corresponding to the first plane and a second projection size corresponding to the second plane; And if the sizes of the first projection size, the second projection size and the shelf legs of the target shelf model are smaller than a difference threshold value based on the first projection size, the second projection size and the size of the target shelf model, executing the steps of determining the initial pose of the target shelf by the central position of the target shelf and the initial orientation of the target shelf, otherwise, neglecting the target combination.
- 17. An electronic device comprising a memory and a processor connected to each other, wherein the memory is configured to store a computer program which, when executed by the processor, is configured to implement the method of any of claims 1-16.
- 18. A computer readable storage medium, characterized in that the computer readable storage medium stores a computer program executable by a processor to implement the steps in the method of any one of claims 1-16.
Description
Multi-size shelf detection method, electronic device, and computer-readable storage medium Technical Field The present application relates to the field of mobile robots for shelf identification, and in particular, to a multi-size shelf detection method, an electronic device, and a computer readable storage medium. Background In the field of logistics and industry, a mobile robot generally refers to an automatic guided vehicle (Automated Guided Vehicle, abbreviated as an AGV), which is a vehicle equipped with an electromagnetic or optical automatic guiding device, capable of traveling along a predetermined guiding path, and having safety protection and transfer functions, and can replace a person to complete lifting and transfer of containers such as shelves. The mobile robot needs to accurately move to the position right below the goods shelf when carrying the goods shelf task, and in some cases, the goods shelf is not accurately placed or the positioning information of the mobile robot is not accurate enough, so that the mobile robot cannot accurately reach the position right below the goods shelf. Therefore, how to accurately identify the position and pose information of the goods shelf is a technical problem to be solved. Disclosure of Invention The application provides a multi-size shelf detection method, electronic equipment and a computer readable storage medium, which can enable a vehicle body to accurately identify shelf pose information. The application provides a multi-size shelf detection method, which comprises the steps of obtaining point cloud data collected by a vehicle body, carrying out clustering processing on the point cloud data to obtain point cloud clusters corresponding to different candidate shelf legs, screening target combinations meeting target conditions from a plurality of candidate combinations, determining target shelf models matched with the target combinations from all shelf models for each target combination, determining target shelves corresponding to the target combinations, carrying out plane fitting on the point cloud clusters in the target combinations for each target combination, determining initial positions of the target shelves corresponding to the target combinations, and determining the target positions of the target shelves according to the target shelf models matched with the target combinations, the initial positions of the target shelves corresponding to the target combinations and the point cloud clusters in the target combinations for each target combination. A second aspect of the application provides an electronic device comprising a memory and a processor connected to each other, wherein the memory is adapted to store a computer program for implementing the method as described in any of the embodiments above, when the computer program is executed by the processor. A third aspect of the application provides a computer readable storage medium storing a computer program executable by a processor to perform the steps of the method as described in any one of the embodiments above. Compared with the prior art, the method has the beneficial effects that firstly, the method acquires the point cloud data of the vehicle body, performs clustering processing on the point cloud data to obtain the point cloud clusters corresponding to different candidate shelf legs, then screens out target combinations meeting target conditions from a plurality of candidate combinations, determines target shelf models matched with the target combinations from all shelf models, determines target shelves corresponding to the target combinations, performs plane fitting on the point cloud clusters in the target combinations, determines the initial pose of the target shelf corresponding to the target combinations, and determines the target pose of the target shelf according to the target shelf models matched with the target combinations, the initial pose of the target shelves corresponding to the target combinations and the point cloud clusters in the target combinations. According to the method, the initial pose of the target shelf is obtained by carrying out plane fitting on the point cloud clusters in the target combination, so that the accuracy of the initial pose is improved, and the initial pose is further optimized and solved to obtain the target pose, so that the vehicle body can accurately identify the pose of the shelf. Drawings For a clearer description of the technical solutions of the embodiments of the present application, the drawings that are needed in the description of the embodiments will be briefly introduced below, it being obvious that the drawings in the description below are only some embodiments of the present application, and that other drawings can be obtained according to these drawings without inventive effort for a person skilled in the art, wherein: FIG. 1 is a schematic view of a mobile robot according to an embodiment of the present application; FIG. 2 is a