Research and application of improved YOLOv8 in automatic recognition and annotation of traditional Chinese medicine decoction pieces
Objective Addressing the issues of the diverse types and similar shapes of traditional Chinese medicine decoction pieces (TCMDPs),which could make manual identification time-consuming,labor-intensive,and prone to errors. Methods A dataset containing 201 classes of TCMDPs was constructed,and a lightweight improved YOLOv8 algorithm was proposed. The specific improvements include introducing the GhostC2f module in the YOLOv8n network to reduce model parameters,adopting the DySnakeC2f module to enhance sensitivity to fine structures,replacing the pooling layers of the backbone network with SimSPPF to accelerate inference speed,and incorporating the coordinate attention (CA) mechanism to improve feature extraction for small-sized targets. Results The improved algorithm achieved a cross-threshold mean average precision (50%—95%) of 84.16%,representing an increase of 4.39% compared to the previous version,while reducing the model's parameter count by approximately 15%. The enhanced model was successfully deployed on both computer clients and mobile apps,creating an automated recognition and annotation system for TCMDPs. Conclusion The improved model effectively identifies TCMDPs,while the system supports automatic data expansion and upgrades,providing a novel approach for rapid and accurate identification of TCMDPs.
traditional Chinese medicine decoction piecesYOLOv8deep learningimage recognitionobject detection