- The paper introduces a robust, lightweight CNN model (AttX-Net) that integrates ResNet18, CBAM attention, and tailored augmentation for UAV-based crack classification.
- Empirical evaluations on the SDNET2018 dataset demonstrate improved F1-scores and 825 FPS, balancing accuracy with real-time performance on resource-limited systems.
- The methodology effectively localizes weak crack features under harsh imaging conditions, offering a practical solution for automated bridge inspections.
Robust Lightweight Crack Classification for Real-Time UAV Bridge Inspection
Problem Context and Motivation
Automated structural defect detection in bridge inspections has grown increasingly critical as infrastructures age and their maintenance demands intensify. The reliance on UAV platforms has accelerated this paradigm, enabling wide-area, high-resolution collection under hazardous or difficult-to-access conditions. However, real-world UAV image-based crack classification faces four major constraints: weak crack features (especially thin, low-contrast cracks), severe imaging degradation (motion blur, shadows, low light, fog), significant class imbalance, and limited edge computing resources. Conventional CNN-based and deep learning solutions, although effective in controlled settings, often fail to robustly balance accuracy and efficiency in deployment scenarios constrained by real-time processing and resource limitations.
Proposed Framework Overview
The paper presents a unified lightweight CNN-based crack classification system targeting deployment in UAV workflows under realistic environmental conditions. The architecture consists of four synergistic modules:
- Lightweight Backbone: ResNet18, selected based on optimal trade-off between inference speed and representational capacity, forms the foundation for feature extraction.
- Convolutional Block Attention Module (CBAM): Sequentially applies channel and spatial attention to enhance feature maps, facilitating sensitive crack feature localization with minimal overhead.
- Directed Robust Augmentation: Simulates typical environmental degradations observed in UAV inspections (motion blur, low illumination, shadows, fog, perspective distortion), directly narrowing the distribution gap between training and field deployment.
- Focal Loss: Used for adaptive hard-sample learning and explicit compensation for heavy class imbalance.
The pipeline is optimized for ground-station-assisted UAV inspection scenarios, where high-resolution bridge images are acquired and then processed in batch mode for patch-level binary crack classification.
Figure 1: Overview outlining the sequence of robust augmentation, hierarchical feature extraction, attention refinement, hard-sample-focused loss, and interpretability visualization.
Empirical Evaluation and Numerical Results
Experiments employ the SDNET2018 bridge deck dataset with substantial class imbalance (crack/non-crack โ 1:5.7), and rigorously test combinations of backbone, augmentation, attention, and imbalance mitigation. Three backbones (ResNet18, MobileNetV3, EfficientNet-B0) are compared, highlighting ResNet18's superior speed-accuracy equilibrium (719.4 FPS, F1 = 0.7249). EfficientNet-B0 achieves the highest accuracy but with significantly reduced speed, unsuitable for real-time applications.
Figure 2: Resource and performance evaluation of ResNet18, MobileNetV3, and EfficientNet-B0 across critical metrics.
Figure 3: Normalized radar chart visualizing backbone trade-offs, emphasizing ResNet18's operational advantages.
Performance ablation reveals:
- Robust Augmentation alone increases recall substantially (ฮRecall = +16.42%) but causes precision loss via more false positives.
- Focal Loss alone has marginal effect unless robust augmentation is active; the combination yields highest F1-score.
- CBAM addition to augmentation + Focal Loss maximizes precision (0.8347) and accuracy (0.9325), with slightly lower recall but optimal deployment suitability.
Cross-backbone generalization confirms consistent effectiveness (ฮF1 = +2.51โ5.01%), even when native SE modules are present, due to CBAM's spatial localization superiority.
Figure 4: F1-score and precision improvements with CBAM across backbones; percentage gains annotated.
Figure 5: 3D scatter of FPS, test F1, and model size, validating overall architectural efficiency and accuracy.
Computational Complexity and Practical Deployment
AttX-Net (ResNet18+CBAM) uses only 11.21M parameters and 1.82G FLOPs, with 825 FPS inference speed. CBAM incurs negligible overhead (ฮParams โ 0.03M, ฮFLOPs < 0.6%)โsuitable for resource-restricted ground-station deployment. The classifier head contributes insignificant MACs and parameters.

Figure 6: Attention module overhead quantified across backbones; boxplot and heatmap detail parameter and MAC shares.
Figure 7: Ground-station UAV workflow, illustrating acquisition-to-processing pipeline and real deployment.
Interpretability and Robustness
Grad-CAM visualizations demonstrate the CBAM module's effect: precise crack trajectory tracking, background suppression, and improved multi-target sensitivity relative to baseline models.
Figure 8: Grad-CAM activation maps, with CBAM-enhanced localization and suppression of false regions.
Training dynamics show stable convergence and improved generalization (smaller training-validation accuracy gap with augmentation). Five-fold cross-validation and paired tests indicate statistically significant recall and F1-score improvements.
Figure 9: Five-fold cross-validation statistics; significance results for F1/recall with CBAM.
Figure 10: Loss/accuracy convergence curves comparing baseline and full method, highlighting generalization stability.
Practical and Theoretical Implications
This framework provides a deployable solution for automated, high-throughput bridge crack screening, supporting efficient ground-station-assisted UAV workflows. The joint integration and empirical synergy of robust augmentation and Focal Loss offer clear guidance for defect detection in imbalanced, degraded environments. CBAM's spatial attention outperforms channel-only modules, making attention design critical for weak, spatially sparse defects.
The methodology is adaptable to related UAV inspection domains (road, tunnel, geotechnical monitoring) and compatible with future lightweight transformer architectures. The patch-level classification design can be extended to full-scene segmentation and quantification tasks.
Limitations and Future Directions
Interpretability remains qualitative in the absence of pixel-level crack annotations. Tile-level splitting for evaluation may not fully decouple spatial correlations in SDNET2018; location-aware splitting is advised for field datasets. Onboard UAV inference validation is pending; current results reflect ground-station deployment. Further, explicit multi-task extensions (crack segmentation, severity quantification) and deployment-linked closed-loop evaluations are indicated for future advancement.
Conclusion
The presented AttX-Net achieves a robust balance of accuracy, efficiency, and interpretability for real-time patch-level crack classification in UAV bridge inspection scenarios. With strong numerical gains (F1-score +2.51%, recall +3.95%, 825 FPS) under severe class imbalance and harsh imaging conditions, the framework is practical for ground-assist deployment pipelines. Integration of robust scene augmentation, Focal Loss, and CBAM attention are empirically validated as synergistic, not redundant. The approach is generalizable and provides foundational design guidance for automated defect screening in infrastructure inspection.
Figure 11: Epoch-wise validation F1 and precision across ablation stages; summary inset highlights test results at best epochs.