# Fabric Weave Pattern and Yarn Color Recognition and Classification Using a Deep ELM Network
## 3 Experiments  
Three groups of experiments were performed on the entire datasets, to show the novelty and advantage of our proposed model over existing algorithms. The dataset images used for all our experiments were customly built according to the experimental design; in other words, there is no standard benchmark dataset for our problem. The first experiment is to test the algorithm for recognizing changes in fabric texture type, we used four classes of texture types in our experiment, namely, plain, horizontal stripes, vertical stripes, and check textures. We gathered images for different texture types and arranged them in different class categories, with each class category representing a unique texture type (shown in Figure 4 as Experiment 1). As a second test, we performed a test to determine the recognition accuracy of the algorithm for recognizing different yarn colors. We arranged the fabric images in different class categories, with each class category representing a unique yarn color (shown in Figure 4 as Experiment 2). As a final test, we evaluated the recognition accuracy of the proposed algorithm for a change in fabric texture type and yarn color simultaneously. Therefore, for this test, we created different class categories such that each class represents a unique fabric texture type and yarn color (shown in Figure 4 as Experiment 3). It is very important to understand the arrangement of the different classes in the dataset for the three experiments (see Figure 4 for details).  
The images in our dataset with several color and texture features of different fabrics were re-organized to form classes in different arrangements to perform different experiments, as explained earlier, with the help of Figure 4. Moreover, the images in every class category consist of several fabric images with similar features belonging to the same class to capture \"feature invariance\". This can be seen in Figure 5, where four class categories are shown for an experiment (see Experiment 3 shown in Figure 4) to test the algorithm for fabric recognition. In this image, class I represents fabric images with horizontal stripes and different colors, class II represents fabric images with check patterns, whereas class III represents plain fabric images with different colors. A set of images similar to those shown in Figure 5 are used to create a collection of images arranged in different classes to capture feature invariance and to perform a recognition test of the algorithm for different weave patterns and different yarn colors.  
The method is applied to 400 images, divided into four class categories. In each class category, there were a total of 100 images. The training images and the testing images were selected from the dataset images using k-fold cross-validation method (for k = 10, 20, and 25), in order to train and test the developed algorithm over the entire image set. The entire dataset is divided into N/k segments, where N is the number of images in the dataset. Each segment is used for testing turn by turn, and the remaining segments are used for training in each turn. Finally the results are averaged together to  
Figure 4: Illustration example of the custom-built dataset images with four classes for each test.  
The software package used for the implementation of the feature extraction and classification modules was MATLAB 2014a developed by Mathworks (Natick, MA, USA) used on Microsoft Windows 7 operating system. The images used for all the experiments, were of a moderate resolution of up to 500 \(\times\) 500 px, in JPEG format.  
The recognition performance of the algorithm was evaluated according to the statistical criteria as follows:  
\[\text{classification accuracy}\ =\ \frac{\text{number of correct classifications}}{\text{total number of testing images}} \tag{7}\]