Path coverage method and device, electronic device and storage medium

By detecting obstacles and re-planning the coverage path, the sweeping robot can effectively avoid obstacles during the sweeping process, improves the cleaning efficiency and coverage rate, and solves the problems of low coverage efficiency and repeated cleaning in the prior art.

CN113064432BActive Publication Date: 2024-11-26BEIJING JINMIN TECHNOLOGY CO LTD
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN202110302029.5
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2021-03-22
Publication Date
2024-11-26
Estimated Expiration
2041-03-22

AI Technical Summary

Technical Problem

It is difficult for the sweeping robot to effectively avoid obstacles during the cleaning process, resulting in low coverage efficiency, low coverage rate and large repeated cleaning area.

Method used

By detecting obstacles and re-planning, splitting or updating the paths to cover, we can actively avoid obstacles and improve the efficiency and coverage of path coverage.

Benefits of technology

The coverage efficiency of the sweeping robot for cleaning areas is improved, the area of ​​repeated cleaning is reduced, and the ability to avoid obstacles is enhanced.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN113064432B_ABST
    Figure CN113064432B_ABST
Patent Text Reader

Abstract

The present disclosure relates to a path coverage method and device, an electronic device and a storage medium, the method comprising: determining a set of paths to be covered according to an original scene map, wherein the set of paths to be covered includes multiple paths to be covered; in the process of performing coverage processing according to the set of paths to be covered, in the case where an obstacle is detected on a first path to be covered, re-planning the path of the first path to be covered to obtain at least one second path to be covered, wherein the first path to be covered includes a path to be covered within the detection range of the electronic device; updating the set of paths to be covered according to the second path to be covered to obtain an updated set of paths to be covered; and performing coverage processing according to the updated set of paths to be covered. The embodiments of the present disclosure can improve the efficiency of path coverage.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present disclosure relates to the field of computer technology, and in particular to a path coverage method and device, an electronic device, and a storage medium. Background Art

[0002] With the advancement of science and technology, high-tech products have provided great convenience for people's daily lives and greatly improved people's living standards and happiness index. Take sweeping robots as an example. In recent years, sweeping robots have gradually entered thousands of households and become common appliances and powerful assistants in people's daily lives.

[0003] One of the core tasks of a sweeping robot is to clean the area to be cleaned in the entire room, that is, to move itself so that the effective cleaning area covers the entire area to be cleaned. Summary of the invention

[0004] The present disclosure proposes a technical solution for path coverage.

[0005] According to one aspect of the present disclosure, a path coverage method is provided, which is applied to an electronic device, including:

[0006] According to the original scene map, a set of paths to be covered is determined, wherein the set of paths to be covered includes multiple paths to be covered; in the process of performing coverage processing according to the set of paths to be covered, when an obstacle is detected on a first path to be covered, the first path to be covered is re-planned to obtain at least one second path to be covered, wherein the first path to be covered includes a path to be covered within a detection range of the electronic device; according to the second path to be covered, the set of paths to be covered is updated to obtain an updated set of paths to be covered; and coverage processing is performed according to the updated set of paths to be covered.

[0007] The path coverage method provided by the embodiment of the present disclosure can actively detect obstacles during the path coverage process, and by re-planning the path set to be covered where the obstacles are located, it can actively and timely avoid obstacles during the coverage process, thereby improving the coverage rate of the area to be covered, reducing the coverage repetition rate, and improving the coverage efficiency.

[0008] In a possible implementation, any path to be covered includes a first endpoint and a second endpoint, and when an obstacle is detected on the first path to be covered, re-planning the first path to be covered to obtain at least one second path to be covered includes:

[0009] When an obstacle is detected on the first path to be covered, the first path to be covered is replanned according to the first end point and the second end point of the first path to be covered and the position of the obstacle to obtain at least one second path to be covered.

[0010] The path coverage method provided by the embodiment of the present disclosure can obtain a second coverage path after re-planning the path according to the first endpoint and the second endpoint of the first path to be covered and the position of the obstacle, so as to actively avoid obstacles in the path coverage and reduce the coverage repetition rate.

[0011] In a possible implementation, re-planning the first path to be covered according to the first endpoint and the second endpoint of the first path to be covered and the position of the obstacle to obtain at least one second path to be covered includes:

[0012] When the obstacle is located between the first end point and the second end point of the first path to be covered, the first path to be covered is split into a second path to be covered. m and the second path to be covered L s , wherein the second path to be covered L m The first end point of the first path to be covered is taken as the first end point, and the first position between the first end point of the first path to be covered and the obstacle and close to the obstacle is taken as the second end point. s A second position between the second end point of the first path to be covered and the obstacle and close to the obstacle is taken as the first end point, and the second end point of the first path to be covered is taken as the second end point.

[0013] The path coverage method provided by the embodiment of the present disclosure can split the first path to be covered into two second paths to be covered according to the position of the obstacle when the position of the obstacle is between the first end point and the second end point of the first path to be covered, so as to actively avoid obstacles during path coverage, reduce coverage repetition rate, and improve coverage efficiency.

[0014] In a possible implementation, re-planning the first path to be covered according to the first endpoint and the second endpoint of the first path to be covered and the position of the obstacle to obtain at least one second path to be covered includes:

[0015] When the position of the obstacle coincides with the first end point of the first path to be covered, a third position close to the obstacle and between the obstacle and the second end point of the first path to be covered is determined; and a second path to be covered L is obtained according to the third position and the second end point of the first path to be covered. z, wherein the second path to be covered L z The third position is used as the first endpoint, and the second endpoint of the first path to be covered is used as the second endpoint; or,

[0016] When the position of the obstacle coincides with the second end point of the first path to be covered, a fourth position close to the obstacle and between the obstacle and the first end point of the first path to be covered is determined; and a second path to be covered L is obtained according to the fourth position and the first end point of the first path to be covered. x , wherein the second path to be covered L x The first endpoint of the first path to be covered is used as the first endpoint, and the fourth position is used as the second endpoint.

[0017] The path coverage method provided by the embodiment of the present disclosure can, when the position of the obstacle coincides with the first endpoint or the second endpoint of the first path to be covered, re-plan the first path to be covered according to the position of the obstacle to obtain the second path to be covered, so as to actively avoid obstacles during path coverage, reduce the coverage repetition rate, and improve the coverage efficiency.

[0018] In a possible implementation, the moving direction of the electronic device is from a starting endpoint to a destination endpoint, the starting endpoint is a first endpoint or a second endpoint of the path to be covered, and the destination endpoint is another endpoint of the path to be covered except the starting endpoint, and the updating of the set of paths to be covered according to the second path to be covered to obtain an updated set of paths to be covered includes:

[0019] Determine a target path to be covered including the starting endpoint of the first path to be covered from the second path to be covered; use the target path to be covered to replace the first path to be covered in the set of paths to be covered; determine whether there is a newly added path to be covered, wherein the newly added path to be covered is the second path to be covered in the second path to be covered except the target path to be covered; if the newly added path to be covered exists, add the newly added path to be covered to the set of paths to be covered; and obtain an updated set of paths to be covered.

[0020] In a possible implementation manner, the updating the set of paths to be covered according to the second path to be covered to obtain an updated set of paths to be covered further includes:

[0021] When the target path to be covered does not exist, the second path to be covered is used to replace the first path to be covered in the set of paths to be covered.

[0022] The path coverage method of the disclosed embodiment can not only realize active obstacle avoidance, reduce coverage repetition rate and improve coverage efficiency in path coverage, but also in the process of updating the path set to be covered, the electronic device can normally perform the path coverage work, and can reduce the impact of the process of updating the path set to be covered on the work of the electronic device.

[0023] In a possible implementation, performing coverage processing according to the updated set of paths to be covered includes:

[0024] The electronic device moves from the starting endpoint of the current path to be covered to the destination endpoint of the current path to be covered; when the electronic device moves to the destination endpoint of the current path to be covered, the current path to be covered is updated to a covered path in the set of paths to be covered, wherein the starting endpoint of the current path to be covered is the first endpoint or the second endpoint of the current path to be covered, and the destination endpoint of the current path to be covered is another endpoint in the current path to be covered except the starting endpoint.

[0025] The coverage method provided by the embodiment of the present disclosure can update the set of paths to be covered in real time according to the coverage processing progress of the electronic device, so that the coverage progress for the area to be covered can be known through the set of paths to be covered, thereby reducing the occurrence of repeated coverage processing for the covered paths, reducing the coverage repetition rate, and improving the coverage efficiency.

[0026] In a possible implementation, performing coverage processing according to the updated set of paths to be covered further includes:

[0027] When the electronic device moves from the starting endpoint of the current path to be covered to the destination endpoint of the current path to be covered, a third path to be covered is determined from the updated set of paths to be covered according to the destination endpoint of the current path to be covered; the electronic device moves from the current path to be covered to the third path to be covered; and the third path to be covered is used as the new current path to be covered.

[0028] In a possible implementation manner, the electronic device moves from the current path to be covered to the third path to be covered, including:

[0029] The electronic device moves from the destination endpoint of the current path to be covered to the starting endpoint of the third path to be covered; wherein, when the destination endpoint of the current path to be covered is the second endpoint of the current path to be covered, the second endpoint of the third path to be covered is determined as the starting endpoint of the third path to be covered, and the first endpoint of the third path to be covered is determined as the destination endpoint of the third path to be covered; or,

[0030] When the destination endpoint of the current path to be covered is the first endpoint of the current path to be covered, the first endpoint of the third path to be covered is determined as the starting endpoint of the third path to be covered, and the second endpoint of the third path to be covered is determined as the destination endpoint of the third path to be covered.

[0031] The covering method provided by the embodiment of the present disclosure can enable the electronic device to cover the area to be covered with a "bow-shaped" moving trajectory, which can reduce the coverage repetition rate and improve the coverage efficiency.

[0032] In a possible implementation manner, determining a third path to be covered from the updated path to be covered according to the destination endpoint of the current path to be covered includes:

[0033] Determine whether there is a path to be covered in front of the current path to be covered in the current scene coverage direction; if there is a path to be covered in front of the current path to be covered in the current scene coverage direction, determine a third path to be covered from the path to be covered in front of the current path to be covered according to the destination endpoint of the current path to be covered.

[0034] In a possible implementation, the determining, according to the destination endpoint of the current path to be covered, a third path to be covered from the paths to be covered ahead of the current path to be covered includes:

[0035] Determine a target endpoint from the endpoints corresponding to the path to be covered in front of the current path to be covered, the target endpoint and the destination endpoint of the current path to be covered are the same type of endpoints, and the target endpoint is closest to the destination endpoint of the current path to be covered; determine that the path to be covered corresponding to the target endpoint is the third path to be covered.

[0036] The covering method provided by the embodiment of the present disclosure can make the trajectory of the electronic device moving from the current path to be covered to the third path to be covered be "bow-shaped" with the shortest moving distance, which can reduce the coverage repetition rate and thus improve the coverage efficiency of the electronic device.

[0037] In a possible implementation manner, the determining a third path to be covered from the updated path to be covered according to the destination endpoint of the current path to be covered further includes:

[0038] When there is no path to be covered in front of the current path to be covered in the current scene coverage direction, determine whether there is a path to be covered in the same row as the current path to be covered based on the destination endpoint of the current path to be covered; when there is a path to be covered in the same row as the current path to be covered, determine that the path to be covered in the same row as the current path to be covered is the third path to be covered.

[0039] In a possible implementation manner, the determining a third path to be covered from the updated path to be covered according to the destination endpoint of the current path to be covered further includes:

[0040] If there is no path to be covered in the same row as the current path to be covered, the current scene coverage direction is changed. The coverage method provided by the embodiment of the present disclosure can improve the coverage rate of the area to be covered, reduce the coverage repetition rate, and improve the coverage efficiency.

[0041] In a possible implementation, the method further includes:

[0042] When no obstacle is detected at the position of the first obstacle, determine whether there is a fourth path to be covered associated with the position of the first obstacle in the path to be covered; when the fourth path to be covered exists, re-plan the path of the fourth path to be covered according to the position of the first obstacle to obtain a fifth path to be covered; and update the set of paths to be covered according to the fifth path to be covered to obtain an updated set of paths to be covered, wherein the position of the first obstacle includes the position of obstacles within the detection range of the electronic device.

[0043] In a possible implementation, the method further includes: in the absence of the fourth path to be covered, performing path planning according to the position of the first obstacle to obtain a sixth path to be covered; and updating the set of paths to be covered according to the sixth path to be covered to obtain an updated set of paths to be covered.

[0044] The path coverage method provided by the embodiment of the present disclosure can adaptively plan the path according to the movement of the obstacle, and can re-plan the path according to the position of the obstacle after the obstacle is removed, so as to timely cover and clean the area occupied by the obstacle, which can effectively increase the coverage area and reduce the coverage repetition rate.

[0045] In a possible implementation, performing coverage processing according to the updated set of paths to be covered further includes:

[0046] In the case where the third path to be covered does not exist, the area where the obstacle is located is detected; in the case where no obstacle is detected in the area where the obstacle is located, coverage processing is performed on the area where the obstacle is located. The path coverage method provided in the embodiment of the present disclosure can improve the coverage rate of the area to be covered.

[0047] According to one aspect of the present disclosure, an electronic device is provided, comprising: a processor; and a memory for storing processor-executable instructions; wherein the processor is configured to call the instructions stored in the memory to execute the above method.

[0048] According to one aspect of the present disclosure, a computer-readable storage medium is provided, on which computer program instructions are stored, and the computer program instructions implement the above method when executed by a processor.

[0049] In an embodiment of the present disclosure, the electronic device can determine a set of paths to be covered including multiple paths to be covered based on the acquired original scene map, and in the process of performing coverage processing on the area to be covered based on the set of paths to be covered, when an obstacle is detected on the first path to be covered, the first path to be covered can be re-planned to obtain at least one second path to be covered, and the set of paths to be covered can be updated based on the second path to be covered to obtain an updated set of paths to be covered, and then coverage processing can be performed based on the updated set of paths to be covered. The path coverage method and device, electronic device and storage medium provided by the embodiment of the present disclosure can actively detect obstacles during the path coverage process, and by re-planning the path of the set of paths to be covered where the obstacles are located, obstacles can be actively and timely avoided during the coverage process, which can improve the coverage rate of the area to be covered, reduce the coverage repetition rate, and improve the coverage efficiency.

[0050] It should be understood that the above general description and the following detailed description are exemplary and explanatory only and do not limit the present disclosure. Other features and aspects of the present disclosure will become clear from the following detailed description of exemplary embodiments with reference to the accompanying drawings. BRIEF DESCRIPTION OF THE DRAWINGS

[0051] The drawings herein are incorporated into the specification and constitute a part of the specification. These drawings illustrate embodiments consistent with the present disclosure and are used to illustrate the technical solutions of the present disclosure together with the specification.

[0052] Figure 1a to Figure 1d A schematic diagram showing a path coverage method according to an embodiment of the present disclosure;

[0053] Figure 2 A flow chart showing a path coverage method according to an embodiment of the present disclosure is shown;

[0054] Figure 3a to Figure 3c A schematic diagram showing a path coverage method according to an embodiment of the present disclosure;

[0055] Figure 4a to Figure 4b A schematic diagram showing a path coverage method according to an embodiment of the present disclosure;

[0056] Figure 5a to Figure 5b A schematic diagram showing a path coverage method according to an embodiment of the present disclosure;

[0057] Figure 6 A block diagram showing a path coverage device according to an embodiment of the present disclosure is shown;

[0058] Figure 7 A block diagram of an electronic device 800 according to an embodiment of the present disclosure is shown;

[0059] Figure 8 A block diagram of an electronic device 1900 according to an embodiment of the present disclosure is shown. DETAILED DESCRIPTION

[0060] Various exemplary embodiments, features and aspects of the present disclosure will be described in detail below with reference to the accompanying drawings. The same reference numerals in the accompanying drawings represent elements with the same or similar functions. Although various aspects of the embodiments are shown in the accompanying drawings, the drawings are not necessarily drawn to scale unless otherwise specified.

[0061] The word “exemplary” is used exclusively herein to mean “serving as an example, example, or illustration.” Any embodiment described herein as “exemplary” is not necessarily to be construed as preferred or advantageous over other embodiments.

[0062] The term "and / or" herein is only a description of the association relationship of the associated objects, indicating that there may be three relationships. For example, A and / or B can represent: A exists alone, A and B exist at the same time, and B exists alone. In addition, the term "at least one" herein represents any combination of at least two of any one or more of a plurality of. For example, including at least one of A, B, and C can represent including any one or more elements selected from the set consisting of A, B, and C.

[0063] In addition, in order to better illustrate the present disclosure, numerous specific details are given in the following specific embodiments. It should be understood by those skilled in the art that the present disclosure can also be implemented without certain specific details. In some examples, methods, means, components and circuits well known to those skilled in the art are not described in detail in order to highlight the subject matter of the present disclosure.

[0064] One of the core tasks of a sweeping robot is to cover the entire room's cleaning area through its own movement, so as to achieve the purpose of comprehensive cleaning of the cleaning area. The related coverage cleaning strategy is that the sweeping robot moves randomly. When the sensors around the body detect that it has collided with an obstacle, the sweeping robot turns left or right and continues to move randomly. This coverage cleaning strategy has a high coverage repetition rate and a low coverage rate, and the cleaning efficiency is low.

[0065] The disclosed embodiment provides a path coverage method. After obtaining the original scene map of the area to be covered, the electronic device can determine a set of paths to be covered according to the original scene map. The set of paths to be covered includes multiple paths to be covered, and the multiple paths to be covered are not connected to each other. Exemplarily, the set of paths to be covered can be displayed in the form of a set of paths to be covered graph. The set of paths to be covered graph can refer to Figure 1a shown.

[0066] After the electronic device determines a path to be covered as the starting path from the set of paths to be covered, it moves from the current location of the electronic device to the starting path, and performs coverage processing on the paths to be covered in the set of paths to be covered starting from the starting path. For example: the path to be covered includes two endpoints. After the electronic device moves from one endpoint of the starting path to the other endpoint, it deletes the starting path from the set of paths to be covered (or it may mark the starting path as a covered path), and it may determine the next path to be covered 1 that has not yet been covered from the paths to be covered in the set of paths to be covered, and move to the path to be covered 1, and perform coverage processing on the path to be covered 1. It should be noted that during the process of path coverage, the movement trajectory of the electronic device may be in a "bow shape", and the bow-shaped movement path may refer to Figure 1b As shown, the partial movement trajectory of the electronic device in the set of paths to be covered using the "bow shape" can be referred to Figure 1c shown.

[0067] When the electronic device is performing coverage processing on the path to be covered, the electronic device can detect whether there are obstacles on the current path to be covered and / or the path to be covered around the electronic device. In the case of detecting that there are obstacles on the first path to be covered, the first path to be covered can be re-planned to obtain at least one second path to be covered, and the set of paths to be covered can be updated according to the obtained second path to be covered to obtain an updated set of paths to be covered. For example: the first path to be covered in the set of paths to be covered can be replaced with the second path to be covered, and / or the second path to be covered can be added to the set to be covered to obtain an updated set of paths to be covered.

[0068] The electronic device can continue to perform coverage processing according to the updated set of paths to be covered. The specific coverage process is similar to the aforementioned coverage process, and the present embodiment will not be repeated here. According to the path coverage method provided by the embodiment of the present disclosure, by re-planning the path of the set of paths to be covered where the obstacles are located, obstacles can be actively avoided during the coverage process, the coverage rate of the area to be covered can be improved, the coverage repetition rate can be reduced, and the coverage efficiency can be improved.

[0069] Figure 2 A flow chart of a path coverage method according to an embodiment of the present disclosure is shown, and the path coverage method can be executed by an electronic device such as a terminal device or a server, and the terminal device can be a user equipment (UE), a mobile device, a user terminal, a terminal, a cellular phone, a cordless phone, a personal digital assistant (PDA), a handheld device, a computing device, a vehicle-mounted device, a wearable device, a sweeping robot, a snow-clearing robot, etc. The method can also be implemented by a processor calling a computer-readable instruction stored in a memory. Alternatively, the method can be executed by a server.

[0070] like Figure 2 As shown, the path coverage method includes:

[0071] In step S21, a set of paths to be covered is determined according to the original scene map, wherein the set of paths to be covered includes a plurality of paths to be covered.

[0072] For example, the electronic device can obtain the original scene map of the area to be covered. For example, the electronic device can move randomly or orderly in the area to be covered, and during the movement, collect map information of the area to be covered through image acquisition devices and / or sensors and other devices to obtain the original scene map of the area to be covered. Alternatively, the electronic device can also directly obtain the original scene map of the area to be covered by uploading or downloading, etc. The method for obtaining the original scene map is not specifically limited in the embodiments of the present disclosure.

[0073] Taking the electronic device as a sweeping robot as an example, an image acquisition device can be integrated in the sweeping robot. Before executing path coverage to clean the area to be cleaned, the sweeping robot can be moved in the indoor area to be cleaned to collect environmental image information of the area to be cleaned through the image acquisition device, and then build an original scene map based on the environmental image information, for example: using VSLAM (Visual Simultaneous Localization and Mapping) to build the original scene map. It should be noted that the sweeping robot can perform cleaning work or not when collecting the original scene map, and the disclosed embodiment does not specifically limit this.

[0074] After obtaining the original scene map, the electronic device can perform path planning according to the original scene map to obtain multiple paths to be covered, and obtain a set of paths to be covered according to the planned multiple paths to be covered. Exemplarily, when performing path planning, the two endpoints of the middle obstacle-free area to be covered can be connected in sequence as a path to be covered, so as to obtain multiple paths to be covered in the area to be covered, and the multiple paths to be covered are parallel to each other and not connected to each other. Among them, the distance between two adjacent paths to be covered can be determined according to the coverage parameters of the electronic device, for example: in the case where the electronic device is a sweeping robot, the distance between two adjacent paths to be covered can be determined according to the suction coverage range of the sweeping robot, for example: the larger the suction coverage range, the larger the distance between the corresponding two adjacent paths to be covered; or, the distance between two adjacent paths to be covered can also be set according to the body size of the sweeper, for example: the larger the body size, the larger the distance between the corresponding two adjacent paths to be covered; or, the distance between two adjacent paths to be covered can also be set manually, and the embodiment of the present disclosure does not specifically limit the method for determining the distance between two adjacent paths to be covered.

[0075] In fact, any path planning method is applicable to the embodiments of the present disclosure, such as: grid method, template model method, or neural network processing method, etc. The embodiments of the present disclosure do not specifically limit the path planning method.

[0076] In a possible implementation, the plurality of paths to be covered in the set of paths to be covered are parallel to each other. For example, the path planning result for the area to be covered can refer to Figure 1a As shown in FIG. 1 , since the paths to be covered are parallel to each other, the repetition rate of path coverage can be effectively reduced and the path coverage rate can be improved.

[0077] In step S22, during the process of performing coverage processing according to the set of paths to be covered, when an obstacle is detected on the first path to be covered, the first path to be covered is re-planned to obtain at least one second path to be covered, and the first path to be covered includes the path to be covered within the detection range of the electronic device.

[0078] For example, after obtaining the set of covered paths, the initial path can be determined from the set of paths to be covered, as well as the starting endpoint and the destination endpoint of the initial path. The electronic device moves from the current location to the starting endpoint of the initial path, and moves from the starting endpoint to the destination endpoint of the initial path to achieve coverage of the initial path. After completing the coverage of the initial path, the electronic device can determine the next path to be covered, and move to the path to be covered to perform coverage processing on the path to be covered, that is, move from the starting endpoint of the path to be covered to the destination endpoint of the path to be covered.

[0079] For example, the paths to be covered that are located at both ends of the scene to be covered and are closest to the electronic device may be determined as the initial paths. Figure 1a It is possible to determine that the path to be covered L1 in the set of scenes to be covered is the initial path. It should be noted that, in fact, any path to be covered can be determined as the initial path, and the embodiment of the present disclosure does not specifically limit the method for determining the initial path.

[0080] In the process of moving from the starting end point of the path to be covered to the destination end point of the path to be covered, the electronic device can detect obstacles within the detection range in real time, and when an obstacle is detected on the first path to be covered within the detection range, the first path to be covered is re-planned according to the position of the obstacle to obtain at least one second path to be covered. The at least one second path to be covered can avoid obstacles, so that the electronic device can actively avoid obstacles during the path coverage process.

[0081] Among them, obstacles may include static or dynamic obstacles. For example, obstacles may include dynamic obstacles such as people and animals, and may also include static obstacles such as furniture, cartons, bonsai, etc. The embodiments of the present disclosure do not specifically limit the types of obstacles. Any object that hinders the movement of electronic equipment can be regarded as an obstacle.

[0082] Exemplarily, the electronic device can detect obstacles by visual detection. For example, when the electronic device is covering the path to be covered, it can collect the environmental image around the electronic device in real time, and perform image recognition on the collected environmental image to determine whether there are obstacles in the current environment based on the image recognition result. The specific image recognition process is not described in detail in the embodiments of this disclosure. For example, it can be implemented by a neural network for image recognition. In one possible implementation, when the electronic device recognizes an obstacle in the environmental image, it can determine whether the obstacle is detected within a preset time range. If so, it can be determined that there is an obstacle in the current environment.

[0083] Alternatively, the electronic device may also detect obstacles using a laser radar or other detection method. For example, it may detect whether there are obstacles around based on the reflected signal received by a laser radar or other device. In fact, the obstacle detection method is not specifically limited in the embodiments of the present disclosure, and any method that can be used to detect obstacles is applicable to the embodiments of the present disclosure.

[0084] It should be noted that the detection range of the electronic device can be determined based on the performance parameters of the electronic device. For example, when the electronic device detects obstacles using visual detection, the detection range of the electronic device can be determined based on the viewing angle range of the image acquisition device integrated in the electronic device; or, when the electronic device detects obstacles using laser radar or other detection methods, the detection range of the electronic device can be determined based on the detection range of the laser radar or other devices.

[0085] For example, when the electronic device detects an obstacle within the detection range, it can be determined that the path to be covered where the obstacle is located is the first path to be covered, and the path planning for the first path to be covered is re-performed. Exemplarily, the specific process of re-planning the path for the first path to be covered can be determined according to the location of the obstacle. For example, in the process of re-planning the path for the first path to be covered, if the obstacle is located in the middle of the first path to be covered, the first path to be covered can be split into two second paths to be covered according to the location of the obstacle, or if the obstacle is located at both ends of the first path to be covered, the endpoints of the first path to be covered can be updated according to the location of the obstacle to obtain a second path to be covered.

[0086] In step S23, the set of paths to be covered is updated according to the second path to be covered to obtain an updated set of paths to be covered.

[0087] For example, after obtaining at least one second path to be covered, the set of paths to be covered can be updated according to the second path to be covered. For example, the first path to be covered is deleted from the set of paths to be covered, and at least one second path to be covered is added to the set to be covered, or the first path to be covered is replaced by at least one second path to be covered to update the set of paths to be covered and obtain an updated set of paths to be covered.

[0088] In step S24, coverage processing is performed according to the updated set of paths to be covered.

[0089] For example, after the set of paths to be covered is updated, the covering process may continue to be performed according to the updated set of paths to be covered. The specific process may refer to the relevant description of the aforementioned embodiment, and the embodiments of the present disclosure will not be described in detail here.

[0090] In this way, the electronic device can determine a set of paths to be covered including multiple paths to be covered based on the acquired original scene map, and in the process of performing coverage processing on the area to be covered based on the set of paths to be covered, when an obstacle is detected on the first path to be covered, the first path to be covered can be re-planned to obtain at least one second path to be covered, and the set of paths to be covered can be updated based on the second path to be covered to obtain an updated set of paths to be covered, and then coverage processing can be performed based on the updated set of paths to be covered. The path coverage method provided in the embodiment of the present disclosure can actively detect obstacles during the path coverage process, and by re-planning the path of the set of paths to be covered where the obstacles are located, obstacles can be actively and timely avoided during the coverage process, which can improve the coverage rate of the area to be covered, reduce the coverage repetition rate, and improve the coverage efficiency.

[0091] In a possible implementation, any path to be covered may include a first endpoint and a second endpoint. In the above step S22, when an obstacle is detected on the first path to be covered, re-planning the first path to be covered to obtain at least one second path to be covered may include:

[0092] When an obstacle is detected on the first path to be covered, the first path to be covered is replanned according to the first end point and the second end point of the first path to be covered and the position of the obstacle to obtain at least one second path to be covered.

[0093] For example, the path to be covered has two endpoints: a first endpoint and a second endpoint. In the embodiment of the present disclosure, the path to be covered is composed of a left endpoint and a right endpoint, and the left endpoint is used as the first endpoint and the right endpoint is used as the second endpoint to illustrate the embodiment of the present disclosure. In fact, the path to be covered can also use the left endpoint as the second endpoint and the right endpoint as the first endpoint. Or, in the case of Figure 1d In the case shown, the path to be covered is composed of an upper endpoint and a lower endpoint. The upper endpoint can be the first endpoint and the lower endpoint can be the second endpoint, or the lower endpoint can be the first endpoint and the upper endpoint can be the second endpoint. The embodiment of the present disclosure does not specifically limit the first endpoint and the second endpoint of the path to be covered, and all paths to be covered can be unified.

[0094] When an obstacle is detected on the first path to be covered, the position of the obstacle can be determined, and the first path to be covered can be replanned based on the position of the obstacle and the relationship between the first end point and the second end point of the first path to be covered, so that at least one second path to be covered obtained by replanning can avoid the obstacle. Exemplarily, when an obstacle is detected, the position of the obstacle can be determined by visual positioning, or the distance between the obstacle and the electronic device can be determined by laser radar, focal distance measurement, etc., and then the position of the obstacle can be obtained based on the position of the electronic device and the distance between the electronic device and the obstacle.

[0095] In a possible implementation, the obstacle is an object with a certain volume. Therefore, after obtaining the position of the obstacle, the coverage position of the obstacle can be determined according to the distance of the obstacle from the electronic device, the position of the electronic device and the volume parameters (length, width and height) of the obstacle. The coverage position of the obstacle can be used as the position of the obstacle. For example: the position of the electronic device is A0 (x0, y0), the obstacle is located a meters in front of the electronic device, and the volume of the obstacle is b1 meters long, b2 meters wide and b3 meters high, then the area between A1 (x0 + a, y0) and A2 (x0 + a + b1, y0) can be determined as the position of the obstacle.

[0096] Exemplarily, the volume parameters of the obstacle can be determined by a visual detection method, for example, the volume parameters of the obstacle can be obtained directly through image recognition; or after the type of obstacle is identified, the preset volume parameters of the obstacle type can be obtained (the preset volume parameters of various types of obstacles can be pre-set, for example, obstacles of a small volume type can be set with smaller preset volume parameters, and relatively, obstacles of a large volume type can be set with larger preset volume parameters). The embodiments of the present disclosure do not specifically limit the method of obtaining the volume parameters of the obstacles.

[0097] When neither the first endpoint nor the second endpoint of the first path to be covered is located within the position of the obstacle, it can be determined that the position of the obstacle is located between the first endpoint and the second endpoint of the first path to be covered; or, when the first endpoint of the first path to be covered is located within the position of the obstacle, it can be determined that the position of the obstacle coincides with the first endpoint of the first path to be covered, or, when the second endpoint of the first path to be covered is located within the position of the obstacle, it can be determined that the position of the obstacle coincides with the second endpoint of the first path to be covered.

[0098] For example, when the position of the obstacle is between the first endpoint and the second endpoint of the first path to be covered, the first path to be covered can be split from the position of the obstacle to obtain two paths to be covered, which theoretically do not cover the position of the obstacle; or, when the position of the obstacle is at the first endpoint or the second endpoint of the first path to be covered, the first endpoint or the second endpoint of the first path to be covered is re-determined according to the position of the obstacle to obtain a second path to be covered, and the second path to be covered is the new first path to be covered.

[0099] In this way, the path coverage method provided by the embodiment of the present disclosure can re-plan the path according to the first endpoint and the second endpoint of the first path to be covered and the position of the obstacle to obtain the second coverage path, so as to actively avoid obstacles in the path coverage and reduce the coverage repetition rate.

[0100] In a possible implementation, re-planning the first path to be covered according to the first endpoint and the second endpoint of the first path to be covered and the position of the obstacle to obtain at least one second path to be covered may include:

[0101] When the obstacle is located between the first end point and the second end point of the first path to be covered, the first path to be covered is split into a second path to be covered. m and the second path to be covered L s ,

[0102] Among them, the second path to be covered L m The first endpoint of the first path to be covered is taken as the first endpoint, and the first position between the first endpoint of the first path to be covered and the obstacle and close to the obstacle is taken as the second endpoint,

[0103] The second path L to be covered s A second position between the second end point of the first path to be covered and the obstacle and close to the obstacle is taken as the first end point, and the second end point of the first path to be covered is taken as the second end point.

[0104] For example, combining Figure 1a In the example shown, when the obstacle is located between the first end point and the second end point of the first path to be covered L1, the first path to be covered L1 can be split into the second path to be covered L1 according to the location of the obstacle. m and the second path to be covered L s , you can refer to Figure 3a As shown (in FIG3 , the obstacle position is marked as a black area, and the first position is marked as P 13 (x3, y1), the second position is marked as P 14 (x4, y1)). It should be noted that Figure 3a The first endpoint of the first path to be covered L1 is identified as P 11 (x1, y1), the second endpoint is marked as P 12 (x2, y1).

[0105] Exemplarily, a first position can be determined between the obstacle and the first endpoint, and the first position is close enough to the obstacle, for example: the first position and the position A1 of the obstacle can be separated by a first distance, and the first distance can be any value less than a preset distance threshold; or, the first distance can be determined according to the body parameters of the electronic device, for example: the body size radius of the electronic device is a meters, then the first distance can be determined to be a meters; or, the first distance can also be determined according to the performance parameters of the electronic device, for example: when the unit coverage cleaning distance of the electronic device is b meters (that is, the electronic device can clean the area from the current position to b meters in front at the current position), then the first distance can be determined to be b meters.

[0106] Similarly, a second position can be determined between the obstacle and the second endpoint, and the second position is also close enough to the obstacle. For example, the second position can be separated from the position A2 of the obstacle by a second distance, wherein the method for determining the second distance can refer to the method for determining the first distance.

[0107] After determining the first position and the second position, the second path to be covered L can be obtained by taking the first endpoint of the first path to be covered as the first endpoint and the first position as the second endpoint. m , and take the second position as the first endpoint and the second endpoint of the first path to be covered as the second endpoint to obtain the second path to be covered L s .

[0108] In this way, the path coverage method provided by the embodiment of the present disclosure can split the first path to be covered into two second paths to be covered according to the position of the obstacle when the position of the obstacle is between the first endpoint and the second endpoint of the first path to be covered, so as to actively avoid obstacles during path coverage, reduce coverage repetition rate, and improve coverage efficiency.

[0109] In a possible implementation, re-planning the first path to be covered according to the first endpoint and the second endpoint of the first path to be covered and the position of the obstacle to obtain at least one second path to be covered may include:

[0110] When the position of the obstacle coincides with the first end point of the first path to be covered, determining a third position close to the obstacle and between the obstacle and the second end point of the first path to be covered;

[0111] A second path L to be covered is obtained according to the third position and the second end point of the first path to be covered z , wherein the second path to be covered L z Taking the third position as the first endpoint and taking the second endpoint of the first path to be covered as the second endpoint;

[0112] Alternatively, when the position of the obstacle coincides with the second end point of the first path to be covered, determining a fourth position close to the obstacle and between the obstacle and the first end point of the first path to be covered;

[0113] A second path L to be covered is obtained according to the fourth position and the first end point of the first path to be covered x , wherein the second path to be covered L x The first endpoint of the first path to be covered is used as the first endpoint, and the fourth position is used as the second endpoint.

[0114] For example, when the position of the obstacle coincides with the first end point of the first path to be covered, a third position (at Figure 3b In the example, the third position is marked as P 15 (x5, y1)), the third position is close enough to the obstacle. The specific determination process of the third position can refer to the determination process of the first position, and the embodiment of the present disclosure will not be repeated here. After determining the third position, the second endpoint of the first path to be covered can be used as the second endpoint, and the third position can be used as the first endpoint to obtain the second path to be covered L z , Exemplarily, the second path to be covered L z You can refer to Figure 3b shown.

[0115] Alternatively, when the position of the obstacle coincides with the second end point of the first path to be covered, a fourth position (at Figure 3c In the example, the third position is marked as P 16(x6, y1)), the fourth position is close enough to the obstacle. The specific determination process of the fourth position can refer to the determination process of the first position, and the embodiment of the present disclosure will not be repeated here. After determining the fourth position, the first endpoint of the first path to be covered can be used as the first endpoint, and the fourth position can be used as the second endpoint to obtain the second path to be covered L x , Exemplarily, the second path to be covered L x You can refer to Figure 3c shown.

[0116] In this way, the path coverage method provided by the embodiment of the present disclosure can, when the position of the obstacle coincides with the first endpoint or the second endpoint of the first path to be covered, re-plan the first path to be covered according to the position of the obstacle to obtain the second path to be covered, so as to actively avoid obstacles during path coverage, reduce coverage repetition rate, and improve coverage efficiency.

[0117] In a possible implementation, the moving direction of the electronic device is from a starting endpoint to a destination endpoint, the starting endpoint is a first endpoint or a second endpoint of the path to be covered, and the destination endpoint is another endpoint of the path to be covered except the starting endpoint.

[0118] The updating of the set of paths to be covered according to the second path to be covered to obtain an updated set of paths to be covered includes:

[0119] Determine, from the second path to be covered, a target path to be covered that includes a starting endpoint of the first path to be covered;

[0120] Replacing the first path to be covered in the set of paths to be covered with the target path to be covered;

[0121] Determine whether there is a newly added path to be covered, wherein the newly added path to be covered is a second path to be covered in the second path to be covered except the target path to be covered;

[0122] In the case where the newly added path to be covered exists, adding the newly added path to be covered to the set of paths to be covered;

[0123] Get the updated set of paths to be covered.

[0124] For example, when an electronic device performs covering processing on a path to be covered, if it moves from the first endpoint to the second endpoint of the path to be covered, the first endpoint can be determined as the starting endpoint and the second endpoint can be determined as the destination endpoint; conversely, if the electronic device moves from the second endpoint to the first endpoint of the path to be covered, the second endpoint can be determined as the starting endpoint and the first endpoint can be determined as the destination endpoint.

[0125] After obtaining at least one second path to be covered, the target path to be covered can be determined from the second paths to be covered according to the starting endpoint of the first path to be covered. The target path to be covered includes the starting endpoint of the first path to be covered. If there are other second paths to be covered in addition to the target path to be covered, the other second paths to be covered can be determined as newly added paths to be covered.

[0126] In one example, the first path to be covered is split into the second path L to be covered m and the second path to be covered L s , when the starting endpoint of the first path to be covered is the first endpoint, since the second path to be covered L m Taking the first endpoint as the first endpoint, the second path to be covered L can be determined. m is the target path to be covered, and the second path to be covered L s is a newly added path to be covered; or, in the case where the starting endpoint of the first path to be covered is the second endpoint, since the second path to be covered L s Taking the second endpoint as the second endpoint, the second path to be covered L can be determined. s is the target path to be covered, and the second path to be covered L m Add a new path to be covered.

[0127] That is, when the starting endpoint of the first path to be covered is the first endpoint of the first path to be covered, the second path to be covered L m Replace the first path to be covered and add the second path to be covered L to the set of paths to be covered s , get the updated set of paths to be covered;

[0128] Alternatively, when the starting endpoint of the first path to be covered is the second endpoint of the first path to be covered, the second path to be covered L is used. s Replace the first path to be covered and add the second path to be covered L to the set of paths to be covered m , and obtain the updated set of paths to be covered.

[0129] The first path to be covered is still L1 (P 11 (x1, y1), P 12 (x2, y1)) as an example, when the starting endpoint of the first path to be covered is the first endpoint of the first path to be covered L1, the second path to be covered L m (P 11 (x1, y1), P 13 (x3, y1)) as the target path to be covered, the second path to be covered L m (P 11 (x1, y1), P 13(x3, y1)) replaces the first path to be covered L1 in the set of paths to be covered. Exemplarily, in the set of paths to be covered, the second path to be covered L m as the new first path to be covered L1, and the second path to be covered L m The second endpoint P 13 The second endpoint P of the new first path L1 to be covered 12 , and then obtain the new first path to be covered L1 (P 11 (x1, y1), P 12 (x3, y1)), and the second path to be covered L s (P 14 (x4, y1), P 12 (x2, y1)) is added to the set of paths to be covered. After being added to the set of paths to be covered, the second path to be covered L s Identified as (P s1 (x4, y1), P s2 (x2, y1)), and obtain the updated set of paths to be covered. The set of paths to be covered corresponding to the updated set of paths to be covered can be referred to in the graph Figure 4a shown.

[0130] Alternatively, when the starting endpoint of the first path to be covered is the second endpoint of the first path to be covered L1, the second path to be covered L s (P 14 (x4, y1), P 12 (x2, y1)) as the target path to be covered, the second path to be covered L s (P 14 (x4, y1), P 12 (x2, y1)) replaces the first path to be covered L1 in the set to be covered. Exemplarily, in the set of paths to be covered, the second path to be covered L s as the new first path to be covered L1, and the second path to be covered L s The first endpoint P 14 The second endpoint P of the new first path L1 to be covered 11 , and then obtain the new first path to be covered L1 (P 11 (x4, y1), P 12 (x2, y1)), and the second path to be covered L m (P 11 (x1, y1), P 13 (x3, y1)) is added to the set of paths to be covered. After being added to the set of paths to be covered, the second path to be covered L m Identified as (P m1 (x1, y1), Pm2 (x3, y1)), and obtain the updated set of paths to be covered.

[0131] In another example, when the starting endpoint of the first path to be covered is the first endpoint, after re-planning the first path to be covered, a second path to be covered P is obtained. z , since the second path to be covered P z Taking the first endpoint of the first path to be covered as the first endpoint, the second path to be covered P can be determined z is the target path to be covered; or, in the case where the starting endpoint of the first path to be covered is the second endpoint, the first path to be covered is replanned to obtain the second path to be covered P x , since the second path to be covered P x Taking the second endpoint of the first path to be covered as the second endpoint, the second path to be covered P can be determined x The target path to be covered.

[0132] In the scenario of this example, there is no other second path to be covered except the target path to be covered, so there is no new path to be covered. Therefore, after replacing the first path to be covered in the set of paths to be covered with the target path to be covered, an updated set of paths to be covered can be obtained.

[0133] The first path to be covered is still L1 (P 11 (x1, y1), P 12 (x2, y1)) as an example, when the starting endpoint of the first path to be covered is the second endpoint of the first path to be covered L1, the second path to be covered L z (P 15 (x5, y1), P 12 (x2, y1)) as the target path to be covered, the second path to be covered L z (P 15 (x5, y1), P 12 (x2, y1)) replaces the first path to be covered L1 in the set of paths to be covered. Exemplarily, in the set of paths to be covered, the second path to be covered L z as the new first path to be covered L1, and the second path to be covered L z The first endpoint P 15 As the first endpoint P of the new first path to be covered L1 11 , and then obtain the new first path to be covered L1 (P 11 (x5, y1), P 12 (x2, y1)), and then get the updated set of paths to be covered. The updated set to be covered corresponding to the set to be covered graph can be referred to Figure 4bor, in the case where the starting endpoint of the first path to be covered is the first endpoint of the first path to be covered L1, the second path to be covered L x (P 11 (x1, y1), P 16 (x6, y1)) as the target path to be covered, the second path to be covered L x (P 11 (x1, y1), P 16 (x6, y1)) replaces the first path to be covered L1 in the set to be covered. Exemplarily, in the set of paths to be covered, the second path to be covered L x as the new first path to be covered L1, and the second path to be covered L x The second endpoint P 16 The second endpoint P of the new first path L1 to be covered 12 , and then obtain the new first path to be covered L1 (P 11 (x1, y1), P 12 (x6, y1)).

[0134] In a possible implementation manner, the updating the set of paths to be covered according to the second path to be covered to obtain an updated set of paths to be covered may further include:

[0135] When the target path to be covered does not exist, the second path to be covered is used to replace the first path to be covered in the set of paths to be covered.

[0136] For example, when the coverage processing of the first path to be covered is not performed, if an obstacle is detected at the starting end point corresponding to the first path to be covered, a second path to be covered can be obtained after re-planning the first path to be covered. The second path to be covered should avoid the location of the obstacle, that is, the second path to be covered does not include the starting end point of the first path to be covered. At this time, the second path to be covered can be directly used to replace the first path to be covered, so as to update the set of paths to be covered and obtain an updated set of paths to be covered.

[0137] In this way, the path coverage method of the embodiment of the present disclosure can not only realize active obstacle avoidance in path coverage, reduce coverage repetition rate, and improve coverage efficiency, but also in the process of updating the path set to be covered, the electronic device can normally perform the path coverage work, and can reduce the impact of the process of updating the path set to be covered on the work of the electronic device.

[0138] In a possible implementation, performing coverage processing according to the updated set of paths to be covered includes:

[0139] The electronic device moves from a starting end point of a current path to be covered to a destination end point of the current path to be covered;

[0140] When the electronic device moves to the destination endpoint of the current path to be covered, the current path to be covered is updated as a covered path in the set of paths to be covered,

[0141] The starting endpoint of the current path to be covered is the first endpoint or the second endpoint of the current path to be covered, and the destination endpoint of the current path to be covered is another endpoint of the current path to be covered except the starting endpoint.

[0142] For example, in the process of the electronic device performing the covering process according to the set of paths to be covered or the updated set of paths to be covered, the electronic device can move from the starting end point of the path to be covered to the destination end point of the path to be covered. The path to be covered on which the electronic device is currently performing the covering process can be determined as the current path to be covered. When the electronic device moves from the starting end point of the current path to be covered to the destination end point, it can be determined that the covering process for the current path to be covered has been completed, and the current path to be covered can be updated as a covered path in the set of paths to be covered.

[0143] In fact, when the electronic device completes the coverage processing for the current path to be covered, it can also delete the current path to be covered from the set of paths to be covered. The embodiment of the present disclosure does not specifically limit the processing method of the path to be covered that has completed the coverage processing. The methods that can distinguish between the paths that have completed the coverage and the paths that have not performed the coverage processing are applicable to the embodiments of the present disclosure.

[0144] In this way, the coverage method provided by the embodiment of the present disclosure can update the set of paths to be covered in real time according to the coverage processing progress of the electronic device, so that the coverage progress of the area to be covered can be known through the set of paths to be covered, thereby reducing the occurrence of repeated coverage processing for the covered paths, reducing the coverage repetition rate, and improving the coverage efficiency.

[0145] In a possible implementation, performing coverage processing according to the updated set of paths to be covered further includes:

[0146] When the electronic device moves from the starting endpoint of the current path to be covered to the destination endpoint of the current path to be covered, determining a third path to be covered from the updated set of paths to be covered according to the destination endpoint of the current path to be covered;

[0147] The electronic device moves from the current path to be covered to the third path to be covered;

[0148] The third path to be covered is used as a new current path to be covered.

[0149] For example, when an electronic device moves from the starting endpoint of the current path to be covered to the destination endpoint of the current path to be covered, it can be determined that the coverage processing for the current path to be covered has been completed, and then the third path to be covered that is to be covered and is to be determined as the next path to be covered in the set of paths to be covered according to the destination endpoint of the current path to be covered, and after updating the current path to be covered in the set to be covered to a covered path, the device moves to the third path to be covered, uses the third path to be covered as the new current path to be covered, and performs coverage processing for the new current path to be covered, and so on, until there is no third path to be covered in the set of paths to be covered, or until there is no path to be covered.

[0150] In a possible implementation manner, the electronic device moving from the current path to be covered to the third path to be covered may include:

[0151] The electronic device moves from the destination endpoint of the current path to be covered to the starting endpoint of the third path to be covered;

[0152] Wherein, when the destination endpoint of the current path to be covered is the second endpoint of the current path to be covered, the second endpoint of the third path to be covered is determined as the starting endpoint of the third path to be covered, and the first endpoint of the third path to be covered is determined as the destination endpoint of the third path to be covered; or,

[0153] When the destination endpoint of the current path to be covered is the first endpoint of the current path to be covered, the first endpoint of the third path to be covered is determined as the starting endpoint of the third path to be covered, and the second endpoint of the third path to be covered is determined as the destination endpoint of the third path to be covered.

[0154] For example, after determining the third path to be covered, the electronic device can determine the starting endpoint and destination endpoint of the third path to be covered based on the destination endpoint of the current path to be covered, and plan a connection path between the destination endpoint of the current path to be covered and the starting endpoint of the third path to be covered, and move from the destination endpoint of the current path to be covered to the starting endpoint of the third path to be covered through the connection path.

[0155] The moving direction of the current path to be covered is opposite to the moving direction of the third path to be covered, that is, when the current path to be covered moves from the first endpoint to the second endpoint, the third path to be covered moves from the second endpoint to the first endpoint, and vice versa, when the current path to be covered moves from the second endpoint to the first endpoint, the third path to be covered moves from the first endpoint to the second endpoint, that is, the destination endpoint of the current path to be covered and the starting endpoint of the third path to be covered should be the same type of endpoints, that is, both are the first endpoints or both are the second endpoints, so that the movement trajectory of the electronic device in the area to be covered can present a "bow shape". Exemplarily, when the destination endpoint of the current path to be covered is the first endpoint, the starting endpoint of the third path to be covered should be the first endpoint of the third path to be covered, and the destination endpoint of the third path to be covered should be the second endpoint of the third path to be covered; or, when the destination endpoint of the current path to be covered is the second endpoint, the starting endpoint of the third path to be covered should be the second endpoint of the third path to be covered, and the destination endpoint of the third path to be covered should be the first endpoint of the third path to be covered.

[0156] In this way, the path coverage method provided by the embodiment of the present disclosure can enable the electronic device to cover the area to be covered with a "bow-shaped" moving trajectory, which can reduce the coverage repetition rate and improve the coverage efficiency.

[0157] In a possible implementation manner, determining the third path to be covered from the updated path to be covered according to the destination endpoint of the current path to be covered may include:

[0158] Determine whether there is a path to be covered ahead of the current path to be covered in the current scene coverage direction;

[0159] When there is a path to be covered ahead of the current path to be covered in the current scene coverage direction, a third path to be covered is determined from the paths to be covered ahead of the current path to be covered according to the destination endpoint of the current path to be covered.

[0160] For example, the current scene coverage direction for the area to be covered may be determined, and the current scene coverage direction may be used to indicate the coverage direction of the electronic device for the area to be covered. Figure 4a In the set of paths to be covered shown in FIG. 1 , it can be determined that the direction from top to bottom is the current scene coverage direction (such as Figure 4a In the direction indicated by the arrow in the middle), that is, the coverage of the area to be covered is performed from top to bottom. At this time, the path to be covered L1 can be determined as the initial path; or, the direction from bottom to top (such as Figure 4a The opposite direction of the direction indicated by the arrow in the middle) is the current scene coverage direction, that is, the coverage of the area to be covered is performed from bottom to top. At this time, the path to be covered L can be setn is the initial path. In fact, when the path to be covered includes an upper endpoint and a lower endpoint (such as Figure 1d As shown), it can be determined that the current scene coverage direction is from left to right, or from right to left.

[0161] It can be determined whether there is another path to be covered ahead of the current path to be covered in the current scene coverage direction. Figure 4a In the scene set diagram to be covered, the current path to be covered is the path to be covered L1, and it is determined that there are paths to be covered (paths to be covered L2, ..., paths to be covered L1) in front of the path to be covered n ), then the to-be-covered paths existing in front of the to-be-covered path L1 (the to-be-covered path L2, ..., the to-be-covered path L n )Determine the third path to be covered.

[0162] In a possible implementation, the determining, according to the destination endpoint of the current path to be covered, a third path to be covered from the paths to be covered ahead of the current path to be covered includes:

[0163] Determine a target endpoint from endpoints corresponding to the path to be covered ahead of the current path to be covered, the target endpoint being an endpoint of the same type as the destination endpoint of the current path to be covered, and the target endpoint being closest to the destination endpoint of the current path to be covered;

[0164] It is determined that the path to be covered corresponding to the target endpoint is the third path to be covered.

[0165] For example, the trajectory of an electronic device moving from the starting endpoint of the current path to be covered to the destination endpoint of the third path to be covered is in the shape of a "bow", and the distance required for the electronic device to move to the third path to be covered is the shortest. Therefore, the third path to be covered can be determined based on the destination endpoint of the current path to be covered, that is, among the paths to be covered in front of the current path to be covered, the distance between the starting endpoint of the third path to be covered and the destination endpoint of the current path to be covered is the shortest, and is of the same type as the destination endpoint of the current path to be covered.

[0166] After determining a target endpoint of the same type as the destination endpoint of the current path to be covered and closest to the destination endpoint of the current path to be covered from the endpoints corresponding to the path to be covered in front of the current path to be covered, the path to be covered where the target endpoint is located can be determined as the third path to be covered.

[0167] For example: Figure 4a In the example shown, it is assumed that the current path to be covered is the path to be covered L1, and the destination endpoint of the path to be covered L1 is the second endpoint P 12In the case of n ) corresponding to the second endpoint P 12 The closest target endpoint is the second endpoint P of the path L2 to be covered. 22 , that is, the path to be covered L2 is determined to be the third path to be covered (the starting end point of the third path to be covered is the second end point P 22 , the destination endpoint is the first endpoint P 21 ), the electronic device can be connected to the second terminal P 22 Move to the first endpoint P of the path L2 to be covered 21 , perform coverage processing on the path L2 to be covered.

[0168] Or, in Figure 4a In the example shown, when the electronic device completes the covering process for the path to be covered L2, the destination endpoint of the path to be covered L2 is the first endpoint P 21 , the path to be covered can be found from the path to be covered ahead of the path to be covered L2 (the path to be covered L3, ..., the path to be covered L n ) corresponding to the first endpoint P 21 The closest target endpoint is the first endpoint P of the path L3 to be covered. 31 , that is, the path to be covered L3 can be determined as the third path to be covered.

[0169] In this way, the trajectory of the electronic device moving from the current path to be covered to the third path to be covered can be made into a "bow shape" with the shortest moving distance, which can reduce the coverage repetition rate and thus improve the coverage efficiency of the electronic device.

[0170] In a possible implementation manner, determining a third path to be covered from the updated path to be covered according to the destination endpoint of the current path to be covered may further include:

[0171] In the case that there is no path to be covered ahead of the current path to be covered in the current scene coverage direction, determining whether there is a path to be covered in the same row as the current path to be covered according to the destination endpoint of the current path to be covered;

[0172] In the case that there is a path to be covered in the same row as the current path to be covered, the path to be covered in the same row as the current path to be covered is determined to be the third path to be covered.

[0173] For example, when there is no path to be covered in front of the current path to be covered in the current scene coverage direction, it can be determined that the current path to be covered where the electronic device is located is the last path to be covered in the current scene coverage direction. At this time, it can be determined whether there is a path to be covered in the same row as the current path to be covered.

[0174] Exemplarily, it is possible to determine from the set of paths to be covered whether there is a path to be covered whose endpoint has the same horizontal coordinate as the starting endpoint or the destination endpoint of the current path to be covered, and if such a path to be covered exists, the path to be covered can be used as the third path to be covered, and the electronic device can move from the destination endpoint of the current path to be covered to the starting endpoint of the third path to be covered, and perform coverage processing on the third path to be covered.

[0175] For example, assuming that the current path to be covered is the path to be covered L n , the path to be covered L in the current scene coverage direction n There is no path to be covered in front of , but there is a path L to be covered n The path L to be covered in the same row o , then the path to be covered L o Determined as the third path to be covered, and can be covered from the path L n Move to the path L to be covered o The starting endpoint of the path to be covered L o Path coverage processing.

[0176] In a possible implementation manner, determining a third path to be covered from the updated path to be covered according to the destination endpoint of the current path to be covered may further include:

[0177] When there is no path to be covered in the same row as the current path to be covered, the current scene coverage direction is changed.

[0178] For example, when there is no path to be covered in the same row as the current path to be covered, the current scene coverage direction can be changed to reverse the current scene coverage direction. For example: when the current scene coverage direction is from top to bottom and there is no path to be covered in front, if there is no path to be covered in the same row as the current path to be covered, the current scene coverage direction can be changed to a direction from bottom to top, and after the current scene coverage direction is changed, it is determined whether there is a path to be covered in front of the current path to be covered in the changed current scene coverage direction, and a third path to be covered is determined in the path to be covered in front of the current path to be covered. The specific process of determining the third path to be covered can refer to the aforementioned embodiment, and the embodiments of the present disclosure will not be repeated here.

[0179] In a possible implementation, the method may further include:

[0180] In the case where no obstacle is detected at the position of the first obstacle, determining whether there is a fourth path to be covered associated with the position of the first obstacle in the path to be covered;

[0181] In the case where the fourth path to be covered exists, re-planning the fourth path to be covered according to the position of the first obstacle to obtain a fifth path to be covered;

[0182] The set of paths to be covered is updated according to the fifth path to be covered to obtain an updated set of paths to be covered,

[0183] The position of the first obstacle includes the position of the obstacle within the detection range of the electronic device.

[0184] For example, when performing path coverage, the electronic device can detect whether there are obstacles in the surrounding environment, and at the same time detect whether the detected obstacle has been removed. If the obstacle has been removed, the path to be covered near the obstacle can be re-planned, or the path can be planned for the area where the obstacle is located to achieve coverage processing for the obstacle location.

[0185] For example, Figure 4a In the example shown, when the electronic device executes the path to be covered L3, the covered path L2 and the path to be covered L s-1 If the position of the obstacle between the two paths is within the detection range of the electronic device, the position of the obstacle can be determined as the position of the first obstacle, and it is detected whether there is an obstacle at the position of the first obstacle. If it is detected that there is no obstacle at the position of the first obstacle, the path to be covered L near the position of the first obstacle can be determined. s-1 is a fourth path to be covered associated with the first obstacle, and the path to be covered L is set according to the position of the first obstacle. s-1 The path planning is performed again to obtain the fifth path to be covered.

[0186] Exemplarily, assuming that the position of the first obstacle includes the area A3 (x8, y3) to A4 (x9, y3), then the position of the first obstacle can be far away from the path to be covered L s-1 The fifth position is determined at the position close to A3 (x8, y3), or A3 (x8, y3) can be directly determined as the fifth position, and then the fifth position can be used to replace the path to be covered L s-1 The first endpoint of the path to be covered is obtained by taking the fifth position as the first endpoint and the path to be covered L as the first endpoint.s-1 The second endpoint of is the second endpoint.

[0187] The fifth to-be-covered path can be used to directly replace the to-be-covered path L in the to-be-covered path set. s-1 , an updated set of paths to be covered is obtained. The replacement process can refer to the relevant description of the aforementioned embodiment, and the embodiments of the present disclosure will not be repeated here.

[0188] In a possible implementation, the method may further include:

[0189] In the case where the fourth path to be covered does not exist, performing path planning according to the position of the first obstacle to obtain a sixth path to be covered;

[0190] The set of paths to be covered is updated according to the sixth path to be covered to obtain an updated set of paths to be covered.

[0191] For example, Figure 4b In the example shown, when the electronic device reaches the path to be covered L2, the position of the obstacle near the covered path L1 ( Figure 4b If the black area in the upper left corner of the figure is within the detection range of the electronic device, the position of the obstacle can be determined as the position of the first obstacle, and whether there is an obstacle at the position of the first obstacle is detected. When it is detected that there is no obstacle at the position of the first obstacle, since the path near the position is the covered path L1, there is no path to be covered nearby, that is, there is no fourth path to be covered associated with the position of the first obstacle, then path planning can be performed according to the position of the first obstacle to obtain the sixth path to be covered.

[0192] Exemplarily, assuming that the position of the first obstacle includes the area from A5 (x10, y1) to A6 (x11, y1), the sixth position and the seventh position can be respectively determined at the two end points close to the position of the first obstacle, or A5 (x10, y1) and A6 (x11, y1) can be directly determined as the sixth position and the seventh position, and the sixth position and the seventh position can be used as the first end point and the second end point to obtain the sixth path to be covered, and the sixth path to be covered is added to the set of paths to be covered to obtain an updated set of paths to be covered.

[0193] In this way, the path coverage method provided by the embodiment of the present disclosure can adaptively plan the path according to the movement of the obstacle, and can re-plan the path according to the position of the obstacle after the obstacle is removed, so as to timely cover and clean the area occupied by the obstacle, which can effectively increase the coverage area and reduce the coverage repetition rate.

[0194] In a possible implementation, performing coverage processing according to the updated set of paths to be covered further includes:

[0195] In the case where the third path to be covered does not exist, detecting the area where the obstacle is located;

[0196] In the case that no obstacle is detected in the area where the obstacle is located, a covering process is performed on the area where the obstacle is located.

[0197] For example, when there is no third path to be covered in the set to be covered, it can be determined that all the paths to be covered in the set to be covered have completed the coverage processing. At this time, the electronic device can move to the area where the obstacle is located according to the position of the obstacle, and detect the area where the obstacle is located again to detect whether there are still obstacles in the area where the obstacle is located. The specific detection process can refer to the aforementioned embodiment, and the embodiment of the present disclosure will not be repeated here.

[0198] When no obstacle is detected in the area where the obstacle is located, it can be determined that the obstacle has been removed, so coverage processing can be performed on the area where the obstacle is located, so that the coverage rate of the area to be covered can be improved.

[0199] The embodiments of the present disclosure can be applied to any electronic device that performs tasks such as covering and cleaning. In order to enable those skilled in the art to better understand the embodiments of the present disclosure, the embodiments of the present disclosure are described below using a sweeping robot as an example.

[0200] After obtaining the original scene map corresponding to the cleaning area, the sweeping robot can perform path planning according to the original scene map to obtain a set of paths to be covered. The set of paths to be covered corresponding to the set of paths to be covered is shown in FIG. Figure 1a As shown. Figure 1a In the set of paths to be covered shown in the figure, the path to be covered includes two endpoints, left and right. Let the first endpoint (left endpoint) of the i-th path to be covered be P i1 , the second endpoint (right endpoint) is P i2 , then L1(P 11 , P 12 )、L2(P 21 , P 22 ), ....(P k1 ,P k2 ) together constitute a set of paths to be covered. At this time, the paths to be covered in the set of paths to be covered are not connected.

[0201] The sweeping robot can determine the initial path from the set of paths to be covered and plan to start from the current position P r To the starting endpoint of the initial path (assuming the starting endpoint is P 11) and moves to the starting endpoint P through the connection path 11 , perform path coverage for the path to be covered L1. r To P 11 When there are no obstacles between them, a straight line can be used to connect them directly. Otherwise, algorithms such as A* (A-star algorithm, heuristic search) or RRT (rapidly exploring random tree, rapidly expanding random tree) can be used to generate a feasible connection path.

[0202] The robot vacuum cleaner controller can periodically obtain the latest map of the surrounding environment from the perception system (the perception system can be composed of image acquisition devices, laser radar and other devices, which can sense the environment around the robot vacuum cleaner and generate a map). 11 , P 12 )When an obstacle appears in front of the path L1(P 11 , P 12 ) is split from the location of the obstacle to obtain a new path to be covered L1 (P 11 , P 12 ) and the path to be covered L s (P s1 , P s2 ), using the new path to be covered L1(P 11 , P 12 ) replaces the to-be-covered path L1 (P 11 , P 12 ), the path to be covered L s (P s1 , P s2 ) is added to the set of paths to be covered. The updated set of paths to be covered can be referenced Figure 4a .

[0203] After executing the to-be-covered path L1(P 11 , P 12 ) is covered, the next path to be covered needs to be determined. First, the path to be covered L1 (P 11 , P 12 ) is removed from the set of paths to be covered (or updated to a covered path), and then the next path to be covered is selected from the updated set of paths to be covered. Figure 4a In the case shown in FIG. 1 , when the cleaning robot moves from the first end point to the second end point (P 11 To P 12 ), with the path in the set of paths to be covered being in front of the path to be covered L1 and the second endpoint being at a distance P 12The nearest path to be covered is used as the next path to be covered. 12 The nearest second endpoint is P 22 , then the second endpoint in the set of paths to be covered is P 22 The path to be covered L2 is taken as the path to be covered to be covered, and the path moves to the starting end point of the path to be covered L2 to perform the covering process on the path to be covered L2.

[0204] The above process is repeated until there is no path to be covered in the set of paths to be covered.

[0205] For example, it is assumed that the sweeping robot updates the set of paths to be covered (the updated set of paths to be covered is as follows: Figure 4a If no obstacle is detected again, the sweeping robot Figure 4a The covered path trajectory of the set of paths to be covered is shown as Figure 5a ( Figure 5a The medium-thick line trajectory is the coverage trajectory of the path to be covered, and the thin line is the connection trajectory of two paths to be covered). In the current scenario, if the sweeping robot does not have a path to be covered in the set of paths to be covered, it can detect and process the area where the obstacle is located in the cleaning area, and if no obstacle is detected in the area where the obstacle is located, it can cover the area where the obstacle is located.

[0206] like Figure 5a In the scene shown, if obstacle 1 (carton) moves from area 1 to area 2, the scene after the move will be as follows: Figure 5b As shown, the sweeping robot can detect area 1, and if no obstacle is detected in area 1, it can perform coverage processing on area 1 to improve the coverage rate of the area to be cleaned. In fact, the electronic device can also detect the position of the obstacle detected in the detection range during the path coverage process, and re-plan the path according to the position of the obstacle if no obstacle is detected at the position of the obstacle.

[0207] The embodiments of the present disclosure can be applied to, but not limited to, electronic devices such as sweeping robots that perform tasks such as coverage cleaning. Taking a sweeping robot as an example, the embodiments of the present disclosure can obtain surrounding environment information based on image acquisition equipment, lidar equipment, infrared sensing equipment, etc., and can autonomously perform coverage cleaning of the area to be cleaned. It can also actively avoid static and dynamic obstacles during cleaning, has high coverage cleaning efficiency, and reduces the area of ​​repeated cleaning, and can adapt to complex cleaning environments.

[0208] It can be understood that the above-mentioned various method embodiments mentioned in the present disclosure can be combined with each other to form a combined embodiment without violating the principle logic. Due to space limitations, the present disclosure will not repeat them. It can be understood by those skilled in the art that in the above-mentioned method of the specific implementation method, the specific execution order of each step should be determined according to its function and possible internal logic.

[0209] In addition, the present disclosure also provides a path coverage device, an electronic device, a computer-readable storage medium, and a program, all of which can be used to implement any path coverage method provided by the present disclosure. The corresponding technical solutions and descriptions are referred to the corresponding records in the method part and will not be repeated here.

[0210] Figure 6 A block diagram of a path coverage device according to an embodiment of the present disclosure is shown as follows: Figure 6 As shown, the device comprises:

[0211] A first determining module 61 may be used to determine a set of paths to be covered according to an original scene map, wherein the set of paths to be covered includes a plurality of paths to be covered;

[0212] The first path planning module 62 may be configured to, during the process of performing coverage processing according to the set of paths to be covered, re-plan the first path to be covered to obtain at least one second path to be covered when an obstacle is detected on the first path to be covered, wherein the first path to be covered includes a path to be covered within the detection range of the electronic device;

[0213] A first updating module 63 may be configured to update the set of paths to be covered according to the second path to be covered to obtain an updated set of paths to be covered;

[0214] The processing module 64 may be configured to perform coverage processing according to the updated set of paths to be covered.

[0215] In this way, the electronic device can determine a set of paths to be covered including multiple paths to be covered based on the acquired original scene map, and in the process of performing coverage processing on the area to be covered based on the set of paths to be covered, when an obstacle is detected on the first path to be covered, the first path to be covered can be re-planned to obtain at least one second path to be covered, and the set of paths to be covered can be updated based on the second path to be covered to obtain an updated set of paths to be covered, and then coverage processing can be performed based on the updated set of paths to be covered. The path covering device provided in the embodiment of the present disclosure can actively detect obstacles during the path covering process, and by re-planning the path of the set of paths to be covered where the obstacles are located, obstacles can be actively and timely avoided during the coverage process, which can improve the coverage rate of the area to be covered, reduce the coverage repetition rate, and improve the coverage efficiency.

[0216] In a possible implementation, any path to be covered includes a first endpoint and a second endpoint, and the first path planning module 62 may also be used to:

[0217] When an obstacle is detected on the first path to be covered, the first path to be covered is replanned according to the first end point and the second end point of the first path to be covered and the position of the obstacle to obtain at least one second path to be covered.

[0218] In a possible implementation, the first path planning module 62 may also be used to:

[0219] When the obstacle is located between the first end point and the second end point of the first path to be covered, the first path to be covered is split into a second path to be covered. m and the second path to be covered L s ,

[0220] Among them, the second path to be covered L m The first endpoint of the first path to be covered is taken as the first endpoint, and the first position between the first endpoint of the first path to be covered and the obstacle and close to the obstacle is taken as the second endpoint,

[0221] The second path L to be covered s A second position between the second end point of the first path to be covered and the obstacle and close to the obstacle is taken as the first end point, and the second end point of the first path to be covered is taken as the second end point.

[0222] In a possible implementation, the first path planning module 62 may also be used to:

[0223] When the position of the obstacle coincides with the first end point of the first path to be covered, determining a third position close to the obstacle and between the obstacle and the second end point of the first path to be covered;

[0224] A second path L to be covered is obtained according to the third position and the second end point of the first path to be covered z , wherein the second path to be covered L z Taking the third position as the first endpoint and taking the second endpoint of the first path to be covered as the second endpoint;

[0225] or,

[0226] In a case where the position of the obstacle coincides with the second end point of the first path to be covered, determining a fourth position close to the obstacle and located between the obstacle and the first end point of the first path to be covered;

[0227] A second path L to be covered is obtained according to the fourth position and the first end point of the first path to be covered x , wherein the second path to be covered L x The first endpoint of the first path to be covered is used as the first endpoint, and the fourth position is used as the second endpoint.

[0228] In a possible implementation, the moving direction of the electronic device is from a starting endpoint to a destination endpoint, the starting endpoint is a first endpoint or a second endpoint of the path to be covered, and the destination endpoint is another endpoint in the path to be covered except the starting endpoint. The first updating module 63 may also be used to:

[0229] Determine, from the second path to be covered, a target path to be covered that includes a starting endpoint of the first path to be covered;

[0230] Replacing the first path to be covered in the set of paths to be covered with the target path to be covered;

[0231] Determine whether there is a newly added path to be covered, wherein the newly added path to be covered is a second path to be covered in the second path to be covered except the target path to be covered;

[0232] In the case where the newly added path to be covered exists, adding the newly added path to be covered to the set of paths to be covered;

[0233] Get the updated set of paths to be covered.

[0234] In a possible implementation, the first updating module 63 may also be used to:

[0235] When the target path to be covered does not exist, the second path to be covered is used to replace the first path to be covered in the set of paths to be covered.

[0236] In a possible implementation, the processing module 64 may also be used to:

[0237] The electronic device moves from a starting end point of a current path to be covered to a destination end point of the current path to be covered;

[0238] When the electronic device moves to the destination endpoint of the current path to be covered, the current path to be covered is updated as a covered path in the set of paths to be covered,

[0239] The starting endpoint of the current path to be covered is the first endpoint or the second endpoint of the current path to be covered, and the destination endpoint of the current path to be covered is another endpoint of the current path to be covered except the starting endpoint.

[0240] In a possible implementation, the processing module 64 may also be used to:

[0241] When the electronic device moves from the starting endpoint of the current path to be covered to the destination endpoint of the current path to be covered, determining a third path to be covered from the updated set of paths to be covered according to the destination endpoint of the current path to be covered;

[0242] The electronic device moves from the current path to be covered to the third path to be covered;

[0243] The third path to be covered is used as a new current path to be covered.

[0244] In a possible implementation, the processing module 64 may also be used to:

[0245] The electronic device moves from the destination endpoint of the current path to be covered to the starting endpoint of the third path to be covered;

[0246] Wherein, when the destination endpoint of the current path to be covered is the second endpoint of the current path to be covered, the second endpoint of the third path to be covered is determined as the starting endpoint of the third path to be covered, and the first endpoint of the third path to be covered is determined as the destination endpoint of the third path to be covered; or,

[0247] When the destination endpoint of the current path to be covered is the first endpoint of the current path to be covered, the first endpoint of the third path to be covered is determined as the starting endpoint of the third path to be covered, and the second endpoint of the third path to be covered is determined as the destination endpoint of the third path to be covered.

[0248] In a possible implementation, the processing module 64 may also be used to:

[0249] Determine whether there is a path to be covered ahead of the current path to be covered in the current scene coverage direction;

[0250] When there is a path to be covered ahead of the current path to be covered in the current scene coverage direction, a third path to be covered is determined from the paths to be covered ahead of the current path to be covered according to the destination endpoint of the current path to be covered.

[0251] In a possible implementation, the processing module 64 may also be used to:

[0252] Determine a target endpoint from endpoints corresponding to the path to be covered ahead of the current path to be covered, the target endpoint being an endpoint of the same type as the destination endpoint of the current path to be covered, and the target endpoint being closest to the destination endpoint of the current path to be covered;

[0253] It is determined that the path to be covered corresponding to the target endpoint is the third path to be covered.

[0254] In a possible implementation, the processing module 64 may also be used to:

[0255] In the case that there is no path to be covered ahead of the current path to be covered in the current scene coverage direction, determining whether there is a path to be covered in the same row as the current path to be covered according to the destination endpoint of the current path to be covered;

[0256] In the case that there is a path to be covered in the same row as the current path to be covered, the path to be covered in the same row as the current path to be covered is determined to be the third path to be covered.

[0257] In a possible implementation, the processing module 64 may also be used to:

[0258] When there is no path to be covered in the same row as the current path to be covered, the current scene coverage direction is changed.

[0259] In a possible implementation, the device may further include:

[0260] The second determination module may be configured to determine whether there is a fourth path to be covered associated with the position of the first obstacle in the path to be covered when no obstacle is detected at the position of the first obstacle;

[0261] The second path planning module may be configured to re-plan the fourth path to be covered according to the position of the first obstacle to obtain a fifth path to be covered when the fourth path to be covered exists;

[0262] The second updating module may be configured to update the set of paths to be covered according to the fifth path to be covered to obtain an updated set of paths to be covered.

[0263] The position of the first obstacle includes the position of the obstacle within the detection range of the electronic device.

[0264] In a possible implementation, the device may further include:

[0265] A third path planning module may be used to perform path planning according to the position of the first obstacle to obtain a sixth path to be covered when the fourth path to be covered does not exist;

[0266] The third updating module may be configured to update the set of paths to be covered according to the sixth path to be covered to obtain an updated set of paths to be covered.

[0267] In a possible implementation, the processing module 64 may also be used to:

[0268] In the case where the third path to be covered does not exist, detecting the area where the obstacle is located;

[0269] In the case that no obstacle is detected in the area where the obstacle is located, a covering process is performed on the area where the obstacle is located.

[0270] In some embodiments, the functions or modules included in the device provided by the embodiments of the present disclosure can be used to execute the method described in the above method embodiments. The specific implementation can refer to the description of the above method embodiments, and for the sake of brevity, it will not be repeated here.

[0271] The embodiment of the present disclosure also provides a computer-readable storage medium, on which computer program instructions are stored, and when the computer program instructions are executed by a processor, the above method is implemented. The computer-readable storage medium may be a non-volatile computer-readable storage medium.

[0272] An embodiment of the present disclosure further proposes an electronic device, comprising: a processor; and a memory for storing instructions executable by the processor; wherein the processor is configured to call the instructions stored in the memory to execute the above method.

[0273] The embodiments of the present disclosure also provide a computer program product, including computer-readable codes. When the computer-readable codes are executed on a device, a processor in the device executes instructions for implementing the path coverage method provided in any of the above embodiments.

[0274] The embodiment of the present disclosure also provides another computer program product for storing computer-readable instructions, which, when executed, enables a computer to perform the operations of the path coverage method provided in any of the above embodiments.

[0275] The electronic device may be provided as a terminal, a server, or a device in other forms.

[0276] Figure 7 A block diagram of an electronic device 800 according to an embodiment of the present disclosure is shown. For example, the electronic device 800 may be a mobile phone, a computer, a digital broadcast terminal, a messaging device, a game console, a tablet device, a medical device, a fitness device, a personal digital assistant, or the like.

[0277] Reference Figure 7 , the electronic device 800 may include one or more of the following components: a processing component 802 , a memory 804 , a power component 806 , a multimedia component 808 , an audio component 810 , an input / output (I / O) interface 812 , a sensor component 814 , and a communication component 816 .

[0278] The processing component 802 generally controls the overall operation of the electronic device 800, such as operations associated with display, phone calls, data communications, camera operations, and recording operations. The processing component 802 may include one or more processors 820 to execute instructions to complete all or part of the steps of the above-mentioned method. In addition, the processing component 802 may include one or more modules to facilitate the interaction between the processing component 802 and other components. For example, the processing component 802 may include a multimedia module to facilitate the interaction between the multimedia component 808 and the processing component 802.

[0279] The memory 804 is configured to store various types of data to support operations on the electronic device 800. Examples of such data include instructions for any application or method operating on the electronic device 800, contact data, phone book data, messages, pictures, videos, etc. The memory 804 can be implemented by any type of volatile or non-volatile storage device or a combination thereof, such as static random access memory (SRAM), electrically erasable programmable read-only memory (EEPROM), erasable programmable read-only memory (EPROM), programmable read-only memory (PROM), read-only memory (ROM), magnetic memory, flash memory, magnetic disk or optical disk.

[0280] The power supply component 806 provides power to the various components of the electronic device 800. The power supply component 806 may include a power management system, one or more power supplies, and other components associated with generating, managing, and distributing power to the electronic device 800.

[0281] The multimedia component 808 includes a screen that provides an output interface between the electronic device 800 and the user. In some embodiments, the screen may include a liquid crystal display (LCD) and a touch panel (TP). If the screen includes a touch panel, the screen may be implemented as a touch screen to receive input signals from the user. The touch panel includes one or more touch sensors to sense touch, slide, and gestures on the touch panel. The touch sensor may not only sense the boundaries of the touch or slide action, but also detect the duration and pressure associated with the touch or slide operation. In some embodiments, the multimedia component 808 includes a front camera and / or a rear camera. When the electronic device 800 is in an operating mode, such as a shooting mode or a video mode, the front camera and / or the rear camera may receive external multimedia data. Each front camera and rear camera may be a fixed optical lens system or have a focal length and optical zoom capability.

[0282] The audio component 810 is configured to output and / or input audio signals. For example, the audio component 810 includes a microphone (MIC), and when the electronic device 800 is in an operating mode, such as a call mode, a recording mode, and a voice recognition mode, the microphone is configured to receive an external audio signal. The received audio signal can be further stored in the memory 804 or sent via the communication component 816. In some embodiments, the audio component 810 also includes a speaker for outputting audio signals.

[0283] I / O interface 812 provides an interface between processing component 802 and peripheral interface modules, such as keyboards, click wheels, buttons, etc. These buttons may include but are not limited to: a home button, a volume button, a start button, and a lock button.

[0284] The sensor assembly 814 includes one or more sensors for providing various aspects of status assessment for the electronic device 800. For example, the sensor assembly 814 can detect the open / closed state of the electronic device 800, the relative positioning of the components, such as the display and keypad of the electronic device 800, and the sensor assembly 814 can also detect the position change of the electronic device 800 or a component of the electronic device 800, the presence or absence of contact between the user and the electronic device 800, the orientation or acceleration / deceleration of the electronic device 800, and the temperature change of the electronic device 800. The sensor assembly 814 may include a proximity sensor configured to detect the presence of a nearby object without any physical contact. The sensor assembly 814 may also include an optical sensor, such as a complementary metal oxide semiconductor (CMOS) or a charge coupled device (CCD) image sensor, for use in imaging applications. In some embodiments, the sensor assembly 814 may also include an acceleration sensor, a gyroscope sensor, a magnetic sensor, a pressure sensor, or a temperature sensor.

[0285] The communication component 816 is configured to facilitate wired or wireless communication between the electronic device 800 and other devices. The electronic device 800 can access a wireless network based on a communication standard, such as a wireless network (WiFi), a second generation mobile communication technology (2G) or a third generation mobile communication technology (3G), or a combination thereof. In an exemplary embodiment, the communication component 816 receives a broadcast signal or broadcast-related information from an external broadcast management system via a broadcast channel. In an exemplary embodiment, the communication component 816 also includes a near field communication (NFC) module to facilitate short-range communication. For example, the NFC module can be implemented based on radio frequency identification (RFID) technology, infrared data association (IrDA) technology, ultra-wideband (UWB) technology, Bluetooth (BT) technology and other technologies.

[0286] In an exemplary embodiment, the electronic device 800 may be implemented by one or more application-specific integrated circuits (ASICs), digital signal processors (DSPs), digital signal processing devices (DSPDs), programmable logic devices (PLDs), field programmable gate arrays (FPGAs), controllers, microcontrollers, microprocessors, or other electronic components to perform the above methods.

[0287] In an exemplary embodiment, a non-volatile computer-readable storage medium is also provided, such as a memory 804 including computer program instructions, which can be executed by a processor 820 of an electronic device 800 to perform the above method.

[0288] Figure 8 1 is a block diagram of an electronic device 1900 according to an embodiment of the present disclosure. For example, the electronic device 1900 may be provided as a server. Figure 8 , the electronic device 1900 includes a processing component 1922, which further includes one or more processors, and a memory resource represented by a memory 1932 for storing instructions executable by the processing component 1922, such as an application. The application stored in the memory 1932 may include one or more modules, each corresponding to a set of instructions. In addition, the processing component 1922 is configured to execute instructions to perform the above method.

[0289] The electronic device 1900 may also include a power supply component 1926 configured to perform power management of the electronic device 1900, a wired or wireless network interface 1950 configured to connect the electronic device 1900 to a network, and an input / output (I / O) interface 1958. The electronic device 1900 may operate based on an operating system stored in the memory 1932, such as a Microsoft Server operating system (Windows Server 2003). TM ), a graphical user interface operating system launched by Apple (Mac OSX TM ), a multi-user, multi-process computer operating system (Unix TM ), a free and open source Unix-like operating system (Linux TM ), an open source Unix-like operating system (FreeBSD TM ) or similar.

[0290] In an exemplary embodiment, a non-volatile computer-readable storage medium is also provided, such as a memory 1932 including computer program instructions, which can be executed by the processing component 1922 of the electronic device 1900 to perform the above method.

[0291] The present disclosure may be a system, a method and / or a computer program product. The computer program product may include a computer-readable storage medium carrying computer-readable program instructions for causing a processor to implement various aspects of the present disclosure.

[0292] Computer readable storage medium can be a tangible device that can hold and store instructions used by an instruction execution device. Computer readable storage medium can be, for example, (but not limited to) an electrical storage device, a magnetic storage device, an optical storage device, an electromagnetic storage device, a semiconductor storage device, or any suitable combination thereof. More specific examples (non-exhaustive list) of computer readable storage medium include: a portable computer disk, a hard disk, a random access memory (RAM), a read-only memory (ROM), an erasable programmable read-only memory (EPROM or flash memory), a static random access memory (SRAM), a portable compact disk read-only memory (CD-ROM), a digital versatile disk (DVD), a memory stick, a floppy disk, a mechanical encoding device, for example, a punch card or a convex structure in a groove on which instructions are stored, and any suitable combination thereof. The computer readable storage medium used here is not interpreted as a transient signal itself, such as a radio wave or other freely propagating electromagnetic wave, an electromagnetic wave propagated by a waveguide or other transmission medium (for example, a light pulse by an optical fiber cable), or an electrical signal transmitted by a wire.

[0293] The computer-readable program instructions described herein can be downloaded from a computer-readable storage medium to each computing / processing device, or downloaded to an external computer or external storage device via a network, such as the Internet, a local area network, a wide area network, and / or a wireless network. The network can include copper transmission cables, optical fiber transmissions, wireless transmissions, routers, firewalls, switches, gateway computers, and / or edge servers. The network adapter card or network interface in each computing / processing device receives the computer-readable program instructions from the network and forwards the computer-readable program instructions for storage in the computer-readable storage medium in each computing / processing device.

[0294] The computer program instructions for performing the operation of the present disclosure may be assembly instructions, instruction set architecture (ISA) instructions, machine instructions, machine-related instructions, microcode, firmware instructions, state setting data, or source code or object code written in any combination of one or more programming languages, including object-oriented programming languages, such as Smalltalk, C++, etc., and conventional procedural programming languages, such as "C" language or similar programming languages. Computer-readable program instructions may be executed completely on a user's computer, partially on a user's computer, as an independent software package, partially on a user's computer, partially on a remote computer, or completely on a remote computer or server. In the case of a remote computer, the remote computer may be connected to the user's computer via any type of network, including a local area network (LAN) or a wide area network (WAN), or may be connected to an external computer (e.g., using an Internet service provider to connect via the Internet). In some embodiments, an electronic circuit, such as a programmable logic circuit, a field programmable gate array (FPGA), or a programmable logic array (PLA), may be customized by utilizing the state information of the computer-readable program instructions, and the electronic circuit may execute the computer-readable program instructions, thereby realizing various aspects of the present disclosure.

[0295] Various aspects of the present disclosure are described herein with reference to the flowcharts and / or block diagrams of the methods, devices (systems) and computer program products according to the embodiments of the present disclosure. It should be understood that each box in the flowchart and / or block diagram and the combination of each box in the flowchart and / or block diagram can be implemented by computer-readable program instructions.

[0296] These computer-readable program instructions can be provided to a processor of a general-purpose computer, a special-purpose computer, or other programmable data processing device, thereby producing a machine, so that when these instructions are executed by the processor of the computer or other programmable data processing device, a device that implements the functions / actions specified in one or more boxes in the flowchart and / or block diagram is generated. These computer-readable program instructions can also be stored in a computer-readable storage medium, and these instructions cause the computer, programmable data processing device, and / or other equipment to work in a specific manner, so that the computer-readable medium storing the instructions includes a manufactured product, which includes instructions for implementing various aspects of the functions / actions specified in one or more boxes in the flowchart and / or block diagram.

[0297] Computer-readable program instructions may also be loaded onto a computer, other programmable data processing apparatus, or other device so that a series of operating steps are performed on the computer, other programmable data processing apparatus, or other device to produce a computer-implemented process, thereby causing the instructions executed on the computer, other programmable data processing apparatus, or other device to implement the functions / actions specified in one or more boxes in the flowchart and / or block diagram.

[0298] The flow chart and block diagram in the accompanying drawings show the possible architecture, function and operation of the system, method and computer program product according to multiple embodiments of the present disclosure. In this regard, each square box in the flow chart or block diagram can represent a part of a module, program segment or instruction, and a part of the module, program segment or instruction includes one or more executable instructions for realizing the specified logical function. In some alternative implementations, the function marked in the square box can also occur in a sequence different from that marked in the accompanying drawings. For example, two continuous square boxes can actually be executed substantially in parallel, and they can sometimes be executed in reverse order, depending on the functions involved. It should also be noted that each square box in the block diagram and / or flow chart, and the combination of the square boxes in the block diagram and / or flow chart can be implemented with a dedicated hardware-based system that performs the specified function or action, or can be implemented with a combination of special hardware and computer instructions.

[0299] The computer program product may be implemented in hardware, software or a combination thereof. In one optional embodiment, the computer program product is embodied as a computer storage medium, and in another optional embodiment, the computer program product is embodied as a software product, such as a software development kit (SDK) and the like.

[0300] The embodiments of the present disclosure have been described above, and the above description is exemplary, not exhaustive, and is not limited to the disclosed embodiments. Many modifications and changes will be apparent to those of ordinary skill in the art without departing from the scope and spirit of the described embodiments. The selection of terms used herein is intended to best explain the principles of the embodiments, practical applications, or improvements to the technology in the market, or to enable other persons of ordinary skill in the art to understand the embodiments disclosed herein.

Claims

1. A path coverage method, characterized in that: Applied to electronic equipment, the method comprises: Determine a set of paths to be covered according to the original scene map, wherein the set of paths to be covered includes multiple paths to be covered; In the process of performing coverage processing according to the set of paths to be covered, when an obstacle is detected on a first path to be covered, re-planning the first path to be covered to obtain at least one second path to be covered, wherein the first path to be covered includes a path to be covered within a detection range of the electronic device; Updating the set of paths to be covered according to the second path to be covered to obtain an updated set of paths to be covered; Performing coverage processing according to the updated set of paths to be covered; Wherein, when an obstacle is detected on the first path to be covered, re-planning the first path to be covered to obtain at least one second path to be covered includes: When the obstacle is located between the first end point and the second end point of the first path to be covered, the first path to be covered is split into a second path to be covered. m and the second path to be covered L s , wherein the second path to be covered L m The first end point of the first path to be covered is taken as the first end point, and the first position between the first end point of the first path to be covered and the obstacle and close to the obstacle is taken as the second end point. s A second position between the second end point of the first path to be covered and the obstacle and close to the obstacle is taken as the first end point, and the second end point of the first path to be covered is taken as the second end point; The covering process is performed according to the updated set of paths to be covered, including: Determine a target endpoint from endpoints corresponding to the path to be covered ahead of the current path to be covered, the target endpoint being an endpoint of the same type as the destination endpoint of the current path to be covered, and the target endpoint being closest to the destination endpoint of the current path to be covered; It is determined that the path to be covered corresponding to the target endpoint is the third path to be covered.

2. The method according to claim 1, characterized in that: The re-planning of the first path to be covered according to the first endpoint and the second endpoint of the first path to be covered and the position of the obstacle to obtain at least one second path to be covered includes: When the position of the obstacle coincides with the first end point of the first path to be covered, determining a third position close to the obstacle and between the obstacle and the second end point of the first path to be covered; A second path L to be covered is obtained according to the third position and the second end point of the first path to be covered z , wherein the second path to be covered L z Taking the third position as the first endpoint and taking the second endpoint of the first path to be covered as the second endpoint; or, In a case where the position of the obstacle coincides with the second end point of the first path to be covered, determining a fourth position close to the obstacle and located between the obstacle and the first end point of the first path to be covered; A second path L to be covered is obtained according to the fourth position and the first end point of the first path to be covered x , wherein the second path to be covered L x The first endpoint of the first path to be covered is used as the first endpoint, and the fourth position is used as the second endpoint.

3. The method according to claim 1 or 2, characterized in that: The moving direction of the electronic device is from the starting endpoint to the destination endpoint, the starting endpoint is the first endpoint or the second endpoint of the path to be covered, and the destination endpoint is another endpoint of the path to be covered except the starting endpoint. The updating of the set of paths to be covered according to the second path to be covered to obtain an updated set of paths to be covered includes: Determine, from the second path to be covered, a target path to be covered that includes a starting endpoint of the first path to be covered; Replacing the first path to be covered in the set of paths to be covered with the target path to be covered; Determine whether there is a newly added path to be covered, wherein the newly added path to be covered is a second path to be covered in the second path to be covered except the target path to be covered; In the case where the newly added path to be covered exists, adding the newly added path to be covered to the set of paths to be covered; Get the updated set of paths to be covered.

4. The method according to claim 3, characterized in that The updating of the set of paths to be covered according to the second path to be covered to obtain an updated set of paths to be covered also includes: When the target path to be covered does not exist, the second path to be covered is used to replace the first path to be covered in the set of paths to be covered.

5. The method according to claim 1 or 2, characterized in that: The performing coverage processing according to the updated set of paths to be covered includes: The electronic device moves from a starting end point of a current path to be covered to a destination end point of the current path to be covered; When the electronic device moves to the destination endpoint of the current path to be covered, the current path to be covered is updated as a covered path in the set of paths to be covered, The starting endpoint of the current path to be covered is the first endpoint or the second endpoint of the current path to be covered, and the destination endpoint of the current path to be covered is another endpoint of the current path to be covered except the starting endpoint.

6. The method according to claim 5, characterized in that: The performing coverage processing according to the updated set of paths to be covered also includes: When the electronic device moves from the starting endpoint of the current path to be covered to the destination endpoint of the current path to be covered, determining a third path to be covered from the updated set of paths to be covered according to the destination endpoint of the current path to be covered; The electronic device moves from the current path to be covered to the third path to be covered; The third path to be covered is used as a new current path to be covered.

7. The method according to claim 6, characterized in that The electronic device moves from the current path to be covered to the third path to be covered, comprising: The electronic device moves from the destination endpoint of the current path to be covered to the starting endpoint of the third path to be covered; Wherein, when the destination endpoint of the current path to be covered is the second endpoint of the current path to be covered, the second endpoint of the third path to be covered is determined as the starting endpoint of the third path to be covered, and the first endpoint of the third path to be covered is determined as the destination endpoint of the third path to be covered; or, When the destination endpoint of the current path to be covered is the first endpoint of the current path to be covered, the first endpoint of the third path to be covered is determined as the starting endpoint of the third path to be covered, and the second endpoint of the third path to be covered is determined as the destination endpoint of the third path to be covered.

8. The method according to claim 6, characterized in that The determining a third path to be covered from the updated path to be covered according to the destination endpoint of the current path to be covered includes: Determine whether there is a path to be covered ahead of the current path to be covered in the current scene coverage direction; In the case that there is a path to be covered ahead of the current path to be covered in the current scene coverage direction, a third path to be covered is determined from the paths to be covered ahead of the current path to be covered according to the destination endpoint of the current path to be covered.

9. The method according to claim 1 or 2, characterized in that: The method further comprises: In the case where no obstacle is detected at the position of the first obstacle, determining whether there is a fourth path to be covered associated with the position of the first obstacle in the path to be covered; In the case where the fourth path to be covered exists, re-planning the fourth path to be covered according to the position of the first obstacle to obtain a fifth path to be covered; The set of paths to be covered is updated according to the fifth path to be covered to obtain an updated set of paths to be covered, The position of the first obstacle includes the position of the obstacle within the detection range of the electronic device.

10. The method according to claim 9, characterized in that The method further comprises: In the case where the fourth path to be covered does not exist, performing path planning according to the position of the first obstacle to obtain a sixth path to be covered; The set of paths to be covered is updated according to the sixth path to be covered to obtain an updated set of paths to be covered.

11. The method according to claim 6, characterized in that The performing coverage processing according to the updated set of paths to be covered also includes: In the case where the third path to be covered does not exist, detecting the area where the obstacle is located; In the case that no obstacle is detected in the area where the obstacle is located, a covering process is performed on the area where the obstacle is located.

12. A path coverage device, characterized in that: Used in electronic equipment, including: A first determination module is used to determine a set of paths to be covered according to an original scene map, wherein the set of paths to be covered includes a plurality of paths to be covered; a first path planning module, configured to, in a process of performing coverage processing according to the set of paths to be covered, re-plan the first path to be covered to obtain at least one second path to be covered when an obstacle is detected on the first path to be covered, wherein the first path to be covered includes a path to be covered within a detection range of the electronic device; A first updating module, configured to update the set of paths to be covered according to the second path to be covered, to obtain an updated set of paths to be covered; A processing module, used for performing coverage processing according to the updated set of paths to be covered; Wherein, the first path planning module is used for: When the obstacle is located between the first end point and the second end point of the first path to be covered, the first path to be covered is split into a second path to be covered. m and the second path to be covered L s , wherein the second path to be covered L m The first end point of the first path to be covered is taken as the first end point, and the first position between the first end point of the first path to be covered and the obstacle and close to the obstacle is taken as the second end point. s A second position between the second end point of the first path to be covered and the obstacle and close to the obstacle is taken as the first end point, and the second end point of the first path to be covered is taken as the second end point; Wherein, the processing module is used for: Determine a target endpoint from endpoints corresponding to the path to be covered ahead of the current path to be covered, the target endpoint being an endpoint of the same type as the destination endpoint of the current path to be covered, and the target endpoint being closest to the destination endpoint of the current path to be covered; It is determined that the path to be covered corresponding to the target endpoint is the third path to be covered.

13. An electronic device, characterized in that: include: processor; a memory for storing processor-executable instructions; The processor is configured to call the instructions stored in the memory to execute the method described in any one of claims 1 to 11.

14. A computer-readable storage medium having computer program instructions stored thereon, characterized in that: When the computer program instructions are executed by a processor, the method according to any one of claims 1 to 11 is implemented.