# Improved Mask R-CNN Combined with Otsu Preprocessing for Rice Panicle Detection and Segmentation
## 1 Introduction  
Rice is one of the most important food crops worldwide, as more than half of the world's population depends on rice as its main food source. China is the second largest rice-growing country, accounting for more than 30% of the total global rice production, and rice is the second most important crop in China [1]. Rice yield is closely related to the number and proportional area of rice panicles. Traditional monitoring methods mainly rely on manual observation, which is tedious, inefficient and subjective, and has difficulty meeting real-time, rapid and nondestructive monitoring requirements. With improvements in agricultural information and the development of computer vision, traditional production management methods are gradually shifting to an artificial intelligence basis, and the detection and assessment of rice pests and diseases, as well as fertility, can be achieved with the help of images taken by field cameras in real time, allowing timely prevention and management [2, 3, 4, 5, 6, 7]. Accurate rice panicle segmentation is a key step in achieving intelligent rice monitoring and yield assessment. However, it is very difficult to segment rice panicles due to the complex natural environment in rice fields, for example, panicle and leaf shielding, the easy color mixing and uneven light changes. Researchers have applied image detection technology in detecting and segmenting field crops such as rice panicles and wheat ears, effectively improving detection efficiency and reducing costs. By leveraging color and texture features at the pixel level, [PERSON] selected red, green and blue images acquired by manned ground vehicles according tothe light intensity for superpixel segmentation, and used the relevant features to count the number of wheat ears, but the accuracy varied greatly with the number of features and illumination intensity [8]. [PERSON] proposed an automatic counting algorithm for measuring the density of ears of wheat using RGB images acquired by handheld cameras, however this method was only suitable for counting unripe wheat [9]. [PERSON] fused a simple linear iterative clustering (SLIC) method to generate superpixels and segment ears of corn, but the hardware facilities that this method relies on could not meet the requirements of real-time segmentation [10]. [PERSON] proposed a simple linear iterative clustering (SLIC) method based on superpixel region generation and convolutional neural network (CNN) classification to segment ears of wheat [11]. However, this method was time-consuming and cumbersome, and the segmentation results were easily affected by many factors. [PERSON] collected images of wheat ears in a field environment with a camera, and accurately extracted the outlines of the ears based on the color and texture features of the ears, finally obtaining the number of ears in the image, however illumination had a great influence on color and texture features in the real environment [12]. [PERSON] used the LAB color model and the Otsu thresholding segmentation (Otsu) method to extract rice seedling information and combined it with skeleton extraction to detect the number of machine-planted seedlings [13]. [PERSON] used digital images of experimental rice fields taken by unmanned aerial vehicles (UAV), the number of rice spikes in the ground plot sample and other measured data, and applied the feature parameters extracted by the best subset selection algorithm to construct a rice spike segmentation model and obtain the number of rice spikes [14]. Nevertheless, it was difficult to prepare the data set, the color features were unstable, and the segmentation effect was closely related to the shooting. By implementing candidate area-based classification and a counting method by segmenting (spike or background), and counting the generated candidate areas, [PERSON] generated spike candidate regions using Laws' texture energy to calculate the number of spikes for spike detection.