## 3 Experiments and Results
### Detection of the Grape Clusters under Different Lighting Conditions  
In order to investigate the performance of the detection algorithm under varying lighting conditions and complex backgrounds, 200 summer black grape images that were captured from different perspectives at the vineyard were tested using the developed detection algorithm in this paper. Among the 200 images, 60 images were collected under sunny frontlight conditions in which 136 grape clusters could be found, 60 images were collected under sunny overshadow conditions in which 129 grape clusters could be found, and the remaining 80 images were collected under overcast lighting conditions in which 182 grape clusters could be found. The tests were performed under above three different lighting conditions, respectively. The segmentation and detection results of one of the three conditions are shown in Figure 7. From the figure we can see that the grape clusters in original images were correctly identified and the backgrounds (green leaves, surface and sky, etc.) can be well classified. However, some iron frames, petioles, stipes and dead leaves can't be identified at times, and a large part of the pixels were wrongly classified as grape, which can be seen in Figure 7b. However, these pixel points could be effectively removed after the denoising process, and the final detection effects were better.  
\begin{table}
\begin{tabular}{c c c c c c c} \hline \hline \multirow{2}{*}{**Classifiers**} & \multirow{2}{*}{**Actual Categories**} & \multirow{2}{*}{**Samples Number**} & \multicolumn{2}{c}{**Classified Categories**} & \multirow{2}{*}{**TPR/\%**} & \multirow{2}{*}{**FPR/\%**} \\ \cline{3-3} \cline{5-6}  & & & **Grape** & & **Background** & \\ \hline \multirow{2}{*}{\(h_{1}(x_{i})\)} & Grape & 300 & 276 & 24 & \multirow{2}{*}{93.67} & \multirow{2}{*}{6.33} \\  & Background & 600 & 33 & 567 & & \\ \hline \multirow{2}{*}{\(h_{2}(x_{i})\)} & Grape & 300 & 231 & 69 & \multirow{2}{*}{90.22} & \multirow{2}{*}{9.78} \\  & Background & 600 & 19 & 581 & & \\ \hline \multirow{2}{*}{\(h_{3}(x_{i})\)} & Grape & 300 & 259 & 41 & \multirow{2}{*}{81.33} & \multirow{2}{*}{18.67} \\  & Background & 600 & 127 & 473 & & \\ \hline \multirow{2}{*}{\(h_{4}(x_{i})\)} & Grape & 300 & 278 & 22 & \multirow{2}{*}{83.56} & \multirow{2}{*}{16.44} \\  & Background & 600 & 126 & 474 & & \\ \hline \multirow{2}{*}{\(H(x_{i})\)} & Grape & 300 & 282 & 18 & \multirow{2}{*}{96.56} & \multirow{2}{*}{3.44} \\  & Background & 600 & 13 & 587 & & \\ \hline \hline \end{tabular}
\end{table}
Table 2: Comparison of the classifiers accuracy.  
Figure 7: _Cont._  
In order to quantitatively evaluate the performance of the developed detection approach the false negative rate (FNR), false positive rate (FPR) and true positive rate (TPR) of the experiment were analyzed. The total of false negatives (where the background was misclassified as grape clusters) and missed grape clusters were manually counted. Table 3 lists the FNR, FPR and TPR of the proposed method under three different lighting conditions. In this developed detection approach, 93.74% of the actual numbers of the grape clusters were correctly identified. The false negative rate was about 4.34%. About 6.26% of the grape clusters were not detected. The true positives rate was the highest under the overcast lighting and reached to 95.05%.