Abstract:Dense mushroom clusters can significantly impact mushroom quality and the success rate of automated harvesting. To address this issue,a spatiotemporal prediction algorithm for mushroom growth status based on historical time series growth images was proposed,which can facilitate early bud thinning to prevent the formation of dense mushroom clusters. The algorithm employed a sequence-to-sequence structure, comprising an encoder and a predictor. In the input, historical image sequences were transformed into 3D tensor sequences and sent to encoder. Within the encoder network, a three-layer long short term memory (LSTM) model was utilized. Here, convolution was fused into LSTM cell to extract spatiotemporal correlation features of mushroom growth. Meanwhile, a diffusion model was introduced into the predictor to address the blurriness issue in predicting images. Furthermore, a mushroom area difference loss function was designed and incorporated into the loss function to further reduce the shape and positional deviations between the predicted and actual mushrooms. The experimental results indicated that the proposed spatiotemporal prediction algorithm for mushroom growth status achieved a peak signal-to-noise ratio of 35.611dB, a multiscale structure similarity of 0.927, and a high mushroom mean intersection over union of 0.93, which represented improvements of 36%, 33% and 24%, respectively, over that of the ConvLSTM(Converlution LSTM)spatiotemporal prediction algorithm. This showed the proposed algorithm can effectively enhance the quality and accuracy of mushroom growth status image prediction, providing a approach for precise forecasting of edible mushroom growth.