Automatic Evaluation of Soybean Seed Traits Using RGB Image Data and a Python Algorithm

Plants (Basel). 2023 Aug 28;12(17):3078. doi: 10.3390/plants12173078.

Abstract

Soybean (Glycine max) is a crucial legume crop known for its nutritional value, as its seeds provide large amounts of plant protein and oil. To ensure maximum productivity in soybean farming, it is essential to carefully choose high-quality seeds that possess desirable characteristics, such as the appropriate size, shape, color, and absence of any damage. By studying the relationship between seed shape and other traits, we can effectively identify different genotypes and improve breeding strategies to develop high-yielding soybean seeds. This study focused on the analysis of seed traits using a Python algorithm. The seed length, width, projected area, and aspect ratio were measured, and the total number of seeds was calculated. The OpenCV library along with the contour detection function were used to measure the seed traits. The seed traits obtained through the algorithm were compared with the values obtained manually and from two software applications (SmartGrain and WinDIAS). The algorithm-derived measurements for the seed length, width, and projected area showed a strong correlation with the measurements obtained using various methods, with R-square values greater than 0.95 (p < 0.0001). Similarly, the error metrics, including the residual standard error, root mean square error, and mean absolute error, were all below 0.5% when comparing the seed length, width, and aspect ratio across different measurement methods. For the projected area, the error was less than 4% when compared with different measurement methods. Furthermore, the algorithm used to count the number of seeds present in the acquired images was highly accurate, and only a few errors were observed. This was a preliminary study that investigated only some morphological traits, and further research is needed to explore more seed attributes.

Keywords: Python algorithm; image analysis; seed number; seed size; soybean.