Global and Local Characterization of Rock Classification by Gabor and DCT Filters with a Color Texture Descriptor

—In the automatic classification of colored natural textures, the idea of proposing methods that reflect human perception arouses the enthusiasm of researchers in the field of image processing and computer vision. Therefore, the color space and the methods of analysis of color and texture, must be discriminating to correspond to the human vision. Rock images are a typical example of natural images and their analysis is of major importance in the rock industry. In this paper, we combine the statistical (Local Binary Pattern (LBP) with Hue Saturation Value (HSV) and Red Green Blue (RGB) color spaces fusion) and frequency (Gabor filter and Discrete Cosine Transform (DCT)) descriptors named respectively Gabor Adjacent Local Binary Pattern Color Space Fusion (G-ALBPCSF) and DCT Adjacent Local Binary Pattern Color Space Fusion (D-ALBPCSF) for the extraction of visual textural and colorimetric features from direct view images of rocks. The textural images from the two G-ALBPCSF and D-ALBPCSF approaches are evaluated through similarity metrics such as Chi2 and the intersection of histograms that we have adapted to color histograms. The results obtained allowed us to highlight the discrimination of the rock classes. The proposed extraction method provides better classification results for various direct view rock texture images. Then it is validated by a confusion matrix giving a low error rate of 0.8% of classification.


I. INTRODUCTION
In general, the classification and characterization of rocks are done visually following a long process by geologists and mineralogists with many years of experience or through by laboratory tests [1].Therefore, this so-called manual classification takes time and seems approximate and subjective.However, the automatic classification of rocks could be beneficial and bridge this gap.Today, the analysis and automatic classification of color textures has become one of the areas of active search for shape recognition and computer vision.Several fields of application are covered; let us mention: biomedical [2], facial recognition [3], classification of rocks [4][5][6][7][8][9][10][11][12][13][14].The automatic classification of rocks is a challenge in the field of image processing with an interest in geologists, universities and specific schools that study rocks and also these applications in construction (roads, buildings, monuments).This is mainly related to the complex nature of the rocks that make those natural textures are not homogeneous, directional natural textures with very different granularity and color properties, making their classification very difficult.In this classification, the physiological perception of texture and color is very important.Therefore, the color space and texture / color analysis methods to be used, must be chosen to match human vision.A good classification always starts from discriminating methods of extraction of texture / color characteristics that are robust to noise, rotation and change of illumination.Typically, the feature extraction process for texture analysis involves statistical, structural, and multiscale methods.However, statistical and multiscale (frequency) approaches for feature extraction are becoming more popular using co-occurrence matrices, histograms, Gabor filters, and various LBP enhancements with exponential use for facial detection [3].All these characteristics are derived from the measurement of attributes such as energy, contrast, entropy.Then, they are used by various classification and indexing algorithms such as K nearest neighbors (K-NN) [5,8], Boosting algorithms (LPBoosting) [6], Support Vector Machine (SVM) [7,9], Artificial Neural Networks (ANN) [8,10], Maximum Likelihood (MV) [11] and K-means [21] to result in a better classification.In general, the extraction techniques focus on three forms of analysis of visual attribute: spectral analysis, radiometric analysis and textural analysis in the joint or separate use of color and texture.In [10], Ishikawa and Virginia in 2013, based on these visual attributes (texture and color) and Raman spectroscopy, were able to differentiate minerals in igneous rocks from networks of neurons through the analyze of spectral signature of minerals.However, although the classification of minerals has been largely successful, it is difficult to apply the same methods to all rocks because the spectra may have a combination of signature concurrent.In addition, some minerals that were underrepresented with their method, were well identified with radiometric and textural analyzes.In [12], Blake et al. (2012), using X-ray diffraction, required rock samples to be collected and pulverized before chemical analysis.In [9], Galdames et www.ijacsa.thesai.orgal. (2017), based on a textural and colorimetric analysis with 3D Laser Range-based features, made a lithological classification to determine the approximate mineralogical composition of rocks.A method for identifying the texture of different basalts in RGB or grayscale images using neural networks has been introduced by Singh et al. (2010) [13].In [7], Bianconi et al. (2012) presented a classification system for granite tiles incorporating textural and color features.They tested different characteristics and the best performance was obtained with the co-occurrence matrices.A method for classifying limestone types using features based on color image histograms and a probabilistic neural network has been introduced in [14].Lepisto et al. (2005) [5], succeeded in classifying rocks with textural and colorimetric analysis of visual attributes by applying Gabor filters in different color channels independently.In this study, it has been shown that it is possible to improve the classification of natural rock images by combining the color information with the description of the texture.It is known that rock images are rich in texture and color information.Despite these cited works, the classification of rock texture images remains a real challenge for the image processing scientific community.In recent times, the texture analysis community has developed a variety of different descriptors for the effective capture of textural information for representation and analysis.Local Binary Pattern (LBP) [15] is one of the best texture descriptors for extracting local texture information and has been used in various applications such as face recognition [3] and rock classification [ 4].In [4], the performance of LBP, Coordinated Cluster Representation (CCR) and Improved Local Binary Pattern (ILBP) are measured for the classification of granite textures by evaluating the robustness against the rotation of these different LBP descriptors.In 2003, Lepisto et al [16] improved the classification result with the application of K-NN by combining the color information in the HSI space and the extraction of the texture of the rocks by the Gabor filters.The HSI space proved better for this study.Over the past decade, various original LBP extensions have been proposed for classification performance.Attention has been focused on Gabor filters and the LBP operator fusion.Thus Zhang et al. [17] introduced the Local Gabor-based Binary Pattern Histogram Sequence (LGBPHS) by combining LBP and Gabor to enhance the discriminative capacity of LBP descriptors.For the same reasons, Shan et al. [18] proposed Local Gabor Binary Patterns (LGBP) in face recognition.In 2013, Zhihua Xie in [19] showed that integrating global and local characteristics into facial recognition improved performance by comparing the DCT method to the new LGBPH classification method.However, these texture representation methods [17][18][19] do not consider, on the one hand, the color information in the texture and, on the other hand, its spatial representation in the texture and until now have not yet has been applied to our knowledge to the textures of rock direct view images.To overcome these problems, we propose in this paper two new color texture descriptors that consists in extending LBP color (ALBPCSF) [20] to Gabor Adjacent Local Binary Pattern Color Space Fusion (G-ALBPCSF) by introducing before and impressively the filtering multi-orientation and multi-scale Gabor.And then the DCT Adjacent Local Binary Pattern Color Space Fusion (D-ALBPCSF) compared to the color LBP considering spatial structure relationships and color characteristics.This paper is organized as follows.Section II refers to previous work on LBP and its merger with Gabor.In section III, we will present the proposed new approach.Finally, the experimental results obtained by the two strategies of our new approach are compared to the different methods used.In section IV, our results will be discussed, and then we end with section V with the conclusion and the perspectives.

II. PREVIOUS WORK ON THE LBP AND ITS MERGER WITH GABOR
In this section, a summary of the LBP algorithms is first presented as well as its merger with Gabor.

A. Brief Review of Original LBP
A common strategy for detecting textures in images is to consider local patches that describe the behavior of the texture around a group of pixels.One of the descriptors that follows this strategy is the LBP descriptor.The LBP operator introduced by Ojala et al. [22] is an effective element of texture description with its discriminating power and simplicity of calculation.As shown in Fig. 1, the operator labels the pixels of an image with decimal numbers, called local bit patterns or LBP codes, which encodes the local structure around each central pixel defined as the threshold for the 3x3 neighborhood.Then each pixel is compared to its eight neighbors by subtracting the value of the central pixel from that of each of these neighbors.The resulting strictly negative values are coded with 0 and the others with 1. Finally, a binary number is obtained by concatenating all the pixels in the direction of the hand of a watch.The decimal value is used for labeling.This process can be expressed mathematically as follows: 0 where c p is the gray value of the central pixel, i p is the gray value of the neighboring pixels, P is the number of neighboring pixels on the circle, R is the radius of the neighborhood circle.
Then primitive extensions considering neighborhoods of different sizes, use of circular neighborhoods, bilinear interpolation of pixel values, and use of uniform patterns are used to estimate pixels that are not exactly in the center pixels:   After completing this coding step for the LBP operators, the histogram of these two variants can be created based on the following equation: where i is the gray level number i, i H is the number of pixels in the image with i as the gray level and n is the number of different labels produced by the LBP operators.Other extensions and variants of the LBP operator followed (see Fig. 2) one another with better performances in the extraction of textures, especially for the classification of facial images but will not be treated in this article.However, an exhaustive review of these LBP color and grayscale descriptors is done in [23,24] for all readers interested in this descriptor which has gained an exponential popularity over the past ten years [2-4, 9, 15, 17 -20, 23, 24].

B. Gabor Filter Combined with LBP
To increase the applicability of the LBP operator, modifications of it have been proposed.For example, Zhang et al. [17] proposed the extraction of LBP characteristics from images obtained by filtering a facial image with 40 Gabor filters at different scales and orientations with remarkable results.In [9], the LBP operator was computed on color texture images transformed into the HSV color space after applying Gabor filters on each of the three channels independently.In this same logic, we merge the two RGB and HSV color spaces by putting in the first line the relation between the spatial structure and the color characteristics as in [20].

III. PROPOSED APPROACHES
Inspired in part by the remarkable achievements obtained by combining Gabor's features with the LBP operator, we propose in this paper two new feature extraction algorithms, the first of which is named Gabor Adjacent Local Binary Pattern color space Fusion (G-ALBPCSF) and the second DCT Adjacent Local Binary Pattern Color Space Fusion (D-ALBPCSF).Indeed, the main interest of the combination of the first strategy, that is G-ALBPCSF compared to the original LBP lies in its ability to model the local characteristics of various orientations and scales provided by the transformation of Gabor and the likely consideration of color information.In G-ALBPCSF, the LBP operator applied on the different channels of the RGB and HSV color spaces, is built on the amplitudes of the Gabor filtered image rather than on the intensity of the original image.This coding makes it possible to exploit multi-resolution information and multi-orientations between the pixels, while being robust to the changes of illuminations.Then the second strategy named D_ALBPCSF, another extraction algorithm that combines the characteristics of the DCT and those of LBPcolor (ALBPCSF) to extract the capital information from the rocks.

A. Extraction of Characteristics by Gabor Filters
Gabor multi-resolution and multi-scale filters are frequency filters, located in space and with orientations convenient for the extraction and detection of contours.They are applied for decomposing input images for the sequential extraction of characteristics by changing two characteristic parameters that are: frequency and orientation.The Gabor filters for calculating quantities such as amplitude and phase [9] are defined by equation (3): The Gabor transformation is a complex function, and can be separated into amplitude (5) www.ijacsa.thesai.orgEquation ( 5) is a complex representation of the Gabor transformation of the image and from this transformation a feature vector is created (amplitude, phase).

   
, , , , It should be remembered that since the information phase varies over time (therefore very sensitive), in general, only the amplitude is explored.Thus, for each Gabor filter, an amplitude value is calculated at each position of the pixel, giving a total of 40 amplitudes corresponding to 5 scales and 8 orientations.Fig. 3 shows an image of granite and other images of the same size called Gabor images whose characteristics: amplitude and phase were extracted for two wavelengths and four orientations (16 Gabor images of which 4 are identical so 12 have been represented).
These images clearly show, on the one hand, that the texture information is perceptible and better represented in the Gabor amplitude images, and on the other hand they show that whatever the orientation and / or the scale, the granularity and the structure remain the most important elements and differ significantly from those shown by LBP images (Fig. 3).However, we summarize that Gabor filters transform a given image in only three directions: vertical (0 ° or 180 °), horizontal (90 °) and diagonal (45 ° and 135 °).

B. Extraction of Characteristics by ALBPCSF
To improve the information in the amplitudes, we code the values of the amplitudes of Gabor by the operator ALBPCSF.In G-ALBPCSF, the ALBPCSF operator is driven on the amplitudes produced by the multi-resolution and multi-scale Gabor filters rather than on the intensities of the original images.The LBP operator uses the comparison between the central pixel and its eight neighbors in a 3 * 3 neighbor and their combination with the Gabor images thus exploiting the links between the pixels for several resolutions and orientations has proved to be very robust to enlightenment and change of scale [17].Fig. 5 illustrates this combination well.It shows the application of ALBPCSF on five Gabor amplitude images for two different frequencies (λ = 4 for the images of the first line and λ = 8 for the images of the second line) and five orientations.Fig. 4 shows that the Gabor filters are more informative in the diagonal direction (45° and 135°) and confirms the directional structure of the studied rock.

C. Combination of ALBPCSF with DCT for Extraction of Characteristics
Discrete Cosine Transform (DCT) is a popular technique for imaging and compressing still images and video that transforms spatial representation signals into a frequency representation.As we know, a large amount of information about the original image is stored in a relatively small number of coefficients (in the upper left corresponding to the DCT components at low spatial frequencies of the image) in the image center of Fig. 5.This region contains most of the information, energy, and useful features of the image.For a digital image ( , ) f x y of resolution MN  , its two-dimensional DCT is defined as follows [19]: 0,1, 2,....., 1; 0,1, 2,....., 1; Where, x and y are the spatial coordinates of the pixels of the image; i and j are the coordinates of the DCT coefficients of the pixels.  , A i j is the result of the DCT.    a i and a j is defined as follows: www.ijacsa.thesai.org  However, the performances of the DCT or the LBP taken independently show some insufficient.In [19], the combination of DCT with LGBPH on an ENT database showed better results compared to LGBPH applied alone.In this section, we propose a new algorithm for extracting rock texture features named D-ALBPCSF by combining the DCT and ALBPCSF to consider the color information in addition to the advantages already mentioned above.First, the DCT is performed on direct images of rock.Then we select some useful low frequency DCT coefficients to extract the overall characteristics of the rock texture images.In addition, the LBPcolor operator (more precisely ALBPCSF) is executed on these DCT characteristics of rock textures to now extract the local characteristics with high frequencies (see image on the far right in Fig. 5 above).As we know, the analysis of the existing has shown that using a combination of several classifiers of different types can improve the performance of the classification [5].Indeed, descriptors based on global characteristics can contribute to a discriminant capacity complementary to descriptors based on local characteristics in the recognition of rocks [9].

IV. EXPERIMENTAL RESULTS AND DISCUSSION
In this section we will analyze and comment on the results of our experiments.The selected direct view rock images shown in Fig. 6 below are images from our designed database.This database contains 160 images of magmatic and metamorphic rocks textures.These images have been grouped into eight classes (from class 1 to class 8).These 256x256 resolution images, encoded on eight bits by colorimetric component, present textures that are not homogeneous and often show significant differences in directionality, granularity and color within a given class.Thanks to these texture and color characteristics, the original images were subjectively grouped into eight classes by a geology expert.

A. Averages and Standard Deviation of Gabor and DCT Coefficients
In our study, because of the directionality present in the rock textures, the Gabor filters were applied on these textures.Then, first-order (mean), second-order (standard deviation) were computed on Gabor amplitudes and DCT coefficients, then those of Gabor and DCT combined with ALBPCSF in the different channels.color.Indeed, the calculated average characterizes the luminous intensity of the energies in the image whereas the standard deviation characterizes the variation of the average intensity of all the pixels and corresponds to the changes of contrast of the image.The results are recorded in the tables below.
The analysis of the statistical characteristics used in this work such as average and the standard deviation of the DCT coefficients and Gabor amplitudes for an orientation and a scale (lambda = 4, theta = 135°) indicated in Tables I to VIII shows that magmatic rocks have higher intensity rate than metamorphic rocks.These high intensity rate in magmatic rocks indicate that these rocks have a grainy texture and crystallize at higher temperatures and pressures than metamorphic rocks.Magmatic rocks are characterized by strong energies.However, shale, eclogite, and corneal metamorphic rocks have intensities comparable to those of magmatic rocks when DCT coefficients and Gabor amplitudes are used individually, indicating a lack of such approaches.However, the analysis of the means and the standard deviations of the G-ALBPCSF and D-ALBPCSF coefficients calculated from the combinations of the approaches for these same rocks show a good categorization of the rocks:  Magmatic rocks with higher intensity rate  Metamorphic rocks with lower intensity rate than those of magmatic rocks.
These analyzes show that the approach combinations D-ALBPCSF and G-ALBPCSF make it possible to better categorize the rocks, unlike the information with Gabor and DCT taken individually.However, the reflection that this raise is up to what threshold value or limit, we can consider that the average characteristics corresponds to that of a rock belonging to a given class?

B. Comparison D-ALBPCSF and G-ALBPCSF based on the Measurements of Similarity of Intersection of Histograms and chi 2
There are several frequently used metrics for measuring similarity between two histograms for comparing textures.These metrics calculate the distance between the characteristic vectors.In this study, we use the intersection of the histograms and the distance of the Chi 2 defined respectively in equations ( 8) and ( 9) below and will allow to compare the efficiency of these two types of characteristics described in Section 3 a little higher.( (1), ( 2)) 1 min( ( 1), ( 2)) ( (2)) ( ( 1), ( 2)) (9) ( (1) (2)) ( (1), ( 2)) 1 min( ( 1), ( 2)) ( (2)) ( ( 1), ( 2)) (9) ( (1) (2)) where i h are the histograms of the samples of the images of the rocks to be compared.Rock samples can be said to be similar by matching their characteristic histograms (color and / or texture) and when the value obtained is closer to 0 if not there is no similarity.The same process is followed for Chi2.
The results with both metrics show good trends with very low values with the χ2.Values between 0 and 1 show that the histograms have been normalized.However, the HI and χ2 applications have better results in terms of similarity between the rocks with the combination D-ALBPCSF compared to G-ALBPCSF and the other methods used.This shows that the characteristics extracted by the DCT are practically common to all rocks of the same class and show a strong correlation between the rocks of the same class.Tables IX and X show the results of these first experiments.
In this work, we will manly exploit he intersection metric of the histograms with the LBP and D_ALBPCSF approaches given that these approaches make it easier to appreciate the similarity with respect to G_ALBPCSF (see Tables XI and  XII).
The analysis of these two methods shows that some metamorphic rocks (migmatite, eclogite, cornea, ...) are like each other and to some magmatic rocks (granite, gabbro, ...).This can be justified by the fact that they have magmatic origins since genesis as it is the case for eclogite for example.The G-ALBPCSF strategy will be especially exploited in our future work.The results are shown in Fig. 7.
where VP: True Positive, FP: False Positive; VN: True Negative; FN: False Negative.Here the definitions of the terms assume that one rock is like another if the value of the intersection of their histogram is the lowest.As a result, a true positive is a rock that belongs to a class and whose average value of the histogram intersections is the smallest.The false positive is a rock that does not belong to a class but has the average value of the smallest inter-sections of histograms.The false negative is a rock that does not belong to a class and does not have the smallest average value of the histogram intersections.The true negative is a non-class rock that does not have the smallest value of the histogram intersections.
Both methods give similar performance at first sight from a general analysis of performance indicators such as sensitivity, specificity and accuracy.However, with a misclassification rate of almost 8% with both the LBP and D_ALBPCSF methods for the 5 classes of metamorphic rocks, the proposed method classifies magmatic rocks better with an error rate of 0.8% against 3.3% for the LBP method.These results show a slightly better performance of our method compared to LBP (see Fig. 8).This is consistent with the observation that can be made of these rock texture images.For images of magmatic rocks, we notice that the texture and the color in these images are somewhat regular in their spatial representation, unlike the case of certain metamorphic rocks where there is no homogeneity in the spatial representation of the tex.and color (examples of eclogite and migmatite).The color texture combination in the rock study has been beneficial for their identification.
As a result, the local and global characteristics used in this study for their extraction have been very useful.
and LBP are respectively invariant by rotation of LBP and invariant by uniform rotation of LBP.These two improved LBP operators have been proposed byOjala et al. in  2002 [15].

Fig. 1 .
Fig. 1.Example of the Coding Process of the Standard LBP Operator.

Fig. 2 .
Fig. 2.An Example of an Original Image of Granodiorite (a), Its Image LBP (b), Its Image ALBPCSF (c) (The 3 Superimposed), the Histogram of the Image LBP (d) and the Histogram ALBPCSF (e).
0,..., 4 and   define respectively the orientations and the scales of the Gabor filters used.Gabor's transformation of an image that can be called a Gabor image is defined as the convolution of the original image   , I x y with the Gabor


and thus can be rewritten as follows:, , ,

Fig. 6 .
Fig. 6.Examples of the Eight different Classes of Rock Images.

TABLE I .
AVERAGE GABOR AMPLITUDE COEFFICIENTSAverage of the coefficients of Gabor amplitudes calculated for different rocks, Lambda = 4, theta = 135°

TABLE III .
AVERAGES OF THE DCT COEFFICIENTSAverages of the DCT coefficients calculated for different rocks

TABLE VI
. STANDARD DEVIATION OF THE COEFFICIENTS OF AMPLITUDES OF GABOR_ALBPCSF (G-ALBPCSF)Mean standard deviations of G-ALBPCSF coefficients calculated for different rocks, Lambda = 4, Theta = 135 °

TABLE IX .
MEAN VALUES OF HI FOR THE DIFFERENT METHODS USED Mean HI values of the different methods used

TABLE XII .
PERFORMANCE INDICATORS OF THE TWO METHODS

TABLE XIII .
COMPARISON OF LBP AND D_ALBPCSF METHODS