An XCT fiber bundle identification method based on improved YOLOv8
By improving the YOLOv8 network YOLOv8_CMC, the problems of slow fiber bundle identification speed and high computational resource consumption in XCT slices of ceramic matrix composites are solved, realizing efficient and accurate fiber bundle segmentation, which is suitable for 2.5D braided ceramic matrix composite preforms.
Patent Information
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- NANJING UNIV OF AERONAUTICS & ASTRONAUTICS
- Filing Date
- 2024-06-28
- Publication Date
- 2026-07-24
AI Technical Summary
Existing technologies for fiber bundle identification in XCT slices of ceramic matrix composites suffer from slow identification speed, long training time, and high computational resource consumption. Furthermore, traditional deep learning algorithms struggle to balance identification accuracy and speed.
An improved YOLOv8 network, YOLOv8_CMC, was used. Data augmentation was performed by creating a 2.5D braided fiber bundle XCT slice dataset. A network model containing VanillaNet, C2f, SPPF, Segment, Contact, Unsample, VoVGSCSP, and GSConv modules was constructed. The network was trained using the SGD algorithm, and the weights were optimized using the WIoU loss function to achieve direct semantic segmentation of fiber bundles.
While ensuring high recognition accuracy, the model size and training time are reduced, the computational resource requirements are lowered, and the speed and accuracy of fiber bundle segmentation are improved. It is suitable for fiber bundle recognition of 2.5D braided ceramic matrix composite preforms.
Smart Images

Figure CN118736229B_ABST
Abstract
Description
Technical Field
[0001] This invention belongs to the field of microstructure identification of ceramic matrix composite preforms, and particularly relates to an XCT fiber bundle identification method based on an improved YOLOv8. Background Technology
[0002] Ceramic matrix composites (CMCs) are widely used in next-generation aero-engines and are materials that can be used under extreme conditions. They typically use continuous ceramic fibers as the reinforcing phase and have advantages such as high temperature resistance, corrosion resistance, low density, and wear resistance.
[0003] A continuous framework of ceramic fibers is called a complex preform (CMC), which is woven from fiber bundles. Specific weaving structures include plain weave, 2.5D, and three-dimensional four-dimensional weaves. Common methods for preparing CMCs include chemical vapor deposition (CVI), precursor impregnation pyrolysis (PIP), and reactive melting (MI). The commonly used CVI process for preparing CMCs involves first depositing an interface layer on the fiber surface, then depositing the matrix inside the fiber bundles, and finally depositing the matrix between the fiber bundles to form the CMC. Identifying these fiber bundles is fundamental to studying the mechanical properties and failure mechanisms of CMCs.
[0004] X-ray computed tomography (XCT) is an effective method for obtaining the microstructure of complex ceramic matrix composite preforms such as fiber bundles. It can accurately obtain the actual internal microstructure of the material without damaging it, thus producing a series of fiber bundle-related XCT slices.
[0005] Currently, XCT nondestructive testing technology has matured considerably, but the identification of fine structures such as fiber bundles, matrix, and pores in XCT slices remains a significant technical challenge. Fine structure identification, as discussed here, primarily refers to the classification of individual pixels within each slice; different pixels may belong to fibers, matrix, or pores.
[0006] Existing XCT slice microstructure recognition techniques are mostly based on traditional computer vision techniques. Examples include the structure tensor method for two-dimensional woven fabrics, the gray-level co-occurrence matrix for three-dimensional orthogonal woven fabrics, and fiber tracking algorithms for multi-directional carbon fiber reinforced polymer (CFRP) specimens. The recognition performance of these methods heavily depends on the scanning resolution and is designed only for specific microstructures, making them unsuitable for fiber bundle recognition.
[0007] Therefore, some scholars have proposed the Ostu maximum threshold segmentation method to identify fiber bundles in XCT images of 2.5D woven structures. For example, there is a Chinese patent application with patent number "201610838554.8", entitled "A Computer Image Recognition Technology and 3D Modeling Method for the Microstructure of Composite Materials". This method first identifies the matrix portion of the 2.5D woven structure XCT image, numbers the matrix portion, and pairs it using the left-right symmetry of the matrix. It then selects appropriate upper and lower boundary points of the matrix for boundary fitting; the upper and lower boundary points are warp yarns, and the left and right boundary points are weft yarns. However, because this method uses symmetry for matrix identification, the recognition algorithm fails if the matrix portion in the slice is an asymmetrical structure, resulting in poor robustness.
[0008] For three-dimensional four-way woven structures, some scholars have established theoretical models of three-dimensional woven composite material unit cells based on pre-set geometric parameters. These models are then compared with XCT slices that have undergone thresholding and denoising processing. The preset values of the theoretical model are adjusted, and the final recognition result is obtained through algorithm optimization. For example, there is Chinese patent application number "201810537212.1", entitled "A Computer Image Recognition Technology and Three-Dimensional Modeling Method for Microstructures of Composite Materials". However, in the process of using threshold segmentation for recognition in XCT images, due to imaging issues, the grayscale variation range between fiber bundles is large, making it difficult to find an optimal threshold for segmentation for each slice.
[0009] In the field of computer vision, the technique of applying convolutional neural networks to the identification of the aforementioned fiber bundle microstructures is called semantic segmentation. With the development of deep learning, more and more neural networks have been proposed and applied to the semantic segmentation of images, resulting in many high-performance structures such as FCN, SegNet, and U-Net.
[0010] Previous research has utilized neural networks to identify fiber bundles in ceramic matrix composites (CMCs). Multi-decoder fully convolutional neural networks (MCNNs) can be used for semantic segmentation of XCT images of CMCs. These MCNNs employ a max-pooling decoder network, a channel fusion decoder network, and a channel connection decoder network, designed in parallel. Through network training, the final identification of fine structures is achieved, as illustrated in Chinese patent application number "201910165647.2". However, MCNNs require significant memory usage and time during training. To address this issue and reduce reliance on hyperparameter tuning during training, researchers have used a fully convolutional neural network, CMCs_Net, to identify fine structures in XCT slices of CMC preforms. However, the deep learning framework used in this approach is outdated and cannot effectively balance training accuracy and speed. Furthermore, these traditional deep learning algorithms often require first extracting the region containing the target and then identifying it within that region, significantly reducing detection speed. On the other hand, these networks are generally large in size to ensure recognition accuracy, consuming substantial computational resources.
[0011] In summary, although existing methods can achieve the identification and segmentation of fiber bundles in CMCs, they all have some drawbacks, including slow recognition speed, long training time, and high computational resource consumption. Therefore, semantic segmentation of XCT slices of ceramic matrix composites based on deep learning requires further research. Summary of the Invention
[0012] The purpose of this invention is to address the problems existing in the prior art by providing an XCT fiber bundle recognition method based on an improved YOLOv8, used for fiber bundle recognition in XCT slices of ceramic matrix composite preforms. Because this invention improves YOLOv8 for application in the CMC field, it is called YOLOv8_CMC. It solves the problems of large size, high memory consumption, and slow training time of existing convolutional neural networks while maintaining high recognition accuracy. This invention can be used for the recognition of fiber bundles (warp and weft yarns) in 2.5D woven ceramic matrix composite preforms.
[0013] To achieve the above-mentioned technical objectives, the technical solution adopted by the present invention is as follows:
[0014] An XCT fiber bundle identification method based on improved YOLOv8 (i.e., YOLOv8_CMC) includes the following steps:
[0015] Step 1: Establish a 2.5D braided fiber bundle XCT slice dataset and divide it into a training set and a validation set;
[0016] Step 2: Perform data augmentation on the XCT slice dataset to increase the number of samples;
[0017] Step 3: Establish a network model of the YOLOv8_CMC network for segmenting fiber bundles in the XCT slice dataset;
[0018] Step 4: Import the XCT slice dataset into the YOLOv8_CMC network;
[0019] Step 5: Train the YOLOv8_CMC network and save the weight file and corresponding evaluation parameters after training.
[0020] Step 6: After the YOLOv8_CMC network is trained, perform semantic segmentation on all images and save them in a folder. Based on the three evaluation parameters of precision, recall, and mean precision, select the best segmentation result as the optimal weight file to segment all XCT images and complete the fiber bundle recognition of 2.5D braided structures.
[0021] Further improvements to optimize the technical solution include:
[0022] In step one, the fiber bundles of the 2.5D braided structure are manually marked to generate label files in the open-source software Labelme, with a test set to validation set ratio of 7:3.
[0023] In step two, the XCT slice dataset is augmented using methods including cropping, flipping, rotating, adding noise, brightness variation, and contrast enhancement. After augmentation, the ratio of the test set to the validation set in the dataset is 7:3.
[0024] In step three, the YOLOv8_CMC network model consists of three parts: the backbone network, the neck network, and the head network. These three parts contain a total of 24 modules, including VanillaNet, C2f, SPPF, Segment, Contact, Unsample, VoVGSCSP, and GSConv. The Contact and Unsample modules are consistent with their corresponding modules in the original YOLOv8 model and are not modified. These 24 modules are numbered sequentially from 0 to 23.
[0025] The backbone network consists of 5 VanillaNet modules, 4 C2f modules, and 1 SPPF module. Modules numbered 0, 1, 3, 5, and 7 are VanillaNet modules; modules numbered 2, 4, 6, and 8 are C2f modules; and module numbered 9 is the SPPF module. The input image is standardized to 640×640 pixels before entering module 0. After passing through module 0, the feature map size becomes 320×320×64 pixels. It then passes through modules 1 through 9 sequentially. The feature maps output from modules 4, 6, and 9 are used as input to the neck network. After passing through the VanillaNet modules, the height and width of the feature map are halved, and the number of channels is doubled. After passing through the SPPF module, the height and width remain unchanged, and the number of channels is halved. After passing through the C2f module, the height, width, and number of channels remain unchanged.
[0026] The neck network consists of 4 VoVGSCSP modules, 2 GSConv modules, 4 Contact modules, and 2 Upsample modules. Modules numbered 12, 15, 18, and 21 are VoVGSCSP modules; modules numbered 16 and 19 are GSConv modules; modules numbered 11, 14, 17, and 20 are SPPF modules; and modules numbered 10 and 13 are Upsample modules. The connection method of each module is as follows: Module 10 receives data, and module 9 outputs data in a 20×20 format. After receiving the feature map of size ×512, a feature map of size 40×40×512 is output to module 11. Module 11 receives the feature map output by module 10 and the feature map of size 40×40×512 output by module 6, and then outputs a feature map of size 40×40×1024 to module 12. After receiving the feature map input by module 11, module 12 outputs a feature map of size 40×40×512 to modules 13 and 17 respectively. After receiving the feature map input by module 12, module 13 outputs a feature map of size 80×80×512 to module 14. Module 14 receives feature maps of size 80×80×256 from modules 13 and 4, and outputs a feature map of size 80×80×768 to module 15. Module 15 receives the feature map input from module 14 and outputs a feature map of size 80×80×512 to module 16 and the head network respectively. Module 16 receives the feature map input from module 15 and outputs a feature map of size 40×40×256 to module 17. Module 17 receives the feature maps input from modules 12 and 16 and outputs a feature map of size 40×40×768 to module 18. After receiving the feature map input from module 17, module 18 outputs a 40×40×512 feature map to module 19 and the head network respectively. After receiving the feature map input from module 18, module 19 outputs a 20×20×512 feature map to module 20. After receiving the feature map output from module 19 and module 9 in the backbone network, module 20 outputs a 20×20×1024 feature map to module 21. After receiving the feature map input from module 20, module 21 outputs a 20×20×512 feature map to the head network.
[0027] The head network consists of three segment modules, numbered 21, 22, and 23. Modules 21, 22, and 23 receive feature maps from modules 15, 18, and 21 in the neck network, respectively, and then identify and segment the fiber bundles to output mask results. The head network combines the mask results output by these three segment modules to finally output XCT images of the segmented fiber bundles.
[0028] The VanillaNet module consists of five parts. The first part is a 2D convolutional layer with a kernel size of 3×3 and a stride of 4, with 512 kernels. The second, third, and fourth parts are 2D max pooling layers with a kernel size of 1×1 and a stride of 2, with 1024, 2048, and 4096 kernels respectively. The fifth part is a 2D average pooling layer with a kernel size of 2×2 and a stride of 1. Each part ends with an activation layer using the SiLu activation function, and a 2D regularization layer is added between the max pooling layer and the activation layer in the second, third, and fourth parts.
[0029] The C2f module consists of one Concat module, two Conv modules, and six Bottleneck modules. The two Conv modules are the first and last modules of the C2f module, respectively. The two Conv modules have 2×2 kernels and strides of 2 in their 2D convolutional layers, and both use padding with a padding size of 1. Both have the same number of kernels. The first Conv module is followed by six Bottleneck modules, all of which use residual connections. Half of the feature map from the output is passed to the next module, and the other half of the feature map is passed to the Concat module. The Concat module is located between the last Bottleneck module and the last Conv module.
[0030] The SPPF module consists of one Concat module, two Conv modules, and four 2D max pooling layers. The two Conv modules are the first and last modules of the SPPF module, respectively. The convolutional kernels of the two 2D convolutional layers are both 1×1 with a stride of 1 and no padding is used. The first Conv module is followed by four 2D average pooling layers, each with a kernel size of 2×2 and a stride of 1. All of these layers use residual connections. Half of the feature map from the output is fed into the next layer, and the other half of the feature map is fed into the Concat module, which is located between the last 2D average pooling layer and the last Conv module.
[0031] The Segment module has two branches. The first branch consists of two Conv modules, a 2D convolutional layer, and a loss function calculation layer (MasLoss). In both Conv modules, the 2D convolutional layer has a 3×3 kernel size, a stride of 1, and is padded with a padding size of 1. The 2D convolutional layer has a 1×1 kernel size, a stride of 1, and no padding, with a total of 4 kernels. The MasLoss loss function calculation layer uses the WIoU loss function to calculate the loss for fiber bundle segmentation. The second branch also consists of two Conv modules, a 2D convolutional layer, and a loss function calculation layer (ClsLoss). In both Conv modules, the 2D convolutional layer has a 3×3 kernel size, a stride of 1, and is padded with a padding size of 1. The 2D convolutional layer has a 1×1 kernel size, a stride of 1, and no padding, with a total of 4 kernels. The ClsLoss loss function calculation layer uses the BCE loss function to calculate the loss for fiber bundle segmentation.
[0032] The Bottleneck module is composed of two Conv modules connected sequentially using residual connections. In the main branch, the first Conv module has a 1×1 kernel size and a stride of 1 for its 2D convolutional layer, and does not use padding. The second Conv module has a 3×3 kernel size and a stride of 1 for its 2D convolutional layer, and uses padding with a padding size of 1. There are no modules in the residual branch.
[0033] The Conv module consists of a 2D convolutional layer, a 2D regularization layer, and an activation layer, where the activation layer uses the ReLU activation function.
[0034] The VoVGSCSP module consists of three 2D convolutional layers, one Concat module, and one GSbottleneck module. The VoVGSCSP module is first divided into two branches: one branch consists of a single 2D convolutional layer, and the other branch consists of a single 2D convolutional layer and a GSbottleneck module. The outputs of both branches are fed into the Concat module and then into a single 2D convolutional layer. All convolutional layers have a 1×1 kernel size and a stride of 1, and no padding is used. The output feature map of the 2D convolutional layer in the same branch as the GSbottleneck module has half the number of channels as the input feature map.
[0035] The GSbottleneck module employs residual connections. Its main branch consists of two GSConv modules. The second GSConv module outputs a feature map with twice the number of channels as its input feature map. The residual branch contains only one 2D convolutional layer with a 3×3 kernel size, a stride of 1, and padding of 1 unit. Both the 2D convolutional layer and the 2D depthwise separable convolutional layer within the GSConv module have 2×2 kernel sizes, a stride of 1, and are padded with 1 unit.
[0036] The GSConv module consists of a 2D convolutional layer, a 2D separable convolutional layer, a Concat module, and a shuffle layer. The kernel size of both the 2D convolutional layer and the 2D separable convolutional layer is 2×2, and the stride is 1. The feature maps first enter the 2D convolutional layer. Half of the output channel feature maps are then passed to the 2D separable convolutional layer before being output to the Concat module, while the other half of the output channel feature maps are directly passed to the Concat module. Finally, the feature maps enter the shuffle layer for channel rearrangement.
[0037] In step five, the YOLOv8_CMC network is built using the PyTorch neural network framework, and the YOLOv8_CMC network is trained using the SGD stochastic gradient algorithm.
[0038] In step five, the specific method for obtaining the weight file and corresponding evaluation parameters is as follows: Based on the 512 feature channels output by the last two-dimensional convolutional layer of the Segment module in the head network, calculate and compare the probability of each pixel at the same position in the 512 feature channels, select the category with the highest probability to determine the category of this pixel in the XCT slice image, and combine the results obtained by iteratively calculating the three Segment modules to obtain a complete XCT fiber bundle segmentation prediction map; use the WIoU loss function to calculate the difference between the ground truth map and the segmentation prediction map to obtain the loss of the YOLOv8_CMC network, and update the weights of the YOLOv8_CMC network through the backpropagation algorithm and the SGD algorithm. After training, the weight file and corresponding evaluation parameters are obtained.
[0039] In step five, the YOLOv8_CMC network is trained 300 times.
[0040] In step six, the method for obtaining the three evaluation parameters of precision, recall, and mean precision is as follows: after each training of the YOLOv8_CMC network, the corresponding weight file is saved, and the XCT image on the validation set is segmented using the weight file to obtain the three evaluation metrics of precision, recall, and mean precision.
[0041] Compared with the prior art, the present invention has the following beneficial effects:
[0042] 1. This invention solves the problems of large size, large memory usage and slow training time of existing convolutional neural networks while ensuring high recognition accuracy. It is very suitable for the recognition of fiber bundles (warp and weft yarns) of 2.5D woven ceramic matrix composite preforms.
[0043] 2. This invention replaces the original Conv module with a VanillaNet module in the backbone network, avoiding the complex operations of the original module and using relatively simple operations to extract fiber bundle features, reducing the overall model size and lowering the model's computational resource requirements. While eliminating the segmentation layer in the original Cf2 module, the number of Bottleneck modules using residual structures is increased, ensuring the model's ability to extract fiber bundle features while accelerating the feature extraction speed, thus guaranteeing the model's fiber bundle segmentation accuracy and significantly speeding up the segmentation process. The original SPPF module is improved by adding a two-dimensional max-pooling layer, enhancing the model's receptive field and improving its ability to segment fiber bundles of different sizes.
[0044] 3. In the neck network, the VoVGSCSP and GSConv modules were used. Compared to the original Conv module, GSConv simplifies the model by eliminating normalization operations and activation functions, reducing the number of parameters and significantly increasing computational efficiency. Using shuffle layers for channel rearrangement improves the parallelism and efficiency of convolutional computation in the GSConv module while reducing memory accesses and enhancing feature fusion capabilities, thus ensuring model accuracy. The VoVGSCSP module reduces convolutional operations, decreasing model size and consequently reducing parameters, accelerating training.
[0045] 4. A decoupled head network structure is used to perform fiber bundle recognition and segmentation. Three segmentation modules simultaneously segment fiber bundles of different sizes, improving segmentation accuracy and efficiency while reducing the time required for fiber bundle segmentation. Furthermore, the WIoU loss function is used instead of the original loss function, ensuring high-quality segmentation masking while reducing the impact of harmful gradients, thus improving the overall model performance. This also accelerates convergence speed and accuracy during model training, enhances generalization ability, reduces training costs and time, and lowers hardware requirements for training the model.
[0046] 5. YOLOv8_CMC adopts a single-stage recognition and segmentation strategy, which directly segments the entire fiber bundle. This abandons the traditional method of first determining the target region and then performing recognition and segmentation in convolutional neural networks, which greatly improves segmentation efficiency and reduces the time the model spends segmenting the fiber bundle. Attached Figure Description
[0047] Figure 1 The overall network structure diagram of the improved YOLOv8 (i.e., YOLOv8_CMC) network;
[0048] Figure 2 Here is a structural diagram of the VanillaNet module;
[0049] Figure 3 Here is the structure diagram of the C2f module;
[0050] Figure 4 This is a structural diagram of an SPPF module;
[0051] Figure 5 Here is a structural diagram of the Segment module;
[0052] Figure 6 Here is a structural diagram of the Bottleneck module;
[0053] Figure 7 Here is a structural diagram of the Conv module;
[0054] Figure 8 Here is a structural diagram of the VoVGSCSP module;
[0055] Figure 9 Here is a structural diagram of the GSbottleneck module;
[0056] Figure 10 This is a structural diagram of the GSConv module. Detailed Implementation
[0057] To make the objectives, technical solutions, and advantages of this application clearer, the application is described and illustrated below with reference to the accompanying drawings and embodiments. It should be understood that the specific embodiments described herein are merely illustrative and not intended to limit the scope of this application. All other embodiments obtained by those skilled in the art based on the embodiments provided in this application without inventive effort are within the scope of protection of this application.
[0058] Obviously, the accompanying drawings described below are merely some examples or embodiments of this application. Those skilled in the art can apply this application to other similar scenarios based on these drawings without any inventive effort. Furthermore, it is understood that although the efforts made in this development process may be complex and lengthy, for those skilled in the art related to the content disclosed in this application, any changes to design, manufacturing, or production based on the technical content disclosed in this application are merely conventional technical means and should not be construed as insufficient disclosure of the content of this application.
[0059] like Figure 1 As shown, this invention proposes an XCT fiber bundle identification method based on an improved YOLOv8, comprising the following steps:
[0060] 1. Construct the XCT slice dataset and divide it into training and validation sets.
[0061] In the Labelme software, the fiber bundles in XCT were manually labeled, and the corresponding label files were generated. Based on this, a dataset of 200 images was created for the YOLOv8_CMC network, with 140 images designated as the training set and the remaining 60 as the validation set.
[0062] Data augmentation preprocessing was performed on the 2.5D woven structured XCT slice dataset to make the dataset more comprehensive.
[0063] Data augmentation methods included cropping, flipping, rotating, adding noise, adjusting brightness, and enhancing contrast. After augmentation, the dataset contained 1000 images, with 700 in the test set and 300 in the validation set.
[0064] 3. A YOLOv8_CMC network model for segmenting 2.5D braided XCT fiber bundles was established and debugged to ensure proper operation. The entire network was trained on an RTX 4090 graphics card. This network consists of three main parts: the backbone, the neck, and the head, containing a total of 24 modules including VanillaNet, C2f, SPPF, Segment, Contact, Unsample, VoVGSCSP, and GSConv.
[0065] The Contact and Unsample modules remain the same as their counterparts in the original YOLOv8 model, without any modifications.
[0066] like Figure 1As shown, the backbone network consists of 5 VanillaNet modules, 4 C2f modules, and 1 SPPF module. Modules numbered 0, 1, 3, 5, and 7 are VanillaNet modules. Modules numbered 2, 4, 6, and 8 are C2f modules. Module number 9 is the SPPF module. The input image is standardized to 640×640 pixels before entering module 0. After passing through module 0, the feature map size becomes 320×320×64 pixels, and then passes through modules 1 through 9 sequentially. The feature maps output from modules 4, 6, and 9 are used as input to the neck network. After passing through the VanillaNet modules, the height and width of the feature map are halved, and the number of channels is doubled. After passing through the SPPF module, the height and width remain unchanged, and the number of channels is halved. After passing through the C2f module, the height, width, and number of channels remain unchanged.
[0067] like Figure 1As shown, the neck network consists of 4 VoVGSCSP modules, 2 GSConv modules, 4 Contact modules, and 2 Upsample modules. Modules numbered 12, 15, 18, and 21 are VoVGSCSP modules. Modules numbered 16 and 19 are GSConv modules. Modules numbered 11, 14, 17, and 20 are SPPF modules. Modules numbered 10 and 13 are Upsample modules. The connection between the modules is as follows: Module 10 receives a feature map of size 20×20×512 from module 9 and outputs a feature map of size 40×40×512 to module 11. Module 11 receives the feature map output by Module 10 and the 40×40×512 feature map output by Module 6, and outputs a 40×40×1024 feature map to Module 12. Module 12 receives the feature map input by Module 11 and outputs a 40×40×512 feature map to Module 13 and Module 17 respectively. Module 13 receives the feature map input by Module 12 and outputs an 80×80×512 feature map to Module 14. Module 14 receives the 80×80×256 feature map output by Module 13 and Module 4, and outputs an 80×80×768 feature map to Module 15. Module 15 receives the feature map input by Module 14 and outputs an 80×80×512 feature map to Module 16 and the head network respectively. After receiving the feature map input from module 15, module 16 outputs a feature map of size 40×40×256 to module 17. After receiving the feature maps input from modules 12 and 16, module 17 outputs a feature map of size 40×40×768 to module 18. After receiving the feature map input from module 17, module 18 outputs a feature map of size 40×40×512 to module 19 and the head network respectively. After receiving the feature map input from module 18, module 19 outputs a feature map of size 20×20×512 to module 20. After receiving the feature map output from module 19 and module 9 in the backbone network, module 20 outputs a feature map of size 20×20×1024 to module 21. After receiving the feature map input from module 20, module 21 outputs a feature map of size 20×20×512 to the head network.
[0068] like Figure 1As shown, the head network consists of three segment modules, numbered 21, 22, and 23. Modules 21, 22, and 23 receive feature maps from modules 15, 18, and 21 in the neck network, respectively, and then segment the fiber bundles and output a mask result. Module 21 receives the largest feature map module with the largest receptive field, primarily responsible for segmenting small-sized edge weft yarns. Module 22 receives a medium-sized feature map module with a medium receptive field, primarily responsible for segmenting medium-sized non-edge weft yarns. Module 23 receives the smallest feature map module with the smallest receptive field, primarily responsible for segmenting large-sized warp yarns. The head network combines the mask results output from these three segment modules to finally output an XCT image of the segmented fiber bundles.
[0069] like Figure 2 As shown, the VanillaNet module consists of five parts. The first part is a 3×3 2D convolutional layer with a stride of 4 and 512 kernels. The second, third, and fourth parts are 1×1 2D max-pooling layers with a stride of 2 and 1024, 2048, and 4096 kernels respectively. The fifth part is a 2×2 2D average pooling layer with a stride of 1. Each part ends with an activation layer using the SiLu activation function. A 2D regularization layer is added between the max-pooling layer and the activation layer in the second, third, and fourth layers.
[0070] like Figure 3 As shown, the C2f module consists of one Concat module, two Conv modules, and six Bottleneck modules. The two Conv modules are the first and last modules of the C2f module, respectively. Both have 2×2 kernels in their 2D convolutional layers, a stride of 2, and are padded with a padding size of 1. They also have the same number of kernels. The first Conv module is followed by six Bottleneck modules, all connected using residual connections. Half of the feature map from the output is fed into the next module, and the other half is fed into the Concat module. The Concat module is located between the last Bottleneck module and the last Conv module.
[0071] like Figure 4As shown, the SPPF module consists of one Concat module, two Conv modules, and four 2D max pooling layers. The two Conv modules are the first and last modules of the SPPF module, respectively. Both Conv modules have 1×1 kernels and a stride of 1 in their 2D convolutional layers, without padding. The first Conv module is followed by four 2D average pooling layers, each with a 2×2 kernel and a stride of 1, all using residual connections. Half of the feature map from the output is fed into the next layer, and the other half is fed into the Concat module. The Concat module is located between the last 2D average pooling layer and the last Conv module.
[0072] like Figure 5 As shown, the Segment module has two branches; the first branch consists of two Conv modules, a two-dimensional convolutional layer, and a loss function calculation layer, MasLoss. In the two Conv modules, the two-dimensional convolutional layers have 3×3 kernels, a stride of 1, and are padded with a padding size of 1. The two-dimensional convolutional layers have 1×1 kernels, a stride of 1, and are not padded; the number of kernels is 4. The loss function calculation layer, MasLoss, uses the WIoU loss function to calculate the loss function for the fibers. The first branch calculates the loss for fiber bundle segmentation. The second branch consists of two Conv modules, a two-dimensional convolutional layer, and a loss function calculation layer ClsLoss. In the two Conv modules, the kernel size of the two-dimensional convolutional layer is 3×3, the stride is 1, and padding is applied with a padding size of 1. The kernel size of the two-dimensional convolutional layer is 1×1, the stride is 1, no padding is applied, and the number of kernels is 4. The loss function calculation layer ClsLoss uses the BCE loss function to calculate the loss for fiber bundle segmentation.
[0073] like Figure 6 As shown, the Bottleneck module is composed of two Conv modules in sequence using residual connections. On the main branch, the first Conv module has a 1×1 kernel size and a stride of 1 for its 2D convolutional layer, and does not use padding. The second Conv module has a 3×3 kernel size and a stride of 1 for its 2D convolutional layer, and uses padding with a padding size of 1. There are no modules on the residual branch.
[0074] like Figure 7 As shown, the Conv module consists of a two-dimensional convolutional layer, a two-dimensional regularization layer, and an activation layer. The activation layer uses the ReLU activation function.
[0075] like Figure 8As shown, the VoVGSCSP module consists of three 2D convolutional layers, one Concat module, and one GSbottleneck module. The VoVGSCSP module is first divided into two branches: one branch consists of a single 2D convolutional layer, and the other branch consists of a single 2D convolutional layer and a GSbottleneck module. The outputs of both branches are fed into the Concat module and then into a single 2D convolutional layer. All convolutional layers have a kernel size of 1×1 and a stride of 1, without padding. The output feature map of the 2D convolutional layer in the same branch as the GSbottleneck module has half the number of channels as the input feature map.
[0076] like Figure 9 As shown, the GSbottleneck module employs residual connections. Its main branch consists of two GSConv modules, with the output feature map of the second GSConv module having twice the number of channels as the input feature map. The residual branch contains only one 2D convolutional layer with a kernel size of 3×3, a stride of 1, and padding of 1 unit. Both the 2D convolutional layer and the 2D depthwise separable convolutional layer in the GSConv module have kernel sizes of 2×2, strides of 1, and are padded with 1 unit.
[0077] like Figure 10 As shown, the GSConv module consists of a 2D convolutional layer, a 2D separable convolutional layer, a Concat module, and a shuffle layer. The kernel size of both the 2D convolutional layer and the 2D separable convolutional layer is 2×2, and the stride is 1. The feature maps first enter the 2D convolutional layer. Half of the output channel feature maps are fed into the 2D separable convolutional layer and then output to the Concat module. The other half of the output channel feature maps are directly fed into the Concat module. Finally, the feature maps enter the shuffle layer for channel rearrangement.
[0078] 4. Import the dataset into the YOLOv8_CMC network.
[0079] Import the data from the YOLOv8_CMC network, including XCT plots and corresponding annotation files.
[0080] 5. Following the network model structure described above, construct the YOLOv8_CMC network using the PyTorch neural network framework; the operating system used is Windows. Set the training iterations to 300. Use the SGD stochastic gradient algorithm to train the YOLOv8_CMC network. Initialize the network weights using the MSRA method and set the weight decay coefficient to 0.0005. Initialize the network biases using the He method. Set a specified file path to save the weight file and corresponding evaluation parameters after training.
[0081] VI. Conduct training on the YOLOv8_CMC network.
[0082] Based on the 512 feature channels output from the last 2D convolutional layer of the Segment module in the head network, the probability of pixels at the same position in each of the 512 feature channels is calculated and compared. The category with the highest probability is selected to determine the category of this pixel in the XCT slice image. By combining the results obtained from the three Segment modules in this iterative calculation, a complete XCT fiber bundle segmentation prediction map can be obtained. The WIoU loss function is used to calculate the difference between the ground truth map and the segmentation prediction map to obtain the loss of the YOLOv8_CMC network. The weights of the YOLOv8_CMC network are updated using the backpropagation algorithm and the SGD algorithm. After training, the weight file and the corresponding evaluation parameters are obtained. After each training, the corresponding weight file is saved, and the XCT image on the validation set is segmented using the weight file to obtain three evaluation metrics: precision, recall, and mean precision.
[0083] 7. After the YOLOv8_CMC network is trained, select a specific folder, perform semantic segmentation on all images, and save the results in that folder.
[0084] The optimal weight file is selected by considering three evaluation metrics: precision, recall, and mean precision. The file with the best segmentation performance is chosen as the optimal weight file for segmenting all XCT images.
[0085] This invention identifies fiber bundles in 2.5D braided preforms of ceramic matrix composites by establishing a YOLOv8_CMC network. Lightweight modules such as VanillaNet, VoVGSCSP, and GSbottleneck are employed, significantly reducing the number of model parameters, accelerating model training, and lowering computational resource consumption. The WIoU loss function optimizes weight updates, enhancing the model's ability to extract fiber bundles and thus improving the accuracy of fiber bundle identification. Simultaneously, the YOLOv8_CMC network's identification and segmentation of fiber bundles in the 2.5D braided preform provides accurate fiber bundle geometric data for the 3D modeling of the 2.5D preform.
[0086] The above are merely preferred embodiments of the present invention. The scope of protection of the present invention is not limited to the above embodiments. All technical solutions that fall within the scope of the present invention are within the scope of protection of the present invention. It should be noted that for those skilled in the art, any improvements and modifications made without departing from the principle of the present invention should be considered within the scope of protection of the present invention.
Claims
1. A method for XCT fiber bundle identification based on improved YOLOv8, characterized in that, Includes the following steps: Step 1: Establish a 2.5D braided fiber bundle XCT slice dataset and divide it into a training set and a validation set; Step 2: Perform data augmentation on the XCT slice dataset to increase the number of samples; Step 3: Establish a network model of the YOLOv8_CMC network for segmenting fiber bundles in the XCT slice dataset; Step 4: Import the XCT slice dataset into the YOLOv8_CMC network; Step 5: Train the YOLOv8_CMC network and save the weight file and corresponding evaluation parameters after training. Step 6: After the YOLOv8_CMC network is trained, perform semantic segmentation on all images and save them in a folder. Based on the three evaluation parameters of precision, recall and mean precision, select the best segmentation result as the optimal weight file to segment all XCT images and complete the fiber bundle recognition of 2.5D braided structures. In step three, the YOLOv8_CMC network model consists of three parts: the backbone network, the neck network, and the head network. These three parts contain a total of 24 modules, including VanillaNet, C2f, SPPF, Segment, Contact, Unsample, VoVGSCSP, and GSConv. The Contact and Unsample modules are consistent with their corresponding modules in the original YOLOv8 model and are not modified. These 24 modules are numbered sequentially from 0 to 23. The backbone network consists of 5 VanillaNet modules, 4 C2f modules, and 1 SPPF module. Modules numbered 0, 1, 3, 5, and 7 are VanillaNet modules; modules numbered 2, 4, 6, and 8 are C2f modules; and module numbered 9 is the SPPF module. The input image is standardized to 640×640 pixels before entering module 0. After passing through module 0, the feature map size becomes 320×320×64 pixels. It then passes through modules 1 through 9 sequentially. The feature maps output from modules 4, 6, and 9 are used as input to the neck network. After passing through the VanillaNet modules, the height and width of the feature map are halved, and the number of channels is doubled. After passing through the SPPF module, the height and width remain unchanged, and the number of channels is halved. After passing through the C2f module, the height, width, and number of channels remain unchanged. The neck network consists of 4 VoVGSCSP modules, 2 GSConv modules, 4 Contact modules, and 2 Upsample modules. Modules numbered 12, 15, 18, and 21 are VoVGSCSP modules; modules numbered 16 and 19 are GSConv modules; modules numbered 11, 14, 17, and 20 are SPPF modules; and modules numbered 10 and 13 are Upsample modules. The connection method of each module is as follows: Module 10 receives data, and module 9 outputs data in a 20×20 format. After receiving the feature map of size ×512, a feature map of size 40×40×512 is output to module 11. Module 11 receives the feature map output by module 10 and the feature map of size 40×40×512 output by module 6, and then outputs a feature map of size 40×40×1024 to module 12. After receiving the feature map input by module 11, module 12 outputs a feature map of size 40×40×512 to modules 13 and 17 respectively. After receiving the feature map input by module 12, module 13 outputs a feature map of size 80×80×512 to module 14. Module 14 receives feature maps of size 80×80×256 from modules 13 and 4, and outputs a feature map of size 80×80×768 to module 15. Module 15 receives the feature map input from module 14 and outputs a feature map of size 80×80×512 to module 16 and the head network respectively. Module 16 receives the feature map input from module 15 and outputs a feature map of size 40×40×256 to module 17. Module 17 receives the feature maps input from modules 12 and 16 and outputs a feature map of size 40×40×768 to module 18. After receiving the feature map input from module 17, module 18 outputs a 40×40×512 feature map to module 19 and the head network respectively. After receiving the feature map input from module 18, module 19 outputs a 20×20×512 feature map to module 20. After receiving the feature map output from module 19 and module 9 in the backbone network, module 20 outputs a 20×20×1024 feature map to module 21. After receiving the feature map input from module 20, module 21 outputs a 20×20×512 feature map to the head network. The head network consists of three segment modules, numbered 21, 22, and 23. Modules 21, 22, and 23 receive feature maps from modules 15, 18, and 21 in the neck network, respectively, and then identify and segment the fiber bundles to output mask results. The head network combines the mask results output by these three segment modules to finally output XCT images of the segmented fiber bundles.
2. The XCT fiber bundle identification method based on improved YOLOv8 according to claim 1, characterized in that, In step one, the fiber bundles of the 2.5D braided structure are manually marked to generate label files in the open-source software Labelme, with a test set to validation set ratio of 7:
3.
3. The XCT fiber bundle identification method based on improved YOLOv8 according to claim 1, characterized in that, In step two, the XCT slice dataset is augmented using methods including cropping, flipping, rotating, adding noise, brightness variation, and contrast enhancement. After augmentation, the ratio of the test set to the validation set in the dataset is 7:
3.
4. The XCT fiber bundle identification method based on improved YOLOv8 according to claim 1, characterized in that, The VanillaNet module consists of five parts. The first part is a 2D convolutional layer with a kernel size of 3×3 and a stride of 4, with 512 kernels. The second, third, and fourth parts are 2D max pooling layers with a kernel size of 1×1 and a stride of 2, with 1024, 2048, and 4096 kernels respectively. The fifth part is a 2D average pooling layer with a kernel size of 2×2 and a stride of 1. Each part ends with an activation layer using the SiLu activation function, and a 2D regularization layer is added between the max pooling layer and the activation layer in the second, third, and fourth parts. The C2f module consists of one Concat module, two Conv modules, and six Bottleneck modules. The two Conv modules are the first and last modules of the C2f module, respectively. The two Conv modules have 2×2 kernels and strides of 2 in their 2D convolutional layers, and both use padding with a padding size of 1. Both have the same number of kernels. The first Conv module is followed by six Bottleneck modules, all of which use residual connections. Half of the feature map from the output is passed to the next module, and the other half of the feature map is passed to the Concat module. The Concat module is located between the last Bottleneck module and the last Conv module. The SPPF module consists of one Concat module, two Conv modules, and four 2D max pooling layers. The two Conv modules are the first and last modules of the SPPF module, respectively. The convolutional kernels of the two 2D convolutional layers are both 1×1 with a stride of 1 and no padding is used. The first Conv module is followed by four 2D average pooling layers, each with a kernel size of 2×2 and a stride of 1. All of these layers use residual connections. Half of the feature map from the output is fed into the next layer, and the other half of the feature map is fed into the Concat module, which is located between the last 2D average pooling layer and the last Conv module. The Segment module has two branches. The first branch consists of two Conv modules, a 2D convolutional layer, and a loss function calculation layer (MasLoss). In both Conv modules, the 2D convolutional layer has a 3×3 kernel size, a stride of 1, and is padded with a padding size of 1. The 2D convolutional layer has a 1×1 kernel size, a stride of 1, and no padding, with a total of 4 kernels. The MasLoss loss function calculation layer uses the WIoU loss function to calculate the loss for fiber bundle segmentation. The second branch also consists of two Conv modules, a 2D convolutional layer, and a loss function calculation layer (ClsLoss). In both Conv modules, the 2D convolutional layer has a 3×3 kernel size, a stride of 1, and is padded with a padding size of 1. The 2D convolutional layer has a 1×1 kernel size, a stride of 1, and no padding, with a total of 4 kernels. The ClsLoss loss function calculation layer uses the BCE loss function to calculate the loss for fiber bundle segmentation. The Bottleneck module is composed of two Conv modules connected sequentially using residual connections. In the main branch, the first Conv module has a 1×1 kernel size and a stride of 1 for its 2D convolutional layer, and does not use padding. The second Conv module has a 3×3 kernel size and a stride of 1 for its 2D convolutional layer, and uses padding with a padding size of 1. There are no modules in the residual branch. The Conv module consists of a 2D convolutional layer, a 2D regularization layer, and an activation layer, where the activation layer uses the ReLU activation function. The VoVGSCSP module consists of three 2D convolutional layers, one Concat module, and one GSbottleneck module. The VoVGSCSP module is first divided into two branches: one branch consists of a single 2D convolutional layer, and the other branch consists of a single 2D convolutional layer and a GSbottleneck module. The outputs of both branches are fed into the Concat module and then into a single 2D convolutional layer. All convolutional layers have a 1×1 kernel size and a stride of 1, and no padding is used. The output feature map of the 2D convolutional layer in the same branch as the GSbottleneck module has half the number of channels as the input feature map. The GSbottleneck module employs residual connections. Its main branch consists of two GSConv modules. The second GSConv module outputs a feature map with twice the number of channels as its input feature map. The residual branch contains only one 2D convolutional layer with a 3×3 kernel size, a stride of 1, and padding of 1 unit. Both the 2D convolutional layer and the 2D depthwise separable convolutional layer within the GSConv module have 2×2 kernel sizes, a stride of 1, and are padded with 1 unit. The GSConv module consists of a 2D convolutional layer, a 2D separable convolutional layer, a Concat module, and a shuffle layer. The kernel size of both the 2D convolutional layer and the 2D separable convolutional layer is 2×2, and the stride is 1. The feature maps first enter the 2D convolutional layer. Half of the output channel feature maps are then passed to the 2D separable convolutional layer before being output to the Concat module, while the other half of the output channel feature maps are directly passed to the Concat module. Finally, the feature maps enter the shuffle layer for channel rearrangement.
5. The XCT fiber bundle identification method based on improved YOLOv8 according to claim 4, characterized in that, In step five, the YOLOv8_CMC network is built using the PyTorch neural network framework, and the YOLOv8_CMC network is trained using the SGD stochastic gradient algorithm.
6. The XCT fiber bundle identification method based on improved YOLOv8 according to claim 5, characterized in that, In step five, the specific method for obtaining the weight file and corresponding evaluation parameters is as follows: Based on the 512 feature channels output by the last two-dimensional convolutional layer of the Segment module in the head network, calculate and compare the probability of each pixel at the same position in the 512 feature channels, select the category with the highest probability to determine the category of this pixel in the XCT slice image, and combine the results obtained by iteratively calculating the three Segment modules to obtain a complete XCT fiber bundle segmentation prediction map; use the WIoU loss function to calculate the difference between the ground truth map and the segmentation prediction map to obtain the loss of the YOLOv8_CMC network, and update the weights of the YOLOv8_CMC network through the backpropagation algorithm and the SGD algorithm. After training, the weight file and corresponding evaluation parameters are obtained.
7. The XCT fiber bundle identification method based on improved YOLOv8 according to claim 6, characterized in that, In step five, the YOLOv8_CMC network is trained 300 times.
8. The XCT fiber bundle identification method based on improved YOLOv8 according to claim 7, characterized in that, In step six, the method for obtaining the three evaluation parameters of precision, recall, and mean precision is as follows: after each training of the YOLOv8_CMC network, the corresponding weight file is saved, and the XCT image on the validation set is segmented using the weight file to obtain the three evaluation metrics of precision, recall, and mean precision.