A robot control method, a robot control device and a robot
By determining and constructing the location path of dynamic objects in the cleaning robot, the problem of path confusing and repetitiveness of cleaning robots during secondary cleaning in the prior art is solved, and the cleaning efficiency and effect are improved.
Patent Information
- Application Number
- CN202210712326.1
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2022-06-22
- Publication Date
- 2024-12-03
- Estimated Expiration
- 2042-06-22
Smart Images

Figure CN115040038B_ABST
Abstract
Description
Technical Field
[0001] The present invention relates to the field of robot technology, and in particular to a robot control method and device and a robot. Background Art
[0002] As the functions of cleaning robots become more and more complete, more and more users choose to use cleaning robots for floor cleaning. For example, in a home, a user uses a cleaning robot to clean the living room floor; in a shopping mall, a user uses a cleaning robot to clean the floors of each floor of the shopping mall, and so on.
[0003] In the related art, a cleaning robot usually cleans a designated area according to the user's instructions. For example, when the user issues an instruction to the cleaning robot to clean the kitchen floor, the cleaning robot cleans the kitchen floor according to the user's instructions; when the user issues an instruction to the cleaning robot to clean the floor of a designated location in a workshop, the cleaning robot cleans the floor of the designated location in the workshop according to the user's instructions, and so on.
[0004] However, when the cleaning robot cleans a designated area, the cleaned area may be contaminated again due to the movement of people, pets, etc., and since dynamic targets such as people and pets have different shapes, the cleaning robots in the prior art cannot effectively distinguish between different dynamic targets. When performing a secondary cleaning of the area, they cannot construct an accurately optimized path, resulting in confusing or repetitive cleaning paths and low cleaning efficiency. Summary of the invention
[0005] The purpose of the embodiments of the present invention is to provide a robot control method, device and a robot to enhance the cleaning effect of the robot. The specific technical solution is as follows:
[0006] In a first aspect, an embodiment of the present invention provides a robot control method, the method comprising:
[0007] When the target robot performs a preset task on a designated area, determining each position point passed by a dynamic object existing in a sub-area that has completed the preset task;
[0008] After the target robot completes the preset task for the designated area, based on the determined positional relationship of all the position points, construct a target path passing through all the position points;
[0009] The target robot is controlled to move along the target path and execute the preset task.
[0010] Optionally, in a specific implementation, the determining each position point passed by the dynamic object existing in the sub-area that has completed the preset task includes:
[0011] The tracking algorithm is used to track the dynamic objects existing in the sub-area that has completed the preset task, and obtain the various position points passed by the dynamic objects.
[0012] Optionally, in a specific implementation, the tracking algorithm is used to track the dynamic objects existing in the sub-area that has completed the preset task to obtain various position points passed by the dynamic objects, including:
[0013] Obtain regional scene information collected at preset time intervals;
[0014] Performing dynamic object detection on each area scene information to obtain a detection result, and when the detection result indicates that a dynamic object exists in the sub-area where the preset task has been completed, determining the position information of the detected dynamic object;
[0015] Based on the determined respective position information, respective position points passed by the dynamic objects existing in the sub-area that has completed the preset task are determined.
[0016] Optionally, in a specific implementation, the method further includes:
[0017] For the first area scene information where the dynamic object is detected, determining feature information of the detected dynamic object, and adding an object identifier to the detected dynamic object;
[0018] For each regional scene information whose acquisition time is after the acquisition time of the first regional scene information, when the obtained detection result indicates that there is a dynamic object in the sub-region, determine the target feature information of the detected dynamic object, and judge whether there is specified feature information matching the displayed target feature information in the feature information of the dynamic object detected for the previous regional scene information;
[0019] If it exists, then a specified object identifier is added to the dynamic object detected for the scene information of the area; wherein the specified object identifier is: the object identifier added to the dynamic object whose characteristic information is the specified characteristic information;
[0020] If not, add a new object identifier for the dynamic object detected for the scene information in the area;
[0021] The determining, based on each determined position information, each position point passed by the dynamic object existing in the sub-area that has completed the preset task includes:
[0022] Based on the object identifications added to all the detected dynamic objects and the determined all the position information, various position points passed by the dynamic objects existing in the sub-area that has completed the preset task are determined.
[0023] Optionally, in a specific implementation, the determining of each position point passed by the dynamic objects existing in the sub-area that has completed the preset task based on the object identifications added to all the detected dynamic objects and the determined all the position information includes:
[0024] Path construction is performed on each position information of the dynamic objects added with the same object identifier to obtain at least one initial path;
[0025] For each initial path, the initial path is discretized according to a preset discrete step length to obtain a plurality of discrete points, and based on the plurality of discrete points, various position points passed by the dynamic objects existing in the sub-area that has completed the preset task are determined.
[0026] Optionally, in a specific implementation, the step of constructing a path for each position information of the dynamic objects with the same object identifier added thereto to obtain at least one initial path includes:
[0027] For each object identification, if the number of position information of dynamic objects added with the object identification is greater than a preset number, a path is constructed for each position information of the dynamic objects added with the object identification to obtain an initial path.
[0028] Optionally, in a specific implementation, for each initial path, the initial path is discretized according to a preset discrete step length to obtain a plurality of discrete points, including:
[0029] For each initial path whose length is greater than a preset length, the initial path is discretized according to a preset discrete step length to obtain a plurality of discrete points.
[0030] Optionally, in a specific implementation, the regional scene information includes: image information and / or laser point cloud.
[0031] Optionally, in a specific implementation, the step of constructing a target path passing through all the position points based on the determined positional relationship of all the position points includes:
[0032] Based on the determined positional relationship of all the position points and the connectivity relationship between every two position points among all the position points, construct a target path starting from the current position of the target robot and passing through all the position points;
[0033] The connectivity relationship is a relationship determined according to the existence of obstacles between every two position points.
[0034] Optionally, in a specific implementation, the target robot is a cleaning robot, and the preset task is a cleaning task.
[0035] In a second aspect, an embodiment of the present invention provides a robot control device, the device comprising:
[0036] A sensor, used to collect movement information of the target robot and spatial information of the environment in which the target robot is located when the target robot performs a preset task in a designated area;
[0037] A processor is used to determine the sub-area that has completed the preset task based on the movement information of the target robot collected by the sensor and the spatial information of the environment in which the target robot is located; when the target robot performs the preset task on the designated area, determine the various position points passed by the dynamic objects existing in the sub-area that has completed the preset task; after the target robot completes the preset task on the designated area, based on the positional relationship of all the determined position points, construct a target path passing through all the position points; control the target robot to move along the target path and perform the preset task.
[0038] Optionally, in a specific implementation,
[0039] The sensor is also used to collect regional scene information of the target robot during its movement;
[0040] The processor is specifically used to obtain regional scene information collected at preset time intervals, perform dynamic object detection on each regional scene information, obtain detection results, and when the detection results indicate that there are dynamic objects in the sub-area that has completed the preset task, determine the position information of the detected dynamic objects; based on the determined respective position information, determine the respective position points passed by the dynamic objects in the sub-area that has completed the preset task.
[0041] Optionally, in a specific implementation, the processor is specifically configured to:
[0042] Path construction is performed on each position information of the dynamic objects added with the same object identifier to obtain at least one initial path;
[0043] For each initial path, the initial path is discretized according to a preset discrete step length to obtain a plurality of discrete points, and based on the plurality of discrete points, various position points passed by the dynamic objects existing in the sub-area that has completed the preset task are determined.
[0044] In a third aspect, an embodiment of the present invention provides a robot, including a processor, a communication interface, a memory and a communication bus, wherein the processor, the communication interface and the memory communicate with each other via the communication bus;
[0045] Memory, used to store computer programs;
[0046] The processor is used to implement the steps of any of the above method embodiments when executing the program stored in the memory.
[0047] In a fourth aspect, an embodiment of the present invention provides a computer-readable storage medium, wherein the computer-readable storage medium stores a computer program, and when the computer program is executed by a processor, the steps of any of the above method embodiments are implemented.
[0048] In a fifth aspect, an embodiment of the present invention further provides a computer program product comprising instructions, which, when executed on a computer, enables the computer to execute the steps of any of the above method embodiments.
[0049] Beneficial effects of the embodiments of the present invention:
[0050] It can be seen from the above that, by applying the solution provided by the embodiment of the present invention, when the target robot performs a preset task on a specified area, the various position points passed by the dynamic objects existing in the sub-area that has completed the preset task can be determined; in this way, after the target robot completes the preset task on the specified area, based on the positional relationship of all the determined position points, a target path passing through all the position points can be constructed; then, the robot is controlled to move along the target path and perform the preset task.
[0051] Based on this, by applying the solution provided by the embodiment of the present invention, after completing the preset task for the designated area, the target robot can re-execute the preset task for the position points passed by each dynamic object in the sub-area that has completed the preset task during the designation process of the above-mentioned preset task, so as to avoid the situation where the execution result of the preset task for the position points passed by the above-mentioned dynamic objects is destroyed due to the movement of the above-mentioned dynamic objects, and the execution effect required by the above-mentioned preset task cannot be achieved. Therefore, the above-mentioned preset task can be executed again for the position points passed by the above-mentioned dynamic objects, so that each position in the above-mentioned designated area can achieve the execution effect required by the above-mentioned preset task.
[0052] Among them, when the cleaning robot performs a cleaning task on a designated area, it can record the various positions that people, pets, etc. pass through in the above sub-area it has cleaned, and after the cleaning robot completes the cleaning task on the designated area, it controls the cleaning robot to move along the target path constructed by all the determined positions, and performs secondary cleaning on each position point that the above recorded people, pets, etc. pass through, so as to remove the secondary pollution caused to the cleaned area by the movement of people, pets, etc., and by constructing a target path that includes all the above positions, the degree of confusion of the cleaning path can be reduced, and the duplication between target paths can be reduced. Therefore, the cleaning effect of the cleaning robot can be enhanced. BRIEF DESCRIPTION OF THE DRAWINGS
[0053] In order to more clearly illustrate the embodiments of the present invention or the technical solutions in the prior art, the drawings required for use in the embodiments or the description of the prior art will be briefly introduced below. Obviously, the drawings in the following description are only some embodiments of the present invention. For ordinary technicians in this field, other embodiments can also be obtained based on these drawings.
[0054] Figure 1 A schematic diagram of a flow chart of a robot control method provided by an embodiment of the present invention;
[0055] Figure 2 A schematic diagram of a specific example of determining position information of a dynamic object provided by an embodiment of the present invention;
[0056] Figure 3 A schematic diagram of another specific example of determining position information of a dynamic object provided by an embodiment of the present invention;
[0057] Figure 4 A schematic diagram of another specific example of determining position information of a dynamic object provided by an embodiment of the present invention;
[0058] Figure 5 A schematic diagram of a specific example of determining discrete points provided by an embodiment of the present invention;
[0059] Figure 6 A schematic diagram of a specific example of constructing a target path provided by an embodiment of the present invention;
[0060] Figure 7 A schematic diagram of the structure of a robot control device provided by an embodiment of the present invention;
[0061] Figure 8 A schematic structural diagram of a robot provided by an embodiment of the present invention. DETAILED DESCRIPTION
[0062] The following will be combined with the drawings in the embodiments of the present invention to clearly and completely describe the technical solutions in the embodiments of the present invention. Obviously, the described embodiments are only part of the embodiments of the present invention, not all of the embodiments. Based on the embodiments in the present invention, all other embodiments obtained by ordinary technicians in this field based on this application belong to the scope of protection of the present invention.
[0063] In the related art, the robot usually cleans the designated area according to the user's instructions. For example, when the user issues an instruction to the robot to clean the kitchen floor, the robot cleans the kitchen floor according to the user's instructions; when the user issues an instruction to the robot to clean the floor of a designated location in a workshop, the robot cleans the floor of the designated location in the workshop according to the user's instructions, and so on.
[0064] However, when the cleaning robot cleans a designated area, the cleaned area may be contaminated again due to the movement of people, pets, etc., and since dynamic targets such as people and pets have different shapes, the cleaning robots in the prior art cannot effectively distinguish between different dynamic targets. When performing a secondary cleaning of the area, they cannot construct an accurately optimized path, resulting in confusing or repetitive cleaning paths and low cleaning efficiency.
[0065] In order to solve the above technical problems, an embodiment of the present invention provides a robot control method.
[0066] Among them, the method can be applied to various application scenarios that require controlling the robot to perform preset tasks, for example, in a home, controlling the robot to clean a designated area; in a factory, controlling the robot to patrol a work area, etc. In addition, the method can be applied to the robot, and can also be applied to other electronic devices that communicate with the robot, such as a management server of the robot. Based on this, the embodiment of the present invention does not specifically limit the application scenario and execution subject of the method.
[0067] A robot control method provided by an embodiment of the present invention may include the following steps:
[0068] When the target robot performs a preset task on a designated area, determining each position point passed by a dynamic object existing in a sub-area that has completed the preset task;
[0069] After the target robot completes the preset task for the designated area, based on the determined positional relationship of all the position points, construct a target path passing through all the position points;
[0070] The robot is controlled to move along the target path and execute the preset task.
[0071] It can be seen from the above that, by applying the solution provided by the embodiment of the present invention, when the target robot performs a preset task on a specified area, the various position points passed by the dynamic objects existing in the sub-area that has completed the preset task can be determined; in this way, after the target robot completes the preset task on the specified area, based on the positional relationship of all the determined position points, a target path passing through all the position points can be constructed; then, the robot is controlled to move along the target path and perform the preset task.
[0072] Based on this, by applying the solution provided by the embodiment of the present invention, after completing the preset task for the designated area, the target robot can re-execute the preset task for the position points passed by each dynamic object in the sub-area that has completed the preset task during the designation process of the above-mentioned preset task, so as to avoid the situation where the execution result of the preset task for the position points passed by the above-mentioned dynamic objects is destroyed due to the movement of the above-mentioned dynamic objects, and the execution effect required by the above-mentioned preset task cannot be achieved. Therefore, the above-mentioned preset task can be executed again for the position points passed by the above-mentioned dynamic objects, so that each position in the above-mentioned designated area can achieve the execution effect required by the above-mentioned preset task.
[0073] Among them, when the cleaning robot performs a cleaning task on a designated area, it can record the various positions that people, pets, etc. pass through in the above-mentioned sub-area that it has cleaned, and after the cleaning robot completes the cleaning task on the designated area, it controls the cleaning robot to move along the target path constructed by all the determined positions, and performs secondary cleaning on each position point that the above-mentioned recorded people, pets, etc. pass through, so as to remove the secondary pollution caused to the cleaned area by the movement of people, pets, etc., and by constructing a target path that includes all the above-mentioned positions, the degree of confusion of the cleaning path can be reduced, and the duplication between the target paths can be reduced. Therefore, the cleaning efficiency of the cleaning robot can be improved, and the cleaning effect of the cleaning robot on the designated area can be enhanced.
[0074] A robot control method provided by an embodiment of the present invention is described in detail below with reference to the accompanying drawings.
[0075] Figure 1 A schematic diagram of a flow chart of a robot control method provided by an embodiment of the present invention, such as Figure 1 As shown, the method may include the following steps S101-S103.
[0076] S101: When the target robot performs a preset task in a designated area, determine each position point passed by a dynamic object existing in a sub-area that has completed the preset task;
[0077] When controlling the target robot to perform a preset task in a designated area, the target robot can detect in real time whether there are dynamic objects in the sub-area that has completed the preset task. Thus, when detecting that there is at least one dynamic object in the sub-area, the various position points passed by each dynamic object in the sub-area can be determined.
[0078] The above-mentioned designated area may be one area or multiple areas; it may be an area of any shape in the same plane or multiple areas in different planes, which is reasonable and is not specifically limited in the embodiments of the present invention.
[0079] Exemplarily, the above-mentioned designated area may be three different floors in the same building; it may also be any room in the building; it may also be a square area in any room, etc.
[0080] The above-mentioned preset tasks can be cleaning tasks or patrol tasks, which are all reasonable; corresponding to the above-mentioned preset tasks, the above-mentioned target robot can be a cleaning robot or a patrol robot, which are all reasonable. In the embodiments of the present invention, the types of the above-mentioned target robots and the types of preset tasks are not specifically limited.
[0081] Optionally, in a specific implementation, the target robot is a cleaning robot, and the preset task is a cleaning task.
[0082] In this specific implementation, the target robot may be a cleaning robot, and the preset task may be a cleaning task.
[0083] That is to say, when the cleaning robot performs a cleaning task in a designated area, it can detect in real time whether there are dynamic objects in the sub-area that has been cleaned. When there is at least one dynamic object in the above sub-area, the various position points passed by each dynamic object in the above sub-area can be determined.
[0084] When determining the various position points passed by the dynamic objects existing in the above-mentioned sub-area, each dynamic object detected in the above-mentioned sub-area can be tracked based on the tracking algorithm to obtain the various position points passed by each dynamic object in the above-mentioned sub-area; or the area information in the above-mentioned sub-area can be collected according to a preset specified collection time interval, and the position point of each dynamic object is determined based on the collected area information to obtain the various position points passed by each dynamic object. This is all reasonable and is not specifically limited in the embodiments of the present invention.
[0085] For the sake of clarity, the execution method of the above step S101 will be described with examples in the following.
[0086] S102: after the target robot completes the preset task in the designated area, based on the positional relationship of all the determined position points, construct a target path passing through all the position points;
[0087] When the target robot performs the preset task on the designated area, the sub-area that has completed the preset task increases as the target robot performs the preset task for an increasing period of time, so that the number of position points that each dynamic object passing through in the sub-area can also increase accordingly, so that when the target robot completes the preset task on the designated area, all the determined position points can be obtained. Furthermore, after the target robot completes the preset task on the designated area, a target path passing through all the position points can be constructed based on the positional relationship of all the position points.
[0088] Among them, the above-mentioned position relationship may include the orientation relationship and distance relationship between any two of the above-mentioned position points, and may also include the orientation relationship and distance relationship between any position point of all the above-mentioned position points and the above-mentioned target robot. This is reasonable and is not specifically limited in the embodiments of the present invention.
[0089] Optionally, after all the above position points are obtained, a target path passing through all the above position points can be determined based on the positional relationship among all the above position points and taking the current position of the target robot as a starting point.
[0090] In some cases, there may be obstacles between two location points. Therefore, when constructing a target path passing through all the above location points, it is necessary to consider the connectivity between every two location points among all the location points.
[0091] Based on this, optionally, based on the positional relationship of all the above position points and the connectivity relationship between every two of all the position points, the target path passing through all the above position points can be determined with the current position of the target robot as the starting point.
[0092] The so-called connectivity relationship between each two position points is a relationship determined according to the existence of obstacles between each two position points. When there is an obstacle between the above two position points, the connectivity relationship between the above two position points is non-connected; when there is no obstacle between the above two position points, the connectivity relationship between the above two position points is mutually connected. Figure 6 As shown, there is an obstacle between point 14 and point 15, so it can be determined that the connectivity relationship between point 14 and point 15 is non-connected; there is no obstacle between point 14 and point 1, so it can be determined that the connectivity relationship between point 14 and point 1 is mutually connected.
[0093] Optionally, the current position of the target robot can be taken as the starting point, and the position point that has the smallest distance from the current position of the target robot among the position points that have not been determined as path points of the target path can be determined as the second path point of the target path; then, the position point that has the smallest distance from the second path point among the position points that have not been determined as path points of the target path can be determined as the third path point of the target path; according to the above method, all the above position points are traversed to determine the path points of the target path, and the path points are connected in sequence from the earliest to the last according to the order of each determined path point to obtain the target path passing through all the position points.
[0094] Optionally, based on the positional relationship of all the position points and the connectivity relationship between every two position points in all the position points, each position point in all the path points can be used as a starting point, and the path point of the target path can be determined among the position points that are connected to the position point and have not been determined as the path point of the target path; then, the next path point of the target path can be determined among the position points that are connected to the path point and have not been determined as the path point of the target path; all the above position points are determined as the path points of the target path in sequence, and each path point is connected in sequence according to the order in which each path point is determined, so as to construct multiple candidate paths passing through all the position points. Then, the path length of each candidate path can be determined, and the candidate path with the shortest path length passed by the target robot in the process of moving from the current position of the target robot to the starting point of each candidate path and then passing through all the position points along the above candidate path can be used as the target path.
[0095] Of course, the methods for constructing the target path listed above are only examples and not limitations. When determining a target path by determining multiple position points, the method provided by the embodiment of the present invention can be applied.
[0096] S103: Control the target robot to move along the target path and perform a preset task.
[0097] After obtaining the target path, the target robot can be controlled to move along the target path and perform the preset task.
[0098] In this way, after obtaining the above-mentioned target path, the target robot can be controlled to move from the current position of the target robot to each path point of the above-mentioned target path in sequence, and execute the above-mentioned preset tasks during the movement. Thus, when moving to the end point of the above-mentioned target path, it can pass through all the above-mentioned position points and execute the above-mentioned preset tasks again for each position point.
[0099] Exemplarily, when the target robot is a cleaning robot and the preset task is a cleaning task, after the cleaning robot completes the preset task for the designated area, the cleaning robot can be controlled to move from the current position of the cleaning robot to the starting point of the target path, and then the cleaning robot can be controlled to move along the target path and perform the cleaning task again. Thus, when the cleaning robot moves to the end point of the target path, the cleaning robot has passed through all the above positions and performed the cleaning task for all the above positions again.
[0100] It can be seen from the above that, by applying the solution provided by the embodiment of the present invention, the target robot can, after completing the preset task for the designated area, perform the preset task again for the position points passed by each dynamic object in the sub-area where the preset task has been completed during the designation process of the preset task, so as to avoid the situation where the execution result of the preset task for the position points passed by the dynamic object is destroyed due to the movement of the dynamic object, and the execution effect required by the preset task cannot be achieved. Therefore, the preset task can be performed again for the position points passed by the dynamic object, so that each position in the designated area can achieve the execution effect required by the preset task.
[0101] Among them, when the cleaning robot performs a cleaning task on a designated area, it can record the various positions that people, pets, etc. pass through in the above sub-area it has cleaned, and after the cleaning robot completes the cleaning task on the designated area, it controls the cleaning robot to move along the target path constructed by all the determined positions, and performs secondary cleaning on each position point that the above recorded people, pets, etc. pass through, so as to remove the secondary pollution caused to the cleaned area by the movement of people, pets, etc., and by constructing a target path that includes all the above positions, the degree of confusion of the cleaning path can be reduced, and the duplication between target paths can be reduced. Therefore, the cleaning effect of the cleaning robot can be enhanced.
[0102] Next, the specific implementation method of the above step S101 of determining each position point passed by the dynamic object existing in the sub-region that has completed the preset task is described by example.
[0103] Optionally, in a specific implementation, the above step S101 may include the following step 11:
[0104] Step 11: Using a tracking algorithm, the dynamic objects existing in the sub-area that has completed the preset task are tracked to obtain various position points that the dynamic objects have passed through.
[0105] In this specific implementation, a tracking algorithm may be used to track each dynamic object that appears in the sub-region that has completed the preset task, and determine each position point that each dynamic object passes through.
[0106] The tracking algorithm may be a frame difference method, an optical flow method, or a similarity measurement algorithm, which are all reasonable. The tracking algorithm is not specifically limited in the embodiments of the present invention.
[0107] Optionally, in a specific implementation, the above step 11 may include the following steps 111-113:
[0108] Step 111: Acquire regional scene information collected at preset time intervals;
[0109] Step 112: Perform dynamic object detection on each area scene information to obtain a detection result, and when the detection result indicates that a dynamic object exists in the sub-area that has completed the preset task, determine the position information of the detected dynamic object;
[0110] Step 113: Based on the determined position information, determine the position points passed by the dynamic objects existing in the sub-area that has completed the preset task.
[0111] In this specific implementation, when the target robot performs a preset task on a designated area, the acquisition device carried by the target robot can collect the regional scene information of the sub-area that has completed the preset task in its own acquisition area in real time according to its own acquisition frequency. In this way, when determining whether there is a dynamic object in the sub-area that has completed the preset task, a preset time interval can be set, and the regional scene information collected according to the preset time interval can be obtained.
[0112] Among them, the above-mentioned preset time interval can be the same as the collection time period corresponding to the collection frequency of the above-mentioned collection device; it can also be different from the collection time period corresponding to the collection frequency of the above-mentioned collection device. For example, when the collection time period corresponding to the collection frequency of the above-mentioned collection device is 3 seconds, the above-mentioned preset time interval can be 3 seconds, 6 seconds, or 12 seconds, which are all reasonable and are not specifically limited in the embodiments of the present invention.
[0113] Optionally, when the preset time interval is the same as the collection time period corresponding to the collection frequency of the collection device, the regional scene information is obtained according to the preset time interval, and the obtained regional scene information is all regional scene information collected by the collection device carried by the target robot;
[0114] Optionally, when the preset time interval is different from the collection time period corresponding to the collection frequency of the collection device, the regional scene information is acquired according to the preset time interval, and the acquired regional scene information is part of the regional scene information acquired by the collection device carried by the target robot. Exemplarily, when the collection time period corresponding to the collection frequency of the collection device is 4 seconds, the preset time interval may be 8 seconds. After acquiring one regional scene information, the next regional scene information is acquired after one collection frequency of the collection device is set.
[0115] After obtaining multiple regional scene information of the sub-region that has completed the preset task at the preset time interval, dynamic object detection can be performed on each of the obtained regional scene information to determine whether there is a dynamic object in the regional scene information and obtain a detection result. Thus, when the detection result indicates that there is a dynamic object in the sub-region that has completed the preset task, the position information of the detected dynamic object can be determined, and then, based on the determined position information, each position point passed by each dynamic object in the sub-region that has completed the preset task can be determined.
[0116] When acquiring the regional scene information of the sub-area that has completed the preset task, the acquisition device carried by the target robot is different, and the acquired regional scene information may be different. For example, the acquisition device carried by the target robot may be an image sensor, or a laser radar, or an image sensor and a laser radar, and further, the acquired regional scene information may be image information, or a laser point cloud, or image information and a laser point cloud, which are all reasonable and are not specifically limited in the embodiments of the present invention.
[0117] Optionally, in a specific implementation, the regional scene information includes: image information and / or laser point cloud.
[0118] In this specific implementation, when the acquisition device carried by the above-mentioned target robot includes an image sensor and / or a laser radar, the acquired regional scene information includes image information and / or a laser point cloud.
[0119] That is to say, when the acquisition device carried by the above-mentioned target robot is an image sensor, the acquired regional scene information may be image information; when the acquisition device carried by the above-mentioned target robot is a lidar, the acquired regional scene information may be a laser point cloud; when the acquisition device carried by the above-mentioned target robot is an image sensor and a lidar, the acquired regional scene information may be image information and a laser point cloud.
[0120] After acquiring the above regional scene information, dynamic object detection may be performed on each regional scene information, and when a dynamic object exists in the above sub-region that has completed the preset task, the position information of the detected dynamic object is determined.
[0121] For each area scene information, the number of detected dynamic objects may be one or more.
[0122] Optional, such as Figure 2 As shown, when the acquisition device carried by the target robot is an image sensor, the acquired regional scene information may include the image information of the sub-area that has completed the preset task. After acquiring the above image information, it can be determined whether there is a dynamic object in the above sub-area based on the target recognition algorithm, for example, whether there is a person or a pet in the above image information. Furthermore, when it is determined that there is a dynamic object in the above sub-area, the position of the dynamic object and the distance from the target robot can be identified based on the visual algorithm, thereby obtaining the position information of the dynamic object. Among them, the above visual algorithm can be a self-supervised algorithm, or it can be a gradient descent method and Newton's method, which are all reasonable, and the above visual algorithm is not specifically limited in the embodiments of the present invention.
[0123] Optionally, when the target robot is equipped with multiple image sensors, the acquired regional scene information may include multiple image information of the sub-area that has completed the preset task. Furthermore, it can be determined whether there is a dynamic object in the sub-area based on the target recognition algorithm. When it is determined that there is a dynamic object in the sub-area, the position of the dynamic object and the distance from the target robot can be predicted based on the parallax between the multiple image information, thereby obtaining the position information of the dynamic object.
[0124] Optional, such as Figure 3 As shown, when the acquisition device carried by the target robot is a laser radar, the acquired regional scene information may include the laser point cloud of the sub-area that has completed the preset task. After acquiring the laser point cloud, it is possible to determine whether there is a dynamic object in the sub-area based on the point cloud algorithm. Then, when it is determined that there is a dynamic object in the sub-area, the position of the dynamic object and the distance from the target robot can be identified based on the point cloud algorithm. For example, when a person moves in the sub-area, the position of the legs of the person can be identified based on the point cloud algorithm, thereby obtaining the position information of the person. Among them, the point cloud algorithm can be a 3D point cloud algorithm or other algorithms, which are all reasonable. In the embodiments of the present invention, the point cloud algorithm is not specifically limited.
[0125] Optional, such as Figure 4As shown, when the acquisition devices carried by the target robot are image sensors and laser radars, the acquired regional scene information may include the image information and laser point cloud of the sub-region that has completed the preset task. After acquiring the image information and laser point cloud, it is possible to determine whether there is a dynamic object in the sub-region based on the projection of the laser point cloud on the image. Further, when it is determined that there is a dynamic object in the sub-region, the position of the dynamic object can be identified based on a visual algorithm, and the target distance between the dynamic object and the target robot can be estimated based on the point cloud corresponding to the dynamic object, thereby obtaining the position information of the dynamic object.
[0126] After determining that there is a dynamic object in the sub-area that completes the preset task, the position information of the dynamic object can be obtained based on the above-mentioned regional scene information, and then, based on the determined various position information, the various position points passed by the dynamic object in the above-mentioned sub-area can be determined.
[0127] Among them, the points corresponding to all the determined position information in the specified area can be determined as the various position points that the above-mentioned dynamic object passes through in the above-mentioned sub-area; or, according to a preset selection rule, some points corresponding to all the determined position information in the specified area can be selected as the various position points that the above-mentioned dynamic object passes through in the above-mentioned sub-area. For example, among the points corresponding to all the determined position information in the specified area, points whose distance to obstacles is greater than a specified distance can be selected as the various position points that the above-mentioned dynamic object passes through in the above-mentioned sub-area.
[0128] Optionally, in a specific implementation, the above step 11 further includes the following steps 11A-11D:
[0129] Step 11A: for the first regional scene information where the dynamic object is detected, determining feature information of the detected dynamic object, and adding an object identifier to the detected dynamic object;
[0130] Step 11B: For each regional scene information whose acquisition time is after the acquisition time of the first regional scene information, when the obtained detection result indicates that there is a dynamic object in the sub-region, determine the target feature information of the detected dynamic object, and judge whether there is specified feature information matching the target feature information in the feature information of the dynamic object detected for the previous regional scene information; if it matches, execute step 11C; otherwise, execute step 11D:
[0131] Step 11C: adding a designated object identifier to the dynamic object detected for the scene information of the area; wherein the designated object identifier is: an object identifier added to the dynamic object whose characteristic information is designated characteristic information;
[0132] Step 11D: adding a new object identifier for the dynamic object detected for the scene information of the area;
[0133] Accordingly, in this specific implementation, the above step 113, based on the determined position information, determines the position points passed by the dynamic objects existing in the sub-area that has completed the preset task, and may include the following step 1131:
[0134] Step 1131: Based on the object identifications added to all the detected dynamic objects and the determined all the position information, determine the various position points passed by the dynamic objects existing in the sub-area that has completed the preset task.
[0135] In this specific implementation, after obtaining multiple regional scene information of sub-regions that have completed the preset task, each of the obtained regional scene information can be analyzed to determine whether there is a dynamic object in the regional scene information. Furthermore, for the first regional scene information where a dynamic object is detected, feature information of the detected dynamic object can be determined, and an object identifier can be added to the detected dynamic object.
[0136] Then, according to the order of collecting each regional scene information, for each regional scene information collected after the collection time of the first regional scene information, dynamic object detection is performed on the regional scene information to obtain a detection result. Thus, when the obtained detection result indicates that there is a dynamic object in the sub-region, the target feature information of the detected dynamic object is determined, and it is determined whether there is specified feature information matching the target feature information in the feature information of the dynamic object detected for the previous regional scene information.
[0137] In the presence of designated feature information that matches the target feature information, it can be indicated that the dynamic objects detected for the previous area scene information include the dynamic objects detected for the area scene information. Thus, the same object identifier can be added to the dynamic objects having the above target feature information and the dynamic objects having the above designated feature information. Therefore, the designated object identifier added to the dynamic objects having the above designated feature information can be determined, and the designated object identifier can be added to the dynamic objects having the above target feature information.
[0138] That is to say, in the presence of designated characteristic information that matches the target characteristic information, for the dynamic object whose characteristic information detected for the regional scene information is the target characteristic information, the designated object identifier added to the dynamic object whose characteristic information is the designated characteristic information is added; in this way, the tracking of the same dynamic object can be achieved by judging whether the characteristic information of the dynamic object detected for multiple consecutive regional scene information is the same.
[0139] Correspondingly, in the absence of specified feature information matching the target feature information, it can be indicated that the dynamic objects detected for the previous area scene information do not include the dynamic objects detected for the area scene information. Therefore, the dynamic objects with target feature information detected for the area scene information can be identified as newly appeared dynamic objects, and thus, a new object identifier can be added for the dynamic objects with target feature information.
[0140] The so-called new object identification is an object identification that is different from the object identification added to all dynamic objects detected before the scene information in the area.
[0141] Exemplarily, for the first regional scene information in which dynamic objects are detected, dynamic objects A, B, and C are detected, and the target feature information of the three dynamic objects is determined to be a, b, and c, respectively, and object tags are added to the three dynamic objects, wherein object tag A1 is added to dynamic object A, object tag B1 is added to dynamic object B, and object tag C1 is added to dynamic object C; the next regional scene information of the first regional scene information is detected, and dynamic objects D, E, and F are detected. It can be determined that the target feature information of the three dynamic objects is a, b, and f, respectively, and the three target feature information a, b, and f are respectively compared with the target feature information determined for the first regional scene information. Match a, b and c, and then, the target feature information of the dynamic object D matches the target feature information of the dynamic object A, and the target feature information of the dynamic object E matches the specified feature information of the dynamic object B; at this time, it can be determined that the above-mentioned dynamic object D and the dynamic object A are the same dynamic object, and then, the object identification A1 can be added to the dynamic object D, and the above-mentioned dynamic object E and the dynamic object B are the same dynamic object, and then, the object identification B1 can be added to the dynamic object E; in addition, since the target feature information of the dynamic object F does not match the target feature information a, b and c determined for the above-mentioned first area scene information, a new object identification F1 can be added to the dynamic object F.
[0142] In this way, by adding the same object identifier to the same dynamic object detected for different regional scene information, and adding different object identifiers to different dynamic objects detected for different regional scene information, after detecting all the acquired regional scene information, the corresponding relationship between the dynamic object, the object identifier and the position information can be established, so that for the dynamic object with the same object identifier, the various position information of the dynamic object can be obtained. Therefore, for each detected dynamic object, the various position information of the dynamic object can be determined, and then the various position points passed by the dynamic object can be determined.
[0143] Optionally, in a specific implementation, the above step 1131, based on the object identifications added to all the detected dynamic objects and the determined all the position information, determines the various position points passed by the dynamic objects existing in the sub-area that has completed the preset task, and may include the following steps 21-22:
[0144] Step 21: constructing paths for each position information of dynamic objects with the same object identifier added thereto, and obtaining at least one initial path;
[0145] Step 22: For each initial path, the initial path is discretized according to a preset discrete step length to obtain a plurality of discrete points, and based on the plurality of discrete points, each position point passed by the dynamic object existing in the sub-area that has completed the preset task is determined.
[0146] In this specific implementation, after adding object identifiers to the dynamic objects in each area scene information, based on the added object identifiers, path construction can be performed on each position information of the dynamic objects with the same object identifier added to obtain the initial path of each dynamic object.
[0147] Since the time and path of each dynamic object appearing in the sub-area that has completed the preset task can be different, the frequency of appearance of each dynamic object in the collected regional scene information is also different, and the amount of position information of the collected dynamic objects is also different. Based on this, for a dynamic object with too little position information, it may be impossible to construct the initial path of the dynamic object.
[0148] Optionally, the above step 21 may include the following step 211:
[0149] Step 211: for each object identifier, if the number of position information of dynamic objects added with the object identifier is greater than a preset number, a path is constructed for each position information of the dynamic objects added with the object identifier to obtain an initial path.
[0150] In this specific implementation, for each object identifier, the number of position information of dynamic objects added with the object identifier can be determined. When the number of object identifiers added is greater than a preset number, a path can be constructed for each position information of the dynamic objects added with the object identifier to obtain an initial path.
[0151] Furthermore, for dynamic objects whose position information is not greater than the preset number, each position information of the dynamic object can be ignored in the process of constructing the target path.
[0152] The above-mentioned preset number can be 5 or 10, which is reasonable and is not specifically limited in the embodiment of the present invention.
[0153] That is, for each object identifier, when the position information of the dynamic object with the object identifier is greater than the preset number, it can be considered that the dynamic object exists in the sub-area that has completed the preset task for a long time, and then a moving path can be constructed for the dynamic object with the object identifier to obtain the initial path of the dynamic object. After that, the initial path can be discretized according to the preset discrete step length to obtain multiple discrete points.
[0154] In addition, since the speed, step frequency, step length, etc. of different dynamic objects may be different during the movement process, the length of the movement trajectory of each dynamic object in the above-mentioned sub-area that has completed the preset task may be different. For a dynamic object with a shorter initial path constructed, it may not be possible to discretize the initial path of the dynamic object.
[0155] Afterwards, for each initial path, the initial path can be discretized according to a preset discrete step length, and then a plurality of discrete points can be obtained. In this way, the various position points passed by the dynamic object in the above sub-area that has completed the preset task can be determined based on the obtained plurality of discrete points.
[0156] The preset discrete step lengths may be set according to actual needs, such as 3 meters or 5 meters, which are all reasonable and are not specifically limited in the embodiments of the present invention.
[0157] Among them, after obtaining the above-mentioned multiple discrete points, all the discrete points can be determined as the various position points passed by the dynamic objects in the sub-area that has completed the preset task; or some discrete points can be selected from all the discrete points as the various position points passed by the dynamic objects in the sub-area that has completed the preset task.
[0158] Optionally, the above step 22 may include the following step 221:
[0159] Step 221: for each initial path whose length is greater than a preset length, the initial path is discretized according to a preset discrete step length to obtain a plurality of discrete points.
[0160] In this specific implementation, after obtaining multiple initial paths, the length of each initial path can be determined, and the initial paths with a length greater than a preset length can be discretized according to preset discrete steps to obtain multiple discrete points.
[0161] The preset length may be 8 meters or 20 meters, which is reasonable and is not specifically limited in the embodiments of the present invention.
[0162] That is to say, for each dynamic object, when the length of the initial path of the dynamic object is not greater than the preset length, the initial path of the dynamic object can be ignored in the process of constructing the target path.
[0163] When determining the various position points passed by each dynamic object within the above-mentioned completed preset task based on the multiple discrete points obtained above, the above-mentioned multiple discrete points can be used as the various position points passed by the above-mentioned dynamic object in the sub-area that has completed the preset task, or a part of the discrete points can be selected from the above-mentioned multiple discrete points according to preset conditions as the various position points passed by the above-mentioned dynamic object in the sub-area that has completed the preset task.
[0164] Compared with directly moving along the initial path of each determined dynamic object, the above initial path is discretized, and the obtained multiple discrete points are used as multiple path points for constructing the target path, so as to obtain the target path passing through all the position points. The moving path of the target robot in the process of performing the above preset task again can be better planned, thereby shortening the length of the path passing through all the above position points. Furthermore, when controlling the target robot to move along the above target path and perform the above preset task again, the task execution efficiency of the target robot can be improved and the energy consumption of the target robot can be reduced.
[0165] In order to facilitate understanding of this specific implementation, Figure 5 , give an example.
[0166] like Figure 5 As shown, initial path 1, initial path 2 and initial path 3 are initial paths of the three objects respectively constructed based on the position information of the three detected dynamic objects.
[0167] Afterwards, for each initial path, the initial path is discretized according to the preset discrete step length to obtain multiple discrete points. Among them, the initial path 1 is discretized to obtain discrete points a, discrete points b, discrete points c, discrete points d and discrete points e; the initial path 2 is discretized to obtain discrete points f, discrete points g, discrete points h, discrete points i, discrete points j and discrete points k; the initial path 3 is discretized to obtain discrete points l, discrete points m, discrete points n and discrete points o. Then, the above-obtained discrete points ao can be used as the various position points passed by the above-mentioned dynamic object in the sub-area that has completed the preset task.
[0168] Taking into account that there may be obstacles in the specified area and the above-mentioned location points may be distributed near the above-mentioned obstacles, therefore, when constructing the target path passing through all the path points, it is possible to consider whether there are obstacles between every two of the above-mentioned location points. Furthermore, if there are obstacles between every two of the above-mentioned location points, it is necessary to bypass the above-mentioned obstacles and plan the path between the above-mentioned two location points.
[0169] Based on the above specific implementations, optionally, in a specific implementation, the above step S102, based on the determined positional relationship of all the position points, constructing a target path passing through all the position points, may include the following step 31:
[0170] Step 31: Based on the determined positional relationship of all the position points and the connectivity relationship between every two position points among all the position points, a target path starting from the current position of the target robot and passing through all the position points is constructed;
[0171] The connectivity relationship is a relationship determined according to the existence of obstacles between every two position points.
[0172] In this specific implementation, after obtaining all the position points that the dynamic object passes through, it is possible to determine whether there are obstacles between every two of the above-mentioned position points, and then determine the connectivity relationship between every two of the above-mentioned position points.
[0173] Optionally, if there is an obstacle between any two position points, the connectivity relationship between the two position points is disconnected; conversely, if there is no obstacle between any two position points, the connectivity relationship between the two position points is connected.
[0174] In this way, after determining the connectivity relationship between every two of all the above-mentioned position points, a target path with the robot's current position as the starting point and passing through all the position points can be constructed based on the position relationship of all the above-mentioned position points and the connectivity relationship between every two of all the position points.
[0175] For example, the target path is constructed by using a path planning algorithm, a genetic algorithm, etc. Exemplarily, the path planning algorithm used may be a Dijkstra algorithm, etc., which is not specifically limited in the embodiment of the present invention.
[0176] Optionally, taking the current position of the target robot as the starting point, among the position points connected to the current position of the robot, the position point with the shortest distance to the current position of the target robot is determined as the second path point of the target path, and the starting point and the second path point are connected; thereafter, among the position points connected to the second path point, among the position points that have not been determined as path points, the position point with the shortest distance to the second path point is determined as the third path point of the target path, and the second path point and the third path point are connected; and so on, all path points are traversed, each path point of the target path is determined in turn, and each path point is connected in order from the first to the last in the order in which each path point is determined, to obtain the target path passing through all the position points.
[0177] For example, Figure 6 As shown in FIG. 1 , points 1-15 are all discrete points obtained by discretizing the three initial paths on the basis of constructing the three initial paths, and all points 1-15 are determined as all the position points that the dynamic object passes through in the sub-area that has completed the preset task. The circle is the target robot and the rectangle is the obstacle. Therefore, based on the position relationship and connectivity relationship between points 1-15, the following can be constructed: Figure 6 The target path shown in the figure, in which the target robot passes through all the position points in the following order: point 1-point 2-point 3-point 4-point 5-point 6-point 7-point 8-point 9-point 10-point 11-point 12-point 13-point 14-point 1-point 15.
[0178] By adopting the method embodiment of the present invention, different dynamic objects in a specified area can be distinguished, and accurate paths can be constructed for the respective trajectories of the different dynamic objects that have been distinguished, so that the cleaning robot can clean according to the accurately constructed optimized path, reducing the degree of confusion or repetitiveness in path planning errors caused by the inability to distinguish targets, thereby improving the cleaning efficiency of the cleaning robot.
[0179] Based on the same inventive concept, corresponding to the above-mentioned embodiment of the present invention, Figure 1 A robot control method is shown, and an embodiment of the present invention also provides a robot control device.
[0180] Figure 7 A schematic diagram of the structure of a robot control device provided by an embodiment of the present invention is shown in FIG. Figure 7 As shown, the device may include:
[0181] Sensor 710, used to collect movement information of the target robot and spatial information of the environment in which the target robot is located when the target robot performs a preset task in a designated area;
[0182] Processor 720 is used to determine the sub-area that has completed the preset task based on the movement information of the target robot collected by the sensor and the spatial information of the environment in which the target robot is located; when the target robot performs the preset task on the designated area, determine the various position points passed by the dynamic objects existing in the sub-area that has completed the preset task; after the target robot completes the preset task on the designated area, based on the positional relationship of all the determined position points, construct a target path passing through all the position points; control the target robot to move along the target path and perform the preset task.
[0183] It can be seen from the above that, by applying the solution provided by the embodiment of the present invention, the target robot can, after completing the preset task for the designated area, perform the preset task again for the position points passed by each dynamic object in the sub-area where the preset task has been completed during the designation process of the preset task, so as to avoid the situation where the execution result of the preset task for the position points passed by the dynamic object is destroyed due to the movement of the dynamic object, and the execution effect required by the preset task cannot be achieved. Therefore, the preset task can be performed again for the position points passed by the dynamic object, so that each position in the designated area can achieve the execution effect required by the preset task.
[0184] Among them, when the cleaning robot performs a cleaning task on a designated area, it can record the various positions that people, pets, etc. pass through in the above sub-area it has cleaned, and after the cleaning robot completes the cleaning task on the designated area, it controls the cleaning robot to move along the target path constructed by all the determined positions, and performs secondary cleaning on each position point that the above recorded people, pets, etc. pass through, so as to remove the secondary pollution caused to the cleaned area by the movement of people, pets, etc., and by constructing a target path that includes all the above positions, the degree of confusion of the cleaning path can be reduced, and the duplication between target paths can be reduced. Therefore, the cleaning effect of the cleaning robot can be enhanced.
[0185] Optionally, in a specific implementation, the processor 720 is specifically configured to:
[0186] The tracking algorithm is used to track the dynamic objects existing in the sub-area that has completed the preset task, and obtain the various position points passed by the dynamic objects.
[0187] Optionally, in a specific implementation,
[0188] The sensor 710 is also used to collect regional scene information of the target robot during its movement;
[0189] The processor 720 is specifically used to obtain regional scene information collected at preset time intervals, perform dynamic object detection on each regional scene information, obtain a detection result, and when the detection result indicates that there is a dynamic object in the sub-region that has completed the preset task, determine the position information of the detected dynamic object; based on the determined respective position information, determine the respective position points passed by the dynamic object in the sub-region that has completed the preset task.
[0190] Optionally, in a specific implementation, the processor 720 is specifically configured to:
[0191] For the first area scene information where the dynamic object is detected, determining feature information of the detected dynamic object, and adding an object identifier to the detected dynamic object;
[0192] For each regional scene information whose acquisition time is after the acquisition time of the first regional scene information, when the obtained detection result indicates that there is a dynamic object in the sub-region, determine the target feature information of the detected dynamic object, and judge whether there is specified feature information matching the displayed target feature information in the feature information of the dynamic object detected for the previous regional scene information;
[0193] If it exists, then a specified object identifier is added to the dynamic object detected for the scene information of the area; wherein the specified object identifier is: the object identifier added to the dynamic object whose characteristic information is the specified characteristic information;
[0194] If not, add a new object identifier for the dynamic object detected for the scene information in the area;
[0195] Based on the object identifications added to all the detected dynamic objects and the determined all the position information, various position points passed by the dynamic objects existing in the sub-area that has completed the preset task are determined.
[0196] Optionally, in a specific implementation, the processor 720 is specifically configured to:
[0197] Path construction is performed on each position information of the dynamic objects added with the same object identifier to obtain at least one initial path;
[0198] For each initial path, the initial path is discretized according to a preset discrete step length to obtain a plurality of discrete points, and based on the plurality of discrete points, various position points passed by the dynamic objects existing in the sub-area that has completed the preset task are determined.
[0199] Optionally, in a specific implementation, the processor 720 is specifically configured to:
[0200] For each object identification, if the number of position information of dynamic objects added with the object identification is greater than a preset number, a path is constructed for each position information of the dynamic objects added with the object identification to obtain an initial path.
[0201] Optionally, in a specific implementation, the processor 720 is specifically configured to:
[0202] For each initial path whose length is greater than a preset length, the initial path is discretized according to a preset discrete step length to obtain a plurality of discrete points.
[0203] Optionally, in a specific implementation, the regional scene information includes: image information and / or laser point cloud.
[0204] Optionally, in a specific implementation, the processor 720 is specifically configured to:
[0205] Based on the determined positional relationship of all the position points and the connectivity relationship between every two position points among all the position points, construct a target path starting from the current position of the target robot and passing through all the position points;
[0206] The connectivity relationship is a relationship determined according to the existence of obstacles between every two position points.
[0207] Optionally, in a specific implementation, the target robot is a cleaning robot, and the preset task is a cleaning task.
[0208] The embodiment of the present invention further provides a robot, such as Figure 8 As shown, it includes a processor 801, a communication interface 802, a memory 803 and a communication bus 804, wherein the processor 801, the communication interface 802, and the memory 803 communicate with each other through the communication bus 804.
[0209] Memory 803, used for storing computer programs;
[0210] The processor 801 is used to implement the steps of any robot control method provided by the above-mentioned embodiments of the present invention when executing the program stored in the memory 803.
[0211] The communication bus mentioned in the above electronic device can be a Peripheral Component Interconnect (PCI) bus or an Extended Industry Standard Architecture (EISA) bus, etc. The communication bus can be divided into an address bus, a data bus, a control bus, etc. For ease of representation, only one thick line is used in the figure, but it does not mean that there is only one bus or one type of bus.
[0212] The communication interface is used for communication between the above electronic device and other devices.
[0213] The memory may include a random access memory (RAM) or a non-volatile memory (NVM), such as at least one disk memory. Optionally, the memory may also be at least one storage device located away from the aforementioned processor.
[0214] The above-mentioned processor can be a general-purpose processor, including a central processing unit (CPU), a network processor (NP), etc.; it can also be a digital signal processor (DSP), an application specific integrated circuit (ASIC), a field programmable gate array (FPGA) or other programmable logic devices, discrete gate or transistor logic devices, discrete hardware components.
[0215] In another embodiment of the present invention, a computer-readable storage medium is provided, in which a computer program is stored. When the computer program is executed by a processor, the steps of any of the above-mentioned robot control methods are implemented.
[0216] In another embodiment provided by the present invention, a computer program product including instructions is also provided, which, when executed on a computer, enables the computer to execute any robot control method in the above embodiments.
[0217] In the above embodiments, it can be implemented in whole or in part by software, hardware, firmware or any combination thereof. When implemented by software, it can be implemented in whole or in part in the form of a computer program product. The computer program product includes one or more computer instructions. When the computer program instructions are loaded and executed on a computer, the process or function described in the embodiment of the present invention is generated in whole or in part. The computer can be a general-purpose computer, a special-purpose computer, a computer network, or other programmable device. The computer instructions can be stored in a computer-readable storage medium, or transmitted from one computer-readable storage medium to another computer-readable storage medium. For example, the computer instructions can be transmitted from a website site, computer, server or data center to another website site, computer, server or data center by wired (e.g., coaxial cable, optical fiber, digital subscriber line (DSL)) or wireless (e.g., infrared, wireless, microwave, etc.). The computer-readable storage medium can be any available medium that a computer can access or a data storage device such as a server or data center that includes one or more available media integrated. The available medium can be a magnetic medium (e.g., a floppy disk, a hard disk, a tape), an optical medium (e.g., a DVD), or a semiconductor medium (e.g., a solid-state hard disk Solid State Disk (SSD)), etc.
[0218] It should be noted that, in this article, relational terms such as first and second, etc. are only used to distinguish one entity or operation from another entity or operation, and do not necessarily require or imply any such actual relationship or order between these entities or operations. Moreover, the terms "include", "comprise" or any other variants thereof are intended to cover non-exclusive inclusion, so that a process, method, article or device including a series of elements includes not only those elements, but also other elements not explicitly listed, or also includes elements inherent to such process, method, article or device. In the absence of further restrictions, the elements defined by the sentence "comprise a ..." do not exclude the existence of other identical elements in the process, method, article or device including the elements.
[0219] Each embodiment in this specification is described in a related manner, and the same or similar parts between the embodiments can be referred to each other, and each embodiment focuses on the differences from other embodiments. In particular, for the device embodiment, robot embodiment, computer-readable storage medium embodiment, and computer program product embodiment, since they are basically similar to the method embodiment, the description is relatively simple, and the relevant parts can be referred to the partial description of the method embodiment.
[0220] The above description is only a preferred embodiment of the present invention and is not intended to limit the protection scope of the present invention. Any modification, equivalent replacement, improvement, etc. made within the spirit and principle of the present invention are included in the protection scope of the present invention.
Claims
1. A robot control method, characterized in that: The method comprises: When the target robot performs a preset task in a designated area, a tracking algorithm is used to track multiple dynamic objects in the sub-area that has completed the preset task, so as to obtain initial paths of the multiple dynamic objects; For each initial path, the initial path is discretized according to a preset discrete step length to obtain a plurality of discrete points, and based on the plurality of discrete points, each position point passed by the dynamic object existing in the sub-area that has completed the preset task is determined; After the target robot completes the preset task for the designated area, a target path starting from the current position of the target robot and passing through all the position points is constructed based on the determined positional relationship of all the position points of the multiple dynamic objects and the connectivity relationship between every two of the all the position points; wherein the connectivity relationship is a relationship determined according to the existence of obstacles between every two position points; The target robot is controlled to move along the target path and execute the preset task.
2. The method according to claim 1, characterized in that: The method of using a tracking algorithm to track the dynamic objects in the sub-area that has completed the preset task to obtain initial paths of multiple dynamic objects includes: Obtain regional scene information collected at preset time intervals; Performing dynamic object detection on each area scene information to obtain a detection result, and when the detection result indicates that a dynamic object exists in the sub-area where the preset task has been completed, determining the position information of the detected dynamic object; Based on the determined respective position information, initial paths of multiple dynamic objects existing in the sub-area that has completed the preset task are determined.
3. The method according to claim 2, characterized in that The method further comprises: For the first area scene information where the dynamic object is detected, determining feature information of the detected dynamic object, and adding an object identifier to the detected dynamic object; For each regional scene information whose acquisition time is after the acquisition time of the first regional scene information, when the obtained detection result indicates that there is a dynamic object in the sub-region, determine the target feature information of the detected dynamic object, and judge whether there is specified feature information matching the displayed target feature information in the feature information of the dynamic object detected for the previous regional scene information; If it exists, then a specified object identifier is added to the dynamic object detected for the scene information of the area; wherein the specified object identifier is: the object identifier added to the dynamic object whose characteristic information is the specified characteristic information; If not, add a new object identifier for the dynamic object detected for the scene information in the area; The determining of initial paths of multiple dynamic objects existing in the sub-area that has completed the preset task based on the determined respective position information includes: Based on the object identifications added to all the detected dynamic objects and the determined all the position information, the initial paths of the multiple dynamic objects existing in the sub-area that has completed the preset task are determined.
4. The method according to claim 3, characterized in that The determining of initial paths of multiple dynamic objects existing in the sub-area that has completed the preset task based on the object identifications added to all the detected dynamic objects and the determined all the position information includes: For each object identification, if the number of position information of dynamic objects added with the object identification is greater than a preset number, a path is constructed for each position information of the dynamic objects added with the object identification to obtain an initial path.
5. The method according to claim 1, characterized in that For each initial path, the initial path is discretized according to a preset discrete step length to obtain multiple discrete points, including: For each initial path whose length is greater than a preset length, the initial path is discretized according to a preset discrete step length to obtain a plurality of discrete points.
6. The method according to claim 2, characterized in that The regional scene information includes: image information and / or laser point cloud.
7. The method according to claim 1, characterized in that The target robot is a cleaning robot, and the preset task is a cleaning task.
8. A robot control device, characterized in that: The device comprises: A sensor, used to collect movement information of the target robot and spatial information of the environment in which the target robot is located when the target robot performs a preset task in a designated area; A processor is used to determine the sub-area that has completed the preset task according to the movement information of the target robot collected by the sensor and the spatial information of the environment in which the target robot is located; when the target robot performs the preset task on the designated area, use a tracking algorithm to track multiple dynamic objects existing in the sub-area that has completed the preset task to obtain initial paths of the multiple dynamic objects; for each initial path, discretize the initial path according to a preset discrete step length to obtain multiple discrete points, and determine the various position points passed by the dynamic objects existing in the sub-area that has completed the preset task based on the multiple discrete points; after the target robot completes the preset task on the designated area, based on the position relationship of all the position points of the multiple dynamic objects determined, and the connectivity relationship between every two position points in all the position points, construct a target path starting from the current position of the target robot and passing through all the position points; wherein the connectivity relationship is: a relationship determined according to the existence of obstacles between every two position points; control the target robot to move along the target path and perform the preset task.
9. The device according to claim 8, characterized in that The sensor is also used to collect regional scene information of the target robot during its movement; The processor is specifically used to obtain regional scene information collected at preset time intervals, perform dynamic object detection on each regional scene information, obtain a detection result, and determine the position information of the detected dynamic object when the detection result indicates that there is a dynamic object in the sub-region where the preset task has been completed; Based on the determined respective position information, initial paths of multiple dynamic objects existing in the sub-area that has completed the preset task are determined.
10. A robot, characterized in that: It includes a processor, a communication interface, a memory and a communication bus, wherein the processor, the communication interface and the memory communicate with each other through the communication bus; Memory, used to store computer programs; A processor, for implementing the method steps described in any one of claims 1 to 7 when executing a program stored in a memory.
11. A computer-readable storage medium, characterized in that: The computer-readable storage medium stores a computer program, and when the computer program is executed by a processor, the method steps described in any one of claims 1 to 7 are implemented.
