# HSV Color-Space-Based Automated Object Localization for Robot Grasping without Prior Knowledge
## 5 Experiment and Result Analysis
### Comparison of Algorithms  
The algorithm was evaluated by testing three products produced on the FaaS platform with different colors. Figure 7 shows the actual appearance of the product and the appearance of the product in the additive manufacturing facility (3D printer). It can be observed that the color of the product is deformed by shadows, reflections, etc., owing to the blue LED lighting in the additive manufacturing facility. Figure 7: Test products and test environments after production is completed in 3D printers: (a,d,g) original Test 1,2,3 products; (b,e,h) foreground of original Test 1,2,3; (c,f,i) background of original Test 1,2,3. The background subtraction by the Otsu algorithm in Figure 8 does not detect the product properly because of the long height of product 1 and severe noise owing to the influence of the top illumination. Even background subtraction by the GMM algorithm is not robust to changes in lighting, and only a part of the product background is detected. The GrabCut algorithm exhibits high performance because the user directly sets the product's bounding box in the foreground. However, GrabCut extracts the foreground step by step through user interaction. The HOG algorithm is insensitive to changes in light and illumination owing to the characteristic that distinguishes the amount and direction of the edge; thus, its IoU is higher than the background subtraction by the Otsu and GMM algorithms, but it has difficulty in accurate object localization. Test 2 in Figure 9 is a case where the background color and product color are clearly different. In the test product, the color of the product changes owing to the lighting in the 3D printer, but the colors are easily distinguished and separated, so the Otsu and GMM algorithms and IoU show good performance. Figure 10 shows that the background subtraction by the Otsu and GMM algorithms recognizes the reflected image of the Test 3 product, produced in the additive manufacturing facility (3D printer) as a product object. Although the intersection over union (IoU) performance is not high, GraphCut set by humans shows the same excellent performance as Test 1 and 2 products. Figure 11 shows the performance evaluation results of the proposed algorithm for the Test 1 product. The maximum ROI is displayed as a cyan line. Random sampling ROI sets to search 70 or 150 ROI and are indicated by a red rectangle within the maximum ROI of the 3D printer, and the reference ROI is represented by a yellow line. Figure 11b shows the mask image of the product that is merged by selecting only ROIs with high similarity to the HSV of the reference region among the HSV values of the random sampling ROI. The proposed algorithm shows good performance in IoU by extracting object localization by reflecting the effect of lighting in test product 1. Figure 10: Test 3 product result of background subtraction by the Otsu and GMM algorithms: (**a**) foreground mask of the background subtraction by the Otsu algorithm; (**b**) test result of the background subtraction by the Otsu algorithm; (**c**) foreground mask of the background subtraction by the GMM algorithm; (**d**) test result of the background subtraction by the GMM algorithm; (**e**) foreground mask of the GrabCut algorithm; (**f**) test result of the GrabCut algorithm; (**g**) gradient vector of the HOG algorithm; (**h**) test result of the HOG algorithm. Figure 12 shows the performance evaluation results of the proposed algorithm for the Test 2 product. The proposed algorithm extracts the HSV values of the reference ROI and of the random ROI and compares their similarity. Then, the merge operation is performed by selecting only the HSV values of the ROIs with a close distance. As a result of the HSV color-based similarity analysis, the similarity of ROI in the Test 1 product is high when the distance value is small (approximately 30 or less). Figure 13 shows the performance evaluation results of the proposed algorithm for the Test 3 products.