In this paper, a lightweight model—OMC-YOLO, improved based on YOLOv8n—is proposed for the automated detection and grading of oyster mushrooms. Aiming at the problems of low efficiency, high costs, and the difficult quality assurance of manual operations in traditional oyster mushroom cultivation, OMC-YOLO was improved based on the YOLOv8n model. Specifically, the model introduces deeply separable convolution (DWConv) into the backbone network, integrates the large separated convolution kernel attention mechanism (LSKA) and Slim-Neck structure into the Neck part, and adopts the DIoU loss function for optimization. The experimental results show that on the oyster mushroom dataset, the OMC-YOLO model had a higher detection effect compared to mainstream target detection models such as Faster R-CNN, SSD, YOLOv3-tiny, YOLOv5n, YOLOv6, YOLOv7-tiny, YOLOv8n, YOLOv9-gelan, YOLOv10n, etc., and that the mAP50 value reached 94.95%, which is an improvement of 2.62%. The number of parameters and the computational amount were also reduced by 26%. The model provides technical support for the automatic detection of oyster mushroom grades, which helps in realizing quality control and reducing labor costs and has positive significance for the construction of smart agriculture.
The maturity of Lentinus edodes directly affects its quality, taste, and market value. Currently, maturity assessment primarily relies on manual experience, making it difficult to ensure efficiency and consistency. To achieve efficient and accurate detection of Lentinus edodes maturity, this study proposes an improved lightweight object detection model, YOLOv8n-CFS. Based on YOLOv8n, the model integrates the SegNeXt Attention structure to enhance key feature extraction capabilities and optimize feature representation. A Feature Diffusion Propagation Network (FDPN) is designed to improve the expressive ability of objects at different scales through cross-layer feature propagation, enabling precise detection. The CSFCN module combines global cue reasoning with fine-grained spatial information to enhance detection robustness and generalization performance in complex environments. The CWD method is adopted to further optimize the model. Experimental results demonstrate that the proposed model achieves 97.34% mAP50 and 84.5% mAP95 on the Lentinus edodes maturity detection task, representing improvements of 2.02% and 4.92% compared to the baseline method, respectively. It exhibits excellent stability in five-fold cross-validation and outperforms models such as Faster R-CNN, YOLOv5n, YOLOv7-tiny, YOLOv8n, YOLOv8s, YOLOv10n, YOLOv11n, and YOLOv12. This study provides efficient and reliable technical support for Lentinus edodes maturity detection and holds significant implications for the intelligent production of edible fungi.
In traditional time-series image prediction tasks, both accuracy and image quality tend to deteriorate as the prediction horizon extends. To address this challenge in Shiitake mushroom fruiting body growth prediction, this study selected Shiitake mushroom strain No. 509, cultivated by the Shanghai Academy of Agricultural Sciences, as the experimental subject and proposed an enhanced model, VMRNN-DMSA, based on the Vision Mamba RNN Depth architecture. This model integrates a skip-connection mechanism with a Max Feature Map module to effectively filter and fuse features, enhancing feature representation and prediction accuracy. Additionally, a Spatial Attention Mechanism was introduced to strengthen the perception of key regions and improve spatial modeling. Furthermore, an Adaptive Kernel Convolution module with irregular context convolution kernels was incorporated to extract fine-grained local features and enhance visual quality. A weighted loss function was used to balance pixel-level accuracy, structural fidelity, and perceptual quality. This function combines Mean Squared Error Loss, Multi-Scale Structural Similarity, and Perceptual Loss. Experimental results showed that the proposed method achieved an MSE of 39.4255, an SSIM of 0.8579, and a PSNR of 22.0774. Compared with baseline models, MSE decreased by 29.05%, while SSIM and PSNR increased by 19.34% and 14.52%, respectively. These results indicate that VMRNN-DMSA significantly improves both prediction accuracy and image quality in long-term forecasting tasks, providing a reliable reference for the growth prediction of other edible fungi.