Lawn mower visual positioning method, device, equipment and storage medium

By visually detecting and optimizing the signs in the lawn mower, the accuracy problem of RTK and visual slam positioning when the signal is unstable is solved, achieving higher lawn mower positioning accuracy and avoiding cumulative drift.

CN117570969BActive Publication Date: 2024-09-10RUICHI LASER (SHENZHEN) CO LTD
View PDF 19 Cites 0 Cited by

Patent Information

Application Number
CN202410060045.1
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2024-01-16
Publication Date
2024-09-10
Estimated Expiration
2044-01-16

AI Technical Summary

Technical Problem

Traditional RTK positioning and visual slam positioning are inaccurate and prone to drift when the signal is unstable.

Method used

Through visual inspection of the sign positioning stakes on the lawn where the lawn mower is located, the absolute pose of the sign is obtained, and when the lawn mower is in the mowing task, the absolute pose of the lawn mower is determined based on the sign position, combined with camera vision The inertial pose is globally optimized to obtain the visual positioning pose.

Benefits of technology

It effectively avoids cumulative positioning drift in RTK signal occlusion environments, improves positioning accuracy, and achieves higher visual positioning poses.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN117570969B
    Figure CN117570969B
Patent Text Reader

Abstract

The present invention relates to the technical field of lawn mowers, and discloses a lawn mower visual positioning method, device, equipment and storage medium, the method comprising: visually detecting the signboard positioning stake of the lawn where the lawn mower is located to obtain the absolute position and posture of the signboard; when the lawn mower is in a mowing task, based on the signboard positioning stake, determining the absolute position and posture of the lawn mower corresponding to the lawn mower through the absolute position and posture of the signboard; globally optimizing the absolute position and posture of the lawn mower and the visual inertial position and posture of the camera to obtain the re-visual positioning posture. Since the present invention determines the absolute position and posture of the lawn mower through the absolute position and posture of the signboard positioning stake of the lawn, and finally globally optimizes the visual inertial position and posture of the camera of the lawn mower, it avoids the situation that the lawn mower is prone to cumulative drift in the environment where the RTK signal is blocked, further optimizes the traditional visual slam positioning, obtains the re-visual positioning posture with higher accuracy, and effectively solves the problem of cumulative drift.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present invention relates to the technical field of lawn mowers, and in particular to a lawn mower visual positioning method, device, equipment and storage medium. Background Art

[0002] With the development of science and technology, lawnmower robots can autonomously mow according to the planned path without human intervention. They are widely used in scenes such as maintaining lawns in family courtyards and trimming large lawns, providing great convenience for people's production and life. At present, the main positioning solutions for lawnmowers are RTK positioning or visual slam positioning. RTK positioning uses the differential data between the base station and the lawnmower robot for measurement to achieve precise positioning of the lawnmower robot, with an accuracy of several centimeters. Visual slam positioning uses the traditional positioning method based on visual perception, that is, by collecting environmental images around the lawnmower robot and extracting features in the natural environment, the position and posture of the lawnmower robot are calculated.

[0003] The former has higher absolute positioning accuracy when the RTK signal is good, but it has the disadvantage that the RTK signal is easily blocked and the positioning is inaccurate when the signal is unstable. Although the latter can adapt to the environment where the RTK signal is blocked, it has the disadvantage that the positioning is prone to accumulated drift.

[0004] The above contents are only used to assist in understanding the technical solution of the present invention and do not constitute an admission that the above contents are prior art. Summary of the invention

[0005] The main purpose of the present invention is to provide a lawn mower visual positioning method, device, equipment and storage medium, aiming to solve the technical problems of traditional RTK positioning or visual slam positioning, which have the disadvantages of inaccurate positioning when the signal is unstable and easy accumulated drift.

[0006] To achieve the above object, the present invention provides a lawn mower visual positioning method, the method comprising the following steps:

[0007] Performing visual inspection on the signboard positioning stakes of the lawn where the lawn mower is located to obtain the absolute position of the signboard positioning stakes in the lawn;

[0008] When the lawn mower is in a mowing task, based on the signboard positioning pile, the absolute position of the lawn mower corresponding to the lawn mower is determined by the absolute position of the signboard;

[0009] The absolute pose of the lawn mower and the visual inertial pose of the camera of the lawn mower are globally optimized to obtain a re-visual positioning pose.

[0010] Optionally, the visual detection of the sign positioning stakes of the lawn where the lawn mower is located to obtain the absolute position of the sign of the sign positioning stakes in the lawn includes:

[0011] Performing environmental detection on the lawn where the lawn mower is located to obtain an environmental map corresponding to the lawn;

[0012] Performing visual inspection on the signboard positioning stakes of the lawn to obtain the relative position of the signboard between the signboard positioning stakes and the lawn mower, wherein the signboard positioning stakes are pre-installed within a preset range of the lawn;

[0013] Based on the environment map, the relative position of the signboard is solved to obtain the absolute position of the signboard of the signboard positioning stake in the lawn.

[0014] Optionally, before visually inspecting the sign post of the lawn to obtain the relative position of the sign between the sign post and the lawn mower, the method further includes:

[0015] Detecting the signboard on the lawn to obtain a rectangular frame area of ​​the signboard;

[0016] Extracting features of the region of interest in the rectangular frame area to obtain matching feature points of the signboard;

[0017] Determining whether the matching feature point matches the preset positioning pile template;

[0018] If so, the signboard that matches the preset positioning pile template is determined to be the signboard positioning pile.

[0019] Optionally, the visual detection of the sign positioning stakes of the lawn to obtain the relative position of the sign between the sign positioning stakes and the lawn mower includes:

[0020] Performing visual inspection on the signboard positioning stakes of the lawn to obtain a current image frame of the signboard positioning stakes;

[0021] Performing matrix transformation on the matching feature points corresponding to the current image frame and the preset positioning pile template to obtain a homography matrix between the current image frame and the preset positioning pile template;

[0022] Performing homography transformation on the preset template two-dimensional points on the preset positioning pile template according to the homography matrix to obtain the frame two-dimensional points corresponding to the current frame;

[0023] The three-dimensional distance between the two-dimensional point of the image frame and the two-dimensional point of the template is processed by the PNP algorithm to obtain the relative position of the sign between the sign positioning pile and the lawn mower.

[0024] Optionally, when the lawn mower is in a mowing task, based on the signboard positioning pile, determining the absolute position of the lawn mower corresponding to the lawn mower through the absolute position of the signboard includes:

[0025] When the lawn mower is in a mowing task, determining whether the signboard positioning stake is within the visual range of the lawn mower;

[0026] If yes, then based on the signboard positioning stake, obtaining the relative position of the lawn mower between the lawn mower and the signboard positioning stake;

[0027] The relative posture of the lawn mower and the absolute posture of the sign are solved to obtain the absolute posture of the lawn mower in the lawn.

[0028] Optionally, when the lawn mower is in a mowing task, after determining whether the signboard positioning stake is within the visual range of the lawn mower, the method further includes:

[0029] When the signboard positioning stake is not within the visual range, turning on the camera and IMU sensor of the lawn mower;

[0030] Based on the camera and the IMU sensor, obtaining a camera visual inertial position of the lawn mower within the lawn;

[0031] The lawn mower is controlled according to the visual inertial posture of the camera to perform a mowing task along a preset planned path.

[0032] Optionally, globally optimizing the absolute pose of the lawn mower and the visual inertial pose of the camera of the lawn mower to obtain the re-visual positioning pose includes:

[0033] Acquire the camera visual inertial pose of the lawn mower through a camera and an IMU sensor;

[0034] Using the visual inertial pose of the camera as a relative constraint and the absolute pose of the lawn mower as an absolute constraint;

[0035] Taking the relative constraint condition and the absolute constraint condition as targets, constructing a current pose graph of the lawn mower;

[0036] The current pose graph is optimized to obtain a re-visual positioning pose corresponding to the lawn mower in the current pose graph.

[0037] In addition, to achieve the above-mentioned purpose, the present invention also provides a lawn mower visual positioning device, the device comprising:

[0038] A sign detection module is used to perform visual detection on the sign positioning stakes of the lawn where the lawn mower is located, and obtain the absolute position of the sign positioning stakes in the lawn;

[0039] A posture determination module, used for determining the absolute posture of the lawn mower corresponding to the lawn mower through the absolute posture of the sign based on the sign positioning pile when the lawn mower is in a mowing task;

[0040] The visual positioning module is used to globally optimize the absolute posture of the lawn mower and the visual inertial posture of the camera of the lawn mower to obtain a re-visual positioning posture.

[0041] In addition, to achieve the above-mentioned purpose, the present invention also proposes a lawn mower visual positioning device, which includes: a memory, a processor, and a lawn mower visual positioning program stored in the memory and executable on the processor, wherein the lawn mower visual positioning program is configured to implement the steps of the lawn mower visual positioning method described above.

[0042] In addition, to achieve the above-mentioned purpose, the present invention also proposes a storage medium, on which a lawn mower visual positioning program is stored. When the lawn mower visual positioning program is executed by a processor, the steps of the lawn mower visual positioning method described above are implemented.

[0043] The present invention obtains the absolute position of the signboard in the lawn by visually detecting the signboard positioning stakes of the lawn where the lawn mower is located; then, when the lawn mower is in a mowing task, the absolute position of the lawn mower corresponding to the lawn mower is determined by the absolute position of the signboard based on the signboard positioning stakes; finally, the absolute position of the lawn mower and the visual inertial position of the camera of the lawn mower are globally optimized to obtain the re-visual positioning position. Since the present invention determines the absolute position of the lawn mower by the absolute position of the signboard positioning stakes of the lawn, and finally performs global optimization with the visual inertial position of the camera of the lawn mower, it avoids the situation where the lawn mower is prone to cumulative drift in the environment where the RTK signal is blocked, further optimizes the traditional visual slam positioning, obtains a more accurate re-visual positioning position, and effectively solves the problem of cumulative drift. BRIEF DESCRIPTION OF THE DRAWINGS

[0044] Figure 1 It is a structural schematic diagram of a lawn mower visual positioning device in a hardware operating environment involved in an embodiment of the present invention;

[0045] Figure 2 It is a schematic diagram of the flow chart of the first embodiment of the lawn mower visual positioning method of the present invention;

[0046] Figure 3 It is a schematic diagram of the flow chart of the second embodiment of the lawn mower visual positioning method of the present invention;

[0047] Figure 4 It is a schematic diagram of the flow chart of the third embodiment of the lawn mower visual positioning method of the present invention;

[0048] Figure 5 This is a structural block diagram of the first embodiment of the lawn mower visual positioning device of the present invention.

[0049] The realization of the purpose, functional features and advantages of the present invention will be further explained in conjunction with embodiments and with reference to the accompanying drawings. DETAILED DESCRIPTION

[0050] It should be understood that the specific embodiments described herein are only used to explain the present invention, and are not used to limit the present invention.

[0051] Reference Figure 1 , Figure 1 The structure diagram of the lawn mower visual positioning device in the hardware operating environment involved in the embodiment of the present invention.

[0052] like Figure 1 As shown, the lawn mower visual positioning device may include: a processor 1001, such as a central processing unit (CPU), a communication bus 1002, a user interface 1003, a network interface 1004, and a memory 1005. Among them, the communication bus 1002 is used to realize the connection and communication between these components. The user interface 1003 may include a display screen (Display), an input unit such as a keyboard (Keyboard), and the optional user interface 1003 may also include a standard wired interface and a wireless interface. The network interface 1004 may optionally include a standard wired interface and a wireless interface (such as a wireless fidelity (Wireless-Fidelity, Wi-Fi) interface). The memory 1005 may be a high-speed random access memory (Random Access Memory, RAM), or a stable non-volatile memory (Non-Volatile Memory, NVM), such as a disk memory. The memory 1005 may also be a storage device independent of the aforementioned processor 1001.

[0053] Those skilled in the art will understand that Figure 1 The structure shown in the figure does not constitute a limitation on the visual positioning device for a lawn mower, and may include more or less components than those shown in the figure, or combine certain components, or arrange the components differently.

[0054] like Figure 1 As shown, the memory 1005 as a storage medium may include an operating system, a network communication module, a user interface module, and a lawn mower visual positioning program.

[0055] exist Figure 1 In the lawn mower visual positioning device shown, the network interface 1004 is mainly used for data communication with the network server; the user interface 1003 is mainly used for data interaction with the user; the processor 1001 and the memory 1005 in the lawn mower visual positioning device of the present invention can be set in the lawn mower visual positioning device, and the lawn mower visual positioning device calls the lawn mower visual positioning program stored in the memory 1005 through the processor 1001, and executes the lawn mower visual positioning method provided by the embodiment of the present invention.

[0056] The embodiment of the present invention provides a lawn mower visual positioning method, referring to Figure 2 , Figure 2 It is a flow chart of the first embodiment of the lawn mower visual positioning method of the present invention.

[0057] In this embodiment, the lawn mower visual positioning method includes the following steps:

[0058] Step S10: visually inspect the sign positioning stakes on the lawn where the lawn mower is located to obtain the absolute position of the sign positioning stakes in the lawn.

[0059] It should be noted that the execution subject of the method of this embodiment can be an electronic device with visual detection and visual positioning functions, such as a lawn mower robot control computer, etc., or other electronic devices that can achieve the same or similar functions, such as the above-mentioned lawn mower visual positioning device, and this embodiment does not limit this. The above-mentioned lawn mower visual positioning device can be arranged inside the lawn mower to control the lawn mower to perform visual detection and visual positioning. Here, the above-mentioned lawn mower visual positioning device (referred to as positioning device) is used to specifically describe this embodiment and the following embodiments.

[0060] It is understandable that a lawn mower is a robotic device that can automatically mow the lawn. The lawn mower can be equipped with built-in sensor devices such as cameras and IMU modules. The cameras and IMU modules can detect the external environment, and the machine can move autonomously within a predetermined area and cut the lawn with a razor or blade.

[0061] It should be understood that the signpost is a device set on the lawn for identification, positioning and indication. The signpost can be customized with special identification, such as a specific rectangular frame and texture, which is not limited in this embodiment. Multiple customized signposts are evenly installed around the lawn. The positioning device can detect the rectangular frame of the signpost in real time to ensure that the camera can occasionally capture the signpost when the lawn mower is working, so as to locate the lawn mower.

[0062] It should be understood that the absolute position and posture of the sign refers to the precise position and posture information of the sign's positioning stake in the three-dimensional space of the lawn, which is used to describe the accurate position (translation) and direction (rotation) of the sign relative to the lawn's global reference coordinate system. By analyzing the feature points or patterns on the sign's positioning stake, combined with the data collected by the lawn mower's camera or sensor, the absolute position and posture of the sign's positioning stake in the lawn can be calculated, thereby realizing the positioning of the sign's positioning stake in the lawn.

[0063] In a specific implementation, the positioning device can perform visual detection of the signboard positioning stakes on the lawn through the camera and IMU module carried by the lawn mower. By analyzing the feature points or patterns on the signboard positioning stakes and combining the data collected by the camera and IMU module of the lawn mower, the absolute position of the signboard positioning stakes in the lawn can be calculated, thereby realizing the positioning of the signboard positioning stakes in the lawn.

[0064] Step S20: when the lawn mower is in a mowing task, based on the signboard positioning pile, the absolute position of the lawn mower corresponding to the lawn mower is determined by the absolute position of the signboard.

[0065] It should be noted that the mowing task refers to placing a lawn mower in the area where the lawn needs to be mowed and allowing it to mow automatically. In the mowing task, the lawn mower usually works according to a preset mode, such as traveling along a fixed path, mowing at a set height, and automatically detouring when encountering obstacles. The surrounding environment can be sensed by laser sensors, ultrasonic sensors, cameras, etc. to avoid colliding with obstacles or injuring people, ensuring the safety of the mowing process. By handing over the mowing task to the lawn mower, the labor and time costs of manual lawn mowing can be saved, and the lawn can be mowed efficiently.

[0066] It is understandable that the absolute position and posture of the lawn mower refers to the precise position and posture information of the lawn mower in the three-dimensional space of the lawn, which is used to describe the accurate position (translation) and direction (rotation) of the lawn mower relative to the global reference coordinate system of the lawn. By analyzing the characteristic points or patterns of the lawn mower at different angles relative to the positioning stakes of the sign, combined with the data collected by the camera or sensor of the lawn mower, the absolute position and posture of the lawn mower in the lawn can be calculated, thereby realizing the positioning of the lawn mower in the lawn.

[0067] The absolute position of the mower can be used to locate and navigate the mower, so that the mower can move and operate accurately and cover the entire lawn area. It can also be used for map construction and area division, so that the mower can work according to the preset area, to ensure that the mower can effectively and safely complete the mowing task during the work process, and improve the efficiency and quality of lawn maintenance.

[0068] In a specific implementation, the positioning device can detect the sign positioning stakes in real time when the lawn mower is in a mowing task. When the sign positioning stakes are detected, the position of the sign relative to the camera is calculated, and the absolute position of the lawn mower in the lawn is calculated based on the absolute position of the sign, thereby realizing the positioning of the lawn mower in the lawn.

[0069] Step S30: globally optimizing the absolute pose of the lawn mower and the visual inertial pose of the camera of the lawn mower to obtain a re-visual positioning pose.

[0070] It should be noted that the Camera Visual Inertial Odometry (VIO) estimates the motion and position of the camera in the three-dimensional space of the lawn by fusing data from the camera and inertial sensors (such as gyroscopes and accelerometers). VIO pose combines the advantages of camera vision and inertial sensors, using the image features observed by the lawn mower's camera and the accelerometer and gyroscope data measured by the inertial sensors, and uses a nonlinear optimization algorithm to calculate the camera's accurate position and attitude information in the lawn space. Through the camera visual inertial pose, the approximate pose of the lawn mower in the lawn can be obtained to achieve approximate motion tracking of the lawn mower.

[0071] Due to the cumulative error of VIO pose, the error of VIO pose gradually increases after long-term operation and may exceed the available range of the lawn mower. At this time, it is necessary to reposition the absolute pose of the lawn mower in the lawn calculated by the signboard to eliminate the cumulative error and obtain the re-visual positioning pose.

[0072] In the specific implementation, considering the cumulative error of VIO pose, the VIO pose error of long-term operation gradually increases and may exceed the available range of the lawn mower. At this time, the positioning device can globally optimize the absolute pose of the lawn mower and the visual inertial pose of the camera of the lawn mower to obtain a more accurate re-visual positioning pose, thereby solving the problem of cumulative drift of the lawn mower during positioning.

[0073] The positioning device of this embodiment can perform visual detection of the signboard positioning stakes on the lawn through the camera and IMU module carried by the lawn mower. By analyzing the feature points or patterns on the signboard positioning stakes, combined with the data collected by the camera and IMU module of the lawn mower, the absolute position and posture of the signboard of the signboard positioning stake in the lawn can be calculated, thereby realizing the positioning of the signboard positioning stake in the lawn. Then, when the lawn mower is in the mowing task, the signboard positioning stake can be detected in real time. When the signboard positioning stake is detected, the position and posture of the signboard relative to the camera are calculated, and the absolute position and posture of the lawn mower in the lawn are calculated based on the absolute position and posture of the signboard, thereby realizing the positioning of the lawn mower in the lawn. Considering that there is a cumulative error in the VIO pose, the error of the VIO pose that runs for a long time gradually increases and may exceed the available range of the lawn mower. Finally, the absolute pose of the lawn mower and the visual inertial pose of the camera of the lawn mower can be globally optimized to obtain a more accurate re-visual positioning pose, thereby solving the problem of cumulative drift of the lawn mower during positioning. Since this embodiment uses the absolute posture of the lawn signboard positioning stake to determine the absolute posture of the lawn mower, and finally performs global optimization with the visual inertial posture of the lawn mower's camera, it avoids the situation where the lawn mower's positioning is prone to cumulative drift in an environment where the RTK signal is blocked. The traditional visual slam positioning is further optimized to obtain a more accurate re-visual positioning posture, which effectively solves the problem of cumulative drift.

[0074] refer to Figure 3 , Figure 3 It is a flow chart of the second embodiment of the lawn mower visual positioning method of the present invention.

[0075] Based on the above first embodiment, in this embodiment, step S10 includes:

[0076] Step S11: Perform environmental detection on the lawn where the lawn mower is located to obtain an environmental map corresponding to the lawn.

[0077] It should be noted that the environmental map is a map model that models and represents the spatial and geographic information of the lawn where the lawn mower is located. The lawn mower collects and integrates sensor data, geographic information and other relevant data to present objects, structures, features and other information in the lawn environment in a visual way. By establishing an environmental map, the lawn mower can achieve functions such as precise positioning and path planning.

[0078] Step S12: visually inspecting the signboard positioning stakes of the lawn to obtain the relative position of the signboard between the signboard positioning stakes and the lawn mower, wherein the signboard positioning stakes are pre-installed within a preset range of the lawn.

[0079] It should be noted that the relative posture of the sign refers to the motion posture and position relationship of the sign positioning post relative to the lawn mower, and describes the relative position and rotation relationship between the lawn mower's camera and the sign positioning post in three-dimensional space.

[0080] When the lawn mower's camera captures an image of the sign post, image processing and computer vision techniques are used to estimate the relative pose between the camera and the sign. Accurate pose tracking can be achieved by accurately estimating the relative pose between the camera and the sign post.

[0081] It is understandable that the preset range is the range where the sign positioning stakes are installed in the lawn and the camera can occasionally capture the range when the lawn mower is working, such as the center position of the lawn or the surrounding edge positions. The preset range can be determined based on specific needs and design requirements, and this embodiment does not limit this.

[0082] Multiple customized sign stakes can be evenly installed around the lawn, and the positioning device can detect the rectangular frame of the sign stakes in real time to ensure that the camera can capture the sign stakes from time to time when the lawn mower is working, so as to position the lawn mower.

[0083] Step S13: Based on the environment map, the relative position of the signboard is solved to obtain the absolute position of the signboard of the signboard positioning stake in the lawn.

[0084] For ease of understanding, the settlement of the absolute position of the sign is used as an example for explanation, but this embodiment is not limited. During the construction of the lawn mower edge map, the positioning device will calculate the absolute position T_w_c of the key frame in the map in real time through the camera and sensor data. At the same time, the positioning device will detect the sign positioning stake and calculate the position T_c_m of the sign positioning stake relative to the camera. Then the absolute position T_w_m of the sign positioning stake in the map = T_w_c * T_c_m.

[0085] Furthermore, the position of the signpost relative to the camera can be stored in the positioning device, and loop optimization can be performed again along the edge to re-observe the previously observed landmarks or repeated features to perform map consistency correction and optimization. Finally, based on the optimized keyframe position and the position of the signpost relative to the camera, the absolute position of the signpost in the map is calculated.

[0086] In the specific implementation, after the sign positioning stakes are installed, the positioning device can start the lawn mower, drive along the edge of the lawn, and establish an environmental map through the lawn mower's camera and IMU module. At the same time, the sign positioning stakes are detected. When the sign positioning stakes are detected, the relative position of the sign relative to the camera is calculated, and the absolute position of each sign positioning stake in the map is calculated based on the camera key frame pose. Thus, by establishing an environmental map and sign positioning stakes, the lawn mower can be accurately positioned.

[0087] Furthermore, before step S12, the present embodiment also includes: detecting the signboard on the lawn to obtain a rectangular frame area of ​​the signboard; performing feature extraction on an area of ​​interest in the rectangular frame area to obtain matching feature points of the signboard; determining whether the matching feature points match a preset positioning pile template; and if so, determining that the signboard matching the preset positioning pile template is a signboard positioning pile.

[0088] Considering that there are not only pre-set sign positioning stakes on the lawn, but also public welfare signs, road signs and other signs, it is necessary to identify the signs on the lawn first.

[0089] It should be noted that the rectangular frame area is a rectangular boundary box drawn when locating and identifying the sign. When using image processing and computer vision algorithms to detect and identify the sign, a specific algorithm can be used first to find the rectangular frame area in the image. The rectangular frame area can assist the recognition algorithm in more accurately determining the location and boundaries of the sign.

[0090] It is understandable that the region of interest (ROI) is a portion of the image area that is centrally processed and analyzed for a specific target or region of interest in the image processing of the rectangular frame area. The region of interest can be a rectangular, circular or polygonal area, etc., and this embodiment does not limit this. By defining the region of interest, the positioning device can focus on the key area to identify the sign, reduce the amount of calculation and improve the processing efficiency.

[0091] It should be understood that the feature points are matched to extract features of the region of interest, and the obtained feature points, such as corner points, edges, spots, etc., can be used as feature points. Then, a matching algorithm (such as orb feature point matching algorithm, sift feature point matching algorithm, surf feature point matching algorithm and other feature point matching algorithms) is used to compare and describe the similarity between the matching feature points and find the best matching pair.

[0092] It should be noted that the preset positioning pile template is a template used to determine the positioning piles of the signboard. By matching the matching feature points of the signboard with the preset positioning pile template, the positioning piles of the signboard can be quickly determined.

[0093] In the specific implementation, considering that there are not only pre-set signboard positioning stakes on the lawn, but also public welfare signs, road signs and other signs, it is necessary to identify the signs on the lawn first. Since there are specific rectangular frames and textures on the customized signboard positioning stakes, the positioning device can detect the rectangular frame area of ​​the signboard in real time, and filter out the rectangular frames that do not meet the conditions through the aspect ratio of the rectangular frame area. Then extract the region of interest of the filtered rectangular frame area, perform feature extraction on the region of interest, and obtain the matching feature points of the signboard. Finally, perform feature matching with the preset positioning stake template, and a successful match means that the signboard positioning stake is successfully detected. Through the region of interest, the positioning device can focus on the key area to identify the signboard, reduce the amount of calculation and improve processing efficiency.

[0094] Furthermore, in this embodiment, step S12 includes: visually inspecting the signboard positioning stakes on the lawn to obtain the current frame of the signboard positioning stakes; performing matrix transformation on the matching feature points corresponding to the current frame and the preset positioning stake template to obtain the homography matrix between the current frame and the preset positioning stake template; performing homography transformation on the template two-dimensional points preset on the preset positioning stake template according to the homography matrix to obtain the frame two-dimensional points corresponding to the current frame; performing data processing on the three-dimensional distance between the frame two-dimensional points and the template two-dimensional points through the PNP algorithm to obtain the relative posture of the signboard between the signboard positioning stake and the lawn mower.

[0095] It should be noted that the homography matrix, also called the homography transformation matrix, is used to project the plane described by the current image frame onto the plane described by the preset positioning pile template. The current image frame and the preset positioning pile template can be aligned through the homography matrix.

[0096] It is understandable that the PNP algorithm (Perspective-n-Point) is a method for calculating the camera pose, which can be used to calculate the rotation and translation pose of the sign based on the known two-dimensional points of the image frame and the two-dimensional points of the template. In simple terms, the position and orientation of the sign in the environment map can be inferred based on the position of the point on the image.

[0097] In actual implementation, when the signboard positioning stake is successfully detected, the positioning device can perform visual detection on the signboard positioning stake of the lawn to obtain the current image frame of the signboard positioning stake. Then, the homography matrix of the current image frame and the preset positioning stake template is calculated through the above-mentioned matching feature points, and the four two-dimensional points pre-set on the preset positioning stake template are transformed through the homography transformation to obtain the four two-dimensional points corresponding to the current image frame. Then, the relative pose of the signboard of the signboard positioning stake relative to the camera is calculated through the PNP algorithm through the pre-measured three-dimensional distances corresponding to the four points on the preset positioning stake template. Thus, the alignment between the current image frame and the preset positioning stake template is achieved through the homography matrix, and the relative pose of the signboard of the signboard positioning stake relative to the camera is quickly determined.

[0098] After the signboard positioning piles of this embodiment are installed, the positioning device can start the lawn mower, drive along the edge of the lawn, and establish an environmental map through the camera and IMU module of the lawn mower. At the same time, the signboard positioning piles are detected. When the signboard positioning piles are detected, the relative pose of the signboard of the signboard positioning piles relative to the camera is calculated, and the absolute pose of the signboard of each signboard positioning pile in the map is calculated based on the key frame pose of the camera. Thus, by establishing an environmental map and a signboard positioning pile, the precise positioning of the lawn mower can be achieved. Further, considering that there are not only pre-set signboard positioning piles on the lawn, but also public welfare signs, road signs and other signs, it is necessary to first identify the signs on the lawn. Since there are specific rectangular frames and textures on the customized signboard positioning piles, the positioning device can detect the rectangular frame area of ​​the signboard in real time, and filter out the rectangular frames that do not meet the conditions through the aspect ratio of the rectangular frame area. Then extract the area of ​​interest of the filtered rectangular frame area, perform feature extraction on the area of ​​interest, and obtain the matching feature points of the signboard. Finally, feature matching is performed with the preset positioning pile template. If the match is successful, it means that the signboard positioning pile is successfully detected. Through the region of interest, the positioning device can focus the recognition of the signboard on the key area, reduce the amount of calculation and improve the processing efficiency. Furthermore, when the signboard positioning stake is successfully detected, the positioning device can perform visual detection on the signboard positioning stake of the lawn to obtain the current frame of the signboard positioning stake. Then, the homography matrix of the current frame and the preset positioning stake template is calculated through the above-mentioned matching feature points, and the four two-dimensional points pre-set on the preset positioning stake template are transformed through the homography transformation to obtain the four two-dimensional points corresponding to the current frame. Then, through the pre-measured three-dimensional distances corresponding to the four points on the preset positioning stake template, the relative pose of the signboard of the signboard positioning stake relative to the camera is calculated through the PNP algorithm. Therefore, the alignment between the current frame and the preset positioning stake template is achieved through the homography matrix, and the relative pose of the signboard of the signboard positioning stake relative to the camera is quickly determined.

[0099] refer to Figure 4 , Figure 4It is a flow chart of the third embodiment of the lawn mower visual positioning method of the present invention.

[0100] Based on the above embodiments, in this embodiment, step S20 includes:

[0101] Step S21: when the lawn mower is in a mowing task, determining whether the signboard positioning stake is within the visual range of the lawn mower.

[0102] It should be noted that the visual range is the range within which the mower observes and perceives the surrounding environment, which can be achieved by installing cameras or other sensor technologies. Generally, the visual range of a mower should cover the area in front of and to the sides of the mower so that obstacles, boundary lines and other important objects can be perceived in a timely manner. This ensures that the mower can avoid collisions during movement and complete the mowing task in the correct area.

[0103] Step S22: If yes, then based on the sign post, the relative position of the lawn mower between the lawn mower and the sign post is obtained.

[0104] It should be noted that the relative posture of the lawn mower refers to the motion posture and position relationship of the lawn mower relative to the sign post, and describes the relative position and rotation relationship between the lawn mower's camera and the sign post in three-dimensional space.

[0105] When the lawn mower's camera captures an image of the sign post, image processing and computer vision techniques are used to estimate the relative pose between the camera and the sign. Accurate pose tracking can be achieved by accurately estimating the relative pose between the camera and the sign post.

[0106] Step S23: Calculate the relative posture of the lawn mower and the absolute posture of the signboard to obtain the absolute posture of the lawn mower in the lawn.

[0107] In a specific implementation, when the lawn mower is in a mowing task, the positioning device may first determine whether the signboard positioning post is within the visual range of the lawn mower. When the signboard positioning post is detected in real time, the relative posture of the lawn mower between the lawn mower and the signboard positioning post is determined based on the signboard positioning post. Finally, the absolute posture of the lawn mower in the map is solved by calculating the relative posture of the lawn mower with respect to the signboard positioning post and the absolute posture of the signboard with respect to the signboard positioning post in the map. Thus, accurate posture tracking can be achieved by accurately estimating the relative posture of the lawn mower's camera and the signboard positioning post.

[0108] Furthermore, in this embodiment, after step S21, it also includes: when the signboard positioning pile is not within the visual range, turning on the camera and IMU sensor of the lawn mower; based on the camera and IMU sensor, obtaining the camera visual inertial posture of the lawn mower in the lawn; and controlling the lawn mower to perform the mowing task according to a preset planned path according to the camera visual inertial posture.

[0109] It should be noted that IMU sensor refers to inertial measurement unit sensor, which can be used to measure and detect the acceleration and angular velocity of an object. The IMU sensor can be used to estimate the attitude, position and motion state of an object on the lawn to achieve attitude tracking of the object on the lawn.

[0110] It is understandable that the preset planning path is a path that the lawn mower pre-sets for mowing operations when performing mowing tasks. By performing mowing tasks according to the preset planning path, the lawn mower can efficiently cover vegetation within a specified range, maintain the uniformity and effect of mowing, and can accurately stop or return to the base, thereby improving the automation and accuracy of mowing operations.

[0111] In a specific implementation, when the signboard positioning stake is not detected, the positioning device can turn on the camera and IMU sensor of the lawn mower. Through the camera and IMU sensor, the camera visual inertial pose of the lawn mower in the lawn is output. Finally, according to the camera visual inertial pose, the lawn mower is controlled to perform the mowing task according to the preset planned path. Therefore, when the signboard positioning stake is not detected, the posture, position and motion state of the object on the lawn are estimated by the IMU sensor to achieve positioning.

[0112] Furthermore, in this embodiment, step S30 includes: obtaining the camera visual inertial pose of the lawn mower through a camera and an IMU sensor; using the camera visual inertial pose as a relative constraint and using the absolute pose of the lawn mower as an absolute constraint; constructing a current pose graph of the lawn mower with the relative constraint and the absolute constraint as targets; optimizing the current pose graph to obtain the corresponding re-visual positioning pose of the lawn mower in the current pose graph.

[0113] It should be noted that the relative constraint condition is to use the camera visual inertial pose as the condition for pose optimization, while the absolute constraint condition is to use the lawn mower's absolute pose as the condition for pose optimization.

[0114] In the specific implementation, the camera visual inertial pose output by the positioning device through the camera and IMU sensor is used as a relative constraint, and the absolute pose of the lawn mower solved by the sign is used as an absolute constraint. Together, the current pose graph is constructed for optimization to obtain a more accurate re-visual positioning pose. This enables absolute positioning based on the sign positioning stakes, effectively solving the problem of cumulative drift.

[0115] In this embodiment, when the lawn mower is in the mowing task, the positioning device can first determine whether the signboard positioning pile is within the visual range of the lawn mower. When the signboard positioning pile is detected in real time, the relative posture of the lawn mower between the lawn mower and the signboard positioning pile is determined based on the signboard positioning pile. Finally, the absolute posture of the lawn mower in the map is solved by calculating the relative posture of the lawn mower relative to the signboard positioning pile of the camera and the signboard absolute posture of the signboard positioning pile in the map. Thus, by accurately estimating the relative posture of the lawn mower camera and the signboard positioning pile, accurate posture tracking can be achieved. Further, when the signboard positioning pile is not detected, the positioning device can turn on the camera and IMU sensor of the lawn mower. Through the camera and IMU sensor, the camera visual inertial posture of the lawn mower in the lawn is output. Finally, according to the camera visual inertial posture, the lawn mower is controlled to perform the mowing task according to the preset planned path. Thus, when the signboard positioning pile is not detected, the posture, position and motion state of the object on the lawn are estimated by the IMU sensor to achieve positioning. Furthermore, the camera visual inertial pose output by the positioning device through the camera and IMU sensor is used as a relative constraint, and the absolute pose of the lawn mower calculated by the sign is used as an absolute constraint. Together, the current pose graph is constructed for optimization to obtain a more accurate re-visual positioning pose. This enables absolute positioning based on the sign positioning stakes, effectively solving the problem of cumulative drift.

[0116] In addition, an embodiment of the present invention further proposes a storage medium, on which a lawn mower visual positioning program is stored. When the lawn mower visual positioning program is executed by a processor, the steps of the lawn mower visual positioning method described above are implemented.

[0117] Reference Figure 5 , Figure 5 This is a structural block diagram of the first embodiment of the lawn mower visual positioning device of the present invention.

[0118] like Figure 5 As shown, the lawn mower visual positioning device proposed in the embodiment of the present invention includes:

[0119] The sign detection module 501 is used to visually detect the sign positioning stakes on the lawn where the lawn mower is located, and obtain the absolute position of the sign positioning stakes in the lawn;

[0120] A posture determination module 502 is used to determine the absolute posture of the lawn mower corresponding to the lawn mower through the absolute posture of the sign based on the sign positioning pile when the lawn mower is in a mowing task;

[0121] The visual positioning module 503 is used to globally optimize the absolute posture of the lawn mower and the visual inertial posture of the camera of the lawn mower to obtain a re-visual positioning posture.

[0122] The positioning device of this embodiment can perform visual detection of the signboard positioning stakes on the lawn through the camera and IMU module carried by the lawn mower. By analyzing the feature points or patterns on the signboard positioning stakes, combined with the data collected by the camera and IMU module of the lawn mower, the absolute position and posture of the signboard of the signboard positioning stake in the lawn can be calculated, thereby realizing the positioning of the signboard positioning stake in the lawn. Then, when the lawn mower is in the mowing task, the signboard positioning stake can be detected in real time. When the signboard positioning stake is detected, the position and posture of the signboard relative to the camera are calculated, and the absolute position and posture of the lawn mower in the lawn are calculated based on the absolute position and posture of the signboard, thereby realizing the positioning of the lawn mower in the lawn. Considering that there is a cumulative error in the VIO pose, the error of the VIO pose that runs for a long time gradually increases and may exceed the available range of the lawn mower. Finally, the absolute pose of the lawn mower and the visual inertial pose of the camera of the lawn mower can be globally optimized to obtain a more accurate re-visual positioning pose, thereby solving the problem of cumulative drift of the lawn mower during positioning. Since this embodiment uses the absolute posture of the lawn signboard positioning stake to determine the absolute posture of the lawn mower, and finally performs global optimization with the visual inertial posture of the lawn mower's camera, it avoids the situation where the lawn mower's positioning is prone to cumulative drift in an environment where the RTK signal is blocked. The traditional visual slam positioning is further optimized to obtain a more accurate re-visual positioning posture, which effectively solves the problem of cumulative drift.

[0123] Based on the above-mentioned first embodiment of the lawn mower vision positioning device of the present invention, a second embodiment of the lawn mower vision positioning device of the present invention is proposed.

[0124] In this embodiment, the sign detection module 501 is also used to perform environmental detection on the lawn where the lawn mower is located to obtain an environmental map corresponding to the lawn; perform visual detection on the sign positioning stakes of the lawn to obtain the relative position of the sign between the sign positioning stakes and the lawn mower, the sign positioning stakes being pre-installed within a preset range of the lawn; based on the environmental map, the relative position of the sign is solved to obtain the absolute position of the sign of the sign positioning stakes in the lawn.

[0125] Furthermore, the sign detection module 501 is also used to detect the sign on the lawn and obtain the rectangular frame area of ​​the sign; perform feature extraction on the area of ​​interest in the rectangular frame area to obtain matching feature points of the sign; determine whether the matching feature points match the preset positioning pile template; if so, determine that the sign matching the preset positioning pile template is the sign positioning pile.

[0126] Furthermore, the sign detection module 501 is also used to perform visual detection on the sign positioning stakes on the lawn to obtain the current frame of the sign positioning stakes; perform matrix transformation on the matching feature points corresponding to the current frame and the preset positioning stake template to obtain the homography matrix between the current frame and the preset positioning stake template; perform homography transformation on the template two-dimensional points preset on the preset positioning stake template according to the homography matrix to obtain the frame two-dimensional points corresponding to the current frame; perform data processing on the three-dimensional distance between the frame two-dimensional points and the template two-dimensional points through the PNP algorithm to obtain the relative posture of the sign between the sign positioning stake and the lawn mower.

[0127] Furthermore, the posture determination module 502 is also used to determine whether the signboard positioning post is within the visual range of the lawn mower when the lawn mower is in a mowing task; if so, the relative posture of the lawn mower between the lawn mower and the signboard positioning post is obtained based on the signboard positioning post; the relative posture of the lawn mower and the absolute posture of the signboard are solved to obtain the absolute posture of the lawn mower in the lawn.

[0128] Furthermore, the visual positioning module 503 is also used to turn on the camera and IMU sensor of the lawn mower when the signboard positioning post is not within the visual range; based on the camera and IMU sensor, obtain the camera visual inertial position of the lawn mower in the lawn; and control the lawn mower to perform mowing tasks according to a preset planned path according to the camera visual inertial position.

[0129] Furthermore, the visual positioning module 503 is also used to obtain the camera visual inertial pose of the lawn mower through a camera and an IMU sensor; use the camera visual inertial pose as a relative constraint and the absolute pose of the lawn mower as an absolute constraint; construct a current pose graph of the lawn mower with the relative constraint and the absolute constraint as targets; optimize the current pose graph to obtain the corresponding re-visual positioning pose of the lawn mower in the current pose graph.

[0130] Other embodiments or specific implementations of the lawn mower visual positioning device of the present invention can refer to the above-mentioned method embodiments, which will not be described in detail here.

[0131] It should be noted that, in this article, the terms "include", "comprises" or any other variations thereof are intended to cover non-exclusive inclusion, so that a process, method, article or system including a series of elements includes not only those elements, but also other elements not explicitly listed, or also includes elements inherent to such process, method, article or system. In the absence of further restrictions, an element defined by the sentence "comprises a ..." does not exclude the existence of other identical elements in the process, method, article or system including the element.

[0132] The serial numbers of the above embodiments of the present invention are only for description and do not represent the advantages or disadvantages of the embodiments.

[0133] Through the description of the above implementation methods, those skilled in the art can clearly understand that the above-mentioned embodiment methods can be implemented by means of software plus a necessary general hardware platform, and of course by hardware, but in many cases the former is a better implementation method. Based on such an understanding, the technical solution of the present invention, or the part that contributes to the prior art, can be embodied in the form of a software product, which is stored in a storage medium (such as a read-only memory / random access memory, a magnetic disk, or an optical disk), and includes a number of instructions for enabling a terminal device (which can be a mobile phone, a computer, a server, or a network device, etc.) to execute the methods described in each embodiment of the present invention.

[0134] The above are only preferred embodiments of the present invention, and are not intended to limit the patent scope of the present invention. Any equivalent structure or equivalent process transformation made using the contents of the present invention specification and drawings, or directly or indirectly applied in other related technical fields, are also included in the patent protection scope of the present invention.

Claims

1. A lawn mower visual positioning method, characterized in that: The lawn mower visual positioning method comprises: Performing visual inspection on the signboard positioning stakes of the lawn where the lawn mower is located to obtain the absolute position of the signboard positioning stakes in the lawn; When the lawn mower is in a mowing task, based on the signboard positioning pile, the absolute position of the lawn mower corresponding to the lawn mower is determined by the absolute position of the signboard; Globally optimizing the absolute pose of the lawn mower and the visual inertial pose of the camera of the lawn mower to obtain a re-visual positioning pose; Among them, the visual detection of the signboard positioning stake of the lawn where the lawn mower is located to obtain the absolute position of the signboard of the signboard positioning stake in the lawn includes: performing environmental detection on the lawn where the lawn mower is located through the camera and IMU module carried by the lawn mower to obtain the environmental map corresponding to the lawn; detecting the signboard on the lawn to obtain the rectangular frame area and texture of the signboard; filtering out the rectangular frames that do not meet the conditions through the aspect ratio of the rectangular frame area, and extracting features of the screened rectangular frame area and the area of ​​interest of the texture to obtain the matching feature points of the signboard, and the matching feature points include corner points, edges, and spots; through orb feature points The matching algorithm determines whether the matching feature point matches the preset positioning pile template; if so, the signboard matching the preset positioning pile template is determined to be the signboard positioning pile; the signboard positioning pile of the lawn is visually detected to obtain the relative posture of the signboard between the signboard positioning pile and the lawn mower, the relative posture of the signboard includes the relative position and rotation relationship between the camera of the lawn mower and the signboard positioning pile, and the signboard positioning pile is pre-equivalently installed within the preset range of the lawn; based on the environmental map, the relative posture of the signboard is solved to obtain the absolute posture of the signboard of the signboard positioning pile in the lawn, which is solved as: T_w_m = T_w_c * T_c_m; Among them, T_w_m is the absolute position of the signboard, T_w_c is the absolute position of the key frame of the camera in the environment map, and T_c_m is the relative position of the signboard.

2. The lawn mower visual positioning method according to claim 1, characterized in that: The visual detection of the signboard positioning stakes of the lawn to obtain the relative position of the signboard between the signboard positioning stakes and the lawn mower includes: Performing visual inspection on the signboard positioning stakes of the lawn to obtain a current image frame of the signboard positioning stakes; Performing matrix transformation on the matching feature points corresponding to the current image frame and the preset positioning pile template to obtain a homography matrix between the current image frame and the preset positioning pile template; Performing homography transformation on the preset template two-dimensional points on the preset positioning pile template according to the homography matrix to obtain the frame two-dimensional points corresponding to the current frame; The three-dimensional distance between the two-dimensional point of the image frame and the two-dimensional point of the template is processed by the PNP algorithm to obtain the relative position of the sign between the sign positioning pile and the lawn mower.

3. The lawn mower visual positioning method according to claim 1, characterized in that: When the lawn mower is in a mowing task, based on the signboard positioning pile, determining the absolute position of the lawn mower corresponding to the lawn mower through the absolute position of the signboard, includes: When the lawn mower is in a mowing task, determining whether the signboard positioning stake is within the visual range of the lawn mower; If yes, then based on the signboard positioning stake, obtaining the relative position of the lawn mower between the lawn mower and the signboard positioning stake; The relative posture of the lawn mower and the absolute posture of the sign are solved to obtain the absolute posture of the lawn mower in the lawn.

4. The lawn mower visual positioning method according to claim 3, characterized in that: When the lawn mower is in a mowing task, after determining whether the signboard positioning pile is within the visual range of the lawn mower, the method further includes: When the signboard positioning stake is not within the visual range, turning on the camera and IMU sensor of the lawn mower; Based on the camera and the IMU sensor, obtaining a camera visual inertial position of the lawn mower within the lawn; The lawn mower is controlled according to the visual inertial posture of the camera to perform a mowing task along a preset planned path.

5. The lawn mower visual positioning method according to any one of claims 1 to 4, characterized in that: The step of globally optimizing the absolute posture of the lawn mower and the visual inertial posture of the camera of the lawn mower to obtain the re-visual positioning posture includes: Acquire the camera visual inertial pose of the lawn mower through a camera and an IMU sensor; Using the visual inertial pose of the camera as a relative constraint and the absolute pose of the lawn mower as an absolute constraint; Taking the relative constraint condition and the absolute constraint condition as targets, constructing a current pose graph of the lawn mower; The current pose graph is optimized to obtain a re-visual positioning pose corresponding to the lawn mower in the current pose graph.

6. A lawn mower visual positioning device, characterized in that: The device applies the lawn mower visual positioning method according to any one of claims 1 to 5, and the device comprises: A sign detection module is used to perform visual detection on the sign positioning stakes of the lawn where the lawn mower is located, and obtain the absolute position of the sign positioning stakes in the lawn; A posture determination module, used for determining the absolute posture of the lawn mower corresponding to the lawn mower through the absolute posture of the sign based on the sign positioning pile when the lawn mower is in a mowing task; The visual positioning module is used to globally optimize the absolute posture of the lawn mower and the visual inertial posture of the camera of the lawn mower to obtain a re-visual positioning posture.

7. A lawn mower visual positioning device, characterized in that: The device comprises: a memory, a processor, and a lawn mower vision positioning program stored in the memory and executable on the processor, wherein the lawn mower vision positioning program is configured to implement the steps of the lawn mower vision positioning method according to any one of claims 1 to 5.

8. A storage medium, characterized in that: The storage medium stores a lawn mower vision positioning program, and when the lawn mower vision positioning program is executed by the processor, the steps of the lawn mower vision positioning method according to any one of claims 1 to 5 are implemented.

Citation Information

Patent Citations

  • Method and device for optimizing relative precision map, and storage medium

    CN108520543A

  • Distributed device mapping

    CN110537078A

  • Information prompting method and device, terminal equipment and computer readable storage medium

    CN111198608A

  • Mobile robot pose measurement method and system for large-scale multi-site scene

    CN112045655A

  • Method and device for establishing beacon map based on visual beacons

    CN112183171A