Agronomy (Jan 2023)

A Novel Segmentation Recognition Algorithm of <i>Agaricus bisporus</i> Based on Morphology and Iterative Marker-Controlled Watershed Transform

  • Chao Chen,
  • Shanlin Yi,
  • Jinyi Mao,
  • Feng Wang,
  • Baofeng Zhang,
  • Fuxin Du

DOI
https://doi.org/10.3390/agronomy13020347
Journal volume & issue
Vol. 13, no. 2
p. 347

Abstract

Read online

Accurate recognition of Agaricus bisporus is a prerequisite for precise automatic harvesting in a factory environment. Aimed at segmenting mushrooms adhering together from the complex background, this paper proposes a watershed-based segmentation recognition algorithm for A. bisporus. First, the foreground of A. bisporus is extracted via Otsu threshold segmentation and morphological operations. Then, a preliminary segmentation algorithm and a novel iterative marker generation method are proposed to prepare watershed markers. On this basis, a marker-controlled watershed algorithm is adopted to segment and recognize A. bisporus individuals. All the algorithms are implemented based on OpenCV (Open Source Computer Vision) libraries. Tests on images of A. bisporus collected at the cultivation bed show that the average correct recognition rate of the proposed algorithm is 95.7%, the average diameter measurement error is 1.15%, and the average coordinate deviation rate is 1.43%. The average processing time is 705.7 ms per single image, satisfying the real-time constraints based on 1 image/s. The proposed algorithm performed better than the current Circle Hough Transform (OpenCV’s implementation). It is convenient and easy to operate, providing a sound basis for subsequent research on mechanized harvesting equipment for A. bisporus.

Keywords