节点文献

基于卷积神经网络的方格蔟蚕茧细粒度图像分类研究

Research on Square Mount Cocoon Fine-grained Image Classification Based on Convolutional Neural Network

【作者】 王玉明;

【导师】 刘莫尘; 苏良剑;

【作者基本信息】 山东农业大学 , 机械(专业学位), 2022, 硕士

【摘要】 21世纪以来,为了促进蚕桑和丝绸产业的持续发展、提高蚕桑产品的质量和技术竞争力,桑蚕产业需要不断提高机械化和智能化。缫丝过程中,不同品质的蚕茧对产品质量都会产生较大影响,目前国内主要是通过人工方式对蚕茧进行分拣,劳动力成本较高,选茧的准确性易受人员技术水平、精神状态等主观因素影响,存在劳动强度大、误选率高等缺点。本课题将机器视觉和卷积神经网络(Convolutional Neural Network,CNN)应用于蚕茧的识别、分拣中,为蚕茧自动、智能分拣提供了理论依据和技术支撑。本文的主要研究工作如下:(1)采集方格蔟蚕茧原始图像,构建全卷积网络FCN,实现复杂背景下对方格蔟内蚕茧的有效分割,并通过去噪、掩膜等图像处理技术提取蚕茧的图像,从而建立蚕茧数据集。其中对18张无变形的方格蔟分割准确率为100%,对严重变形13张的方格蔟分割准确率>80%,其余准确率均为90%以上。使用旋转、添加噪声、改变亮度、颜色、锐度等方法对数据集进行数据增强,扩充后的样本总数为12913张,其中包含10000张上车茧图片、2913张下茧图片。(2)基于CNN可解释性构建蚕茧分类VGG模型,优化浅层网络结构参数,对模型的浅层卷积层进行基于信息熵的特征纯度计算,特征纯度越高,则模型的特征图信息量越大、网络通道激活越多。结合特征可视化、Grad-CAM热力图可视化,该模型对蚕茧区分特征、纹理、边缘轮廓等细节信息提取得更好。训练测试实验结果为:Conv 1卷积核尺寸为3×3、步长为2,Conv 2卷积核尺寸为3×3、步长为1,Pool 1尺寸为1×1、步长为1的Net-11模型更加适合蚕茧数据集的蚕茧细粒度图像分类,实现对蚕茧的高效识别。(3)对构建的蚕茧分类模型Net-11分别基于L1-norm算法和FPGM算法进行不同剪枝率的网络剪枝,剪枝率分别为:10%、30%、50%、70%、90%,剪枝后模型对蚕茧图像数据集进行训练,与原网络模型进行对比,最终优选出基于FPGM算法、剪枝率为50%的剪枝后的模型,其测试集蚕茧识别的准确率为96.8%、F1值为97.0%,可以满足实际蚕茧识别、分类的精度要求;该剪枝后的模型参数量为36.0 MB,每幅图片的平均帧耗时为38.6 ms,硬件资源占用较少、运行速度快,适合实际应用。(4)基于构建、优化的蚕茧Net-11分类模型,利用直角坐标式方格蔟自动采茧机完成对蚕茧识别、分类的验证试验。由摄像头采集方格蔟蚕茧图像,由FCN全卷积网络分割后发送到控制器进行蚕茧识别、蚕茧定位,控制步进电机和电磁采摘器,完成对下茧的剔除,实现对蚕茧的识别、分类。试验结果为下茧识别准确率较高,平均准确率为88.3%,个别上车茧被错识别为下茧,基本满足实际生产应用,证明构建的蚕茧分类模型适用于蚕茧数据集的细粒度图像分类。

【Abstract】 Since the 21st century,in order to promote the sustainable development of sericulture and silk industry,improve the quality and technical competitiveness of sericulture products,sericulture industry needs to continuously improve mechanization and intelligence.In the process of silk reeling,different quality cocoons will have a great impact on product quality.At present,the cocoons are sorted manually in China,the labor cost is high.The accuracy of cocoon selection is easily affected by subjective factors such as personnel technical level and mental state.There are shortcomings such as high labor intensity and high false selection rate.In this paper,Machine Vision and Convolutional Neural Network(CNN)were used for identification and sorting of cocoons,providing theoretical basis and technical support for automatic and intelligent sorting of cocoons.The main research work of this paper is as follows:(1)The original image of cocoon in square grid is collected,and the FCN full convolution network is constructed to realize the effective segmentation of cocoon in square grid under complex background.The image of cocoon is extracted to establish the cocoon dataset by image processing techniques such as denoising and mask.Among them,the segmentation accuracy of 18 square grids without deformation is 100%,and the segmentation accuracy of 13 square grids with severe deformation is more than 80%,and the remaining is more than 90%.Rotating,adding noise,changing brightness,color,sharpness and other methods are used to enhance the dataset.The total number of expanded samples is 12913,including 10000 cocoon images and 2913 cocoon images.(2)Based on the interpretability of CNN,the VGG model of cocoon classification is constructed,and the parameters of shallow network structure are optimized.The feature purity of the shallow convolution layer of the model is calculated based on information entropy.The higher the feature purity,the greater the information content of the feature map of the model and the activation of the network channel.Combined with feature visualization and Grad-CAM thermal map visualization,this model can extract better details such as cocoon distinguishing feature,texture and edge contour.The training and testing results are as follows:the Net-11 model with Conv1 convolution kernel size of 3×3 and step size of 2,Conv2 convolution kernel size of 3×3 and step size of 1,Pool1 size of 1×1 and step size of 1is more suitable for cocoon fine-grained image classification of cocoon dataset,and the efficient recognition of cocoon is realized.(3)The constructed cocoon classification model Net-11 was pruned based on L1-norm algorithm and FPGM algorithm with different pruning rates,and the pruning rates were 10%,30%,50%,70%and 90%,respectively.The cocoon image dataset was trained by the pruning model.Compared with the original network model,the pruning model based on FPGM algorithm and the pruning rate of 50.0%was finally optimized.The accuracy of cocoon recognition in the test set was 96.8%and the F1-score was 97.0%,which can meet the accuracy requirements of actual cocoon recognition and classification.The number of model parameters after pruning is 36.0 MB,and the average frame time of each image is 38.6 ms.The hardware resources are less occupied and the running speed is fast,which is suitable for deployment in the actual device Jetson Nano.(4)Based on the constructed and optimized cocoon classification Net-11 model,the verification test of cocoon recognition and classification was completed by using the rectangular coordinate grid automatic cocoon picking machine.The cocoon image of grid cocoons was collected by an industrial camera,and it was segmented by the FCN full convolution network and sent to the controller for cocoon recognition and cocoon positioning.The stepping motor and electromagnetic picker were controlled to complete the elimination of the lower cocoons and realize the recognition and classification of cocoons.The experimental results show that the accuracy rate of cocoon recognition is high,and the average accuracy rate is 88.3%.Individual cocoons are wrongly recognized as cocoons,which basically meets the practical production application.It is proved that the constructed cocoon classification model is suitable for fine-grained image classification of cocoon data sets.

  • 【分类号】TP391.41;TP183;TS143.21
节点文献中: 

本文链接的文献网络图示:

本文的引文网络