Intelligent identification method and system for blasting demolition garbage based on improved YOLOv8 model
Patent Information
- Application Number
- CN202611477918.4
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2026-09-22
- Publication Date
- 2026-10-27
AI Technical Summary
然而,此类传统方法在面对材质相似的建筑垃圾(如混凝土与砖块)时,区分能力较弱,尤其在密集堆叠场景下,漏检率普遍高至30%,难以满足高精度分选要求
[0015]本发明的有益效果为:识别精度显著提升:在自建测试集(包含500张复杂场景图像)上,本发明方法的mAP@0.5达到92.3%,较原始YOLOv8(78.5%)提升13.8个百分点,较Faster R-CNN(81.2%)提升11.1个百分点。其中,瓦片(小目标)的识别精度从65.2%提升至89.1%,混凝土(含钢筋)的漏检率从32.7%降至5.2%。
Smart Images

Figure CN122990664A_ABST
Abstract
Description
Technical Field
[0001] This invention relates to the fields of computer vision and environmental protection technology, and in particular to a method and system for intelligent identification of demolition waste based on an improved YOLOv8 model. Background Technology
[0002] Efficient sorting of construction waste is a core step in achieving resource utilization. Existing construction waste image recognition technologies classify waste images using standard CNN networks. However, these traditional methods are weak in distinguishing between construction waste of similar materials (such as concrete and bricks), especially in densely stacked scenarios, where the false negative rate is generally as high as 30%, making it difficult to meet the requirements for high-precision sorting. In addition, while existing deep learning models have high accuracy, their inference speed on mobile devices is usually less than 15 FPS, which cannot meet the real-time requirements of dynamic on-site operations. Furthermore, their deployment heavily relies on high-performance GPU servers, resulting in high single-point deployment costs and significantly restricting the large-scale application of the technology.
[0003] In summary, existing technologies mainly suffer from three major bottlenecks: insufficient recognition accuracy, poor real-time performance, and high deployment costs. Summary of the Invention
[0004] The purpose of this invention is to provide an intelligent identification method and system for demolition debris based on an improved YOLOv8 model. By improving the network structure of the YOLOv8 model, designing a dynamic training strategy, and using lightweight deployment technology, the invention systematically solves the bottlenecks of existing technologies and is applicable to the automated identification and resource scheduling of concrete blocks, bricks, and broken tiles at building demolition sites.
[0005] To achieve the above objectives, the present invention provides the following solution: A method for intelligent identification of blasting demolition debris based on an improved YOLOv8 model includes: Collect image and video data from building demolition sites, label target objects, and construct a multimodal construction waste dataset; The improved YOLOv8 model is dynamically trained using the multimodal construction waste dataset to obtain the trained improved YOLOv8 model. The improved YOLOv8 model is obtained by embedding a coordinate attention mechanism module after the C2f module of the backbone network and replacing the original detection head with a lightweight detection head. The coordinate attention mechanism module captures spatial location information through bidirectional pooling operation. The trained and improved YOLOv8 model is lightweighted, and the lightweight model is deployed to a mobile terminal to achieve real-time detection, outputting garbage category, bounding box coordinates and confidence score.
[0006] Optionally, labeling the target object includes: Use polygonal annotation boxes to annotate target objects including concrete, bricks, and tiles. Specifically, annotate the outer contour and internal steel reinforcement distribution area of the concrete, annotate the complete edge and glazed reflective area of the bricks, and annotate the curved edge and surface anti-slip texture area of the tiles.
[0007] Optionally, the coordinate attention mechanism module captures spatial location information through bidirectional pooling operations, including: Global pooling is performed on the input feature map in both the height and width directions to generate feature codes in the height and width directions respectively; The feature encodings in the height and width directions are respectively input into the first fully connected layer, the ReLU activation function, the second fully connected layer, and the Sigmoid activation function to generate a height attention map and a width attention map; The spatial attention map is obtained by multiplying the height attention map and the width attention map element by element. The spatial attention map is element-wise multiplied with the input feature map to enhance the position-sensitive features of the target object.
[0008] Optionally, the lightweight detection head is constructed using depth-separable convolution.
[0009] Optionally, dynamic training of the improved YOLOv8 model includes: Phase 1: Freeze backbone network parameters and train feature fusion layer; The second stage involves unfreezing the entire network and fine-tuning the backbone network parameters using a cosine annealing learning rate strategy, while also introducing a dynamic weight loss function.
[0010] Optionally, lightweighting the trained improved YOLOv8 model includes: A quantization-aware training method was used to convert the trained and improved YOLOv8 model into INT8 quantization format.
[0011] Optionally, converting the trained improved YOLOv8 model to INT8 quantization format includes: Using the validation set images as the calibration dataset, the distribution of activation values in each layer is statistically analyzed to determine the quantization threshold; During backpropagation, a pseudo-quantization node is inserted to simulate the rounding operation of INT8. Based on the quantization threshold, the parameters of the improved YOLOv8 model after training are fine-tuned and updated to minimize the loss after quantization. After the parameters are updated, the TensorRT tool is used to convert the model to INT8 format, remove redundant floating-point operation nodes, and merge the convolutional layer and batch normalization layer into a single convolutional layer.
[0012] This invention also provides an intelligent identification system for blasting demolition waste based on an improved YOLOv8 model, comprising: The image acquisition module is used to collect image and video data from the building demolition site, and to annotate target objects to build a multimodal construction waste dataset. The model training module, connected to the image acquisition module, is used to dynamically train the improved YOLOv8 model using the multimodal construction waste dataset to obtain the trained improved YOLOv8 model. The improved YOLOv8 model is obtained by embedding a coordinate attention mechanism module after the C2f module of the backbone network and replacing the original detection head with a lightweight detection head. The coordinate attention mechanism module captures spatial location information through bidirectional pooling operations. The real-time detection module, connected to the model training module, is used to lightweight the trained and improved YOLOv8 model, deploy the lightweight model to a mobile terminal to achieve real-time detection, and output the garbage category, bounding box coordinates and confidence score.
[0013] Optionally, the system may also include a data analysis module: The data analysis module, connected to the real-time detection module, includes a heat map generation unit and a decision support unit. The heat map generation unit generates a construction waste distribution density map based on geographic coordinates, and the decision support unit exports a historical data trend analysis report.
[0014] Optionally, the heat map generation unit generates a construction waste distribution density map based on geographic coordinates, including: The center coordinates of the detected target and GPS positioning data are mapped to a two-dimensional plane using a coordinate transformation formula. Density values are calculated for data mapped to a two-dimensional plane based on the Epanechnikov kernel function. The density values are mapped to color gradients using WebGL technology to generate the construction waste distribution density map.
[0015] The beneficial effects of this invention are as follows: Significantly improved recognition accuracy: On a self-built test set (containing 500 complex scene images), the mAP@0.5 of this invention reaches 92.3%, an improvement of 13.8 percentage points compared to the original YOLOv8 (78.5%), and an improvement of 11.1 percentage points compared to Faster R-CNN (81.2%). Specifically, the recognition accuracy for tiles (small targets) increased from 65.2% to 89.1%, and the false negative rate for concrete (including reinforcing steel) decreased from 32.7% to 5.2%.
[0016] Significantly optimized real-time performance: On mobile terminals with the ARM Cortex-A77 architecture, the inference speed reaches 25.6 FPS, a 212% improvement over the original YOLOv8 (8.2 FPS), meeting the dynamic operational requirements of "dismantling and sorting simultaneously" at the demolition site. The model size is compressed to 92MB (40% of the original floating-point model), with a memory usage of only 185MB (target ≤200MB), making it compatible with mainstream mobile devices (such as Huawei Mate 60 Pro and DJI Matrice 350 RTK flight controller).
[0017] Deployment costs are significantly reduced: the system does not rely on GPU servers and can run on mobile terminals with ARM Cortex-A77 or higher performance. The purchase cost of a single device is less than 5,000 yuan (more than 90% lower than traditional GPU servers). Combined with lightweight deployment technology, the device consumes only 3.2W (typical value) and has a battery life of more than 8 hours (equipped with a 5000mAh battery), making it suitable for long-term outdoor operations. Attached Figure Description
[0018] To more clearly illustrate the technical solutions in the embodiments of the present invention or the prior art, the drawings used in the embodiments will be briefly introduced below. Obviously, the drawings described below are only some embodiments of the present invention. For those skilled in the art, other drawings can be obtained based on these drawings without creative effort.
[0019] Figure 1 This is an overall architecture diagram of the intelligent identification method for blasting demolition waste based on the improved YOLOv8 model according to an embodiment of the present invention; Figure 2 This is a structural diagram of the improved YOLOv8 model according to an embodiment of the present invention; Figure 3 This is a flowchart of the dynamic training strategy according to an embodiment of the present invention. Detailed Implementation
[0020] The technical solutions of the embodiments of the present invention will be clearly and completely described below with reference to the accompanying drawings. Obviously, the described embodiments are only some embodiments of the present invention, and not all embodiments. Based on the embodiments of the present invention, all other embodiments obtained by those skilled in the art without creative effort are within the scope of protection of the present invention.
[0021] To make the above-mentioned objects, features and advantages of the present invention more apparent and understandable, the present invention will be further described in detail below with reference to the accompanying drawings and specific embodiments.
[0022] like Figure 1As shown, this embodiment proposes an intelligent identification method for blasting demolition waste based on an improved YOLOv8 model, including: Collect image and video data from building demolition sites, label target objects, and construct a multimodal construction waste dataset; The improved YOLOv8 model is dynamically trained using the multimodal construction waste dataset to obtain the trained improved YOLOv8 model. The improved YOLOv8 model is obtained by embedding a coordinate attention mechanism module after the C2f module of the backbone network and replacing the original detection head with a lightweight detection head. The coordinate attention mechanism module captures spatial location information through bidirectional pooling operation. The trained and improved YOLOv8 model is lightweighted, and the lightweight model is deployed to a mobile terminal to achieve real-time detection, outputting garbage category, bounding box coordinates and confidence score.
[0023] Furthermore, the annotation of the target object includes: Use polygonal annotation boxes to annotate target objects including concrete, bricks, and tiles. Specifically, annotate the outer contour and internal steel reinforcement distribution area of the concrete, annotate the complete edge and glazed reflective area of the bricks, and annotate the curved edge and surface anti-slip texture area of the tiles.
[0024] Specifically, in this embodiment, the following data collection equipment is deployed at a demolition site: Industrial camera (model: Basler acA640-120gc): mounted above the dismantling robot arm (5 meters high), capturing images of a 1.5m × 1.5m area directly below (640 × 640 resolution, 30 FPS frame rate). Drone (model: DJI Mavic 3 Pro): Flying at an altitude of 30 meters and at a speed of 5 m / s around the construction site, capturing panoramic video (4K resolution, 30 FPS). Fixed surveillance camera (model: Hikvision DS-2CD3T46WDV3-L): installed on the construction site fence (6 meters high) to cover the perimeter of the demolition area (1080P resolution, 25FPS frame rate).
[0025] The data collection period was 7 days (covering sunny, cloudy, and light rain weather), resulting in a total of 52,300 images and 105 hours of video data. After labeling using the LabelMe tool, invalid data (8%) that were blurry or excessively occluded were manually reviewed and removed, ultimately yielding a training set of 14,500 images, a validation set of 4,800 images, and a test set of 30,000 images.
[0026] The complex scene characteristics of construction waste (lighting variations, occlusion, material reflection) require the model to have strong generalization ability. This embodiment constructs a multimodal dataset containing images and videos, and the specific implementation steps are as follows: Data Acquisition: Deploy multi-source acquisition devices (industrial cameras, drones, fixed surveillance cameras) at actual demolition sites (such as concrete frame structures and brick-concrete structures) to cover the following scenarios: 1) Light conditions: strong light (12:00 noon, irradiance > 100,000 lux), weak light (6:00 am, irradiance < 10,000 lux), backlight (solar altitude angle < 30°); 2) Occlusion level: No occlusion (the target is fully visible), partially occluded (occlusion area accounts for 20%-80%), completely occluded (only the edge is visible); 3) Stacking status: loose stacking (target spacing > 50cm), tight stacking (target spacing < 20cm). A total of 50,000 images (uniform resolution 640×640) and 100 hours of video data (30FPS frame rate) were collected, covering more than 90% of typical demolition scenes.
[0027] Data annotation: The LabelMe tool was used for polygon annotation, and annotation specifications were designed for the edge details of concrete (including protruding reinforcing bars), bricks (surface glaze reflection), and tiles (rounded edge features). Concrete: Mark the outer contour and the distribution area of internal reinforcing bars (the marking box must include ≥80% of the projected area of the reinforcing bars); Brick: Mark the complete edge, and highlight the reflective areas of the glaze (high-gloss spots); Tile: Mark the curved edge and the anti-slip textured area on the surface (the marking frame must fit the curved surface of the tile).
[0028] After the annotation is completed, manual verification (sampling ratio 10%) is used to ensure the consistency of the annotation (Intersection over Union (IoU) ≥ 0.9). Finally, a training set containing 15,000 annotated images, a validation set of 5,000 images, and a test set of 30,000 images are generated.
[0029] Data augmentation: For small sample scenarios (such as tiles accounting for only 15% of the total dataset), methods such as Mosaic data augmentation (stitching 4 images), MixUp (weighted fusion of images and labels), and HSV color perturbation (brightness ±20%, saturation ±10%, hue ±15°) are used to improve the model's ability to recognize rare categories.
[0030] Furthermore, the coordinate attention mechanism module captures spatial location information through bidirectional pooling operations, including: Global pooling is performed on the input feature map in both the height and width directions to generate feature codes in the height and width directions respectively; The feature encodings in the height and width directions are respectively input into the first fully connected layer, the ReLU activation function, the second fully connected layer, and the Sigmoid activation function to generate a height attention map and a width attention map; The spatial attention map is obtained by multiplying the height attention map and the width attention map element by element. The spatial attention map is element-wise multiplied with the input feature map to enhance the position-sensitive features of the target object.
[0031] Specifically, the original YOLOv8 uses CSPDarknet53 as the backbone network and integrates the Feature Pyramid Network (FPN) and Path Enhancement Network (PAN) through PANet (Path Aggregation Network). While it performs well in general object detection, it lacks adaptability to scenarios involving "small targets (such as tile edges) + complex textures (such as concrete cracks)" in construction waste. Figure 2 As shown, this embodiment improves model accuracy through the following improvements: Backbone network optimization: An embedded coordinate attention (CA) mechanism module is inserted after the C2f module (YOLOv8's feature extraction unit) to address the issue that traditional attention mechanisms (such as the SE module) only focus on channel information and ignore spatial location. The specific implementation is as follows: 1) For the input feature map F∈R H×W×C (H: height, W: width, C: number of channels), perform global average pooling (GAP) along the height direction (H) and width direction (W) respectively to obtain two one-dimensional feature codes: ; ; Where i is the index in the height direction (ranging from 1 to H), and j is the index in the width direction (ranging from 1 to W). and These are feature codes for the height and width directions, respectively.
[0032] 2) and A high-level attention map is generated by passing the image through a fully connected layer (reducing the dimensionality to C / r, where r is the compression ratio, and r=16) and a ReLU activation function, followed by another fully connected layer (reducing the dimensionality back to C) and a Sigmoid activation function. ∈R H ×1×1and width attention map ∈R 1×W×1 ; 3) and Element-wise multiplication yields a two-dimensional spatial attention map A∈R. H×W×1 Finally, it is multiplied element-wise with the input feature map F to enhance the target location-sensitive features.
[0033] This module captures long-distance spatial dependencies through bidirectional pooling, enabling the model to more accurately locate small features such as concrete cracks and brick edges.
[0034] Detector Head Replacement: The original YOLOv8 detector head uses convolutional layers to directly predict bounding boxes and class confidence scores, resulting in a large number of parameters (approximately 25% of the total model). This embodiment replaces it with a lightweight detector head constructed using depthwise separable convolution, with the following structure: 1) Depthwise separable convolutional layer: First, perform channel-wise convolution (Depthwise Conv, kernel size 3×3, padding 1), then perform pointwise convolution (Pointwise Conv, kernel size 1×1, number of output channels 3×(4+3)=21, where 4 is the bounding box coordinates and 3 is the number of classes). 2) Feature fusion layer: Introducing residual connections, which add the feature map from the previous stage (from the top-down path of PANet) to the feature map of the current layer to alleviate the gradient vanishing problem; 3) Output layer: The class probability is output through the Softmax activation function, and the bounding box coordinate offset is output through the Sigmoid activation function.
[0035] The improved detector has 40% fewer parameters and 35% less computational cost (FLOPs), making it more suitable for mobile deployment.
[0036] Furthermore, dynamic training of the improved YOLOv8 model includes: Phase 1: Freeze backbone network parameters and train feature fusion layer; The second stage involves unfreezing the entire network and fine-tuning the backbone network parameters using a cosine annealing learning rate strategy, while also introducing a dynamic weight loss function.
[0037] Specifically, to address the overfitting problem of the model in complex scenes and improve the recognition ability of small sample categories (such as tiles), this embodiment designs a staged dynamic training strategy. Model training is performed on an NVIDIA RTX 3090 GPU (24GB VRAM), with the environment configured to install PyTorch 2.0, CUDA 11.7, OpenCV 4.5.5, and the YOLOv8 open-source framework (version v8.0.108). Figure 3 As shown, the specific training process is as follows: Phase 1: Freeze the backbone network and pre-train the feature fusion layer. Initially, freeze the parameters of the backbone network (C2f module + CA module) and train only the feature fusion layer (including output fusion from the coordinate attention module and residual connections in the detection head). Training parameter settings: Optimizer: AdamW (weight decay 0.001); Learning rate: Initial learning rate 1e-3, using cosine annealing strategy (50 rounds, minimum learning rate 1e-5). Batch size: 16 (limited by training server memory); Training rounds: 50 rounds.
[0038] The goal of this stage is to enable the model to quickly adapt to the multimodal feature distribution of construction waste by leveraging the feature extraction capabilities of the fixed backbone network.
[0039] Phase Two: Unfreeze the entire network and fine-tune the backbone network parameters. A smaller learning rate (1e-4) is used for full network fine-tuning, and a dynamic weight loss function is introduced to address the class imbalance problem. Dynamic weight coefficients. Defined as: ; in, Let be the number of samples in category c. The maximum number of samples in the largest category in the dataset (e.g., concrete has the most samples). =8,000). This design allows for small sample categories (such as tiles, The loss weights (=2,000) are increased by 4 times, forcing the model to focus on learning rare classes. Training parameter settings: Optimizer: SGD (momentum 0.937); Batch size: 32; Training rounds: 100 rounds; Early stopping mechanism: Training is stopped when the validation set mAP shows no improvement for 10 consecutive rounds.
[0040] Furthermore, the lightweighting of the trained and improved YOLOv8 model includes: A quantization-aware training method was used to convert the trained and improved YOLOv8 model into INT8 quantization format.
[0041] Specifically, to achieve real-time detection on mobile devices, this embodiment adopts a comprehensive optimization strategy of "model compression + hardware adaptation" to convert the original floating-point model (FP32) into an INT8 quantization model suitable for the ARM architecture.
[0042] This embodiment uses TensorRT 8.6 to convert the trained model into INT8 quantization format. The specific steps are as follows: Model quantization: Quantization-aware training (QAT) is employed to simulate the rounding error of INT8 quantization during training, enabling the model to learn and adapt to parameters requiring low-precision computation. The quantization process includes: 1) Calibration phase: Use 100 validation set images as the calibration dataset (covering strong light, weak light, and backlight scenes), and statistically analyze the distribution of activation values in each layer (minimum, maximum, and mean). Determine the quantization threshold (e.g., the symmetric quantization threshold is the 99.9th percentile of the activation value range). The quantization threshold is used to limit the dynamic range of activation values. In subsequent pseudo-quantization nodes, floating-point activation values will be cropped and mapped to the INT8 integer range (e.g., -127 to 127) to minimize the truncation error caused by quantization.
[0043] In this embodiment, the maximum value of the convolutional layer output is 2.5, the minimum value is -1.8, and the symmetric quantization threshold is 2.5.
[0044] 2) Training phase: During backpropagation, a fake quantize node is inserted to simulate the rounding operation of INT8. Based on the quantization threshold determined in the calibration phase, the parameters of the improved YOLOv8 model after training are fine-tuned and updated to minimize the loss after quantization. 3) Conversion phase: After the training phase is completed, the TensorRT tool is used to convert the model to INT8 format and remove redundant floating-point operation nodes.
[0045] In this implementation, the quantization conversion command is executed using TensorRT's trtexec tool: trtexec --onnx=model.onnx --int8 --calib=calib.txt --saveEngine=model.engine Here, --onnx=model.onnx specifies the path to the input ONNX format model file; --int8 enables INT8 quantization precision mode; --calib=calib.txt is a list of paths to the calibration dataset, used to perform activation value statistics during the calibration phase; --saveEngine=model.engine specifies the save path to the output inference engine file.
[0046] 4) Layer fusion optimization: The convolutional layer (Conv2D) and the batch normalization layer (BatchNorm2D) are merged into a single convolutional layer, as shown in the formula: ; ; in, ε represents the convolution kernel weights, γ and β are the scaling and translation parameters of BatchNorm, μ and σ² are the mean and variance of the statistics during the training phase, and ε is a small constant (taken as 1e-5) to prevent division by zero. These are the weight parameters of the merged convolutional layer. These are the bias parameters for the fused convolutional layers. Layer fusion reduces the number of computation nodes and improves inference speed.
[0047] 5) Hardware Adaptation: For the NEON instruction set of the ARM Cortex-A77 architecture (supporting 128-bit SIMD operations), vectorization optimizations are performed on operators such as convolution and activation functions (ReLU, Sigmoid). For example, a 3×3 convolution is decomposed into a combination of 1×3 and 3×1 convolutions, utilizing NEON's parallel computing capabilities to process multiple pixels simultaneously; a piecewise linear approximation (PLA) is used for the Sigmoid function, reducing computational complexity from exponential operations to table lookup operations.
[0048] In this embodiment, model.engine is deployed on a Huawei Mate 60 Pro (Kirin 9000S chip, ARM Cortex-A77@2.4GHz), and the model is loaded through the OpenCV DNN module to achieve real-time detection. Actual test results show that the inference time for a single image is 39ms, with an FPS of 25.6, meeting the real-time requirements of demolition sites.
[0049] This embodiment also provides an intelligent identification system for blasting demolition waste based on an improved YOLOv8 model, including: The image acquisition module is used to collect image and video data from the building demolition site, and to annotate target objects to build a multimodal construction waste dataset. The model training module, connected to the image acquisition module, is used to dynamically train the improved YOLOv8 model using the multimodal construction waste dataset to obtain the trained improved YOLOv8 model. The improved YOLOv8 model is obtained by embedding a coordinate attention mechanism module after the C2f module of the backbone network and replacing the original detection head with a lightweight detection head. The coordinate attention mechanism module captures spatial location information through bidirectional pooling operations. The real-time detection module, connected to the model training module, is used to lightweight the trained and improved YOLOv8 model, deploy the lightweight model to a mobile terminal to achieve real-time detection, and output the garbage category, bounding box coordinates and confidence score.
[0050] Specifically, the image acquisition module is responsible for the real-time acquisition and preprocessing of multi-source data, ensuring that the data quality input to the model meets the detection requirements. Its specific structure includes: Multi-source adapter unit: Supports video stream input from mobile terminals (such as mobile phones, industrial PDAs), drones (such as DJI Mavic 3 Pro), and fixed monitoring equipment (such as Hikvision DS-2CD3T46WDV3-L). It acquires raw data via RTSP (Real-Time Streaming Protocol) or USB interface, automatically adapts to different resolutions (such as 4K, 1080P, 720P) and frame rates (25FPS, 30FPS, 60FPS), and synchronizes multi-source data via timestamps (error <10ms).
[0051] Preprocessing unit: Performs distortion correction (Zhang Zhengyou calibration method for radial distortion of UAV camera), noise suppression (using nonlocal mean filtering, window size 5×5) and size normalization (uniformly scaled to 640×640) on the input data to ensure that the images of the input model conform to the data distribution during training.
[0052] The model training module integrates the improved YOLOv8 model training process described in the methodology, including attention enhancement units and dynamic training units, and supports offline training and online incremental learning.
[0053] Attention Enhancement Unit: Enables embedded deployment of the coordinate attention module, accelerating attention map computation through CUDA acceleration (if trained in a GPU environment) or ARM NEON instructions (if trained at the edge). During training, the entropy of the feature map is monitored in real time. When the entropy falls below a threshold (e.g., 3.5 bits), the compression ratio r of the CA module is automatically adjusted (from 16 to 8) to enhance the discriminative power of the attention map.
[0054] The dynamic training unit executes a phased dynamic training strategy, including a model parameter manager (storing parameters of the backbone network and detector heads), a learning rate scheduler (adjusting the learning rate based on a cosine annealing strategy), and a loss function calculator (calculating dynamic weight loss). During training, metrics such as mAP and FPS are monitored in real time using the TensorBoard visualization tool. When the validation set mAP improves by less than 0.5% for five consecutive rounds, an early stopping mechanism is automatically triggered to avoid overfitting.
[0055] The real-time detection module is the core execution unit of the system. It is responsible for loading the lightweight model and performing real-time detection on the input data. It includes a lightweight inference unit and a visualization interaction unit.
[0056] Lightweight inference unit: Loads the INT8 quantized YOLOv8 model (model size 92MB, original floating-point model 230MB), and performs efficient computation through the TensorRT inference engine. The inference process includes: Input preprocessing: Image normalization (mean [0.485, 0.456, 0.406], standard deviation [0.229, 0.224, 0.225]) and channel conversion (HWC→CHW); Feature extraction: Multi-scale feature maps (640×640→320×320→160×160) are extracted through an improved backbone network (including CA module). Object detection: Predict bounding boxes and class confidence using a lightweight detection head, and apply non-maximum suppression (NMS, intersection-over-union threshold of 0.5) to remove duplicate detection boxes; Output: Returns the target category (concrete / brick / tile), bounding box coordinates, and confidence level (0-1).
[0057] Actual test data shows that on the Huawei Atlas 200DK development board (ARM Cortex-A77@2.4GHz, 8GB LPDDR4X memory), the inference latency for a single image is 39ms (corresponding to FPS=25.6), which meets the real-time requirements of the demolition site.
[0058] Visualization and Interaction Unit: Utilizing the OpenCV library, the unit renders detection results in real-time, drawing bounding boxes (colors: red for concrete, blue for bricks, green for tiles) and confidence text (font size 12, transparency 0.7) on the original image. Simultaneously, the unit transmits the detection results (JSON format) to a host computer or mobile terminal via serial port or Wi-Fi, allowing on-site operators to view and intervene (e.g., manually correcting false positives).
[0059] Furthermore, the system also includes a data analysis module: The data analysis module, connected to the real-time detection module, includes a heat map generation unit and a decision support unit. The heat map generation unit generates a construction waste distribution density map based on geographic coordinates, and the decision support unit exports a historical data trend analysis report.
[0060] Specifically, the data analysis module generates statistical reports and decision-making suggestions based on the detection results to assist in the resource-based scheduling of the demolition site, and includes a heat map generation unit and a decision support unit.
[0061] Heatmap generation unit: Visualizes the distribution density of construction waste through the following steps: Coordinate alignment: Aligning the center coordinates of the detected target ( u , v The GPS positioning data (longitude λ, latitude φ) is mapped to a two-dimensional plane geographic coordinate system using a coordinate transformation formula (WGS84 to UTM) to obtain geographic coordinates (X,Y); Kernel density estimation (KDE): Density values within a 500m × 500m grid were calculated using the Epanechnikov kernel function. The formula is: ; Where N is the number of detected targets, and (X,Y) are the geographic coordinates of the density points to be estimated on the two-dimensional plane; Let be the geographic coordinates of the nth detected target on the two-dimensional plane; h=15m is the bandwidth parameter (determined based on cross-validation, taken as 0.3 times the grid side length, i.e., 0.3×50m), used to control the smoothing range of the kernel function. The larger the h value, the smoother the density distribution, and vice versa; K(⋅) is the Epanechnikov kernel function, expressed as: (When |t|≤1, otherwise K(t)=0), where t is the normalized distance variable, i.e. This kernel function has the best mean squared error efficiency in density estimation.
[0062] Dynamic rendering: Using WebGL technology to map density values to color gradients (red: high density, yellow: medium density, blue: low density), supporting 2 refreshes per second, intuitively displaying garbage distribution hotspots.
[0063] Decision support unit: Generates trend analysis reports based on historical monitoring data (last 30 days), including: Category proportion: Daily average production (tons / day) and trend of concrete / bricks / tiles (linear regression fitting). Peak Hours: Predict the peak periods for daily demolition operations (e.g., 10:00-14:00) using time series analysis (ARIMA model). Resource recovery recommendations: Recommend sorting equipment based on material distribution (e.g., prioritize jaw crushers for concrete and impact crushers for bricks), and calculate the recovery rate (e.g., concrete recovery rate ≥ 85%, brick recovery rate ≥ 90%).
[0064] The system ran continuously for 7 days at a demolition site, generating the following analysis report: Heat map: The concrete density is highest in the central part of the demolition area, with an average daily production of about 12 tons; the brick density is highest in the northwest corner, with an average daily production of about 8 tons.
[0065] Decision Recommendations: Based on the material distribution, it is recommended to deploy jaw crushers (for concrete) in the central area and impact crushers (for bricks) in the northwest corner area; the peak demolition period is predicted to be from 10:00 to 14:00 on the 8th day, and more sorting personnel should be added (each additional person will increase sorting efficiency by 15%).
[0066] The embodiments described above are merely preferred embodiments of the present invention and are not intended to limit the scope of the present invention. Various modifications and improvements made to the technical solutions of the present invention by those skilled in the art without departing from the spirit of the present invention should fall within the protection scope defined by the claims of the present invention.
Claims
1. A method for intelligent identification of blasting demolition waste based on an improved YOLOv8 model, characterized in that, include: Collect image and video data from building demolition sites, label target objects, and construct a multimodal construction waste dataset; The improved YOLOv8 model is dynamically trained using the multimodal construction waste dataset to obtain the trained improved YOLOv8 model. The improved YOLOv8 model is obtained by embedding a coordinate attention mechanism module after the C2f module of the backbone network and replacing the original detection head with a lightweight detection head. The coordinate attention mechanism module captures spatial location information through bidirectional pooling operation. The trained and improved YOLOv8 model is lightweighted, and the lightweight model is deployed to a mobile terminal to achieve real-time detection, outputting garbage category, bounding box coordinates and confidence score.
2. The intelligent identification method for blasting demolition waste based on the improved YOLOv8 model according to claim 1, characterized in that, Annotating target objects includes: Use polygonal annotation boxes to annotate target objects including concrete, bricks, and tiles. Specifically, annotate the outer contour and internal steel reinforcement distribution area of the concrete, annotate the complete edge and glazed reflective area of the bricks, and annotate the curved edge and surface anti-slip texture area of the tiles.
3. The intelligent identification method for blasting demolition waste based on the improved YOLOv8 model according to claim 1, characterized in that, The coordinate attention mechanism module captures spatial location information through bidirectional pooling operations, including: Global pooling is performed on the input feature map in both the height and width directions to generate feature codes in the height and width directions respectively; The feature encodings in the height and width directions are respectively input into the first fully connected layer, the ReLU activation function, the second fully connected layer, and the Sigmoid activation function to generate a height attention map and a width attention map; The spatial attention map is obtained by multiplying the height attention map and the width attention map element by element. The spatial attention map is element-wise multiplied with the input feature map to enhance the position-sensitive features of the target object.
4. The intelligent identification method for blasting demolition waste based on the improved YOLOv8 model according to claim 1, characterized in that, The lightweight detection head is constructed using depthwise separable convolution.
5. The intelligent identification method for blasting demolition waste based on the improved YOLOv8 model according to claim 1, characterized in that, Dynamic training of the improved YOLOv8 model includes: Phase 1: Freeze backbone network parameters and train feature fusion layer; The second stage involves unfreezing the entire network and fine-tuning the backbone network parameters using a cosine annealing learning rate strategy, while also introducing a dynamic weight loss function.
6. The intelligent identification method for blasting demolition waste based on the improved YOLOv8 model according to claim 1, characterized in that, Lightweighting the improved YOLOv8 model after training includes: A quantization-aware training method was used to convert the trained and improved YOLOv8 model into INT8 quantization format.
7. The intelligent identification method for blasting demolition waste based on the improved YOLOv8 model according to claim 6, characterized in that, Converting the trained and improved YOLOv8 model to INT8 quantization format includes: Using the validation set images as the calibration dataset, the distribution of activation values in each layer is statistically analyzed to determine the quantization threshold; During backpropagation, a pseudo-quantization node is inserted to simulate the rounding operation of INT8. Based on the quantization threshold, the parameters of the improved YOLOv8 model after training are fine-tuned and updated to minimize the loss after quantization. After the parameters are updated, the TensorRT tool is used to convert the model to INT8 format, remove redundant floating-point operation nodes, and merge the convolutional layer and batch normalization layer into a single convolutional layer.
8. A smart identification system for blasting demolition waste based on an improved YOLOv8 model, used to implement the method described in any one of claims 1-7, characterized in that, include: The image acquisition module is used to collect image and video data from the building demolition site, and to annotate target objects to build a multimodal construction waste dataset. The model training module, connected to the image acquisition module, is used to dynamically train the improved YOLOv8 model using the multimodal construction waste dataset to obtain the trained improved YOLOv8 model. The improved YOLOv8 model is obtained by embedding a coordinate attention mechanism module after the C2f module of the backbone network and replacing the original detection head with a lightweight detection head. The coordinate attention mechanism module captures spatial location information through bidirectional pooling operations. The real-time detection module, connected to the model training module, is used to lightweight the trained and improved YOLOv8 model, deploy the lightweight model to a mobile terminal to achieve real-time detection, and output the garbage category, bounding box coordinates and confidence score.
9. The intelligent identification system for blasting demolition waste based on the improved YOLOv8 model according to claim 8, characterized in that, The system also includes a data analysis module: The data analysis module, connected to the real-time detection module, includes a heat map generation unit and a decision support unit. The heat map generation unit generates a construction waste distribution density map based on geographic coordinates, and the decision support unit exports a historical data trend analysis report.
10. The intelligent identification system for blasting demolition waste based on the improved YOLOv8 model according to claim 9, characterized in that, The heat map generation unit generates a construction waste distribution density map based on geographic coordinates, including: The center coordinates of the detected target and GPS positioning data are mapped to a two-dimensional plane using a coordinate transformation formula. Density values are calculated for data mapped to a two-dimensional plane based on the Epanechnikov kernel function. The density values are mapped to color gradients using WebGL technology to generate the construction waste distribution density map.