Robot anti-falling method, device, robot and storage medium
By collecting and analyzing environmental point clouds, determining the possible fall areas of the robot and performing path planning, the problem that the robot cannot accurately detect fall areas in complex environments is solved, and the work reliability of the robot is improved.
Patent Information
- Application Number
- CN202310383493.0
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2023-04-06
- Publication Date
- 2025-07-11
- Estimated Expiration
- 2043-04-06
AI Technical Summary
The robot cannot accurately detect fall areas in complex environments, resulting in false detection and inability to work properly.
By collecting the point clouds in the environment in which the robot is located, determine the point clouds with a height less than or equal to the preset height under the preset robot coordinate system as the fall point cloud, and determine the fall area when the proportion of the point clouds reaches a certain proportion, and perform path planning to avoid it.
Improve the detection accuracy of the fall area, ensure that the robot can work normally and avoid misdetection and falls.
Smart Images

Figure CN116330291B_ABST
Abstract
Description
Technical Field
[0001] The present invention relates to the technical field of robots, and in particular, to a robot anti-fall method, device, robot and storage medium. Background Art
[0002] In service places such as hotels, in order to save labor costs, robots can be used for greeting guests, leading guests to rooms, delivering meals by robots, delivering items to rooms, and so on. The working environments of robots are various. Among them, the most dangerous environment for robots is the fall area that causes robots to fall. In the case of robot navigation yaw, robots are very likely to fall from the fall area. Currently, robots mainly use depth cameras to detect fall areas, such as stairs. When a fall area is detected, the robot will give an alarm and stop working. However, in complex scenarios, robots are prone to misdetect the fall area, resulting in the robot stopping, which affects the normal operation of the robot. Summary of the Invention
[0003] The main purpose of the present invention is to provide a robot anti-fall method, device, robot and storage medium, aiming to solve the problem that robots cannot accurately detect fall areas, resulting in the inability of robots to work normally.
[0004] To achieve the above object, the present invention provides a robot anti-fall method, which is applied to a robot. The method includes:
[0005] Collect the environmental point cloud of the external environment where the robot is located;
[0006] In the environmental point cloud, determine the point cloud with a height less than or equal to a preset height in a preset robot coordinate system as the fall point cloud;
[0007] When it is detected that the proportion of the number of points in the fall point cloud to the number of points in the environmental point cloud is greater than a first preset proportion, determine the area corresponding to the fall point cloud as the fall area;
[0008] Perform path planning according to the fall area.
[0009] Optionally, after the step of determining the point cloud with a height less than or equal to a preset height in a preset robot coordinate system as the fall point cloud in the environmental point cloud, it includes:
[0010] When it is determined that the proportion of the fall point cloud in the environmental point cloud is greater than a second preset proportion, and the number of points in the fall point cloud is greater than a first point cloud number threshold, adjust the maximum speed of the robot according to the number of points in the fall point cloud, where the more the number of points in the fall point cloud, the lower the adjusted maximum speed of the robot.
[0011] Optionally, the step of adjusting the maximum speed of the robot according to the number of point clouds of the fall point cloud includes:
[0012] When it is detected that the number of point clouds of the fall point cloud exceeds the second point cloud number threshold, control the robot to stop running;
[0013] When it is detected that the number of point clouds of the fall point cloud does not exceed the second point cloud number threshold, determine the preset point cloud number range mapped by the number of point clouds of the fall point cloud, and reduce the maximum speed of the robot to the preset speed corresponding to the preset point cloud number range.
[0014] Optionally, after the step of controlling the robot to stop running when it is detected that the number of point clouds of the fall point cloud exceeds the second point cloud number threshold, it further includes:
[0015] Detect whether the number of point clouds of the fall point cloud in the environmental point clouds of consecutive preset frames all exceeds the second point cloud number threshold;
[0016] If the number of point clouds of the fall point cloud in the environmental point clouds of consecutive preset frames does not all exceed the second point cloud number threshold, control the robot to resume running;
[0017] If the number of point clouds of the fall point cloud in the environmental point clouds of consecutive preset frames all exceeds the second point cloud number threshold, alarm a fatal error and control the robot not to resume running.
[0018] Optionally, the step of determining the area corresponding to the fall point cloud as the fall area includes:
[0019] Detect whether the area corresponding to the fall point cloud is a connected area;
[0020] If the area corresponding to the fall point cloud is a connected area, determine the area corresponding to the fall point cloud as the fall area.
[0021] Optionally, after the step of detecting whether the area corresponding to the fall point cloud is a connected area, it further includes:
[0022] If the area corresponding to the fall point cloud is not a connected area, determine the sub-areas with an area larger than the preset area in each sub-area of the area corresponding to the fall point cloud as the fall area, and execute the step of path planning according to the fall area to avoid the fall area.
[0023] Optionally, the step of collecting the environmental point cloud of the external environment where the robot is located includes:
[0024] Collect the environmental depth image of the external environment where the robot is located through the depth camera of the robot;
[0025] Convert the environmental depth image into a point cloud through the internal camera parameters of the depth camera to obtain an environmental point cloud.
[0026] To achieve the above object, the present invention further provides a robot anti-fall device, which is deployed on the robot. The device includes:
[0027] An acquisition module, configured to acquire the environmental point cloud of the external environment where the robot is located;
[0028] A determination module, configured to determine, in the environmental point cloud, the point cloud with a height less than or equal to a preset height in a preset robot coordinate system as the fall point cloud;
[0029] The determination module is further configured to, when detecting that the proportion of the number of point clouds of the fall point cloud in the number of point clouds of the environmental point cloud is greater than a first preset proportion, determine the area corresponding to the fall point cloud as the fall area;
[0030] A path planning module, configured to perform path planning according to the fall area.
[0031] To achieve the above object, the present invention further provides a robot, which includes: a memory, a processor, and a robot anti-fall program stored on the memory and executable on the processor. When the robot anti-fall program is executed by the processor, the steps of the above-mentioned robot anti-fall method are implemented.
[0032] In addition, to achieve the above object, the present invention further provides a computer-readable storage medium, on which a robot anti-fall program is stored. When the robot anti-fall program is executed by a processor, the steps of the above-mentioned robot anti-fall method are implemented.
[0033] In the present invention, by acquiring the environmental point cloud of the external environment where the robot is located; in the environmental point cloud, determining the point cloud with a height less than or equal to a preset height in a preset robot coordinate system as the fall point cloud; when detecting that the proportion of the number of point clouds of the fall point cloud in the number of point clouds of the environmental point cloud is greater than a first preset proportion, determining the area corresponding to the fall point cloud as the fall area; and performing path planning according to the fall area. When the proportion of the number of point clouds of the fall point cloud in the number of point clouds of the environmental point cloud exceeds a certain threshold, the present invention determines the area corresponding to the fall point cloud as the fall area, avoiding the situation of misdetecting the fall area, improving the accuracy of detecting the fall area, and ensuring the normal operation of the robot. Description of the Drawings
[0034] Figure 1 It is a schematic structural diagram of the hardware operating environment related to the solution of the embodiment of the present invention;
[0035] Figure 2 Schematic flowchart of the first embodiment of the robot anti-falling method of the present invention;
[0036] Figure 3 Schematic flowchart of an implementation manner of the robot anti-falling method of the present invention;
[0037] Figure 4 Schematic flowchart of an implementation manner of the robot anti-falling method of the present invention;
[0038] Figure 5 Schematic diagram of the functional modules of the preferred embodiment of the robot anti-falling device of the present invention.
[0039] The realization, functional features and advantages of the object of the present invention will be further described with reference to the embodiments and the accompanying drawings. Detailed implementation manners
[0040] It should be understood that the specific embodiments described herein are only used to explain the present invention and are not used to limit the present invention.
[0041] As Figure 1 shown, Figure 1 is a schematic diagram of the device structure of the hardware operating environment involved in the embodiment solution of the present invention.
[0042] It should be noted that the device in the embodiment of the present invention can be a smart phone, a personal computer, a server or other devices with data processing capabilities, and the device can be deployed in a mobile robot, which is not specifically limited herein.
[0043] As Figure 1 shown, the device may include: a processor 1001, such as a CPU, a memory 1002, and a communication bus 1003. Among them, the communication bus 1003 is used to realize the connection and communication between these components. The memory 1002 can be a high-speed RAM memory or a stable memory (non-volatile memory), such as a disk memory. Optionally, the memory 1002 can also be a storage device independent of the foregoing processor 1001.
[0044] Those skilled in the art can understand that Figure 1 the device structure shown in
[0045] does not constitute a limitation on the device, and may include more or fewer components than shown in the figure, or combine some components, or different component arrangements. Figure 1 As Figure 1In the device shown, the processor 1001 can be used to call the robot anti-fall program stored in the memory 1002 and perform the following operations:
[0046] Collect the environmental point cloud of the external environment where the robot is located;
[0047] In the environmental point cloud, determine the point cloud with a height less than or equal to a preset height in the preset robot coordinate system as the fall point cloud;
[0048] When it is detected that the proportion of the number of points in the fall point cloud to the number of points in the environmental point cloud is greater than a first preset proportion, determine the area corresponding to the fall point cloud as the fall area;
[0049] Perform path planning according to the fall area.
[0050] Further, after the operation of determining the point cloud with a height less than or equal to a preset height in the preset robot coordinate system as the fall point cloud in the environmental point cloud, the processor 1001 can also be used to call the robot anti-fall program stored in the memory 1002 and perform the following operations:
[0051] When it is determined that the proportion of the fall point cloud in the environmental point cloud is greater than a second preset proportion and the number of points in the fall point cloud is greater than a first point cloud number threshold, adjust the maximum speed of the robot according to the number of points in the fall point cloud, where the more the number of points in the fall point cloud, the lower the adjusted maximum speed of the robot.
[0052] Further, the operation of adjusting the maximum speed of the robot according to the number of points in the fall point cloud includes:
[0053] When it is detected that the number of points in the fall point cloud exceeds a second point cloud number threshold, control the robot to stop running;
[0054] When it is detected that the number of points in the fall point cloud does not exceed the second point cloud number threshold, determine the preset point cloud number range mapped by the number of points in the fall point cloud, and reduce the maximum speed of the robot to the preset speed corresponding to the preset point cloud number range.
[0055] Further, after the operation of controlling the robot to stop running when it is detected that the number of points in the fall point cloud exceeds a second point cloud number threshold, the processor 1001 can also be used to call the robot anti-fall program stored in the memory 1002 and perform the following operations:
[0056] Detect whether the number of points in the fall point cloud in the environmental point cloud of a continuous preset number of frames all exceeds the second point cloud number threshold;
[0057] If the number of points in the falling point cloud in the environmental point cloud for a continuous preset number of frames does not all exceed the second point cloud number threshold, control the robot to resume operation;
[0058] If the number of points in the falling point cloud in the environmental point cloud for a continuous preset number of frames all exceed the second point cloud number threshold, alarm a fatal error and control the robot not to resume operation.
[0059] Further, the operation of determining the area corresponding to the falling point cloud as the falling area includes:
[0060] Detect whether the area corresponding to the falling point cloud is a connected area;
[0061] If the area corresponding to the falling point cloud is a connected area, determine the area corresponding to the falling point cloud as the falling area.
[0062] Further, after the operation of detecting whether the area corresponding to the falling point cloud is a connected area, it further includes:
[0063] If the area corresponding to the falling point cloud is not a connected area, determine the sub-areas with an area greater than the preset area in each sub-area of the area corresponding to the falling point cloud as the falling area, and perform the operation of path planning according to the falling area to avoid the falling area.
[0064] Further, the operation of collecting the environmental point cloud of the external environment where the robot is located includes:
[0065] Collect the environmental depth image of the external environment where the robot is located through the depth camera of the robot;
[0066] Convert the environmental depth image into a point cloud through the camera internal parameters of the depth camera to obtain the environmental point cloud.
[0067] Based on the above structure, various embodiments of the robot anti-fall method of the present invention are proposed.
[0068] Refer to Figure 2 , Figure 2 is the flow diagram of the first embodiment of the robot anti-fall method of the present invention.
[0069] An embodiment of the present invention provides an embodiment of a robot anti-fall method. It should be noted that although the logical order is shown in the flowchart, in some cases, the steps shown or described may be executed in a different order than here. The execution subject of each embodiment of the robot anti-fall method of the present invention can be a robot. The robot can be a conventional robot controlled by an automatic control program. The types and specific implementation details of the robot are not limited in each embodiment. In this embodiment, the robot anti-fall method includes the following steps S10 - S30:
[0070] Step S10, collect the environmental point cloud of the external environment where the robot is located.
[0071] In this embodiment, the point cloud of the external environment where the robot is located (hereinafter referred to as the environmental point cloud for distinction) is collected. By classifying the environmental point cloud, the area that will cause the robot to fall is determined according to the classified points, so that the robot can avoid this area during path planning to prevent falling. Specifically, in a feasible implementation manner, the environmental point cloud can be collected by a laser scanner; in a feasible implementation manner, it can also be collected by a TOF (Time of Flight) sensor; in another feasible implementation manner, it can also be collected by a depth camera, which can be specifically set according to actual needs and is not limited here.
[0072] Step S20, in the environmental point cloud, determine the point cloud with a height less than or equal to a preset height in a preset robot coordinate system as the fall point cloud.
[0073] The fall area, obstacles, and the ground can be distinguished from the height. For example, the height of the fall area is always lower than the ground, so the robot will fall in the fall area during operation. Therefore, in this embodiment, the environmental point cloud is classified according to the height of the environmental point cloud to distinguish the fall area in the environment.
[0074] In the specific implementation manner, the coordinate system in which the coordinates of the environmental point cloud are located is determined according to the acquisition method. For example, when the environmental point cloud is acquired by laser scanning, the origin of the coordinate system in which the environmental point cloud is located is the position where the laser scanner is located; when the environmental point cloud is acquired by a depth camera, the origin of the coordinate system in which the environmental point cloud is located is the light point of the depth camera. However, in order to accurately describe the specific positions of various objects in the external environment in the real world, it is necessary to convert the acquired environmental point clouds to the world coordinate system that describes the positions of various objects in the real world. The origin of the world coordinate system can be selected according to actual needs. In this embodiment, the positive direction of the x-axis of the coordinate system can be determined by the front orientation of the robot, the positive direction of the y-axis can be determined by the left orientation of the robot, and the upward orientation perpendicular to the x-axis and the y-axis can be determined as the positive direction of the z-axis of the coordinate system. Among them, the origin of the coordinate system is any component of the robot. Hereinafter, this coordinate system will be referred to as the preset robot coordinate system for distinction. Exemplarily, in a feasible implementation manner, the preset robot coordinate system can be centered on the robot chassis. At this time, the preset robot coordinate system is also called the chassis coordinate system.
[0075] Exemplarily, in a feasible implementation manner, when the environmental point cloud is acquired by a depth camera, the coordinates of the environmental point cloud can be converted to the coordinates in the preset robot coordinate system of the robot through the external camera parameters. The external camera parameters are composed of a rotation matrix R and a translation vector t, and can be specifically expressed as:
[0076]
[0077] Specifically, in this embodiment, after the coordinates of the environmental point cloud are converted to the preset robot coordinate system, in the environmental point cloud, the point cloud with a height in the preset robot coordinate system, that is, the Z-axis height less than or equal to the preset height, is determined as the drop point cloud. In the specific implementation manner, the preset height can be determined according to the robot parameters and the engineer's experience, and no limitation is made here.
[0078] Step S30, when it is detected that the proportion of the number of point clouds of the drop point cloud in the number of point clouds of the environmental point cloud is greater than a first preset proportion, the area corresponding to the drop point cloud is determined as the drop area.
[0079] In this embodiment, a proportion threshold (hereinafter referred to as the first preset proportion for distinction) is preset. When it is detected that the proportion of the number of point clouds of the drop point cloud in the number of point clouds of the environmental point cloud is greater than the first preset proportion, it is determined that the area range corresponding to the drop point cloud is large enough for the robot to fall. At this time, the area corresponding to the drop point cloud is determined as the drop area.
[0080] Further, in a feasible implementation, due to the hardware limitations of the device for collecting point clouds, there may be meaningless invalid point clouds in the environmental point cloud, such as points with infinite coordinates. At this time, the environmental point cloud can be filtered to filter out the invalid point clouds in the environmental point cloud, and the proportion of the falling point cloud is calculated using the number of point clouds in the environmental point cloud after filtering out the invalid point clouds, so as to improve the accuracy of the calculated proportion of the falling point cloud, thereby improving the accuracy of detecting the falling area and ensuring the normal operation of the robot.
[0081] In another feasible implementation, a voxel filtering algorithm can be used to process the point cloud.
[0082] Step S40, perform path planning according to the falling area.
[0083] In this embodiment, after determining the falling area, path planning is performed according to the falling area so that the robot can avoid the falling area during operation.
[0084] In a specific implementation, after determining the falling area, the falling point cloud corresponding to the falling area can be published to the cost map of the robot to provide a reference for the path planning of the robot. The specific process is not elaborated here.
[0085] Further, in a feasible implementation, in step S30, when the proportion of the number of point clouds of the falling point cloud in the number of point clouds of the environmental point cloud is greater than the first preset proportion, determining the area corresponding to the falling point cloud as the falling area includes S301 - S302:
[0086] Step S301, detect whether the area corresponding to the falling point cloud is a connected area;
[0087] In this implementation, after detecting that the proportion of the number of point clouds of the falling point cloud in the number of point clouds of the environmental point cloud exceeds the first preset proportion, it is detected whether the area corresponding to the falling point cloud is a connected area. If the area corresponding to the falling point cloud is not connected, it means that although the number of point clouds of the falling point cloud is large, the area corresponding to the falling point cloud may be composed of many small areas that are not sufficient to cause the robot to fall.
[0088] Specifically, it can be detected whether the area corresponding to the falling point cloud is connected based on the point cloud map. In a feasible implementation, after determining the falling point cloud, the falling point cloud can be color - marked, and it is determined whether the color marks in the point cloud map are connected through image detection to determine whether the area corresponding to the falling point cloud is connected; in another feasible implementation, it can also be detected whether the area corresponding to the falling point cloud is connected through algorithms such as DFS (Depth First Search), BFS (Breath First Search), and union - find algorithm. The specific details are not elaborated here.
[0089] Step S302: If the area corresponding to the dropped point cloud is a connected area, determine the area corresponding to the dropped point cloud as the dropped area.
[0090] In this embodiment, if the area corresponding to the dropped point cloud is a connected area, it is considered that this area may cause the robot to drop. At this time, determine the area corresponding to the dropped point cloud as the dropped area.
[0091] This embodiment can improve the accuracy of path planning and enhance the safety of the robot during operation.
[0092] Further, in a feasible embodiment, after step S301 of detecting whether the area corresponding to the dropped point cloud is a connected area, S303 may further be included:
[0093] Step S303: If the area corresponding to the dropped point cloud is not a connected area, determine the sub-areas with an area greater than a preset area in each sub-area of the area corresponding to the dropped point cloud as the dropped area, and execute the step of path planning according to the dropped area to avoid the dropped area.
[0094] In this embodiment, if the area corresponding to the dropped point cloud is not connected, for the areas of each unconnected sub-area in the area corresponding to the dropped point cloud, determine the sub-areas with an area greater than a preset area in each sub-area of the area corresponding to the dropped point cloud as the dropped area, and execute the step of path planning according to the dropped area to avoid the dropped area.
[0095] This embodiment can avoid missing the dropped area, thereby improving the accuracy of the robot's path planning and enhancing the safety of the robot during operation.
[0096] Further, in a feasible embodiment, step S10 of collecting the environmental point cloud of the external environment where the robot is located may include S101 - S102:
[0097] Step S101: Collect the environmental depth image of the external environment where the robot is located through the depth camera of the robot.
[0098] In this embodiment, collect the depth image of the external environment where the robot is located through the depth camera of the robot, hereinafter referred to as the environmental depth image for distinction.
[0099] Step S102: Convert the environmental depth image into a point cloud through the camera internal parameters of the depth camera to obtain the environmental point cloud.
[0100] In this embodiment, after obtaining the environmental depth image, convert the environmental depth image into a point cloud through the camera internal parameters of the depth camera to obtain the environmental point cloud.
[0101] Further, in a feasible implementation, referring to Figure 3 , Figure 3 is a schematic flowchart of an implementation of the robot anti-fall method of the present invention. In this implementation, environmental point clouds are collected through a depth camera. As shown in Figure 3 , after the environmental point clouds are collected, the external camera parameters are read, and the environmental point clouds in the environmental point clouds are transformed into the chassis coordinate system of the robot through the external camera parameters (that is, as shown in Figure 3 , the point cloud data is transferred to the base (chassis) coordinate system according to the external parameters). That is, the coordinates of the point clouds collected by the depth camera are transformed from the pixel coordinate system to the chassis coordinate system of the robot through coordinate transformation.
[0102] The point clouds in the environmental point clouds with a height less than or equal to the preset height are determined as fall point clouds (that is, as shown in Figure 3 , it is detected whether the Z-axis height of the point cloud is greater than ht1. If the Z-axis height of the point cloud is not greater than ht1, it is classified as a fall environmental point cloud). In this implementation, obstacle point clouds and ground filter points are also determined from the environmental point clouds (that is, as shown in Figure 3 , it is detected whether the Z-axis height of the point cloud is greater than ht2. If the point cloud with a Z-axis height greater than ht2, it is classified as an obstacle point cloud; if the Z-axis height is less than or equal to ht2 and greater than ht1, it is classified as ground point filtering and filtered out).
[0103] In this embodiment, environmental point clouds of the external environment where the robot is located are collected; in the environmental point clouds, the point clouds with a height less than or equal to the preset height in the preset robot coordinate system are determined as fall point clouds; when the proportion of the number of point clouds of the detected fall point clouds in the number of point clouds of the environmental point clouds is greater than the first preset proportion, the area corresponding to the fall point clouds is determined as the fall area; path planning is performed according to the fall area.
[0104] In this embodiment, when the proportion of the fall point clouds in the environmental point clouds exceeds a certain threshold, the area corresponding to the fall point clouds is determined as the fall area, avoiding the situation of misdetecting the fall area, improving the accuracy of detecting the fall area, and ensuring the normal operation of the robot.
[0105] Further, based on the above first embodiment, a second embodiment of the robot anti-fall method of the present invention is proposed. In this embodiment, after the step S20 of determining the point clouds with a height less than or equal to the preset height in the preset robot coordinate system as fall point clouds in the environmental point clouds, step S50 may be included:
[0106] Step S50. When it is determined that the proportion of the dropped point cloud in the environmental point cloud is greater than a second preset proportion and the number of points in the dropped point cloud is greater than a first point cloud number threshold, adjust the maximum speed of the robot according to the number of points in the dropped point cloud. The more the number of points in the dropped point cloud, the lower the adjusted maximum speed of the robot.
[0107] In this embodiment, a proportion threshold (hereinafter referred to as the second preset proportion for distinction) and a threshold of the number of point clouds (hereinafter referred to as the first point cloud number threshold for distinction) are preset. By comparing the proportion of the number of dropped point clouds to the number of environmental point clouds with the second preset proportion and comparing the number of points in the dropped point cloud with the first point cloud number threshold, it can be determined whether the robot is close to the dropping area. Specifically, when it is determined that the proportion of the dropped point cloud in the environmental point cloud is greater than the second preset proportion and the number of points in the dropped point cloud is greater than the first point cloud number threshold, it is determined that the robot is close to the dropping area. At this time, the maximum speed of the robot can be adjusted. This embodiment enables the robot to work properly when detecting the dropping area.
[0108] Specifically, in this embodiment, the degree to which the robot is close to the dropping area is determined according to the number of points in the dropped point cloud. Therefore, the maximum speed of the robot is adjusted according to the number of points in the dropped point cloud. The more the number of points in the dropped point cloud, the closer the robot is determined to be to the dropping area. At this time, the lower the adjusted maximum speed of the robot. This embodiment can avoid the situation where the robot is too fast when approaching the dropping area and cannot perform path planning in time to avoid the dropping area, improving the safety of the robot.
[0109] Further, in a feasible implementation manner, in step S50, adjusting the maximum speed of the robot according to the number of points in the dropped point cloud includes S501 - S502:
[0110] Step S501. When it is detected that the number of points in the dropped point cloud exceeds a second point cloud number threshold, control the robot to stop running.
[0111] In this embodiment, a point cloud number threshold is preset, hereinafter referred to as the second point cloud number threshold for distinction. When it is detected that the number of points in the dropped point cloud exceeds the second point cloud number threshold, it is determined that the robot is very close to the dropping area, and the possibility of the robot falling due to continued movement is very high. At this time, control the robot to stop running. Further, in a feasible implementation manner, the robot will report a type D error, that is, an alarm error.
[0112] Step S502, when it is detected that the number of point clouds of the dropped point cloud does not exceed the second point cloud number threshold, determine the preset point cloud number range mapped by the number of point clouds of the dropped point cloud, and reduce the maximum speed of the robot to the preset speed corresponding to the preset point cloud number range.
[0113] In this embodiment, when it is detected that the number of point clouds of the dropped point cloud does not exceed the second point cloud number threshold, it is determined that the robot is close to the dropped area but there is still a certain distance. At this time, the robot can run normally, but at this time, the maximum speed of the robot needs to be adjusted to reduce the speed of the robot approaching the dropped area, and avoid the situation that the speed of the robot is too high to perform path planning in time to avoid the dropped area, thereby improving the safety of the robot.
[0114] Specifically, in this embodiment, different point cloud number ranges are set. Different preset point cloud number ranges can represent the degree of closeness between the robot and the dropped area, and different preset point cloud number ranges correspond to different preset speeds. It can be understood that the lower the preset point cloud number range, the farther the robot is from the dropped area, and the higher the preset speed corresponding to the preset point cloud number range. In a specific embodiment, the number of preset point cloud number ranges can be set according to actual needs. For example, 3 preset point cloud number ranges can be set.
[0115] In this embodiment, determine the preset point cloud number range mapped by the number of point clouds of the dropped point cloud, and reduce the maximum speed during the operation of the robot to the preset speed corresponding to the preset point cloud number range. By reducing the maximum speed of the robot in this embodiment, the robot can be safe while ensuring the normal operation of the robot.
[0116] Further, in a feasible embodiment, after step S501, when it is detected that the number of point clouds of the dropped point cloud exceeds the second point cloud number threshold and the robot is controlled to stop running, it may include S503 - S305:
[0117] Step S503, detect whether the number of point clouds of the dropped point cloud in the environmental point clouds of consecutive preset frames all exceeds the second point cloud number threshold.
[0118] In this embodiment, detect whether the number of point clouds of the dropped point cloud in the environmental point clouds of consecutive preset frames all exceeds the second point cloud number threshold to determine whether the robot continues to approach the dropped area. In a specific embodiment, the preset number of frames can be set according to actual needs and is not limited here.
[0119] Step S504, if the number of point clouds of the dropped point cloud in the environmental point clouds of consecutive preset frames does not all exceed the second point cloud number threshold, then control the robot to resume running.
[0120] If the number of points in the falling point cloud among the environmental point clouds for a continuous preset number of frames does not all exceed the second point cloud quantity threshold, it is determined that the robot is not continuously approaching the falling area. At this time, the robot can be controlled to resume operation. Further, in a feasible implementation, if the robot reduces its maximum speed before stopping, after resuming operation, it runs at the reduced maximum speed to improve the safety of the robot.
[0121] Step S505, if the number of points in the falling point cloud among the environmental point clouds for a continuous preset number of frames all exceed the second point cloud quantity threshold, a fatal error is alarmed and the robot is controlled to be irrecoverably inoperative.
[0122] If the number of points in the falling point cloud among the environmental point clouds for a continuous preset number of frames all exceed the second point cloud quantity threshold, it is determined that the robot is continuously approaching the falling area and is very close to the falling area. At this time, the robot reports a fatal error and the robot is controlled to be irrecoverably inoperative to prevent the robot from falling and improve the safety of the robot.
[0123] In this embodiment, when it is determined that the proportion of the falling point cloud in the environmental point cloud is greater than the second preset proportion and the number of points in the falling point cloud is greater than the first point cloud quantity threshold, the maximum speed of the robot is adjusted according to the number of points in the falling point cloud. Among them, the more the number of points in the falling point cloud, the lower the adjusted maximum speed of the robot.
[0124] This embodiment enables the robot to work properly when detecting a falling area. Moreover, this embodiment can prevent the situation where the robot moves too fast when approaching the falling area and cannot perform path planning in time to avoid the falling area, improving the safety of the robot.
[0125] Further, in a feasible implementation, with reference to Figure 4 , Figure 4 FIG. is a schematic flowchart of an embodiment of the robot anti-falling method of the present invention. In this embodiment, after dividing the environmental point cloud into a falling point cloud (i.e., the falling environmental point cloud shown in Figure 4 ), a ground filtered point cloud (i.e., the filtered one shown in Figure 4 ), and an obstacle point cloud, the moving speed of the robot is adjusted according to the number of points in the falling point cloud. Specifically, as shown in Figure 4 , the falling point cloud is counted, and it is detected whether the number of points in the falling point cloud (i.e., the number of falling point clouds shown in Figure 4 ) exceeds the first preset point cloud quantity, and it is detected whether the proportion of the number of points in the falling point cloud in the environmental point cloud (i.e., the total point cloud shown in Figure 4 ) exceeds the second preset proportion (i.e., Figure 4The number of drop point clouds shown in [[]] and the proportion of the total point clouds occupied exceed a certain threshold). If the number of point clouds of the drop point cloud does not exceed the first preset number of point clouds, and the proportion of the number of point clouds of the drop point cloud in the number of point clouds of the environmental point cloud does not exceed the second preset proportion, the drop point cloud is considered as noise and is not processed.
[0126] If the number of point clouds of the drop point cloud exceeds the preset threshold, and the proportion of the number of point clouds of the drop point cloud in the number of point clouds of the environmental point cloud exceeds the first preset number of point clouds, determine the range of the number of point clouds mapped by the number of point clouds of the drop point cloud, and reduce the maximum speed during the operation of the robot to the preset speed corresponding to the range of the number of point clouds. Specifically, in this embodiment, 3 ranges of the number of point clouds are preset:
[0127] When the number of point clouds of the drop point cloud is within the first preset range (that is, Figure 4 the number of point clouds shown in [[]] does not exceed T1), it is determined that the robot is approaching the drop area, but the distance is relatively far. At this time, perform a first-level deceleration on the robot, and limit the maximum speed of the robot within the preset first speed range;
[0128] When the number of point clouds of the drop point cloud is within the second preset range (that is, Figure 4 the number of point clouds shown in [[]] exceeds T1 and does not exceed T2), it is determined that the robot is relatively close to the drop area, but the distance is not very close. At this time, limit the maximum speed of the robot within the preset second speed range;
[0129] When the number of point clouds of the drop point cloud is within the third preset range (that is, Figure 4 the number of point clouds shown in [[]] exceeds T2 and does not exceed T3), it is determined that the robot is very close to the drop area, and limit the maximum speed of the robot within the preset third speed range.
[0130] In this embodiment, when the number of point clouds of the drop point cloud continuously exceeds the second point cloud number threshold for 3 frames (that is, Figure 4 T3 shown in [[]]), report an alarm error once (that is, Figure 4 class D error shown in [[]]), and control the robot to stop running. At this time, the operation of the robot can be restored; if the robot reports class D errors continuously for 3 frames, then report that the robot has a fatal error (that is, Figure 4 class A error shown in [[]]), and control the robot not to be restored to run; if the robot does not report class D errors continuously for 3 frames, then restore the normal operation of the robot. If the maximum speed of the robot is adjusted before stopping running, after restoring the operation, run at the adjusted maximum speed.
[0131] In addition, an embodiment of the present invention also proposes a robot anti-drop device, which is deployed on the robot. Referring to Figure 5 the device includes:
[0132] The acquisition module 10 is configured to acquire the environmental point cloud of the external environment where the robot is located;
[0133] The determination module 20 is configured to determine, in the environmental point cloud, the point cloud with a height less than or equal to a preset height in a preset robot coordinate system as the drop point cloud;
[0134] The determination module 20 is further configured to, when detecting that the proportion of the number of point clouds of the drop point cloud in the number of point clouds of the environmental point cloud is greater than a first preset proportion, determine the area corresponding to the drop point cloud as the drop area;
[0135] The path planning module 30 is configured to perform path planning according to the drop area.
[0136] In a feasible implementation manner, the device further includes an adjustment module, and the adjustment module is configured to:
[0137] When determining that the proportion of the drop point cloud in the environmental point cloud is greater than a second preset proportion and the number of point clouds of the drop point cloud is greater than a first point cloud number threshold, adjust the maximum speed of the robot according to the number of point clouds of the drop point cloud, where the more the number of point clouds of the drop point cloud, the lower the adjusted maximum speed of the robot.
[0138] In a feasible implementation manner, the adjustment module is further configured to:
[0139] When detecting that the number of point clouds of the drop point cloud exceeds a second point cloud number threshold, control the robot to stop running;
[0140] When detecting that the number of point clouds of the drop point cloud does not exceed the second point cloud number threshold, determine the preset point cloud number range mapped by the number of point clouds of the drop point cloud, and reduce the maximum speed of the robot to the preset speed corresponding to the preset point cloud number range.
[0141] In a feasible implementation manner, the adjustment module is further configured to:
[0142] Detect whether the number of point clouds of the drop point cloud in the environmental point cloud of a continuous preset number of frames all exceeds the second point cloud number threshold;
[0143] If the number of point clouds of the drop point cloud in the environmental point cloud of a continuous preset number of frames does not all exceed the second point cloud number threshold, control the robot to resume running;
[0144] If the number of point clouds of the drop point cloud in the environmental point cloud of a continuous preset number of frames all exceeds the second point cloud number threshold, alarm a fatal error and control the robot to be irrecoverably stopped.
[0145] In a feasible implementation manner, the determining module 20 is further configured to:
[0146] Detect whether the area corresponding to the dropped point cloud is a connected area;
[0147] If the area corresponding to the dropped point cloud is a connected area, determine the area corresponding to the dropped point cloud as the dropped area.
[0148] In a feasible implementation manner, the determining module 20 is further configured to:
[0149] If the area corresponding to the dropped point cloud is not a connected area, determine the sub-areas with an area larger than a preset area among the sub-areas of the area corresponding to the dropped point cloud as the dropped areas, and perform the step of path planning according to the dropped areas to avoid the dropped areas.
[0150] In a feasible implementation manner, the acquisition module 10 is further configured to:
[0151] Collect an environmental depth image of the external environment where the robot is located through the depth camera of the robot;
[0152] Convert the environmental depth image into a point cloud through the camera internal parameters of the depth camera to obtain an environmental point cloud.
[0153] The extended content of the specific implementation manner of the robot anti-drop device of the present invention is basically the same as that of each embodiment of the above robot anti-drop method, and will not be elaborated here.
[0154] In addition, an embodiment of the present invention further provides a computer-readable storage medium, on which a robot anti-drop program is stored, and when the robot anti-drop program is executed by a processor, the steps of the robot anti-drop method described below are implemented.
[0155] For each embodiment of the robot and the computer-readable storage medium of the present invention, reference can be made to each embodiment of the robot anti-drop method of the present invention, which will not be elaborated here.
[0156] It should be noted that in this article, the terms "include", "comprise" or any other variant thereof are intended to cover non-exclusive inclusion, so that a process, method, article or device including a series of elements not only includes those elements, but also includes other elements not expressly listed, or further includes elements inherent to such process, method, article or device. Without further limitation, an element defined by the statement "including one..." does not exclude the existence of another identical element in the process, method, article or device including the element.
[0157] The serial numbers of the above embodiments of the present invention are only for description and do not represent the advantages and disadvantages of the embodiments.
[0158] Through the description of the above embodiments, those skilled in the art can clearly understand that the methods of the above embodiments can be implemented by means of software plus a necessary general hardware platform. Of course, they can also be implemented by hardware, but in many cases the former is a better implementation. Based on such an understanding, the technical solution of the present invention, in essence or the part that contributes to the prior art, can be embodied in the form of a software product. This computer software product is stored in a storage medium (such as ROM / RAM, magnetic disk, optical disk) and includes several instructions for causing a terminal device (which can be a mobile phone, a computer, a server, an air conditioner, or a network device, etc.) to execute the methods described in various embodiments of the present invention.
[0159] The above are only the preferred embodiments of the present invention, and do not limit the patent scope of the present invention accordingly. Any equivalent structure or equivalent process transformation made by using the content of the specification and drawings of the present invention, or directly or indirectly applied in other related technical fields, shall be equally included in the patent protection scope of the present invention.
Claims
1. A robot anti-falling method, applied to a robot, characterized in that The method includes: Collecting environmental point clouds of the external environment where the robot is located; In the environmental point clouds, determining the point clouds with a height less than or equal to a preset height in a preset robot coordinate system as fall point clouds; When detecting that the proportion of the number of point clouds of the fall point clouds in the number of point clouds of the environmental point clouds is greater than a first preset proportion, determining the area corresponding to the fall point clouds as a fall area; Performing path planning according to the fall area.
2. The robot anti-falling method according to claim 1, wherein After the step of determining the point clouds with a height less than or equal to a preset height in a preset robot coordinate system as fall point clouds in the environmental point clouds, it includes: When determining that the proportion of the fall point clouds in the environmental point clouds is greater than a second preset proportion and the number of point clouds of the fall point clouds is greater than a first point cloud number threshold, adjusting the maximum speed of the robot according to the number of point clouds of the fall point clouds, where the more the number of point clouds of the fall point clouds, the lower the adjusted maximum speed of the robot.
3. The robot anti-falling method according to claim 2, characterized in that, The step of adjusting the maximum speed of the robot according to the number of point clouds of the fall point clouds includes: When detecting that the number of point clouds of the fall point clouds exceeds a second point cloud number threshold, controlling the robot to stop running; When detecting that the number of point clouds of the fall point clouds does not exceed the second point cloud number threshold, determining the preset point cloud number range mapped by the number of point clouds of the fall point clouds, and reducing the maximum speed of the robot to the preset speed corresponding to the preset point cloud number range.
4. The robot anti-fall method according to claim 3, characterized in that, After the step of controlling the robot to stop running when detecting that the number of point clouds of the fall point clouds exceeds a second point cloud number threshold, it further includes: Detecting whether the number of point clouds of the fall point clouds in the environmental point clouds of a continuous preset number of frames all exceeds the second point cloud number threshold; If the number of point clouds of the fall point clouds in the environmental point clouds of a continuous preset number of frames does not all exceed the second point cloud number threshold, controlling the robot to resume running; If the number of point clouds of the fall point clouds in the environmental point clouds of a continuous preset number of frames all exceeds the second point cloud number threshold, warning of a fatal error and controlling the robot not to be recoverable.
5. The robot anti-falling method according to claim 1, wherein, The step of determining the area corresponding to the fall point clouds as a fall area includes: Detecting whether the area corresponding to the fall point clouds is a connected area; If the area corresponding to the fall point clouds is a connected area, determining the area corresponding to the fall point clouds as a fall area.
6. The robot anti-falling method according to claim 5, wherein, After the step of detecting whether the area corresponding to the fall point clouds is a connected area, it further includes: If the area corresponding to the fall point clouds is not a connected area, determining the sub-areas with an area greater than a preset area in each sub-area of the area corresponding to the fall point clouds as fall areas, and performing the step of performing path planning according to the fall area to avoid the fall areas.
7. The robot anti-falling method according to any one of claims 1 to 6, characterized in that, The step of collecting environmental point clouds of the external environment where the robot is located includes: Collecting an environmental depth image of the external environment where the robot is located through a depth camera of the robot; Converting the environmental depth image into point clouds through the camera internal parameters of the depth camera to obtain environmental point clouds.
8. A robot anti-falling device, the device being deployed on a robot, characterized in that, The device includes: A collection module, configured to collect environmental point clouds of the external environment where the robot is located; A determination module, configured to determine, from the environmental point clouds, the point clouds with heights less than or equal to a preset height in a preset robot coordinate system as fall point clouds; The determination module is further configured to, when detecting that the proportion of the number of point clouds of the fall point clouds in the number of point clouds of the environmental point clouds is greater than a first preset proportion, determine the area corresponding to the fall point clouds as a fall area; A path planning module, configured to perform path planning according to the fall area.
9. A robot, characterized in that, The robot includes: a memory, a processor, and a robot anti-fall program stored on the memory and executable on the processor. When the robot anti-fall program is executed by the processor, the steps of the robot anti-fall method according to any one of claims 1 to 7 are implemented.
10. A computer-readable storage medium, characterized in that, A robot anti-fall program is stored on the computer-readable storage medium. When the robot anti-fall program is executed by a processor, the steps of the robot anti-fall method according to any one of claims 1 to 7 are implemented.
Citation Information
Patent Citations
Method for detecting bridge from remote sense image
CN101159009A
Method and device for identifying falling area
CN110216661A