Читать книгу Handbook of Intelligent Computing and Optimization for Sustainable Development - Группа авторов - Страница 81
3.3.2 Detection of Active Garments
ОглавлениеWe define an active garment as a garment present in the foreground frame obtained from the preceding stage. Individual color masks constituting the dominant colors such as Red, Blue, Green, and Yellow are applied to this foreground frame. As our data pre-processing involves the conversion of the video frames to the HSV color model, the color masks utilized in this step embodies the entire range of HSV values for a given color (i.e., all possible shades of a given color) and not just limited to a specific predetermined value. The corresponding images for each color are obtained after applying the given color masks to the foreground frame. The resulting images are converted to grayscale to reduce space and computational complexities. Morphological image processing techniques, most notably the closing operation, are performed to alleviate the small holes in images that arise due to noise.
Edge detection is used to detect the contours and edges that are present on each of the preceding frames. The given contours could either represent an entire active garment or a region of an active garment present in the foreground. Hence, an imperative step of identifying missing garment regions is performed once the garment regions are obtained. These missing regions of an active garment result from scenarios in which a customer serves as an occlusion to the active garment into consideration, thus obstructing a portion of the garment. These missing regions are identified as garment regions before the linking process. Linking identifies adjacent contours that belong to the same active garment and associates them based on spatial distance. Thus, this stage yields all active garments present used by the subsequent stages in a given video frame.