원시데이터 수집 시스템
선정목록으로

Automatic Classification and Color Changing of Saree Components Using Deep Learning Techniques

관련 모빌리티 소재 · (4) 카시트 모듈

기본 정보

저자
  1. N. V. Karanth — Department of Computer Science Engineering, R. V. College of Engineering (RVCE), Bengaluru, India
  2. Arya Adesh — Department of Computer Science Engineering, R. V. College of Engineering (RVCE), Bengaluru, India
  3. Chandan Kasamsetty — Department of Computer Science Engineering, R. V. College of Engineering (RVCE), Bengaluru, India
  4. Abhinav Samaga — Department of Computer Science Engineering, R. V. College of Engineering (RVCE), Bengaluru, India
  5. G. Shobha — Department of Computer Science Engineering, R. V. College of Engineering (RVCE), Bengaluru, India
  6. Minal Moharir — Department of Computer Science Engineering, R. V. College of Engineering (RVCE), Bengaluru, India
  7. Chetan Garg — Reshamandi, Bangalore, India
DOI
10.1109/access.2024.3352649
저널
IEEE Access
발행년도
2024
발행기관
Institute of Electrical and Electronics Engineers
피인용수
1
라이선스
cc-by-nc-nd
논문 유형
–
언어
–
원문 페이지
https://doi.org/10.1109/access.2024.3352649
토픽
Color Science and Applications
OpenAlex ID
W4390738646

평가 내용

관련도
관련
사업분야
모빌리티 소재 · (4) 카시트 모듈
부 분야
–
R&D 측면
–
확신도
–
근거 용어
–
판단 근거
임베딩 유사도 기반 평가로 '모빌리티 소재 > 카시트 모듈' 분야에 선정된 논문입니다.
R&D 활용 포인트
–
평가 입력
–

초록

Sarees are integral to Indian culture and serve as daily attire for most women on the subcontinent. Despite their popularity, there exists a gap in research regarding the automatic segmentation of sarees and the independent color modification of distinct components. Existing methods rely on labor-intensive manual adjustments through commercial applications, impeding productivity and resulting in avoidable expenses. This paper presents a tool that smartly coordinates different deep-learning techniques to modify the color patterns found on different parts of a saree. MODNet is applied for background removal and custom-trained Mask R-CNN models are utilized to precisely segment the saree body and border. The subsequent application of a color-changing algorithm in the HSV color space facilitates independent color modification for the saree border and body. The methodology proposed in this paper can be extended to any kind of clothing such as shirts, trousers, kurtas, kimonos, etc. An accuracy of 93.01% was achieved for the saree border segmentation, and an accuracy of 89.23% was achieved for the saree body segmentation when tested on a set of 50 test images.

본문 41,825자

본문 펼치기
# Automatic classification and color changing of saree components using Deep Learning Techniques Naman Karanth <sup>1</sup> , Arya Adesh <sup>2</sup> , Chandan Kasamsetty <sup>3</sup> , Abhinav Samaga <sup>4</sup> , Shobha G <sup>5</sup> , Minal Moharir <sup>6</sup> , Chetan Garg <sup>7</sup> 1,2,3,4,5,6 Department of Computer Science Engineering, RVCE, Bangalore, India 7 Reshamandi, Bangalore, India <mark>[Corresponding author: Minal Moharir (e-mail: minalmoharir@rvce.edu.in).](mailto:minalmoharir@rvce.edu.in)</mark> ABSTRACT Sarees are integral to Indian culture and serve as daily attire for most women on the subcontinent. Despite their popularity, there exists a gap in research regarding the automatic segmentation of sarees and the independent color modification of distinct components. Existing methods rely on labor-intensive manual adjustments through commercial applications, impeding productivity and resulting in avoidable expenses. This paper presents a tool that smartly coordinates different deep-learning techniques to modify the color patterns found on different parts of a saree. MODNet is applied for background removal and custom-trained Mask R-CNN models are utilized to precisely segment the saree body and border. The subsequent application of a color-changing algorithm in the HSV color space facilitates independent color modification for the saree border and body. The methodology proposed in this paper can be extended to any kind of clothing such as shirts, trousers, kurtas, kimonos, etc. An accuracy of 93.01% was achieved for the saree border segmentation, and an accuracy of 89.23% was achieved for the saree body segmentation when tested on a set of 50 test images. INDEX TERMS Semantic Segmentation, Neural Networks, Color spaces, MODNet, Mask R-CNN, Faster R-CNN <mark>I.INTRODUCTION</mark> <mark>The onset of artificial intelligence and machine learning has</mark> <mark>revolutionized different domains ranging from education to</mark> <mark>manufacturing. The technological void in the traditional</mark> <mark>Indian clothing sector provides research opportunities to</mark> <mark>advance automation and modernization. The saree market in</mark> <mark>particular suffers from a general shortage of innovation. This</mark> <mark>industry currently uses time-intensive image editing software</mark> <mark>like Photoshop [1] to design and visualize attire, which also</mark> <mark>demands specialized expertise. To make the process more</mark> <mark>efficient and effortless for retailers, this paper proposes a new</mark> <mark>intuitive software tool tailored to the saree market that enables</mark> <mark>easy virtual design and visualization.</mark> <mark>The saree is a traditional Indian garment that is a single</mark> <mark>piece of clothing. The horizontal ends of the cloth are ornate</mark> <mark>to form the border. The body of the saree is the main portion</mark> <mark>of the garment surrounded by the border. Currently, there are</mark> <mark>no methods employed in the saree retail or manufacturing</mark> <mark>sector for the automated detection and color customization of</mark> <mark>different elements of a saree. This paper proposes a</mark> <mark>methodology to recognize distinct elements of a saree using</mark> <mark>deep learning techniques without user intervention and to</mark> <mark>allow color customization of saree components. The</mark> <mark>suggested approach employs background removal, image</mark> <mark>segmentation, and pixel value manipulation in the HSV color</mark> <mark>space to facilitate automation.</mark> <mark>The background in the image is removed to eliminate the</mark> <mark>unwanted noise in the image and increase the accuracy of the</mark> <mark>segmentation. One such technique is the defocused image</mark> <mark>segmentation proposed in [2] which improves upon the PCNN</mark> <mark>and LBP frameworks [3] in terms of accuracy and efficiency.</mark> <mark>This technique relies on the blur or bokeh effects present in</mark> <mark>the image for the segmentation. On the other hand, the</mark> <mark>MODNet architecture [4] generalizes background detection to</mark> <mark>recognize background even in the absence of blur/bokeh</mark> <mark>effect, using a lightweight combination of trimap-free matting</mark> <mark>and a trimap-grounded matting step.</mark> <mark>The detection of the saree body and the border can be</mark> <mark>achieved utilizing state-of-the-art methods like color-based</mark> <mark>segmentation using thresholding [5], edge detection, or</mark> <mark>contour-based techniques [6]. However, these methods suffer</mark> <mark>from various drawbacks, such as sensitivity to lighting</mark> <mark>conditions, manual parameter tuning, lack of robustness when</mark> <mark>dealing with overlapping designs, and reduced computational</mark> <mark>efficiency. To address these limitations, this paper employs a</mark> <mark>strategy similar to the one outlined in [7], which uses peak</mark> <mark>color pixel values for segmentation. However, this paper uses</mark> <mark>HSV to extract the highest hue values in conjunction with</mark> <mark>Mask R-CNN [9], as opposed to the k-means algorithm in [7],</mark> <mark>for improved accuracy. The HSV color space [11][12][13]</mark> <mark>offers a convenient method to alter the color of an image</mark> <mark>while retaining its contrast and saturation details. This paper</mark> <mark>also improves upon the technique proposed in [14] by</mark> <mark>incorporating mask R-CNN for segmentation, enabling</mark> <mark>simultaneous color changing of multiple clothing items.</mark> <mark>The</mark> <mark>contributions of this research work are:</mark> <mark>1.</mark> <mark>Employing deep learning techniques for the</mark> <mark>automated detection of the saree components.</mark> <mark>2.</mark> <mark>Allowing simultaneous color-changing of different</mark> <mark>saree components while preserving its contrast and</mark> <mark>saturation details.</mark> <mark>The following section provides a brief description of the</mark> <mark>classification techniques, followed by the background removal</mark> <mark>process and its significance. Furthermore, it provides a</mark> <mark>detailed explanation of the segmentation model, covering</mark> <mark>aspects of its training and functioning. It then elucidates the</mark> <mark>mechanism of color changing along with the analysis of</mark> <mark>different color spaces. Finally, the paper concludes with the</mark> <mark>experimental results and the future scope of the study</mark> <mark>II.</mark> <mark>RELATED WORKS</mark> <mark>The proposed methodology mainly consists of selecting the</mark> <mark>pixels related to different saree components and then</mark> <mark>recoloring them. To enable this, a combination of background</mark> <mark>removal technologies and semantic segmentation techniques</mark> <mark>are utilized. The HSV color space is adopted for recoloring</mark> <mark>the image. This section briefly explains the current</mark> <mark>advancements in background removal, image segmentation,</mark> <mark>and hue manipulation technologies.</mark> _<mark>A.</mark>_ _<mark>Background Removal - MODNet</mark>_ <mark>MODNet is a lightweight combination of trimap-free matting</mark> <mark>and a trimap-grounded matting step which enhances the</mark> <mark>performance of the algorithm. Image matting and trimap-free</mark> <mark>image mapping are some of the commonly used background</mark> <mark>removal techniques. Traditional matting algorithms such as</mark> <mark>Image matting heavily rely on low-level features, such as</mark> <mark>color cues, to determine the alpha matte through sampling,</mark> <mark>which often fails in complex scenes [15]. Trimap-free</mark> <mark>mapping techniques are less efficient and are computationally</mark> <mark>expensive [16]. MODNet provides an efficient, lightweight,</mark> <mark>and robust pipeline for background removal that overcomes</mark> <mark>the shortcomings of the above two mentioned techniques [4].</mark> <mark>The proposed methodology improves upon the works of F.</mark> <mark>Liu et.al. [5] where YOLO v5 is used along with GrabCut to</mark> <mark>isolate the foreground region. Here MODNet is used for the</mark> <mark>background removal which has an MAE of 18.1 and an IoU of</mark> <mark>66.9, which is significantly better than the performance of</mark> <mark>GrabCut, which has an MAE of 29.3 and an IoU of 49.6 [4].</mark> <mark>Moreover, k-means may not be efficient in cases where the</mark> <mark>color of the garment matches the background color or the skin</mark> <mark>color of the person wearing it which makes it inefficient.</mark> <mark>Hence a custom Mask R-CNN model is used to remove the</mark> <mark>hands and face of the human.</mark> <mark>MODNet has several advantages over previous trimap-free</mark> <mark>methods. MODNet is much faster, running at 67 frames per</mark> <mark>second (fps) on a GTX 1080 Ti GPU with an input size of 512</mark> <mark>× 512 (including data loading) [4]. MODNet achieves state-</mark> <mark>of-the-art results on both the open-source Adobe Matting</mark> <mark>benchmark and the newly proposed PPM-100 benchmark.</mark> <mark>Moreover, MODNet can be easily optimized end-to-end as it</mark> <mark>is a single model instead of a complex pipeline. Finally,</mark> <mark>MODNet has better generalization ability, due to the SOC</mark> <mark>strategy. Hence MODNet is an appropriate model for this</mark> <mark>application.</mark> _<mark>B. Mask R-CNN</mark>_ <mark>Object detection and semantic segmentation technologies are</mark> <mark>structured around Convolutional Neural Networks. These</mark> <mark>methodologies can be divided into two distinct categories:</mark> <mark>one-stage and two-stage approaches. Algorithms like YOLO</mark> <mark>[17] and SSD [18] emphasize on inference speed while</mark> <mark>compromising</mark> <mark>accuracy.</mark> <mark>Whereas</mark> <mark>Semantic</mark> <mark>image</mark> <mark>segmentation assigns a class to each of the pixels of the</mark> <mark>image. The field is dominated by models such as the</mark> <mark>Fast/Faster R-CNN [19], Fully Convolutional Networks</mark> <mark>(FCN) [20], Mask R-CNN [6], and U-net [21][22]. Mask R-</mark> <mark>CNN performs well in partitioning the image into separate</mark> <mark>objects, without combining these detected objects as a single</mark> <mark>entity, as in U-Net [23] or ClothingOut [24].</mark> <mark>DeepLab v3 stands as a prominent semantic segmentation</mark> <mark>model that leverages atrous convolutions to adjust filter field-</mark> <mark>of-view and regulate feature response resolution in CNNs[34].</mark> <mark>Its evolution refines the atrous Spatial Pyramid Pooling</mark> <mark>module by integrating image-level features for enhanced</mark> <mark>global context encoding[35].</mark> <mark>In</mark> <mark>contrast,</mark> <mark>the</mark> <mark>Bilateral</mark> <mark>Segmentation</mark> <mark>Network</mark> <mark>(BiSeNet)[36] adopts a Spatial Path, maintaining spatial</mark> <mark>details through stacked convolutional layers, and a Context</mark> <mark>Path, efficiently utilizing global average pooling and an</mark> <mark>Attention Refinement Module (ARM) for feature learning.</mark> <mark>Combining these paths via a Feature Fusion Module, BiSeNet</mark> <mark>achieves real-time performance and high accuracy in semantic</mark> <mark>segmentation.</mark> <mark>Segmentation of clothes has already been achieved utilizing</mark> <mark>algorithms like SSD [25], and Mask R-CNN [26]. But all</mark> <mark>these techniques focus on parsing western attire and have not</mark> <mark>been trained on parsing sarees. Extracting particular regions of</mark> <mark>interest associated with the body and border of the saree can</mark> <mark>be achieved by utilizing polygonal object detection and</mark> <mark>segmentation.</mark> <mark>Mask R-CNN is an appropriate choice in this scenario as</mark> <mark>object masks produced by it are required for selecting these</mark> <mark>specific pixels. Mask R-CNN improves upon the Faster R-</mark> <mark>CNN by creating a new branch for estimating segmentation</mark> <mark>masks on each Region of Interest (RoI) simultaneously along</mark> <mark>with the existing branch for classification and bounding box</mark> <mark>regression [6].</mark> _<mark>C. HSV COLOR SPACE</mark>_ A color model or color space represents a coordinate system, where each point specifies a color. In this model, every color can be described as a tuple of numbers [11]. HSV color space is a cylindrical color space, with hue as angular dimension, beginning at 0° as a reference, then passing through the colors Yellow, Green, Cyan, Blue, and Magenta and ending at 360°. Saturation is the length of the vector from the origin to a particular point in the color space. The image of interest is converted to HSV because chromatic FIGURE 1. Block Diagram of the proposed architecture information can be extracted from the hue component and changes can be made only in that component of the color [12][13]. All three dimensions of HSV space are independent, so changes in one do not affect the others. Hue is in the range of 0 to 360°, saturation ranges from 0 to 100%, and value is between 0 to 100%. A design is required for the segmentation of saree images to identify components like the body and border of the saree and then be able to modify its colors. The design proposed in this paper makes use of all the above-mentioned models for the same purpose. The proposed methodology offers significant advantages over the approach described in [14]. In contrast to the latter, which performs background and shadow removal as separate time-consuming steps, the proposed method efficiently integrates both tasks into a single step using MODNet [4], significantly improving processing speed. Additionally, the referenced approach relies on the EM method for background parameter estimation, which can be computationally costly and time-consuming. The approach described in [14] relies on a fixed skin map (defined as H≤ 19 and S≥ 48). However, this fixed map can pose difficulties when sarees have hue values similar to the skin and fail to accommodate variations in skin tones. Notably, Mask R-CNN combines the steps of face and skin removal, streamlining the process when compared to the referenced approach. Haar feature-based cascade classifiers used in the referenced approach suffer from a low recognition rate [27] for face detection; hence, Mask R-CNN offers superior accuracy and versatility. The proposed approach can handle images with multiple clothing accessories, unlike [14], allowing simultaneous alteration of body and border colors even when hue values are similar. <mark>III.PROPOSED METHODOLOGY</mark> <mark>The proposed tool consists of three phases: the human</mark> <mark>detection, background removal, and recoloring phase as</mark> <mark>shown in</mark> <mark>Fig.1</mark> <mark>. The first phase takes a saree image as an input</mark> <mark>and classifies it into either an image of a human draped in a</mark> <mark>saree or an image of only a saree without a human using</mark> <mark>Faster R-CNN. Background removal is performed using</mark> <mark>MODNet for images with humans. The second phase involves</mark> <mark>segmenting the saree components by removing human parts</mark> <mark>(such as the face and hands) and detecting borders using</mark> <mark>separate Mask R-CNN models. The last phase involves the</mark> <mark>color change of pixels corresponding to the saree body and the</mark> <mark>saree border, utilizing the HSV color space. Further details</mark> <mark>regarding each of the phases are provided in the following</mark> <mark>section.</mark> _<mark>A. HUMAN DETECTION AND BACKGROUND REMOVAL</mark>_ <mark>All images taken into consideration are classified based on the</mark> <mark>presence or absence of a human in the image. This is</mark> <mark>performed by a Faster-R-CNN model trained with over 1500+</mark> <mark>images and has an accuracy of over 96% [28]. It classifies</mark> <mark>images in less than 90 ms, which is significantly faster than</mark> <mark>that of other state-of-the-art models. Classification is essential</mark> <mark>because images of humans require specific processing steps,</mark> <mark>including background removal, as well as hand and face</mark> removal to eliminate their impact on color modification. <mark>Background removal is necessary to isolate and focus on</mark> <mark>the subject wearing a saree, reducing interference from</mark> <mark>irrelevant noise. In the proposed methodology, MODNet is</mark> <mark>used to remove background from the images. The</mark> <mark>implementation of MODNet was sourced from [4]. The output</mark> <mark>of background removal using MODNet on the input image is</mark> <mark>shown in</mark> <mark>Fig 2.</mark> FIGURE 2: Background removal using MODNet _<mark>B. REMOVING BODY AND DETECTING BORDER</mark>_ Custom-trained Mask R-CNN models are employed to segment the body and border of the saree in the image. The implementation of this model was sourced from [29]. Two separate Mask R-CNN models are utilized for the detection of the body and border in two distinct categories of input images. The first Mask R-CNN model, customized for images containing humans, performs multi-class segmentation, segmenting three different classes: the saree body, the saree border, and the hands and face of the human subject. The Mask R-CNN model designed for images without humans, utilises multi-class segmentation capability to simultaneously segment the saree body and border as distinct classes. The models were trained using a set of 500 images each. The images were manually annotated by using a set of polygons that demarcate the desired regions. Annotations were created using MakeSense AI [30], which is an open-source tool used for annotating images. The model was trained with a learning rate of 0.001 and image size of 512 x 512 with batch size 4 for 15 epochs. <mark>In the case of images containing humans, the sequence of</mark> <mark>operations begins with background removal. Subsequently,</mark> <mark>the first Mask R-CNN model is employed to segment the</mark> <mark>hand, face, and saree border from the image. This leaves the</mark> <mark>saree body unaltered for the color-changing process.</mark> <mark>Fig.3</mark> <mark>illustrates the output of each step of the proposed</mark> <mark>methodology.</mark> FIGURE 3. Different stages of using Mask R-CNN In the case of saree images without humans, the second Mask R-CNN model is directly used on the input image to extract regions belonging to the body and border of the saree. The results of the two models are shown in Fig.4. FIGURE 4. From left to right: Input image of a folded saree, saree body that is obtained after using the saree body detection model and the saree border that is obtained after using the saree border detection model. <mark>These extracted regions associated with the body and the</mark> <mark>border of the saree respectively are used to apply the color</mark> <mark>change. The next section describes the detection of the pixels</mark> <mark>pertaining to the body and border of the saree from these</mark> <mark>regions and the color-changing algorithm used to change</mark> <mark>them.</mark> _<mark>C. COLOR CHANGING</mark>_ <mark>Once the image's region of interest is identified, the existing</mark> <mark>color can be swapped with another color of interest. Swapping</mark> <mark>of colors is easy if both color and intensity information are</mark> <mark>specified as separate components independent of each other.</mark> <mark>Hence, the HSV color space proves to be the right choice for</mark> <mark>this task. On the other hand, RGB space represents the color,</mark> <mark>brightness, and intensity details of an image using a</mark> <mark>combination of red, green, and blue colors. Hence, it is</mark> <mark>difficult to approximate the amount by which each component</mark> <mark>must be changed to obtain the desired color without affecting</mark> <mark>the intensity and brightness. To accomplish this, the hue value</mark> <mark>is used to change colors. Thus, color spaces such as RGB and</mark> <mark>CMY are not suitable for describing colors in the manner that</mark> <mark>humans perceive them [31].</mark> <mark>The HSV Color space includes Hue, Saturation, and</mark> <mark>Brightness [32]. Hue represents the dominant color as</mark> <mark>perceived by the viewer. The hue is a characteristic that</mark> <mark>encodes the dominant wavelength in a mixture of wave lights.</mark> <mark>Saturation represents the amount of white light mixed with</mark> <mark>pure hue. The degree of saturation is inversely proportional to</mark> <mark>the amount of white light mixed with color. The saturation</mark> <mark>and hue describe the chromaticity of an image.</mark> FIGURE 5. Hue histogram of the segmented region <mark>The image is first converted from RGB to the HSV color</mark> <mark>space according to the method described in [12]. Then, for</mark> <mark>each area of interest, the Hue histogram is plotted [13]. The</mark> <mark>hue Histogram represents a plot between the hue value</mark> <mark>(ranging from 0 to 365) and the number of pixels with the</mark> <mark>same hue value (frequency). Fig.5 shows the hue histogram</mark> <mark>plotted for the segmented region consisting of the body of the</mark> <mark>saree. Individual components of a saree tend to have a unique</mark> <mark>but uniform color. The dominant color in each recognized</mark> <mark>region is indicated by the peak in the hue histogram [33]. The</mark> <mark>pixels within the tolerance range are changed to another value</mark> <mark>of choice. Changes made in the hue value of the pixels render</mark> <mark>no changes in saturation or value component; hence, the saree</mark> <mark>retains the contrast and saturation details of the original</mark> <mark>image. The clothing map is calculated according to the</mark> <mark>following equation</mark> - + ( ) { <sup>( )</sup> (1) Smask represents the set of pixels detected by Mask R-CNN, pmax is the mode of Hue values of all pixels belonging to the set, _v_ is the variance, and h(i,j) is the hue of the pixel at a particular coordinate {i,j}. <mark>IV.RESULTS AND PERFORMANCE EVALUATION</mark> <mark>A test set was prepared consisting of 50 images showcasing</mark> <mark>different saree varieties. The test set was meticulously</mark> <mark>annotated using the MakeSenseAI annotation tool to</mark> <mark>distinguish between two class entities: the body and the</mark> <mark>border. The annotations function as the ground truth labels</mark> <mark>against which the results of the proposed methodology are</mark> <mark>assessed and compared. Subsequently, the test set was</mark> <mark>processed using the proposed software tool, which identified</mark> <mark>pixels belonging to the body and border categories. The pixel</mark> <mark>classification obtained from the tool was then compared with</mark> <mark>the manual annotations for validation. The confusion matrix is</mark> <mark>used to assess the model's ability to detect the pixels</mark> <mark>belonging to the interested region of the saree.</mark> TABLE I <u>CLASSIFICATION REPORT SAREE BODY</u> Component Accuracy Precision Recall F1 BiSenetV2 83.98 85.32 82.34 83.80 DeepLabV3+ 87.45 84.65 86.87 85.74 <mark>Confusion matrix for the saree body class and the saree</mark> <mark>border class is created and performance metrics are</mark> <mark>determined separately for the 50 images by analysing the</mark> <mark>model's pixel classification. Table 1 compares the mean</mark> <mark>performance metrics calculated for the saree body with the</mark> <mark>state of the art techniques. Similarly, table 2 provides the</mark> <mark>mean performance values calculated for the saree border. The</mark> <mark>proposed method has been compared to state-of-the-art</mark> <mark>semantic segmentation techniques, namely BiSeNetV2 and</mark> <mark>DeepLabV3, in terms of accuracy, precision, recall, and F1</mark> <mark>score.</mark> <mark>Results</mark> <mark>indicate</mark> <mark>that</mark> <mark>the</mark> <mark>proposed</mark> <mark>approach</mark> <mark>outperforms the other techniques in the majority of cases with</mark> <mark>an accuracy of 89.23% for border and 93.01% for body of the</mark> <mark>saree.</mark> <mark>The performance of color customization is highly</mark> <mark>influenced by the number of dominant colors present in the</mark> <mark>saree image. Color dominance is assessed by analyzing the</mark> <mark>image's color histograms and identifying dominant peaks as</mark> <mark>representations of prominent colors. The degree of color</mark> <mark>dominance is quantified by measuring the difference in</mark> <mark>frequency between the primary peak, typically the first global</mark> <mark>maximum in the hue histogram, and other peaks, with a larger</mark> <mark>difference signifying greater color dominance. The presence</mark> <mark>of background elements and skin tones in the image can</mark> <mark>introduce additional hues, potentially leading to multiple</mark> <mark>peaks in the hue histogram. This can dilute the dominance of</mark> <mark>the saree's colors. Hence, it is necessary to remove pixels that</mark> <mark>do not belong to the saree. otherwise, such pixels act as noise</mark> <mark>and reduce the efficiency of color customization. The graph</mark> <mark>shows the variation in accuracy to change saree body color</mark> <mark>with respect to color dominance in the images with humans.</mark> <mark>From</mark> <mark>Fig.7</mark> <mark>, it can be inferred that the combined operation of</mark> <mark>MODNet, Faster R-CNN, and Mask R-CNN provides stable</mark> <mark>performance and higher accuracy in being able to change the</mark> <mark>color of the interested pixels. This accuracy in color alteration</mark> <mark>is a crucial aspect for applications requiring precise image</mark> <mark>manipulation. Mask R-CNN performs the main task of</mark> <mark>identifying pixels belonging to different parts of the saree,</mark> <mark>however, MODNet helps remove noise and Faster R-CNN</mark> <mark>helps in classifying the image based on human presence.</mark> TABLE II <u>CLASSIFICATION REPORT SAREE BORDER</u> Component Accuracy Precision Recall F1 BiSenetV2 81.21 80.83 78.55 79.67 DeepLabV3+ 86.93 82.57 84.65 83.59 proposed methodology 89.23 83.41 84.08 83.74 Proposed methodology 93.01 87.87 86.85 87.36 <mark>FIGURE.7 Accuracy vs Color Dominance</mark> Since only the hue value is modified while keeping the saturation and brightness constant, the number of attainable shades is constrained to 180. Fig . 8 presents the results of the proposed methodology for folded sarees. Fig.9 shows the results of the proposed methodology for sarees with humans. The functionality to adjust the Hue, Saturation, and Value components provides a wide range of color options, making it easier to find the most suitable color combination for the desired saree component (body or border). FIGURE 8. The resultant images of folded saree (right) obtained from running the architecture on the original images (left). FIGURE 9. The resultant images with humans wearing saree (right) obtained from running the architecture on the original images (left). <mark>V. CONCLUSION</mark> <mark>In this study, an attempt is made to automate the color-</mark> <mark>changing process of individual parts of a saree. Manually</mark> <mark>selecting the desired areas and modifying the colors using</mark> <mark>photo editors requires considerable effort and software</mark> <mark>expertise. The proposed algorithm performs the same task</mark> <mark>within nine seconds and with minimum effort from the user.</mark> <mark>This method also helps retailers visualize the same saree with</mark> <mark>different colors to decide the best color combination before</mark> <mark>manufacturing. It seeks to tap into the ocean of complex</mark> <mark>traditional designs and introduce a spark of intelligence to the</mark> <mark>current system.</mark> The methodology integrates Faster R-CNN for classification, Mask R-CNN for semantic segmentation, and HSV-based color swapping. When evaluated on 50 test images, it achieved an accuracy of 93.01% in detecting saree borders and an accuracy of 89.23% accuracy in identifying saree body regions, outperforming other state-of-the-art techniques for saree body and border detection. The effectiveness of the suggested approach diminishes when applied to images featuring unconventional postures. Enhancements could be achieved by training the model on a more expansive and diverse dataset. The proposed methodology encounters challenges when dealing with sarees that exhibit iridescence, like silk sarees. The extensive range of colors in such sarees results in a substantial loss of details when subjected to color modifications. Additionally, the methodology has the potential to expand its capabilities beyond color alteration, allowing for the incorporation of diverse patterns onto the saree. The approach suggested in this study can be expanded to encompass various types of apparel, such as blouses, pants, kurtas, and kimonos. <mark>REFERENCES</mark> [1] T. Zhang and Y. Chang, “Application of Photoshop Technology Based on Computer Graphic Design Software, 2020 IEEE International Conference on Power, Intelligent Computing and Systems (ICPICS), Shenyang, China, 461-466, 2020, doi: 10.1109/ICPICS50287.2020.9202151. [2] Basar, Sadia, Abdul Waheed, Mushtaq Ali, Saleem Zahid, Mahdi Zareei, and Rajesh Roshan Biswal. 2022. "An Efficient Defocus Blur Segmentation Scheme Based on Hybrid LTP and PCNN" Sensors 22, no. 7: 2724. https://doi.org/10.3390/s22072724 [3] S. Basar, M. Ali, G. Ochoa-Ruiz, A. Waheed, G. Rodriguez-Hernandez and M. Zareei, "A Novel Defocused Image Segmentation Method Based on PCNN and LBP," in IEEE Access, vol. 9, pp. 87219-87240, 2021, doi: 10.1109/ACCESS.2021.3084905. [4] Zhang Han Ke, Jiayu Sun, Kaican Li, Qiong Yan & Rynson W.H. Lau, MODNet: Real-Time Trimap-Free Portrait Matting via Objective Decomposition,2022, [Computer software] https://github.com/ZHKKKe/MODNet [5] F. Liu, Z. Liu, W. Liu and H. Zhao, "Combining the YOLOv5 and Grabcut Algorithms for Fashion Color Analysis of Clothing," 2022 5th World Conference on Mechanical Engineering and Intelligent Manufacturing (WCMEIM), Ma'anshan, China, 2022, pp. 1126-1129, doi: 10.1109/WCMEIM56910.2022.10021426 [6] K. He, G. Gkioxari, P. Dollár, & R. Girshick, “Mask R-CNN”. 2017 IEEE International Conference on Computer Vision (ICCV), pp 29802988,2017, doi: 10.1109/ICCV.2017.322. [7] Basar S, Ali M, Ochoa-Ruiz G, Zareei M, Waheed A, et al. (2020) Unsupervised color image segmentation: “A case of RGB histogrambased K-means clustering initialization”. PLOS ONE 15(10): e0240015. https://doi.org/10.1371/journal.pone.0240015 [8] Septiarini, A., Hamdani, H., Hatta, H. R., & Anwar, K. (2020). “Automatic image segmentation of oil palm fruits by applying the contour-based approach”. Scientia Horticulturae, 261, 108939 [9] He, W., Wang, J., Wang, L. et al. “A semantic segmentation algorithm for fashion images based on modified mask RCNN”. Multimed Tools Appl (2023),doi: 10.1007/s11042-023-14958-1 [10] Bharati, P., Pramanik, A. (2020). Deep Learning Techniques—R-CNN to Mask R-CNN: A Survey. In: Das, A., Nayak, J., Naik, B., Pati, S., Pelusi, D. (eds) Computational Intelligence in Pattern Recognition. Advances in Intelligent Systems and Computing, vol 999. Springer, Singapore,doi: 10.1007/978-981-13-9042-5_56 [11] Rubesh Hema, “Interactive Color Image Segmentation using HSV Color Space”. Science & Technology Journal, 7, 37-41.2020, doi: 10.22232/stj.2019.07.01.05. [12] Lesiangi, F. S., Mauko, A. Y., & Djahi, B. S. (2021, September). Feature extraction Hue, Saturation, Value (HSV) and Gray Level Cooccurrence Matrix (GLCM) for identification of woven fabric motifs in South Central Timor Regency. In Journal of Physics: Conference Series (Vol. 2017, No. 1, p. 012010). IOP Publishing. [13] Erkut, U., Bostancıoğlu, F., Erten, M., Özbayoğlu, A. M., & Solak, E. (2019, November). HSV color histogram-based image retrieval with background elimination. In 2019 1st International Informatics and Software Engineering Conference (UBMYK) (pp. 1-5). IEEE.,doi: 10.1007/978-3-642-14058-7_55 [14] Yao, Susu, Ishtiaq Rasool Khan, and Farzam Farbiz. "Clothing segmentation and recoloring using background subtraction and back projection method." 2011 18th IEEE International Conference on Image Processing. IEEE, 2011. [15] Cai, Shaofan Zhang, Xiaoshuai Fan, Haoqiang Huang, Haibin Liu, Jiangyu Liu, Jiaming Liu, Jiaying Wang, Jue Sun, & Jian. Disentangled Image Matting, 2019 IEEE/CVF International Conference on Computer Vision (ICCV), (pp. 8818-8827), 2019, doi: 10.1109/ICCV.2019.00891 [16] Levin, D. Lischinski, & Y. Weiss, A Closed-Form Solution to Natural Image Matting, in IEEE Transactions on Pattern Analysis and Machine Intelligence, pp. 228-242, vol.30, no.2, 2008, doi: 10.1109/TPAMI.2007.1177. [17] J.Redmon.,S. Divvala.,R. Girshick & A. Farhadi,You Only Look Once: Unified, Real-Time Object Detection .IEEE Conference on Computer Vision and Pattern Recognition 2016,779-788,2016,,doi: 10.1109/CVPR.2016.91 . [18] W. Liu., D. Anguelov., D. Erhan, C. Szegedy, S. Reed, C.Y. Fu., & A.C. Berg. Ssd: Single shot multibox detector. European conference on computer vision, 21-37. Springer, Cham, 2016, doi: 10.1007/978-3-31946448-0_2. [19] S. Ren, K. He, R. Girshick, & J. Sun, Faster R-CNN: Towards Real Time Object Detection with Region Proposal Networks. IEEE Transactions on Pattern Analysis and Machine Intelligence, pp 11371149, vol. 39, no. 6,2017, doi:10.1109/TPAMI.2016.2577031. [20] J. Long., E. Shelhamer. & T. Darrell, Fully convolutional networks for semantic segmentation. IEEE Conference on Computer Vision and Pattern Recognition (CVPR), 3431-3440,2015.,doi: 10.1109/CVPR.2015.7298965 . [21] O. Ronneberger, P. Fischer., & T. Brox, U-net: Convolutional networks for biomedical image segmentation. In International Conference on Medical image computing and computer-assisted intervention, 234-241. Springer, Cham, 2015, doi: 10.1007/978-3-319-24574-4_28. [22] X. Qin., Z. Zhang.,C. Huang., M. Dehghan,O.R. Zaiane,, & M. Jagersand, U2-Net: Going deeper with nested U-structure for salient object detection. Pattern recognition, 106, 1. 107404,2020, doi: 10.1016/j.patcog.2020.107404 [23] T. T. P. Quoc, T. T. Linh & T. N. T. Minh, Comparing U-Net Convolutional Network with Mask R-CNN in Agricultural Area Segmentation on Satellite Images, 7th NAFOSTED Conference on Information and Computer Science, 124-129, 2020, doi: 10.1109/NICS51282.2020.9335856. [24] H. Zhang, Y. Sun, L. Liu, X. Wang, L. Li, W. Liu, ClothingOut: a category-supervised GAN model for clothing segmentation and retrieval. Neural computing and applications. Vol 32(9), 4519-30,2020, doi: 10.1007/s00521-018-3691-y [25] De Souza Inácio and H. S. Lopes, "EPYNET: Efficient Pyramidal Network for Clothing Segmentation," in IEEE Access, vol. 8, pp. 187882-187892, 2020, doi: 10.1109/ACCESS.2020.3030859. [26] Fu, C.Y., Berg, T.L. and Berg, A.C., 2019. Imp: Instance mask projection for high accuracy semantic segmentation of things. In Proceedings of the IEEE/CVF International Conference on Computer Vision (pp. 5178-5187). [27] Kaihan Lin, Huimin Zhao, Jujian Lv, Canyao Li, Xiaoyong Liu, Rongjun Chen, Ruoyan Zhao, "Face Detection and Segmentation Based on Improved Mask R-CNN", Discrete Dynamics in Nature and Society, vol. 2020, Article ID 9242917, 11 pages, 2020. doi:10.1155/2020/9242917 [28] Tensorflow, TensorFlow 1 Detection Model Zoo, [Computer software] https://github.com/tensorflow/models/blob/master/research/object_detec tion/g3doc/tf1_detection_zoo.md [29] Waleed Abdulla, Mask R-CNN for object detection and instance segmentation on Keras and TensorFlow (2017), [Computer software] https://github.com/matterport/Mask_RCNN [30] Piotr Skalski, Make Sense,2019, [Computer software] https://github.com/SkalskiP/make-sense/ [31] S. B and A. P, Effect of Different Color Spaces on Deep Image Segmentation, 2021 IEEE International Women in Engineering (WIE) Conference on Electrical and Computer Engineering (WIECON-ECE), Dhaka, Bangladesh, pp. 1-4, 2021 doi: 10.1109/WIECONECE54711.2021.9829655. [32] Inoue, K., Jiang, M., & Hara, K. (2021). “Hue-preserving saturation Improvement in RGB color cube”. Journal of Imaging, 7(8), 150.,doi: 10.3390/jimaging7080150 . [33] Kurniastuti, I., Yuliati, E. N. I., Yudianto, F., & Wulan, T. D. (2022). “Determination of Hue Saturation Value (HSV) color feature in kidney histology image”. In Journal of Physics: Conference Series (Vol. 2157, No. 1, p. 012020). IOP Publishing. [34] S. C. Yurtkulu, Y. H. Şahin and G. Unal, "Semantic Segmentation with Extended DeepLabv3 Architecture," 2019 27th Signal Processing and Communications Applications Conference (SIU), Sivas, Turkey, 2019, pp. 1-4, doi: 10.1109/SIU.2019.8806244. [35] Chen, L.C., Zhu, Y., Papandreou, G., Schroff, F. and Adam, H., 2018. Encoder-decoder with atrous separable convolution for semantic image segmentation. In Proceedings of the European conference on computer vision (ECCV) (pp. 801-818). [36] Yu, C., Gao, C., Wang, J., Yu, G., Shen, C. and Sang, N., 2021. Bisenet v2: Bilateral network with guided aggregation for real-time semantic segmentation. International Journal of Computer Vision, 129, pp.30513068. NAMAN KARANTH, is currently pursuing Bachelor of Engineering in computer science and engineering from RV College of Engineering, Bengaluru. His research interests involve computer vision, machine learning and backend development. As a research intern for Reshmandi, he was involved in the development of a deep learning-based algorithm and a web application to detect and change the colors of different parts of a saree. He has also worked with microcontrollers like Raspberry Pi to architect smart traffic signaling systems ARYA ADESH is a third-year student pursuing a bachelor’s degree in Computer Science and Engineering at RVCE, India. He participated in the HPCC Systems Intern Program in 2022, where he contributed to the creation of an anomaly detection algorithm that is currently accessible through the HPCC Machine Learning Library. Additionally, He has gained experience working on various ventures related to image processing and both the frontend and backend development of databases. During his tenure as a Research Intern at Reshamandi, he successfully built a saree image segmentation Deep Learning pipeline. CHANDAN KASAMSETTY, is a highly motivated and skilled student pursuing a B.E. in Computer Science at R.V College of Engineering in Bangalore, India. In terms of professional experience, he has undertaken impactful internships that have honed his skills and expanded his knowledge. As a Project Intern at LexisNexis, He is currently involved in developing a distributed parser for the Bitcoin blockchain network using Enterprise Control Language (ECL). His role includes analyzing existing implementations in Python and C++ to improve the efficiency and functionality of the parser. Previously, as a Research Intern at Reshamandi, He developed a Deep Learning pipeline for saree image segmentation, significantly reducing the time required for editing. He designed a web interface for the pipeline using HTML, CSS, JavaScript, and the Flask framework, displaying their ability to combine technical expertise with practical application. ABHINAV SAMAGA, is an undergraduate student pursuing B.E. in Computer Science at R V College of Engineering in Bangalore, India. He is currently interning at Inferigence Quotient developing an automatic license plate recognition pipeline for the Indian scenario. He is involved in designing a multi-frame approach involving vehicle tracking, license plate detection and optical character recognition. He has worked on projects involving image processing, embedded software development and full stack development. DR. SHOBHA G, Senior member IEEE, Professor, Computer Science and Engineering Department, RV College of Engineering, Bengaluru, India have teaching experience of 27 years, her specialization includes Data mining, Machine Learning, and Image processing. She has published more than 150 papers in reputed journals / conferences. She has also executed sponsored projects worth INR 200 lakhs funded from various agencies nationally and internationally. DR. MINAL MOGARIR, IEEE and ACM Member, Professor, Computer Science and Engineering Department, RV College of Engineering, Bengaluru, India have teaching experience of 21 years, her specialization includes Computer Networks and Secuirty, Machine/Deep Learning and Image processing. Parallel Computing. She has published more than 50 papers in reputed journals / conferences. She has also executed sponsored projects worth INR 50 lakhs funded from various agencies nationally and internationally. MR. CHETAN GARG, working as Associate Staff Engineer - Data Scientist at ReshaMandi Pvt, Ltd. He is a result-oriented engineer & consultant having approx. 5.5+ years of experience in Artificial Intelligence, Machine Learning & Deep Learning. An excellent team player with positive attitude & experienced in solving real business problems with the help of AI & Data.

섹션 본문 53문단 · 28,143자

(제목 없음)

1Sarees are integral to Indian culture and serve as daily attire for most women on the subcontinent.Despite their popularity, there exists a gap in research regarding the automatic segmentation of sarees and the independent color modification of distinct components.Existing methods rely on labor-intensive manual adjustments through commercial applications, impeding productivity and resulting in avoidable expenses.This paper presents a tool that smartly coordinates different deep-learning techniques to modify the color patterns found on different parts of a saree.MODNet is applied for background removal and custom-trained Mask R-CNN models are utilized to precisely segment the saree body and border.The subsequent application of a color-changing algorithm in the HSV color space facilitates independent color modification for the saree border and body.The methodology proposed in this paper can be extended to any kind of clothing such as shirts, trousers, kurtas, kimonos, etc.An accuracy of 93.01% was achieved for the saree border segmentation, and an accuracy of 89.23% was achieved for the saree body segmentation when tested on a set of 50 test images.

I. INTRODUCTION

2The onset of artificial intelligence and machine learning has revolutionized different domains ranging from education to manufacturing.The technological void in the traditional Indian clothing sector provides research opportunities to advance automation and modernization.The saree market in particular suffers from a general shortage of innovation.This industry currently uses time-intensive image editing software like Photoshop [1] to design and visualize attire, which also demands specialized expertise.To make the process more efficient and effortless for retailers, this paper proposes a new intuitive software tool tailored to the saree market that enables easy virtual design and visualization.

3The associate editor coordinating the review of this manuscript and approving it for publication was Jeon Gwanggil .

4The saree is a traditional Indian garment that is a single piece of clothing.The horizontal ends of the cloth are ornate to form the border.The body of the saree is the main portion of the garment surrounded by the border.Currently, there are no methods employed in the saree retail or manufacturing sector for the automated detection and color customization of different elements of a saree.This paper proposes a methodology to recognize distinct elements of a saree using deep learning techniques without user intervention and to allow color customization of saree components.The suggested approach employs background removal, image segmentation, and pixel value manipulation in the HSV color space to facilitate automation.

5The background in the image is removed to eliminate the unwanted noise in the image and increase the accuracy of the segmentation.One such technique is the defocused image segmentation proposed in [2] which improves upon the PCNN and LBP frameworks [3] in terms of accuracy and efficiency.This technique relies on the blur or bokeh effects present in the image for the segmentation.On the other hand, the MODNet architecture [4] generalizes background detection to recognize background even in the absence of blur/bokeh effect, using a lightweight combination of trimap-free matting and a trimap-grounded matting step.

6The detection of the saree body and the border can be achieved utilizing state-of-the-art methods like color-based segmentation using thresholding [5], edge detection, or contour-based techniques [6].However, these methods suffer from various drawbacks, such as sensitivity to lighting conditions, manual parameter tuning, lack of robustness when dealing with overlapping designs, and reduced computational efficiency.To address these limitations, this paper employs a strategy similar to the one outlined in [7], which uses peak color pixel values for segmentation.However, this paper uses HSV to extract the highest hue values in conjunction with Mask R-CNN [9], as opposed to the k-means algorithm in [7], for improved accuracy.The HSV color space [11], [12], [13] offers a convenient method to alter the color of an image while retaining its contrast and saturation details.This paper also improves upon the technique proposed in [14] by incorporating mask R-CNN for segmentation, enabling simultaneous color changing of multiple clothing items.The contributions of this research work are:

71. Employing deep learning techniques for the automated detection of the saree components.2. Allowing simultaneous color-changing of different saree components while preserving its contrast and saturation details.

8The following section provides a brief description of the classification techniques, followed by the background removal process and its significance.Furthermore, it provides a detailed explanation of the segmentation model, covering aspects of its training and functioning.It then elucidates the mechanism of color changing along with the analysis of different color spaces.Finally, the paper concludes with the experimental results and the future scope of the study

II. RELATED WORKS

9The proposed methodology mainly consists of selecting the pixels related to different saree components and then recoloring them.To enable this, a combination of background removal technologies and semantic segmentation techniques are utilized.The HSV color space is adopted for recoloring the image.This section briefly explains the current advancements in background removal, image segmentation, and hue manipulation technologies.

A. BACKGROUND REMOVAL -MODNet

10MODNet is a lightweight combination of trimap-free matting and a trimap-grounded matting step which enhances the performance of the algorithm.Image matting and trimap-free image mapping are some of the commonly used background removal techniques.Traditional matting algorithms such as Image matting heavily rely on low-level features, such as color cues, to determine the alpha matte through sampling, which often fails in complex scenes [15].Trimap-free mapping techniques are less efficient and are computationally expensive [16].MODNet provides an efficient, lightweight, and robust pipeline for background removal that overcomes the shortcomings of the above mentioned techniques [4].

11The proposed methodology improves upon the works introduced in [5] where YOLO v5 is used along with GrabCut to isolate the foreground region.Here MODNet is used for the background removal which has an MAE of 18.1 and an IoU of 66.9, which is significantly better than the performance of GrabCut, which has an MAE of 29.3 and an IoU of 49.6 [4].Moreover, k-means may not be efficient in cases where the color of the garment matches the background color or the skin color of the person wearing it which makes it inefficient.Hence a custom Mask R-CNN model is used to remove the hands and face of the human.

12MODNet has several advantages over previous trimapfree methods.MODNet is much faster, running at 67 frames per second (fps) on a GTX 1080 Ti GPU with an input size of 512 × 512 (including data loading) [4].MOD-Net achieves state-of-the-art results on both the open-source Adobe Matting benchmark and the newly proposed PPM-100 benchmark.Moreover, MODNet can be easily optimized endto-end as it is a single model instead of a complex pipeline.Finally, MODNet has better generalization ability, due to the SOC strategy.Hence MODNet is an appropriate model for this application.

B. MASK R-CNN

13Object detection and semantic segmentation technologies are structured around Convolutional Neural Networks.These methodologies can be divided into two distinct categories: one-stage and two-stage approaches.Algorithms like YOLO [17] and SSD [18] emphasize on inference speed while compromising accuracy.Whereas Semantic image segmentation assigns a class to each of the pixels of the image.The field is dominated by models such as the Fast/Faster R-CNN [19], Fully Convolutional Networks (FCN) [20], Mask R-CNN [6], and U-net [21], [22].Mask R-CNN performs well in partitioning the image into separate objects, without combining these detected objects as a single entity, as in U-Net [23] or ClothingOut [24].

14DeepLab v3 stands as a prominent semantic segmentation model that leverages atrous convolutions to adjust filter fieldof-view and regulate feature response resolution in CNNs [34].Its evolution refines the atrous Spatial Pyramid Pooling module by integrating image-level features for enhanced global context encoding [35].

15In contrast, the Bilateral Segmentation Network (BiSeNet) [36] adopts a Spatial Path, maintaining spatial details through stacked convolutional layers, and a Context Path, efficiently utilizing global average pooling and an Attention Refinement Module (ARM) for feature learning.Combining these paths via a Feature Fusion Module, BiSeNet achieves real-time performance and high accuracy in semantic segmentation.

16Segmentation of clothes has already been achieved utilizing algorithms like SSD [25], and Mask R-CNN [26].But all these techniques focus on parsing western attire and have not been trained on parsing sarees.Extracting particular regions of interest associated with the body and border of the saree can be achieved by utilizing polygonal object detection and segmentation.

17Mask R-CNN is an appropriate choice in this scenario as object masks produced by it are required for selecting these specific pixels.Mask R-CNN improves upon the Faster R-CNN by creating a new branch for estimating segmentation masks on each Region of Interest (RoI) simultaneously along with the existing branch for classification and bounding box regression [6].

C. HSV COLOR SPACE

18A color model or color space represents a coordinate system, where each point specifies a color.In this model, every color can be described as a tuple of numbers [11].

19HSV color space is a cylindrical color space, with hue as angular dimension, beginning at 0 • as a reference, then passing through the colors Yellow, Green, Cyan, Blue, and Magenta and ending at 360 • .Saturation is the length of the vector from the origin to a particular point in the color space.The image of interest is converted to HSV because chromatic information can be extracted from the hue component and changes can be made only in that component of the color [12], [13].All three dimensions of HSV space are independent, so changes in one do not affect the others.Hue is in the range of 0 to 360 • , saturation ranges from 0 to 100%, and value is between 0 to 100%.

20A design is required for the segmentation of saree images to identify components like the body and border of the saree and then be able to modify its colors.The design proposed in this paper makes use of all the above-mentioned models for the same purpose.

21The proposed methodology offers significant advantages over the approach described in [14].In contrast to the latter, which performs background and shadow removal as separate time-consuming steps, the proposed method efficiently integrates both tasks into a single step using MODNet [4], significantly improving processing speed.Additionally, the referenced approach relies on the EM method for background parameter estimation, which can be computationally costly and time-consuming.The approach described in [14] relies on a fixed skin map (defined as H ≤ 19 and S ≥ 48).However, this fixed map can pose difficulties when sarees have hue values similar to the skin and fail to accommodate variations in skin tones.Notably, Mask R-CNN combines the steps of face and skin removal, streamlining the process when compared to the referenced approach.Haar feature-based cascade classifiers used in the referenced approach suffer from a low recognition rate [27] for face detection; hence, Mask R-CNN offers superior accuracy and versatility.The proposed approach can handle images with multiple clothing accessories, unlike [14], allowing simultaneous alteration of body and border colors even when hue values are similar.

III. PROPOSED METHODOLOGY

22The proposed tool consists of three phases: human detection, background removal, and recoloring phase as shown in Fig. 1.The first phase takes a saree image as an input and classifies it into either an image of a human draped in a saree or an image of only a saree without a human using Faster R-CNN.Background removal is performed using MODNet for images with humans.The second phase involves segmenting the saree components by removing human parts (such as the face and hands) and detecting borders using separate Mask R-CNN models.The last phase involves the color change of pixels corresponding to the saree body and the saree border, utilizing the HSV color space.Further details regarding each of the phases are provided in the following section.

A. HUMAN DETECTION AND BACKGROUND REMOVAL

23All images taken into consideration are classified based on the presence or absence of a human in the image.This is performed by a Faster-R-CNN model trained with over 1500+ images and has an accuracy of over 96% [28].It classifies images in less than 90 ms, which is significantly faster than that of other state-of-the-art models.Classification is essential because images of humans require specific processing steps, including background removal, as well as hand and face removal to eliminate their impact on color modification.

24Background removal is necessary to isolate and focus on the subject wearing a saree, reducing interference from irrelevant noise.In the proposed methodology, MODNet is used to remove background from the images.The implementation of MODNet was sourced from [4].The output of background removal using MODNet on the input image is shown in Fig 2.

B. REMOVING BODY AND DETECTING BORDER

25Custom-trained Mask R-CNN models are employed to segment the body and border of the saree in the image.The implementation of this model was sourced from [29].Two separate Mask R-CNN models are utilized for the detection of the body and border in two distinct categories of input images.The first Mask R-CNN model, customized for images containing humans, performs multi-class segmentation, segmenting three different classes: the saree body, the saree border, and the hands and face of the human subject.The Mask R-CNN model designed for images without humans, utilizes multi-class segmentation capability to simultaneously segment the saree body and border as distinct classes.The models were trained using a set of 500 images each.The images were manually annotated by using a set of polygons that demarcate the desired regions.Annotations were created using MakeSense AI [30], which is an 9588 VOLUME 12, 2024 Authorized licensed use limited to the terms of the applicable license agreement with IEEE.Restrictions apply.open-source tool used for annotating images.The model was trained with a learning rate of 0.001 and image size of 512 × 512 with batch size 4 for 15 epochs.

26In the case of images containing humans, the sequence of operations begins with background removal.Subsequently, the first Mask R-CNN model is employed to segment the hand, face, and saree border from the image.This leaves the saree body unaltered for the color-changing process.Fig. 3 illustrates the output of each step of the proposed methodology.

27In the case of saree images without humans, the second Mask R-CNN model is directly used on the input image to extract regions belonging to the body and border of the saree.The results of the two models are shown in Fig. 4.

28These extracted regions associated with the body and the border of the saree respectively are used to apply the color change.The next section describes the detection of the pixels pertaining to the body and border of the saree from these regions and the color-changing algorithm used to change them.

C. COLOR CHANGING

29Once the image's region of interest is identified, the existing color can be swapped with another color of interest.From left to right: Input image of a folded saree, saree body that is obtained after using the saree body detection model and the saree border that is obtained after using the saree border detection model.

30Swapping colors is easy if both color and intensity information are specified as separate components independent of each other.Hence, the HSV color space proves to be the right choice for this task.On the other hand, RGB space represents the color, brightness, and intensity details of an image using a combination of red, green, and blue colors.Hence, it is difficult to approximate the amount by which each component must be changed to obtain the desired color without affecting the intensity and brightness.To accomplish this, the hue value is used to change colors.Thus, color spaces such as RGB and CMY are not suitable for describing colors in the manner that humans perceive them [31].

31The HSV Color space includes Hue, Saturation, and Brightness [32].Hue represents the dominant color as perceived by the viewer.The hue is a characteristic that encodes the dominant wavelength in a mixture of wave lights.Saturation represents the amount of white light mixed with pure hue.The degree of saturation is inversely proportional to the amount of white light mixed with color.The saturation and hue describe the chromaticity of an image.

32The image is first converted from RGB to the HSV color space according to the method described in [12].Then, for each area of interest, the Hue histogram is plotted [13].The hue Histogram represents a plot between the hue value (ranging from 0 to 365) and the number of pixels with the same hue value (frequency).Fig. 5 shows the hue histogram plotted for the segmented region consisting of the body of the saree.Individual components of a saree tend to have a unique but uniform color.The dominant color in each recognized region is indicated by the peak in the hue histogram [33].The pixels within the tolerance range are changed to another value of choice.Changes made in the hue value of the pixels render no changes in saturation or value component; hence, the saree retains the contrast and saturation details of the original image.The clothing map is calculated according to the following equation

33S mask represents the set of pixels detected by Mask R-CNN, p max is the mode of Hue values of all pixels belonging to the set, v is the variance, and h(i, j) is the hue of the pixel at a particular coordinate {i, j}.

IV. RESULTS AND PERFORMANCE EVALUATION

34A test set was prepared consisting of 50 images showcasing different saree varieties.The test set was meticulously annotated using the MakeSenseAI annotation tool to distinguish between two class entities: the body and the border.The annotations function as the ground truth labels against which the results of the proposed methodology are assessed and compared.Subsequently, the test set was processed using the proposed software tool, which identified pixels belonging to the body and border categories.The pixel classification obtained from the tool was then compared with the manual annotations for validation.The confusion matrix is used to assess the model's ability to detect the pixels belonging to the interested region of the saree.Confusion matrix for the saree body class and the saree border class is created and performance metrics are determined separately for the 50 images by analysing the model's pixel classification.Table 1 compares the mean performance metrics calculated for the saree body with the state-ofthe-art techniques.Similarly, table 2 provides the mean performance values calculated for the saree border.The proposed method has been compared with state-of-the-art semantic segmentation techniques, namely BiSeNetV2 and DeepLabV3, in terms of accuracy, precision, recall, and F1 score.Results indicate that the proposed approach outperforms the other techniques in the majority of cases with an accuracy of 89.23% for border and 93.01%for body of the saree.

35The performance of color customization is highly influenced by the number of dominant colors present in the saree image.Color dominance is assessed by analyzing the image's color histograms and identifying dominant peaks as representations of prominent colors.The degree of color dominance is quantified by measuring the difference in frequency between the primary peak, typically the first global maximum in the hue histogram, and other peaks, with a larger difference signifying greater color dominance.The presence of background elements and skin tones in the image can introduce additional hues, potentially leading to multiple peaks in the hue histogram.This can dilute the dominance of the saree's colors.Hence, it is necessary to remove pixels that do not belong to the saree.otherwise, such pixels act as noise and reduce the efficiency of color customization.The graph shows the variation in accuracy to change saree body color with respect to color dominance in the images with humans.From Fig. 6, it can be inferred that the combined operation of MODNet, Faster R-CNN, and Mask R-CNN provides stable performance and higher accuracy in being able to change the color of the interested pixels.This accuracy in color alteration is a crucial aspect for applications requiring precise image manipulation.Mask R-CNN performs the main task of identifying pixels belonging to different parts of the saree, however, MODNet helps remove noise and Faster R-CNN helps in classifying the image based on human presence.

36Since only the hue value is modified while keeping the saturation and brightness constant, the number of attainable shades is constrained to 180.Fig. 7 presents the results of the proposed methodology for folded sarees.Fig. 8 shows the results of the proposed methodology for sarees with humans.The functionality to adjust the Hue, Saturation, and Value components provides a wide range of color options, making it easier to find the most suitable color combination for the desired saree component (body or border).

V. CONCLUSION

37In this study, an attempt is made to automate the color-changing process of individual parts of a saree.Manually selecting the desired areas and modifying the colors using photo editors requires considerable effort and software expertise.The proposed algorithm performs the same task within nine seconds and with minimum effort from the user.This method also helps retailers visualize the same saree with different colors to decide the best color combination before manufacturing.It seeks to tap into the ocean of complex traditional designs and introduce a spark of intelligence to the current system.

38The methodology integrates Faster R-CNN for classification, Mask R-CNN for semantic segmentation, and HSV-based color swapping.When evaluated on 50 test images, it achieved an accuracy of 93.01% in detecting saree borders and an accuracy of 89.23% accuracy in identifying saree body regions, outperforming other state-of-the-art techniques for saree body and border detection.

39The effectiveness of the suggested approach diminishes when applied to images featuring unconventional postures.

40Enhancements could be achieved by training the model on a more expansive and diverse dataset.The proposed methodology encounters challenges when dealing with sarees that exhibit iridescence, like silk sarees.The extensive range of colors in such sarees results in a substantial loss of details when subjected to color modifications.Additionally, the methodology has the potential to expand its capabilities beyond color alteration, allowing for the incorporation of diverse patterns onto the saree.The approach suggested in this study can be expanded to encompass various types of apparel, such as blouses, pants, kurtas, and kimonos.CHANDAN KASAMSETTY is currently pursuing the B.E. degree in computer science with the R. V. College of Engineering, Bengaluru, India.In terms of professional experience, he has undertaken impactful internships that have honed his skills and expanded his knowledge.As a Project Intern with LexisNexis.He is also involved in developing a distributed parser for the bitcoin blockchain network using enterprise control language (ECL).His role includes analyzing existing implementations in Python and C++ to improve the efficiency and functionality of the parser.Previously, he was as a Research Intern with ReshaMandi.He developed a deep learning pipeline for saree image segmentation and significantly reducing the time required for editing.He designed a web interface for the pipeline using HTML, CSS, JavaScript, and the flask framework, displaying their ability to combine technical expertise with practical application.

41ABHINAV SAMAGA is currently pursuing the B.E. degree in computer science with the R. V. College of Engineering, Bengaluru, India.He is also interning with Inferigence Quotient developing an automatic license plate recognition pipeline for the Indian scenario.He is involved in designing a multi-frame approach involving vehicle tracking, license plate detection, and optical character recognition.He has worked on projects involving image processing, embedded software development, and full stack development.

FIGURE 1 .

42FIGURE 1. Block diagram of the proposed architecture.

FIGURE 2 .

43FIGURE 2. Background removal using MODNet.

FIGURE 3 .

44FIGURE 3. Different stages of using mask R-CNN.

FIGURE 4 .

45FIGURE 4.From left to right: Input image of a folded saree, saree body that is obtained after using the saree body detection model and the saree border that is obtained after using the saree border detection model.

FIGURE 5 .

46FIGURE 5. Hue histogram of the segmented region.

FIGURE 6 .

47FIGURE 6. Accuracy vs color dominance.

FIGURE 7 .

48FIGURE 7. The resultant images of folded saree (right) obtained from running the architecture on the original images (left).

FIGURE 8 .

49FIGURE 8.The resultant images with humans wearing saree (right) obtained from running the architecture on the original images (left).

50NAMAN KARANTH is currently pursuing the Bachelor of Engineering degree in computer science and engineering from the R. V. College of Engineering, Bengaluru.His research interests include computer vision, machine learning, and backend development.As a Research Intern with ReshaMandi, he was involved in the development of a deep learning-based algorithm and a web application to detect and change the colors of different parts of a saree.He has also worked with microcontrollers like Raspberry Pi to architect smart traffic signaling systems.ARYA ADESH is currently pursuing the bachelor's degree in computer science and engineering with the R. V. College of Engineering (RVCE), India.He participated in the HPCC Systems Intern Program, in 2022, where he contributed to the creation of an anomaly detection algorithm that is currently accessible through the HPCC Machine Learning Library.Additionally, he has gained experience working on various ventures related to image processing and frontend and backend development.During his tenure as a Research Intern with ReshaMandi, he successfully built a saree image segmentation deep learning pipeline.

51G. SHOBHA (Senior Member, IEEE) is currently a Professor with the Computer Science and Engineering Department, R. V. College of Engineering, Bengaluru, India, have teaching experience of 27 years, her specialization includes data mining, machine learning, and image processing.She has published more than 150 papers in reputed journals/conferences.She has also executed sponsored projects worth INR 200 lakhs funded from various agencies and internationally.MINAL MOHARIR (Member, IEEE) is currently a Professor with the Computer Science and Engineering Department, R. V. College of Engineering, Bengaluru, India, have teaching experience of 21 years, her specialization includes computer networks and security, machine/deep learning and image processing, and parallel computing.She has published more than 50 papers in reputed journals/conferences.She has also executed sponsored projects worth INR 50 lakhs funded from various agencies nationally and internationally.She is also a member of ACM.CHETAN GARG is currently an Associate Staff Engineer-Data Scientist with ReshaMandi Private Ltd.He is also a Result-Oriented Engineer and a Consultant having approximately more than five and half years of experience in artificial intelligence, machine learning, and deep learning.An excellent team player with positive attitude and experienced in solving real business problems with the help of AI and data.

TABLE 1 .

52Classification report saree body.

TABLE 2 .

53Classification report saree border.

참고문헌 32건

  1. U-Net: Convolutional Networks for Biomedical Image Segmentation Lecture notes in computer science · Springer Science+Business Media · 2015 10.1007/978-3-319-24574-4_28
  2. Fully convolutional networks for semantic segmentation 2015 10.1109/cvpr.2015.7298965
  3. A Closed-Form Solution to Natural Image Matting IEEE Transactions on Pattern Analysis and Machine Intelligence · IEEE Computer Society · 2007 10.1109/tpami.2007.1177
  4. Clothing segmentation and recoloring using background subtraction and back projection method 2011 10.1109/icip.2011.6116331
  5. ClothingOut: a category-supervised GAN model for clothing segmentation and retrieval Neural Computing and Applications · Springer Science+Business Media · 2018 10.1007/s00521-018-3691-y
  6. You Only Look Once: Unified, Real-Time Object Detection 2016 10.1109/cvpr.2016.91
  7. Mask R-CNN 2017 10.1109/iccv.2017.322
  8. Encoder-Decoder with Atrous Separable Convolution for Semantic Image Segmentation Lecture notes in computer science · Springer Science+Business Media · 2018 10.1007/978-3-030-01234-2_49
  9. Deep Learning Techniques—R-CNN to Mask R-CNN: A Survey Advances in intelligent systems and computing · Springer Nature · 2019 10.1007/978-981-13-9042-5_56
  10. Semantic Segmentation with Extended DeepLabv3 Architecture 2019 10.1109/siu.2019.8806244
  11. Disentangled Image Matting 2021 IEEE/CVF International Conference on Computer Vision (ICCV) · 2019 10.1109/iccv.2019.00891
  12. Automatic image segmentation of oil palm fruits by applying the contour-based approach Scientia Horticulturae · Elsevier BV · 2019 10.1016/j.scienta.2019.108939
  13. IMP: Instance Mask Projection for High Accuracy Semantic Segmentation of Things 2021 IEEE/CVF International Conference on Computer Vision (ICCV) · 2019 10.1109/iccv.2019.00528
  14. HSV Color Histogram Based Image Retrieval with Background Elimination 2019 1st International Informatics and Software Engineering Conference (UBMYK) · 2019 10.1109/ubmyk48245.2019.8965513
  15. Face Detection and Segmentation Based on Improved Mask R-CNN Discrete Dynamics in Nature and Society · Hindawi Publishing Corporation · 2020 10.1155/2020/9242917
  16. U2-Net: Going deeper with nested U-structure for salient object detection Pattern Recognition · Elsevier BV · 2020 10.1016/j.patcog.2020.107404
  17. Application of Photoshop Technology Based on Computer Graphic Design Software 2020 IEEE International Conference on Power, Intelligent Computing and Systems (ICPICS) · 2020 10.1109/icpics50287.2020.9202151
  18. Unsupervised color image segmentation: A case of RGB histogram based K-means clustering initialization PLoS ONE · Public Library of Science · 2020 10.1371/journal.pone.0240015
  19. EPYNET: Efficient Pyramidal Network for Clothing Segmentation IEEE Access · Institute of Electrical and Electronics Engineers · 2020 10.1109/access.2020.3030859
  20. SSD: Single Shot MultiBox Detector Lecture notes in computer science · Springer Science+Business Media · 2016 10.1007/978-3-319-46448-0_2
  21. Interactive Color Image Segmentation using HSV Color Space Science & Technology Journal · Mizoram University · 2019 10.22232/stj.2019.07.01.05
  22. Comparing U-Net Convolutional Network with Mask R-CNN in Agricultural Area Segmentation on Satellite Images 2021 8th NAFOSTED Conference on Information and Computer Science (NICS) · 2020 10.1109/nics51282.2020.9335856
  23. A Novel Defocused Image Segmentation Method Based on PCNN and LBP IEEE Access · Institute of Electrical and Electronics Engineers · 2021 10.1109/access.2021.3084905
  24. Hue-Preserving Saturation Improvement in RGB Color Cube Journal of Imaging · Multidisciplinary Digital Publishing Institute · 2021 10.3390/jimaging7080150
  25. BiSeNet V2: Bilateral Network with Guided Aggregation for Real-Time Semantic Segmentation International Journal of Computer Vision · Springer Science+Business Media · 2021 10.1007/s11263-021-01515-2
  26. Feature extraction Hue, Saturation, Value (HSV) and Gray Level Cooccurrence Matrix (GLCM) for identification of woven fabric motifs in South Central Timor Regency Journal of Physics Conference Series · IOP Publishing · 2021 10.1088/1742-6596/2017/1/012010
  27. Determination of Hue Saturation Value (HSV) color feature in kidney histology image Journal of Physics Conference Series · IOP Publishing · 2022 10.1088/1742-6596/2157/1/012020
  28. An Efficient Defocus Blur Segmentation Scheme Based on Hybrid LTP and PCNN Sensors · Multidisciplinary Digital Publishing Institute · 2022 10.3390/s22072724
  29. MODNet: Real-Time Trimap-Free Portrait Matting via Objective Decomposition Proceedings of the AAAI Conference on Artificial Intelligence · Association for the Advancement of Artificial Intelligence · 2022 10.1609/aaai.v36i1.19999
  30. Combining the YOLOv5 and Grabcut Algorithms for Fashion Color Analysis of Clothing 2022 5th World Conference on Mechanical Engineering and Intelligent Manufacturing (WCMEIM) · 2022 10.1109/wcmeim56910.2022.10021426
  31. A semantic segmentation algorithm for fashion images based on modified mask RCNN Multimedia Tools and Applications · Springer Science+Business Media · 2023 10.1007/s11042-023-14958-1
  32. Faster R-CNN: Towards Real-Time Object Detection with Region Proposal Networks IEEE Transactions on Pattern Analysis and Machine Intelligence · IEEE Computer Society · 2016 10.1109/tpami.2016.2577031