Pleurotus geesteranus growth identification and prediction method, device and equipment based on image segmentation, medium and product
Through the improved YOLOv8-seg model and TFT-LSTM hybrid model, the inefficiency and instability problems of Pleurotus geesteranus growth status identification were solved, high-precision growth trend prediction and anomaly detection were achieved, and the ability of intelligent planting management was improved.
Patent Information
- Application Number
- CN202510994252.9
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2025-07-18
- Publication Date
- 2025-10-17
AI Technical Summary
The existing technology for identifying the growth status of Pleurotus geesteranus has the problems of low recognition efficiency, strong subjectivity, and poor robustness. It is difficult to cope with lighting changes and background interference in complex environments, and lacks refined extraction and quantitative analysis, making it difficult to meet the needs of intelligent planting management.
An improved YOLOv8-seg model was used for image segmentation, combined with a TFT-LSTM hybrid model for growth trend prediction. Deep learning technology was used to extract the growth stage and status information of Pleurotus geesteranus, and multimodal data was combined for monitoring and feedback.
It improves the accuracy and stability of Pleurotus geesteranus growth identification and prediction, enables precise prediction of growth trends and early detection of abnormal situations, and supports intelligent planting management.
Smart Images

Figure CN120807932A_ABST
Abstract
Description
TECHNICAL FIELD
[0001] The present application relates to the field of image analysis processing, and in particular to a method and device for identifying and predicting the growth of Hypsizygus marmoreus based on image segmentation, equipment, medium and product. BACKGROUND
[0002] At present, the identification of the growth state of Hypsizygus marmoreus mainly relies on manual experience or traditional image processing-based classification methods, which have the problems of low recognition efficiency, strong subjectivity, poor robustness, etc., and are difficult to cope with changes in light, background interference and various growth forms in complex environments. At the same time, the existing methods mainly focus on rough judgment at stages, lack of fine extraction and quantitative analysis of the growth state of the mushroom body, and are difficult to meet the actual needs of intelligent planting management. SUMMARY
[0003] The purpose of the present application is to provide a method and device for identifying and predicting the growth of Hypsizygus marmoreus based on image segmentation, which can improve the accuracy and stability of the identification and prediction of the growth of Hypsizygus marmoreus.
[0004] To achieve the above-mentioned purpose, the present application provides the following solutions:
[0005] In a first aspect, the present application provides a method for identifying and predicting the growth of Hypsizygus marmoreus based on image segmentation, comprising:
[0006] obtaining image data during the growth of Hypsizygus marmoreus;
[0007] using an improved YOLOv8-seg model to determine the identification result of the growth stage of Hypsizygus marmoreus and the growth state information of Hypsizygus marmoreus according to the image data; the improved YOLOv8-seg model includes a YOLOv8 backbone network; the YOLOv8 backbone network includes a mixed backbone network module, a feature fusion module, a detection head optimization module and a segmentation head optimization module connected in sequence through a data stream;
[0008] using a standard growth model to perform growth prediction based on the growth state information, and using a TFT-LSTM hybrid model to perform growth trend prediction to obtain predicted growth trend information; the standard growth model is determined based on historical growth state information using statistical analysis methods and a DBSCAN clustering algorithm; the TFT-LSTM hybrid model is based on a time fusion transformer and a long short-term memory network, and is trained based on historical growth information using an attention mechanism.
[0009] Optionally, the method for identifying and predicting the growth of Hypsizygus marmoreus based on image segmentation further comprises:
[0010] Based on the predicted growth trend information, the growth process of the Pleurotus geesterus is monitored, and feedback is performed according to the monitoring result to obtain early warning information.
[0011] Optionally, an improved YOLOv8-seg model is used to determine the recognition result of the growth stage of the Pleurotus geesterus and the growth state information of the Pleurotus geesterus according to the image data, specifically including:
[0012] The YOLOv8 backbone network is used for image segmentation on the image data to obtain a segmented image;
[0013] Based on the multi-modal data, the YOLOv8 algorithm is used for target detection on the Pleurotus geesterus target region image in the segmented image to obtain the recognition result of the growth stage of the Pleurotus geesterus;
[0014] Based on the recognition result, the YOLOv8-seg algorithm is used to determine the growth state information of the Pleurotus geesterus.
[0015] Optionally, based on the recognition result, the YOLOv8-seg algorithm is used to determine the growth state information of the Pleurotus geesterus, specifically including:
[0016] The YOLOv8-seg algorithm is used to extract the contour information of the Pleurotus geesterus in the Pleurotus geesterus target region image to obtain mask information;
[0017] According to the mask information, the pixel statistical method is used to determine the size information of the Pleurotus geesterus;
[0018] The growth state information is determined according to the recognition result and the size information.
[0019] Optionally, the determination method of the TFT-LSTM hybrid model specifically includes:
[0020] The time series data set is constructed according to the historical growth information;
[0021] The time series data set is smoothed by using the moving average method to obtain a processed time series data set;
[0022] The processed time series data set is input into the long short-term memory network for calculation and processing to output a hidden state sequence;
[0023] The time fusion transformer is used to integrate the features of the hidden state sequence and screen the covariates through the attention mechanism to train the attention weight of the long short-term memory network to obtain a trained long short-term memory network;
[0024] The trained long short-term memory network and the time fusion transformer are combined to obtain the TFT-LSTM hybrid model.
[0025] Optionally, after the image data in the growth process of the Pleurotus geesterum is acquired, the method further includes:
[0026] The image data is subjected to color space conversion, histogram equalization processing, normalization and data enhancement processing; the data enhancement processing includes rotation, flipping and random cropping.
[0027] In a second aspect, the present application provides a Pleurotus geesterum growth identification and prediction device based on image segmentation, comprising:
[0028] An image data acquisition module is configured to acquire image data in the growth process of the Pleurotus geesterum.
[0029] An identification and detection module is configured to determine an identification result of a growth stage of the Pleurotus geesterum and growth state information of the Pleurotus geesterum according to the image data by using an improved YOLOv8-seg model; the improved YOLOv8-seg model comprises a YOLOv8 backbone network; the YOLOv8 backbone network comprises a mixed backbone network module, a feature fusion module, a detection head optimization module and a segmentation head optimization module connected in sequence through a data stream.
[0030] A growth trend prediction module is configured to perform growth prediction according to the growth state information by using a standard growth model, and perform growth trend prediction based on a TFT-LSTM hybrid model to obtain predicted growth trend information; the standard growth model is determined based on historical growth state information by using a statistical analysis method and a DBSCAN clustering algorithm; the TFT-LSTM hybrid model is obtained by training historical growth information based on a time fusion transformer and a long short-term memory network using an attention mechanism.
[0031] In a third aspect, the present application provides a computer device, comprising a memory, a processor and a computer program stored in the memory and executable on the processor, wherein the processor executes the computer program to implement the Pleurotus geesterum growth identification and prediction method based on image segmentation.
[0032] In a fourth aspect, the present application provides a computer readable storage medium having a computer program stored thereon, wherein the computer program is executed by a processor to implement the Pleurotus geesterum growth identification and prediction method based on image segmentation.
[0033] In a fifth aspect, the present application provides a computer program product comprising a computer program, wherein the computer program is executed by a processor to implement the Pleurotus geesterum growth identification and prediction method based on image segmentation.
[0034] According to the embodiments of the present application, the following technical effects are disclosed:
[0035] The present application provides a method, apparatus, device, medium, and product for identifying and predicting the growth of Pleurotus geesteranus based on image segmentation. The method obtains image data of the Pleurotus geesteranus during its growth process; uses an improved YOLOv8-seg model to determine the identification results of the growth stage of Pleurotus geesteranus and the growth status information of the Pleurotus geesteranus based on the image data; uses a standard growth model to predict growth based on the growth status information, and uses a TFT-LSTM hybrid model to predict growth trends; the standard growth model is determined based on historical growth status information using statistical analysis methods and the DBSCAN clustering algorithm; and the present application improves the accuracy of Pleurotus geesteranus growth identification and prediction by using the improved YOLOv8-seg model and the standard growth model. Furthermore, the TFT-LSTM hybrid model used in the present application is based on a time-fusion transformer and a long short-term memory network, and is trained using an attention mechanism based on historical growth information. By combining the time-fusion transformer and the long short-term memory network, the model can capture long-term dependencies and improve the stability of Pleurotus geesteranus growth identification and prediction. BRIEF DESCRIPTION OF THE DRAWINGS
[0036] In order to more clearly illustrate the embodiments of the present application or the technical solutions in the prior art, the following briefly introduces the drawings required for use in the embodiments. Obviously, the drawings described below are only some embodiments of the present application. For ordinary technicians in this field, other drawings can be obtained based on these drawings without creative work.
[0037] Figure 1 This is a flowchart of the method for identifying and predicting the growth of Pleurotus geesteranus based on image segmentation;
[0038] Figure 2 To improve the YOLOv8-seg network structure diagram;
[0039] Figure 3 It is a visualization diagram of the segmentation effect at each growth stage; Figure 3 (a) is the segmentation effect diagram at the mature stage; Figure 3 (b) is the effect diagram of coral stage segmentation; Figure 3 (c) is the segmentation effect diagram during the primordium formation period; Figure 3 (d) is the segmentation effect diagram during the hyphae stage;
[0040] Figure 4 A flow chart for identifying the growth status of Pleurotus geesteranus;
[0041] Figure 5 This is a structural diagram of a device for identifying and predicting the growth of Pleurotus geesteranus based on image segmentation;
[0042] Figure 6 A schematic diagram of the structure of a computer device provided in one embodiment of the present application. DETAILED DESCRIPTION
[0043] The technical solutions in the embodiments of the present application will be described clearly and completely below with reference to the drawings in the embodiments of the present application. Obviously, the described embodiments are only part of the embodiments of the present application, rather than all the embodiments. Based on the embodiments in the present application, all other embodiments obtained by those skilled in the art without creative work belong to the scope of protection of the present application.
[0044] The present application realizes accurate extraction of the fruiting body region by introducing the instance segmentation technology of deep learning, and combines the growth characteristics to distinguish the stage and evaluate the state, which not only improves the recognition accuracy and stability, but also has good practicability and deployability, and provides reliable support for intelligent cultivation and early disease warning of Pleurotus geesteri.
[0045] The above purposes, features and advantages of the present application can be more obvious and easy to understand. The present application will be described in further detail below with reference to the drawings and specific embodiments.
[0046] In an exemplary embodiment, as shown in Figure 1 An image segmentation-based Pleurotus geesteri growth recognition and prediction method is provided, comprising:
[0047] Step 100: acquiring image data in the growth process of Pleurotus geesteri.
[0048] Step 200: using an improved YOLOv8-seg model to determine the recognition result of the growth stage of Pleurotus geesteri and the growth state information of Pleurotus geesteri according to the image data. The improved YOLOv8-seg model includes a YOLOv8 backbone network; the YOLOv8 backbone network includes a mixed backbone network module, a feature fusion module, a detection head optimization module and a segmentation head optimization module connected in sequence through a data stream.
[0049] Step 300: using a standard growth model to perform growth prediction according to the growth state information, and using a TFT-LSTM hybrid model to perform growth trend prediction based on the TFT-LSTM hybrid model to obtain predicted growth trend information. The standard growth model is determined based on historical growth state information using statistical analysis method and DBSCAN clustering algorithm; the TFT-LSTM hybrid model is based on time fusion transformer and long short-term memory network, and is trained according to historical growth information using attention mechanism.
[0050] In an embodiment, the image segmentation-based Pleurotus geesteri growth recognition and prediction method further comprises:
[0051] Based on the predicted growth trend information, the growth process of Pleurotus geesteri is monitored, and feedback is performed according to the monitoring result to obtain early warning information.
[0052] In an embodiment, a modified YOLOv8-seg model is adopted to determine the recognition result of the growth stage of the H. capsulota and the growth state information of the H. capsulota according to the image data, specifically including:
[0053] The image data is subjected to image segmentation by using the YOLOv8 backbone network to obtain a segmented image.
[0054] Based on the multi-modal data, the target region image of the H. capsulota in the segmented image is subjected to target detection by using the YOLOv8 algorithm to obtain the recognition result of the growth stage of the H. capsulota.
[0055] Based on the recognition result, the growth state information of the H. capsulota is determined by using the YOLOv8-seg algorithm.
[0056] In an embodiment, based on the recognition result, the growth state information of the H. capsulota is determined by using the YOLOv8-seg algorithm, specifically including:
[0057] The contour information of the H. capsulota in the target region image of the H. capsulota is extracted by using the YOLOv8-seg algorithm to obtain mask information; the size information of the H. capsulota is determined by using a pixel statistical method according to the mask information; and the growth state information is determined according to the recognition result and the size information.
[0058] The determination method of the TFT-LSTM hybrid model specifically includes:
[0059] A time series dataset is constructed according to historical growth information; the time series dataset is subjected to smoothing processing by using a moving average method to obtain a processed time series dataset; the processed time series dataset is input into a long short-term memory network for calculation and processing to output a hidden state sequence; a time fusion transformer is adopted to integrate features and screen covariates of the hidden state sequence through an attention mechanism to train the attention weight of the long short-term memory network to obtain a trained long short-term memory network; and the trained long short-term memory network and the time fusion transformer are combined to obtain the TFT-LSTM hybrid model.
[0060] As an optional implementation, after the image data in the growth process of the H. capsulota is acquired, the method further includes:
[0061] The image data is subjected to color space conversion, histogram equalization processing, normalization and data enhancement processing; the data enhancement processing includes rotation, flipping and random cropping.
[0062] In actual application, the specific operation steps of the method mentioned in the application are as follows:
[0063] S1: Set up a track-type intelligent image acquisition platform, and collect image data of the growth process of Pleurotus geesteri through the image acquisition platform.
[0064] S2: Based on the image segmentation algorithm, the YOLOv8 backbone network is used to perform instance segmentation on the collected growth environment image (image data during the growth process) of Pleurotus geesteri, to segment the target area and background area of Pleurotus geesteri.
[0065] S3: Extract and optimize the morphological characteristics of Pleurotus geesteri, and conduct comprehensive analysis combined with multi-modal data (such as temperature and humidity, CO2 concentration, etc.) to improve the recognition accuracy.
[0066] S4: According to the mask size of each growth stage obtained by image segmentation, it is judged whether the growth state of Pleurotus geesteri at this stage is good.
[0067] S5: Combined with historical data, the growth trend is predicted, and the abnormal situation in the growth process of Pleurotus geesteri is monitored, and a warning is made according to the feedback of the growth state of Pleurotus geesteri.
[0068] The data acquisition module adopts a track-type intelligent image acquisition platform, which uses a high-definition camera to collect image data of Pleurotus geesteri in the growth process at fixed points and fixed times. The collected image data is uploaded to the cloud platform, and the platform is fully automated to efficiently collect images at each growth stage. This platform can be applied to the continuous collection of picture data in a compartment-type mushroom house, and combined with the established model to monitor the growth state of Pleurotus geesteri.
[0069] S1.1 The track-type intelligent image acquisition platform is designed to move on the guide rail, and is equipped with a rotatable high-definition camera and an environmental sensor. Remote information acquisition is realized by wireless communication, in order to solve the problems of high labor intensity, small amount of collected data, and high demand for mushroom house supporting facilities in the collection method.
[0070] S1.2 The track provides a fixed path for the collection platform. The length and width of the mushroom house are 8m and 9m respectively, and the height of the mushroom house is 5m. Considering the shooting quality and the arrangement of mushrooms in the mushroom house, the height of the truss is set to 5m. In order to cover each cluster of Pleurotus geesteri for shooting, the length of the truss is 7m, the lifting height is 1.5m, and the camera can rotate up, down, left and right by 15°, which meets the requirements of multi-angle data collection. The collection platform is hung on the guide rail through the guide rail wheel, and the movement on the track and the collection of the information in the mushroom house are realized through wireless remote control.
[0071] According to the growth characteristics and stage division principles of Pleurotus geesteri, its growth state can be divided into mycelium growth period, primordium formation period, coral-like period and mature picking period, so as to realize accurate stage recognition and growth state evaluation.
[0072] The growth state recognition flowchart of Pleurotus geesterum is shown in Figure 4 This application mainly includes two core parts: growth stage detection based on target detection and growth state recognition based on instance segmentation.
[0073] Among them, the growth stage detection uses YOLOv8 algorithm for target detection to identify different stages such as mycelium growth period, primordium formation period, coral period, and mature period.
[0074] The growth state recognition uses YOLOv8-seg algorithm for instance segmentation to extract the contour information of Pleurotus geesterum, and calculate the mask area, aspect ratio and other feature parameters for evaluating the growth situation. At the same time, this method combines time series analysis to monitor the growth trend and detect abnormal growth conditions such as slow growth, deformity or disease, etc.
[0075] S2.1 In terms of data processing, data preprocessing and data enhancement are performed. Data preprocessing includes color space conversion (RGB, HSV, etc.), histogram equalization (improve image contrast), normalization (reduce light influence), etc. Data enhancement uses general methods such as rotation, flipping, random cropping, etc., and combines YOLOv8-specific Mosaic, CutMix and MixUp techniques to improve the robustness and adaptability of the model.
[0076] S2.2 In terms of network architecture optimization, a new segmentation model is introduced to optimize the backbone network of YOLOv8. As shown in Figure 2 The overall structure of the deep learning instance segmentation network is shown. The network mainly includes four functional modules, namely hybrid backbone network, feature fusion, detection head optimization and segmentation head optimization, which are connected in sequence through data flow to form a complete image recognition and mask generation process. The hybrid backbone network uses SwinTransformer to enhance the global feature modeling capability with window attention mechanism, improve the segmentation accuracy, and then uses EfficientNet to improve the calculation efficiency and model lightweight capability through compound scaling method. Enhance the feature extraction capability of the network, improve the accuracy of Pleurotus geesterum instance segmentation, and reduce the consumption of computing resources. The Neck module combines FPN and PAN structure to realize multi-level fusion of high-level semantic information and low-level details, and improve the recognition ability of the model under different target scales. The detection head is used to output the class information and bounding box coordinates of each detection target. In the post-processing stage of detection head optimization, Soft-NMS is used instead of traditional NMS to reduce the missed detection problem and improve the detection accuracy of overlapping targets. The segmentation head includes mask prototype generator and mask coefficient predictor, the former generates a fixed number of shared mask prototypes, and the latter generates corresponding mask coefficients for each target, and finally generates instance-level mask through linear combination.
[0077] S2.3 In terms of model optimization, the embedded attention mechanism is mainly used to improve the key feature extraction capability. The CBAM (Convolutional Block Attention Module) module is used to enhance the attention to the edge and morphological details of the Hypsizigus marmoreus in the backbone network or feature fusion layer. The SE (Squeeze-and-Excitation) module is introduced to dynamically adjust the weight of the feature channel, further improving the feature extraction capability. In addition, the activation function is improved, the default SiLU (Swish) activation function of YOLOv8 is replaced with GELU to improve the stability of gradient propagation and non-linear expression ability, thereby improving the detection and segmentation accuracy. The CIoU (Complete IoU) loss function is used to improve the accuracy of the bounding box regression. At the same time, the FocalLoss is introduced to solve the class imbalance problem and improve the model's detection ability for difficult samples. During the training process, the CosineAnnealing learning rate scheduler is used to dynamically adjust the learning rate to avoid the model falling into local optimum. At the same time, the Warmup strategy is used to gradually increase the learning rate at the beginning of training to improve the training stability. In terms of multi-modal data fusion, early fusion or late fusion strategies are used to combine image data with environmental sensor data such as temperature, humidity, and CO2 concentration to improve the model's comprehensive judgment ability for Hypsizigus marmoreus growth status.
[0078] In terms of morphological feature measurement and optimization, statistical analysis methods are used. First, the instance segmentation model is used to process the Hypsizigus marmoreus image to obtain the bounding box, pixel-level region, and growth stage classification results of each mushroom body. On this basis, the system automatically extracts key morphological parameters including area, circularity, and aspect ratio. Based on a large number of sample data for each growth stage, the mean and variance of the morphological features of each growth stage are calculated, and the average value and variance are calculated to establish a standard growth model. When the morphological indicators of a single Hypsizigus marmoreus (such as circularity) deviate significantly from the mean value of the characteristics of its own stage (below the set threshold), it can be automatically marked as growth abnormality or damage. At the same time, the DBSCAN clustering algorithm is introduced for unsupervised clustering analysis of the morphological features of all Hypsizigus marmoreus instances, which can mine the implicit morphological boundaries between growth stages without relying on labels, thereby improving the model's ability to distinguish between different growth stages.
[0079] First, the deep learning instance segmentation model is used to process the image to obtain the pixel-level mask area (mask) corresponding to each Hypsizigus marmoreus instance in different growth stages, such as Figure 3 The visualization of the segmentation results for each growth stage. Among them, Figure 3 (a) is the segmentation result of the mature stage; Figure 3 (b) is the segmentation result of the coral stage; Figure 3 (c) is the segmentation result of the primordium formation stage; Figure 3(d) is a segmented image of the mycelium stage.
[0080] The masks are classified according to the predicted growth stage in combination with the classification label output by the model. Each set of masks represents the spatial area of the H. capsulota during the growth stage. By extracting the mask area from the original image, the automatic separation and visualization of the mushroom area at each stage can be achieved, which can be used for morphological analysis and state evaluation.
[0081] S4.1 In the calculation of mask size, a pixel counting method is used, that is, the number of foreground pixels (white area) in the binary mask is directly calculated to estimate the physical size of H. capsulota. If the shooting distance and camera parameters are fixed, the spatial calibration (Spatial Calibration) is used to convert the pixel area to the actual physical area (such as square millimeters) to improve the accuracy of the evaluation.
[0082] S4.2 In order to determine whether the growth state is good, a standard model of the growth stage is established. Through large-scale sample data analysis, the mean and standard deviation of the mask size at each stage are calculated, and a reasonable growth threshold is set. In a certain stage, if the mask area is much lower than the normal range, it may mean that the growth is blocked; if the mask area is too large, it may represent excessive growth or abnormal expansion.
[0083] S4.3 In addition to the size of the area, morphological feature analysis is used to further determine the growth state. The aspect ratio (AspectRatio) is calculated to detect whether there is abnormal growth, or the circularity (Circularity) is used to measure the integrity of the cap. Further, time series analysis is used to track the trend of mask size to determine whether the growth is stable.
[0084] S4.4 In the aspect of anomaly detection, a growth health evaluation model (RegressionModel) is trained. In the aspect of time series modeling, Temporal Fusion Transformer (TFT) is used as the core model, combined with LSTM to capture long-term trends. The input is the mask area and morphological features of the time series, and the output is the growth trend curve at multiple future time points. By comparing the predicted value with the threshold range, the system can automatically identify abnormal growth trends and issue warnings. This can improve the accuracy of growth trend prediction.
[0085] In the growth trend prediction based on historical data, a time series dataset is constructed to record the changes in mask size at different growth stages of H. truffidea. The mask size (area) extracted by image segmentation technology can reflect the growth rate of H. truffidea, while the morphological features (such as aspect ratio, roundness, etc.) can further supplement the growth state information. These data are recorded at fixed time intervals (such as every 6 hours) and normalized to ensure data consistency and comparability.
[0086] S5.1: To predict the growth trend of H. truffidea, a time series modeling method is used, which combines TFT and LSTM modeling. The input is the feature data (mask area, temperature and humidity, etc.) of the past T time steps, with a shape of (T, D), where D is the feature dimension. The historical time series data (mask area of the past 3 days) are input into LSTM, and the unit calculation formula of LSTM is:
[0087]
[0088] where f t ,i t ,o t are the gating signals, W f ,W i ,W o are weight matrices, W C is the weight matrix of the current time state unit, x t is the current input, b f ,b i ,b o ,b C are bias values, σ is the sigmoid function, is the current time unit state, C t is the unit state, C t-1 is the previous time unit state, h t-1 is the previous time output state, h t is the hidden state. The output hidden state sequence H = [h2, h2,..., h T ].
[0089] TFT integrates the output of LSTM, static features and environmental covariates, and models long-term dependencies through attention mechanism. By using an interpretable variable selection mechanism, the importance of LSTM output H and covariates is screened, and the mask features are screened. Through the multi-head attention mechanism, long-term dependencies are captured, and the attention weight calculation formula is:
[0090]
[0091] where Q, V, K are query, key, and value matrices (from LSTM output H), dk For dimensions. Re-process fixed features, output prediction values for future T' steps through full connection layer.
[0092] Reduce short-term fluctuations by using a sliding average (SMA), whose formula is:
[0093]
[0094] where w is the window size, x i is the original feature value collected at time i. Based on historical data, calculate the mean and standard deviation of the mask area at each growth stage, set a dynamic threshold (±3σ), if the current mask area x t satisfies |x t -μ t |>3σ t , where μ t is the mean at time t, and σ t is the standard deviation at time t, then it is determined to be abnormal.
[0095] TFT and LSTM can capture long-term trends, suitable for tasks with time dependence such as shiitake mushroom growth. By inputting mask size data from the past few days, TFT and LSTM can predict growth within the next 24-48 hours and assess whether there are abnormalities. In addition, moving average (Moving Average) is used to smooth the data to reduce the impact of short-term fluctuations, making the prediction results more stable.
[0096] S5.2: In the process of growth prediction, real-time monitoring of abnormal situations. A reasonable mask area range can be set for different growth stages, and when the growth data exceeds this range, the system can determine that there is an abnormality. If the mask area grows too slowly, it may be due to unsuitable temperature and humidity or insufficient nutrient supply; if the mask area is too large, it may be due to excessive growth, over-expansion, or even the risk of disease. In addition, abnormalities in morphological features (such as distorted caps and thin stems) may also indicate problems with the growth environment.
[0097] S5.3: In the monitoring of shiitake mushroom growth, morphological features such as mask area, aspect ratio, and circularity of shiitake mushrooms extracted by image segmentation technology (YOLOv8-seg) are recorded at fixed time intervals (every 6 hours) to form a time series dataset. Normalize the mask area and other features (Z-score) to eliminate the influence of dimensions. Z-score formula:
[0098]
[0099] Among them, μ is the historical mean and σ is the standard deviation. Anomaly detection is achieved by combining Z-score standardization and DBSCAN clustering. First, the growth data is standardized by the Z-score method to eliminate the dimension effect, making the values of different features comparable. Then, an anomaly threshold (|z|>3) is set to determine an anomaly. The standardized feature matrix Z=[z1,z2,...,z n ](Each row contains features such as mask area and aspect ratio) The DBSCAN clustering algorithm is used to assist in anomaly detection, discover hidden anomalies not covered by the Z-score, classify historical data, and identify which data points deviate too much from the normal growth pattern, thereby discovering abnormal growth.
[0100] S5.4: Warning information can be sent to management personnel via intelligent control systems, push notifications, or SMS notifications, enabling real-time monitoring and control of the growth process of Pleurotus geesteranus. Combining historical data analysis, time series modeling, anomaly detection, and intelligent warnings can effectively improve Pleurotus geesteranus growth management and provide technical support for the automation and precision of smart mushroom houses.
[0101] This application uses a track-mounted inspection robot equipped with a high-definition camera and environmental sensors to automatically collect mushroom house data. An improved YOLOv8-seg model integrates the Swin Transformer global attention mechanism and the CBAM local enhancement module to perform instance segmentation and growth stage classification. Based on the segmentation results, morphological features such as mask area and roundness are extracted, and anomaly detection is performed using Z-score normalization and DBSCAN clustering. A TFT-LSTM hybrid model is combined to predict growth trends. Finally, a multi-level early warning mechanism is used to link the environmental control system. Through the closed-loop technology of "image acquisition-feature extraction-state assessment-intelligent decision-making," this system improves the accuracy of identifying the growth status of Pleurotus geesteranus, providing a highly efficient solution for smart agriculture.
[0102] This application uses deep learning technology to automatically identify different growth stages and combines it with instance segmentation methods to assess growth status. The system collects data through a rail-mounted inspection robot, uses YOLOv8 for target detection and segmentation, and combines EfficientNet or Swin Transformer to optimize the backbone network to improve recognition accuracy. At the same time, it can assess growth trends based on the size of the instance segmentation mask, detect abnormal growth, and provide intelligent warnings. This application improves the level of intelligent management of edible fungus cultivation and is suitable for modern agricultural production.
[0103] The present application realizes intelligent monitoring and accurate early warning of the whole cycle of the growth state of Pleurotus by fusing deep learning, instance segmentation and multi-modal data analysis technology. Specifically, the system uses an improved YOLOv8-seg instance segmentation model combined with a SwinTransformer optimized network to realize pixel-level mushroom segmentation and growth stage recognition; by integrating environmental sensor data and a time series prediction model (TFT+LSTM), the growth trend can be predicted 24-48 hours in advance and abnormal conditions can be detected; the innovative combination of Z-score and DBSCAN clustering algorithm realizes accurate determination of growth abnormalities.
[0104] In an exemplary embodiment, as shown in Figure 5 An image segmentation-based Pleurotus growth recognition and prediction device is provided, comprising:
[0105] An image data acquisition module for acquiring image data during the growth of Pleurotus.
[0106] An identification and detection module for using an improved YOLOv8-seg model to determine the recognition result of the growth stage of Pleurotus and the growth state information of Pleurotus according to the image data; the improved YOLOv8-seg model includes a YOLOv8 backbone network; the YOLOv8 backbone network includes a hybrid backbone network module, a feature fusion module, a detection head optimization module and a segmentation head optimization module connected in turn through data flow.
[0107] A growth trend prediction module for using a standard growth model to perform growth prediction based on the growth state information, and using a TFT-LSTM hybrid model to perform growth trend prediction to obtain predicted growth trend information; the standard growth model is determined based on historical growth state information using statistical analysis methods and DBSCAN clustering algorithm; the TFT-LSTM hybrid model is based on a time fusion transformer and a long short-term memory network, and is trained based on historical growth information using an attention mechanism.
[0108] In an exemplary embodiment, a computer device, which can be a server or a terminal, is provided, and its internal structure diagram can be as shown in Figure 6As shown in the figure. The computer device includes a processor, a memory, an input / output interface (Input / Output, referred to as I / O) and a communication interface. Among them, the processor, the memory and the input / output interface are connected through the system bus, and the communication interface is connected to the system bus through the input / output interface. Among them, the processor of the computer device is used to provide computing and control capability. The memory of the computer device includes a non-volatile storage medium and an internal memory. The non-volatile storage medium stores an operating system, a computer program and a database. The internal memory provides an environment for the operation of the operating system and the computer program in the non-volatile storage medium. The input / output interface of the computer device is used to exchange information between the processor and the external device. The communication interface of the computer device is used to communicate with the terminal outside through the network connection. The computer program is executed by the processor to realize the image segmentation-based identification and prediction method for the growth of Auricularia delicosa.
[0109] Those skilled in the art can understand that, Figure 6 The structure shown in the figure is only a block diagram of part of the structure related to the scheme of the present application, and does not constitute a limitation on the computer device to which the scheme of the present application is applied. The specific computer device can include more or fewer components than those shown in the figure, or combine certain components, or have a different component arrangement.
[0110] In one exemplary embodiment, a computer device is also provided, including a memory and a processor, the memory storing a computer program, and the processor executing the computer program to implement the steps in each of the above method embodiments.
[0111] In one exemplary embodiment, a computer readable storage medium is provided, storing a computer program, which is executed by a processor to implement the steps in each of the above method embodiments.
[0112] In one exemplary embodiment, a computer program product is provided, including a computer program, which is executed by a processor to implement the steps in each of the above method embodiments.
[0113] It should be noted that the user information (including but not limited to user device information, user personal information, etc.) and data (including but not limited to data for analysis, stored data, displayed data, etc.) involved in the present application are all information and data authorized by the user or authorized by all parties, and the collection, use and processing of related data need to comply with relevant regulations.
[0114] Those skilled in the art can understand that all or part of the processes in the above-mentioned embodiment methods can be completed by instructing the relevant hardware through a computer program. The computer program can be stored in a non-volatile computer readable storage medium, and when executed, can include the processes of the above-mentioned embodiment methods. Any reference to memory, database or other medium used in the embodiments provided in the present application can include at least one of non-volatile and volatile memory. Non-volatile memory can include read-only memory (ROM), magnetic tape, floppy disk, flash memory, optical storage, high-density embedded non-volatile memory, resistive random access memory (ReRAM), magnetoresistive random access memory (MRAM), ferroelectric random access memory (FRAM), phase change memory (PCM), graphene memory, etc. Volatile memory can include random access memory (RAM) or external cache memory, etc. As an illustration but not limitation, RAM can be in various forms, such as static random access memory (SRAM) or dynamic random access memory (DRAM), etc.
[0115] The database involved in the embodiments provided in the present application can include at least one of a relational database and a non-relational database. The non-relational database can include a distributed database based on a blockchain, etc., without being limited thereto. The processor involved in the embodiments provided in the present application can be a general-purpose processor, a central processing unit, a graphics processing unit, a digital signal processor, a programmable logic device, a data processing logic device based on quantum computing, etc., without being limited thereto.
[0116] The technical features of the above embodiments can be combined arbitrarily. In order to make the description simple, all possible combinations of the technical features in the above embodiments are not described, however, as long as the combinations of the technical features do not exist contradictory, they should be considered as the scope of the present application.
[0117] The principles and implementation manners of the present application are described herein by using specific examples, and the above examples are only used to help understand the method of the present application and its core idea; meanwhile, for those skilled in the art, according to the idea of the present application, the specific implementation manners and application ranges will have changes. In conclusion, the content of the specification should not be understood as a limitation of the present application.
Claims
1. A method for identifying and predicting the growth of Pleurotus geesteranus based on image segmentation, characterized in that: include: Acquire image data during the growth process of Pleurotus geesteranus; An improved YOLOv8-seg model is used to determine an identification result of the growth stage of Pleurotus geesteranus and growth status information of Pleurotus geesteranus based on the image data; the improved YOLOv8-seg model includes a YOLOv8 backbone network; the YOLOv8 backbone network includes a hybrid backbone network module, a feature fusion module, a detection head optimization module, and a segmentation head optimization module sequentially connected through a data stream; A standard growth model is used to perform growth prediction based on the growth status information, and a growth trend prediction is performed based on a TFT-LSTM hybrid model to obtain predicted growth trend information; the standard growth model is based on historical growth status information and is determined using a statistical analysis method and a DBSCAN clustering algorithm; the TFT-LSTM hybrid model is based on a time fusion transformer and a long short-term memory network and is trained using an attention mechanism based on historical growth information.
2. The method for identifying and predicting the growth of Pleurotus geesteranus based on image segmentation according to claim 1, wherein: The method for identifying and predicting the growth of Pleurotus geesteranus based on image segmentation further includes: Based on the predicted growth trend information, the growth process of Pleurotus geesteranus is monitored, and feedback is provided according to the monitoring results to obtain early warning information.
3. The method for identifying and predicting the growth of Pleurotus geesteranus based on image segmentation according to claim 1, wherein: The improved YOLOv8-seg model is used to determine the recognition result of the growth stage of Pleurotus geesteranus and the growth status information of Pleurotus geesteranus based on the image data, specifically including: Perform image segmentation on the image data using a YOLOv8 backbone network to obtain a segmented image; Based on multimodal data, the YOLOv8 algorithm is used to detect the target area of Pleurotus geesteranus in the segmented image, and the recognition results of the growth stage of Pleurotus geesteranus are obtained. Based on the recognition results, the YOLOv8-seg algorithm is used to determine the growth status information of Pleurotus geesteranus.
4. The method for identifying and predicting the growth of Pleurotus geesteranus based on image segmentation according to claim 3, wherein: Based on the recognition results, the YOLOv8-seg algorithm is used to determine the growth status information of Pleurotus geesteranus, specifically including: The YOLOv8-seg algorithm is used to extract the outline information of P. geesteranus in the target area image and obtain the mask information. Determining the size information of Pleurotus geesteranus using a pixel statistics method according to the mask information; Growth status information is determined according to the recognition result and the size information.
5. The method for identifying and predicting the growth of Pleurotus geesteranus based on image segmentation according to claim 1, wherein: The method for determining the TFT-LSTM hybrid model specifically includes: Construct a time series dataset based on historical growth information; Smoothing the time series data set using a sliding average method to obtain a processed time series data set; The processed time series data set is input into the long short-term memory network for calculation and processing, and the hidden state sequence is output; A time-fusion transformer is used to integrate features of hidden state sequences and filter covariates through the attention mechanism to train the attention weights of the long short-term memory network and obtain the trained long short-term memory network. The trained long short-term memory network and the time fusion transformer are combined to obtain the TFT-LSTM hybrid model.
6. The method for identifying and predicting the growth of Pleurotus geesteranus based on image segmentation according to claim 1, wherein: After acquiring the image data of the growth process of Pleurotus geesteranus, the following steps are also included: The image data is subjected to color space conversion, histogram equalization, normalization and data enhancement processing; the data enhancement processing includes: rotation, flipping and random cropping.
7. A device for identifying and predicting the growth of Pleurotus geesteranus based on image segmentation, characterized in that: include: An image data acquisition module is used to acquire image data of the growth process of Pleurotus geesteranus; An identification and detection module is configured to use an improved YOLOv8-seg model to determine an identification result of the growth stage of Pleurotus geesteranus and growth status information of Pleurotus geesteranus based on the image data; the improved YOLOv8-seg model includes a YOLOv8 backbone network; the YOLOv8 backbone network includes a hybrid backbone network module, a feature fusion module, a detection head optimization module, and a segmentation head optimization module sequentially connected via a data stream; The growth trend prediction module is used to perform growth prediction based on the growth status information using a standard growth model, and to perform growth trend prediction based on a TFT-LSTM hybrid model to obtain predicted growth trend information; the standard growth model is based on historical growth status information and is determined using a statistical analysis method and a DBSCAN clustering algorithm; the TFT-LSTM hybrid model is based on a time fusion transformer and a long short-term memory network and is trained using an attention mechanism based on historical growth information.
8. A computer device comprising: A memory, a processor, and a computer program stored in the memory and executable on the processor, wherein the processor executes the computer program to implement the Pleurotus geesteranus growth identification and prediction method based on image segmentation according to any one of claims 1 to 6.
9. A computer-readable storage medium having a computer program stored thereon, characterized in that: When the computer program is executed by a processor, the method for identifying and predicting the growth of Pleurotus geesteranus based on image segmentation according to any one of claims 1 to 6 is implemented.
10. A computer program product comprising a computer program, characterized in that When the computer program is executed by a processor, the method for identifying and predicting the growth of Pleurotus geesteranus based on image segmentation according to any one of claims 1 to 6 is implemented.