Agricultural engineers have developed an edge-deployable computer vision and machine learning pipeline capable of tracking dense clusters of commercial mushrooms, predicting their physical expansion hours in advance, and estimating harvested biomass from individual overhead images. Cultivated button mushrooms, such as white button and baby bella varieties of Agaricus bisporus, present severe operational monitoring bottlenecks because they develop in dim, humid growing rooms on vertically stacked shelf beds and must be harvested within tight windows of only a few hours once peak maturity is reached. Conventional automated vision systems often struggle with severe cap occlusions, ambient illumination shifts, and camera lens distortions, while manual shelf inspection remains error-prone and labor-intensive. To overcome these barriers without resorting to computationally expensive neural architectures, the researchers engineered an end-to-end framework combining convex-hull ellipse completion, causal time-series smoothing, and lightweight regression models capable of executing onboard compact embedded processing hardware.
The physical imaging configuration for monitoring commercial crop growth was established using a Rexing TL1 water-resistant time-lapse camera mounted directly above an industrial baby bella mushroom bed, positioned with its optical lens 419 millimeters above the casing soil surface. Configured to capture one high-resolution frame of 1,920 by 1,080 pixels every fifteen minutes over a 110-degree nominal field of view, the camera monitored an entire commercial crop cycle across 530 hours between May 1 and May 23, 2025, recording a sequence of 2,121 consecutive images. Because wide-angle lenses introduce severe radial barrel distortion that bows straight lines outward and warps spatial dimensions toward image borders, the team calibrated radial distortion parameters using a checkerboard calibration target. By establishing Brown-Conrady coefficients of k1 equal to minus 0.078 and k2 equal to zero, followed by cropping the images to 1,580 by 697 pixels, the distortion was removed. Using planar calibration routines, the optical focal length was determined to be 879.2 pixels, yielding a ground-sampling resolution of 0.477 millimeters per pixel across the horizontal growing plane.
Individual mushroom caps were segmented from every captured frame using a YOLOv8-X instance segmentation network trained on the M18K mushroom dataset, which achieved a validation precision of 0.955 and recall of 0.933 at an intersection-over-union threshold of 0.5. To track individual caps persistently across consecutive 15-minute frames, the researchers implemented a geometric tracking module based on mask overlap and the Hungarian assignment algorithm. Because physical mushroom growth causes radial expansion with cap centroid displacements below one pixel between frames, a strict intersection-over-union matching threshold of 0.90 was enforced. Across 2,121 frames and 135,879 associations, this conservative threshold prevented identity switches, yielding zero implausible associations where centroids shifted by more than a quarter diameter. When caps were temporarily obscured, an allowable tracking gap tolerance of up to ten frames bridged missed detections, producing 1,778 stable trajectories lasting at least five hours.
A critical technical obstacle in mushroom sizing is the occlusion caused by taller neighboring caps overlapping smaller caps below them, which carves concave indentations into the detected 2D masks and distorts standard diameter calculations. The researchers addressed this geometric corruption by extracting the convex hull of each segmented mask contour before performing geometric parameter estimation. By computing the convex hull, the concave bites caused by neighboring caps are discarded while preserving the true visible perimeter vertices of the cap. The team then fitted a Fitzgibbon direct least-squares ellipse under a quadratic constraint to these hull coordinates to recover the major and minor axis diameters. In controlled synthetic-occlusion experiments testing up to 50 percent area removal, the convex-hull ellipse fit recovered ground-truth diameters of well-formed caps with mean errors of only 1.0 percent at 10 percent occlusion, 2.3 percent at 40 percent occlusion, and 3.2 percent at 50 percent occlusion. Even across randomly sampled caps without circular screening, errors remained at 7.3 percent under 40 percent occlusion, outperforming raw contour fits and bounding boxes by a factor of two to four.
To translate fitted two-dimensional cap axes into accurate fresh biomass without destructive sampling, the team investigated the mathematical relationship between cap geometry and harvest weight across 203 white button mushrooms and 203 baby bella mushrooms spanning diameters from 2 to 83 millimeters and weights from 0.2 to 97 grams. Caliper measurements confirmed that caps deviate from circular geometry, meaning projected surface area is accurately described by an ellipse defined by perpendicular axes w and h. By evaluating 42 candidate regression algorithms using five-fold cross-validation repeated five times on stratified training sets, the researchers discovered that bivariate models incorporating both diameters consistently outperformed single-diameter models. Furthermore, the experiments proved that cultivated varieties exhibit distinct tissue densities: baby bella caps were systematically denser and heavier than white button caps of identical dimensions. Models trained on white mushrooms systematically underestimated baby bella weights with negative mean errors, while brown-trained models overestimated white caps, demonstrating that variety-specific or density-aware models are necessary for unbiased yield estimation.
The study also analyzed synthetic data augmentation by swapping width and height pairs to enforce mathematical symmetry on the unorganized axes. While width-height swapping improved cross-variety generalization and reduced errors for tree-based models on white button mushrooms by 0.9 to 1.8 grams, it slightly degraded performance when specialized to baby bella caps, where K-nearest neighbors achieved its lowest root-mean-square error of 2.22 grams and a mean error of minus 0.23 grams without augmentation. For white button mushrooms, an Extra-Trees regressor achieved a root-mean-square error of 4.73 grams and a mean signed error of minus 0.53 grams. These findings demonstrate that systematic measurement bias can be suppressed below one single gram per harvested cap using lightweight classical regressors, avoiding complex deep neural architectures.
Forecasting future cap size over time requires overcoming high-frequency segmentation jitter caused by frame-to-frame mask boundaries. The researchers implemented a causal moving average filter applied across a sliding temporal window of training sequences, which suppresses high-frequency edge fluctuations without leaking future chronological information. For single-image input settings where a forecast must be generated from one newly acquired image, causal smoothing of training targets with a ten-frame window reduced the validation root-mean-square error of an Extra-Trees growth model by 12.5 percent. When evaluated across 30 repeated group-level random data splits, single-image forecasts achieved an overall trajectory root-mean-square error of 4.6 millimeters. At fixed horizons, validation-selected models achieved diameter errors of 1.7 millimeters at 1 hour, 3.3 millimeters at 6 hours, 4.9 millimeters at 12 hours, and 10.1 millimeters at 24 hours.
Compared to a standard persistence baseline that assumes caps cease expanding, the learned forecasting models reduced 12-hour and 24-hour diameter prediction errors by approximately 18 to 23 percent. Linear autoregression models performed with high accuracy over extended rollouts, achieving an error of 9.7 millimeters at 24 hours compared to 13.1 millimeters for persistence. Because recursive predictions naturally compound errors over multi-day horizons when executed open-loop, the authors simulated periodic re-anchoring to fresh visual detections. Re-anchoring forecasts every 24 hours restricted the 72-hour diameter root-mean-square error to 12.1 millimeters, compared to 20.7 millimeters for static persistence, while re-anchoring every 12 hours suppressed 72-hour error to 6.4 millimeters. This demonstrates that scanning carts or mobile inspection robots making regular passes through growing rooms can maintain precise forward projections across multi-day harvesting periods.
To evaluate complete crop yield estimation, the researchers composed the convex-hull ellipse fit, single-image size forecasting, and the baby bella weight regressor into an integrated pipeline, tracking cohort biomass across 78 start images sampled every six hours across the crop cycle. Because physical trays could not be weighed destructively without disrupting growth, prediction errors were evaluated through Monte Carlo error propagation on tracked trajectories over 100 draws per image, sampling ellipse-fit and weight-regression residuals across distinct size classes. For the initial visible caps, the pipeline achieved a mean absolute biomass error of 3.4 percent at zero hours, 6.6 percent at 6 hours, 9.9 percent at 12 hours, 15.7 percent at 24 hours, and 26.5 percent at 72 hours using Extra-Trees, with signed mean errors remaining between minus 1.5 and positive 0.7 percent through 24 hours. The cohort biomass curve flattened after 24 to 48 hours as mature caps reached the end of their tracked lifespans and were picked from the beds.
Deployability on resource-constrained embedded platforms was validated by benchmarking the full processing pipeline on an NVIDIA Jetson Orin NX 16-gigabyte embedded hardware module operating in MAXN power mode. With the YOLOv8-X network compiled under TensorRT in 16-bit floating-point precision, undistortion, cropping, mask decoding, convex-hull fitting, 72-hour growth forecasting, and mass regression required only 0.55 seconds per image when using linear autoregression, and 7.8 seconds per image when utilizing the Extra-Trees forecaster. Both runtimes remain well within the 15-minute operational image acquisition interval, confirming that advanced growth tracking and yield prediction can run locally without continuous cloud connectivity or heavy computational infrastructure.
The authors emphasize several operational limitations that delineate the scope of their findings. All time-lapse growth sequences were recorded from a single commercial cultivation shelf during a single 22-day crop cycle, meaning geographic, seasonal, and environmental variations across differing farm facilities, ventilation rates, compost preparations, and mushroom strains require further multi-site validation. Because harvest times were not prospective predictions, cohort yield evaluations were conducted conditional on observed trajectory endpoints, meaning future deployments must incorporate automated harvest-readiness classifiers. Furthermore, vertical distance variations between the camera and elevated cap rims introduce uncorrected magnification effects that could be mitigated in future work by integrating depth sensors or volumetric descriptors. Nevertheless, the released open dataset, trajectory annotations, and lightweight algorithms provide an efficient technological foundation for data-driven harvest scheduling and automated robotic picking in modern controlled-environment agriculture.
Subject of Research: Edge computer vision and yield forecasting pipeline for commercial mushroom cultivation
Article Title: Edge-deployable growth and yield forecasting for commercial mushroom farms
Article References: Zakeri, A., Kang, J., Koirala, B., Silwal, R., Balan, V., Zhu, W., Benhaddou, D., & Merchant, F. A. (2026). Edge-deployable growth and yield forecasting for commercial mushroom farms. Smart Agricultural Technology, 15, Article 102762. https://doi.org/10.1016/j.atech.2026.102762
Image Credits: AI Generated
DOI: 10.1016/j.atech.2026.102762
Keywords: mushroom cultivation, Agaricus bisporus, edge computing, computer vision, yield forecasting, growth prediction, instance segmentation, YOLOv8, convex hull, Fitzgibbon ellipse fitting, biomass estimation, causal smoothing, Jetson Orin NX, precision agriculture, time-lapse analysis, crop monitoring
News Source: Alan Morgan. (November 26, 2026). Edge Computer Vision Pipeline Forecasts Mushroom Growth and Crop Yield. Scienmag.



