Motion control method and motion equipment
Through the fusion of image and sensor information, combined with neural networks, the sensor parameters are adjusted to solve the problem of insufficient sensory information and poor real-time performance in robot obstacle avoidance, and improve the accuracy of obstacle perception and real-time performance of obstacle avoidance.
Patent Information
- Application Number
- CN202310327794.1
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2023-03-24
- Publication Date
- 2024-09-27
- Estimated Expiration
- 2043-03-24
AI Technical Summary
Among existing robot obstacle avoidance technologies, obstacle perception based on two-dimensional lidar has problems such as insufficient information and poor real-time performance of obstacle avoidance decision-making and planning, resulting in robots often failing during the obstacle avoidance process.
By obtaining image and sensor information, the depth and distance information of obstacles is determined, and based on this information, the sensing range and frame rate of the sensor are adjusted, and obstacle avoidance planning is performed in combination with neural networks to improve the robot's perception accuracy of obstacles and real-time avoidance of obstacles.
It improves the robot's perception accuracy of obstacles and real-time obstacle avoidance, enhances its ability to avoid obstacles in dynamic scenes, reduces information redundancy and energy consumption, and improves the success rate of obstacle avoidance.
Smart Images

Figure CN118707939A
Abstract
Description
Technical Field
[0001] The present application relates to the technical field of robot obstacle avoidance, and more specifically, to a motion control method and motion equipment. Background Art
[0002] Obstacle avoidance technology refers to the technology that allows a robot to sense obstacles on its path and avoid them in time to continue moving toward its destination. In current obstacle avoidance technology, obstacle avoidance planning is usually based on obstacles sensed by a two-dimensional laser radar. Since two-dimensional laser radar can only sense obstacles at a certain height, there is insufficient perception information in the obstacle avoidance planning process and the real-time performance of obstacle avoidance decision-making and planning is poor, which often leads to obstacle avoidance failures in the robot's obstacle avoidance process.
[0003] In view of this, a motion control solution that can improve the obstacle perception accuracy and obstacle avoidance real-time needs to be developed urgently. Summary of the invention
[0004] The present application provides a motion control method and a motion device, which can improve the perception accuracy of the motion device to obstacles and the real-time obstacle avoidance of the motion device.
[0005] The sports equipment involved in this application may include road vehicles, water vehicles, air vehicles, industrial equipment, agricultural equipment, or entertainment equipment, etc. For example, the sports equipment may include unmanned vehicles, which are vehicles in a broad sense, and may be vehicles (such as commercial vehicles, passenger cars, motorcycles, flying cars, trains, etc.), industrial vehicles (such as forklifts, trailers, tractors, etc.), engineering vehicles (such as excavators, bulldozers, cranes, etc.), agricultural equipment (such as mowers, harvesters, etc.), amusement equipment, toy vehicles, etc. The embodiments of this application do not specifically limit the types of vehicles. Alternatively, the sports equipment may also include smart homes, such as sweeping robots and other equipment.
[0006] In a first aspect, a motion control method is provided, the method comprising: acquiring an image of a first area, the image indicating position information of a first obstacle in the first area, the first area being an area where a destination of a motion device is located; acquiring sensor information, the sensor information indicating first depth information between a second obstacle and the motion device, the second obstacle being an obstacle located at a first preset height in the first area; determining first distance information of the first obstacle based on the image and the first depth information, the first obstacle being an obstacle located between the first preset height and a second preset height in the first area, the first distance information indicating a lateral distance between the first obstacle and the second obstacle in the image, and a depth distance between the first obstacle and the motion device; and controlling the motion device to avoid obstacles based on the first distance information during the motion device moving toward the destination.
[0007] In the above technical solution, more abundant obstacle information can be obtained based on sensor information and images, thereby improving the perception accuracy of the sports device to obstacles; based on the abundant obstacle information, the distance information of the obstacle between the first preset height and the second preset height is determined, and the core information (such as the first distance information) that is helpful for the sports device to perform obstacle avoidance planning is extracted, so that the sports device can perform obstacle avoidance planning based on the core information, which helps to reduce the amount of data that needs to be preprocessed during the obstacle avoidance planning process of the sports device, thereby improving the real-time obstacle avoidance of the sports device. In particular, for dynamic scenes with large obstacle changes, the above method helps the sports device to quickly and accurately plan the obstacle avoidance path.
[0008] Exemplarily, the image may be a red green blue (RGB) image, a grayscale image, or the like.
[0009] In some possible implementations, the sensor information is obtained by a detection sensor, which may include a detection sensor such as a laser radar, a photoelectric sensor, etc. Further, the first preset height may be a sensing height of the detection sensor, which may be less than or equal to the height of the motion device, or may be greater than the height of the motion device, and this embodiment of the application does not specifically limit this.
[0010] In one example, the motion device is a device that moves on a plane (such as a sweeping robot), and the second preset height may be lower than the height of the motion device, for example, may be the height of the plane.
[0011] In another example, the sports device is a flying device (such as a drone), and the second preset height can be a height higher than the sports device, for example, it can be 2 meters higher or 3 meters higher than the sports device; or it can be a height lower than the sports device, for example, it can be 2 meters lower or 3 meters lower than the sports device; the embodiment of the present application does not specifically limit this.
[0012] Exemplarily, the first area may include an area perceived by a viewing angle of an image sensor, which is used to acquire the above-mentioned image.
[0013] Exemplarily, the position of the first obstacle in the first area may be determined according to two-dimensional coordinate parameters of the first obstacle on the image and an intrinsic parameter matrix of the image sensor.
[0014] It should be noted that the destination of the above-mentioned motion device may include the final target position of the motion device, or may also include the position along the way when the motion device moves to the final target position.
[0015] In some possible implementations, the lateral distance between the first obstacle and the second obstacle, and the depth distance between the first obstacle and the motion device, can be used to determine the position of the first obstacle in the coordinate system O-XYZ of the motion device. Exemplarily, the origin of the coordinate system O-XYZ of the motion device can be the center point of the motion device, and O-XYZ includes an X-axis, a Y-axis, and a Z-axis, wherein the Z-axis can be parallel to the front direction of the motion device, the Y-axis is parallel to the height direction of the motion device, and the X-axis can be perpendicular to the Y-axis and the Z-axis, respectively. Furthermore, the X coordinate of the first obstacle in the O-XZ coordinate system can be determined based on the lateral distance between the first obstacle and the second obstacle; and the Z coordinate of the first obstacle in the O-XZ coordinate system can be determined based on the depth distance between the first obstacle and the motion device.
[0016] In combination with the first aspect, in certain implementations of the first aspect, the first distance information of the first obstacle is determined based on the image and the first depth information, including: determining the lateral distance between the first obstacle and the second obstacle based on the pixel distance of the pixels in the image; and determining the depth distance between the first obstacle and the motion device based on the grayscale value of the pixels in the image.
[0017] In combination with the first aspect, in certain implementations of the first aspect, determining the depth distance between the first obstacle and the motion device based on the grayscale value of the pixel in the image includes: determining the depth distance corresponding to the grayscale value of the first pixel in the image based on the first depth information, the first pixel being the pixel in the image corresponding to the graphic of the second obstacle; determining the depth distance between the first obstacle and the motion device based on the grayscale value of the second pixel in the image, at least one of the grayscale gradient value between the second pixel and the first pixel, and the depth distance corresponding to the grayscale value of the first pixel, the second pixel being the pixel in the image corresponding to the graphic of the first obstacle.
[0018] Exemplarily, the first depth information and the image may be input into a convolutional neural network to obtain a depth estimation map, where the depth estimation map indicates a depth distance corresponding to each pixel in the image.
[0019] It is understandable that estimating the depth distance between the first obstacle and the motion device based only on the image may have a large error. Estimating the depth distance between the second obstacle and the motion device based on the first depth information combined with the image can greatly improve the accuracy of depth estimation.
[0020] In combination with the first aspect, in certain implementations of the first aspect, the method further includes: detecting the second obstacle by means of a detection sensor of the motion device, and acquiring the sensor information based on data collected by the detection sensor, wherein the perception range of the detection sensor is adjustable.
[0021] In combination with the first aspect, in some implementations of the first aspect, the method further includes: dynamically adjusting the sensing range of the detection sensor according to the depth distance indicated by the first distance information.
[0022] Exemplarily, the sensing range of the detection sensor may be adjusted according to a comparison result between the first depth information and the first distance information.
[0023] It should be noted that both the first depth information and the first distance information include obstacle distance information in two dimensions. When the matching degree between the first distance information and the first depth information is less than or equal to a preset threshold, it indicates that the sensing range of the detection sensor is not appropriate, and therefore needs to be adjusted.
[0024] In the above technical solution, by adjusting the sensing range of the sensor in real time, the adaptive ability of the sports equipment to the environment can be improved, thereby improving the intelligence of the sports equipment.
[0025] In some possible implementations, the motion device adjusts the perception range of the detection sensor according to a comparison result between the first distance information and the first depth information, including: when the depth indicated by the first distance information is less than the depth indicated by the first depth information, the motion device reduces the perception range of the detection sensor; or, when the depth indicated by the first distance information is greater than the depth indicated by the first depth information, the motion device increases the perception range of the detection sensor.
[0026] In the above technical solution, when the depth indicated by the first distance information is smaller than the depth indicated by the first depth information, it means that the obstacle perceived by the detection sensor is farther away, so the perception range of the detection sensor can be reduced; when the depth indicated by the first depth information is smaller than the depth indicated by the first distance information, it means that the obstacle perceived by the detection sensor is closer, which means that the data obtained by the detection sensor is very important and the perception range of the detection sensor needs to be increased as much as possible.
[0027] In combination with the first aspect, in certain implementations of the first aspect, the sensor information further indicates the density of the second obstacle, and the method further includes: dynamically adjusting the perception frame rate of the detection sensor according to the density of the second obstacle.
[0028] In the above technical solution, by adjusting the perception frame rate of the sensor in real time, the adaptability of the sports equipment to the environment can be improved, thereby improving the intelligence of the sports equipment.
[0029] In some possible implementations, the perception frame rate of the detection sensor is adjusted according to the density of the first obstacle, including: when the density of the first obstacle is large, increasing the perception frame rate of the detection sensor; or, when the density of the first obstacle is small, decreasing the perception frame rate of the detection sensor.
[0030] In some possible implementations, the obstacle density is associated with the scene texture, and the smaller the obstacle density, the lower the scene texture. In low-texture scenes, there is no need to use a lower perceived frame rate.
[0031] In the above technical solution, increasing the perception frame rate in scenes with rich obstacles can improve the perception accuracy of the motion device; reducing the perception frame rate in scenes with low texture can reduce the power consumption of the detection sensor and avoid power waste.
[0032] In combination with the first aspect, in certain implementations of the first aspect, the image indicates position information of a third obstacle in the first area, and the method further includes: determining the obstacle that is closer to the motion device among the second obstacle and the third obstacle located in the first plane as the first obstacle, wherein the first plane is a plane parallel to the height direction and the depth direction of the motion device.
[0033] Exemplarily, the third obstacle may be all obstacles contained in the image.
[0034] In some possible implementations, a depth estimation map is determined based on the image, where the depth estimation map indicates a depth distance corresponding to each pixel in the image. Further, a first obstacle is determined based on the depth estimation map.
[0035] For example, the pixel coordinates in the x direction of the depth estimation image are from x1 to x r , the pixel coordinates in the y direction are from y1 to y t , z1~z t×r is the value of each pixel in the depth estimation map. Where r and t are integers greater than 1. The pixel coordinates in the x direction can be used to determine the lateral distance between the obstacle and the motion device, and the pixel coordinates in the y direction can be used to determine the height of the obstacle.
[0036] In some possible implementations, x is determined i Corresponding y1 to y hi The obstacle indicated by the minimum value point among the pixels is the first obstacle, and the minimum value is the depth distance between the first obstacle and the motion device. Wherein, i is any value from 1 to r.
[0037] In the depth estimation diagram, x = x i The indicated plane may be understood as an example of a first plane.
[0038] In some possible implementations, the first preset height and the second preset height may be determined based on the depth estimation map. It is understandable that the first preset height and the second preset height may be respectively represented as a curve in the depth estimation map, then y yi For x i The corresponding pixel coordinates at the first preset height in the y direction, y hi For x i The pixel coordinates at the second preset height in the corresponding y direction.
[0039] Further, the first distance information may be determined according to the depth estimation map, the first preset height and the second preset height, including: determining x i The corresponding y yi to y hi The minimum value among the pixels is x i The corresponding minimum depth distance, x1 to x r The corresponding minimum depth distance constitutes the first distance information.
[0040] In the above technical solution, the depth estimation map containing obstacle distance information in three dimensions is compressed into the first distance information including only two dimensions (x direction and z direction), retaining the information valuable for obstacle avoidance planning, which helps to reduce the amount of data that needs to be preprocessed during the obstacle avoidance planning of the motion device, thereby improving the real-time obstacle avoidance of the motion device.
[0041] In combination with the first aspect, in certain implementations of the first aspect, the method also includes: obtaining current motion parameters of the motion device; and controlling the motion device to avoid obstacles based on the first distance information, including: inputting the current motion parameters and the first distance information into a first neural network to obtain current environmental perception information; inputting the current environmental perception information and the destination into a second neural network to obtain a target angular velocity and a target linear velocity; and controlling the motion device to avoid obstacles based on the target angular velocity and the target linear velocity.
[0042] Exemplarily, the current motion parameters may include, but are not limited to: linear velocity, angular velocity, current position coordinates, and posture angle (or heading angle) of the motion device.
[0043] Exemplarily, the first neural network may include a convolutional neural network based on an attention mechanism; and the second neural network may include a recurrent neural network.
[0044] In some possible implementations, the second neural network also includes fully connected layers (FC), and the motion device inputs the current environment perception information and the destination into the second neural network to obtain the target angular velocity and the target linear velocity, including: the motion device inputs the current environment perception information and the historical environment perception information into the recurrent neural network to obtain the environment perception information; the motion device inputs the environment perception information and the destination into the FC layer to obtain the target angular velocity and the target linear velocity.
[0045] In the above technical solution, the current environmental perception information is obtained through a convolutional neural network based on the attention mechanism, which conforms to the different characteristics of people's attention to the field of vision in different motion states, reduces the redundancy of information and the synthesis of invalid information after multi-sensor information fusion; through the recurrent neural network layer, environmental perception information with a historical field of vision is obtained. In the FC layer, current information and historical information (such as environmental perception information) and future information (such as destination) are used as perception inputs, which helps to further improve the accuracy of obstacle avoidance.
[0046] In combination with the first aspect, in certain implementations of the first aspect, controlling the motion device to avoid obstacles based on the first distance information includes: determining a fused depth distance based on the first distance information and the first depth information; and controlling the motion device to avoid obstacles based on the fused depth distance and the destination.
[0047] In some possible implementations, the process of processing sensor information and images may introduce errors, resulting in the depth of obstacles in certain areas indicated by the first distance information being greater than the depth indicated by the first depth information. In the above technical solution, by fusing the first depth information and the first distance information, the perception accuracy can be further improved, which helps to improve the real-time performance and success rate of obstacle avoidance.
[0048] In a second aspect, a motion device is provided, an image sensor, used to: obtain an image of a first area, the image indicating position information of a first obstacle in the first area, the first area being the area where the destination of the motion device is located; a detection sensor, used to: detect a second obstacle located at a first preset height in the first area to obtain sensor information, the sensor information indicating first depth information between the second obstacle and the motion device, the second obstacle being an obstacle located at the first preset height in the first area; a processor, used to: determine first distance information of the first obstacle based on the image and the first depth information, the first obstacle being an obstacle located between the first preset height and the second preset height in the first area, the first distance information indicating a lateral distance between the first obstacle and the second obstacle in the image, and a depth distance between the first obstacle and the motion device; the processor is also used to control the motion device to avoid obstacles based on the first distance information during the motion device moving toward the destination.
[0049] In combination with the second aspect, in certain implementations of the second aspect, the processor is used to: determine the lateral distance between the first obstacle and the second obstacle based on the pixel distance of the pixel points in the image; determine the depth distance between the first obstacle and the motion device based on the grayscale value of the pixel points in the image.
[0050] In combination with the second aspect, in certain implementations of the second aspect, the position of the second obstacle in the first area includes the height of the second obstacle, and the processor is also used to: determine the depth distance corresponding to the grayscale value of a first pixel in the image based on the first depth information, where the first pixel is a pixel in the image corresponding to the graphic of the second obstacle; determine the depth distance between the first obstacle and the motion device based on the grayscale value of the second pixel in the image, at least one of the grayscale gradient value between the second pixel and the first pixel, and the depth distance corresponding to the grayscale value of the first pixel, where the second pixel is a pixel in the image corresponding to the graphic of the first obstacle.
[0051] In combination with the second aspect, in some implementations of the second aspect, the sensing range of the detection sensor is adjustable.
[0052] In combination with the second aspect, in certain implementations of the second aspect, the processor is used to: dynamically adjust the perception range of the detection sensor according to the depth distance indicated by the first distance information.
[0053] In combination with the second aspect, in certain implementations of the second aspect, the sensor information further indicates the density of the second obstacle, and the processor is further used to: adjust the perception frame rate of the detection sensor according to the density of the first obstacle.
[0054] In combination with the second aspect, in certain implementations of the second aspect, the image indicates position information of the third obstacle in the first area, and the processor is also used to: determine the obstacle that is closer to the motion device among the second obstacle and the third obstacle located in the first plane as the first obstacle, wherein the first plane is a plane parallel to the height direction and the depth direction of the motion device.
[0055] In combination with the second aspect, in certain implementations of the second aspect, the processor is used to: obtain current motion parameters of the motion device; input the current motion parameters and the first distance information into a first neural network to obtain current environmental perception information; input the current environmental perception information and the destination into a second neural network to obtain a target angular velocity and a target linear velocity; and control the motion device to avoid obstacles based on the target angular velocity and the target linear velocity.
[0056] In combination with the second aspect, in certain implementations of the second aspect, the processor is used to: determine a fused depth distance based on the first distance information and the first depth information; and control the motion device to avoid obstacles based on the fused depth distance and the destination.
[0057] In a third aspect, an integrated circuit is provided, comprising: a memory for storing a computer program; and a processor for executing the computer program stored in the memory, so that the device performs a method as in any possible implementation of the first aspect.
[0058] In a fourth aspect, a computer program product is provided, the computer program product comprising: a computer program code, when the computer program code is run on a computer, the computer executes the method in any possible implementation of the first aspect.
[0059] It should be noted that the above-mentioned computer program code may be stored in whole or in part on a first storage medium, wherein the first storage medium may be packaged together with the processor or may be packaged separately from the processor.
[0060] In a fifth aspect, a computer-readable medium is provided, wherein the computer-readable medium stores instructions, and when the instructions are executed by a processor, the processor implements the method in any possible implementation manner of the first aspect. BRIEF DESCRIPTION OF THE DRAWINGS
[0061] Figure 1 is a functional schematic block diagram of a sports device provided in an embodiment of the present application;
[0062] Figure 2 is a schematic diagram of the system architecture required for implementing the motion control method provided in the embodiment of the present application;
[0063] Figure 3 is a schematic flow chart of a motion control method provided in an embodiment of the present application;
[0064] Figure 4 is a schematic diagram of a neural network model provided in an embodiment of the present application;
[0065] Figure 5 is another schematic diagram of the neural network model provided in the embodiment of the present application;
[0066] Figure 6 is a schematic diagram of a depth estimation map and minimum depth information provided by an embodiment of the present application;
[0067] Figure 7 is another schematic diagram of the neural network model provided in the embodiment of the present application;
[0068] Figure 8 is a schematic diagram of a comparison result of first depth information and minimum depth information provided by an embodiment of the present application;
[0069] Fig. 9 is a schematic diagram of the overall process of the motion control method provided in an embodiment of the present application;
[0070] Fig.10 is another schematic flow chart of the motion control method provided in the embodiment of the present application;
[0071] Fig.11 is a schematic block diagram of a motion control device provided in an embodiment of the present application;
[0072] Fig.12 It is a schematic block diagram of a motion control device provided in an embodiment of the present application. DETAILED DESCRIPTION
[0073] In the description of the embodiments of the present application, unless otherwise specified, " / " means or, for example, A / B can mean A or B; "and / or" in this article is a kind of association relationship that describes associated objects, indicating that three relationships can exist, for example, A and / or B can mean: A exists alone, A and B exist at the same time, and B exists alone. In this application, "at least one" means one or more, and "multiple" means two or more. "At least one of the following items" or similar expressions refers to any combination of these items, including any combination of single items or plural items. For example, at least one of a, b, or c can mean: a, b, c, ab, ac, bc, or abc, where a, b, c can be single or multiple.
[0074] The prefixes such as "first" and "second" used in the embodiments of the present application are only used to distinguish different description objects, and have no limiting effect on the position, order, priority, quantity or content of the described objects. The use of prefixes such as ordinal numbers used to distinguish description objects in the embodiments of the present application does not constitute a limitation on the described objects. For the statement of the described objects, please refer to the description in the context of the claims or embodiments, and the use of such prefixes should not constitute an unnecessary limitation.
[0075] Since the embodiments of the present application involve the application of neural networks, for ease of understanding, the relevant terms and concepts of neural networks that may be involved in the embodiments of the present application are first introduced below.
[0076] (1) Neural Network
[0077] A neural network can be composed of neural units. A neural unit can be a s The output of the operation unit can be:
[0078]
[0079] Where, s = 1, 2, ... n, n is a natural number greater than 1, W s For x s, b is the bias of the neural unit. f is the activation function of the neural unit, which is used to introduce nonlinear characteristics into the neural network to convert the input signal in the neural unit into the output signal. The output signal of the activation function can be used as the input of the next convolutional layer, and the activation function can be a sigmoid function. A neural network is a network formed by connecting multiple single neural units mentioned above, that is, the output of one neural unit can be the input of another neural unit. The input of each neural unit can be connected to the local receptive field of the previous layer to extract the features of the local receptive field. The local receptive field can be an area composed of several neural units.
[0080] (2) Deep Neural Networks
[0081] A deep neural network (DNN), also known as a multi-layer neural network, can be understood as a neural network with multiple hidden layers. According to the position of different layers, the neural network inside the DNN can be divided into three categories: input layer, hidden layer, and output layer. Generally speaking, the first layer is the input layer, the last layer is the output layer, and the layers in between are all hidden layers. The layers are fully connected, that is, any neuron in the i-th layer must be connected to any neuron in the i+1-th layer.
[0082] Although DNN looks complicated, the work of each layer is not complicated. In simple terms, it can be expressed as the following linear relationship: in, is the input vector, is the output vector, is the offset vector, W is the weight matrix (also called coefficient), and α() is the activation function. Each layer is just an input vector After such a simple operation, the output vector Since DNN has many layers, the coefficient W and the offset vector The number of these parameters is also relatively large. The definitions of these parameters in DNN are as follows: Take the coefficient W as an example: Assume that in a three-layer DNN, the linear coefficient from the 4th neuron in the second layer to the 2nd neuron in the third layer is defined as The superscript 3 represents the layer number of the coefficient W, while the subscripts correspond to the third layer index 2 of the output and the second layer index 4 of the input.
[0083] In summary, the coefficients from the kth neuron in the L-1th layer to the jth neuron in the Lth layer are defined as
[0084] It should be noted that the input layer does not have a W parameter. In a deep neural network, more hidden layers allow the network to better describe complex situations in the real world. Theoretically, the more parameters a model has, the higher its complexity and the greater its "capacity", which means it can complete more complex learning tasks. Training a deep neural network is the process of learning the weight matrix, and its ultimate goal is to obtain the weight matrix of all layers of the trained deep neural network (the weight matrix formed by many layers of vector W).
[0085] (3) Convolutional Neural Network
[0086] Convolutional neural network (CNN) is a deep neural network with a convolutional structure. Convolutional neural network contains a feature extractor consisting of a convolution layer and a subsampling layer, which can be regarded as a filter. Convolutional layer refers to the neuron layer in the convolutional neural network that performs convolution processing on the input signal. In the convolutional layer of the convolutional neural network, a neuron can only be connected to some neurons in the adjacent layers. A convolutional layer usually contains several feature planes, each of which can be composed of some rectangularly arranged neural units. The neural units in the same feature plane share weights, and the shared weights here are convolution kernels. Shared weights can be understood as the way to extract image information is independent of position. The convolution kernel can be initialized in the form of a matrix of random size, and the convolution kernel can obtain reasonable weights through learning during the training process of the convolutional neural network. In addition, the direct benefit of shared weights is to reduce the connection between the layers of the convolutional neural network, while reducing the risk of overfitting.
[0087] (4) Recurrent neural networks (RNN) are used to process sequence data. In traditional neural network models, the layers are fully connected from the input layer to the hidden layer and then to the output layer, while the nodes within each layer are disconnected. Although this common neural network has solved many difficult problems, it is still powerless to solve many problems. For example, to predict the next word in a sentence, the previous word is generally needed because the previous and next words in a sentence are not independent. RNN is called a recurrent neural network because the current output of a sequence is also related to the previous output. The specific manifestation is that the network will remember the previous information and apply it to the calculation of the current output, that is, the nodes between the hidden layers are no longer disconnected but connected, and the input of the hidden layer includes not only the output of the input layer but also the output of the hidden layer at the previous moment. In theory, RNN can process sequence data of any length. The training of RNN is the same as the training of traditional CNN or DNN.
[0088] RNN aims to enable machines to have memory capabilities like humans. Therefore, the output of RNN needs to depend on current input information and historical memory information.
[0089] The above is an introduction to the terms related to neural networks. The following will describe the technical solutions in the embodiments of the present application in conjunction with the accompanying drawings.
[0090] As mentioned above, the current obstacle avoidance algorithm has the problems of insufficient perception information and poor real-time performance of obstacle avoidance decision-making and planning, which leads to frequent obstacle avoidance failures in the robot's obstacle avoidance process. Specifically, in the field of robot obstacle avoidance technology, the current problems mainly include the following two points:
[0091] First, there is a contradiction between perception accuracy and model reasoning real-time performance: the perception and obstacle avoidance accuracy based on two-dimensional (2D) radar is limited. For example, a 2D radar can only perceive obstacles at the radar height. When the obstacle is higher or lower than the radar height, the obstacle cannot be perceived, and obstacle avoidance may fail, causing the robot to collide with the obstacle and bring danger. However, crude multi-sensor fusion will only increase the computational difficulty of the obstacle avoidance decision model, thereby reducing the real-time performance of the model reasoning.
[0092] Second, the fixed sensing range and frame rate of the radar lead to information redundancy: Improving the radar sensing range and frame rate will improve the robot's perception accuracy, but it will also lead to problems such as longer information fusion and information collection time. At present, when the radar scans, it still scans at a preset fixed sensing range and frame rate, and cannot be adaptively adjusted. In scenes with many obstacles, when scanning at a fixed sensing frame rate, the sensing frame rate is low, which may result in the inability to obtain effective information about all obstacles; in scenes with few obstacles, when scanning at a fixed sensing frame rate, the sensing frame rate is too high, which may cause waste of sensor power consumption.
[0093] It should be noted that the radar's perception frame rate (or scanning speed) represents the number of revolutions of the radar motor in one second, that is, the number of times a scan is completed per second. Since the radar's sampling rate is fixed, the higher the frame rate, the smaller the angular resolution and the more detailed the object details; the lower the frame rate, the greater the angular resolution. The radar's perception range can be the radar's scanning range, such as the scanning angle.
[0094] In view of this, an embodiment of the present application provides a motion control method, which can fuse and compress 2D radar information and image information to obtain the depth distance between obstacles and motion equipment within a preset height range; and then control the movement of the motion equipment according to the depth distance to achieve the purpose of obstacle avoidance. In addition, an embodiment of the present application also provides a motion control method, which can adjust the perception range of the 2D radar according to the comparison result between the above-mentioned depth distance and the 2D radar information; and adjust the perception frame rate of the 2D radar according to the 2D radar information. Thereby improving the adaptive ability of the motion equipment to the environment, reducing information redundancy, and improving the real-time performance of obstacle avoidance planning.
[0095] Figure 1 A functional block diagram of a sports device 100 provided in an embodiment of the present application is shown. The sports device 100 may include a perception system 120 and a computing platform 150, wherein the perception system 120 may include one or more sensors for sensing information about the environment around the sports device 100. For example, the perception system 120 may include a detection sensor and an image sensor, wherein the detection sensor may include a 2D radar (such as a lidar), a photoelectric sensor, an ultrasonic sensor, and other detection sensors; the image sensor may include an RGB camera, a red green blue-depth (RGB-D) camera, a time of flight (TOF) camera, and other sensors whose images can be used to determine depth information (such as RGB images, grayscale images).
[0096] Some or all functions of the sports device 100 can be controlled by the computing platform 150. The computing platform 150 may include one or more processors, such as processors 151 to 15n (n is a positive integer). The processor is a circuit with the ability to process instructions. In one implementation, the processor may be a circuit with the ability to read and run instructions, such as a central processing unit (CPU), a microprocessor, a graphics processing unit (GPU) (which can be understood as a microprocessor), or a digital signal processor (DSP); in another implementation, the processor can implement certain functions through the logical relationship of the hardware circuit, and the logical relationship of the hardware circuit is fixed or reconfigurable, such as a hardware circuit implemented by a processor as an application-specific integrated circuit (ASIC) or a programmable logic device (PLD), such as a field programmable gate array (FPGA). In a reconfigurable hardware circuit, the process of the processor loading a configuration document to implement the hardware circuit configuration can be understood as the process of the processor loading instructions to implement the functions of some or all of the above units. In addition, it can also be a hardware circuit designed for artificial intelligence, which can be understood as an ASIC, such as a neural network processing unit (NPU), a tensor processing unit (TPU), a deep learning processing unit (DPU), etc. In addition, the computing platform 150 can also include a memory, the memory is used to store instructions, and some or all of the processors 151 to 15n can call the instructions in the memory and execute the instructions to achieve corresponding functions.
[0097] In the embodiment of the present application, the computing platform 150 can control the obstacle avoidance driving of the motion device according to the data collected by the detection sensor and the image sensor. In some possible implementations, the data collected by the detection sensor and the image sensor can also be stored in a memory in the computing platform 150.
[0098] Figure 2 FIG. 1 is a schematic diagram showing the system architecture provided by an embodiment of the present application. Figure 2As shown, the system includes a perception module 201, a feature extraction module 202, an information fusion module 203, a sparse depth estimation module 204, a greedy depth compression module 205, a quality assessment module 206, a behavior attention module 207 and a temporal reinforcement learning module 208. The perception module 201 may include Figure 1 One or more sensors in the perception system 120 shown in the figure, which sensors may include, for example, detection sensors and image sensors; feature extraction module 202, information fusion module 203, sparse depth estimation module 204, greedy depth compression module 205, quality assessment module 206, behavior attention module 207 and temporal reinforcement learning module 208 may include Figure 1 One or more processors in the computing platform 150 shown in .
[0099] Specifically, the feature extraction module 202 extracts the features of the sensor information collected by the detection sensor in the perception module 201 and the features of the image collected by the image sensor to form a high-dimensional representation tensor (or multi-dimensional array).
[0100] In some possible implementations, the image indicates the position of obstacle 1 in the area sensed by the image sensor, and the sensor information indicates first depth information between obstacle 2 at a first preset height in the area sensed by the image sensor and the motion device.
[0101] The feature extraction module 202 inputs the high-dimensional representation tensor into the information fusion module 203 for feature fusion to obtain a feature fusion matrix; the information fusion module 203 inputs the feature fusion matrix into the sparse depth estimation module 204 to obtain a depth estimation map.
[0102] It can be understood that the depth estimation map indicates the depth distance between the obstacle 1 included in the image and the motion device, and the depth estimation map is represented by pixel coordinates in the x direction and the y direction, wherein the y direction represents the height direction, and the x direction is perpendicular to the height direction and the depth direction (hereinafter referred to as the z direction) respectively. That is, the depth estimation map includes distance information in three dimensions: the x direction, the y direction, and the z direction.
[0103] The sparse depth estimation module 204 inputs the depth estimation map into the greedy depth compression module 205 to obtain minimum depth information, which indicates the depth distance between the first obstacle and the moving device, and the first obstacle includes the obstacle closest to the moving device in the unit length along the x direction among all obstacles whose heights are between the first preset height and the second preset height. In other words, the minimum depth information includes distance information in two dimensions, the x direction and the z direction.
[0104] Further, the greedy depth compression module 205 inputs the minimum depth information into the quality assessment module 206 and the behavior attention module 207 respectively.
[0105] Among them, the quality assessment module 206 obtains optimization information based on the minimum depth information and sensor information, and the optimization information can be used to adjust the perception range of the detection sensor; the behavioral attention module 207 obtains the current environment perception information based on the current motion parameters of the motion device (such as angular velocity, linear velocity and mileage, etc.) and the minimum depth information.
[0106] The behavior attention module 207 inputs the current environment perception information and the target position of the motion device into the time series reinforcement learning module 208 to obtain the target motion parameters (such as linear velocity and angular velocity) of the motion device, so that the motion device can travel based on the target motion parameters, thereby achieving the purpose of obstacle avoidance.
[0107] It should be understood that the above modules and devices are only examples. In actual applications, the above modules and devices may be added or deleted according to actual needs. In one example, the information fusion module 203 and the sparse depth estimation module 204 can be combined into one module, that is, the functions of the two are implemented by one module. In another example, the system may not include the quality assessment module 206.
[0108] Figure 3 Schematic flow chart of the control method provided by the embodiment of the present application is shown. The method 300 can be applied to Figure 1 The exercise device shown, or the method can be performed by Figure 2 The system shown is executed. Figure 3 The steps or operations of the control method shown are only examples, and the embodiments of the present application may also perform other operations or Figure 3 The various operations in the variant, and may not be performed Figure 3 For example, the method 300 is described below by taking the method being executed by a computing platform of a sports device as an example. The method 300 may include:
[0109] S301, input the image and sensor information into the feature extraction layer to obtain first feature information and second feature information respectively.
[0110] Exemplarily, the image may be acquired by an image sensor, and the sensor information may be acquired by a detection sensor. The image sensor and the detection sensor may be sensors in the perception system or the perception module in the above-mentioned embodiment.
[0111] It should be noted that the image indicates the position of obstacle 1 in the area sensed by the image sensor, and the sensor information indicates the first depth information between obstacle 2 at a first preset height in the area sensed by the image sensor and the motion device. The first preset height may include the first preset height in the above-mentioned embodiment, specifically, the first preset height may be the sensing height of the detection sensor, the first preset height may be less than or equal to the height of the motion device, or may be greater than the height of the motion device, and the embodiment of the present application does not specifically limit this.
[0112] Exemplarily, the first feature information and the second feature information may be high-dimensional embedded feature information, for example, may include the multi-dimensional array in the above embodiment.
[0113] Exemplarily, the first feature information may include reference depth information, which includes the depth distance between the obstacle 2 at the first preset height in the area sensed by the image sensor and the motion device. The second feature information may include the pixel value of the pixel point; or the second feature information may also include the three-dimensional coordinate parameters of the obstacle 1; or the second feature information may also include texture information, color information, etc.
[0114] In some possible implementations, taking the case where the sensor information includes data collected by a 2D laser radar as an example, the data collected by the 2D laser radar may be a sparse depth map, which includes a logic code and a depth value, wherein the depth value indicates the distance between the detected object (such as an obstacle) and the motion device, and the depth value between adjacent laser points is unknown, and the logic code is used to indicate whether there is a valid depth value in the unknown depth value area. In an embodiment of the present application, the feature extraction layer is used to extract the depth value in the sparse depth map to obtain reference depth information.
[0115] Exemplarily, the three-dimensional coordinate parameters of obstacle 1 include the x-coordinate, y-coordinate and z-coordinate of obstacle 1 in the coordinate system of the image sensor. The coordinate system of the image sensor refers to a three-dimensional rectangular coordinate system with the focusing center of the image sensor as the origin and the optical axis as the z-axis.
[0116] In some possible implementations, the three-dimensional coordinate parameters of the obstacle 1 may be determined according to the two-dimensional coordinate parameters of the obstacle 1 on the image and the intrinsic parameter matrix of the image sensor.
[0117] Specifically, the relationship between the three-dimensional coordinate parameters and the two-dimensional coordinate parameters is as shown in the following formula:
[0118]
[0119] in, is the intrinsic parameter matrix of the image sensor; x represents the horizontal coordinate of obstacle 1 in the coordinate system of the image sensor, y represents the vertical coordinate of obstacle 1 in the coordinate system of the image sensor, and z represents the depth coordinate of obstacle 1 in the coordinate system of the image sensor; u represents the horizontal coordinate of the pixel of obstacle 1 in the pixel coordinate system, and v represents the height coordinate of the pixel of obstacle 1 in the pixel coordinate system; f represents the focal length of the image sensor. fx represents the parameter of the focal length of the image sensor after scaling on the u axis in the pixel coordinate system, fy represents the parameter of the focal length of the image sensor after scaling on the v axis in the pixel coordinate system, cx represents the translation of the origin of the coordinate system of the image sensor on the u axis, and cy represents the translation of the origin of the coordinate system of the image sensor on the v axis.
[0120] In some possible implementations, the feature extraction layer may extract the second feature information based on the above formula.
[0121] The feature extraction layer can be understood as an example of the feature extraction module 202. The feature extraction layer can be a pre-trained convolutional neural network, such as VGG16, VGG19, ResNet50, etc.
[0122] S302, input the first feature information and the second feature information into a channel fusion layer to obtain feature fusion information.
[0123] The channel fusion layer can be understood as an example of the above-mentioned information fusion module 203.
[0124] For example, the schematic diagram of the channel fusion layer is as follows Figure 4 As shown, it includes a convolution layer, a global pooling layer and an activation function layer. Specifically, the output of the first feature information after passing through the convolution layer, the global pooling layer and the activation function layer is cross-multiplied element by element with the output of the second feature information after passing through the convolution layer, the global pooling layer and the activation function layer, and then the information obtained by the respective cross-products is combined at the channel level and output to obtain feature fusion information.
[0125] S303, inputting the feature fusion information into a sparse depth estimation module to obtain a depth estimation map.
[0126] Exemplarily, the sparse depth estimation module may include the sparse depth estimation module 204 in the above embodiment. The sparse depth estimation module may include a hole convolution layer and a jump upsampling layer. The schematic diagram of the jump upsampling layer is shown in FIG. Figure 5 As shown in FIG. 1 , the skip information is skip connection information, which may include part or all of the feature fusion information. The feature fusion information is input into the sparse depth estimation module, and the following can be obtained: Figure 6 Depth estimation diagram shown in (a) in .
[0127] S304, input the depth estimation image into a greedy depth compression module to obtain minimum depth information.
[0128] Exemplarily, the greedy deep compression module may include the greedy deep compression module 205 in the above embodiment.
[0129] For example, Figure 6 The pixel coordinates in the x direction of the depth estimation image shown in (a) are from x1 to x r , the pixel coordinates in the y direction are from y1 to y t , z1~z t×r is the value of each pixel in the depth estimation image, where r and t are integers greater than 1.
[0130] In some possible implementations, the greedy depth compression module compresses the depth estimation map according to the first preset height and the second preset height to obtain the minimum depth information, wherein the second preset height may be lower than the height of the sports device, or may be higher than the first preset height.
[0131] In one example, the greedy depth compression module only retains the portion between a first preset height and a second preset height in the depth estimation image, and determines the minimum depth information according to the value of each pixel in the portion between the first preset height and the second preset height.
[0132] In another example, the minimum depth information is as follows: Figure 6 As shown in (b) in the figure, the greedy depth compression module can compress the depth estimation map to obtain the minimum depth information by the following formula:
[0133] F[x i ]=min(D[x i ,y yi :y hi ]),
[0134] Among them, D represents the depth estimation map, F represents the minimum depth information, and x i Represents x=x in the x direction in the depth estimation image i The corresponding pixel coordinate, y yi :y hi Indicates the depth estimation image in the y direction from y=y yi to y=y hi The corresponding pixel coordinates, i is any value from 1 to r, y yi For x i The corresponding pixel coordinates at the first preset height in the y direction, y hi For x i The pixel coordinates at the second preset height in the corresponding y direction.
[0135] It is understandable that F[x i] represents x=x i The depth value between the obstacle closest to the motion device and the motion device is between the first preset height and the second preset height.
[0136] S305, inputting the minimum depth information and the current motion parameters of the motion device into a behavior attention module to obtain current environment perception information.
[0137] Exemplarily, the current motion parameter of the motion device may include one or more of the current angular velocity, linear velocity, position, posture angle, and heading angle of the motion device.
[0138] Exemplarily, the behavior attention module may include the behavior attention module 207 in the above embodiment. Figure 7 As shown, the current action parameters of the motion device are input into a one-dimensional convolution layer for vector normalization, that is, the motion parameters with different unit meanings are weighted by the convolution layer to reduce the difference between the motion parameters. The one-dimensional output information of each motion parameter after vector normalization is merged to form a fusion matrix; the fusion matrix and the position coding matrix are added element by element and then passed through a two-dimensional convolution layer to obtain an attention matrix; wherein, the position coding matrix is a matrix of the same size as the fusion matrix, and the purpose of the matrix is to give the fusion matrix position information. Exemplarily, the position coding matrix can be assigned values in a certain pattern starting from the 0th row and the 0th column (such as 0, 1, 2, 3...), or it can also be encoded by a position coding tool. The minimum depth information is output through the two-dimensional convolution layer and the attention matrix is element-by-element dot multiplied to obtain the current environmental perception information.
[0139] In some possible implementations, the greedy depth compression module may also fuse the minimum depth information and the sensor information to obtain fused minimum depth information, and then input the fused minimum depth information and the current motion parameters of the motion device into the behavior attention module.
[0140] S306, inputting the current environment perception information and the target position of the motion device into a temporal reinforcement learning module to obtain target motion parameters for controlling the motion of the motion device.
[0141] Exemplarily, the temporal reinforcement learning module may include the temporal reinforcement learning module 208 in the above embodiment. The temporal reinforcement learning module may include a recurrent neural network, such as a long short-term memory (LSTM) neural network. The current environmental perception information and the historical environmental perception information are sequentially input into the recurrent neural network to obtain environmental perception information including historical importance selection and current environmental perception information. Further, the environmental perception information and the target position are input into the fully connected layer so that the fully connected layer can output the target motion parameters for controlling the motion of the motion device.
[0142] S305', adjusting the sensing range of the detection sensor according to the minimum depth information.
[0143] Exemplarily, the minimum depth information may be input into the quality assessment module 206 in the above embodiment to obtain optimization information. The optimization information may indicate the degree of matching between the minimum depth information and the first depth information.
[0144] In some possible implementations, when the degree of overlap between the curve of the minimum depth information and the curve of the first depth information is greater than or equal to a preset threshold, it is determined that the minimum depth information and the first depth information have a high degree of match, and there is no need to adjust the perception range of the detection sensor; when the degree of overlap between the curve of the minimum depth information and the curve of the first depth information is less than the preset threshold, the perception range of the detection sensor is adjusted according to the comparison result between the minimum depth information and the first depth information. Exemplarily, the above preset threshold may be 95%, or 90%, or other values.
[0145] Exemplarily, the comparison result between the minimum depth information and the first depth information is as follows: Figure 8 shown.
[0146] like Figure 8 As shown in (a), the first depth information is greater than the minimum depth information, that is, for any x corresponding to the curve in the figure, j , there is dj >z mj , it means that the obstacle perceived by the detection sensor is farther away, so the sensing range of the detection sensor can be reduced. dj For x j The depth distance of the obstacle sensed by the corresponding detection sensor, z dj For x j The corresponding depth distance of the obstacle is obtained by fusion of sensor information and image.
[0147] like Figure 8 As shown in (b), when the first depth information is less than the minimum depth information, that is, for any x=x corresponding to the curve in the figurej , there is dj <z mj , it means that the obstacle perceived by the detection sensor is closer, which means that the data obtained by the detection sensor is very important. It is necessary to increase the perception range of the detection sensor as much as possible to obtain more abundant data on the depth distance between the obstacle and the motion device.
[0148] like Figure 8 As shown in (c), when a portion of the first depth information curve is less than the minimum depth information, that is, for the portion corresponding to the curve in the figure x=x k , z dk <z mk , the sensing range of the detection sensor can be adjusted so that at least the sensing range can sense at least a portion of the first depth information that is smaller than the minimum depth information.
[0149] In some possible implementations, the optimization information may also indicate the density of obstacles in the area sensed by the image sensor, or the optimization information may also indicate the density of obstacles sensed by the detection sensor, so that the motion device can adjust the detection sensor's perception frame rate according to the density of obstacles. Specifically, when there are many obstacles, the detection sensor may be adjusted to sense at a faster frame rate; when there are few obstacles, the detection sensor may be adjusted to sense at a medium frame rate; when there are almost no obstacles, the detection sensor may be adjusted to sense at a slower frame rate.
[0150] In the specific implementation process, the above S305' may not be executed.
[0151] The entire process from S301 to S306 is as follows: Fig. 9 shown.
[0152] The motion control method provided in the embodiment of the present application can improve the perception accuracy of the motion device to obstacles, as well as the real-time obstacle avoidance of the motion device. By fusing the image and sensor information, rich information about the location of obstacles can be obtained, thereby improving the perception accuracy of the motion device; by compressing the rich information about the location of obstacles and eliminating redundant information, core information that is helpful for the motion device to plan obstacle avoidance can be obtained, namely, the minimum depth information, thereby improving the real-time obstacle avoidance decision-making of the motion device. In addition, the motion control method provided in the embodiment of the present application can also adjust the perception range and perception frame rate of the sensor in real time, which can improve the motion device's ability to adapt to the environment, thereby improving the intelligence of the motion device, and helping to save the energy consumption of the motion device.
[0153] Fig.10 1000 is a schematic flow chart of a control method provided in an embodiment of the present application. Figure 1The exercise device shown, or the method can be performed by Figure 2 For example, the method 1000 is performed by a sports device as an example, and the method 1000 may include:
[0154] S1010, acquiring an image of a first area, where the image indicates location information of a first obstacle in the first area, and the first area is an area where a destination of the sports device is located.
[0155] Exemplarily, the image may include the image in the above embodiment; the first area may include the area sensed by the image sensor in the above embodiment.
[0156] Exemplarily, the position of the first obstacle in the first area may be determined according to two-dimensional coordinate parameters of the first obstacle on the image.
[0157] S1020: Acquire sensor information, where the sensor information indicates first depth information between a second obstacle and the motion device, where the second obstacle is an obstacle located at a first preset height in the first area.
[0158] Exemplarily, the sensor information may include the sensor information in the above-mentioned embodiment.
[0159] S1030: Determine first distance information of the first obstacle according to the image and the first depth information, where the first distance information indicates a lateral distance between the first obstacle and the second obstacle in the image, and a depth distance between the first obstacle and the motion device.
[0160] Exemplarily, the first distance information may include the minimum depth information in the above embodiment. The specific method for the motion device to determine the first distance information may refer to the description of S301 to S304 in the above method 300, which will not be repeated here.
[0161] S1040: When the moving device moves toward the destination, control the moving device to avoid obstacles according to the first distance information.
[0162] Exemplarily, the specific method in which the motion device controls the movement of the motion device according to the first distance information may refer to the descriptions in S305 and S306 in the above method 300, which will not be described in detail here.
[0163] The motion control method provided in the embodiment of the present application can obtain richer obstacle information based on sensor information and images, and improve the perception accuracy of the motion device to obstacles; based on the rich obstacle information, the core information (such as the first distance information) that is helpful for the motion device to perform obstacle avoidance planning is extracted, so that the motion device performs obstacle avoidance planning based on the core information, thereby improving the real-time performance of obstacle avoidance. In particular, for dynamic scenes with large obstacle changes, the above method helps the motion device to quickly and accurately plan the obstacle avoidance path.
[0164] In the various embodiments of the present application, unless otherwise specified or logically conflicting, the terms and / or descriptions between the various embodiments are consistent and can be referenced to each other, and the technical features in different embodiments can be combined to form new embodiments according to their inherent logical relationships.
[0165] In one example, when method 1000 is combined with S301 to S304 in method 300, S301 to S304 can be summarized as: determining the lateral distance between the first obstacle and the second obstacle based on the pixel distance of the pixel points in the image; determining the depth distance between the first obstacle and the moving device based on the grayscale value of the pixel points in the image.
[0166] Among them, determining the depth distance between the first obstacle and the moving device according to the grayscale value of the pixel in the image includes: determining the depth distance corresponding to the grayscale value of the first pixel in the image according to the first depth information, the first pixel being the pixel in the image corresponding to the figure of the second obstacle; determining the depth distance between the first obstacle and the moving device according to the grayscale value of the second pixel in the image, at least one of the grayscale gradient value between the second pixel and the first pixel, and the depth distance corresponding to the grayscale value of the first pixel, the second pixel being the pixel in the image corresponding to the figure of the first obstacle.
[0167] In another example, when method 1000 is combined with S304 in method 300, S304 can be summarized as: the image indicates the position information of the third obstacle in the first area, and the method also includes: determining the obstacle closer to the moving device among the second obstacle and the third obstacle located in the first plane as the first obstacle, wherein the first plane is a plane parallel to the height direction and the depth direction of the moving device.
[0168] Among them, the depth direction of the motion device can be Figure 6 The z direction shown in (b).
[0169] In another example, when method 1000 is combined with S305-S306 in method 300, S305-S306 can be summarized as: obtaining current motion parameters of the motion device; controlling the motion device to avoid obstacles based on the first distance information, including: inputting the current motion parameters and the first distance information into the first neural network to obtain current environmental perception information; inputting the current environmental perception information and the destination into the second neural network to obtain the target angular velocity and the target linear velocity; and controlling the motion device to avoid obstacles based on the target angular velocity and the target linear velocity.
[0170] The first neural network may include a behavioral attention module, the second neural network may include a temporal reinforcement learning module, and the destination may include the target location in the above embodiment.
[0171] Alternatively, S305 - S306 may also be summarized as: the motion device determines a fused depth distance according to the first distance information and the first depth information; and the motion device controls the motion device to avoid obstacles according to the fused depth distance and the destination.
[0172] The fused depth distance may include the fused minimum depth information in method 300 .
[0173] Combined with the above Figures 1 to 10 The method provided in the embodiment of the present application is described in detail. Fig.11 and Fig.12 The device provided in the embodiment of the present application is described in detail. It should be understood that the description of the device embodiment corresponds to the description of the method embodiment, so the contents not described in detail can be referred to the method embodiment above, and for the sake of brevity, they will not be repeated here.
[0174] Fig.11 A schematic block diagram of a motion control device 2000 provided in an embodiment of the present application is shown. The device 2000 includes an acquisition unit 2010 and a processing unit 2020 .
[0175] The apparatus 2000 may include a Figure 3 , Fig.10 Furthermore, each unit in the device 2000 is respectively for implementing Figure 3 , Fig.10 The corresponding process of the method embodiment in FIG.
[0176] Wherein, when the device 2000 is used to perform Fig.10 When the method 1000 is performed, the acquisition unit 2010 can be used to execute S1010 and S1020 in the method 1000, and the processing unit 2020 can be used to execute S1030 and S1040 in the method 1000.
[0177] Specifically, the acquisition unit 2010 is used to: acquire an image of a first area, the image indicating position information of a first obstacle in the first area, and the first area is the area where the destination of the moving device is located; acquire sensor information, the sensor information indicating first depth information between a second obstacle and the moving device, and the second obstacle is an obstacle located at a first preset height in the first area; the processing unit 2020 is used to: determine first distance information of the first obstacle based on the image and the first depth information, the first obstacle is an obstacle located between the first preset height and the second preset height in the first area, and the first distance information indicates the lateral distance between the first obstacle and the second obstacle in the image, as well as the depth distance between the first obstacle and the moving device; and control the moving device to avoid obstacles based on the first distance information during the movement of the moving device toward the destination.
[0178] Optionally, the processing unit 2020 is used to: determine the lateral distance between the first obstacle and the second obstacle based on the pixel distance of the pixel points in the image; determine the depth distance between the first obstacle and the motion device based on the grayscale value of the pixel points in the image.
[0179] Optionally, the processing unit 2020 is used to: determine the depth distance corresponding to the grayscale value of a first pixel in the image according to the first depth information, where the first pixel is a pixel in the image corresponding to the graphic of the second obstacle; determine the depth distance between the first obstacle and the motion device according to the grayscale value of a second pixel in the image, at least one of a grayscale gradient value between the second pixel and the first pixel, and the depth distance corresponding to the grayscale value of the first pixel, where the second pixel is a pixel in the image corresponding to the graphic of the first obstacle.
[0180] Optionally, the acquisition unit 2010 detects the second obstacle through a detection sensor of the motion device, and acquires the sensor information according to data collected by the detection sensor, wherein the sensing range of the detection sensor is adjustable.
[0181] Optionally, the processing unit 2020 is used to dynamically adjust the sensing range of the detection sensor according to the depth distance indicated by the first distance information.
[0182] Optionally, the processing unit 2020 is used to: when the second depth distance is smaller than the first depth information, reduce the perception range of the detection sensor; or when the second depth distance is larger than the first depth information, increase the perception range of the detection sensor.
[0183] Optionally, the sensor information also indicates the density of the second obstacle, and the processing unit 2020 is used to dynamically adjust the perception frame rate of the detection sensor according to the density of the second obstacle.
[0184] Optionally, the image indicates position information of a third obstacle in the first area, and the processing unit 2020 determines the obstacle that is closer to the motion device among the second obstacle and the third obstacle located in the first plane as the first obstacle, wherein the first plane is a plane parallel to the height direction and the depth direction of the motion device.
[0185] Optionally, the acquisition unit 2010 is also used to: acquire current motion parameters of the motion device; the processing unit 2020 is used to: input the current motion parameters and the first distance information into a first neural network to obtain current environment perception information; input the current environment perception information and the destination into a second neural network to obtain a target angular velocity and a target linear velocity; and control the motion device to avoid obstacles according to the target angular velocity and the target linear velocity.
[0186] Optionally, the processing unit 2020 is used to: determine a fused depth distance according to the first distance information and the first depth information; and control the motion device to avoid obstacles according to the fused depth distance and the destination.
[0187] Exemplarily, the acquisition unit 2010 and the processing unit 2020 may be arranged in Figure 1 In the sports device 100 shown in FIG. 1 , more specifically, the acquisition unit 2010 and the processing unit 2020 may be arranged in Figure 1 In the computing platform 150 shown in FIG. 1 , the acquisition unit 2010 and the processing unit 2020 may also be arranged in Figure 2 In the system shown, more specifically, the acquisition unit 2010 may include a perception module 201, and the processing unit 2020 may include one or more of a feature extraction module 202, an information fusion module 203, a sparse depth estimation module 204, a greedy depth compression module 205, a quality assessment module 206, a behavioral attention module 207 and a temporal reinforcement learning module 208.
[0188] It should be understood that the division of the units in the above device is only a division of logical functions. In actual implementation, they can be fully or partially integrated into one physical entity, or they can be physically separated. In addition, the units in the device can be implemented in the form of a processor calling software; for example, the device includes a processor, the processor is connected to a memory, and instructions are stored in the memory. The processor calls the instructions stored in the memory to implement any of the above methods or realize the functions of the units of the device, wherein the processor is, for example, a general-purpose processor, such as a CPU or a microprocessor, and the memory is a memory in the device or a memory outside the device. Alternatively, the units in the device can be implemented in the form of hardware circuits, and the functions of some or all of the units can be realized by designing the hardware circuits. The hardware circuit can be understood as one or more processors; for example, in one implementation, the hardware circuit is an ASIC, and the functions of some or all of the above units are realized by designing the logical relationship of the components in the circuit; for another example, in another implementation, the hardware circuit can be implemented by PLD. Taking FPGA as an example, it can include a large number of logic gate circuits, and the connection relationship between the logic gate circuits is configured through the configuration file, so as to realize the functions of some or all of the above units. All units of the above device may be implemented entirely in the form of a processor calling software, or entirely in the form of a hardware circuit, or partially in the form of a processor calling software and the rest in the form of a hardware circuit.
[0189] Each unit in the above device can be one or more processors (or processing circuits) configured to implement the above method, such as: CPU, GPU, NPU, TPU, DPU, microprocessor, DSP, ASIC, FPGA, or a combination of at least two of these processor forms.
[0190] In addition, all or part of the units in the above device can be integrated together, or can be implemented independently. In one implementation, these units are integrated together and implemented in the form of a system-on-a-chip (SOC). The SOC may include at least one processor for implementing any of the above methods or implementing the functions of each unit of the device. The type of the at least one processor may be different, for example, including a CPU and an FPGA, a CPU and an artificial intelligence processor, a CPU and a GPU, etc.
[0191] In a specific implementation process, the operations performed by the acquisition unit 2010 and the processing unit 2020 may be performed by one processor, or may be performed by different processors. Figure 1 The processor in the computing platform 150 shown; alternatively, the above-mentioned device 2000 can be a chip set in the sports equipment 100.
[0192] Fig.12 It is a schematic block diagram of a motion control device provided in an embodiment of the present application. Fig.12 The motion control device 2100 shown may include: a processor 2110, a transceiver 2120, and a memory 2130. The processor 2110, the transceiver 2120, and the memory 2130 are connected via an internal connection path, the memory 2130 is used to store instructions, and the processor 2110 is used to execute the instructions stored in the memory 2130 to implement the control method in the above embodiments. Optionally, the memory 2130 can be coupled to the processor 2110 through an interface, or can be integrated with the processor 2110.
[0193] It should be noted that the transceiver 2120 may include but is not limited to a transceiver device such as an input / output interface to achieve communication between the device 2100 and other devices or a communication network.
[0194] The memory 2130 may be a read only memory (ROM), a static storage device, a dynamic storage device or a random access memory (RAM).
[0195] The transceiver 2120 uses a transceiver device such as but not limited to a transceiver to implement communication between the device 2100 and other devices or a communication network to receive / send data / information used to implement the control method in the above embodiments.
[0196] In the specific implementation process, the device 2100 can be set at Figure 1 The computing platform 150 shown in FIG. Figure 2 in the system shown.
[0197] An embodiment of the present application further provides a sports device, which includes the above-mentioned device 2000; or, the sports device includes the above-mentioned device 2100, as well as a detection sensor and an image sensor.
[0198] An embodiment of the present application further provides a computer program product, which includes a computer program code. When the computer program code runs on a computer, the computer implements the methods in the above embodiments of the present application.
[0199] An embodiment of the present application further provides a computer-readable storage medium, which stores computer instructions. When the computer instructions are executed on a computer, the computer implements the methods in the above embodiments of the present application.
[0200] An embodiment of the present application also provides a chip, including a circuit, for executing the methods in the above embodiments of the present application.
[0201] In the implementation process, each step of the above method can be completed by an integrated logic circuit of hardware in a processor or an instruction in the form of software. The method disclosed in conjunction with the embodiment of the present application can be directly embodied as a hardware processor for execution, or a combination of hardware and software modules in a processor for execution. The software module can be located in a storage medium mature in the art such as a random access memory, a flash memory, a read-only memory, a programmable read-only memory, or a power-on erasable programmable memory, a register, etc. The storage medium is located in a memory, and the processor reads the information in the memory and completes the steps of the above method in conjunction with its hardware. To avoid repetition, it is not described in detail here.
[0202] Those skilled in the art can clearly understand that, for the convenience and brevity of description, the specific working processes of the systems, devices and units described above can refer to the corresponding processes in the aforementioned method embodiments and will not be repeated here.
[0203] In the several embodiments provided in the present application, it should be understood that the disclosed systems, devices and methods can be implemented in other ways. For example, the device embodiments described above are only schematic. For example, the division of the units is only a logical function division. There may be other division methods in actual implementation, such as multiple units or components can be combined or integrated into another system, or some features can be ignored or not executed. Another point is that the mutual coupling or direct coupling or communication connection shown or discussed can be through some interfaces, indirect coupling or communication connection of devices or units, which can be electrical, mechanical or other forms.
[0204] The units described as separate components may or may not be physically separated, and the components shown as units may or may not be physical units, that is, they may be located in one place or distributed on multiple network units. Some or all of the units may be selected according to actual needs to achieve the purpose of the solution of this embodiment.
[0205] In addition, each functional unit in each embodiment of the present application may be integrated into one processing unit, or each unit may exist physically separately, or two or more units may be integrated into one unit.
[0206] The above is only a specific implementation of the present application, but the protection scope of the present application is not limited thereto. Any person skilled in the art who is familiar with the present technical field can easily think of changes or substitutions within the technical scope disclosed in the present application, which should be included in the protection scope of the present application. Therefore, the protection scope of the present application should be based on the protection scope of the claims.
Claims
1. A motion control method, characterized in that: include: Acquire an image of a first area, wherein the image indicates location information of a first obstacle in the first area, and the first area is an area where a destination of the sports device is located; Acquire sensor information, where the sensor information indicates first depth information between a second obstacle and the sports device, where the second obstacle is an obstacle located at a first preset height in the first area; Determine, according to the image and the first depth information, first distance information of the first obstacle, where the first obstacle is an obstacle located between the first preset height and a second preset height in the first area, and the first distance information indicates a lateral distance between the first obstacle and the second obstacle in the image, and a depth distance between the first obstacle and the sports device; When the moving device moves toward the destination, the moving device is controlled to avoid obstacles according to the first distance information.
2. The method according to claim 1, characterized in that The determining, according to the image and the first depth information, first distance information of the first obstacle includes: determining a lateral distance between the first obstacle and the second obstacle according to a pixel distance between pixel points in the image; The depth distance between the first obstacle and the motion device is determined according to the grayscale value of the pixel in the image.
3. The method according to claim 2, characterized in that The determining the depth distance between the first obstacle and the motion device according to the grayscale value of the pixel point in the image includes: Determine, according to the first depth information, a depth distance corresponding to a grayscale value of a first pixel point in the image, where the first pixel point is a pixel point in the image corresponding to a graphic of the second obstacle; The depth distance between the first obstacle and the motion device is determined based on the grayscale value of a second pixel in the image, at least one of the grayscale gradient values between the second pixel and the first pixel, and the depth distance corresponding to the grayscale value of the first pixel, where the second pixel is a pixel in the image corresponding to the graphic of the first obstacle.
4. The method according to any one of claims 1 to 3, characterized in that The method further comprises: The second obstacle is detected by a detection sensor of the motion device, and the sensor information is acquired according to data collected by the detection sensor, wherein the sensing range of the detection sensor is adjustable.
5. The method according to claim 4, characterized in that The method further comprises: The sensing range of the detection sensor is dynamically adjusted according to the depth distance indicated by the first distance information.
6. The method according to claim 4 or 5, characterized in that: The sensor information further indicates a density of the second obstacle, and the method further includes: The sensing frame rate of the detection sensor is dynamically adjusted according to the density of the second obstacle.
7. The method according to any one of claims 1 to 6, characterized in that The image indicates location information of a third obstacle in the first area, and the method further includes: The obstacle closer to the sports equipment between the second obstacle and the third obstacle located in a first plane is determined as the first obstacle, wherein the first plane is a plane parallel to the height direction and the depth direction of the sports equipment.
8. The method according to any one of claims 1 to 7, characterized in that The method further comprises: Get the current motion parameters of the motion device; The controlling the motion device to avoid obstacles according to the first distance information includes: Inputting the current motion parameter and the first distance information into a first neural network to obtain current environment perception information; Inputting the current environment perception information and the destination into a second neural network to obtain a target angular velocity and a target linear velocity; The motion device is controlled to avoid obstacles according to the target angular velocity and the target linear velocity.
9. The method according to any one of claims 1 to 8, characterized in that The controlling the motion device to avoid obstacles according to the first distance information includes: Determine a fused depth distance according to the first distance information and the first depth information; The motion device is controlled to avoid obstacles according to the fusion depth distance and the destination.
10. A sports equipment, characterized in that: include: An image sensor is used to: acquire an image of a first area, wherein the image indicates location information of a first obstacle in the first area, and the first area is an area where a destination of the sports device is located; A detection sensor is used to: detect a second obstacle located at a first preset height in the first area to obtain sensor information, wherein the sensor information indicates first depth information between the second obstacle and the motion device, and the second obstacle is an obstacle located at a first preset height in the first area; The processor is used to: determine first distance information of the first obstacle based on the image and the first depth information, the first obstacle being an obstacle located between the first preset height and the second preset height in the first area, the first distance information indicating the lateral distance between the first obstacle and the second obstacle in the image, and the depth distance between the first obstacle and the moving device; the processor is also used to control the moving device to avoid obstacles based on the first distance information during the movement of the moving device toward the destination.
11. The sports equipment according to claim 10, characterized in that The processor is used to: determining a lateral distance between the first obstacle and the second obstacle according to a pixel distance between pixel points in the image; The depth distance between the first obstacle and the motion device is determined according to the grayscale value of the pixel in the image.
12. The exercise equipment according to claim 11, characterized in that The position of the second obstacle in the first area includes a height of the second obstacle, and the processor is further configured to: Determine, according to the first depth information, a depth distance corresponding to a grayscale value of a first pixel point in the image, where the first pixel point is a pixel point in the image corresponding to a graphic of the second obstacle; The depth distance between the first obstacle and the motion device is determined based on the grayscale value of a second pixel in the image, at least one of the grayscale gradient values between the second pixel and the first pixel, and the depth distance corresponding to the grayscale value of the first pixel, where the second pixel is a pixel in the image corresponding to the graphic of the first obstacle.
13. The sports equipment according to any one of claims 10 to 12, characterized in that The sensing range of the detection sensor is adjustable.
14. The exercise equipment according to claim 13, characterized in that The processor is used to: The sensing range of the detection sensor is dynamically adjusted according to the depth distance indicated by the first distance information.
15. The sports equipment according to claim 13 or 14, characterized in that The sensor information further indicates a density of the second obstacle, and the processor is further configured to: According to the density of the first obstacle, the sensing frame rate of the detection sensor is adjusted.
16. The sports equipment according to any one of claims 10 to 15, characterized in that The image indicates location information of a third obstacle in the first area, and the processor is further configured to: The obstacle closer to the sports equipment between the second obstacle and the third obstacle located in a first plane is determined as the first obstacle, wherein the first plane is a plane parallel to the height direction and the depth direction of the sports equipment.
17. The sports equipment according to any one of claims 10 to 16, characterized in that The processor is further configured to: Get the current motion parameters of the motion device; Inputting the current motion parameter and the first distance information into a first neural network to obtain current environment perception information; Inputting the current environment perception information and the destination into a second neural network to obtain a target angular velocity and a target linear velocity; The motion device is controlled to avoid obstacles according to the target angular velocity and the target linear velocity.
18. The sports equipment according to any one of claims 10 to 17, characterized in that The processor is used to: Determine a fused depth distance according to the first distance information and the first depth information; The motion device is controlled to avoid obstacles according to the fusion depth distance and the destination.
19. An integrated circuit, characterized in that: include: Memory for storing computer programs; A processor, configured to execute the computer program stored in the memory, so that the apparatus performs the method according to any one of claims 1 to 9.
20. A computer-readable storage medium, characterized in that: Instructions are stored thereon, and when the instructions are executed by a processor, the processor implements the method according to any one of claims 1 to 9.
Citation Information
Patent Citations
Indoor robot obstacle avoidance method and device
CN110502019A
Robot and obstacle sensing method and device thereof
CN111399492A
Robot advancing path planning method and device and storage medium
CN112363494A
Method and system for determining 3D image information
EP3945349A1
Cited By
Motion control method and moving device
EP4645022A1
Motion control method and moving device
WO2024198994A1
