Wind driven generator blade unmanned aerial vehicle inspection method based on deep reinforcement learning algorithm

Through the deep reinforcement learning algorithm and the improved TD3 algorithm, the problem of unstable drone inspections in complex wind field environments is solved, more efficient and stable wind turbine blade inspections are achieved, and maintenance costs and deviations are reduced. degree.

CN118601807APending Publication Date: 2024-09-06SOUTHEAST UNIV +1

Patent Information

Application Number
CN202410641203.2
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2024-07-29
Publication Date
2024-09-06

AI Technical Summary

Technical Problem

Existing drones used to inspect wind turbine blades in complex wind field environments are unstable, which affects the quality of image information collection and leads to high maintenance costs.

Method used

A drone inspection method based on deep reinforcement learning algorithm is used to build a reinforcement learning model, define a heuristic dynamic reward function for continuous position and energy consumption, and improve the double-delay deep deterministic policy gradient TD3 algorithm to train drones to operate in complex Achieve stable inspection in wind field environment.

Benefits of technology

It improves the adaptability and stability of the drone in complex environments, reduces maintenance costs, achieves smoother inspection paths and less deviation, and significantly improves the inspection effect.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN118601807A
    Figure CN118601807A
Patent Text Reader

Abstract

The invention discloses a wind driven generator blade unmanned aerial vehicle inspection method based on a deep reinforcement learning algorithm, and the method is suitable for an unmanned aerial vehicle blade inspection task, can guarantee the stability and robustness of an unmanned aerial vehicle in a complex environment, and completes the inspection task with the lowest energy consumption path. The method comprises the following steps: firstly, constructing a reinforcement learning model for the unmanned aerial vehicle to inspect fan blades to simulate an inspection task of the unmanned aerial vehicle in a three-dimensional space, and limiting a feasible space and an Euler angle of the unmanned aerial vehicle to prevent the unmanned aerial vehicle from intensely moving; secondly, defining a heuristic dynamic reward function including continuous position, energy consumption, task completion and obstacle avoidance so as to excite the unmanned aerial vehicle to adopt an optimal flight path; and finally, designing an improved TD3 algorithm of a convocation network structure and a priority experience playback mechanism, and improving algorithm learning efficiency. Compared with a traditional control mode, the stability and robustness of unmanned aerial vehicle inspection are improved.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present invention belongs to the technical field of unmanned aerial vehicle inspection, and specifically relates to a wind turbine blade unmanned aerial vehicle inspection method based on a deep reinforcement learning algorithm. Background Art

[0002] Facing the current trend of global energy transformation, countries are actively supporting and promoting the development of the wind power industry. However, since wind turbine blades are exposed to the natural environment and are affected by various natural factors, blade damage will not only reduce energy output, but may also cause wind turbine imbalance and shorten equipment life. Therefore, blade maintenance and inspection work has become particularly important.

[0003] In recent years, with the rapid development of drone technology, the method of using a quadcopter drone to autonomously inspect wind turbine blades has become mainstream. For example, the Chinese patent publication (announcement) number CN116906276A provides an intelligent inspection method for wind turbine blades. The invention includes determining the inspection path of the drone, collecting image information, and judging the fault type. However, the clarity of the blade damage image is affected by the stability of the drone. In a complex wind field environment, the stability of the drone is limited, which will greatly affect the collection of image information. The Chinese patent publication (announcement) number CN116906276A discloses an intelligent inspection method for wind turbine blades. According to the established model of the wind turbine to be inspected, the inspection path is determined, and the drone is used for autonomous inspection. However, in a complex wind field environment, the drone will deviate from the planned inspection path due to the disturbance of the wind field, and the stability is limited.

[0004] In order to improve the stability of UAVs and reduce maintenance costs, it is of great significance to explore the use of deep reinforcement learning algorithms for UAV inspection control and study and improve the TD3 algorithm for UAV inspection control in complex wind field environments. Summary of the invention

[0005] The present invention discloses a wind turbine blade UAV inspection method based on a deep reinforcement learning algorithm, which is suitable for wind turbine blade inspection tasks and can control UAVs to perform efficient and stable inspections. In an environment with sparse rewards, it can comprehensively consider energy consumption, stability and other issues to complete the UAV's autonomous inspection task of wind turbine blades.

[0006] A wind turbine blade drone inspection method based on a deep reinforcement learning algorithm comprises the following steps:

[0007] Step 1: Build a reinforcement learning model for the UAV inspection of wind turbine blades;

[0008] Step 2: Define a heuristic dynamic reward function based on continuous position and energy consumption;

[0009] Step 3: Build an improved double-delayed deep deterministic policy gradient TD3 algorithm;

[0010] Step 4: Train the algorithm in a complex wind field environment to control the drone to perform blade inspection tasks.

[0011] Preferably, step 1 specifically comprises the following steps:

[0012] Step 1-1: Construct a reinforcement learning model (S, A, P, R, γ) for drone inspection of wind turbine blades, where S is the set of all possible environments. In the reinforcement learning framework, S contains all the information required for drone inspection; A is the set of all possible actions that the drone can take in each state; P is the state transition probability, the possibility of transitioning to another state after taking an action in the current state; R is the reward function; γ is the discount factor. The feasibility space of the drone in the environment is a three-dimensional environment space of H×L×W, where H represents the height of the feasibility space; L is the length of the space, and W is the width of the space. This area is the feasibility space for drone inspection of blades;

[0013] Step 1-2: Define the state space of the reinforcement learning model; set the state to: S = [S l ,S a ,S v ,S w ,S p ], where state S l =[x,y,z] represents the three-dimensional coordinate position of the drone in the environment; represents the Euler angle of the drone, is the roll angle of the drone, θ is the pitch angle of the drone, and ψ is the yaw angle of the drone. The Euler angle of the drone is limited to a reasonable range. If it exceeds the set range, it means that the drone is moving violently and the movement is terminated: S v =[v x ,v y ,v z ] represents the velocity component of the UAV’s motion speed in the three-dimensional coordinate system; S w =[ω x ,ω y ,ω z ] represents the angular velocity component of the UAV in the three-dimensional coordinate system; S p =[Δx, Δy, Δz] represents the coordinate difference between the current position of the drone and the three-dimensional coordinates of the inspection point;

[0014] Step 1-3: Define the action space of the reinforcement learning model: The output action A of the drone represents the set of all possible actions that the drone can take in each state; output action A = [w1 ,w 2 ,w 3 ,w 4 ], where w 1 …w 4 Indicates the rotation speed of the four rotors of the drone; constrains the rotation speed of the four rotors of the drone and the acceleration of the drone to prevent the drone from moving violently: w i ∈[w min ,w max ], where w min 、w max Respectively represent the minimum and maximum rotation speed of the UAV rotor; a i ∈[a min ,a max ] represent the minimum and maximum acceleration of the drone respectively.

[0015] Preferably, step 2 specifically comprises the following steps:

[0016] Step 2-1: Define the reward function R, use the drone sensor to obtain the distance between the drone and the inspection point, set the heuristic dynamic reward function of continuous position and energy consumption, control the drone to autonomously inspect the wind turbine blades in the most stable way with the least energy consumption, and speed up the training process by setting obstacle avoidance rewards and task completion rewards for the drone;

[0017] Step 2-2: Set up the continuous position heuristic dynamic reward function R p As shown below:

[0018]

[0019] Among them, η is the reward coefficient, d t is the distance from the drone to the inspection point in the current state, d t+1 is the distance from the drone to the inspection point in the next state. When the drone performs the current action, if the next state is closer to the inspection point, it will receive a positive reward. If the next state is far away from the inspection point, it will be punished. The farther the distance, the greater the penalty.

[0020] Step 2-3: In the task of inspecting wind turbine blades by drones in this application, since the wind turbine blades are long and the height of the wind turbine tower is generally around 100m, in order to extend the flight time of the drone, it is necessary to reduce the consumption of battery power. Therefore, in the inspection task of drones in this application, it is also necessary to design a reward function for energy consumption. The continuous energy consumption reward function R e For: R e =T+0.3·v 2 +0.5·a, where T is the total motion time of the drone, v 2Proportional to the kinetic energy of the drone, it encourages low-energy motion by adjusting the speed. a is the acceleration of the drone. Similar to speed, an increase in acceleration usually leads to an increase in energy consumption (for example, through more thrust to accelerate). Therefore, in the reward function, the larger a is, the greater the energy penalty is;

[0021] Step 2-4: When the distance between the drone and the inspection point is less than 0.5m, the drone is considered to have completed the flight mission and receives a positive reward R of 100. s ;

[0022] Step 2-5: Set the obstacle avoidance reward function to R c =0.5-d, where d is the distance from the current drone to the inspection point;

[0023] The reward function R is obtained by integrating the drone continuous position reward function, energy consumption reward function, task completion reward and obstacle avoidance reward: R = R p +R e +R s +R c

[0024] Step 2-6: Define the discount factor γ: The discount factor γ ranges from (0, 1) and is used to calculate the cumulative value of the reward. The larger the γ, the more emphasis is placed on long-term returns.

[0025] Preferably, step 3 specifically comprises the following steps:

[0026] Step 3-1: The improved double-delay deep deterministic policy gradient algorithm uses 6 networks, 4 Critic networks and 2 Actor networks. The 2 Actor networks take the state as input, and the 4 Critic networks take the state and action as input. The state consists of 15 elements, which are the three-dimensional coordinate position of the quadcopter, the Euler angle of the drone, the linear velocity and angular velocity of the drone on the three coordinates, and the coordinate difference between the current coordinate and the coordinate of the position of the inspection point. The output of the network is different. For the 4 Critic networks, a duel network structure design is adopted to output the advantage value and the state value, while for the 2 Actor networks, there will be 4 outputs, namely the speed of the four motors of the quadcopter. Among them, the Critic network divides the state input into two parts after passing through a 128-layer fully connected layer. One part passes through a 64-layer fully connected layer and is output as the state value; the other part passes through a 64-layer fully connected layer and is connected to the action input after passing through the 128-layer and 64-layer fully connected layers. After input into the 64-layer fully connected layer, it is output as the advantage value. Figure 2 The Actor network consists of two hidden layers of 128 nodes and 64 nodes with ReLU activation and an output layer with Tanh activation function.

[0027] Step 3-2: Construct a priority experience playback buffer pool: Introduce TD_error to determine the probability of experience being sampled. Experience with high TD_error is considered to be more valuable because it indicates that the drone has a large deviation in its prediction of these experiences. Learning from these experiences may bring about a greater update of the value function. As a preferred step, step 4, training the algorithm in a complex wind field environment to control the drone to achieve the blade inspection task, specifically includes the following steps:

[0028] Step 4-1: Build a wind turbine model and a complex wind field environment in the UE4 and AirSim simulation environment. The wind field environment is designed according to the national standard requirements for UAV wind resistance and consists of three types of wind fields: continuous wind, gusts, and tangential wind. Train the improved TD3 algorithm in the built simulation environment.

[0029] Step 4-2: Initialize the simulation environment and neural network model. The simulation environment includes the wind field environment and the UAV autonomously taking off to the starting point and keeping hovering. For the neural network, the Critic network uses a duel network structure to decompose the Q value function into a state value function and an advantage value function. The mathematical expression is as follows:

[0030]

[0031] Set the algorithm's hyperparameters: learning rate, maximum number of action steps in a single round, maximum number of training rounds, maximum capacity of the priority experience pool, soft update parameters, and noise parameters;

[0032] Step 4-3: In each training step, do the following:

[0033] Select an action with exploration noise, execute action a and get reward r, and observe the new state s` of the drone: s`,r,done=step(a)

[0034] Calculate the priority for the current transformation using the following formula:

[0035] TD-error=|Q 1 (s,a)-r-γ×min(Q 1 _tar(s',π_tar(s')),Q 2 _tar(s',π_tar(s')))|

[0036] priority=(TD-error+ε)×α

[0037] Among them, TD_error is used to measure the difference between the current estimated value and the target value, Q 1(s,a)Critic_1 network estimates the current state s and the selected action a, r is the reward after executing action a, γ is the discount factor used to measure the importance of future rewards, min(Q 1 _tar(s',π_tar(s')),Q 2 _tar(s',π_tar(s'))) represents the minimum Q value of the Critic network estimated when the next state s' uses the target strategy π_tar to select an action;

[0038] The priority is calculated based on TD_error and is used to guide the sampling process during experience playback. In the formula, TD_error is added with a very small positive number ε to ensure that each sample has a priority;

[0039] Then, the experience tuple (s, a, r, s`) is stored in the priority experience revisit pool, and the current state is updated to the new state;

[0040] To update the network, follow these steps:

[0041] Sample the minimum batch of samples from the priority experience replay pool according to the priority, as shown in the following formula, and update the experience and network parameters:

[0042] transitions,indices,weights=D.sample(batch_size,β)

[0043] Among them, transitions is the sampled experience sample, which contains a tuple of state transitions, indices is the index used for the priority of subsequent experience updates, weights is the importance weight, batch_size is the batch size, and β is the importance sampling parameter used to adjust the weight when sampling experience;

[0044] Update the Critic network:

[0045] Among them, L critic represents the loss function of the Critic network, N is the batch size, w i is the importance sampling weight of sample i, which is used to adjust the contribution of each sample to the loss function, Represents the TD_error square of sample i, which measures the prediction error of the network;

[0046] Use delayed updating of Actor network and target network:

[0047]

[0048] Among them, θL represents the gradient of the loss function with respect to the Actor network parameters, E represents the expectation, represents the gradient of the Critic network with respect to action a, Represents the gradient of the Actor network with respect to the parameter θ;

[0049] φ' i ←τφ i +(1-τ)φ' i

[0050] θ′←τθ+(1-τ)θ′

[0051] Among them, τ determines the trade-off between the current parameters and the target parameters, and is used to control the hyperparameters of the sliding average update, φ i is the parameter of the current Critic network, φ' i is the parameter of the target Critic network, θ is the parameter of the current Actor network, and θ′ is the parameter of the target Actor network. The target parameters of the policy network and the value network are updated by sliding average to improve the stability and efficiency of training.

[0052] Update experience priority:

[0053] new_priorities=|yQ 1 (s,a)|+ε

[0054] D.update_priorities(indices,new_priorities);

[0055] Step 4-4: Set hyperparameters and control the UAV in the designed simulation environment to perform wind turbine blade inspection tasks, and compare the control effects of the improved TD3 algorithm and the TD3 algorithm.

[0056] The beneficial effects of the present invention are:

[0057] In response to the current problem of instability of drones inspecting wind turbine blades in complex environments, this application proposes a drone control method based on a deep reinforcement learning algorithm, which has better adaptability and stability in complex environments. The design idea is to first create a reinforcement learning model for drone inspection of wind turbine blades, and define the feasibility space of the drone in the environment; the state space, which includes 15 elements of the drone's three-dimensional coordinate position, Euler angle, speed, angular velocity and distance in the environment; and the drone's action space, to prevent the drone from taking radical movements, limit the value range of the drone's Euler angle, speed and acceleration. Secondly, according to the inspection task requirements, a heuristic dynamic reward function for continuous position and energy consumption and a reward function for completing tasks and avoiding obstacles are designed to control the drone to autonomously inspect the wind turbine blades in the most stable and least energy-consuming path. For wind turbine inspection tasks, the neural network structure and priority experience replay technology of the TD3 deep reinforcement learning algorithm are improved to accelerate the training process. Finally, in the constructed wind turbine and wind farm simulation environment, the control effects of the TD3 algorithm and the improved TD3 algorithm were compared. The experimental results showed that when subjected to complex wind field disturbances, the method of controlling UAV inspection based on the improved TD3 algorithm had better stability and robustness, better path smoothness, less deviation, and fewer correction actions. BRIEF DESCRIPTION OF THE DRAWINGS

[0058] Figure 1 Schematic diagram of the steps of the method of the present invention;

[0059] Figure 2 Schematic diagram of the Critic neural network of the method of the present invention;

[0060] Figure 3 A schematic diagram of the Actor neural network of the method of the present invention;

[0061] Figure 4 It is a schematic diagram of the algorithm structure of the present invention;

[0062] Figure 5 Schematic diagram of simulation results of implementation example 1;

[0063] Figure 6 Schematic diagram of simulation results of implementation example 2;

[0064] Figure 7 Schematic diagram of simulation results of implementation example 3;

[0065] Figure 8 Schematic diagram of simulation results of implementation example 4;

[0066] Fig. 9 Schematic diagram of simulation results of implementation example 5. DETAILED DESCRIPTION

[0067] The present invention will be further explained below in conjunction with the accompanying drawings and specific embodiments. It should be understood that the following specific embodiments are only used to illustrate the present invention and are not used to limit the scope of the present invention.

[0068] Embodiment: The wind turbine blade inspection method based on deep reinforcement learning algorithm described in the present invention can improve the stability and robustness of wind turbine blade inspection by drone and shorten the training time. Figure 1 The method of the present invention is shown as a schematic flow chart, which comprises the following steps:

[0069] Step 1: Build a reinforcement learning model for drone inspection of wind turbine blades;

[0070] Step 2: Define a heuristic dynamic reward function based on position and energy consumption;

[0071] Step 3: Build an improved double-delayed deep deterministic policy gradient (TD3) algorithm;

[0072] Step 4: Train the algorithm in a complex wind field environment to control the drone to perform blade inspection tasks.

[0073] Among them, in step 1, the specific steps of building a reinforcement learning model for drone inspection of wind turbine blades are:

[0074] Step 1-1: The next state of the UAV autonomous inspection of wind turbine blades depends only on the current state and has nothing to do with the past state. Therefore, the inspection process can be regarded as a reinforcement learning process. The reinforcement learning model (S, A, P, R, γ) of the UAV inspection of wind turbine blades is constructed, where S is all possible sets of the environment, including the position, speed, angular velocity and Euler angle of the UAV and the environmental information of the wind turbine, including wind speed, position coordinates and length of the wind turbine blades. In the Markov framework, S contains all the information required by the agent; A is the set of all possible actions that the agent can take in each state. In this patent, the UAV action must meet the stability, robustness and minimum energy consumption path expectations; P is the state transition probability, the possibility of transferring to another state after taking an action in the current state; R is the reward function; γ is the discount factor. The feasibility space of the UAV in the environment is a three-dimensional environment space of 500H×500L×500W, H represents the height of the feasibility space; L is the length of the space, W is the width of the space, and this area is the movement area of ​​the UAV inspection blades;

[0075] Step 1-2: Define the state space of the reinforcement learning model; set the state to: S = [S l ,S a ,S v ,S w ,S p], where state S l =[x, y, z] represents the three-dimensional coordinate position of the drone in the environment. The starting point is the center point of the three blades of the wind turbine, with coordinates (17, 175, 95), and the coordinates of the first inspection point are (17, 175, 135); represents the Euler angle of the drone, is the roll angle of the drone, θ is the pitch angle of the drone, and ψ is the yaw angle of the drone. The Euler angle of the drone is limited to a reasonable range. If it exceeds the set range, it means that the drone is moving violently and the movement is terminated: S v =[v x ,v y ,v z ] represents the velocity component of the UAV’s motion speed in the three-dimensional coordinate system; S w =[ω x ,ω y ,ω z ] represents the angular velocity component of the UAV in the three-dimensional coordinate system; S p =[Δx, Δy, Δz] represents the coordinate difference between the current position of the drone and the three-dimensional coordinates of the point to be inspected. The coordinate difference from the starting point to the first point to be inspected is (0, 0, 40);

[0076] Step 1-3: Define the action space of the reinforcement learning model: The output action A of the drone represents the set of all possible actions that the drone can take in each state; output action A = [w 1 ,w 2 ,w 3 ,w 4 ], where w 1 …w 4 Indicates the rotation speed of the drone's four rotors; constrains the rotation speed of the drone's four rotors and the acceleration of the drone to prevent the drone from moving violently: a i ∈[1m / s 2 , 10m / s 2 ];

[0077] In step 2, a heuristic dynamic reward function based on position and energy consumption is defined, and the specific steps are:

[0078] Step 2-1: Define the reward function R, use the drone sensor to obtain the distance between the drone and the inspection point, and control the drone to autonomously inspect the wind turbine blades along the path that meets the requirements of stability, robustness and minimum energy consumption by setting a heuristic dynamic reward function of continuous position and energy consumption;

[0079] Step 2-2: Set up the continuous position heuristic dynamic reward function R pAs shown below:

[0080]

[0081] Among them, η is the reward coefficient, d t is the distance from the drone to the inspection point in the current state, d t+1 is the distance from the drone to the inspection point in the next state. The formula shows that when the drone performs the current action, if the next state is closer to the inspection point, it will receive a positive reward. If the next state is far away from the inspection point, it will be punished. The farther the distance, the greater the penalty. The distance from the drone starting point (17,175,95) to the inspection point (17,175,135) at the top of the blade is 40m;

[0082] Step 2-3: In the task of inspecting wind turbine blades by the drone of this patent, since the wind turbine blades are long and the height of the wind turbine tower is generally around 100m, in order to extend the flight time of the drone, it is necessary to reduce the consumption of battery power. Therefore, in the inspection task of the drone of this patent, it is also necessary to design a reward function for energy consumption. The continuous energy consumption reward function R e For: R e =T+0.3·v 2 +0.5·a, where T is the total motion time of the drone, v 2 Proportional to the kinetic energy of the drone, it encourages low-energy motion by adjusting the speed. a is the acceleration of the drone. Similar to speed, an increase in acceleration usually leads to an increase in energy consumption (for example, through more thrust to accelerate). Therefore, in the reward function, the larger a is, the greater the energy penalty is;

[0083] Step 2-4: When the distance between the drone and the inspection point is less than 0.5m, the drone is considered to have completed the flight mission and receives a positive reward R of 100. s ;

[0084] Step 2-5: Set the obstacle avoidance reward function to R c =0.5-d, where d is the distance from the current drone to the inspection point;

[0085] The reward function R is obtained by integrating the drone continuous position reward function, energy consumption reward function, task completion reward and obstacle avoidance reward: R = R p +R e +R s +R c ;

[0086] Step 2-6: Define the discount factor γ: The discount factor γ ranges from (0, 1) and is used to calculate the cumulative value of the reward. The larger the γ, the more emphasis is placed on long-term returns.

[0087] The step 3 is to build an improved double-delay deep deterministic policy gradient TD3 algorithm, and the specific steps are as follows: Step 3-1: The improved double-delay deep deterministic policy gradient algorithm uses 6 networks, 4 Critic networks and 2 Actor networks. The 2 Actor networks take the state as input, and the 4 Critic networks take the state and action as input. The state is composed of 15 elements, which are the three-dimensional coordinate position of the quadcopter drone, the Euler angle of the drone, the linear velocity and angular velocity of the drone on the three coordinates, and the coordinate difference between the current coordinate and the coordinate of the position of the inspection point. The output of the network is different. For the 4 Critic networks, the duel network structure design is adopted to output the advantage value and the state value, while for the 2 Actor networks, there will be 4 outputs, namely the speed of the four motors of the quadcopter drone. Among them, the Critic network divides the state input into two parts after passing through a 128-layer fully connected layer. One part passes through a 64-layer fully connected layer and is output as the state value; the other part passes through a 64-layer fully connected layer and is connected with the action input that passes through the 128-layer and 64-layer fully connected layers and is input into the 64-layer fully connected layer and output as the advantage value. Figure 2 The Actor network is composed of two hidden layers of 128 nodes and 64 nodes with ReLU activation and an output layer with Tanh activation function, as shown in Figure 3 .

[0088] Step 3-2: Construct a priority experience replay buffer pool: Introduce TD_error to determine the probability of experience being sampled. Experience with high TD_error is considered to be more valuable because it indicates that the drone has a large deviation in its prediction of these experiences. Learning from these experiences is likely to bring about a greater update of the value function.

[0089] The step 4 is to train the algorithm in a complex wind field environment to control the UAV to perform the blade inspection task, and the specific steps are as follows:

[0090] Step 4-1: Construct a wind turbine model and a complex wind field environment in the UE4 and AirSim simulation environment. The wind field environment is designed according to the national standard requirements for UAV wind resistance and consists of three types of wind fields: continuous wind with a wind speed of 11m / s, gusts with a wind speed of 11m / s, and tangential wind with a wind speed of 4m / s; train the improved TD3 algorithm in the constructed simulation environment;

[0091] Step 4-2: Initialize the simulation environment and neural network model. The simulation environment includes the wind field environment and the UAV autonomously takes off to the starting point (17, 175, 95) and keeps hovering. For the neural network, the Critic network uses a duel network structure to decompose the Q value function into a state value function and an advantage value function. The mathematical expression is as follows:

[0092]

[0093] Set the algorithm's hyperparameters: learning rate, maximum number of action steps in a single round, maximum number of training rounds, maximum capacity of the priority experience pool, soft update parameters, and noise parameters;

[0094] Step 4-3: In each training step, do the following:

[0095] Select an action with exploration noise, execute action a and get reward r, and observe the new state s` of the drone: s`,r,done=step(a)

[0096] Calculate the priority for the current transformation using the following formula:

[0097] TD-error=|Q 1 (s,a)-r-γ×min(Q 1 _tar(s',π_tar(s')),Q 2 _tar(s',π_tar(s')))|

[0098] priority=(TD-error+ε)×α

[0099] Among them, TD_error is used to measure the difference between the current estimated value and the target value, Q 1 (s,a) Critic_1 network estimates the current state s and the selected action a, r is the reward after executing action a, γ is the discount factor used to measure the importance of future rewards,

[0100] min(Q 1 _tar(s',π_tar(s')),Q 2 _tar(s',π_tar(s'))) represents the minimum Q value of the Critic network estimated when the next state s' uses the target strategy π_tar to select an action;

[0101] The priority is calculated based on TD_error and is used to guide the sampling process during experience playback. In the formula, TD_error is added with a very small positive number ε to ensure that each sample has a priority;

[0102] Then, the experience tuple (s, a, r, s`) is stored in the priority experience revisit pool, and the current state is updated to the new state;

[0103] To update the network, follow these steps:

[0104] Sample the minimum batch of samples from the priority experience replay pool according to the priority, as shown in the following formula, and update the experience and network parameters:

[0105] transitions,indices,weights=D.sample(batch_size,β)

[0106] Among them, transitions is the sampled experience sample, which contains a tuple of state transitions, indices is the index used for the priority of subsequent experience updates, weights is the importance weight, batch_size is the batch size, and β is the importance sampling parameter used to adjust the weight when sampling experience;

[0107] Update the Critic network:

[0108] Among them, L critic represents the loss function of the Critic network, N is the batch size, w i is the importance sampling weight of sample i, which is used to adjust the contribution of each sample to the loss function, Represents the TD_error square of sample i, which measures the prediction error of the network;

[0109] Use delayed updating of Actor network and target network:

[0110]

[0111] Among them, θ L represents the gradient of the loss function with respect to the Actor network parameters, E represents the expectation, represents the gradient of the Critic network with respect to action a, Represents the gradient of the Actor network with respect to the parameter θ;

[0112] φ i '←τφ i +(1-τ)φ i '

[0113] θ′←τθ+(1-τ)θ′,

[0114] Among them, τ determines the trade-off between the current parameters and the target parameters, and is used to control the hyperparameters of the sliding average update, φ i is the parameter of the current Critic network, φ' i is the parameter of the target Critic network, θ is the parameter of the current Actor network, and θ′ is the parameter of the target Actor network. The target parameters of the policy network and the value network are updated by sliding average to improve the stability and efficiency of training.

[0115] Update experience priority:

[0116] new_priorities=|yQ1 (s,a)|+ε

[0117] D.update_priorities(indices,new_priorities);

[0118] The experimental results of step 4-4 are as follows:

[0119] In the simulation environment, the drone arm length is 1m, and its flight speed is determined by the improved TD3 algorithm in the range of [-20, 20]m / s. The hyperparameter settings are shown in Table 1:

[0120] Table 1 Hyperparameter settings of the improved algorithm

[0121]

[0122]

[0123] The test results are shown in Table 2:

[0124] Table 2 Comparison results of algorithm tests in five simulation environments

[0125]

[0126] The trajectory diagrams of the two algorithms controlling the inspection of drones in five wind field environments are shown below:

[0127] Implementation example 1: In the absence of wind field disturbance:

[0128] Both algorithms show good performance in the absence of wind field disturbances. However, compared with the TD3 algorithm, the improved TD3 algorithm has a faster response speed and a smaller deviation on the x-axis, y-axis and z-axis. For details on the simulation results, see Figure 5 , where a is the x-axis position, b is the y-axis position, and c is the z-axis position.

[0129] Implementation Example 2: In case of continuous wind disturbance:

[0130] Under the interference of continuous wind, the deviation of the drone under the control of both algorithms has increased, but compared with the TD3 algorithm, the improved TD3 algorithm is more adaptable to continuous wind fields, can maintain stability faster, and no longer vibrate. Compared with the environment without wind disturbance, the trajectory smoothness of the improved TD3 algorithm is still very good. Therefore, the improved TD3 has a strong adaptability to continuous wind. For example, see the simulation results. Figure 6 , where a is the x-axis position, b is the y-axis position, and c is the z-axis position

[0131] Implementation Example 3: In the case of gust interference:

[0132] This patent adds gust disturbances to the y-axis when the quadcopter flies to the center of the wind turbine. As can be seen from the figure, under the influence of the gusts, both the x-coordinate and the z-coordinate are affected to some extent, but under the control of the two algorithms, they can quickly reach a stable flight state. However, the y-axis is directly disturbed by the gust wind field, and the TD3 algorithm has a small oscillation, but there are many correction actions. Compared with the improved TD3 algorithm, it still has better anti-wind disturbance capabilities in the gust field environment, and the generated trajectory is smoother. Compared with implementation example 1 in an environment without wind disturbances, the improved TD3 algorithm can maintain stability in a very short time, and the correction action is not obvious. For the simulation structure, see Figure 7 , where a is the x-axis position, b is the y-axis position, and c is the z-axis position.

[0133] Implementation example 4: In case of tangential wind disturbance:

[0134] The tangential wind set in this patent is a wind field disturbance of 4m / s generated when the height reaches 100m. Under the influence of the tangential wind, when the drone reaches a height of 100m, the x-coordinate and y-coordinate are disturbed to varying degrees, and the adjustment time of the z-coordinate is also significantly longer. However, under the action of the two algorithms, they can quickly reach a stable state. The simulation results are shown in Figure 8 , where a is the x-axis position, b is the y-axis position, and c is the z-axis position

[0135] Implementation Example 5: Under three combined wind field interference conditions:

[0136] When subjected to the disturbance of three wind fields, the control effect of TD3 algorithm is obviously insufficient, and obvious oscillations appear in both x-coordinate and y-coordinate, and the correction time in z-coordinate is also significantly longer. The improved TD3 algorithm performs well, with a small oscillation amplitude and can remain stable in a short time. The simulation structure is shown in Fig. 9 , where a is the x-axis position, b is the y-axis position, and c is the z-axis position.

[0137] According to the experimental results, the improved TD3 algorithm improves the success rate of drones in the simulation environment better than the TD3 algorithm, and effectively reduces the collision rate of drones. At the same time, the improved TD3 algorithm only needs less adjustment time to achieve stable flight of drones. As the wind field environment changes, the effect of the improved TD3 algorithm becomes more obvious.

[0138] It should be noted that the above content only illustrates the technical idea of ​​the present invention and cannot be used to limit the protection scope of the present invention. For ordinary technicians in this technical field, several improvements and modifications can be made without departing from the principle of the present invention. These improvements and modifications all fall within the protection scope of the claims of the present invention.

Claims

1. A wind turbine blade drone inspection method based on deep reinforcement learning algorithm, It is characterized in that The method comprises the following steps: Step 1: Build a reinforcement learning model for the UAV inspection of wind turbine blades; Step 2: Define a heuristic dynamic reward function based on continuous position and energy consumption; Step 3: Build an improved double-delayed deep deterministic policy gradient TD3 algorithm; Step 4: Train the algorithm in a complex wind field environment to control the drone to perform blade inspection tasks.

2. According to claim 1, the wind turbine blade drone inspection method based on deep reinforcement learning algorithm, It is characterized in that Step 1 specifically includes the following steps: Step 1-1: Construct a reinforcement learning model (S, A, P, R, γ) for drone inspection of wind turbine blades, where S is the set of all possible environments. In the reinforcement learning framework, S contains all the information required for drone inspection; A is the set of all possible actions that the drone can take in each state; P is the state transition probability, the possibility of transferring to another state after taking an action in the current state; R is the reward function; γ is the discount factor, and the feasibility space of the drone in the environment is a three-dimensional environment space of H×L×W, where H represents the height of the feasibility space; L is the length of the space, and W is the width of the space. This area is the feasibility space for drone inspection of blades; Step 1-2: Define the state space of the reinforcement learning model; set the state to: S = [S l ,S a ,S v ,S w ,S p ], where state S l =[x,y,z] represents the three-dimensional coordinate position of the drone in the environment; represents the Euler angle of the drone, is the roll angle of the drone, θ is the pitch angle of the drone, and ψ is the yaw angle of the drone. The Euler angle of the drone is limited to a reasonable range. If it exceeds the set range, it means that the drone is moving violently and the movement is terminated: S v =[v x ,v y ,v z ] represents the velocity component of the UAV’s motion speed in the three-dimensional coordinate system; S w =[ω x ,ω y ,ω z ] represents the angular velocity component of the UAV in the three-dimensional coordinate system; S p =[Δx, Δy, Δz] represents the coordinate difference between the current position of the drone and the three-dimensional coordinates of the inspection point; Step 1-3: Define the action space of the reinforcement learning model: The output action A of the drone is represented as the set of all possible actions that the drone can take in each state; output action A = [w 1 ,w 2 ,w 3 ,w 4 ], where w 1 …w 4 Indicates the rotation speed of the four rotors of the drone; constrains the rotation speed of the four rotors of the drone and the acceleration of the drone to prevent the drone from moving violently: w i ∈[w min ,w max ], where w min 、w max Respectively represent the minimum and maximum rotation speed of the UAV rotor; a i ∈[a min ,a max ] represent the minimum and maximum acceleration of the drone respectively.

3. According to claim 2, the wind turbine blade drone inspection method based on deep reinforcement learning algorithm, It is characterized in that Step 2 specifically includes the following steps: Step 2-1: Define the reward function R, use the drone sensor to obtain the distance between the drone and the inspection point, set the heuristic dynamic reward function of continuous position and energy consumption, control the drone to autonomously inspect the wind turbine blades in the most stable way with the least energy consumption, and speed up the training process by setting obstacle avoidance rewards and task completion rewards for the drone; Step 2-2: Set up the continuous position heuristic dynamic reward function R p As shown below: Among them, η is the reward coefficient, d t is the distance from the drone to the inspection point in the current state, d t+1 is the distance from the drone to the inspection point in the next state. When the drone performs the current action, if the next state is closer to the inspection point, it will receive a positive reward. If the next state is far away from the inspection point, it will be punished. The farther the distance, the greater the penalty. Step 2-3: In the task of UAV inspection of wind turbine blades, design a reward function for energy consumption, continuous energy consumption reward function R e For: R e =T+0.3·v 2 +0.5·a, where T is the total motion time of the drone, v 2 It is proportional to the kinetic energy of the drone. It encourages low-energy movement by adjusting the speed. a is the acceleration of the drone. An increase in acceleration usually leads to an increase in energy consumption. Therefore, in the reward function, the larger a is, the greater the energy penalty is. Step 2-4: When the distance between the drone and the inspection point is less than 0.5m, the drone is considered to have completed the flight mission and receives a positive reward R of 100. s ; Step 2-5: Set the obstacle avoidance reward function to R c =0.5-d, where d is the distance from the current drone to the inspection point; The reward function R is obtained by integrating the drone continuous position reward function, energy consumption reward function, task completion reward and obstacle avoidance reward: R = R p +R e +R s +R c Step 2-6: Define the discount factor γ: The discount factor γ ranges from (0, 1) and is used to calculate the cumulative value of the reward. The larger the γ, the more emphasis is placed on long-term returns.

4. According to claim 3, the wind turbine blade drone inspection method based on deep reinforcement learning algorithm, It is characterized in that Step 3 is as follows: Step 3-1: The improved double-delay deep deterministic policy gradient algorithm uses 6 networks, 4 Critic networks and 2 Actor networks. The 2 Actor networks take the state as input, and the 4 Critic networks take the state and action as input. The state consists of 15 elements, which are the three-dimensional coordinate position of the quadcopter, the Euler angle of the drone, the linear velocity and angular velocity of the drone on the three coordinates, and the coordinate difference between the current coordinate and the coordinate of the position of the inspection point. The output of the network is different. For the 4 Critic networks, the duel network structure design is adopted to output the advantage value and the state value, and For two Actor networks, there will be four outputs, namely the speed of the four motors of the quadcopter. Among them, the Critic network divides the state input into two parts after passing through a 128-layer fully connected layer. One part passes through a 64-layer fully connected layer and is output as the state value; the other part passes through a 64-layer fully connected layer and is connected with the action input after passing through the 128-layer and 64-layer fully connected layers. After input into the 64-layer fully connected layer, the output is the advantage value. The Actor network is composed of two hidden layers with 128 nodes and 64 nodes with ReLU activation and an output layer with Tanh activation function. Step 3-2: Build a priority experience replay buffer pool: Introduce TD_error to determine the probability of experience being sampled.

5. According to claim 3, the wind turbine blade drone inspection method based on deep reinforcement learning algorithm, It is characterized in that Step 4 is as follows: Step 4-1: Build a wind turbine model and a complex wind field environment in the UE4 and AirSim simulation environment. The wind field environment is designed according to the national standard requirements for UAV wind resistance and consists of three types of wind fields: continuous wind, gusts, and tangential wind. Train the improved TD3 algorithm in the built simulation environment. Step 4-2: Initialize the simulation environment and neural network model. The simulation environment includes the wind field environment and the UAV autonomously taking off to the starting point and keeping hovering. For the neural network, the Critic network uses a duel network structure to decompose the Q value function into a state value function and an advantage value function. The mathematical expression is as follows: Set the algorithm's hyperparameters: learning rate, maximum number of actions in a single round, maximum number of training rounds, maximum capacity of the priority experience pool, soft update parameters, and noise parameters; Step 4-3: In each training step, do the following: Select an action with exploration noise, execute action a and get reward r, and observe the new state s` of the drone: s`,r,done=step(a) Calculate the priority for the current transformation using the following formula: TD-error=|Q 1 (s,a)-r-γ×min(Q 1 _tar(s',π_tar(s')),Q 2 _tar(s',π_tar(s')))| priority=(TD-error+ε)×α Among them, TD_error is used to measure the difference between the current estimated value and the target value, Q 1 (s,a)Critic_1 network estimates the current state s and the selected action a, r is the reward after executing action a, γ is the discount factor used to measure the importance of future rewards, min(Q 1 _tar(s',π_tar(s')),Q 2 _tar(s',π_tar(s'))) represents the minimum Q value of the Critic network estimated when the next state s' uses the target strategy π_tar to select an action; Then, the experience tuple (s, a, r, s`) is stored in the priority experience revisit pool, and the current state is updated to the new state; To update the network, follow these steps: Sample the minimum batch of samples from the priority experience replay pool according to the priority, as shown in the following formula, and update the experience and network parameters: transitions,indices,weights=D.sample(batch_size,β) Among them, transitions is the sampled experience sample, which contains a tuple of state transitions, indices is the index used for the priority of subsequent experience updates, weights is the importance weight, batch_size is the batch size, and β is the importance sampling parameter used to adjust the weight when sampling experience; Update the Critic network: Among them, L critic represents the loss function of the Critic network, N is the batch size, w i is the importance sampling weight of sample i, which is used to adjust the contribution of each sample to the loss function, Represents the TD_error square of sample i, which measures the prediction error of the network; Use delayed updating of Actor network and target network: in, represents the gradient of the loss function with respect to the Actor network parameters, E represents the expectation, represents the gradient of the Critic network with respect to action a, Represents the gradient of the Actor network with respect to the parameter θ; Among them, τ determines the trade-off between the current parameters and the target parameters, and is used to control the hyperparameters of the sliding average update, φ i is the parameter of the current Critic network, φ' i is the parameter of the target Critic network, θ is the parameter of the current Actor network, and θ′ is the parameter of the target Actor network. The target parameters of the policy network and the value network are updated by sliding average to improve the stability and efficiency of training. Update experience priority: new_priorities=|y-Q 1 (s,a)|+ε D.update_priorities(indices,new_priorities); Step 4-4: Set hyperparameters and control the UAV in the designed simulation environment to perform wind turbine blade inspection tasks, and compare the control effects of the improved TD3 algorithm and the TD3 algorithm.

6. A terminal, Features: It includes a processor, a memory, and a program stored in the wind turbine blade drone inspection method based on a deep reinforcement learning algorithm. When the program is executed by the processor, the steps of the wind turbine blade drone inspection method based on a deep reinforcement learning algorithm as described in any one of claims 1 to 5 are implemented.

7. A computer-readable storage medium having computer instructions stored thereon, Features: When the computer instructions are executed by the processor, the steps of the wind turbine blade drone inspection method based on the deep reinforcement learning algorithm as described in any one of claims 1-5 are implemented.

Citation Information

Patent Citations

  • Quadrotor attitude trajectory control method using PPO algorithm based on dimension cutting

    CN113885549A

  • Multi-quad-rotor unmanned aerial vehicle centralized task path planning method based on reinforcement learning

    CN116301007A

  • Unmanned aerial vehicle visual servo control method and system for fan blade inspection

    CN116912715A

  • Unmanned aerial vehicle flight path planning method of improved TD3 algorithm fused with prior strategy

    CN118349031A

  • System and method for diagnosis assistance of diabetic neuropathy

    KR1020250068311A

Cited By

  • Unmanned aerial vehicle steering engine control method, device and equipment and storage medium

    CN118819175A

  • Unmanned aerial vehicle control method based on multi-target reinforcement learning

    CN118884837A

  • A UAV control method based on multi-objective reinforcement learning

    CN118884837B

  • New energy flexible direct output system oscillation suppression method based on double-delay depth deterministic strategy gradient algorithm

    CN119518834A

  • Unmanned aerial vehicle control method and device, electronic equipment and storage medium

    CN119861576A