Single robot motion planning method for assembly tasks based on pulse hybrid reinforcement learning

By introducing the pulse hybrid reinforcement learning model in the robot arm motion planning, combined with the pulse neural network and the deep neural network, the problems of low flexibility and high energy consumption in the robot arm motion planning are solved, and the energy consumption is reduced and the learning speed is improved. Improved, suitable for energy-constrained operating environments.

CN118438457BActive Publication Date: 2024-09-17ANHUI UNIV +1
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN202410906141.3
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2024-07-08
Publication Date
2024-09-17
Estimated Expiration
2044-07-08

AI Technical Summary

Technical Problem

There are problems of low flexibility and high energy consumption in robot arm motion planning. Especially in assembly tasks, traditional neural networks have high energy consumption and are difficult to effectively process time-changing information in the environment.

Method used

A single manipulator motion planning method based on pulse hybrid reinforcement learning is designed, combining pulse neural network and deep neural network, introducing a self-driven adaptive threshold plasticity mechanism, which is only activated when receiving an input signal, reducing energy consumption, and passing Deep reinforcement learning framework optimizes network parameters.

Benefits of technology

Significantly reduces the energy consumption of the system, improves inference speed and computational sparsity, reduces overfitting to specific samples, speeds up learning, improves the robustness and generalization ability of value estimation, and adapts to energy-constrained operations environment.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN118438457B
    Figure CN118438457B
Patent Text Reader

Abstract

The present invention relates to a single robot arm motion planning method for an assembly task based on pulse hybrid reinforcement learning, comprising: dividing the robot arm motion into n stages, and designing a dense reward function for the end point of each stage; utilizing the observation information and action information dimensions of the robot arm and target parts in the scene, designing a pulse encoding module and a pulse neural network module with a dynamic threshold, extracting features through the pulse neural layer therein, and outputting the final pulse activity; designing a group decoding module, decoding the pulse activity output by the pulse neural network into a more intuitive action space expression; designing a pulse hybrid reinforcement learning SAC model, combining the above three modules in the policy network, and using a deep neural network in the value network, and utilizing the pulse hybrid reinforcement learning model to optimize the parameters in each network, thereby achieving a high reasoning speed, while giving the network the characteristics of sparse computing and high-precision performance, and guiding the robot arm to complete the assembly task.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present invention relates to the technical field of single robot arm motion planning, and in particular to a single robot arm motion planning method based on pulse hybrid reinforcement learning assembly tasks. Background Art

[0002] Using a robot to complete tasks has many advantages over human labor. In terms of production efficiency, the robot can work continuously and does not need to rest like workers. This allows the production line to run without interruption, greatly improving production efficiency and output. Compared with human labor, the robot can perform more precise movements to ensure that each product is assembled according to standards. This precision is particularly important to ensure that the quality and durability of all assembled parts meet high standards. In terms of safety, the robot can perform tasks that are dangerous or harmful to human health, such as carrying heavy objects, operating sharp or high-speed tools, etc., thereby reducing the risk of industrial accidents.

[0003] But assembling parts is not simple even for humans. First, a variety of different types of parts need to be combined into the final configuration. Specifically, from the parts alone, it is not clear which parts to choose for attachment and in what order to attach them. Therefore, this study needs to analyze the final configuration and derive the sequence of tasks required to build the assembly. In addition, connecting two parts requires complex manipulation skills, such as accurate alignment of two attachment points and precise force control to connect them firmly. Therefore, assembly is a highly comprehensive robotic arm technical task that requires reliable 3D perception, high-level planning, and complex control, making it a suitable benchmark for robotic arm learning algorithms.

[0004] A spiking neural network is an artificial neural network that mimics the action potential transmission mechanism of neurons in the biological brain. It is an energy-saving alternative to deep networks. The neurons of a spiking neural network are activated only when they receive enough stimulation to exceed a certain threshold, thereby generating a pulse. This way of working means that energy is consumed only when necessary, making it extremely efficient in energy consumption and avoiding a large number of floating-point high-precision multiplication operations in traditional neural networks. Currently, spiking neural networks have been applied to technologies such as robotic arm control operations, autonomous driving systems, pattern recognition and image processing, showing the diversity and potential of spiking neural networks in solving practical problems, especially in situations where fast, efficient and low-energy solutions are required. Summary of the invention

[0005] The purpose of the present invention is to address the problems of low flexibility and high energy consumption in robot arm motion planning, and to provide a single robot arm motion planning method based on pulse hybrid reinforcement learning assembly tasks. This method consumes energy only when necessary, making it extremely efficient in energy consumption and avoiding a large number of high-precision floating-point multiplication operations in traditional neural networks. The innovation of the present invention lies in the design of a pulse hybrid reinforcement learning model, combining a pulse neural network SNN in the policy network Actor, introducing a pulse neural network in the policy network, and still using a deep neural network in the value network. The introduced pulse neural networks can better process information that changes over time in the environment and are more energy-efficient because they are only activated when they receive input signals. Therefore, this method significantly reduces energy consumption when the system is running. In addition, a self-driven adaptive threshold plasticity mechanism is proposed in the pulse neural network stage, which enables neurons to dynamically and unsupervisedly adjust the trigger threshold according to their own pulse activity, thereby achieving a higher reasoning speed, while giving the network the characteristics of sparse computing and high-precision performance; and in the value network Critic, the deep neural network DNN is still used, which has the advantages of reducing overfitting of specific samples, accelerating learning speed, improving the robustness and generalization ability of value estimation, etc. Based on the deep reinforcement learning framework SAC, the parameters in each network are optimized to obtain a trained model to guide the robot to complete a new assembly task. In this way, this study aims to find a set of optimal actions with low energy consumption for the robot to adapt to the energy-constrained operating environment and promote the widespread deployment of robot technology in practical applications.

[0006] To solve the above technical problems, the present invention provides the following technical solution: a single robot arm motion planning method for an assembly task based on pulse hybrid reinforcement learning, comprising the following steps:

[0007] S1. For assembly tasks, the robot arm motion is divided into n stages, and a dense reward function is designed for the end point of each stage.

[0008] S2. Using the observation information and action information dimensions of the robot arm and the target parts in the scene, design a pulse coding module so that each dimension of the observation data of the robot arm and the target parts is encoded by a neuron group, so that these observation data can be encoded into pulse signals suitable for processing by the pulse neural network through the pulse coding layer;

[0009] S3. Design a pulse neural network module with dynamic threshold based on the circuit leakage-integration-discharge working principle, use the obtained pulse signal to input into the module, extract features through the pulse neural layer therein, and output the final pulse activity;

[0010] S4. Design a group decoding module to convert the pulse activity output by the pulse neural layer into a more intuitive action space expression through the group decoding layer;

[0011] S5. Design a pulse hybrid reinforcement learning SAC model. In the policy network Actor, the above-mentioned pulse encoding module, pulse neural network module and group decoding module are combined. In the value network Critic, the DNN deep neural network is used. The pulse hybrid reinforcement learning SAC model is used to optimize the parameters in each network to guide the robot arm to complete the assembly task.

[0012] Furthermore, in step S1, the movement of the robot arm is divided into n stages, specifically including: dividing the movement of the robot arm into 8 stages, namely: initial stage, arrival stage, descent stage, grasping stage, lifting stage, alignment stage, movement stage and fine-grained movement stage.

[0013] Furthermore, the dense reward function in step S1 specifically includes:

[0014] In order to grasp the new target part, the reward given when the end effector moves to the initial position is expressed as , The reward is calculated by reducing the Euclidean distance between the actuator and the target part position, and the reward is proportional to the negative distance between the end-effector gripper position and the initial position;

[0015] The reward given when the end effector moves above the target part is expressed as , also based on Euclidean distance calculation; the reward is proportional to the negative distance between the end effector gripper position and a point 5 cm above the gripper pick-up point;

[0016] The reward given when the end effector is lowered onto the target part is expressed as , the reward is calculated based on the proximity of the end effector to the target part, and the reward is proportional to the negative distance between the end effector gripper position and the target grasping point;

[0017] The reward given when the target part is correctly grasped is expressed as , the reward is calculated based on the position accuracy of the end effector and the correctness of the grasping action, and the reward is proportional to the force applied by the robot arm gripper;

[0018] The reward when upgrading the target component is expressed as , calculated based on the distance difference between the actual position of the target part and the target position, the reward is proportional to the negative distance between the position of the grasped target part and the position where the target part is lifted;

[0019] The reward when the target part is aligned with the target connector is expressed as The reward is proportional to the cosine similarity between the upper vector and the front vector of the two connectors. The connector refers to the specific part of the target component that the robot needs to align and operate. If the position and angle of the target component are accurately aligned without contacting the target component, positive incentives are given, and penalties are imposed when the target component is deviated;

[0020] The reward for aligning a target part held by the end effector with another target part is roughly expressed as , the reward is proportional to the negative distance between the connector of the clamped target part and the point 5 cm above the connector of the other target part, and the reward is proportional to the cosine similarity between the top vector and the front vector of the two connectors. All connectors are marked with aligned top and front vectors;

[0021] The reward for fine-tuning the target component so that it is perfectly aligned with the connector is expressed as ,In addition, when the target part is connectable, a reward is provided based on the activation of the ,connection action;

[0022] The reward for the alignment of the up vector and the front vector of the end effector is expressed as ;

[0023] The penalty given according to the state of the actuator is expressed as , at the stage when the grabber should be closed, if the grabber is not closed, a penalty of -1 is imposed;

[0024] The control penalty is expressed as , penalizes excessive actions, and the penalty is the action vector norm*(-0.001);

[0025] The penalty for moving a non-target part is expressed as ; Therefore, the total reward .

[0026] Furthermore, in step S2, the observation data is converted by inputting observation information of the robot arm and the target component in the scene into an encoder.

[0027] Furthermore, the dimensions of observation information and action information of the robot arm and the target component in step S2 specifically include:

[0028] The observation information is divided into robot arm observation values ​​and target component observation values. The robot arm observation values ​​include the position of each joint of the robot arm, the speed of each joint of the robot arm, the joint position of the gripper, the position of the end effector, the quaternion of the end effector, the linear velocity of the end effector, and the angular velocity of the end effector. Therefore, the observation value of the robot arm is represented by a 7+7+2+3+4+3+3=29-dimensional data.

[0029] The target component observation value includes the position and posture of the target component. The position is represented by 3-dimensional data, and the posture is represented by quaternion, that is, 4 dimensions. When there are n target components in the task, the observation data of all target components are represented by n*(3+4)=7n-dimensional data, so the total observation data is represented by 29+7n-dimensional data;

[0030] The motion information of the robot arm includes the speed of each joint of the robot arm, as well as two additional functions of selection and connection. Therefore, the motion information is represented by a 7+1+1=9-dimensional data.

[0031] Furthermore, in step S2, a pulse coding module is designed so that each dimension of the observation data of the robot arm and the target component is encoded by a neuron group, so that these observation data are encoded into pulse signals suitable for processing by the pulse neural network through the pulse coding layer. The specific process includes the following steps:

[0032] S21: For the robot arm and the target part in the scene at time Observation data at Any dimension in Data , ; First, the observed data is transformed into Transformed into the response width of each neuron to the input observation data ,in represents the specific response center of each neuron, It represents the response width of each neuron, both of which are trainable parameters;

[0033] S22: Based on response width Generate a pulse signal , the generated rules are as follows:

[0034] ;

[0035] ;

[0036] ;

[0037] in Indicates that at present The membrane potential state of all neurons at the moment is 0 initially; Indicates that at present Time pulse signal; Process each element of the input vector; determine whether the corresponding neuron exceeds the threshold , if it exceeds the threshold, it takes 1, otherwise it takes 0; in the formula Threshold , so as to better simulate the situation in which the membrane voltage of biological neurons drops after firing an action potential.

[0038] Furthermore, in step S3, the spiking neural layer includes two hidden layers and one output layer, and the number of spiking neurons are 256, 256, and 90 respectively.

[0039] Further, in step S3, a pulse neural network module with a dynamic threshold based on the circuit leakage-integration-discharge working principle is designed, the obtained pulse signal is input into the module, the features are extracted through the pulse neural layer therein, and the final pulse activity is output. The specific process includes the following steps:

[0040] S31, any pulse neuron current ,in Indicates the number of layers of the neural network where the neuron is located, Indicates that the layer The update rule of neurons is as follows:

[0041] ;

[0042] The update takes into account the leaky nature of neurons, using Represents the current decay rate. The current decays naturally when there is no new input, but is also affected by new input signals. represents a linear layer used to process pulse signals. Indicates that at present Moment The first layer of the neural network The impulse signal of each neuron;

[0043] S32, any pulse neuron model voltage The update rules are as follows:

[0044] ;

[0045] Represents the firing threshold of the neuron. The voltage accumulation process simulates the change of the neuron membrane potential, which is the key process for the neuron to prepare to fire a spike.

[0046] S33, discharge threshold Based on the current output of the neuron , membrane potential V and discharge threshold The neurons themselves are dynamically updated in time. The discharge activity triggers, that is, the self-driven adaptive threshold is expressed as:

[0047] ;

[0048] ;

[0049] in represents the update rate, is the average firing rate of the neuron, is a small positive number to prevent division by zero; represents the output of the neuron, which is expressed as follows:

[0050] ;

[0051] in, is the Dirac delta function, indicating whether the spike is at time trigger, is the response intensity;

[0052] S34, any pulse neuron pulse signal The update rules are as follows:

[0053] ;

[0054] in, Process each element of the input vector to determine whether the corresponding neuron exceeds the threshold If it exceeds the threshold, it takes 1, otherwise it takes 0. This step simulates the action potential discharge of biological neurons when the voltage reaches the threshold.

[0055] Furthermore, in step S4, the pulse activity output by the pulse neural layer is converted into a continuous action space through one-dimensional convolution and activation function to realize autonomous motion planning of the robotic arm.

[0056] Furthermore, the specific process of step S5 includes the following steps:

[0057] S51, inputting the observation value information, action information and parameter value processed by the group decoding module into the strategy network to obtain the corresponding logarithmic probability of the action and the entropy information of the action;

[0058] S52. The value network includes two critic networks, each of which includes an MLP multilayer perceptron. Each MLP multilayer perceptron consists of three fully connected layers, with an input dimension of 38+7n and a final output dimension of 1. The observation values ​​and action information obtained by the encoder and group decoding modules of the policy network are respectively calculated through the value network Critic to obtain the Q value, and the action is evaluated through the Q value, which can be further fed back to the policy network to improve its strategy.

[0059] S53, input the pulse hybrid reinforcement learning SAC model through the observation value, action information, reward value, and next observation value information, use the mean square error to calculate the loss of the two Q networks in the value network to calculate the total critic loss, perform back propagation based on the obtained critic loss value to calculate the gradient of the network parameters, and use the optimizer to update these parameters; the observation value and action information obtained by the encoder and group decoding module of the policy network are respectively input into the value network, and the calculated minimum Q value is used as part of the actor loss of the policy network, and then the loss entropy is obtained according to the policy entropy and temperature parameter, the actor loss and the loss entropy are added to obtain the total actor loss, and back propagation is also performed to calculate the gradient of the policy network parameters, and the optimizer is used to update these parameters;

[0060] S54. During the training process, the parameter updates of the value network and the policy network are performed alternately, and the updated optimized actions are deployed to the robotic arm and target parts in the scene, so as to realize the task of assembling the target parts by the robotic arm in the scene.

[0061] By means of the above technical solution, the present invention provides a single robot arm motion planning method for an assembly task based on pulse hybrid reinforcement learning, which has at least the following beneficial effects:

[0062] The innovation of the present invention lies in the design of a pulse hybrid reinforcement learning model, which combines a pulse neural network SNN in the policy network Actor, introduces a pulse neural network in the policy network, and still uses a deep neural network in the value network; the introduced pulse neural network can better process the time-varying information in the environment and is more energy-efficient, because they are only activated when they receive input signals, so this method significantly reduces energy consumption when the system is running. In addition, a self-driven adaptive threshold plasticity mechanism is proposed in the pulse neural network stage, which enables neurons to dynamically and unsupervisedly adjust the trigger threshold according to their own pulse activity, thereby achieving a higher reasoning speed, while giving the network the characteristics of sparse computing and high-precision performance; and the deep neural network DNN is still used in the value network Critic, which has the advantages of reducing overfitting of specific samples, accelerating learning speed, improving the robustness and generalization ability of value estimation, etc.; based on the deep reinforcement learning framework SAC, the parameters in each network are optimized to obtain a trained model, thereby guiding the robot to complete a new assembly task. In this way, this study aims to find a set of optimal action sets with low energy consumption for the robot to adapt to the energy-constrained operating environment and promote the widespread deployment of robot technology in practical applications. BRIEF DESCRIPTION OF THE DRAWINGS

[0063] The drawings described herein are used to provide a further understanding of the present application and constitute a part of the present application. The illustrative embodiments of the present application and their descriptions are used to explain the present application and do not constitute an improper limitation on the present application. In the drawings:

[0064] Figure 1 It is an overall flow chart of the single robot arm motion planning method based on pulse hybrid reinforcement learning assembly task of the present invention;

[0065] Figure 2 This is a diagram of the architecture of the population coding spike neural network of the present invention;

[0066] Figure 3 It is the overall architecture diagram of the hybrid reinforcement model SAC in the present invention;

[0067] Figure 4 It is a schematic diagram of the robot arm assembly simulation in the present invention. DETAILED DESCRIPTION

[0068] In order to make the above-mentioned purposes, features and advantages of the present invention more obvious and easy to understand, the present invention is further described in detail below with reference to the accompanying drawings and specific implementation methods, so that the implementation process of how the present application uses technical means to solve technical problems and achieve technical effects can be fully understood and implemented accordingly.

[0069] Those skilled in the art can understand that all or part of the steps in the above-mentioned embodiment method can be completed by instructing the relevant hardware through a program, so the present application can take the form of a complete hardware embodiment, a complete software embodiment, or an embodiment combining software and hardware. Moreover, the present application can take the form of a computer program product implemented on one or more computer-usable storage media (including but not limited to disk storage, CD-ROM, optical storage, etc.) containing computer-usable program codes.

[0070] Please refer to Figure 1-Figure 4, shows a specific implementation of this embodiment. This embodiment combines the pulse neural network SNN in the policy network Actor by designing a pulse hybrid reinforcement learning model, introduces the pulse neural network in the policy network, and still uses the deep neural network in the value network; the introduced pulse neural network can better process the time-varying information in the environment and is more energy-efficient, because they are only activated when receiving input signals. Therefore, this method significantly reduces energy consumption when the system is running. In addition, a self-driven adaptive threshold plasticity mechanism is proposed in the pulse neural network stage, which enables neurons to dynamically and unsupervisedly adjust the trigger threshold according to their own pulse activity, thereby achieving a higher reasoning speed, while giving the network the characteristics of sparse computing and high-precision performance; and the deep neural network DNN is still used in the value network Critic, which has the advantages of reducing overfitting of specific samples, accelerating learning speed, improving the robustness and generalization ability of value estimation, etc.; based on the deep reinforcement learning framework SAC, the parameters in each network are optimized to obtain a trained model, thereby guiding the robot arm to complete a new assembly task. In this way, this study aims to find a set of optimal actions with low energy consumption for the robotic arm to adapt to energy-constrained operating environments and promote the widespread deployment of robotic arm technology in practical applications.

[0071] Please refer to Figure 1 , this embodiment proposes a single robot arm motion planning method based on pulse hybrid reinforcement learning assembly task, the method includes the following steps:

[0072] S1. For assembly tasks, the robot arm motion is divided into n stages, and a dense reward function is designed for the end point of each stage.

[0073] As a preferred implementation of step S1, in step S1, the movement of the robot arm is divided into n stages, specifically including: dividing the movement of the robot arm into 8 stages, namely: initial stage, arrival stage, descent stage, grasping stage, lifting stage, alignment stage, moving stage and fine-grained moving stage.

[0074] More specifically, the dense reward function in step S1 specifically includes:

[0075] In this embodiment, the target component can be selected as a chair leg, such as Figure 4 In order to grasp the new target part, the reward given when the end effector moves to the initial position is expressed as , The reward is calculated by reducing the Euclidean distance between the actuator and the target part position, and the reward is proportional to the negative distance between the end-effector gripper position and the initial position;

[0076] The reward given when the end effector moves above the target part is expressed as , also based on Euclidean distance calculation; the reward is proportional to the negative distance between the end effector gripper position and a point 5 cm above the gripper pick-up point;

[0077] The reward given when the end effector is lowered onto the target part is expressed as , the reward is calculated based on the proximity of the end effector to the target part, and the reward is proportional to the negative distance between the end effector gripper position and the target part grasping point;

[0078] The reward given when the target part is correctly grasped is expressed as , the reward is calculated based on the position accuracy of the end effector and the correctness of the grasping action, and the reward is proportional to the force applied by the robot arm gripper;

[0079] The reward when upgrading the target component is expressed as , calculated based on the distance difference between the actual position of the target part and the target position, the reward is proportional to the negative distance between the position of the grasped target part and the position where the target part is lifted;

[0080] The reward when the target part is aligned with the target connector is expressed as The reward is proportional to the cosine similarity between the upper vector and the front vector of the two connectors. The connector refers to the specific part of the target component that the robot needs to align and operate. If the position and angle of the target component are accurately aligned without contacting the target component, positive incentives are given, and penalties are imposed when the target component is deviated;

[0081] The reward for the end effector to move and align the gripped target part with another target part is expressed as , the reward is proportional to the negative distance between the connector of the clamped target part and the point 5 cm above the connector of the other target part, and the reward is proportional to the cosine similarity between the top vector and the front vector of the two connectors. All connectors are marked with aligned top and front vectors;

[0082] The reward for fine-tuning the target component so that it is perfectly aligned with the connector is expressed as ,The robot arm must finely align the two connectors on the target part until it is attached. The same reward is used as the movement phase with a higher coefficient, making the reward more sensitive to small changes. In addition, when the target part is connectable, a reward is provided based on the activation of the connection action;

[0083] The reward for the alignment of the up vector and the front vector of the end effector is expressed as ;

[0084] The penalty given according to the state of the actuator is expressed as , at the stage when the grabber should be closed, if the grabber is not closed, a penalty of -1 is imposed;

[0085] The control penalty is expressed as , penalizes actions that are too large, and the penalty is the action vector norm*(-0.001);

[0086] The penalty for moving a non-target part is expressed as ; Therefore, the total reward .

[0087] S2. Using the observation information and action information dimensions of the robot arm and the target parts in the scene, design a pulse coding module so that each dimension of the observation data of the robot arm and the target parts is encoded by a neuron group, so that these observation data can be encoded into pulse signals suitable for processing by the pulse neural network through the pulse coding layer;

[0088] As a preferred implementation of step S2, the dimensions of observation information and action information of the robot arm and the target component in step S2 specifically include:

[0089] The observation information is divided into robot arm observation values ​​and target component observation values. The robot arm observation values ​​include the position of each joint of the robot arm, the speed of each joint of the robot arm, the joint position of the gripper, the position of the end effector, the quaternion of the end effector, the linear velocity of the end effector, and the angular velocity of the end effector. Therefore, the observation value of the robot arm is represented by a 7+7+2+3+4+3+3=29-dimensional data.

[0090] The target component observation value includes the position and posture of the target component. The position is represented by 3-dimensional data, and the posture is represented by quaternion, that is, 4 dimensions. When there are 5 target components in the task, the observation data of all target components are represented by 35-dimensional data, so the total observation data is represented by 64-dimensional data.

[0091] The motion information of the robot arm includes the speed of each joint of the robot arm, as well as two additional functions of selection and connection. Therefore, the motion information is represented by a 7+1+1=9-dimensional data.

[0092] More specifically, in step S2, a pulse coding module is designed so that each dimension of the observation data of the robot arm and the target component is encoded by a neuron group, so that these observation data are encoded into pulse signals suitable for processing by the pulse neural network through the pulse coding layer. The specific process includes the following steps:

[0093] S21: For the robot arm and the target part in the scene at time Observational data at Any dimension in Data , ; First, the observed data is transformed into Transformed into the response width of each neuron to the input observation data ,in represents the specific response center of each neuron, It represents the response width of each neuron, both of which are trainable parameters;

[0094] S22: Based on response width Generate a pulse signal , the generated rules are as follows:

[0095] ;

[0096] ;

[0097] ;

[0098] in Indicates that at present The membrane potential state of all neurons at the moment is 0 initially; Indicates that at present Time pulse signal; Process each element of the input vector; determine whether the corresponding neuron exceeds the threshold , if it exceeds the threshold, it takes 1, otherwise it takes 0; in the formula Threshold , so as to better simulate the situation in which the membrane voltage of biological neurons drops after firing an action potential.

[0099] In step S2, the observation data is converted by inputting the observation information of the robot arm and the target component in the scene into an encoder.

[0100] S3. Design a pulse neural network module with dynamic threshold based on the circuit leakage-integration-discharge working principle, use the obtained pulse signal to input into the module, extract features through the pulse neural layer therein, and output the final pulse activity;

[0101] As a preferred implementation of step S3, in step S3, the pulse neural layer includes two hidden layers and one output layer, and the number of pulse neurons is 256, 256, and 90 respectively. Figure 2 shown.

[0102] More specifically, in step S3, a pulse neural network module with a dynamic threshold based on the circuit leakage-integration-discharge working principle is designed, the obtained pulse signal is input into the module, the features are extracted through the pulse neural layer therein, and the final pulse activity is output. The specific process includes the following steps:

[0103] S31, any pulse neuron current ,in Indicates the number of layers of the neural network where the neuron is located, Indicates that the layer The update rule of neurons is as follows:

[0104] ;

[0105] The update takes into account the leaky nature of neurons, using Represents the current decay rate. The current decays naturally when there is no new input, but is also affected by new input signals. represents a linear layer used to process pulse signals. Indicates that at present Moment The first layer of the neural network The impulse signal of each neuron;

[0106] S32, any pulse neuron model voltage The update rules are as follows:

[0107] ;

[0108] Represents the firing threshold of the neuron. The voltage accumulation process simulates the change of the neuron membrane potential, which is the key process for the neuron to prepare to fire a spike.

[0109] S33, discharge threshold Based on the current output of the neuron , membrane potential V and discharge threshold The neurons themselves are dynamically updated in time. The discharge activity triggers, that is, the self-driven adaptive threshold is expressed as:

[0110] ;

[0111] ;

[0112] in represents the update rate, is the average firing rate of the neuron, is a small positive number to prevent division by zero; represents the output of the neuron, which is expressed as follows:

[0113] ;

[0114] in, is the Dirac delta function, indicating whether the spike is at time trigger, is the response intensity;

[0115] S34, any pulse neuron pulse signal The update rules are as follows:

[0116] ;

[0117] Process each element of the input vector to determine whether the corresponding neuron exceeds the threshold If it exceeds the threshold, it takes 1, otherwise it takes 0. This step simulates the action potential discharge of biological neurons when the voltage reaches the threshold.

[0118] S4. Design a group decoding module to convert the pulse activity output by the pulse neural layer into a more intuitive action space expression through the group decoding layer;

[0119] As a preferred implementation of step S4, in step S4, the pulse activity output by the pulse neural layer is converted into a continuous action space through one-dimensional convolution and activation function to realize autonomous motion planning of the robotic arm.

[0120] S5. Design a pulse hybrid reinforcement learning SAC model. In the policy network Actor, the pulse encoding module, pulse neural network module and group decoding module are combined. In the value network Critic, the DNN deep neural network is used. The pulse hybrid reinforcement learning SAC model is used to optimize the parameters in each network to guide the robot arm to complete the target component assembly task, such as Figure 4 As shown;

[0121] As a preferred implementation of step S5, the specific process of step S5 includes the following steps:

[0122] S51, inputting the observation value information, action information and parameter value processed by the group decoding module into the strategy network to obtain the corresponding logarithmic probability of the action and the entropy information of the action;

[0123] S52, the value network includes two critic networks, each critic network includes an MLP multi-layer perceptron, each MLP multi-layer perceptron (such as Figure 3The layers 1 and 2 shown in the figure are composed of three fully connected layers, with an input dimension of 73, and the final output dimension through the output layer is 1. The observation value and action information obtained by the encoder and group decoding module of the policy network are respectively calculated by the value network Critic to obtain the Q value, and the action is evaluated by the Q value, and the Q value can be further fed back to the policy network to improve its strategy;

[0124] S53, input the pulse hybrid reinforcement learning SAC model through the observation value, action information, reward value, and next observation value information, use the mean square error to calculate the loss of the two Q networks in the value network to calculate the total critic loss, perform back propagation based on the obtained critic loss value to calculate the gradient of the network parameters, and use the optimizer to update these parameters; the observation value and action information obtained by the encoder and group decoding module of the policy network are respectively input into the value network, and the calculated minimum Q value is used as part of the actor loss of the policy network, and then the loss entropy is obtained according to the policy entropy and temperature parameter, the actor loss and the loss entropy are added to obtain the total actor loss, and back propagation is also performed to calculate the gradient of the policy network parameters, and the optimizer is used to update these parameters;

[0125] S54. During the training process, the parameter updates of the value network and the policy network are performed alternately, and the updated optimized actions are deployed to the robotic arm and target parts in the scene, so as to realize the task of assembling the target parts by the robotic arm in the scene.

[0126] In summary, this study provides a single robot arm motion planning method based on pulse hybrid reinforcement learning for assembly tasks. This method significantly reduces energy consumption during system operation. In this way, this study aims to find a set of optimal actions with low energy consumption for the robot arm to adapt to energy-constrained operating environments.

[0127] In the description of this specification, the description with reference to the terms "one embodiment", "some embodiments", "example", "specific example", or "some examples" means that the specific features, structures, materials or characteristics described in conjunction with the embodiment or example are included in at least one embodiment or example of the present application. Moreover, the specific features, structures, materials or characteristics described may be combined in any one or more embodiments or examples in a suitable manner. In addition, those skilled in the art may combine and combine different embodiments or examples described in this specification and the features of different embodiments or examples, unless they are contradictory.

[0128] The logic and / or steps represented in the flowchart or otherwise described herein, for example, can be considered as an ordered list of executable instructions for implementing logical functions, which can be embodied in any computer-readable medium for use by an instruction execution system, apparatus or device (such as a computer-based system, a system including a processor or other system that can fetch instructions from an instruction execution system, apparatus or device and execute instructions), or used in combination with these instruction execution systems, apparatuses or devices.

[0129] The above implementation methods have been described in detail. Specific examples are used herein to illustrate the principles and implementation methods of the present invention. The description of the above embodiments is only used to help understand the method of the present invention and its core idea. At the same time, for those skilled in the art, according to the idea of ​​the present invention, there will be changes in the specific implementation methods and application scope. In summary, the content of this specification should not be understood as a limitation on the present invention.

Claims

1. Single robot motion planning method for assembly tasks based on pulse hybrid reinforcement learning, It is characterized in that The following steps are involved: S1. For assembly tasks, the robot arm motion is divided into n stages, and a dense reward function is designed for the end point of each stage. S2. Using the observation information and action information dimensions of the robot arm and the target parts in the scene, design a pulse coding module so that each dimension of the observation data of the robot arm and the target parts is encoded by a neuron group, so that these observation data can be encoded into pulse signals suitable for processing by the pulse neural network through the pulse coding layer; S3. Design a pulse neural network module with dynamic threshold based on the circuit leakage-integration-discharge working principle, use the obtained pulse signal to input into the module, extract features through the pulse neural layer therein, and output the final pulse activity; S4. Design a group decoding module to convert the pulse activity output by the pulse neural layer into a more intuitive action space expression through the group decoding layer; S5. Design a pulse hybrid reinforcement learning SAC model. In the policy network Actor, the above-mentioned pulse encoding module, pulse neural network module and group decoding module are combined. In the value network Critic, the DNN deep neural network is used. The pulse hybrid reinforcement learning SAC model is used to optimize the parameters in each network to guide the robot arm to complete the assembly task.

2. The single robot arm motion planning method for assembly tasks based on pulse hybrid reinforcement learning according to claim 1, Features: In step S1, the movement of the robot arm is divided into n stages, specifically including: dividing the movement of the robot arm into 8 stages, namely: initial stage, arrival stage, descent stage, grasping stage, lifting stage, alignment stage, movement stage and fine-grained movement stage.

3. The single robot arm motion planning method for assembly tasks based on pulse hybrid reinforcement learning according to claim 2, Features: The dense reward function in step S1 specifically includes: In order to grasp the new target part, the reward given when the end effector moves to the initial position is expressed as , The reward is calculated by reducing the Euclidean distance between the actuator and the target part position, and the reward is proportional to the negative distance between the end-effector gripper position and the initial position; The reward given when the end effector moves above the target part is expressed as , also based on Euclidean distance calculation; the reward is proportional to the negative distance between the end effector gripper position and a point 5 cm above the gripper pick-up point; The reward given when the end effector is lowered onto the target part is expressed as , the reward is calculated based on the proximity of the end effector to the target part, and the reward is proportional to the negative distance between the end effector gripper position and the target grasping point; The reward given when the target part is correctly grasped is expressed as , the reward is calculated based on the position accuracy of the end effector and the correctness of the grasping action, and the reward is proportional to the force applied by the robot gripper The reward when upgrading the target component is expressed as , calculated based on the distance difference between the actual position of the target part and the target position, the reward is proportional to the negative distance between the position of the grasped target part and the position where the target part is lifted; The reward when the target part is aligned with the target connector is expressed as The reward is proportional to the cosine similarity between the upper vector and the front vector of the two connectors. The connector refers to the specific part of the target component that the robot needs to align and operate. If the position and angle of the target component are accurately aligned without contacting the target component, positive incentives are given, and penalties are imposed when the target component is deviated; The reward for aligning a target part held by the end effector with another target part is roughly expressed as , the reward is proportional to the negative distance between the connector of the clamped target part and the point 5 cm above the connector of the other target part, and the reward is proportional to the cosine similarity between the top vector and the front vector of the two connectors. All connectors are marked with aligned top and front vectors; The reward for fine-tuning the target component so that it is perfectly aligned with the connector is expressed as ,In addition, when the target part is connectable, a reward is provided based on the activation of the ,connection action; The reward for the alignment of the up vector and the front vector of the end effector is expressed as ; The penalty given according to the state of the actuator is expressed as , at the stage when the grabber should be closed, if the grabber is not closed, a penalty of -1 is imposed; The control penalty is expressed as , penalizes excessive actions, and the penalty is the action vector norm×(-0.001); The penalty for moving a non-target part is expressed as ; Therefore, the total reward .

4. The single robot arm motion planning method for assembly tasks based on pulse hybrid reinforcement learning according to claim 1, Features: In step S2, the observation data is converted by inputting the observation information of the robot arm and the target component in the scene into an encoder.

5. The single robot arm motion planning method for assembly tasks based on pulse hybrid reinforcement learning according to claim 1, Features: The observation information and action information dimensions of the robot arm and the target component in step S2 specifically include: The observation information is divided into robot arm observation values ​​and target component observation values. The robot arm observation values ​​include the position of each joint of the robot arm, the speed of each joint of the robot arm, the joint position of the gripper, the position of the end effector, the quaternion of the end effector, the linear velocity of the end effector, and the angular velocity of the end effector. Therefore, the observation value of the robot arm is represented by a 7+7+2+3+4+3+3=29-dimensional data. The target component observation value includes the position and posture of the target component. The position is represented by 3-dimensional data, and the posture is represented by quaternion, that is, 4 dimensions. When there are n target components in the task, the observation data of all target components are represented by n×(3+4)=7n-dimensional data, so the total observation data is represented by 29+7n-dimensional data; The motion information of the robot arm includes the speed of each joint of the robot arm, as well as two additional functions of selection and connection. Therefore, the motion information is represented by a 7+1+1=9-dimensional data.

6. The single robot arm motion planning method for assembly tasks based on pulse hybrid reinforcement learning according to claim 5, Features: In step S2, a pulse coding module is designed so that each dimension of the observation data of the robot arm and the target component is encoded by a neuron group, so that these observation data are encoded into pulse signals suitable for pulse neural network processing through the pulse coding layer. The specific process includes the following steps: S21: For the robot arm and the target part in the scene at time Observational data at Any dimension in Data , ; First, the observed data is transformed into Transformed into the response width of each neuron to the input observation data ,in represents the response center of each neuron, It represents the response width of each neuron, both of which are trainable parameters; S22: Based on response width Generate a pulse signal , the generated rules are as follows: ; ; ; in Indicates that at present The membrane potential state of all neurons at the moment is 0 initially; Indicates that at present Time pulse signal; Process each element of the input vector; determine whether the corresponding neuron exceeds the threshold , if it exceeds the threshold, it takes 1, otherwise it takes 0; in the formula Threshold , so as to better simulate the situation in which the membrane voltage of biological neurons drops after firing an action potential.

7. The single robot arm motion planning method for assembly tasks based on pulse hybrid reinforcement learning according to claim 1, Features: In step S3, the spiking neural layer includes two hidden layers and one output layer, and the number of spiking neurons are 256, 256, and 90 respectively.

8. The single robot arm motion planning method for assembly tasks based on pulse hybrid reinforcement learning according to claim 1, Features: In step S3, a pulse neural network module with a dynamic threshold based on the circuit leakage-integration-discharge working principle is designed, the obtained pulse signal is input into the module, the features are extracted through the pulse neural layer therein, and the final pulse activity is output. The specific process includes the following steps: S31, any pulse neuron current ,in Indicates the number of layers of the neural network where the neuron is located, Indicates that the layer The update rule of neurons is as follows: ; The update takes into account the leaky nature of neurons, using Represents the current decay rate. The current decays naturally when there is no new input, but is also affected by new input signals. represents a linear layer used to process pulse signals. Indicates that at present Moment The first layer of the neural network The impulse signal of each neuron; S32. The update rule of any pulse neuron model voltage is as follows: ; Represents the firing threshold of the neuron. The voltage accumulation process simulates the change of the neuron membrane potential, which is the key process for the neuron to prepare to fire a spike. S33, discharge threshold Based on the current output of the neuron , membrane potential and discharge threshold The neurons themselves are dynamically updated in time. The discharge activity triggers, that is, the self-driven adaptive threshold is expressed as: ; ; in represents the update rate, is the average firing rate of the neuron, is a small positive number to prevent division by zero; represents the output of the neuron, which is expressed as follows: ; in, is the Dirac delta function, indicating whether the spike is at time trigger, is the response intensity; S34. The update rule of any pulse neuron pulse signal is as follows: ; in, Process each element of the input vector to determine whether the corresponding neuron exceeds the threshold If it exceeds the threshold, it takes 1, otherwise it takes 0. This step simulates the action potential discharge of biological neurons when the voltage reaches the threshold.

9. The single robot arm motion planning method for assembly tasks based on pulse hybrid reinforcement learning according to claim 1, Features: In step S4, the pulse activity output by the pulse neural layer is converted into a continuous action space through one-dimensional convolution and activation function to realize the autonomous motion planning of the robotic arm.

10. The single robot arm motion planning method for assembly tasks based on pulse hybrid reinforcement learning according to claim 1, Features: The specific process of step S5 includes the following steps: S51, inputting the observation value information, action information and parameter value processed by the group decoding module into the strategy network to obtain the corresponding logarithmic probability of the action and the entropy information of the action; S52. The value network includes two critic networks, each of which includes an MLP multilayer perceptron. Each MLP multilayer perceptron consists of three fully connected layers, with an input dimension of 38+7n and a final output dimension of 1. The observation values ​​and action information obtained by the encoder and group decoding modules of the policy network are respectively calculated through the value network Critic to obtain the Q value, and the action is evaluated through the Q value, which can be further fed back to the policy network to improve its strategy. S53, input the pulse hybrid reinforcement learning SAC model through the observation value, action information, reward value, and next observation value information, use the mean square error to calculate the loss of the two Q networks in the value network to calculate the total critic loss, perform back propagation based on the obtained critic loss value to calculate the gradient of the network parameters, and use the optimizer to update these parameters; the observation value and action information obtained by the encoder and group decoding module of the policy network are respectively input into the value network, and the calculated minimum Q value is used as part of the actor loss of the policy network, and then the loss entropy is obtained according to the policy entropy and temperature parameter, the actor loss and the loss entropy are added to obtain the total actor loss, and back propagation is also performed to calculate the gradient of the policy network parameters, and the optimizer is used to update these parameters; S54. During the training process, the parameter updates of the value network and the policy network are performed alternately, and the updated optimized actions are deployed to the robotic arm and target parts in the scene, so as to realize the task of assembling the target parts by the robotic arm in the scene.