End-to-End Image Compression with Segmentation Guided Dual Coding for Wind Turbines
Authors: Raül Pérez-Gonzalo, Andreas Espersen, Søren Forchhammer, Antonio Agudo
Organizations: Wind Power LAB, 1150 Copenhagen, Denmark · Institut de Robòtica i Informàtica Industrial, CSIC-UPC, 08028 Barcelona, Spain · Department of Photonics Engineering, Technical University of Denmark (DTU), 2800 Lyngby, Denmark
Transferring large volumes of high-resolution images during wind turbine inspections introduces a bottleneck in assessing and detecting severe defects. Efficient coding must preserve high fidelity in blade regions while aggressively compressing the background. In this work, we propose an end-to-end deep learning framework that jointly performs segmentation and dual-mode (lossy and lossless) compression. The segmentation module accurately identifies the blade region, after which our region-of-interest (ROI) compressor encodes it at superior quality compared to the rest of the image. Unlike conventional ROI schemes that merely allocate more bits to salient areas, our framework integrates: (i) a robust segmentation network (BU-Netv2+P) with a CRF-regularized loss for precise blade localization, (ii) a hyperprior-based autoencoder optimized for lossy compression, and (iii) an extended bits-back coder with hierarchical models for fully lossless blade reconstruction. Furthermore, our ROI framework removes the sequential dependency in bits-back coding by reusing background-coded bits, enabling parallelized and efficient dual-mode compression. To the best of our knowledge, this is the first fully integrated learning-based ROI codec combining segmentation, lossy, and lossless compression, ensuring that subsequent defect detection is not compromised. Experiments on a large-scale wind turbine dataset demonstrate superior compression performance and efficiency, offering a practical solution for automated inspections.
Figures & tables
Fig. 1 : Overview of our ROI algorithm for blade image compression . Our method begins by extracting a segmentation mask using our proposed BU-Netv2+P. This mask is converted into a polygonal representation by classifying image patches as either blade (ROI) or background. The polygon mask is then efficiently encoded via its corner points. The background is highly compressed with our lossy coder, while the blade region is coded either lossily –in better quality and less distortion– or losslessly. In ROI lossless case, the background is first encoded to provide its lossy bitstream for parallel bits-back coding.
Fig. 2 : BU-Netv2+P algorithm pipeline to segment blades : 1) an enhanced BU-Netv2, 2) a hole filling step, 3) a random forest module that exploits the input image set and the preliminary solution and, 4) a repeated hole filling operation.
Fig. 3 : Hole filling scheme. Example of artifact removal inside the segmented blade region ( s^BU ). The method detects blade orientation to locate border edges (in red) and applies a standard hole-filling algorithm [ 19 ] to produce the mask s^H .
Fig. 4 : Overview of HP+EASN-deep hierarchical model and architecture. Left-side illustrates the 2-level nested variable model, where latent variables z1 and z2 are obtained during encoding hϕ and quantized Q . Right-side shows the architecture, a symmetric 2-layer autoencoder composed of convolutional and up/downsampling blocks with non-linear activations.
Fig. 5 : Network architecture corresponding to the decoder transforms : pθ(x∣z1) and pθ(zl∣zl+1) for l∈{1,…,L−1} . The arrows indicate the direction of the forward pass.
Fig. 6 : Order of the encoding and decoding operations for a standard hierarchical bits-back and for its optimized scheme on a L -level nested variable model for lossless compression.
Fig. 7 : Acceptance-ratio curves of each segmentation step. Θaccuracy and Θrecall similarity metrics are displayed in the top and bottom sides, respectively. On the right column, the lefts plots are zoomed on the black dashed area.
Performance
BU-Netv2
Fill holes
Random forest
Fill holes 2
metric
s^BU
s^H1
s^RF
s^≡s^H2
Accuracy [%]
96.82
96.98
97.54
97.61
Recall [%]
96.41
96.61
97.54
97.67
F1-score [%]
95.60
95.72
96.44
96.50
Table I : Performance results of each segmentation step .
Method
Accuracy
Recall
F1-score
mIoU
Relative
Relative
[%]
[%]
[%]
[%]
accuracy
recall
U-Net [ 29 ]
86.24
68.93
77.95
75.94
1
1
DeepLabv3+ [ 27 ]
94.14
87.38
89.03
87.47
1.09
1.27
SW [ 28 ]
93.48
91.71
91.37
87.44
1.08
1.33
ResNeSt [ 34 ]
94.23
91.47
92.77
89.63
1.09
1.33
U-NetFormer [ 35 ]
96.20
93.51
94.42
91.75
1.12
1.36
Table II : Quantitative comparison on blade segmentation with respect to state-of-the-art methods. Models marked with an asterisk only propose segmentation regions without a class; results assume a perfect region classifier.
Fig. 8 : Acceptance-ratio curves of comparison techniques. Θaccuracy and Θrecall similarity metrics are displayed in the left and right parts, respectively.
Fig. 9 : Rate-distortion curves for state-of-the-art lossy coders . Learning-based curves for each distortion loss metric: PSNR (left) or MS-SSIM (right) with red regions zoomed (middle). Non-learning-based coders are depicted with dashed lines.
Performance
Compression Time
Decompression Time
Coding
BD-rate
BD-rate
Minimum
Maximum
Mean
Slope
Minimum
Maximum
Mean
Slope
scheme
[PSNR]
[MS-SSIM]
time [s]
time [s]
time [s]
growth [s/bit]
time [s]
time [s]
time [s]
growth [s/bit]
HP [ 11 ]
15.35
5.81
5.76
6.17
5.96
0.25
6.51
15.60
12.83
5.57
HP+EASN-deep [ 21 ]
0
0
6.46
6.95
6.64
0.26
7.86
15.35
12.74
4.00
JA [ 51 ]
2.55
-6.04
200.68
204.19
203.01
1.96
442.74
458.26
451.08
8.69
JA+EASN-deep [ 21 ]
2.14
-1.11
200.53
205.75
203.42
2.83
443.54
458.08
453.10
7.88
Table III : BD-rate, compression and decompression times of a full-resolution image for state-of-the-art lossy coders.
Coding
Mean
Std
scheme
bit rate [bit/pix]
bit rate [bit/pix]
Bit-swap
8.98
1.70
PNG [ 42 ]
11.33
1.64
BPG [ 45 ]
11.61
2.19
JPEG2000 [ 10 ]
10.41
1.69
WebP [ 43 ]
10.17
1.77
Table IV : Compression performance of a full-resolution image for the distinct state-of-the-art lossless coders. Std denotes the standard deviation across test images.
Compression
Decompression
Coding
Mean
Std
Mean
Std
scheme
time [s]
time [s]
time [s]
time [s]
Bit-swap
5688
21.56
4367
19.64
PNG [ 42 ]
11.35
2.28
9.8
1.96
BPG [ 45 ]
7.22
0.49
14.03
1.99
JPEG2000 [ 10 ]
7.03
0.89
18.78
4.91
Table V : Compression and decompression times of a full-resolution image for state-of-the-art lossless coders. Std denotes the standard deviation across test images.
Fig. 10 : Proportion of ROI width along the pressure side of a wind turbine blade . Red numbers denote the i -th image.
Fig. 11 : Blade pictures compressed with our proposed ROI algorithm . The first column showcases the images compressed using the lossy HP+EASN-deep coder with two distinct rate-distortion models on the blade ( [ζ=0.1]⋅ MSE) and background ( [ζ=0.01]⋅ MSE), whereas the third column presents these blade regions compressed losslessly. Second and fourth column represent their left column images augmented and gray-scaled, so the high-frequency components can be visualized and compared. The sub-captions indicate the PSNR, MS-SSIM and bit/px. See Fig. 8 from Supplementary for the original images.
Fig. 1 : Four example instances of the blade imagery dataset . The complexity on this data arises due to the background variation and wild illumination conditions.
Fig. 2 : Validation accuracy after applying the random forest step with distinct sets of input pixels . The performance is analyzed in terms of the number of local pixel neighbors taken as input n and the distance d between these input pixels. The purple horizontal line represents the accuracy obtained before applying the random forest step.
Fig. 3 : Windfarm test performance of each segmentation step . For readability, the plot does not include every windfarm.
Fig. 4 : Qualitative comparison evaluation between BU-Netv1+P and our approach BU-Netv2+P . The figure depicts on the left side the test images x and its ground truth mask s ; on the inner side the segmentation steps of BU-Netv1+P (from left to right columns: BU-Netv1, first hole filling, random forest, second hole filling); and on the right side the the steps of our proposed segmentation algorithm BU-Netv2+P (from left to right columns: BU-Netv2 s^BU , first hole filling s^H1 , random forest ensemble s^RF and second hole filling s^≡s^H2 ).
Fig. 5 : Failure cases on test images after running each segmentation step . First column: input color image x . From second to fifth column: BU-Netv2 s^BU , first hole filling s^H1 , random forest ensemble s^RF and second hole filling s^≡s^H2 estimations, respectively. On both sides, the same information is displayed.
Fig. 6 : Computational time in seconds of an individual image for each segmentation step . Computational time for the BU-Net, hole filling and random forest steps are reported. The blue line represents the cumulative time.
Fig. 7 : Additional bits per pixel of information required to decompress each rate-distortion model of HP+EASN-deep.
Figure 24
Fig. 8 : Quality assessment of two blade pictures with high compression rates . The first row showcases the complete original images, whereas the second row presents a zoomed-in image accompanied by two different compression rates. Sub-captions indicate the distortion loss term and the compression performance. Red regions indicated with numbers pinpoint the following artifacts: 1) blocking artifacts, 2) smoothed contours, 3) smoothed textures and 4) visual color scale change.
Fig. 9 : Compression and decompression time of a full-resolution image for the distinct state-of-the-art lossy coders.
Fig. 10 : Cumulative average bit rate of the distinct coding steps when applying the recursive bits-back algorithm (left) or the optimized version (middle). Average net bit rate of the distinct coding steps (right). The minimum negative bit rate denotes the required initial bits for a single image patch.
Fig. 11 : Bit rate as a function of the number of image patches that have been sequentially compressed.
Fig. 12 : Learning curves of each individual distribution when training on the validation dataset. Notice the inference curves are minimized when our desire is to maximize them. Top: Inference distributions (decoding steps). Bottom: Likelihood and prior distributions (encoding steps).
Fig. 13 : Ablation study of the number of latent variables L and the patch size PS over the Bit-swap model.
Fig. 14 : Compression and decompression times in terms of the number of latent variables L and the patch size PS over the Bit-swap model.
Fig. 15 : Rate-distortion curves per region of ROI-eML ; HP+EASN-deep trained for squared error. The error bars indicate the std distortion on the compression performance. PSNR (left) and MS-SSIM (right) quality measures.
Coding
Region
Bit rate
Bit rate
scheme
mean
std
JPEG2000-ROI [ 10 ]
Blade
10.06
1.68
JPEG2000-ROI [ 10 ]
Background
10.31
1.72
ROI-eML
Blade
8.84
1.68
ROI-eML
Background
9.06
1.72
Table I : Lossless compression performance comparison of ROI-eML per region , implemented by means of Bit-swap.
School of Mechanical Engineering, Zhejiang Sci-Tech University, Hangzhou 310018, China · Department of Artificial Intelligence and Robotics, Zhejiang Energy Digital Technology Co., Ltd, Hangzhou 311100, China · School of Computer Science and Technology, Nanjing University of Aeronautics and Astronautics, Nanjing, China +1
Dept. of Electrical and Computer Engineering, University of Patras, Patras, Greece · Dept. of Digital Media and Communication, Ionian University, Argostoli, Greece