Method for straightening map
Through the map straightening method, the problems of map tilt and user terminal display difficulty created by the cleaning robot are solved, and standardized adjustment and user-friendly display of the map are achieved.
Patent Information
- Application Number
- PCT/CN2023/111961
- Authority / Receiving Office
- WO · WO
- Patent Type
- Applications
- Current Assignee / Owner
- Priority Date
- 2023-04-18
- Filing Date
- 2023-08-09
- Publication Date
- 2024-10-24
AI Technical Summary
The map initially constructed by the cleaning robot may be tilted, which affects subsequent positioning and movement decisions, and the orientation of the map received by the user terminal is inconsistent, making the display more difficult.
The map straightening method is used to obtain the boundary information of the map, distinguish the orthogonal line groups, calculate the relationship between the reference ratio and the judgment threshold, establish a plane rectangular coordinate system, straighten the map, and output the straightened boundary information.
The map adjustment method is standardized to adapt the map to the user's observation habits, reduce the difficulty of complete map display, and improve the accuracy and consistency of map alignment.
Smart Images

Figure CN2023111961_24102024_PF_FP_ABST
Abstract
Description
Map alignment method Technical Field
[0001] The present application relates to the field of robotics, and in particular to a map correction method. Background Art
[0002] In existing technologies, cleaning robots can use LiDAR ranging technology to create maps of their surroundings, facilitating positioning and navigation during the subsequent cleaning process. However, the positive orientation of the cleaning robot's initial map construction is typically based on its own first-person perspective. Due to the cleaning robot's different initial postures, the maps corresponding to the same area may not have the same orientation after initial formation or alignment based on the initial posture. This results in different orientations of the maps received by the user terminal, posing a significant challenge to the user terminal's display unit.
[0003] In existing technologies, cleaning robots typically use SLAM (simultaneous localization and mapping) technology to construct a map of their surroundings. However, this map is typically constructed from the robot's initial position at startup. This method can create a tilted map, which can hinder subsequent positioning and motion decision-making, thereby impacting the robot's efficiency.
[0004] Therefore, there is an urgent need for a method to correct the map, which can reduce the difficulty of complete display of the display unit while ensuring the consistency of the correction results, so that users can obtain the corrected map and reduce the difficulty of users understanding the map.
[0005] Summary of the Invention
[0006] The purpose of this application is to provide a map correction method to achieve the correction operation of the map, standardize the map adjustment method, enable the map to adapt to the user's observation habits, and help reduce the difficulty of complete display of the map.
[0007] To achieve this goal, this application adopts the following technical solutions:
[0008] The map straightening method comprises the following steps:
[0009] S10: Acquire boundary information of the map, the boundary information including state information of boundary lines and a total length of the boundary, the total length of the boundary being configured as the sum of the lengths of all the boundary lines;
[0010] S20: Summarize all the boundary lines that meet the preset conditions into an orthogonal line group;
[0011] S30: Determine the relationship between the reference ratio and the determination threshold. If the first relationship is satisfied, proceed to S40; if the second relationship is satisfied, proceed to S50. The reference ratio is the ratio of the maximum boundary line length to the total boundary length. The boundary line length is defined as the sum of the lengths of all boundary lines in one orthogonal line group.
[0012] S40: Establishing a plane rectangular coordinate system according to the first reference, and then proceeding to S60;
[0013] S50: Establishing a plane rectangular coordinate system according to the second datum, and then proceeding to S60;
[0014] S60: Straightening the map according to the plane rectangular coordinate system, and outputting the boundary information of the straightened map to a user terminal.
[0015] As a preferred technical solution of the map straightening method, the preset condition is that the boundary lines are parallel, collinear or perpendicular to each other.
[0016] As an optimal technical solution for the map straightening method, the first relationship is that the benchmark ratio is not less than the judgment threshold, and the second relationship is that the benchmark ratio is less than the judgment threshold; the first benchmark is the boundary line corresponding to the benchmark ratio, and the second benchmark is the benchmark circumscribed rectangle.
[0017] As a preferred technical solution of the map straightening method, S20 includes the following detailed steps:
[0018] S21: Select any one of the boundary lines as a positioning line;
[0019] S22: taking all the boundary lines that are parallel, collinear, or perpendicular to the positioning line as orthogonal lines, taking the sum of the positioning line and all the orthogonal lines as the boundary line length, and calculating and recording the boundary line length;
[0020] S23: repeatedly selecting the positioning lines and calculating the lengths of the corresponding boundary lines until no more positioning lines can be selected, thereby calculating and recording the lengths of all the boundary lines;
[0021] S24: Compare and select the largest one among all the boundary line lengths, and calculate the ratio of the largest boundary line length to the total boundary length as the reference ratio.
[0022] As a preferred technical solution of the map straightening method, S23 includes the following detailed steps:
[0023] S231: Determine whether there is a boundary line that has not been used as the positioning line or the orthogonal line. If so, proceed to S232; if not, proceed to S24.
[0024] S232: Select any boundary line that has never been used as the positioning line or the orthogonal line, replace it with the positioning line, and then perform S22 again.
[0025] As a preferred technical solution of the map straightening method, S50 includes the following detailed steps:
[0026] S51: Establish a circumscribed plane rectangular coordinate system, use two long sides parallel to the X axis of the circumscribed plane rectangular coordinate system and two short sides parallel to the Y axis of the circumscribed plane rectangular coordinate system to generate a circumscribed rectangle of the figure enclosed by the boundary lines, use the area of the circumscribed rectangle as the test area, and calculate and record the test area;
[0027] S52: rotating the circumscribed plane rectangular coordinate system by a predetermined angle multiple times, selecting different circumscribed plane rectangular coordinate systems and calculating the corresponding test areas, until the circumscribed plane rectangular coordinate system is rotated 90°, so as to calculate and record all the test areas;
[0028] S53: Compare all the test areas, and use the smallest circumscribed rectangle among all the test areas as the reference circumscribed rectangle.
[0029] As a preferred technical solution of the map correction method, the following steps are further included after S10:
[0030] S11: Find the specified benchmark;
[0031] S12: Determine whether the designated reference exists. If so, correct the map according to the designated reference and output the boundary information of the corrected map to the user terminal. If not, proceed to S20.
[0032] As a preferred technical solution of the map correction method, the following steps are further included before S20:
[0033] S18: Determine whether the ratio of the length of the longest boundary line to the total boundary length is not less than the determination threshold, if so, proceed to S19, if not, proceed to S20;
[0034] S19: Establish a plane rectangular coordinate system based on the longest boundary line, and then proceed to S60.
[0035] As a preferred technical solution of the map correction method, the following steps are further included before S30:
[0036] S28: Determine whether the orthogonal line group having at least two boundary lines exists. If so, proceed to S30; if not, proceed to S50.
[0037] As a preferred technical solution of the map correction method, the following steps are further included before S30:
[0038] S29: Determine whether there are at least two parallel maximum boundary line lengths. If so, proceed to S50; if not, proceed to S30.
[0039] Beneficial effects of this application:
[0040] This map straightening method extracts and divides the boundary lines on the map into different orthogonal line groups, and can obtain the boundary line length of each orthogonal line group. After calculating the ratio of the maximum boundary line length to the total boundary length, it is compared with the judgment threshold to determine the benchmark determination method for map straightening. The above design achieves the purpose of determining the plane rectangular coordinate system, thereby completing the map straightening process, and finally straightening the map according to the determined plane rectangular coordinate system, and presenting the straightened map to the user through the user terminal. The above method determines the plane rectangular coordinate system by judging the size of the benchmark ratio, thereby realizing the map straightening operation, standardizing the map adjustment method, enabling the map to adapt to the user's observation habits, and helping to reduce the difficulty of complete map display. BRIEF DESCRIPTION OF THE DRAWINGS
[0041] FIG1 is a simplified workflow diagram of a map correction method according to an embodiment of the present application;
[0042] FIG2 is a detailed workflow diagram of the map correction method provided in an embodiment of the present application;
[0043] FIG3 is a schematic diagram of an application scenario of the map correction method provided in an embodiment of the present application;
[0044] FIG4 is a second schematic diagram of an application scenario of the map correction method provided in an embodiment of the present application;
[0045] FIG5 is a third schematic diagram of an application scenario of the map correction method provided in an embodiment of the present application.
[0046] In the figure: 110, first positioning line; 120, second positioning line; 200, reference plane rectangular coordinate system; 310, third positioning line; 320, fourth positioning line; 330, fifth positioning line; 400, circumscribed plane rectangular coordinate system; 500, first circumscribed rectangle; 600, second circumscribed rectangle; 700, third circumscribed rectangle; 800, fourth circumscribed rectangle; 900, fifth circumscribed rectangle. Specific embodiments
[0047] The following will clearly and completely describe the technical solution of this application in conjunction with the accompanying drawings. Obviously, the embodiments described are only part of the embodiments of this application, not all of them. Based on the embodiments in this application, all other embodiments obtained by ordinary technicians in this field without making any creative efforts are within the scope of protection of this application.
[0048] In the description of this application, it should be noted that the terms "center", "up", "down", "left", "right", "vertical", "horizontal", "inside", "outside" and the like indicate orientations or positional relationships based on the orientations or positional relationships shown in the accompanying drawings, and are only for the convenience of describing this application and simplifying the description, and are not intended to indicate or imply that the device or element referred to must have a specific orientation, be constructed and operated in a specific orientation, and therefore should not be understood as limiting this application. In addition, the terms "first" and "second" are used for descriptive purposes only and should not be understood as indicating or implying relative importance. Among them, the terms "first position" and "second position" are two different positions, and the first feature being "above", "above" and "above" the second feature includes the first feature being directly above and obliquely above the second feature, or simply means that the first feature is at a higher level than the second feature. The first feature being "below", "below" and "below" the second feature includes the first feature being directly below and obliquely below the second feature, or simply means that the first feature is at a lower level than the second feature.
[0049] In the description of this application, it should be noted that, unless otherwise expressly specified or limited, the terms "mounted," "connected," and "connected" should be understood in a broad sense. For example, they can refer to fixed connections, detachable connections, or integral connections; mechanical connections or electrical connections; direct connections or indirect connections through an intermediate medium; and internal connections between two components. Those skilled in the art will understand the specific meanings of the above terms in this application based on the specific circumstances.
[0050] The following describes in detail embodiments of the present application. Examples of the embodiments are shown in the accompanying drawings, wherein the same or similar reference numerals throughout represent the same or similar elements or elements having the same or similar functions. The embodiments described below with reference to the accompanying drawings are exemplary and are only used to explain the present application and are not to be construed as limiting the present application.
[0051] When the map is initially created, the coordinate system used is the default coordinate system. During the map alignment process, a reference coordinate system needs to be established. This is achieved by mapping points in the default coordinate system to the reference coordinate system.
[0052] The map's boundary lines include the map's outer boundary and the map's inner boundary. In the initial state, with reference to the default coordinate system, the state information of the boundary lines, including the length of the boundary lines and the angle between adjacent boundary lines, can be obtained.
[0053] The boundary information of the map includes the status information of the boundary lines and the total length of the boundary. The status information of the boundary lines includes the length and direction of each boundary line. The total length of the boundary is calculated from the boundary line information and is configured as the sum of the lengths of all boundary lines.
[0054] The map boundary is formed by connecting straight line segments end to end. In some embodiments, the boundary line is a straight line segment. In other embodiments, the boundary line is a straight line segment with a length greater than a certain threshold, and the straight line segment is obtained by Hough transform.
[0055] As shown in FIG1 to FIG5 , this embodiment provides a map correction method, including the following steps:
[0056] Step 1: Get the map's boundary information.
[0057] Step 2: Group all boundary lines that meet the preset conditions into an orthogonal line group.
[0058] Step 3: Determine the relationship between the reference ratio and the determination threshold. If the first relationship is satisfied, proceed to step 4. If the second relationship is satisfied, proceed to step 5.
[0059] Step 4: Establish a plane rectangular coordinate system based on the first datum, and then proceed to step 6.
[0060] Step 5: Establish a plane rectangular coordinate system based on the second datum, and then proceed to step 6.
[0061] Step 6: Straighten the map according to the plane rectangular coordinate system, and output the boundary information of the straightened map to the user terminal.
[0062] In this embodiment, the reference ratio is defined as the ratio of the maximum boundary line length to the total boundary length, and the boundary line length is defined as the sum of the lengths of all boundary lines in an orthogonal line group.
[0063] This map straightening method extracts and divides the boundary lines on the map into different orthogonal line groups, and can obtain the boundary line length of each orthogonal line group. After calculating the ratio of the maximum boundary line length to the total boundary length, it is compared with the judgment threshold to determine the benchmark determination method for map straightening. The above design achieves the purpose of determining the plane rectangular coordinate system, thereby completing the map straightening process, and finally straightening the map according to the determined plane rectangular coordinate system, and presenting the straightened map to the user through the user terminal. The above method determines the plane rectangular coordinate system by judging the size of the benchmark ratio, thereby realizing the map straightening operation, standardizing the map adjustment method, enabling the map to adapt to the user's observation habits, and helping to reduce the difficulty of complete map display.
[0064] In this embodiment, the preset condition is that the boundary lines are parallel, collinear or perpendicular to each other.
[0065] In this embodiment, step 2 involves the following detailed process: All boundary lines on the map are integrated, and all parallel, collinear, or perpendicular boundary lines are grouped into an orthogonal line group. Step 3 involves the following detailed process: After all boundary lines are grouped, the sum of the lengths of the boundary lines in each orthogonal line group is calculated and compared, and the largest of these is selected as the maximum boundary line length. The ratio of the maximum boundary line length to the total boundary length is then calculated and used as the benchmark ratio.
[0066] Furthermore, the first relationship is that the reference ratio is not less than the determination threshold, and the second relationship is that the reference ratio is less than the determination threshold; the first reference is the boundary line corresponding to the reference ratio, and the second reference is the reference circumscribed rectangle. This step determines whether the reference ratio exceeds the determination threshold. If so, step 4 is performed; if not, step 5 is performed.
[0067] When performing step four, the following detailed process is included: extracting the boundary line corresponding to the reference ratio, establishing a plane rectangular coordinate system, and the plane rectangular coordinate system corresponds to the above-mentioned boundary line; then performing step six, correcting the map according to the plane rectangular coordinate system, and outputting the boundary information of the corrected map to the user terminal.
[0068] When performing step five, the following detailed process is involved: obtaining the base circumscribed rectangle of the map and establishing a plane rectangular coordinate system, which corresponds to the base circumscribed rectangle; then performing step six, straightening the map according to the plane rectangular coordinate system, and outputting the boundary information of the straightened map to the user terminal.
[0069] The above process determines whether the linear datum determination method is suitable for map alignment. If so, the linear datum determination method can be used to locate the plane rectangular coordinate system. If not, the rectangular datum determination method is used instead. The above design combines the linear datum determination method with the rectangular datum determination method for the plane rectangular coordinate system to determine the plane rectangular coordinate system and achieve map alignment.
[0070] The determination threshold is 40%-80%. The determination threshold is a preset value and can be adjusted by the user according to actual needs. Specifically, in this embodiment, the determination threshold is 60%.
[0071] In this embodiment, step 4 also includes the following: the x-axis of the plane rectangular coordinate system is parallel to one of the boundary lines corresponding to the reference ratio. The above definition provides a standard for determining the orientation of the plane rectangular coordinate system, avoids the situation where the results of the map straightening operation are inconsistent, and ensures the reliability of the straightening result.
[0072] In this embodiment, step 2 includes the following detailed steps: select any boundary line as a positioning line; use all boundary lines that are parallel, collinear or perpendicular to the positioning line as orthogonal lines, use the sum of the positioning line and all orthogonal lines as the boundary line length, calculate and record the boundary line length; repeatedly select positioning lines and calculate the corresponding boundary line lengths until no more positioning lines can be selected, so as to calculate and record all boundary line lengths; compare and select the largest one among all boundary line lengths, calculate the ratio of the largest boundary line length to the total boundary length, and use it as the benchmark ratio. With the help of the above steps, the boundary line length of each orthogonal line group can be effectively calculated, and the largest one can be selected to calculate the benchmark ratio. In this way, the technical purpose of obtaining the benchmark ratio is achieved, which helps the smooth operation of the map correction method and ensures the accuracy of the map correction result.
[0073] Furthermore, repeatedly selecting positioning lines and calculating the length of corresponding boundary lines includes the following detailed steps: determining whether there are boundary lines that have neither been used as positioning lines nor as orthogonal lines; if so, selecting any boundary line that has neither been used as positioning lines nor as orthogonal lines, replacing it with a positioning line, and then returning to the step of selecting orthogonal lines; if not, comparing the lengths of all boundary lines, and calculating the ratio of the maximum boundary line length to the total boundary length as the benchmark ratio. With the help of the above process, omissions and errors in recording can be effectively avoided, ensuring the accuracy and completeness of the boundary line lengths, ensuring that the benchmark ratio can be accurately calculated and selected, and further ensuring the accuracy of the map correction results.
[0074] In another embodiment, step 2 includes the following detailed steps: selecting any boundary line as a positioning line; taking all boundary lines that are parallel, collinear, or perpendicular to the positioning line as orthogonal lines, taking the ratio of the sum of the positioning line and all orthogonal lines to the total length of the boundary as a test ratio, calculating and recording the test ratio; repeatedly selecting positioning lines and calculating the corresponding test ratios until no more positioning lines can be selected, so as to calculate and record all test ratios; comparing all test ratios, and selecting the largest one as the benchmark ratio. With the help of the above steps, the ratio of the sum of the lengths of each group of boundary lines to the total length of the boundary can be effectively calculated, and the largest one can be selected as the benchmark ratio. In this way, the technical purpose of obtaining the benchmark ratio is achieved, which helps the smooth operation of the map correction method and ensures the accuracy of the map correction results.
[0075] Furthermore, the content of repeatedly selecting positioning lines and calculating the corresponding test ratios includes the following detailed steps: determining whether there are boundary lines that have neither been used as positioning lines nor as orthogonal lines; if so, selecting any boundary line that has neither been used as a positioning line nor as an orthogonal line, replacing it with a positioning line, and then returning to the step of selecting an orthogonal line; if not, comparing all test ratios and selecting the largest one as the benchmark ratio. With the help of the above process, omissions and errors in the recording process can be effectively avoided, ensuring the accuracy and completeness of the test ratio records, ensuring that the benchmark ratio can be accurately calculated and selected, and further ensuring the accuracy of the map correction results.
[0076] Exemplarily, step six also includes the following: the X-axis of the plane rectangular coordinate system is parallel to the long side of the reference circumscribed rectangle, and the Y-axis of the plane rectangular coordinate system is parallel to the short side of the reference circumscribed rectangle. The above definition provides a specification for determining the direction of the plane rectangular coordinate system, avoids the situation where the results of the map straightening operation are different, and ensures the reliability of the straightening result. At the same time, the design of the X-axis being parallel to the long side and the Y-axis being parallel to the short side is easy to adapt to the size of the common display unit today, which helps to further reduce the difficulty of fully displaying the map on the display unit, thereby further improving the user's perception of the map.
[0077] Furthermore, step five includes the following detailed steps: establishing a circumscribed plane rectangular coordinate system 400, using two long sides parallel to the X axis of the circumscribed plane rectangular coordinate system 400 and two short sides parallel to the Y axis of the circumscribed plane rectangular coordinate system 400 to generate a circumscribed rectangle of a figure enclosed by boundary lines, using the area of the circumscribed rectangle as the test area, and calculating and recording the test area; rotating the circumscribed plane rectangular coordinate system 400 by a predetermined angle multiple times, selecting different circumscribed plane rectangular coordinate systems 400 and calculating the corresponding test areas, until the circumscribed plane rectangular coordinate system 400 is rotated 90° to calculate and record all test areas; comparing all test areas, and using the smallest circumscribed rectangle among all test areas as the reference circumscribed rectangle. With the help of the above steps, the operation of obtaining the reference circumscribed rectangle can be successfully completed. Thus, the technical purpose of obtaining the reference circumscribed rectangle is achieved, which helps to determine the position of the subsequent circumscribed plane rectangular coordinate system 400 and further ensures the accuracy of the map correction result.
[0078] Furthermore, the content of rotating the circumscribed plane rectangular coordinate system 400 by a predetermined angle multiple times includes the following detailed steps: rotating the circumscribed plane rectangular coordinate system 400 (N-1) times, each time rotating (90 / N) degrees, calculating and recording the test area corresponding to each circumscribed plane rectangular coordinate system 400; then comparing all the test areas, and using the smallest circumscribed rectangle among all the test areas as the reference circumscribed rectangle. The above operation increases the number of samples by obtaining and calculating the circumscribed rectangle, thereby making it possible to move the position of the reference circumscribed rectangle closer to the minimum circumscribed rectangle. The above design ensures the accuracy of the selection of the reference circumscribed rectangle, thereby improving the map straightening effect and further ensuring the accuracy of the map straightening result.
[0079] The value of N is selected as an integer greater than or equal to 2. In this embodiment, N=90. In other embodiments of this embodiment, N is selected as other integers greater than or equal to 2. The larger the selected value, the more circumscribed rectangles are generated, and the closer the area of the obtained reference circumscribed rectangle is to the minimum circumscribed rectangle. The above settings make the alignment of the map more regular, which helps to further reduce the display difficulty of the display unit. However, the increase in N also increases the number of circumscribed rectangles, increases the workload of analysis, and slows down the speed of obtaining the reference circumscribed rectangle. The specific value of N is determined by the comprehensive work situation of technicians in this field, and the determination method is the conventional technical means in this field, which will not be elaborated here.
[0080] When generating a circumscribed rectangle, it is necessary to ensure that each side of the circumscribed rectangle is in contact with the figure enclosed by the boundary lines. The above design ensures that the circumscribed rectangle accurately circumscribes the figure enclosed by the boundary lines.
[0081] In this embodiment, the following steps are included after step one: searching for a designated benchmark; determining whether the designated benchmark exists; if so, correcting the map according to the designated benchmark, and outputting the boundary information of the corrected map to the user terminal; if not, proceeding to step two. The above design allows the benchmark for map correction to be determined manually by the user, thereby greatly improving the flexibility of the map correction operation and achieving a user-friendly design, so that the position of the plane rectangular coordinate system can be set manually or automatically. The designated benchmark is usually specified by the user. After obtaining the boundary information of the map, the designated benchmark is directly retrieved. This not only ensures the priority of the user's search, but also simplifies the process of the map correction method, omitting unnecessary calculations and records, thereby effectively improving the efficiency of the correction operation.
[0082] In this embodiment, the priority for determining the plane rectangular coordinate system is user-defined, linear reference, and rectangular reference. If the user is dissatisfied with the map alignment results, they can modify them again using the user-defined method. The specific modification methods are common knowledge in the art and well-known to those skilled in the art, so they will not be elaborated on here.
[0083] In this embodiment, the following steps are included before step 2: determining whether the ratio of the length of the longest boundary line to the total boundary length is not less than a determination threshold. If so, a plane rectangular coordinate system is established using the longest boundary line as a reference, and then step 6 is performed. If not, step 2 is performed. Through these steps, it is possible to determine whether a boundary line exists that satisfies the relationship with the determination threshold. If so, this proves that the boundary line length of the orthogonal line group in which this boundary line resides is the largest, and its reference ratio naturally also satisfies the relationship requirement of the determination threshold. By performing these steps before step 2, it is possible to determine whether the map can be straightened using the straight line reference determination method. This allows a group of maps that meet the first relationship to be determined using the straight line reference determination method before determining the relationship between the reference ratio and the determination threshold. This design helps reduce the workload of the map straightening method, optimizes the process of the map straightening method, and accelerates execution. The above steps are simple and effective, improving the efficiency of map straightening, reducing user-induced judgment errors, and enhancing the quality of map straightening.
[0084] Exemplarily, the following step is included before step three: determining whether an orthogonal line group with at least two boundary lines exists. If so, proceed to step three; if not, proceed to step five. Through these steps, it is possible to determine whether all boundary lines form an orthogonal line group. In this case, no two boundary lines are parallel, collinear, or perpendicular to each other, and the ratio of any boundary line to the total length of the boundary is small. After alignment using the straight line reference determination method, only one boundary line is horizontally or vertically positioned. In some cases, this may affect the user's visual experience and pose a severe challenge to the display capabilities of the display unit. Considering these factors, it is preferable to use a rectangular reference determination method to correct the map. Through the above steps, maps that meet the above conditions can be corrected using the rectangular reference determination method, thereby improving the map's alignment quality and reducing the display difficulty of the display unit. Furthermore, performing these steps before step three optimizes the map alignment process, helps reduce the workload of the map alignment method, and improves its efficiency.
[0085] In other embodiments of this embodiment, if there are two or more maximum boundary line lengths, the display unit displays multiple rotation schemes, and the user selects one by interacting with the display unit.
[0086] In this embodiment, the following steps are included before step 3: determining whether there are at least two parallel maximum boundary line lengths. If so, proceed to step 5; if not, proceed to step 3. With the above steps, the boundary line status information can be analyzed before determining the relationship between the reference ratio and the judgment threshold. When there are parallel situations, it can be clearly determined that the reference ratio must not exceed 50%, and the result of map correction is likely to cause visual errors in the user's judgment, affecting normal observation and failing to achieve the correction advantages of the straight line reference determination method. Therefore, it is easy to determine that the straight line reference determination method is no longer the optimal map correction method, and switch to the rectangular reference determination method for map correction. Furthermore, performing the above steps before step 3 helps reduce the workload of the map correction method. The above steps are simple and effective, optimizing the process of the map correction method, improving the efficiency of map correction, reducing the occurrence of user judgment errors, and improving the quality of map correction.
[0087] The following describes the process of the alignment operation using the two maps shown in Figures 3 and 4 as examples:
[0088] In the map shown in FIG3 (units of length are meters, not shown), after obtaining all boundary information and integrating the boundary lines on the map, all boundary lines are divided into two groups: a first group with first positioning line 110 as the positioning line and a second group with second positioning line 120 as the positioning line. Specifically, the angle between first positioning line 110 and second positioning line 120 is 45°.
[0089] After integration, it can be seen that the total length of the boundary is 32.728 meters, the sum of the positioning lines and all the orthogonal lines in the first group is 20.000 meters, and the sum of the positioning lines and all the orthogonal lines in the second group is 12.728 meters.
[0090] In this embodiment, it can be seen from comparison that the maximum boundary line length is 20.000 meters. It can be seen from calculation that the reference ratio is 61.110%, which exceeds the determination threshold of 60%.
[0091] In another embodiment, calculations show that the test ratio corresponding to the first positioning line 110 is 61.110%, and the test ratio corresponding to the second positioning line 120 is 38.890%. By comparison, it can be seen that the reference ratio is 61.110%, which exceeds the determination threshold of 60%.
[0092] Therefore, it is necessary to establish a reference plane rectangular coordinate system 200, the X axis of the reference plane rectangular coordinate system 200 is parallel to the straight line where the first positioning line 110 is located, and the Y axis of the reference plane rectangular coordinate system 200 is perpendicular to the straight line where the first positioning line 110 is located. After the map is straightened according to the reference plane rectangular coordinate system 200, the boundary information of the straightened map is output to the user terminal.
[0093] In the maps shown in Figures 4 and 5 (the unit of length is meters, not shown in the figures), after obtaining all boundary information and integrating the boundary lines on the map, all boundary lines are divided into three groups: a third group with third positioning line 310 as the positioning line, a fourth group with fourth positioning line 320 as the positioning line, and a fifth group with fifth positioning line 330 as the positioning line. Specifically, the angle between third positioning line 310 and fourth positioning line 320 is 45°, and the angle between third positioning line 310 and fifth positioning line 330 is 65°.
[0094] After integration, it can be seen that the total length of the boundary is 39.939 meters, the sum of the positioning lines and all the orthogonal lines in the third group is 20.000 meters, the sum of the positioning lines and all the orthogonal lines in the fourth group is 12.728 meters, and the sum of the positioning lines and all the orthogonal lines in the fifth group is 7.211 meters.
[0095] In this embodiment, it can be seen from comparison that the maximum boundary line length is 20.000 meters. It can be seen from calculation that the reference ratio is 50.076%, which does not exceed the determination threshold of 60%.
[0096] In another embodiment, calculations show that the test ratio corresponding to the third positioning line 310 is 50.076%, the test ratio corresponding to the fourth positioning line 320 is 31.869%, and the test ratio corresponding to the fifth positioning line 330 is 18.055%. Comparison shows that the baseline ratio is 50.076%, which does not exceed the determination threshold of 60%.
[0097] The above results indicate that it is not convenient to determine the plane rectangular coordinate system of the map using the straight line reference determination method. Therefore, the rectangular reference determination method is switched to select the minimum circumscribed rectangle of the map as the reference for alignment. The reference circumscribed rectangle is obtained to determine the corresponding plane rectangular coordinate system, thereby completing the map alignment operation.
[0098] To achieve the above technical effects, a circumscribed plane rectangular coordinate system 400 must be established. Using two long sides parallel to the X-axis of circumscribed plane rectangular coordinate system 400 and two short sides parallel to the Y-axis of circumscribed plane rectangular coordinate system 400, a circumscribed rectangle of the figure enclosed by the boundary lines is generated. The first circumscribed rectangle generated by circumscribed plane rectangular coordinate system 400 is referred to as first circumscribed rectangle 500. The area of first circumscribed rectangle 500 is calculated and recorded as a test area. Circumscribed plane rectangular coordinate system 400 is then rotated to obtain a new circumscribed rectangle, and the area of the newly generated circumscribed rectangle is calculated and recorded.
[0099] In this embodiment, there are a total of 90 circumscribed plane rectangular coordinate systems 400, and therefore a total of 90 test areas. Each rotation of the coordinate axis is 1°. Each rotation of the circumscribed plane rectangular coordinate system 400 generates a new circumscribed rectangle, and the area of the newly generated circumscribed rectangle is calculated and recorded. This process continues until the areas of all circumscribed rectangles are calculated and compared, resulting in the smallest circumscribed rectangle, which is the reference circumscribed rectangle.
[0100] FIG5 shows the position information of the second circumscribed rectangle 600 , the third circumscribed rectangle 700 , the fourth circumscribed rectangle 800 and the fifth circumscribed rectangle 900 when the first circumscribed plane rectangular coordinate system 400 is rotated by 1°, 2°, 8° and 9°.
[0101] The circumscribed plane rectangular coordinate system 400 corresponding to the reference circumscribed rectangle is used as the plane rectangular coordinate system, and the map is rectified by the plane rectangular coordinate system, and then the boundary information of the rectified map is output to the user terminal.
[0102] The above embodiment can be applied to the field of intelligent robots and is commonly found in various types of autonomous working equipment. The autonomous working equipment includes a control module and an interaction module. The control module, by running the above method, can realize the map alignment operation relative to the working area and intuitively display the aligned map on the interaction module.
[0103] In this embodiment, the autonomous operating equipment is especially a robot that can move autonomously within a preset area and perform specific operations, such as a smart sweeper / vacuum cleaner that performs cleaning operations, or a smart lawn mower that performs mowing operations. Among them, the specific operation especially refers to the operation of processing the working surface and changing the state of the working surface. This application is explained in detail using a smart lawn mower as an example. The autonomous operating equipment can autonomously walk on the surface of the working area, and especially as a smart lawn mower, it can autonomously perform mowing operations on the ground. In addition to the control module and the interaction module, the autonomous operating equipment also includes at least a main body mechanism, a moving mechanism, a working mechanism, an energy module and a detection module.
[0104] The main body mechanism generally includes a chassis and a device shell. The chassis is used to install and accommodate at least one of the functional mechanisms and functional modules such as the mobile mechanism, working mechanism, energy module, detection module, interaction module and control module. The device shell is generally constructed to at least partially cover the chassis, mainly to enhance the aesthetics and recognition of the autonomous operating equipment. In some embodiments, at least one of the above-mentioned functional mechanisms and functional modules is mounted on the device shell. In some prior arts, the device shell is constructed to be able to translate and / or rotate relative to the chassis in a resettable manner under the action of external force. In conjunction with an appropriate detection module, such as a Hall sensor, it can further sense events such as collisions and lifts.
[0105] The control module typically includes at least one processor and at least one non-volatile memory. The memory stores a pre-written computer program or instruction set. The processor controls the autonomous device's movements, operations, and other actions according to the program or instruction set. Furthermore, the control module can control and adjust the autonomous device's behavior and modify parameters stored in the memory based on signals from the detection module and / or user control commands.
[0106] The interaction module is configured to at least receive control command information input by the user, issue information that requires user perception, and communicate with other systems or devices to send and receive information. In this embodiment, the interaction module includes an input device provided on the autonomous operating device for receiving control command information input by the user, typically such as a control panel, an emergency stop button, etc.; the interaction module also includes a display screen, indicator lights, and / or buzzers provided on the autonomous operating device, which enable the user to perceive information by emitting light or sound. In other embodiments, the interaction module includes a communication module provided on the autonomous operating device and a terminal device independent of the autonomous operating device, such as a mobile phone, computer, or network server. The user's control command information or other information can be input on the terminal device and reach the autonomous operating device via a wired or wireless communication module.
[0107] Obviously, the above embodiments of the present application are merely examples for the purpose of clearly illustrating the present application, and are not intended to limit the embodiments of the present application. Those skilled in the art will appreciate that other variations or modifications can be made based on the above description. It is not necessary and impossible to enumerate all embodiments here. Any modifications, equivalent substitutions, and improvements made within the spirit and principles of the present application shall be included within the scope of protection of the claims of the present application.
Claims
1. A map correction method, characterized in that: The following steps are involved: S10: Acquire boundary information of the map, the boundary information including state information of boundary lines and total boundary length, the total boundary length is configured as the sum of lengths of all boundary lines; S20: Summarize all the boundary lines that meet the preset conditions into an orthogonal line group; S30: Determine the relationship between the reference ratio and the determination threshold, if the first relationship is satisfied, proceed to S40, if the second relationship is satisfied, proceed to S50; the reference ratio is the ratio of the maximum boundary line length to the total boundary length, and the boundary line length is defined as the sum of the lengths of all the boundary lines in one of the orthogonal line groups; S40: Establishing a plane rectangular coordinate system according to the first reference, and then proceeding to S60; S50: Establishing a plane rectangular coordinate system according to the second reference, and then proceeding to S60; S60: Straightening the map according to the plane rectangular coordinate system, and outputting the boundary information of the straightened map to a user terminal.
2. The map correction method according to claim 1, characterized in that: The preset condition is that the boundary lines are parallel, collinear or perpendicular to each other.
3. The map correction method according to claim 2, characterized in that: The first relationship is that the reference ratio is not less than the determination threshold, and the second relationship is that the reference ratio is less than the determination threshold; the first reference is the boundary line corresponding to the reference ratio, and the second reference is a reference circumscribed rectangle.
4. The map correction method according to claim 3, characterized in that: S20 includes the following detailed steps: S21: Select any of the boundary lines as a positioning line; S22: All the boundary lines that are parallel, collinear or perpendicular to the positioning line are taken as orthogonal lines. The sum of the positioning line and all the orthogonal lines is taken as the length of the boundary line, and the length of the boundary line is calculated and recorded; S23: repeatedly selecting the positioning lines and calculating the lengths of the corresponding boundary lines until no more positioning lines can be selected, so as to calculate and record the lengths of all the boundary lines; S24: Compare and select the largest one among all the boundary line lengths, and calculate the ratio of the largest boundary line length to the total boundary length as the reference ratio.
5. The map correction method according to claim 4, characterized in that: S23 includes the following detailed steps: S231: Determine whether there is a boundary line that has never been used as the positioning line or the orthogonal line. If yes, proceed to S232; if no, proceed to S24; S232: Select any boundary line that has never been used as the positioning line or the orthogonal line, replace it with the positioning line, and then perform S22 again.
6. The map correction method according to claim 3, characterized in that: S50 includes the following detailed steps: S51: establishing a circumscribed plane rectangular coordinate system (400), using two long sides parallel to the X axis of the circumscribed plane rectangular coordinate system (400) and two short sides parallel to the Y axis of the circumscribed plane rectangular coordinate system (400), generating a circumscribed rectangle of the figure enclosed by the boundary lines, taking the area of the circumscribed rectangle as the test area, and calculating and recording the test area; S52: rotating the circumscribed plane rectangular coordinate system (400) by a predetermined angle multiple times, selecting different circumscribed plane rectangular coordinate systems (400) and calculating the corresponding test areas, until the circumscribed plane rectangular coordinate system (400) is rotated by 90°, so as to calculate and record all the test areas; S53: Compare all the test areas, and select the smallest one among all the test areas. The circumscribed rectangle is used as the reference circumscribed rectangle.
7. The map correction method according to claim 1, characterized in that: After S10, the following steps are also included: S11: Find the specified benchmark; S12: Determine whether the designated reference exists. If so, correct the map according to the designated reference, and output the boundary information of the corrected map to the user terminal. If not, proceed to S20.
8. The map correction method according to claim 1, characterized in that: Prior to S20, the following steps were also included: S18: Determine whether the ratio of the length of the longest boundary line to the total length of the boundary is not less than the determination threshold, if so, proceed to S19, if not, proceed to S20; S19: Establish a plane rectangular coordinate system based on the longest boundary line, and then proceed to S60.
9. The map correction method according to claim 1, characterized in that: Prior to S30, the following steps were also included: S28: Determine whether there is an orthogonal line group having at least two boundary lines. If so, proceed to S30; if not, proceed to S50.
10. The map correction method according to any one of claims 1 to 9, characterized in that: Prior to S30, the following steps were also included: S29: Determine whether there are at least two parallel largest boundary line lengths. If so, proceed to S50; if not, proceed to S30.
Citation Information
Patent Citations
Mobile robot separating visual positioning and navigation method and positioning and navigation system thereof
CN102929280A
Running method and device of cleaning robot
CN110801180A
Environmental map direction adjusting method, system and device
CN112747734A
Map adjustment method, electronic device and storage medium
CN113459088A
Plotting processor
JP1998188011A
