Unmanned aerial vehicle inspection method and terminal device for power grid security situation awareness

By constructing a hybrid deep neural network to correct the flight status of UAVs, the problem of flight instability during UAV inspections was solved, image quality and inspection accuracy were improved, and the needs of power grid security situation awareness were met.

CN115861852BActive Publication Date: 2025-12-23HUNAN UNIV
View PDF 2 Cites 0 Cited by

Patent Information

Application Number
CN202211455338.7
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2022-11-21
Publication Date
2025-12-23
Estimated Expiration
2042-11-21

AI Technical Summary

Technical Problem

Existing UAV inspection methods are susceptible to airflow disturbances during close-range inspections, resulting in unstable flight positions and attitudes. This leads to a decline in image quality from airborne inspection equipment, failing to meet the accuracy and efficiency requirements for power grid security situational awareness.

Method used

A hybrid deep neural network (HDNN) is adopted, including perturbation-resistant convolutional neural network (ADCNN), fast gated recurrent neural network (FGRNN) and fully connected neural network (Dense Net). By constructing a state space and action space, deep learning technology is used to correct the flight state of the UAV and enhance the stability of the inspection.

Benefits of technology

It significantly improves the flight position and attitude stability of UAVs during close-range inspections, enhances the image quality of airborne inspection equipment, improves the accuracy and efficiency of power transmission line inspections, and strengthens the power grid security situation awareness capability.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN115861852B_ABST
    Figure CN115861852B_ABST
Patent Text Reader

Abstract

The application discloses a kind of unmanned aerial vehicle inspection methods for power grid security situation awareness, terminal equipment.The inspection method is based on deep reinforcement learning, and the main steps include: constructing state space;Constructing mixed deep neural network;The simulation training is carried out to the mixed deep neural network, and the unmanned aerial vehicle flight state correction model is obtained;Flight state correction model is loaded into the flight control program of unmanned aerial vehicle, and the actual transmission line is inspected using unmanned aerial vehicle.The application utilizes the excellent feature learning and control decision-making ability of deep learning and reinforcement learning to effectively enhance the stability of unmanned aerial vehicle flight position and attitude in close-range inspection state to improve the quality of inspection image, thereby improving the transmission line inspection accuracy and efficiency, and enhancing the power grid security situation awareness capability.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This invention relates to the field of smart grid detection technology, and in particular to a drone inspection method and terminal equipment for power grid security situation awareness. Background Technology

[0002] The power grid, composed of transmission and distribution lines and substations at various voltage levels, is a vital energy facility ensuring the normal operation of modern society. Power grid security situation awareness refers to acquiring and analyzing various information closely related to power grid operation to grasp the real-time security status of the grid and predict future security trends, thereby assisting in the formulation of power grid security risk response strategies. As the physical carrier for long-distance power transmission and communication, transmission lines are the most geographically widespread and have the largest spatial span and land area in the power grid; their operational status has a direct and significant impact on the safety and stability of the power grid. Therefore, acquiring transmission line status information is a crucial foundational link in power grid security situation awareness. To achieve this, power line inspection drones are needed to inspect transmission lines. Drones execute inspection tasks according to ground remote control commands and can efficiently and accurately locate faults and potential hazards in transmission lines through various airborne detection equipment. Compared with manual inspection, drone inspection can adapt to complex and harsh natural environments, offering significant technological and economic advantages.

[0003] Overall, drone inspection shows promising application prospects in power grid security situational awareness, but it also has shortcomings: When a drone discovers a critical point potentially harboring faults or hidden dangers during inspection, it needs to approach that point for in-depth inspection. In close-range inspection mode, the drone is easily affected by random factors such as airflow disturbances, causing its flight position and attitude to deviate significantly. This leads to a decrease in the image quality obtained by the onboard inspection equipment, thus affecting the accuracy and efficiency of the inspection and failing to provide high-quality information for power grid security situational awareness. Therefore, existing drone inspection methods cannot meet the requirements of power grid security situational awareness tasks. Summary of the Invention

[0004] The technical problem to be solved by the present invention is to provide a method and terminal equipment for UAV inspection for power grid security situation awareness, which addresses the shortcomings of the existing technology. The method uses deep reinforcement learning technology to correct the flight state of the UAV, thereby effectively enhancing the stability of the UAV's flight position and attitude during close-range inspection, thereby improving the image quality obtained by the airborne inspection equipment, improving the accuracy and efficiency of power transmission line inspection, and enhancing the power grid security situation awareness capability.

[0005] To solve the above-mentioned technical problems, the technical solution adopted by the present invention is: a UAV inspection method for power grid security situation awareness, comprising the following steps:

[0006] S1. Construct the state space, where the state s at any time t is... t Including the detection image DI of the drone at time tt and flight status AS t ;Detection image DI at time t t CI is a sequence of images (CI) taken by a drone at time t and k previous times, arranged in chronological order. t -k,CI t-k+1 ,…,CI j ,…,CI t-2 CI t-1 CI t CI j =[VI j IR j UI j ], VI j A visible light image taken at time j, IR j Infrared image taken at time j, UI j The ultrasound image taken at time j, where j = tk, t-k+1, ..., t-2, t-1, t; and the flight state AS at time t. t PD is a sequence of pose information vectors of the UAV at time t and the previous k times arranged in chronological order. t-k ,PD t-k+1 ,…,PD j ,…,PD t-2 ,PD t-1 ,PD t ; where PD j =[x j ,y j ,u j ,α j ,β j ,γ j ], x j y j and u j These are the three-dimensional coordinates of the UAV's flight position in the Earth coordinate system at time j, and α. j β j and γ j These are the yaw angle, pitch angle, and roll angle of the UAV at time j, respectively.

[0007] S2. Construct a hybrid deep neural network (HDNN), which includes an anti-disturbance convolutional neural network (ADCNN), a first fast gated recurrent neural network (FGRNN), a second fast gated recurrent neural network, and a first fully connected neural network (Dense Net); the ADCNN is connected to the first FGRNN; the first FGRNN and the second FGRNN are both connected to the first Dense Net; the detection image DI at time t is then processed. t As input to the ADCNN, the flight state AS at time t t The sequence is used as the input to the second FGRNN; the output of the first Dense Net is Q(s,a) at time t, where Q(s,a) is the value at time t in state s. t Below, the predicted value of the feedback function obtained after the UAV performs each action in the action space; where the action space a = [Δx, Δy, Δu, Δα, Δβ, Δγ], Δx is the displacement adjustment of the UAV on the horizontal axis in the body coordinate system, Δy is the displacement adjustment of the UAV on the vertical axis in the body coordinate system, Δu is the displacement adjustment of the UAV in the vertical direction in the body coordinate system, Δα is the yaw angle adjustment of the UAV, Δβ is the pitch angle adjustment of the UAV, and Δγ is the roll angle adjustment of the UAV. Δx, Δy, Δu, Δα, Δβ, and Δγ all adopt discrete fine-tuning control mode; the feedback function r = W S S+W D D and S are information-content-weighted structural similarity indexes (IW-SSIM), and D is the detection image DI. t W is the Euclidean distance between the center of each image and the center of the target object to be inspected by the drone. S and W D The weighting coefficients and the feedback function r directly reflect the detection image DI. t The quality;

[0008] S3. Perform simulation training on the HDNN to obtain the UAV flight state correction model (ASCM).

[0009] In this invention, the process of obtaining the output of the first Dense Net, i.e., the Q(s,a) function value at time t, includes:

[0010] (1) Using the ADCNN to detect the image DI at time t t CI of each image in the sequence j The system senses environmental state information and obtains the output feature sequence F. t-k ,F t-k+1 ,…,F j ,…,F t-2 ,F t-1 ,F t Using the first FGRNN from F t-k, F t-k+1 ,…,F j ,…,F t-2 ,F t-1 ,F t Extracting temporal features yields the first feature vector V. 1t ;

[0011] (2) Using the second FGRNN to obtain the flight state AS at time t t Extracting temporal features from the sequence yields the second feature vector V. 2t ;

[0012] (3) Concatenate and splice the first feature vector V 1t Second eigenvector V 2t The concatenated vector V t As input to the first Dense Net, the Q(s,a) function value at time t is obtained.

[0013] In this invention, the HDNN is based on state s t By analyzing the specific characteristics of different information, specialized deep neural network structures composed of ADCNN and FGRNN are set up for targeted analysis and processing, which can effectively enhance feature extraction capabilities and thus significantly improve the fitting accuracy and efficiency of the Q(s,a) function value. Therefore, this invention effectively enhances the stability of the UAV's flight position and attitude in close-range inspection, thereby improving the image quality obtained by the airborne inspection equipment, increasing the accuracy and efficiency of power transmission line inspection, and enhancing the power grid safety situation awareness capability.

[0014] In this invention, the discrete fine-tuning control mode implementation process includes: selecting the maximum positive and negative displacement adjustment amount ΔP of the UAV. max and the maximum positive and negative angle adjustment ΔD max ; for ΔP max Divide ΔD into n1 equal parts. max Divide the sample into n² equal parts, then Δp = ΔP max / n1 is the displacement adjustment interval of the UAV, Δd=ΔD max / n2 is the angle adjustment interval of the UAV. The values ​​of displacement adjustment Δx, Δy and Δu in a are -n1Δp, -(n1-1)Δp, ..., -2Δp, -Δp, 0, +Δp, +2Δp, ..., +(n1-1)Δp, +n1Δp. The values ​​of angle adjustment Δα, Δβ and Δγ are -n2Δd, -(n2-1)Δd, ..., -2Δd, -Δd, 0, +Δd, +2Δd, ..., +(n2-1)Δd, +n2Δd.

[0015] In this invention, ADCNN is used to detect the image DI at time t. t CI of each image in the sequence j The process of sensing environmental state information includes the following steps:

[0016] (1) For DI t Each image in CI j Two-dimensional dilated convolution is performed separately to generate a set of convolutional feature maps M. t-k M t-k+1 ,…,M j ,…,M t-2 M t-1 M t ;

[0017] (2) Take the absolute value of each element in each convolutional feature map to obtain a set of absolute value feature maps AM. t-k AM t-k+1 ,…,AM j ,…,AM t-2 AM t-1 AM t Global average pooling is performed on each channel of the absolute value feature map to obtain a set of pooling vectors g. t-k ,g t-k+1 ,…,g j ,…,g t-2 ,g t-1 ,g t ;

[0018] (3) Each of the pooling vectors is used as the input to the second fully connected neural network to obtain a set of output vectors av. t-k ,av t-k+1 ,…,av j ,…,av t-2 ,av t-1 ,av t Each output vector is element-wise multiplied with each pooling vector to obtain a set of disturbance rejection parameter vectors A. t-k A t-k+1 ,…,A j ,…,A t-2 At-1 A t A j The dimension is equal to the number of channels in the convolutional feature map;

[0019] (4) Multiply each convolutional feature map element-wise with each perturbation parameter vector to obtain the perturbation-resistant convolutional feature map. Unfold the perturbation-resistant convolutional feature map to obtain the output feature sequence F. t-k ,F t-k+1 ,…,F j ,…,F t-2 ,F t-1 ,F t .

[0020] The ADCNN proposed in this invention can comprehensively and accurately perceive environmental state information while effectively suppressing interference signals, thereby effectively enhancing the control and decision-making capabilities of ASCM.

[0021] In this invention, the first FGRNN is used to obtain F t-k ,F t-k+1 ,…,F j ,…,F t-2 ,F t-1 ,F t Extract temporal features, and use the second FGRNN to extract the flight state AS at time t. t The process of extracting temporal features from a sequence includes the following steps:

[0022] (1) Generate the update gate z of the first FGRNN or the second FGRNN at the j-th time step using the following formula. j and reset door r j :(z j ,r j ) = sigmoid(z j ',r j '); where sigmoid is the activation function, z j =DDA(Z) j G z B z ) and r j =DDA(R) j G r B r ) represent the update gate z of the first FGRNN or the second FGRNN at the j-th time step. j and reset door r j The intermediate process vector; DDA represents data distribution adjustment, Z j =W z h j-1 +U z x j +bz With R j =W r h j-1 +U r x j +b r It is an intermediate data vector, with dimensions H and G. z With G r It is the gain vector, B z and B r The bias vector is the bias vector, and both the gain vector and the bias vector are trainable weight vectors; in the intermediate data vector Z j and R j In the middle, x j Let F be the input feature vector of the first or second FGRNN at the j-th time step. j or PD j h j-1 W is the hidden state generated by the first or second FGRNN at the (j-1)th time step. z U z W r and U r Let b be the weight matrix. z and b r It is the bias vector;

[0023] (2) Calculate the internal cell state c of the first FGRNN or the second FGRNN at the j-th time step. j :c j =RELU(c j '); where c j ′ is c j The intermediate value of the calculation W c and U c It is the weight matrix, b c It is a bias vector. This represents element-wise multiplication;

[0024] (3) Calculate the extended weight vector E of the first FGRNN or the second FGRNN at the j-th time step. j : Where λ and η are the extended weight parameters; E j-1 This represents the extended weight vector of the first or second FGRNN at the (j-1)th time step.

[0025] (4) Calculate the hidden state h generated by the first FGRNN or the second FGRNN at the j-th time step. j : in, This represents element-wise addition;

[0026] (5) For each h generated by the first FGRNN or the second FGRNN j Feature enhancement processing is performed to obtain the feature enhancement vector, which is the first feature vector V. 1t Or the second eigenvector V 2t .

[0027] The FGRNN proposed in this invention is based on self-associative memory and the threshold principle, and has higher learning ability and efficiency than traditional recurrent neural networks.

[0028] In this invention, the z-value of the first FGRNN or the second FGRNN is calculated. j 'and r j During the process of ', the Data Distribution Adjustment (DDA) process includes:

[0029] (1) Calculate the mean of the intermediate data vector. With variance Among them, X i For the intermediate data vector Z j or R j The elements in the array; i = 1, 2, ..., H;

[0030] (2) Standardize the distribution of elements in the intermediate data vector: Among them, X i Z' is the intermediate data vector. j or R j The values ​​of each element in the matrix after standard normalization, ε is a positive number that approaches 0 infinitely;

[0031] (3) Adjust the distribution of elements in the intermediate data vector using the following formula: Y i =gn i X i '+ba i ; where Y i For each element in the adjusted intermediate data vector, gn i It is the gain vector G z or G r The i-th element in the array, ba i It is the bias vector B z Or B r The i-th element in gn i with ba i All of these are trainable weight parameters.

[0032] DDA (Distributed Algorithm Analysis) adjusts the distribution of elements in the intermediate data vector based on standard normalization, concentrating most elements within a reasonable range of the nonlinear activation function. This increases the gradient while maintaining the FGRNN's ability to fit nonlinear functional relationships, without compromising the knowledge learned by the FGRNN. Therefore, DDA effectively improves the convergence speed of FGRNN. Furthermore, DDA enhances the generalization ability of FGRNN and reduces its sensitivity to hyperparameters, thus simplifying parameter tuning.

[0033] In this invention, the specific implementation process of training the HDNN in step S3 includes:

[0034] S3-1. Set two action value functions Q(s,a) and Q′(s,a), where Q(s,a) is fitted by the HDNN, and Q′(s,a) is fitted by an auxiliary HDNN with the same structure as the HDNN; initialize the HDNN and the auxiliary HDNN with the same set of random weight parameters; initialize the experience replay buffer R to an empty set {}; initialize the number of training cycles E and the number of training rounds per step Rd to 0;

[0035] S3-2. Determine if the amount of data stored in R has reached its capacity limit. max If the target has been reached, discard the earliest stored data sets to reduce the number of data sets stored in R to less than O. max If the target is not reached, a single-step training round begins, using HDNN to analyze the state s at the current time t. t We obtain Q(s,a) at time t; we determine whether the number of training rounds Rd in a single step has reached the policy transition threshold SW. If not, we select action a according to Q(s,a) using the ε-greedy policy. t Execute; if achieved, select action a according to Q(s,a) using the following formula. t Execute: Where c is the exploration coefficient, and N t (a) represents the number of times each action in action space a has been selected before time t; retrieve action a. t The new state s after execution t+1 and feedback r t ; will s t a t r t and s t+1 The quaternion [s] t ,a t ,r t ,s t+1 This data is stored as a set of data in the playback buffer R;

[0036] S3-3. Determine whether the number of quadruplets stored in R exceeds the lower capacity limit O. min If the limit is not exceeded, return to step S3-2; if the limit is exceeded, randomly sample N quadruplets from R; calculate each sampled quadruplet [s] using Q′(s,a) fitted by the auxiliary HDNN. n ,a n ,r n ,s n+1 The individual loss function value l n =(r n +ymax a Q'(s n+1 ,a)-Q(s n ,a n )) 2 , where y is the discount factor; take the average of the individual loss function values ​​of N quadruples to obtain the target loss function value L; minimize the target loss function value L using gradient descent, update the weight parameters of the HDNN, complete one single-step training round, and increment the value of Rd by 1;

[0037] S3-4. Determine whether the value of Rd is an integer multiple of the number of synchronization rounds C. If so, assign the weight parameters of the HDNN to the auxiliary HDNN.

[0038] S3-5. Determine if the value of Rd has reached the upper limit Rd. max If the condition has been met, increment the value of E by 1 and clear the value of Rd to zero, then proceed to step S3-6; otherwise, return to step S3-2.

[0039] S3-6. Determine if E has reached its upper limit. max If the target has been reached, the training process ends; otherwise, return to step S3-2.

[0040] Since traditional reinforcement learning based on ε-greedy strategies neglects potential optimal actions, leading to action selection easily getting stuck in suboptimal or local optima, this invention improves the action selection strategy during HDNN training by combining ε-greedy strategies with... By combining these approaches, and by conducting biased explorations based on the potential or uncertainty of a suboptimal action becoming the optimal action, training quality can be effectively improved, thereby better meeting the needs of power grid security situational awareness.

[0041] The method of the present invention further includes:

[0042] S4. Load the UAV flight state correction model into the UAV's flight control program, and use the UAV to inspect actual power transmission lines. Specifically, in close-range inspection mode, ASCM analyzes state s using the Q(s,a) function fitted by HDNN. tTo predict the impact of various flight pose correction commands composed of different vectors in the action space a on the detected image DI t The quality of the image is determined by the influence of the feedback function value r. Then, the optimal command with the highest expected image quality, i.e. the highest predicted value of the feedback function value r, is executed to stabilize the UAV's flight attitude, thereby improving the quality of the inspection image, enhancing the inspection accuracy and efficiency, and strengthening the power grid security situation awareness capability.

[0043] In order to better adapt to the actual inspection site in a shorter time, thereby further improving the inspection accuracy and efficiency and enhancing the power grid security situation awareness, in this invention, before using a drone to inspect the actual transmission line, the parameters of the drone flight state correction model are adjusted using a transfer learning method.

[0044] As an inventive concept, the present invention also provides a terminal device, including a memory, a processor, and a computer program stored in the memory; the processor executes the computer program to implement the steps of the method described above.

[0045] As an inventive concept, the present invention also provides a computer-readable storage medium having a computer program / instructions stored thereon; when the computer program / instructions are executed by a processor, they implement the steps of the method described above.

[0046] Compared with existing technologies, the beneficial effects of this invention are as follows: This invention proposes a UAV inspection method for power grid safety situation awareness. It comprehensively utilizes the powerful feature learning and control decision-making capabilities of two artificial intelligence technologies, deep learning and reinforcement learning, to correct the flight state of the UAV, thereby significantly enhancing the stability of the UAV's flight position and attitude during close-range inspections. This improves the image quality obtained by the airborne inspection equipment, ultimately achieving the goal of improving the accuracy and efficiency of transmission line inspections and enhancing the power grid safety situation awareness capability. Attached Figure Description

[0047] Figure 1 This is a flowchart of the UAV inspection method for power grid security situation awareness according to Embodiment 1 of the present invention;

[0048] Figure 2 This is a schematic diagram of the HDNN used to fit the Q(s,a) function in Embodiment 1 of the present invention.

[0049] Figure 3 This is a flowchart of the ADCNN operation in Embodiment 1 of the present invention;

[0050] Figure 4 This is a diagram of the internal structure of the FGRNN in Embodiment 1 of the present invention. Detailed Implementation

[0051] To make the objectives, technical solutions, and advantages of the embodiments of the present invention clearer, the technical solutions of the embodiments of the present invention will be clearly and completely described below with reference to the accompanying drawings. Obviously, the described embodiments are only some embodiments of the present invention, not all embodiments. Based on the embodiments of the present invention, all other embodiments obtained by those skilled in the art without creative effort are within the scope of protection of the present invention.

[0052] In this document, the terms "first," "second," and other similar words are not intended to imply any order, quantity, or importance, but are merely used to distinguish different elements. The terms "one," "a," and other similar words are not intended to indicate the existence of only one of the stated things, but rather that the description pertains to only one of the two stated things, which may include one or more. The terms "comprising," "including," and other similar words are intended to indicate a logical relationship, not a spatial relationship. For example, "A includes B" means that logically B belongs to A, not that spatially B is located inside A. Furthermore, the meanings of the terms "comprising," "including," and other similar words should be considered open-ended, not closed. For example, "A includes B" means that B belongs to A, but B does not necessarily constitute all of A; A may also include other elements such as C, D, and E.

[0053] Example 1

[0054] like Figure 1 As shown, the UAV inspection method for power grid security situation awareness according to Embodiment 1 of the present invention includes the following steps:

[0055] S1. Construct the state space. The state s at any time t. t Including the detection image DI of the drone at time t t and flight status AS t ;Detection image DI at time t t CI is a sequence of images (CI) taken by a drone at time t and k previous times, arranged in chronological order. t-k CI t-k+1 ,…,CI j ,…,CI t-2 CI t-1 CI t CI j =[VI j IR j UI j ], VI j A visible light image taken at time j, IR j Infrared image taken at time j, UI jThe ultrasound image taken at time j, where j = tk, t-k+1, ..., t-2, t-1, t; and the flight state AS at time t. t PD is a sequence of pose information vectors of the UAV at time t and the previous k times arranged in chronological order. t-k ,PD t-k+1 ,…,PD j ,…,PD t-2 ,PD t-1 ,PD t ; where PD j =[x j ,y j ,u j ,α j ,β j ,γ j ], x j y j and u j These are the three-dimensional coordinates of the UAV's flight position in the Earth coordinate system at time j, and α. j β j and γ j These represent the yaw angle, pitch angle, and roll angle of the UAV at time j, respectively.

[0056] S2. Construct a hybrid deep neural network (HDNN). For example... Figure 2 As shown, the HDNN consists of the anti-disturbance convolutional neural network (ADCNN), the first fast gated recurrent neural network (FGRNN), the second fast gated recurrent neural network, and the first fully connected neural network (Dense Net) proposed in Embodiment 1 of this invention, specifically including three parts: DNN1, DNN2, and DNN3. DNN1 is composed of ADCNN and the first FGRNN stacked vertically, and its function is to analyze state s. t Image portion DI in t DNN1 first utilizes ADCNN to detect the image DI at time t during runtime. t CI of each image in the sequence j The system senses environmental state information and obtains the output feature sequence F. t-k ,F t-k+1 ,…,F j ,…,F t-2 ,F t-1 ,F t Then, using the first FGRNN from F t-k ,Ft-k+1 ,…,F j ,…,F t-2 ,F t-1 ,F t Extracting temporal features yields the first feature vector V. 1t Meanwhile, the HDNN utilizes a DNN2 composed of a second FGRNN to analyze the flight state AS at time t. t Extracting temporal features from the sequence yields the second feature vector V. 2t It is important to note that FGRNN in DNN1 and DNN2 can employ multi-layered cascaded deep structures. Figure 2 Only one layer of FGRNN is displayed. Finally, in DNN3, the first feature vector V is concatenated. 1t Second eigenvector V 2t The concatenated vector V t As input to the first Dense Net, the Q(s,a) function value at time t is obtained. The first Dense Net in DNN3 can adopt a deep structure with multiple cascaded hidden layers. Figure 2 Only one layer is shown. The Q(s,a) function value at time t is the value in state s. t Below, the predicted values ​​of the feedback function obtained after the UAV performs each action in the action space. The action space is a = [Δx, Δy, Δu, Δα, Δβ, Δγ], where Δx is the displacement adjustment of the UAV on the horizontal axis in the body coordinate system, Δy is the displacement adjustment of the UAV on the vertical axis in the body coordinate system, Δu is the displacement adjustment of the UAV in the vertical direction in the body coordinate system, Δα is the yaw angle adjustment, Δβ is the pitch angle adjustment, and Δγ is the roll angle adjustment. Δx, Δy, Δu, Δα, Δβ, and Δγ all adopt discrete fine-tuning control mode; the feedback function is r = W S S+W D D and S are information content-weighted structural similarity indexes (IW-SSIM), and D is the detection image DI. t W is the Euclidean distance between the center of each image and the center of the target object to be inspected by the drone. S and W D The weighting coefficients and the feedback function r directly reflect the detection image DI. t The quality.

[0057] In this embodiment, the discrete fine-tuning control mode implementation process includes: selecting the maximum positive and negative displacement adjustment amount ΔP of the UAV. max and the maximum positive and negative angle adjustment ΔDmax ; for ΔP max Divide ΔD into n1 equal parts. max Divide the sample into n² equal parts, then Δp = ΔP max / n1 is the displacement adjustment interval of the UAV, Δd=ΔD max / n2 is the angle adjustment interval of the UAV. The values ​​of displacement adjustment Δx, Δy and Δu in a are -n1Δp, -(n1-1)Δp, ..., -2Δp, -Δp, 0, +Δp, +2Δp, ..., +(n1-1)Δp, +n1Δp. The values ​​of angle adjustment Δα, Δβ and Δγ are -n2Δd, -(n2-1)Δd, ..., -2Δd, -Δd, 0, +Δd, +2Δd, ..., +(n2-1)Δd, +n2Δd.

[0058] In this embodiment, the HDNN determines the state s based on the state. t By analyzing the specific characteristics of different information, specialized deep neural network structures composed of ADCNN and FGRNN are set up for targeted analysis and processing, which can effectively enhance the feature extraction capability and thus significantly improve the fitting accuracy and efficiency of the Q(s,a) function value.

[0059] S3. Perform simulation training on the HDNN to obtain the UAV flight state correction model (ASCM). The specific implementation process includes:

[0060] S3-1. Set two action value functions Q(s,a) and Q′(s,a), where Q(s,a) is fitted by an HDNN and Q′(s,a) is fitted by an auxiliary HDNN with the same structure as the HDNN; initialize the HDNN and the auxiliary HDNN with the same set of random weight parameters; initialize the experience replay buffer R to an empty set {}; initialize the number of training cycles E and the number of training rounds per step Rd to 0.

[0061] S3-2. Determine if the amount of data stored in R has reached its capacity limit. max If the target has been reached, discard the earliest stored data sets to reduce the number of data sets stored in R to less than O. max If the target is not reached, a single-step training round begins, using HDNN to analyze the state s at the current time t. t We obtain Q(s,a) at time t; we determine whether the number of training rounds Rd in a single step has reached the policy transition threshold SW. If not, we select action a according to Q(s,a) using the ε-greedy policy. t Execute; if achieved, select action a according to Q(s,a) using the following formula. t Execute: Where c is the exploration coefficient, and Nt (a) represents the number of times each action in action space a has been selected before time t; retrieve action a. t The new state s after execution t+1 and feedback r t ; will s t a t r t and s t+1 The quaternion [s] t ,a t ,r t ,s t+1 The data is stored as a set of data in the playback buffer R.

[0062] S3-3. Determine whether the number of quadruplets stored in R exceeds the lower capacity limit O. min If the limit is not exceeded, return to step S3-2; if the limit is exceeded, randomly sample N quadruplets from R; calculate each sampled quadruplet [s] using Q′(s,a) fitted by the auxiliary HDNN. n ,a n ,r n ,s n+1 The individual loss function value l n =(r n +ymax a Q'(s n+1 ,a)-Q(s n ,a n )) 2 , where y is the discount factor; take the average of the individual loss function values ​​of the N quadruples to obtain the target loss function value L; minimize the target loss function value L using the gradient descent method, update the weight parameters of the HDNN, complete one single-step training round, and increment the value of Rd by 1.

[0063] S3-4. Determine if the value of Rd is an integer multiple of the number of synchronization rounds C. If so, assign the weight parameters of HDNN to the auxiliary HDNN.

[0064] S3-5. Determine if the value of Rd has reached the upper limit Rd. max If the condition has been met, increment the value of E by 1 and clear the value of Rd to zero, then proceed to step S3-6. If the condition has not been met, return to step S3-2.

[0065] S3-6. Determine if E has reached its upper limit. max If the target has been reached, the training process ends; otherwise, return to step S3-2.

[0066] Since traditional reinforcement learning based on ε-greedy strategies neglects potential optimal actions, leading to action selection easily getting stuck in suboptimal or local optima, this invention improves the action selection strategy during HDNN training by combining ε-greedy strategies with... By combining these approaches, and by conducting biased explorations based on the potential or uncertainty of a suboptimal action becoming the optimal action, training quality can be effectively improved, thereby better meeting the needs of power grid security situational awareness.

[0067] S4. Load the UAV flight state correction model into the UAV's flight control program, and use the UAV to inspect actual power transmission lines. In close-range inspection mode, the ASCM analyzes state s using the Q(s,a) function fitted by the HDNN. t To predict the impact of various flight pose correction commands composed of different vectors in the action space a on the detected image DI t The quality of the image is determined by the influence of the feedback function value r. Then, the optimal command with the highest expected image quality, i.e. the highest predicted value of the feedback function value r, is executed to stabilize the UAV's flight attitude, thereby improving the quality of the inspection image, enhancing the inspection accuracy and efficiency, and strengthening the power grid security situation awareness capability.

[0068] Preferably, in this embodiment, transfer learning can be carried out before the actual inspection begins to fine-tune the existing weights of the HDNN so as to better adapt to the actual inspection site in a shorter time, thereby further improving the inspection accuracy and efficiency and enhancing the power grid security situation awareness capability.

[0069] Furthermore, the ADCNN proposed in Embodiment 1 of this invention is as follows: Figure 3 As shown, ADCNN is used to detect the image DI at time t. t CI of each image in the sequence j The process of sensing environmental state information includes the following steps:

[0070] (1) DI t The sequence is fed into a two-dimensional convolution module to process the DI. t Each image in CI j Two-dimensional dilated convolution is performed separately to generate a set of convolutional feature maps M. t-k M t-k+1 ,…,M j ,…,M t-2 M t-1 M t The two-dimensional convolution module consists of n3 two-dimensional dilated convolutional layers stacked one on top of the other. The convolutional kernels of the two-dimensional dilated convolutional layers have zero-element holes, which can achieve a larger local receptive field than conventional convolutional kernels without increasing the weight parameters. This enables ADCNN to perceive environmental state information more efficiently and comprehensively from a wider image area.

[0071] (2) Take the absolute value of each element in each convolutional feature map to obtain a set of absolute value feature maps AM. t-k AM t-k+1 ,…,AM j ,…,AM t-2 AM t-1 AM t Global average pooling is performed on each channel of the absolute value feature map to obtain a set of pooling vectors g. t-k ,g t-k+1 ,…,g j ,…,g t-2 ,g t-1 ,g t .

[0072] (3) Each pooling vector is used as the input to the second fully connected neural network. The operation performed in the second Dense Net is as follows:

[0073] ts j =RELU(W d1 g j +b d1 (1)

[0074] av j =sigmoid(W d2 ts j +b d2 (2)

[0075] Among them, ts j It is a transition vector, W d1 With W d2 Let b be the weight matrix. d1 With b d2 Given the bias vector, ReLU and sigmoid are the activation functions. The operation in (1) can be performed multiple times as needed, while the operation in (2) is performed only once. After the operations in (1) and (2), a set of output vectors av is obtained. t-k ,av t-k+1 ,…,av j ,…,av t-2 ,av t-1 ,av t Then, each output vector is multiplied element-wise by its corresponding pooling vector to obtain a set of disturbance rejection parameter vectors A. t-k A t-k+1 ,…,A j ,…,A t-2 A t-1 A t A j The dimension is equal to the number of channels in the convolutional feature map.

[0076] (4) Multiply each convolutional feature map element-wise with each perturbation parameter vector to obtain the perturbation-resistant convolutional feature map. Unfold the perturbation-resistant convolutional feature map to obtain the output feature sequence F. t - k ,F t-k+1 ,…,F j ,…,F t-2 ,F t-1 ,F t .

[0077] In step (3), each output vector is multiplied element-wise with each pooling vector, which means multiplying av element-wise. t-k With g t-k Element-wise multiplication, av t-k+1 With g t-k+1 Multiply element by element, and so on.

[0078] In step (4), multiplying each convolutional feature map element-wise with each perturbation parameter vector means: multiplying M... t-k With A t-k Element-wise multiplication, M t-k+1 With A t-k+1 Multiply element by element, and so on.

[0079] The ADCNN proposed in Embodiment 1 of this invention can comprehensively and accurately perceive environmental state information while effectively suppressing interference signals, thereby effectively enhancing the control decision-making capability of ASCM.

[0080] Furthermore, the FGRNN proposed in Embodiment 1 of this invention is as follows: Figure 4 As shown, the first FGRNN is used to start from F t-k ,F t-k+1 ,…,F j ,…,F t-2 ,F t-1 ,F t Extract temporal features and use the second FGRNN to extract the flight state AS at time t. t The process of extracting temporal features from a sequence includes the following steps:

[0081] (1) Generate the update gate z of the first FGRNN or the second FGRNN at the j-th time step using the following formula. j and reset door r j :

[0082] (z j ,r j ) = sigmoid(z j ',r j ') (3)

[0083] Where sigmoid is the activation function, z j =DDA(Z) j G z B z ) and r j =DDA(R) j G r B r ) represent the update gate z of the first FGRNN or the second FGRNN at the j-th time step. j and reset door r j The intermediate process vector; DDA represents data distribution adjustment, Z j =W z h j-1 +U z x j +b z With R j =W r h j-1 +U r x j +b r It is an intermediate data vector, with dimensions H and G. z With G r It is the gain vector, B z and B r The bias vector is the bias vector, and both the gain vector and the bias vector are trainable weight vectors; in the intermediate data vector Z j and R j In the middle, x j Let F be the input feature vector of the first or second FGRNN at the j-th time step. j or PD j h j-1 W is the hidden state generated by the first or second FGRNN at the (j-1)th time step. z U z W r and U r Let b be the weight matrix. z and b r This is the bias vector.

[0084] (2) Calculate the internal cell state c of the first FGRNN or the second FGRNN at the j-th time step. j :

[0085]

[0086] c j =RELU(c j ') (5)

[0087] Among them, c j′ is c j The intermediate value of W is calculated. c and U c It is the weight matrix, b c It is a bias vector. ReLU represents element-wise multiplication; its computational complexity is much lower than that of the hyperbolic tangent activation function tanh commonly used in traditional recurrent neural networks, and its derivative is always 1 when the input is positive, which is higher than the maximum derivative of tanh. Therefore, using ReLU helps to increase the gradient during error backpropagation, thereby effectively improving the learning efficiency of FGRNN.

[0088] (3) Calculate the extended weight vector E of the first FGRNN or the second FGRNN at the j-th time step. j :

[0089] E j =λE j-1 +ηc j c j T (6)

[0090] Where λ and η are the extended weight parameters; E j-1 This represents the extended weight vector of the first or second FGRNN at the (j-1)th time step.

[0091] In FGRNN, such as W c and b z Traditional weights, such as those used in embodiment 1, require learning at least one mini-batch of data before updating, resulting in slow learning and decay speeds and an inability to fully reflect the influence of recent historical data. Furthermore, the learning capability of traditional weights is limited by the capacity of the weight matrix and bias vector. Therefore, the FGRNN in embodiment 1 of this invention introduces extended weights E. j Unlike traditional weights, E j Instead of creating new neurons and iteratively updating using gradient descent, it utilizes existing computational results c. j c j T and E j-1 And by combining two parameters λ and η, it is directly acquired through autoassociative memory. Therefore, E is introduced. j This approach can effectively increase the model's weight capacity without significantly increasing computational overhead, thereby enhancing the model's learning ability and accelerating convergence. Furthermore, compared to traditional weights, E... j It can fully reflect the impact of historical data that is closer to the current time, which is conducive to improving accuracy indicators.

[0092] (4) Calculate the hidden state h generated by the first FGRNN or the second FGRNN at the j-th time step. j:

[0093]

[0094] in, This represents element-wise addition.

[0095] (5) For each h generated by the first FGRNN or the second FGRNN j Feature enhancement processing is performed to obtain the feature enhancement vector HR. t That is, the first eigenvector V 1t Or the second eigenvector V 2t The specific process of feature enhancement includes:

[0096] e j =v·tanh(Wh) j +b) (8)

[0097]

[0098]

[0099] Where tanh is the hyperbolic tangent activation function, W is the weight matrix, b is the bias vector, v is the weight vector, and e is the weight vector. j for h j The corresponding initial computing power weight, as j This represents the computing power weight.

[0100] Traditional recurrent neural networks (RNNs) need to store all the features they learn in the hidden state output at the last time step. When the input data sequence is long, the limited storage capacity of the hidden state cannot completely record all features, and some key features are discarded, leading to a decline in learning ability. To address this, the FGRNN in Embodiment 1 of this invention introduces feature enhancement processing to fully utilize the useful information in all the hidden states it generates, thereby avoiding the loss of key information caused by using only the hidden state at the last time step. Simultaneously, feature enhancement processing rationally allocates computational weights to each hidden state to strengthen the role of key features and suppress interference from secondary information, further improving the learning ability of the FGRNN.

[0101] Overall, the FGRNN proposed in Embodiment 1 of this invention utilizes self-associative memory and the threshold principle to achieve higher learning ability and efficiency than traditional recurrent neural networks, and its parameter tuning is simpler. Therefore, its introduction into HDNN can effectively improve the convergence speed during ASCM training and the control accuracy during application.

[0102] Furthermore, calculate z of the first FGRNN or the second FGRNN. j 'and r jDuring the process of ', the Data Distribution Adjustment (DDA) process includes:

[0103] (1) Calculate the mean μ and variance σ of the intermediate data vector. 2 :

[0104]

[0105]

[0106] Among them, X i For the intermediate data vector Z j or R j The elements in the array are i = 1, 2, ..., H.

[0107] (2) Standardize the distribution of elements in the intermediate data vector:

[0108]

[0109] Among them, X i Z' is the intermediate data vector. j or R j The elements in the vector are normalized values, where ε is a positive number that approaches 0 to prevent division by zero. After normalization, a large number of elements in the intermediate data vector fall into the linear region of non-linear activation functions such as sigmoid, increasing the gradient and thus improving the learning speed of FGRNN.

[0110] (3) Standard normalization severely weakens FGRNN's ability to fit nonlinear functional relationships and destroys the knowledge FGRNN acquires from learning the input data, thus negatively impacting the training effect of FGRNN. Therefore, DDA must further adjust the distribution of elements in the intermediate data vector after standard normalization:

[0111] Y i =gn i X i '+ba i (14)

[0112] Among them, Y i For each element in the adjusted intermediate data vector, gn i It is the gain vector G z or G r The i-th element in the array, ba i It is the bias vector B z Or B r The i-th element in gn i with ba iAll of these are trainable weight parameters. After the above adjustments, the mean and variance of the elements in the intermediate data vector shift relative to the standard normal distribution, and a considerable number of elements fall back into the nonlinear regions at both ends of the nonlinear activation function. Thus, the FGRNN's ability to fit nonlinear functional relationships is restored, and the knowledge learned by the FGRNN is retained.

[0113] DDA (Distributed Algorithm Analysis) adjusts the distribution of elements in the intermediate data vector based on standard normalization, concentrating most elements within a reasonable range of the nonlinear activation function. This increases the gradient while maintaining the FGRNN's ability to fit nonlinear functional relationships, without compromising the knowledge learned by the FGRNN. Therefore, DDA effectively improves the convergence speed of FGRNN. Furthermore, DDA enhances the generalization ability of FGRNN and reduces its sensitivity to hyperparameters, thus simplifying parameter tuning.

[0114] In summary, to address the problem that existing UAVs are easily affected by airflow disturbances during close-range inspections, resulting in insufficient stability in flight position and attitude, and thus difficulty in providing high-quality information for power grid safety situation awareness, Embodiment 1 of this invention proposes a UAV inspection method for power grid safety situation awareness. This method utilizes the powerful feature learning and control decision-making capabilities of deep learning and reinforcement learning, two artificial intelligence technologies, to correct the UAV's flight state, significantly enhancing the stability of the UAV's flight position and attitude during close-range inspections. This improves the quality of UAV-detected images, ultimately achieving the goal of improving the accuracy and efficiency of transmission line inspections and enhancing the power grid safety situation awareness capability.

[0115] Example 2

[0116] Embodiment 2 of the present invention provides a terminal device corresponding to Embodiment 1 above. The terminal device can be a processing device for a client, such as a mobile phone, a laptop, a tablet computer, a desktop computer, etc., to execute the method of the above embodiments.

[0117] The terminal device in this embodiment includes a memory, a processor, and a computer program stored in the memory; the processor executes the computer program in the memory to implement the steps of the method in Embodiment 1 described above.

[0118] In some implementations, the memory may be high-speed random access memory (RAM), and may also include non-volatile memory, such as at least one disk storage device.

[0119] In other implementations, the processor can be any type of general-purpose processor, such as a central processing unit (CPU) or a digital signal processor (DSP), and there is no limitation here.

[0120] Example 3

[0121] Embodiment 3 of the present invention provides a computer-readable storage medium corresponding to Embodiment 1 above, on which a computer program / instructions are stored. When the computer program / instructions are executed by a processor, they implement the steps of the method of Embodiment 1 above.

[0122] A computer-readable storage medium can be a tangible device that holds and stores instructions for use by an instruction execution device. A computer-readable storage medium can be, for example, but not limited to, an electrical storage device, a magnetic storage device, an optical storage device, an electromagnetic storage device, a semiconductor storage device, or any combination thereof.

[0123] Those skilled in the art will understand that embodiments of this application can be provided as methods, systems, or computer program products. Therefore, this application can take the form of a completely hardware embodiment, a completely software embodiment, or an embodiment combining software and hardware aspects. Furthermore, this 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 code. The solutions in the embodiments of this application can be implemented in various computer languages, such as the object-oriented programming language Java and the interpreted scripting language JavaScript.

[0124] This application is described with reference to flowchart illustrations and / or block diagrams of methods, apparatus (systems), and computer program products according to embodiments of this application. It will be understood that each block of the flowchart illustrations and / or block diagrams, and combinations of blocks in the flowchart illustrations and / or block diagrams, can be implemented by computer program instructions. These computer program instructions can be provided to a processor of a general-purpose computer, special-purpose computer, embedded processor, or other programmable data processing apparatus to produce a machine, such that the instructions, which execute via the processor of the computer or other programmable data processing apparatus, generate instructions for implementing the flowchart... Figure 1 One or more processes and / or boxes Figure 1 A device that provides the functions specified in one or more boxes.

[0125] These computer program instructions may also be loaded onto a computer or other programmable data processing equipment to cause a series of operational steps to be performed on the computer or other programmable equipment to produce a computer-implemented process, thereby providing instructions that execute on the computer or other programmable equipment for implementing the process. Figure 1 One or more processes and / or boxes Figure 1 The steps of the function specified in one or more boxes.

[0126] Although preferred embodiments of this application have been described, those skilled in the art, upon learning the basic inventive concept, can make other changes and modifications to these embodiments. Therefore, the appended claims are intended to be interpreted as including the preferred embodiments as well as all changes and modifications falling within the scope of this application.

[0127] Obviously, those skilled in the art can make various modifications and variations to this application without departing from the spirit and scope of this application. Therefore, if such modifications and variations fall within the scope of the claims of this application and their equivalents, this application also intends to include such modifications and variations.

Claims

1. A method for unmanned aerial vehicle (UAV) inspection for power grid security situation awareness, characterized in that, Includes the following steps: S1. Construct the state space, where the state s at any time t is... t Including the detection image DI of the drone at time t t and flight status AS t ;Detection image DI at time t t CI is a sequence of images (CI) taken by a drone at time t and k previous times, arranged in chronological order. t-k, CI t-k+1 ,…,CI j ,…,CI t-2 CI t-1 CI t CI j =[VI j IR j UI j ], VI j A visible light image taken at time j, IR j Infrared image taken at time j, UI j The ultrasound image taken at time j, where j = tk, t-k+1, ..., t-2, t-1, t; and the flight state AS at time t. t PD is a sequence of pose information vectors of the UAV at time t and the previous k times arranged in chronological order. t-k ,PD t-k+1 ,…,PD j ,…,PD t-2 ,PD t-1 ,PD t ; where PD j =[x j ,y j ,u j ,α j ,β j ,γ j ], x j y j and u j These are the three-dimensional coordinates of the UAV's flight position in the Earth coordinate system at time j, and α. j β j and γ j These are the yaw angle, pitch angle, and roll angle of the UAV at time j, respectively. S2. Construct a hybrid deep neural network, which includes an anti-perturbation convolutional neural network, a first fast-threshold recurrent neural network, a second fast-threshold recurrent neural network, and a first fully connected neural network; the anti-perturbation convolutional neural network is connected to the first fast-threshold recurrent neural network; the first fast-threshold recurrent neural network and the second fast-threshold recurrent neural network are both connected to the first fully connected neural network; the detection image DI at time t is... t As the input to the anti-perturbation convolutional neural network, the flight state AS at time t t The sequence serves as the input to the second fast-gated recurrent neural network; the output of the first fully connected neural network is Q(s,a) at time t, where Q(s,a) represents the state s. t Below, the predicted value of the feedback function obtained after the UAV performs each action in the action space; where the action space a = [Δx, Δy, Δu, Δα, Δβ, Δγ], Δx is the displacement adjustment of the UAV on the horizontal axis in the body coordinate system, Δy is the displacement adjustment of the UAV on the vertical axis in the body coordinate system, Δu is the displacement adjustment of the UAV in the vertical direction in the body coordinate system, Δα is the yaw angle adjustment of the UAV, Δβ is the pitch angle adjustment of the UAV, and Δγ is the roll angle adjustment of the UAV. Δx, Δy, Δu, Δα, Δβ, and Δγ all adopt discrete fine-tuning control mode; the feedback function r = W S S+W D D and S are structural similarity indices based on information content weighting, and D is the detection image DI. t W is the Euclidean distance between the center of each image and the center of the target object to be inspected by the drone. S and W D The weighting coefficients and the feedback function r directly reflect the detection image DI. t The quality; preferably, the discrete fine-tuning control mode implementation process includes: selecting the maximum positive and negative displacement adjustment amount ΔP of the UAV. max and the maximum positive and negative angle adjustment ΔD max ; for ΔP max Divide ΔD into n1 equal parts. max Divide the sample into n² equal parts, then Δp = ΔP max / n1 is the displacement adjustment interval of the UAV, Δd=ΔD max / n2 is the angle adjustment interval of the UAV. The values ​​of displacement adjustment Δx, Δy and Δu in a are -n1Δp, -(n1-1)Δp, ..., -2Δp, -Δp, 0, +Δp, +2Δp, ..., +(n1-1)Δp, +n1Δp. The values ​​of angle adjustment Δα, Δβ and Δγ are -n2Δd, -(n2-1)Δd, ..., -2Δd, -Δd, 0, +Δd, +2Δd, ..., +(n2-1)Δd, +n2Δd. S3. Simulate and train the hybrid deep neural network to obtain the UAV flight state correction model.

2. The UAV inspection method for power grid security situation awareness according to claim 1, characterized in that, The process of obtaining the output of the first fully connected neural network, i.e., the value of the Q(s,a) function at time t, includes: Using the perturbation-resistant convolutional neural network, from the detection image DI at time t t CI of each image in the sequence j The system senses environmental state information and obtains the output feature sequence F. t-k ,F t-k+1 ,…,F j ,…,F t-2 ,F t-1 ,F t Using the first fast threshold recurrent neural network from F t-k ,F t-k+1 ,…,F j ,…,F t-2 ,F t-1 ,F t Extracting temporal features yields the first feature vector V. 1t Using the second fast threshold recurrent neural network, the flight state AS at time t is obtained. t Extracting temporal features from the sequence yields the second feature vector V. 2t ; Serial splicing the first feature vector V 1t Second eigenvector V 2t The concatenated vector V t As input to the first fully connected neural network, the Q(s,a) function value at time t is obtained.

3. The UAV inspection method for power grid security situation awareness according to claim 2, characterized in that, Using the perturbation-resistant convolutional neural network, from the detection image DI at time t t CI of each image in the sequence j The process of sensing environmental state information includes the following steps: For DI t Each image in CI j Two-dimensional dilated convolution is performed separately to generate a set of convolutional feature maps M. t-k M t-k+1 ,…,M j ,…,M t-2 M t-1 M t ; By taking the absolute value of each element in each convolutional feature map, a set of absolute value feature maps (AM) is obtained. t-k AM t-k+1 ,…,AM j ,…,AM t-2 AM t-1 AM t Global average pooling is performed channel-by-channel on each of the absolute value feature maps to obtain a set of pooling vectors g. t-k ,g t-k+1 ,…,g j ,…,g t-2 ,g t-1 ,g t ; Each of the pooling vectors is used as input to the second fully connected neural network to obtain a set of output vectors av. t-k ,av t-k+1 ,…,av j ,…,av t-2 ,av t-1 ,av t Each output vector is element-wise multiplied with its corresponding pooling vector to obtain a set of disturbance rejection parameter vectors A. t-k A t-k+1 ,…,A j ,…,A t-2 A t-1 A t A j The dimension is equal to the number of channels in the convolutional feature map; Each convolutional feature map is element-wise multiplied with the corresponding perturbation parameter vector to obtain the perturbation-resistant convolutional feature map. The perturbation-resistant convolutional feature map is then unfolded to obtain the output feature sequence F. t-k ,F t-k+1 ,…,F j ,…,F t-2 ,F t-1 ,F t .

4. The UAV inspection method for power grid security situation awareness according to claim 2, characterized in that, Using the first fast threshold recurrent neural network from F t-k ,F t-k+1 ,…,F j ,…,F t-2 ,F t-1 ,F t Extracting temporal features, and using the second fast threshold recurrent neural network to extract the flight state AS at time t. t The process of extracting temporal features from a sequence includes the following steps: The update gate z at the j-th time step is generated using the following formula: (This formula is used to generate the update gate z of either the first or second fast-gated recurrent neural network.) j and reset door r j :(z j ,r j ) = sigmoid(z j ',r j '); where sigmoid is the activation function, z j =DDA(Z) j G z B z ) and r j =DDA(R) j G r B r ) represent the update gate z of the first fast-gated recurrent neural network or the second fast-gated recurrent neural network at the j-th time step. j and reset door r j The intermediate process vector; DDA represents data distribution adjustment, Z j =W z h j-1 +U z x j +b z With R j =W r h j-1 +U r x j +b r It is an intermediate data vector, with dimensions H and G. z With G r It is the gain vector, B z and B r The bias vector is the bias vector, and both the gain vector and the bias vector are trainable weight vectors; in the intermediate data vector Z j and R j In the middle, x j F is the input feature vector of the first or second fast-gated recurrent neural network at the j-th time step. j or PD j h j-1 W is the hidden state generated by either the first fast-gated recurrent neural network or the second fast-gated recurrent neural network at the (j-1)th time step. z U z W r and U r Let b be the weight matrix. z and b r It is the bias vector; Calculate the internal cell state c of the first fast-gated recurrent neural network or the second fast-gated recurrent neural network at the j-th time step. j :c j =RELU(c j '); where c j ′ is c j The intermediate value of the calculation W c and U c It is the weight matrix, b c It is a bias vector. This represents element-wise multiplication; Calculate the extended weight vector E of the first fast threshold recurrent neural network or the second fast threshold recurrent neural network at the j-th time step. j E j =λE j-1 +ηc j c j T Where λ and η are extended weight parameters; E j-1 This represents the extended weight vector of the first fast-gated recurrent neural network or the second fast-gated recurrent neural network at the (j-1)th time step; Calculate the hidden state h generated by the first fast threshold recurrent neural network or the second fast threshold recurrent neural network at the j-th time step. j : in, This represents element-wise addition; For each h generated by the first fast threshold recurrent neural network or the second fast threshold recurrent neural network j Feature enhancement processing is performed to obtain the feature enhancement vector, which is the first feature vector V. 1t Or the second eigenvector V 2t .

5. The UAV inspection method for power grid security situation awareness according to claim 4, characterized in that, Calculate z of the first fast threshold recurrent neural network or the second fast threshold recurrent neural network. j 'and r j During the process of ', the Data Distribution Adjustment (DDA) process includes: Calculate the mean of the intermediate data vector. With variance Among them, X i For the intermediate data vector Z j Or R j The elements in the array; i = 1, 2, ..., H; Standardize the distribution of elements in the intermediate data vector to normal: Among them, X i Z' is the intermediate data vector. j Or R j The values ​​of each element in the matrix after standard normalization, ε is a positive number that approaches 0 infinitely; The distribution of elements in the intermediate data vector is adjusted using the following formula: Y i =gn i X i '+ba i ; where Y i For each element in the adjusted intermediate data vector, gn i It is the gain vector G z or G r The i-th element in the array, ba i It is the bias vector B z Or B r The i-th element in gn i with ba i All of these are trainable weight parameters.

6. The UAV inspection method for power grid security situation awareness according to claim 1, characterized in that, The specific implementation process of training the hybrid deep neural network includes: S3-1. Set two action value functions Q(s,a) and Q′(s,a), where Q(s,a) is fitted by the hybrid deep neural network, and Q′(s,a) is fitted by an auxiliary hybrid deep neural network with the same structure as the hybrid deep neural network; initialize the hybrid deep neural network and the auxiliary hybrid deep neural network with the same set of random weight parameters; initialize the experience replay buffer R to an empty set {}; initialize the number of training cycles E and the number of training rounds per step Rd to 0; S3-2. Determine if the amount of data stored in R has reached its capacity limit. max If the target has been reached, discard the earliest stored data sets to reduce the number of data sets stored in R to less than O. max If the target is not reached, a single-step training round begins, and the state s at the current time t is analyzed using the hybrid deep neural network. t We obtain Q(s,a) at time t; we determine whether the number of training rounds Rd in a single step has reached the policy transition threshold SW. If not, we select action a according to Q(s,a) using the ε-greedy policy. t Execute; if achieved, select action a according to Q(s,a) using the following formula. t Execute: Where c is the exploration coefficient, and N t (a) represents the number of times each action in action space a has been selected before time t; retrieve action a. t The new state s after execution t+1 and feedback r t ; will s t a t r t and s t+1 The quaternion [s] t ,a t ,r t ,s t+1 This data is stored as a set of data in the playback buffer R; S3-3. Determine whether the number of quadruplets stored in R exceeds the lower capacity limit O. min If the limit is not exceeded, return to step S3-2; if the limit is exceeded, randomly sample N quadruplets from R; calculate each sampled quadruplet [s] using Q′(s,a) fitted by the auxiliary hybrid deep neural network. n ,a n ,r n ,s n+1 The individual loss function value l n =(r n +y max a Q'(s n+1 ,a)-Q(s n ,a n )) 2 , where y is the discount factor; take the average of the individual loss function values ​​of the N quadruples to obtain the target loss function value L; minimize the target loss function value L using the gradient descent method, update the weight parameters of the hybrid deep neural network, complete one single-step training round, and increment the value of Rd by 1; S3-4. Determine whether the value of Rd is an integer multiple of the number of synchronization rounds C. If so, assign the weight parameters of the hybrid deep neural network to the auxiliary hybrid deep neural network. S3-5. Determine if the value of Rd has reached the upper limit Rd. max If the condition has been met, increment the value of E by 1 and clear the value of Rd to zero, then proceed to step S3-6; otherwise, return to step S3-2. S3-6. Determine if E has reached its upper limit. max If the target has been reached, the training process ends; otherwise, return to step S3-2.

7. The UAV inspection method for power grid security situation awareness according to any one of claims 1 to 6, characterized in that, Also includes: S4. Load the UAV flight status correction model into the UAV flight control program and use the UAV to inspect the actual power transmission line.

8. The UAV inspection method for power grid security situation awareness according to claim 7, characterized in that, Before using drones to inspect actual power transmission lines, the parameters of the drone flight state correction model are adjusted using a transfer learning method.

9. A terminal device, comprising a memory, a processor, and a computer program stored in the memory; characterized in that, The processor executes the computer program to implement the steps of the method according to any one of claims 1 to 8.

10. A computer-readable storage medium having a computer program / instructions stored thereon; characterized in that, When the computer program / instructions are executed by the processor, they implement the steps of the method according to any one of claims 1 to 8.

Citation Information

Patent Citations

  • Unmanned aerial vehicle remote power transmission line intelligent inspection system and method

    CN112731960A

  • Distribution network routing inspection method combining high-precision positioning of the unmanned aerial vehicle and visual tracking technology

    CN113485441A