A limb motion emotion recognition method of a humanoid robot
By constructing a method for recognizing the emotions in humanoid robot body movements, and by utilizing emotion and body movement encoding and neural network optimization, the shortcomings of humanoid robot body movement emotion recognition are solved, and more natural and accurate emotion expression and interaction effects are achieved.
Patent Information
- Application Number
- CN202411514657.X
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2024-10-29
- Publication Date
- 2025-12-26
- Estimated Expiration
- 2044-10-29
AI Technical Summary
Existing technologies have shortcomings in recognizing emotions in humanoid robot body movements. The lack of effective computational models makes it difficult to match corresponding emotional needs, thus affecting the human-computer interaction effect.
A method for emotion recognition of humanoid robot body movements is constructed. By encoding emotion and body movements, optimizing the backpropagation neural network topology and particle swarm optimization algorithm, a body movement emotion recognition model is established to realize the emotion recognition and prediction of humanoid robot body movements.
It achieves emotion recognition of humanoid robot body movements, enhances human emotional understanding of robot body movements, improves human-computer interaction, and especially enhances the convenience of interaction at a distance.
Smart Images

Figure CN119380414B_ABST
Abstract
Description
TECHNICAL FIELD
[0001] The present application relates to the field of robots, in particular to a limb action emotion recognition method of a humanoid robot. BACKGROUND
[0002] With the rapid development of new generation information technology, humanoid robots are widely used in public life, public service, industrial production and other environments. Humanoid robots have similar appearance to humans and also need to have similar emotional expression ability. Its limb action can also express certain emotions as human limb action. Robot limb action emotion plays an important role in improving human-robot emotional interaction and enhancing emotional understanding. Especially in a long distance (i.e. the distance corresponding to the situation where a person cannot see the robot's expression and cannot hear the robot's voice, but can see the humanoid robot's action), the emotion expressed by the limb action is more easily perceived by the person.
[0003] Limb action is an indispensable part of human emotional expression, and rich emotional information can be conveyed through body posture. The existing technology still has obvious deficiencies in limb action emotion recognition. How to recognize the emotional state expressed by the limb action is a challenge. There is a lack of computational model support reflecting the limb action of the humanoid robot and the corresponding emotional state, which makes it difficult to match the corresponding emotion when designing the limb action of the humanoid robot, and it is also difficult to match the appropriate limb action expression of the humanoid robot for the clear emotional needs.
[0004] In order to solve the above problems, a limb action emotion recognition method of a humanoid robot is proposed, which can enhance human emotional understanding of robot limb action and provide convenience for human and humanoid robot interaction at a long distance; and the humanoid robot can express emotions more naturally and accurately, improving the effect of human-computer interaction. SUMMARY
[0005] The technical problem to be solved by the present application is to provide a limb action emotion recognition method of a humanoid robot to solve the above-mentioned problems of the prior art. The limb action emotion recognition method of the present application constructs a nonlinear mapping of the limb action of the humanoid robot and the emotion type, realizes the emotion recognition of the limb action of the humanoid robot, enhances the emotional understanding of the human to the robot limb action, and provides convenience for the interaction between the human and the humanoid robot.
[0006] To achieve the above technical purpose, the technical scheme adopted by the present application is as follows:
[0007] A limb action emotion recognition method of a humanoid robot, comprising the steps of emotion and limb action coding, limb action emotion recognition model construction, and limb action emotion prediction.
[0008] Wherein, the emotion and body movement coding step comprises:
[0009] Step S101, the emotion expressed by the humanoid robot is classified into multiple categories;
[0010] Step S102, a binary trigger mechanism is used to code the emotion categories in step S101;
[0011] Step S103, the body movement of the humanoid robot is divided into three units, namely the movement part, the movement direction and the movement mode;
[0012] Step S104, the body movement part of the humanoid robot is regionally coded;
[0013] Step S105, the body movement direction of the humanoid robot is directionally coded;
[0014] Step S106, the body movement mode of the humanoid robot is mode-coded;
[0015] Step S107, the camera captures the body movement of the humanoid robot, sets the time parameter, and extracts the key frame of the body movement of the humanoid robot;
[0016] Step S108, a binary trigger mechanism is used to code the body movement represented by the key frame in combination with step S104, step S105 and step S106;
[0017] Wherein, the body movement emotion recognition model construction step comprises:
[0018] Step S201, a back propagation neural network topology structure is constructed;
[0019] Step S202, a logistic regression logsig is used as a neural network activation function;
[0020] Step S203, the neural network is optimized based on a particle swarm algorithm to obtain the optimal solution of the neural network weight and bias;
[0021] Step S204, the body movement coding obtained in step S108 is used as the input of the neural network, and the emotion category coding in step S102 is used as the output of the neural network, and the neural network is trained;
[0022] Step S205, the RMSProp algorithm is used to optimize the adaptive learning rate, and then the neural network weight and bias optimal solution are updated, and when the mean square error reaches the target error or the iteration number reaches the upper limit, the optimal neural network model, i.e. the body movement emotion recognition model, is obtained;
[0023] Wherein, the body movement emotion prediction step comprises:
[0024] Step S301, using the method of step S107 to extract key frames of the predicted limb movement of the humanoid robot, and using the method of step S108 to encode the limb movement represented by the key frames;
[0025] Step S302, taking the limb movement encoding obtained in step S301 as the input of the limb movement emotion recognition model in S205;
[0026] Step S303, the limb movement emotion recognition model outputs the corresponding emotion category encoding, and decodes the emotion category encoding to obtain the predicted emotion category of the humanoid robot.
[0027] As a further improved technical solution of the present application, the step S101 specifically comprises: dividing the emotions expressed by the humanoid robot into six categories, and the six categories are happiness, surprise, sadness, disgust, anger and fear.
[0028] As a further improved technical solution of the present application, in step S201, the back propagation neural network topology is: input layer, single hidden layer and output layer; wherein the input layer contains nodes of limb movement region encoding, direction encoding and mode encoding of the humanoid robot; the output layer contains nodes of the six emotion categories in step S01; the number of nodes in the single hidden layer is determined under the condition that the mean square error of the neural network is minimum.
[0029] As a further improved technical solution of the present application, the step S203 specifically comprises:
[0030] Step S2031, initializing the particle swarm, initializing the position and speed of the particles; each particle represents a combination of weights and biases of the neural network;
[0031] Step S2032, using the mean square error of the neural network as the fitness function of each particle;
[0032] Step S2033, updating the local optimal solution and the global optimal solution of the particles;
[0033] Step S2034, updating the position and speed of the particles according to the local optimal solution and the global optimal solution of the particles;
[0034] Step S2035, when the mean square error reaches the target error or the number of iterations reaches the upper limit, outputting the current global optimal solution, and obtaining the optimal neural network weights and biases.
[0035] As a further improved technical solution of the present application, the step S2032 specifically comprises:
[0036] The mean square error of the neural network is used as the fitness function of each particle, and the fitness of each particle is determined by calculating the mean square error between the output of the neural network and the target value, for evaluating the pros and cons of the current position of the particle; the smaller the mean square error is, the higher the fitness is, indicating that the solution of the particle is closer to the global optimal solution;
[0037] To ensure the effectiveness of the search, the speed limit formula is:
[0038] v s (t)=max(min(v s (t),v max ),v min ) (1);
[0039] Wherein, v max =0.5, v min =-0.5; v s (t) represents the speed of the tth iteration.
[0040] As a further improved technical solution of the application, the step S2033 specifically comprises:
[0041] After each iteration, the fitness of the current particle is compared with the individual optimal solution of the particle; if the current fitness is better than the individual optimal solution, the individual optimal solution of the particle is updated; at the same time, the individual optimal solution of all particles is compared with the global optimal solution, and if the individual optimal solution of a certain particle is better than the current global optimal solution, the global optimal solution is updated.
[0042] As a further improved technical solution of the application, the step S205 specifically comprises:
[0043] In each iteration, the error and gradient of each layer of the neural network are calculated;
[0044] Wherein the error of each layer of the neural network is:
[0045] δ (i) =logsig′(z (i) )·b (i) δ (i+1) (2);
[0046] δ (i) Indicates the error of the ith layer, z (i) Indicates the net activation value of the ith layer, b (i) Indicates the bias of the ith layer, and δ (i+1) Indicates the error of the i+1th layer.
[0047] The updating step of each parameter is dynamically adjusted by performing exponential weighted moving average on the gradient square; when the mean square error reaches the target error or the iteration number reaches the upper limit, the current optimized neural network model, i.e., the optimal neural network model, is outputted;
[0048] The exponential weighted moving average of the gradient square is:
[0049] G t = βG t-1 + (1-β)g t g t (3);
[0050] Wherein, G t represents the exponential weighted moving average of the gradient square of the tth iteration, β = 0.9 is the decay rate, g t is the gradient of the tth iteration, and t is the iteration number.
[0051] The beneficial effects of the present application are:
[0052] (1) The coding rule of the action input and the emotion output state of the human-imitating robot limb action emotion recognition model realizes the binary coding expression of the input and output of the human-imitating robot limb action recognition, and can serve as the basis of the human-imitating robot limb action emotion recognition calculation model.
[0053] (2) The construction of the topology structure and the training process of the human-imitating robot limb action emotion recognition model realizes the nonlinear mapping of the human-imitating robot limb action and the emotion type, and realizes the emotion recognition of the human-imitating robot limb action.
[0054] (3) After the human-imitating robot limb action is coded, the emotion prediction of the action can be realized through the limb action emotion recognition model, the emotion understanding of the human to the robot limb action is enhanced, and the convenience for the human and the human-imitating robot to interact at a long distance (the long distance refers to the distance that the camera and the user cannot clearly see the robot expression and cannot clearly hear the robot voice, but the camera and the user can see the action of the human-imitating robot) is provided. The human-imitating robot can express emotions more naturally and accurately, and the effect of human-computer interaction is improved. BRIEF DESCRIPTION OF DRAWINGS
[0055] Figure 1 is a human-imitating robot limb action key frame extraction sample diagram provided by the embodiment of the present application.
[0056] Figure 2 is a human-imitating robot limb action emotion recognition model construction and training flowchart provided by the embodiment of the present application.
[0057] Figure 3A limb action emotion recognition model neural network topology structure diagram of a humanoid robot is provided in the embodiment of the present application.
[0058] Figure 4 A limb action emotion prediction flow chart of a humanoid robot is provided in the embodiment of the present application. DETAILED DESCRIPTION
[0059] The specific embodiments will now be described in more detail with reference to the accompanying drawings. The described features, structures, or characteristics can be applicable to any one of the humanoid robot emotion recognitions.
[0060] In the following description, numerous specific details are provided to give a full understanding of the method of the present application. The flow charts shown in the drawings are not necessarily inclusive of all content and operation steps. For example, some steps / operations can be decomposed, some steps / operations can be combined or partially combined, and thus the actual implementation order can be changed according to the actual situation.
[0061] The embodiment provides a limb action emotion recognition method of a humanoid robot, comprising an emotion and limb action coding step, a limb action emotion recognition model construction and training step, and a limb action emotion prediction step.
[0062] The emotion and limb action coding step comprises:
[0063] S101, the emotions / feelings expressed by the robot are mainly divided into six categories, namely happy, surprised, sad, disgusted, angry and frightened, as shown in the output state set of Table 1.
[0064] Table 1: input state set and output state set.
[0065]
[0066] S102, a binary trigger mechanism is adopted, and the emotion category coding is performed in combination with S101. The robot expression emotion sample is as shown in the table. Figure 1 The emotion state expressed by the sample robot is happy, and the binary coding of the emotion state is as shown in the output state coding of Table 2.
[0067] Table 2: action input state coding and action output state coding.
[0068]
[0069] S103, the limb action of the humanoid robot is divided into three units, namely the movement part, the movement direction and the movement mode.
[0070] S104. Encode the moving parts of the humanoid robot's limbs into regions, as shown in Table 1, which represents the moving parts of the input state set. The regions to be encoded can be selected as either partition 1 or partition 2. Partition 1 and partition 2 respectively consider the bipedal and wheeled types of the humanoid robot.
[0071] Specifically, when the humanoid robot is a bipedal humanoid robot, the movement parts of the humanoid robot's limbs are region-coded to obtain the head, torso, right lower limb, left lower limb, right arm, and left arm. When the humanoid robot is a wheel-legged humanoid robot, the movement parts of the humanoid robot's limbs are region-coded to obtain the head, torso, lower limbs, right arm, and left arm.
[0072] S105. Encode the limb movement direction of the humanoid robot. As shown in Table 1, the movement direction of the input state set.
[0073] Specifically, when the humanoid robot is a bipedal or wheel-legged humanoid robot, the direction of the humanoid robot's limb movement is encoded to obtain left, right, forward, backward, up, down, inward, and outward.
[0074] S106. Encode the limb movement patterns of the humanoid robot. As shown in Table 1, the movement patterns of the input state set are as follows.
[0075] Specifically, when the humanoid robot is a bipedal or wheel-legged humanoid robot, the limb movement patterns of the humanoid robot are encoded into rotation, rocking, vertical movement, extension, approach, and bending. Among them, approach refers to the mutual approach between two or more limbs such as the right lower limb, left lower limb, right arm, and left arm.
[0076] S107. The camera captures the robot's limb movements. A time parameter of 1 second is set to extract keyframes of the robot's limb movements. The time parameter is set so that the extracted keyframes can separately display the robot's horizontal and vertical movement states. Example of movement: Figure 1 As shown, the body movement description of this example is: both feet and left hand are extended downwards, and the right hand is bent outwards and upwards.
[0077] S108. A binary triggering mechanism is adopted, combining S104, S105, and S106 to perform binary encoding of the limb movements represented by the keyframes. Taking a moving part as an example, the part is coded as 1 when triggered and 0 when not triggered. The binary encoding of this action example is shown in Table 2.
[0078] The steps for constructing and training a body movement emotion recognition model are as follows: Figure 2 As shown, it includes:
[0079] S201. Construct the backpropagation neural network topology, such as...Figure 3 The input encoding of the neural network contains 20 nodes, which correspond to the partition 1, the moving direction and the moving mode of the biped robot, i.e. the nodes of the region encoding, the direction encoding and the mode encoding. The output encoding of the neural network contains 6 nodes, which correspond to the six emotional state categories. The number of hidden layer nodes is determined according to the input encoding and the output encoding of the neural network under the condition of the minimum neural network error. When the number of hidden layer nodes is 13, the network error is minimum, and this value is exactly half of the sum of the number of input layer nodes and the number of output layer nodes. Therefore, the back propagation neural network structure corresponding to the design of the biped robot is determined as follows: the input layer has 20 nodes, the single hidden layer has 13 nodes, and the output layer has 6 nodes. The back propagation neural network structure corresponding to the design of the wheel-legged robot is determined as follows: the input layer has 19 nodes, and the output layer has 6 nodes.
[0080] In S202, the logistic function is used as the activation function of the neural network, so that the output of the neural network can be mapped in the interval (0, 1). The weights and biases of the neural network are initialized. The following formula (1) is used to describe the calculation process of the activation value of a layer in the neural network. In the formula, a (i) represents the activation value of the i-th layer.
[0081] a (i) = log sig (W (i) a (i-1) + b (i) ) (1);
[0082] The formula (2) is used to calculate the net activation value of the i-th layer in the neural network, i.e. to complete part of the forward propagation. Specifically, the formula performs a nonlinear mapping on the output z (i-1) of the previous layer, then multiplies it with the weight matrix W (i) of the current layer, and adds the bias b (i) of the current layer, so as to obtain the net activation value z (i) of the current layer.
[0083] z (i) = W (i) log sig (z (i-1) ) + b (i) (2);
[0084] In S203, the particle swarm is initialized, and each particle represents a combination of the weights and biases of the neural network. The particle velocity controls the corresponding motion state in the search space. In the particle space, the position matrix L and the velocity matrix v of the particles are as follows:
[0085]
[0086] where s is the particle number, t is the iteration number, and ps pBest, p g gBest. c1 and c2 are learning factors, r1 and r2 are random factors, and ω is the inertia weight. The new position of a particle is obtained by accumulating the current position and the updated velocity . This means that the particle will move to a new position according to its current velocity, gradually exploring the optimal solution. This formula allows the particle to adjust its position in each iteration to constantly approach the optimal solution under the guidance of the individual optimal solution and the global optimal solution.
[0087] S204, design the fitness function of the particle according to the mean square error of the neural network, and calculate its fitness. The fitness of each particle is determined by calculating the mean square error (MSE) between the neural network output and the target value, which is used to evaluate the pros and cons of the current position of the particle. The smaller the MSE, the higher the fitness, indicating that the solution of the particle is closer to the global optimal solution. To ensure the effectiveness of the search, the velocity limit formula is:
[0088] v s (t) = max(min(v s (t), v max ), v min ) (5) ;
[0089] where v max = 0.5 and V min = -0.5.
[0090] S205, update the local optimal solution and the global optimal solution of the particle. After each iteration, compare the fitness of the current particle with the individual optimal solution (pBest) of the particle. If the current fitness is better than the individual optimal solution, update the individual optimal solution of the particle. At the same time, compare the individual optimal solution of all particles with the global optimal solution (gBest), and if the individual optimal solution of a particle is better than the current global optimal solution, update the global optimal solution. In this way, the particle swarm algorithm will gradually approach the optimal solution in each iteration.
[0091] S206, update the position and velocity of the particle. The velocity and position of the particle need to be updated dynamically in each iteration. Specifically, the update of the velocity is determined by the difference between the previous velocity of the particle, the individual optimal solution and the global optimal solution, to balance the exploration and exploitation ability. The inertia weight is used to control the degree of retention of the previous velocity of the particle, while the learning factor controls the degree of approach to the optimal solution. After the velocity is updated, the position is updated by accumulating the current position and velocity, so that the particle constantly adjusts its position in the search space to approach the optimal solution.
[0092] S207, output the global optimal solution under the condition of mean square error convergence or maximum iteration number, and obtain the optimal solution of neural network weight and bias. When the mean square error (MSE) reaches the preset target error or the iteration number reaches the upper limit, the algorithm stops, and the current global optimal solution is output, and the optimal neural network weight and bias are obtained.
[0093] S208, using the limb action code of S108 as the neural network input and the emotion category code of S102 as the neural network output, training the neural network. The derivative of each layer parameter of the neural network is calculated.
[0094]
[0095] wherein, represents the loss function, δ (i) is the error of the i-th layer.
[0096] S209, calculate the error and gradient of each layer of the neural network. During the back propagation process, the error and gradient are calculated layer by layer. The error of each layer is calculated by the derivative of the logsig function, which is used to quantify the contribution of the output of this layer to the loss function. Based on these errors, the gradient of the weight and bias is further calculated, which provides the basis for subsequent optimization update. In each iteration, the error and gradient of each layer of the neural network are calculated, and the specific formula is as follows:
[0097] δ (i) = logsig'(z (i) )·b (i) δ (i+1) (8);
[0098] S210, update the neural network weight and bias by calculating the exponentially weighted moving average of the gradient square, and obtain the optimized neural network model under the condition of minimizing the mean square error or reaching the maximum iteration number. In each iteration, the update step of each parameter is dynamically adjusted by calculating the exponentially weighted moving average of the gradient square, to ensure the stable convergence of the model during the training process. When the mean square error reaches the target error or the iteration number reaches the upper limit, the current optimized neural network model is output.
[0099] The exponentially weighted moving average of the gradient square is calculated by the following formula, and the parameters are updated:
[0100] G t = βG t -1 + (1-β)gtgt (9);
[0101] wherein, G t represents the exponentially weighted moving average of the gradient square. β = 0.9 is the decay rate, g tis the current gradient, i is the iteration number. When the mean square error reaches the target or reaches the maximum iteration number, the optimal neural network model weight and bias are output.
[0102] The limb action emotion prediction step, as shown in Figure 4
[0103] S301, the camera captures the limb action of the humanoid robot to be measured, and performs key frame extraction of the limb action; and the binary coding of the limb action represented by the key frame of the humanoid robot to be measured is performed according to S108.
[0104] S302, the limb action coding of S301 is used as the input of the optimal neural network model of S210.
[0105] S303, the mean square error under the condition of the maximum iteration number is obtained, and the emotion category decoding of the humanoid robot limb action is performed to obtain the predicted emotion state of the humanoid robot.
[0106] The embodiments described herein can be implemented in software in combination with necessary hardware, or through software, and therefore, the technical solution according to the embodiments of the present application can be embodied in the form of "robot + host computer system". The product system of the software and hardware combination can capture the real-time motion of the humanoid robot through the camera, then send the captured information to the host computer system, execute the method according to the embodiments of the present application in the host computer system, judge the emotion category expressed by the humanoid robot limb action through the model, and finally inform the user of the emotion category through voice. The technical solution according to the embodiments of the present application can also be embodied in the form of a software product. The software product can exist in a non-volatile storage medium, such as a mobile hard disk, a U disk, or in a network, such as a personal computer, a server, a touch terminal, and execute the method according to the embodiments of the present application.
[0107] The present application is intended to cover any variations, uses, or adaptive changes of the present application. These variations, uses, or adaptive changes follow the general principles of the present application and include known attempts or conventional techniques in the art that are not disclosed in the present application.
[0108] It should be understood that the present application is not limited to the detailed processes described and shown in the drawings, and various modifications and adjustments can be made without departing from the scope thereof.
Claims
1. A method for recognizing limb motion emotion of a humanoid robot, characterized in that: The method comprises the steps of emotion and body movement coding, body movement emotion recognition model construction, and body movement emotion prediction. The emotion and body movement coding step comprises the following steps: Step S101: classifying the emotions expressed by the humanoid robot into multiple categories; Step S102: using a binary trigger mechanism to code the emotion categories in step S101; Step S103: dividing the body movements of the humanoid robot into three units, namely movement parts, movement directions, and movement modes; Step S104: regionally coding the body movement parts of the humanoid robot; Step S105: directionally coding the body movement directions of the humanoid robot; Step S106: mode coding the body movement modes of the humanoid robot; Step S107: capturing the body movements of the humanoid robot by a camera, setting a time parameter, and extracting key frames of the body movements of the humanoid robot; Step S108: using a binary trigger mechanism to code the body movements represented by the key frames in combination with steps S104, S105, and S106; The body movement emotion recognition model construction step comprises the following steps: Step S201: constructing a back propagation neural network topology; Step S202: using a logistic regression logsig as a neural network activation function; Step S203: optimizing the neural network based on a particle swarm algorithm to obtain the optimal solution of the weights and biases of the neural network; Step S204: using the body movement coding obtained in step S108 as the input of the neural network and using the emotion category coding in step S102 as the output of the neural network to train the neural network; Step S205: using an RMSProp algorithm to optimize the adaptive learning rate, and then updating the optimal solution of the weights and biases of the neural network, and obtaining an optimal neural network model, i.e., a body movement emotion recognition model, when the mean square error reaches a target error or the number of iterations reaches an upper limit; The body movement emotion prediction step comprises the following steps: Step S301: using the method in step S107 to extract key frames of the predicted body movements of the humanoid robot and using the method in step S108 to code the body movements represented by the key frames; Step S302: using the body movement coding obtained in step S301 as the input of the body movement emotion recognition model in step S205; Step S303: the body movement emotion recognition model outputs the corresponding emotion category coding, and the emotion category coding is decoded to obtain the predicted emotion category of the humanoid robot.
2. The limb motion and emotion recognition method of the humanoid robot according to claim 1, characterized in that: The step S101 specifically comprises: classifying the emotions expressed by the humanoid robot into six categories, namely happy, surprised, sad, disgusted, angry, and frightened.
3. The limb motion and emotion recognition method of the humanoid robot according to claim 2, characterized in that: In step S201, the back propagation neural network topology is: an input layer, a single hidden layer, and an output layer; the input layer includes nodes of the body movement region coding, direction coding, and mode coding of the humanoid robot; the output layer includes nodes of the six emotion categories in step S01; and the number of nodes in the single hidden layer is determined under the condition that the mean square error of the neural network is minimum.
4. The limb motion and emotion recognition method of the humanoid robot according to claim 1, characterized in that: The step S203 specifically comprises: Step S2031, initializing the particle swarm, initializing the position and velocity of the particles; each particle represents a combination of the weights and biases of the neural network; Step S2032, using the mean square error of the neural network as the fitness function of each particle; Step S2033, updating the local optimal solution of the particle and the global optimal solution; Step S2034, updating the position and velocity of the particle according to the local optimal solution of the particle and the global optimal solution; Step S2035, when the mean square error reaches the target error or the number of iterations reaches the upper limit, outputting the current global optimal solution, obtaining the optimal neural network weights and biases.
5. The limb motion and emotion recognition method of the humanoid robot according to claim 4, characterized in that: The step S2032 specifically includes: using the mean square error of the neural network as the fitness function of each particle, the fitness of each particle is determined by calculating the mean square error between the neural network output and the target value, for evaluating the pros and cons of the current position of the particle; the smaller the mean square error, the higher the fitness, indicating that the solution of the particle is closer to the global optimal solution; In order to ensure the effectiveness of the search, the velocity limiting formula is: v s (t) = max(min(v s (t), v max ), v min ) (1); where v max = 0.5, v min = -0.5; v s (t) denotes the velocity at the tth iteration.
6. The limb motion and emotion recognition method of the humanoid robot according to claim 4, characterized in that: The step S2033 specifically includes: After each iteration, the fitness of the current particle is compared with the individual optimal solution of the particle; if the current fitness is better than the individual optimal solution, the individual optimal solution of the particle is updated; at the same time, the individual optimal solution of all particles is compared with the global optimal solution, if the individual optimal solution of a particle is better than the current global optimal solution, the global optimal solution is updated.
7. The method of Claim 1, wherein the limb motion emotion recognition of the humanoid robot is characterized by: The step S205 specifically includes: In each iteration, the error and gradient of each layer of the neural network are calculated; The error of each layer of the neural network is: δ (i) = logsig'(z (i) ) · b (i) δ (i+1) (2); δ (i) represents the error of the i-th layer, z (i) represents the net activation value of the i-th layer, b (i) represents the bias of the i-th layer, δ (i+1) represents the error of the i+1-th layer; The update step of each parameter is dynamically adjusted by performing exponential weighted moving average on the square of the gradient; when the mean square error reaches the target error or the number of iterations reaches the upper limit, the current optimized neural network model is output, that is, the optimal neural network model; The exponential weighted moving average of the square of the gradient is: G t = βG t-1 + (1 - β)g t g t (3) where G t denotes the exponentially weighted moving average of the squared gradient of the tth iteration, β = 0.9 is the decay rate, g t is the gradient of the tth iteration, and t is the iteration number.
Citation Information
Patent Citations
Gait recognition method based on particle swarm optimization BP neural network
CN110232372A
Robot-aided system and method for diagnosis of autism spectrum disorder
US20210236032A1