Method and system for dynamic restoration of power inspection images based on meteorological data fusion
By constructing a dynamic restoration method for power line inspection images based on meteorological data fusion, and utilizing visual guidance and RAM-Net network, the problems of clarity and stability of power line inspection images under dynamic micro-meteorological scenarios are solved. Adaptive adjustment of image parameters and artifact suppression are achieved, thereby improving the detection accuracy and reliability of power line inspection.
Patent Information
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- NANTONG SECONDARY VOCATIONAL SCHOOL JIANGSU PROVINCE
- Filing Date
- 2026-03-17
- Publication Date
- 2026-06-16
AI Technical Summary
Existing power line inspection image processing technologies are unable to adapt in real time under dynamic micro-meteorological scenarios, resulting in problems such as decreased image clarity, blurred details, color shift, and edge halos. This affects the detection accuracy and stability of key components, and macro-meteorological data is difficult to apply in a refined manner, leading to artifacts and insufficient timeliness.
By constructing a dynamic restoration method for power line inspection images based on meteorological data fusion, a visually guided spatial compensation model and RAM-Net network are used, combined with a time-dependent attenuation function and gradient-guided filtering method, to achieve adaptive adjustment of image parameters, integrate macro-meteorological data with local micro-meteorological features, suppress artifacts, and improve image clarity.
It has improved image clarity and stability, ensuring the accuracy and reliability of key component inspection, adapting to complex and changeable weather, and meeting the needs of real-time drone inspection.
Smart Images

Figure CN122222845A_ABST
Abstract
Description
Technical Field
[0001] This invention relates to a method and system for dynamic restoration of power grid inspection images based on meteorological data fusion, belonging to the field of smart grid visual perception and power grid inspection image processing technology. Background Technology
[0002] Power grid inspection is a crucial link in ensuring the safe and stable operation of the power grid. With the widespread adoption of drone inspections, image / video-based visual defect detection, channel environment identification, and hazard discovery have become mainstream methods. However, transmission lines often traverse complex terrain areas such as mountains, hills, and valleys. Affected by factors such as topographic uplift, radiative cooling, and wind shear, local micro-meteorological conditions exhibit significant spatial heterogeneity and rapid temporal changes. For example, the same line may experience dense fog or patches of fog in the early morning, turning into light haze at noon; visibility differences between mountaintops and valleys are significant, and fog patches may suddenly intensify or dissipate within a short period. These factors can easily lead to problems such as decreased contrast, blurred details, color cast, and edge halos in inspection images, thereby affecting the inspection accuracy and stability of critical components such as conductors, insulators, hardware, and towers.
[0003] Existing image restoration techniques (such as dehazing) mainly include physical model-based methods and deep learning-based methods, but they still have shortcomings in the dynamic micro-meteorological scenarios of power line inspection. (1) Fixed weather assumptions and static parameter limitations: Traditional physical models (such as atmospheric scattering model restoration based on dark channel priors) often assume that atmospheric light, transmittance and other parameters are relatively stable over the entire image or a period of time, and rely on fixed or empirically set parameters. When faced with the situation that visibility changes rapidly with time and geographical location during the inspection process, static parameters are difficult to match the environment in real time, and are prone to insufficient or excessive defogging, loss of detail and color distortion.
[0004] (2) Lack of environmental awareness and temporal adaptability: Many deep learning dehazing models are trained offline on static datasets and the parameters are fixed after the model is deployed. When encountering sudden micro-meteorological fluctuations in real inspections (such as sudden fog formation, sudden humidity changes, and rapid changes in light), it is difficult to dynamically adjust the restoration intensity according to the environmental changes of "current time - current location", resulting in unstable processing effects and even artifacts.
[0005] (3) The separation between macro-meteorological data and specific image scenes: Currently, meteorological departments or power grid systems can provide gridded macro-meteorological data (such as visibility, humidity, air pressure, etc.) through meteorological information platforms. However, such data usually reflects the average state at a large spatial scale (e.g., kilometer-level grid) and the updates are periodic, making it difficult to directly characterize fine-grained changes such as local fog patches and valley microenvironments within the current field of view of the UAV. Existing image processing methods often fail to effectively utilize these big meteorological data to form interpretable and computable prior constraints, thus failing to achieve "spatial downscaling correction" of macro-data and "timeliness reliability assessment" of update delays.
[0006] (4) Fine structures such as power lines are prone to introducing restoration artifacts: targets such as power transmission lines and ground wires have slender, high-frequency structural features. When estimating transmittance using traditional dark channels and window filtering, they are easily affected by the sky background or neighborhood aliasing, producing artifacts such as halos and over-enhancement at the edges of the conductors, reducing the fidelity of edges and small targets, which is not conducive to subsequent defect identification.
[0007] In summary, there is an urgent need for a power line inspection image restoration solution that integrates meteorological big data, visual features of inspection images, and historical time-series meteorological information. On the one hand, it uses macro-meteorological information as a priori, achieving spatial compensation through visual guidance to refine macro-meteorological data into local micro-meteorological parameters suitable for the current inspection scenario. On the other hand, it constructs a modeling mechanism for meteorological time-series evolution and abrupt changes, adaptively allocating reliable weights to macro-meteorological data based on data timeliness and environmental volatility. Simultaneously, during image restoration, a gradient guidance strategy is employed for the fine structure of transmission lines to effectively suppress halo artifacts. Through these multi-dimensional mechanisms, the image restoration model can dynamically adjust restoration parameters according to the inspection time and geographical location, thereby improving the clarity and stability of power line inspection images under complex and variable weather conditions, providing a high-quality image foundation for subsequent defect detection. Summary of the Invention
[0008] To overcome the shortcomings of existing technologies, this invention provides a method and system for dynamic restoration of power line inspection images based on meteorological data fusion. The technical solution of this invention is as follows: A method for dynamic restoration of power line inspection images based on meteorological data fusion includes the following steps: Step S10: Acquire the inspection image I and its corresponding spatiotemporal coordinates x, y, t in real time, and synchronously acquire the macro-meteorological data stream of the area through the meteorological interface, including the previous update time t. api Visibility benchmark V api ; Step S20: Construct a visually guided spatial compensation model, extract the dark channel features of the inspection image I, and, combined with historical meteorological big data statistical benchmarks, construct a dynamic correction factor for the macro-meteorological data V. apiSpatial downscaling correction is performed to obtain the local spatial micrometeorological parameter V. local ; Step S30: Construct a micro-meteorological sensing network RAM-Net based on residual attention mechanism, and use historical meteorological sequences to predict the current moment. Weather evolution trend value V api And construct a time difference-based The time-dependent decay function is used to calculate the real-time weighting coefficient λ. Step S40: Using weighting coefficients For space micrometeorological parameters V local With time evolution trend value Perform weighted fusion to generate dynamic target parameters V final The physical atmospheric scattering model is then used to adaptively restore the inspection image I.
[0009] In step S20, the local micro-meteorological parameter V local The calculation formula is: ; Among them, J dark This is the dark channel image of a real-time image. β is the historical dark channel reference for this grid region, β is the reference adjustment hyperparameter, and γ is the visual-physical mapping hyperparameter.
[0010] Historical Dark Passage Benchmark of the Region The construction method is as follows: The inspection area is divided into geographical grids, historical image samples and corresponding meteorological tags are retrieved, image subsets under similar meteorological conditions are selected, the dark channel statistical mean of the image subset is calculated, and a prior database containing geographical information is constructed to eliminate the interference of terrain background on the algorithm.
[0011] In step S30, the timeliness decay function is an adaptive decay model based on environmental volatility perception, and its calculation formula is as follows: ;in, Based on the attenuation hyperparameter, For volatility-sensitive hyperparameters, It is a normalized volatility index for historical meteorological series, used to quantify the severity of meteorological changes; This represents the time difference between the current moment and the moment the API data was updated.
[0012] In step S30, the structure of the RAM-Net network includes: Bi-LSTM (Bi-Long Short-Term Memory) network is used to encode historical weather sequences in both forward and reverse directions and extract hidden state features h. i ; Time-sensitive attention mechanism, through Calculate the contribution weights of each time step to the current prediction and generate global features C, where v represents the attention vector hyperparameters, W represents the attention weight hyperparameters, and b represents the attention bias hyperparameters. The residual correction path outputs the predicted value at the current time step. ,in, The actual observed macroscopic visibility value at the previous update time t0, obtained from the API interface. This is the meteorological visibility residual correction function obtained by fitting based on global feature C.
[0013] The training process of the RAM-Net network includes: Pre-training phase: Based on historical meteorological time-series data, the training process was conducted for 50 epochs using the MSE loss function, with a learning rate of 5×10⁻⁶. -5 ; Joint training phase: The pre-trained RAM-Net is jointly trained with the overall restoration model to optimize the image restoration quality.
[0014] In step S40, the dynamic target parameter V final The fusion formula is: ;in, The current time t is the macroscopic visibility prediction value of the RAM-Net network based on historical meteorological data series. This fusion process realizes the dynamic complementarity between macroscopic meteorological evolution trends and local visual features, ensuring that the restoration parameters are adaptively adjusted with time and space.
[0015] The dark channel diagram J dark The gradient-guided adaptive weighted minimum filter method is used for calculation, and its formula is as follows: Where G(q) is the gradient magnitude, Here, p represents the target pixel in the image to be calculated, and q represents the pixels in the neighborhood of the target pixel. represents the adaptive neighborhood window for the target pixel p, with its size dynamically adjusted based on gradient features to suppress halo artifacts at the edges of electric field lines; c represents the RGB color channel dimension of the image. Let q be the pixel value of pixel q in color channel c.
[0016] In the physical atmospheric scattering model, the transmittance t is determined by the dynamic target parameter V. final The derivation leads to: , where k is the atmospheric scattering coefficient, which is fixed at 1.2.
[0017] A system for implementing the dynamic restoration method of power line inspection images based on meteorological data fusion includes: Data acquisition module: Deployed on the UAV, it is used to collect inspection images I and spatiotemporal coordinates x, y, t in real time, and synchronously acquire macro meteorological data streams through the meteorological interface; Spatial compensation module: used to extract dark channel features from images and, combined with historical meteorological big data statistical benchmarks, calculate local micro-meteorological parameters V. local ; Time-series forecasting module: Includes a built-in RAM-Net network for predicting the current meteorological evolution trend based on historical meteorological sequences. And calculate the timeliness weight coefficient λ; Fusion Restoration Module: Used for V local and Perform weighted fusion to generate dynamic target parameters V final And drive the physical atmospheric scattering model to adaptively restore the image; Control module: Used to coordinate the data flow and timing control of each module to ensure that the system runs in real time during the UAV inspection process.
[0018] The advantages of this invention are: 1. Cross-modal fusion of macro-meteorological data and visual features of inspection images was achieved. The spatial downscaling correction of macro-meteorological data was completed through a vision-guided spatial compensation model, which accurately adapted to the local micro-meteorological conditions of the current field of view of the UAV and solved the problem of separation between macro-meteorological data and specific image scenes. 2. A time-series evolution model based on RAM-Net was constructed. It combines bidirectional LSTM and time-sensitive attention mechanism to capture meteorological nonlinear abrupt change characteristics. With the addition of a time-sensitive decay function that is aware of environmental volatility, adaptive weight allocation in the time dimension is realized, which solves the problem of lack of time-series adaptability in existing methods. 3. The gradient-guided adaptive weighted minimum filtering method is used to calculate the dark channel image, dynamically adjust the neighborhood window and introduce edge protection hyperparameters, which effectively suppresses the restoration halo artifacts of fine structures such as power lines and towers, and improves the fidelity of image edges and small targets. 4. The restoration parameters are dynamically and adaptively adjusted according to the inspection time and geographical location, which can cope with complex micro-meteorological scenarios such as dense fog, patchy fog, and sudden changes in humidity, significantly improving the contrast and detail clarity of the inspection images, and ensuring the accuracy and stability of subsequent defect identification. 5. The method is implemented end-to-end, with high computational efficiency, and is suitable for engineering application scenarios such as real-time inspection of power transmission lines by drones. It has strong practicality and generalization ability. Attached Figure Description
[0019] Figure 1 This is a flowchart of the dynamic restoration method for power inspection images based on meteorological data fusion proposed in this invention.
[0020] Figure 2 This is a schematic diagram illustrating the principle of extracting dark channel features from inspection images in this invention.
[0021] Figure 3 This is a schematic diagram of the structure of the micro-meteorological sensing network (RAM-Net) in this invention.
[0022] Figure 4 This is a block diagram of the main structure of the system of the present invention. Detailed Implementation
[0023] The present invention will be further described below with reference to specific embodiments, and the advantages and features of the present invention will become clearer as a result. However, these embodiments are merely exemplary and do not constitute any limitation on the scope of the present invention. Those skilled in the art should understand that modifications or substitutions can be made to the details and form of the technical solutions of the present invention without departing from the spirit and scope of the present invention, but all such modifications and substitutions fall within the protection scope of the present invention.
[0024] This embodiment provides a method for restoring power line inspection images based on meteorological data fusion. The overall process is as follows: Figure 1 As shown, the main steps include cross-modal dynamic data acquisition (S10), construction of a visually guided spatial compensation model (S20), construction of a RAM-Net-based temporal evolution model (S30), and parameter dynamic fusion and adaptive restoration (S40).
[0025] See Figures 1 to 4 This invention relates to a method for dynamic restoration of power line inspection images based on meteorological data fusion, comprising the following steps: Step S10: Acquire the inspection image I and its corresponding spatiotemporal coordinates x, y, t in real time, and synchronously acquire the macro-meteorological data stream of the area through the meteorological interface, including the previous update time t. api Visibility benchmark V api ; Step S20: Construct a visually guided spatial compensation model, extract the dark channel features of the inspection image I, combine historical meteorological big data statistical benchmarks, construct a dynamic correction factor, perform spatial downscaling correction on the macro meteorological data Vapi, and obtain the local spatial micro-meteorological parameter Vlocal. Step S30: Construct a micro-meteorological sensing network RAM-Net based on residual attention mechanism, use historical meteorological sequences to predict the meteorological evolution trend value Vapi at the current time t, and construct a time difference-based network... The time-dependent decay function is used to calculate the real-time weighting coefficient. ; Step S40: Using weighting coefficients Space micrometeorological parameters With time evolution trend value Perform weighted fusion to generate dynamic target parameters. The physical atmospheric scattering model is then used to adaptively restore the inspection image I.
[0026] In step S20, local micro-meteorological parameters The calculation formula is: ; Where Jdark is the dark channel image of the real-time image. β is the historical dark channel reference for this grid region, β is the reference adjustment hyperparameter, and γ is the visual-physical mapping hyperparameter.
[0027] Historical Dark Passage Benchmark of the Region The construction method is as follows: The inspection area is divided into geographical grids, historical image samples and corresponding meteorological tags are retrieved, image subsets under similar meteorological conditions are selected, the dark channel statistical mean of the image subset is calculated, and a prior database containing geographical information is constructed to eliminate the interference of terrain background on the algorithm.
[0028] In step S30, the timeliness decay function is an adaptive decay model based on environmental volatility perception, and its calculation formula is as follows: ;in, Based on the attenuation hyperparameter, For volatility-sensitive hyperparameters, It is a normalized volatility index for historical meteorological series, used to quantify the severity of meteorological changes; This represents the time difference between the current moment and the moment the API data was updated.
[0029] In step S30, the structure of the RAM-Net network includes: Bi-LSTM (Bi-Long Short-Term Memory) network is used to encode historical meteorological sequences in both forward and reverse directions and extract hidden state features hi. Time-sensitive attention mechanism, through Calculate the contribution weights of each time step to the current prediction and generate global features C, where v represents the attention vector hyperparameters, W represents the attention weight hyperparameters, and b represents the attention bias hyperparameters. The residual correction path outputs the predicted value at the current time step. ,in, The last update time obtained for the API interface Actual observed macroscopic visibility. For global features The meteorological visibility residual correction function obtained by fitting.
[0030] The training process of the RAM-Net network includes: Pre-training phase: Based on historical meteorological time-series data, the training process was conducted for 50 epochs using the MSE loss function, with a learning rate of 5×10⁻⁶. -5 ; Joint training phase: The pre-trained RAM-Net is jointly trained with the overall restoration model to optimize the image restoration quality.
[0031] In step S40, the fusion formula for the dynamic target parameter Vfinal is: ;in, The current moment predicted by the RAM-Net network based on historical meteorological data series. The macroscopic visibility forecast, through this fusion process, achieves dynamic complementarity between macroscopic meteorological evolution trends and local visual features, ensuring that the restoration parameters adapt to changes in time and space.
[0032] The dark channel image Jdark is calculated using a gradient-guided adaptive weighted minimum filtering method, and its formula is as follows: Where G(q) is the gradient magnitude, Here, p represents the target pixel in the image to be calculated, and p is the edge protection hyperparameter. For pixels in the neighborhood of the target pixel, An adaptive neighborhood window for the target pixel p, the window size is dynamically adjusted according to the gradient features, used to suppress halo artifacts at the edges of the electric field lines; For the RGB color channel dimensions of the image, For pixels In color channels The pixel values on the screen.
[0033] The present invention also relates to a system for implementing the aforementioned dynamic restoration method for power line inspection images based on meteorological data fusion, comprising: Data acquisition module 1: Deployed on the UAV, it is used to collect inspection images I and spatiotemporal coordinates x, y, t in real time, and synchronously acquire macro meteorological data streams through the meteorological interface; Spatial compensation module 2: used to extract dark channel features of images and calculate local micro-meteorological parameters Vlocal by combining historical meteorological big data statistical benchmarks; Time-series forecasting module 3: Includes a built-in RAM-Net network for predicting the current meteorological evolution trend based on historical meteorological sequences. And calculate the timeliness weight coefficient λ; Fusion Restoration Module 4: Used for Vlocal and Weighted fusion is performed to generate dynamic target parameters Vfinal, which then drive the physical atmospheric scattering model to adaptively restore the image. Control module 5: Used to coordinate the data flow and timing control of each module to ensure that the system operates in real time during the UAV inspection process.
[0034] (I) Basic Experimental Setup 1. Dataset Configuration: This experiment uses a dual data source to construct a comprehensive dataset, totaling 150,000 samples, covering complex terrains such as mountains, hills, valleys, and plains. It includes eight typical micro-meteorological scenarios, such as dense fog, patchy fog, light haze, rain-fog mixtures, and snow-fog superpositions, ensuring the comprehensiveness of the model's generalization ability verification. The first part consists of three years of accumulated data from UAV inspections of transmission lines by a provincial power grid company, and the second part is a publicly available power line inspection image dataset (with authoritative meteorological labels). All samples are divided into a training set (105,000 samples), a validation set (15,000 samples), and a test set (30,000 samples) in a 7:1:2 ratio. Each sample set includes "inspection image + spatiotemporal coordinates". , , +Weather data labels (visibility) "+Real and clear images (synchronously acquired or manually labeled and calibrated for non-degradable scenes)." During data preprocessing, all images were uniformly set to 1920×1080 resolution. Data augmentation strategies such as random horizontal flipping (probability 0.5), brightness ±10% fine-tuning, and adding Gaussian noise (variance 0.001) were employed to avoid model overfitting. Meteorological data labels were uniformly normalized to [missing information]. The interval is used to optimize training convergence efficiency.
[0035] 2. Hardware and Software Environment: In terms of hardware configuration, the CPU uses an Intel Ultra 7 (20 cores, 40 threads), and the GPU uses an NVIDIA RTX 4090 (24GB VRAM) to ensure efficient model training and inference. The software environment is built on the Ubuntu 22.04 LTS operating system, using the PyTorch 2.0.1 deep learning framework and Python 3.9.16 programming language, coupled with CUDA 11.8 and CuDNN 8.7 for accelerated computing. This system can be deployed on the edge computing module of a power line inspection drone (such as the NVIDIA Jetson series), or on a ground control station or cloud server.
[0036] 3. Basic training parameters: The model is trained using the AdamW optimizer, with an initial learning rate set to... Weight decay Maximum training iterations: 300 epochs. The first 30 epochs are the warm-up phase (learning rate starts from...). linear growth to Cosine annealing decay (decay factor 0.95) is used for 30-250 epochs, and a fixed learning rate is used for 250-300 epochs. Fine-tuning. Five core dimensions were selected as evaluation metrics: Peak Signal-to-Noise Ratio (PSNR, measuring the sharpness of image restoration), Structural Similarity (SSIM, measuring the structural consistency between the restored image and the real image), and the improvement rate of object detection accuracy. Based on YOLOv8, the system detects key components of power transmission lines and compares the detection accuracy, artifact rate (AR, which is the percentage of pixels of artifacts such as halos at the edge of power lines) and inference time (ms / frame, which measures real-time performance) before and after restoration, comprehensively quantifying the restoration effect.
[0037] like Figure 1 As shown, the cross-modal dynamic data acquisition in step S10 specifically involves: During power plant drone inspections, high-definition cameras mounted on the drones capture real-time inspection images (I), and simultaneously use GPS modules to obtain the corresponding spatiotemporal coordinates. , , GPS positioning accuracy Timestamp synchronization error The image acquisition frequency is consistent with the spatiotemporal coordinates (10 frames / second). Simultaneously, macroscopic meteorological data streams for this coordinate region are acquired synchronously through a dedicated meteorological information interface for the power grid, with a focus on extracting the data from the previous update time. Visibility benchmark The interface updates data every 30 minutes, with a single data transmission delay of [missing information]. Visibility benchmark The unit is "meter (m)," with a value range of 50-5000m and a data accuracy of ±10m. In the data association stage, the macro-meteorological data obtained from the API is matched to the corresponding inspection images according to a 1km×1km geographic grid to ensure accurate correspondence between "image-meteorology-spatiotemporal," providing basic data support for subsequent spatial compensation and temporal modeling.
[0038] Furthermore, such as Figure 1 As shown, the construction of the visually guided spatial compensation model in step S20 specifically involves: First, the dark channel features of the real-time inspection image I are extracted and statistical values are calculated. Specifically, the "gradient-guided adaptive weighted minimum filtering method" is used to calculate the dark channel image. The principle is as follows Figure 2 As shown, the formula is as follows: ; in, The gradient magnitude is calculated using the 3×3 Sobel operator. The edge protection hyperparameter is set to 0.05 (preferred value 0.05, range 0.01-0.1). The target pixel to be calculated in the image. for Pixels within the neighborhood, As an adaptive neighborhood window, its size is dynamically adjusted based on gradient features -- when When (corresponding to the edge area of power lines, towers, etc.), the window size is set to 3×3 to protect the delicate structure; when When the background area is in use, the window size is set to 7×7 to improve statistical stability. For the RGB color channel dimensions of the image, For pixels In the passage The pixel values on the screen can be dynamically adjusted using this formula to avoid halo artifacts at the edges of power lines.
[0039] To verify the edge protection hyperparameters The rationality of the optimal value was determined using the "controlling a single variable" principle. Other parameters were fixed as optimal values, and only the target parameter was changed. Performance evaluation was performed on the test set, and the comparative experimental results are shown in the table below:
[0040] The experimental results show that Insufficient edge protection means that slight halo artifacts still exist at the edges of power lines, leading to a decrease in detection accuracy and clarity. Excessive edge protection can blur the overall details of the image, causing a significant decline in various metrics; while When the model achieves the optimal balance between effectively suppressing power line edge artifacts and preserving image details, it performs best in all core evaluation indicators, verifying the rationality of the optimal value.
[0041] Subsequently, the historical meteorological big data statistical characteristics of the region were introduced as a regional benchmark to construct a regional historical dark channel benchmark. The inspection area is divided into 1km×1km geographical grids. Historical images of each grid from the past three years under different seasons and meteorological conditions are retrieved, and images of similar meteorological conditions (visibility deviation) are filtered. %) of the sample subsets (number of samples in each subset) 500), calculate the dark channel statistical mean of the subset (retain 2 decimal places), establish an environmental prior database containing geographical location information, update the database once a month to ensure the timeliness of the benchmark, thereby eliminating the interference of different terrain backgrounds on the algorithm.
[0042] A dynamic correction factor is constructed based on the ratio relationship between real-time visual features and historical regional benchmarks. This correction factor is then used to adjust macro-meteorological data. Spatial refinement corrections are performed to calculate local micro-meteorological parameters at the current geographical location. The calculation formula is as follows:
[0043] in, This represents the median statistical value of the real-time dark channel plot. Adjust the hyperparameters based on the baseline (preferred value 1.0, range 0.8-1.2). The hyperparameters for the visual-physical mapping are (preferred value 0.8, range 0.5-1.5). Both parameters are determined by grid search on the validation set (search step size 0.1), with the goal of maximizing the mean values of PSNR and SSIM. This formula can adaptively adjust the local visibility estimate based on the deviation between the current image and historical big data, thereby achieving spatial downscaling correction of macro meteorological data.
[0044] Furthermore, such as Figure 1 As shown, the construction of the RAM-Net-based temporal evolution model in step S30 specifically involves: To address the nonlinear characteristics of weather changes over time, a micro-weather sensing network based on residual attention (RAM-Net) is constructed to predict the current moment using historical weather data sequences. Meteorological evolution trend value .
[0045] The core temporal feature extraction unit of the RAM-Net network adopts a single-hidden-layer bidirectional LSTM (Bi-LSTM) structure, and its network structure is as follows: Figure 3 As shown, the specific configuration is as follows: The number of hidden units was set to 64. This number has been verified to be suitable for capturing short-term trends in meteorological time series data, and can balance computational efficiency and feature representation ability. Only visibility time series data is input, which can simplify the model complexity and focus on core meteorological factors. The regularization strategy adopts a dropout probability of 0.5 to suppress training overfitting, while not using recurrent dropout to avoid distortion in the propagation of time series features.
[0046] The sequence input specification is for inputting past data. The meteorological sequence at each time point (time span 6 hours, sampling frequency 1 hour / time, pre-training data sampling frequency independent of model input sequence, used to enhance the ability to capture temporal features), that is, each input sample is [ , ..., The 1×6 dimension vector can cover the short-term key window of meteorological changes; in terms of feature encoding, Bi-LSTM encodes the input sequence from both the forward (past-present) and backward (present-past) directions, and outputs a 128-dimensional (i.e., 64×2) bidirectional hidden state feature h. i It can fully capture the dependencies between time series data.
[0047] A time-sensitive attention mechanism is introduced to calculate the contribution weight of each historical moment to the current mutation. ,in The hyperparameters for the 128-dimensional attention vector are randomly initialized with a mean of 0 and a variance of 0.01. The attention weight hyperparameter is 256×256 dimension. A 128-dimensional attention bias hyperparameter (initial value 0.1) is used to generate global features C; a trend-corrected residual path is constructed to output the current time-to-time predicted value. ,in The last update time obtained for the API interface Actual observed macroscopic visibility. The residual correction function is a 3-layer fully connected network (input dimension 256, intermediate layer dimension 512, activation function GELU, output dimension 1, dropout probability 0.2).
[0048] The network training adopts a "pre-training + joint training" strategy: first, it is pre-trained for 50 epochs using meteorological time-series data of the region over the past 5 years (100,000 sequences, sampling frequency 10 minutes / time) (AdamW optimizer, learning rate...). The MSE loss function is then used to train the model in conjunction with the overall restoration model to ensure the ability to capture the characteristics of meteorological changes.
[0049] At the same time, construct a time difference-based system The time-dependent decay function is used to calculate the real-time weighting coefficient. The function adopts an "adaptive decay model based on environmental volatility perception", and the formula is as follows: ; in, The basic aging decay hyperparameter is set at 0.1 (preferred value 0.1, range 0.05-0.2). This is a volatility-sensitive hyperparameter (preferred value 0.2, range 0.1-0.3). This represents the time difference (in hours) between the current time and the API data update time. If the time difference exceeds 2 hours, Automatically set to 1.0 (considered a drastic weather change); The normalized volatility index for historical meteorological data series is calculated using a 1-hour calculation window (based on the meteorological data of the previous 60 minutes). The formula is as follows:
[0050] in, Standard deviation, The mean value is within a certain range. It is used to characterize the severity of recent weather changes.
[0051] To verify the basic aging decay hyperparameter The rationality of the optimal value was determined using the "controlling a single variable" principle. Other parameters were fixed as optimal values, and only the target parameter was changed. Performance evaluation was performed on the test set, and the comparative experimental results are shown in the table below:
[0052] The experimental results show that The slow decay of timeliness in meteorological data can cause interference to the fusion of local micro-meteorological parameters, reducing the accuracy of reconstruction. The rapid decay of weather data leads to the loss of effective macro-meteorological evolution trend information, making it impossible for the model to accurately capture meteorological change patterns; while In this way, the model can accurately assess the timeliness of macro-meteorological data, achieve the optimal weight allocation between macro-meteorological evolution trends and local visual features, and achieve the best restoration effect, thus verifying the scientific nature of the optimal value.
[0053] Furthermore, such as Figure 1 As shown, the parameter dynamic fusion and adaptive restoration described in step S40 specifically includes: Using real-time weighting coefficients For space micro-meteorological parameters With time evolution trend value Perform weighted fusion to generate dynamic target parameters specific to the current scene. The fusion formula is as follows:
[0054] To ensure the parameters are reasonable, The range of values is limited to If the calculated result exceeds the range, it will be automatically truncated to the corresponding boundary value (set to 50m if below 50m, set to 500m if above 5000m). This fusion process achieves the complementarity between macro-level meteorological evolution trends and micro-level local visual features, ensuring that the restoration algorithm parameters are dynamically adjusted according to changes in time and location.
[0055] Will Substituting an improved physical atmospheric scattering model, the image restoration algorithm is dynamically driven to process real-time inspection images. After refining, the core formula of the atmospheric scattering model is:
[0056] in, The input is a degraded inspection image. The restored, clear image; The atmospheric light component is calculated from the RGB mean of the top 0.1% bright pixels in the dark channel image; t is the transmittance, derived from the dynamic target parameters. Adaptive derivation, the formula is: , The atmospheric scattering coefficient is fixed at 1.2 (verified through extensive experiments to be suitable for power line inspection scenarios). In the post-processing stage of restoration, [the following is applied]... Adaptive contrast enhancement using the CLAHE algorithm (8×8 kernel size, contrast threshold limited to 2.0) further improves the identification of key components of transmission lines, providing a better image basis for subsequent defect detection.
[0057] (III) Experimental Results and Comparative Analysis This invention selects four mainstream image restoration algorithms as comparison benchmarks. All algorithms use the same dataset, hardware environment and evaluation metrics to ensure the fairness of the comparison: traditional physical models (dark channel prior DCP, histogram equalization HE) and deep learning models (general dehazing state-of-the-art model FFA-Net, power line inspection-specific dehazing model PD-Net).
[0058]
[0059] As shown in the table, in terms of clarity and structural consistency, the PSNR of this invention is improved by 3.3 dB and the SSIM is improved by 0.048 compared to the power-specific model PD-Net, indicating that the restored image is closer to the real and clear image, and the details of conductors, insulators, etc. are preserved more completely; in terms of defect detection adaptability, Compared to PD-Net, it achieves a 9.3 percentage point improvement, with an artifact rate (AR) of only 1.8%, far lower than other algorithms. This demonstrates that the gradient-guided dark channel calculation method effectively suppresses power line edge halo artifacts, significantly improving the reliability of subsequent defect detection. Regarding real-time performance and engineering adaptability, the inference time is 22ms / frame, meeting the real-time processing requirements of UAV inspection. (Frame), balancing performance and efficiency, can be directly deployed in embedded terminals of drones.
[0060] The above description is only a preferred embodiment of the present invention, but the scope of protection of the present invention is not limited thereto. Any equivalent substitutions or modifications made by those skilled in the art within the scope of the technology disclosed in the present invention, based on the technical solution and inventive concept of the present invention, should be covered within the scope of protection of the present invention.
Claims
1. A method for dynamic restoration of power line inspection images based on meteorological data fusion. Its features are, Includes the following steps: step S10: Real-time acquisition of inspection image I and its corresponding spatiotemporal coordinates x, y, t, and synchronous acquisition of macro-meteorological data stream for the region via meteorological interface, including the previous update time t. api Visibility benchmark V api ; Step S20: Construct a visually guided spatial compensation model, extract the dark channel features of the inspection image I, and, combined with historical meteorological big data statistical benchmarks, construct a dynamic correction factor for the macro-meteorological data V. api Spatial downscaling correction is performed to obtain the local spatial micrometeorological parameter V. local ; Step S30: Construct a micro-meteorological sensing network RAM-Net based on residual attention mechanism, and use historical meteorological sequences to predict the current moment. Weather evolution trend value V api And construct a time difference-based The time-dependent decay function is used to calculate the real-time weighting coefficient. ; Step S40: Using weighting coefficients For space micrometeorological parameters V local With time evolution trend value Perform weighted fusion to generate dynamic target parameters V final The physical atmospheric scattering model is then used to adaptively restore the inspection image I.
2. The method for dynamic restoration of power line inspection images based on meteorological data fusion according to claim 1, characterized in that, In step S20, the local micro-meteorological parameter V local The calculation formula is: ; Among them, J dark This is the dark channel image of a real-time image. β is the historical dark channel reference for this grid region, β is the reference adjustment hyperparameter, and γ is the visual-physical mapping hyperparameter.
3. The method for dynamic restoration of power line inspection images based on meteorological data fusion according to claim 2, characterized in that, Historical Dark Passage Benchmark of the Region The construction method is as follows: The inspection area is divided into geographical grids, historical image samples and corresponding meteorological tags are retrieved, image subsets under similar meteorological conditions are selected, the dark channel statistical mean of the image subset is calculated, and a prior database containing geographical information is constructed to eliminate the interference of terrain background on the algorithm.
4. The method for dynamic restoration of power line inspection images based on meteorological data fusion according to claim 1, characterized in that, In step S30, the timeliness decay function is an adaptive decay model based on environmental volatility perception, and its calculation formula is as follows: ;in, Based on the attenuation hyperparameter, For volatility-sensitive hyperparameters, It is a normalized volatility index for historical meteorological series, used to quantify the severity of meteorological changes; This represents the time difference between the current moment and the moment the API data was updated.
5. The method for dynamic restoration of power line inspection images based on meteorological data fusion according to claim 1, characterized in that, In step S30, the structure of the RAM-Net network includes: Bi-LSTM (Bi-Long Short-Term Memory) network is used to encode historical meteorological sequences in both forward and reverse directions and extract hidden state features h. i ; Time-sensitive attention mechanism, through Calculate the contribution weight of each time step to the current prediction, and generate a global feature C, where This represents the attention vector hyperparameters. This represents the attention weight hyperparameter. This represents the attention bias hyperparameter; The residual correction path outputs the predicted value at the current time step. ,in, The last update time obtained for the API interface Actual observed macroscopic visibility. For global features The meteorological visibility residual correction function obtained by fitting.
6. The method for dynamic restoration of power line inspection images based on meteorological data fusion according to claim 5, characterized in that, The training process of the RAM-Net network includes: Pre-training phase: Based on historical meteorological time-series data, the training process was conducted for 50 epochs using the MSE loss function, with a learning rate of 5×10⁻⁶. -5 ; Joint training phase: The pre-trained RAM-Net is jointly trained with the overall restoration model to optimize the image restoration quality.
7. The method for dynamic restoration of power line inspection images based on meteorological data fusion according to claim 1, characterized in that, In step S40, the dynamic target parameter V final The fusion formula is: ;in, The current moment predicted by the RAM-Net network based on historical meteorological data series. The macroscopic visibility forecast, through this fusion process, achieves dynamic complementarity between macroscopic meteorological evolution trends and local visual features, ensuring that the restoration parameters adapt to changes in time and space.
8. The method for dynamic restoration of power line inspection images based on meteorological data fusion according to claim 2, characterized in that, The dark channel diagram J dark The gradient-guided adaptive weighted minimum filter method is used for calculation, and its formula is as follows: Where G(q) is the gradient magnitude, For edge protection hyperparameters, The target pixel to be calculated in the image. For the pixels in the neighborhood of the target pixel, For target pixel An adaptive neighborhood window, whose size is dynamically adjusted according to gradient features, is used to suppress halo artifacts at the edges of power lines; For the RGB color channel dimensions of the image, For pixels In color channels The pixel value on the screen.
9. The method for dynamic restoration of power line inspection images based on meteorological data fusion according to claim 1, characterized in that, In the physical atmospheric scattering model, the transmittance t is determined by the dynamic target parameter V. final The derivation leads to: , where k is the atmospheric scattering coefficient, which is fixed at 1.
2.
10. A system for implementing the dynamic restoration method for power line inspection images based on meteorological data fusion as described in any one of claims 1 to 9, characterized in that, include: Data acquisition module: Deployed on the UAV, it is used to collect inspection images I and spatiotemporal coordinates x, y, t in real time, and synchronously acquire macro meteorological data streams through the meteorological interface; Spatial compensation module: used to extract dark channel features from images and, combined with historical meteorological big data statistical benchmarks, calculate local micro-meteorological parameters V. local ; Time-series forecasting module: Includes a built-in RAM-Net network for predicting the current meteorological evolution trend based on historical meteorological sequences. And calculate the timeliness weighting coefficient. ; Fusion Restoration Module: Used for V local and Perform weighted fusion to generate dynamic target parameters V final And drive the physical atmospheric scattering model to adaptively restore the image; Control module: Used to coordinate the data flow and timing control of each module to ensure that the system runs in real time during the UAV inspection process.