Thursday, October 23, 2025

Enhancing Localized Corrosion Detection in Structural Alloys Using Deep Learning

Share

Advancements in Real-Time Object Detection: A Focus on YOLOv9 for Corrosion Segmentation

Deep Learning (DL) methods from the YOLO (You Only Look Once) series have emerged as cutting-edge technologies for real-time object detection in diverse natural image datasets, notably exemplified by the Microsoft Common Objects in Context (MS COCO) dataset. This series has consistently pushed the envelope in terms of efficiency, accuracy, and adaptability across various applications.

To address the specific challenge of corrosion segmentation, we developed an instance segmentation method based on the recently released YOLOv9. This version integrates groundbreaking techniques such as Programmable Gradient Information (PGI) and the Generalized Efficient Layer Aggregation Network (GELAN), which augment traditional object detection capabilities and cater to the nuanced requirements of image segmentation.

The YOLOv9 Architecture

The architecture of YOLOv9 is structured to effectively process input micrographs, as illustrated in Figure 4. The input image (X) is routed through two main branches: the primary branch primarily focuses on extracting multiscale features, while the auxiliary branch refines these features for improved prediction outcomes.

Key Components of YOLOv9

  1. Main Branch:

    • Comprising several modules, including Convolution, Batch Normalization, Swish Activation (CBS), GELAN, and others, the main branch effectively extracts relevant features from the input image. Multi-scale features are down-sampled via Average Down-sampling (ADW) and enhanced through Spatial Pyramid Pooling (SPP).
  2. Auxiliary Branch:

    • This branch operates on a reversible design leveraging PGI to prevent information loss, crucial for generating reliable gradient updates during training. The CBL block and CBF block of this branch help in merging gradient information from the main and auxiliary branches respectively.
  3. Texture Refinement Module:
    • A pivotal innovation in our model is the incorporation of a texture refinement module. Positioned before the final prediction head, the TR block enhances texture detail extraction, enabling precise identification of corrosion patterns distinct from their backgrounds.

Feature Processing and Predictions

The model captures detailed features through convolutional layers and batch normalization processes. The features from both branches are then concatenated and directed to the prediction head, where a combination of classification and segmentation layers predict the mask (Y’). This prediction phase utilizes a loss function that includes both classification and segmentation losses, ensuring robust learning even in data-scarce scenarios.

Data Utilization in YOLOv9

Training for this architecture was conducted using a multi-faceted approach, leveraging public datasets alongside a newly built dataset specifically for corrosion analysis.

Dataset Overview

  1. Microsoft COCO:

    • As a large-scale dataset upon which YOLO was initially trained, MS COCO hosts around 164,000 natural images with categories ranging from various objects to scenes. Notably, it lacks categories pertaining to corrosion or similar defects, highlighting the necessity for specialized datasets in our research.
  2. Pothole Image Segmentation (PIS):

    • The PIS dataset, designed to enhance road safety, comprises images of potholes. However, due to the stark differences between pothole images and the complex corrosion patterns in our task, this dataset was not sufficient for effective training.
  3. Corrosion Segmentation in Materials (CSM):
    • To address the unique challenges posed by corrosion segmentation, we constructed the CSM dataset. This dataset includes 84 valid images of corrosion patterns collected from Scanning Electron Microscopy (SEM) micrographs, which underwent a meticulous labeling process to ensure accuracy and reliability.

Annotation Process

The construction of the dataset involved a labor-intensive approach, utilizing both human expertise and interactive annotation tools to ensure high-quality segmentation masks. Given the challenges associated with identifying corrosion features due to low contrasts and varying morphologies, iterative refinement and expert consultations played critical roles in achieving precision in labeling.

Implementation of YOLOv9 Model

The YOLOv9 model was implemented using the PyTorch framework, with a structured training regimen aimed at optimizing performance. The training process included rigorous data augmentation strategies to enhance diversity, thereby improving model robustness and accuracy.

  1. Training Regimen:

    • The initial phase involved fine-tuning on the PIS dataset for 300 epochs, followed by further training on the newly constructed CSM dataset for an additional 300 epochs.
  2. Model Evaluation:

    • Various metrics such as precision, recall, and mean Average Precision (mAP) were utilized to measure the model’s performance. The absence of overfitting and the convergence of the training loss curves emphasized the effectiveness of this training approach, even with the relatively small dataset of 84 labeled instances.
  3. Loss Function:
    • The model employed a comprehensive two-part loss function combining segmentation and classification losses, ultimately optimizing overall objective performance.

Result Interpretation

Analysis of training and validation loss curves indicated a positive trend in the model’s learning efficacy without signs of overfitting. With the structure of the training set and the diversity of augmentations applied, the model demonstrated consistent performance and substantial accuracy in identifying corrosion patterns, further validated by quantitative metrics during testing.

The integration of advanced features in YOLOv9, combined with innovative data processing techniques, positions our approach as a significant contribution to the field of corrosion segmentation, paving the way for future developments in effective image analysis solutions.

Read more

Related updates