| Literature DB >> 35845429 |
Zhiqiang Hao1,2,3, Zhigang Wang1,2, Dongxu Bai1,4, Xiliang Tong3,4.
Abstract
Problems such as redundancy of detection model parameters make it difficult to apply to factory embedded device applications. This paper focuses on the analysis of different existing deep learning model compression algorithms and proposes a model pruning algorithm based on geometric median filtering for structured pruning and compression of defect segmentation detection networks on the basis of structured pruning. Through experimental comparisons and optimizations, the proposed optimization algorithm can greatly reduce the network parameters and computational effort to achieve effective pruning of the defect detection algorithm for steel plate surfaces.Entities:
Keywords: deep learning; defect detection; model compression; semantic segmentation; structured pruning
Year: 2022 PMID: 35845429 PMCID: PMC9283705 DOI: 10.3389/fbioe.2022.945248
Source DB: PubMed Journal: Front Bioeng Biotechnol ISSN: 2296-4185
Model compression methods.
| Methods | Method description | Advantages and disadvantages |
|---|---|---|
| Low-rank decomposition | Low-rank decomposition of parameter matrices | Parameter matrix decomposition is more difficult and requires larger hardware resources |
| Structural design | Designing special convolution kernels | Constructing new modules, trained from 0 |
| Knowledge distillation | Train to optimise your network with a large model as a guide | Training from 0, model performance is more sensitive to network structure is more sensitive |
| Parameter quantification | Replacing high-precision weighting parameters with low precision | The quantified parameters are often not derivable and the actual update may deviate from the original gradient direction |
| Model pruning | Crop parameters that are not important to the final accuracy | The pruned model has some robustness and can achieve better optimization |
FIGURE 1Unstructured pruning diagram.
FIGURE 2Structured pruning diagram.
FIGURE 3Structured pruning flow chart.
FIGURE 4Surface defect data for Severstal plates. (A) Pit defects, (B) Edge crack defects, (C) Scratch and scrape defects, (D) Rolled-in scale defects and (E) Non-defect images.
Experimental environment configuration.
| Project | Configuration |
|---|---|
| Operating system | Windows10 |
| CPU | i7-9700k |
| GPU | RTX2080 Ti |
| RAM | DDR5 16GB |
| Programming language | Python3.7 |
| Deep learning framework | PyTorch1.10 |
Effect of different pruning rates on the ResNet50 model.
| Pruning rate/% | Calculated volume/M | Number of parameters/M | Calculated volume decline rate/% | Rate of decline in number of parameters/% |
|---|---|---|---|---|
| 0 | 335.69 | 25.50 | 0 | 0 |
| 10 | 291.82 | 22.17 | 13.07 | 13.06 |
| 20 | 249.37 | 18.98 | 25.71 | 25.57 |
| 30 | 208.96 | 15.98 | 37.75 | 37.33 |
| 40 | 171.84 | 13.15 | 48.81 | 48.43 |
| 50 | 136.86 | 10.50 | 59.23 | 58.82 |
| 60 | 105.67 | 8.08 | 68.52 | 68.31 |
| 70 | 74.70 | 5.72 | 77.75 | 77.57 |
| 80 | 42.31 | 3.38 | 87.40 | 86.75 |
| 90 | 13.79 | 1.29 | 95.89 | 94.94 |
Effect of different pruning rates on the ResNeXt50 (32 × 4d) model.
| Pruning rate/% | Calculated volume/M | Number of parameters/M | Calculated volume decline rate/% | Rate of decline in number of parameters/% |
|---|---|---|---|---|
| 0 | 347.23 | 24.96 | 0 | 0 |
| 10 | 342.73 | 24.75 | 1.3 | 0.84 |
| 20 | 336.55 | 24.13 | 3.08 | 3.25 |
| 30 | 328.34 | 23.21 | 5.44 | 7.01 |
| 40 | 310.92 | 21.73 | 10.43 | 12.94 |
| 50 | 288.07 | 19.81 | 17.04 | 20.63 |
| 60 | 251.99 | 16.96 | 27.43 | 32.05 |
| 70 | 183.47 | 12.63 | 47.16 | 49.40 |
| 80 | 112.31 | 8.07 | 67.66 | 67.67 |
| 90 | 37.06 | 3.04 | 89.33 | 87.82 |
Effect of different pruning rates on the FPN-ResNeSt50 model.
| Pruning rate/% | Calculated volume/M | Number of parameters/M | Calculated volume decline rate/% | Rate of decline in number of parameters/% |
|---|---|---|---|---|
| 0 | 508.19 | 27.98 | 0 | 0 |
| 10 | 464.23 | 25.94 | 8.65 | 7.28 |
| 20 | 425.51 | 23.25 | 16.27 | 16.91 |
| 30 | 372.55 | 20.01 | 26.69 | 28.49 |
| 40 | 325.04 | 17.56 | 36.04 | 37.23 |
| 50 | 268.02 | 14.34 | 47.26 | 48.74 |
| 60 | 212.93 | 11.31 | 58.10 | 59.59 |
| 70 | 152.86 | 8.18 | 69.92 | 70.78 |
| 80 | 95.13 | 5.24 | 81.28 | 81.29 |
| 90 | 31.46 | 2.14 | 93.81 | 92.36 |
FIGURE 5Plot of test results for different pruning rates.