Keywords

1 Introduction

Texture analysis is an area of intense research as it plays a major role in many disciplines. It is also a major field of development for several computer vision applications, ranging from computer assisted diagnosis, defect detection, to food inspection and remote sensing [1, 2].

Texture is certainly one of the most studied image attributes. Nevertheless, it lacks a consensus regarding a formal definition. It is usually described as a repetition, exactly or with small variation, of a small pattern over a region, where the characteristics of this small pattern are directly connected to the physical properties of the surface of the object. Consequently, texture analysis enable us to distinguish regions with different reflectance characteristics, and thus, different colors in a specific combination of bands [2, 3].

The literature describes a great variety of methods for texture characterization, and fractal dimension is an important one. Basically, fractal dimension measures how complex an object is. For a texture image, this complexity is measured in terms of organization of pixels, i.e., fractal dimension enable us to quantify the texture image in terms of homogeneity. This allows comparison with other texture patterns [3,4,5].

In this paper, our goal is to use fractal dimension based descriptors to correctly discriminate samples of an inspected metal: the phases of a Titanium alloy, Ti-6Al-4V. Visual inspection and quality control is a common task of the manufacturing process. Traditionally, the evaluation of metal microstructures and their physical properties is a subject of study in Metallography. Through microscopy (optical and electron microscopes can be used), it is possible to acquire images of the microstructures of the material evaluated, while a human expert performs its analysis. Due to the human component in this process, this task is susceptible to errors. In this sense, computer vision techniques are an effective approach to minimize errors and improve our discrimination ability [6,7,8,9].

Our paper is organized as follows: Sect. 2 describes the titanium alloy properties and its microstructure. Section 3.1 presents the Bouligand-Minkowski fractal dimension method, which is used to extract texture features from the images of titanium alloy’s microstructure. We perform an experiment with 3900 texture samples of 2 different phases of the titanium alloy to evaluate our proposed descriptors (Sect. 4). The results (Sect. 5) indicate that fractal dimension is a feasibility tool for the discrimination of different phases of the titanium alloy as it surpasses all the compared approaches, while Sect. 6 presents some remarks about this work.

2 Titanium Alloy Properties

In the past decades, titanium alloys have been extensively used in several applications, such as seawater, marine and industrial chemical service. This is mostly due to its high strength characteristics and excellent corrosion resistance. Titanium alloys rival directly stainless steels, nickel-based alloys and composites. When analyzing the microstructure of titanium alloys, it is possible to differentiate three different types, called phases: Alpha, Beta, and Alpha+Beta. These phases depend on the manufacturing process used, which also results in different mechanical and physical properties. These phases can also be described as a function of thermo-mechanical evolution of the alloy [6, 10]. Figure 1 shows an example of each phase microstructure.

To obtain a specific phase, alloying elements (called stabilizers) must be added to the titanium. These stabilizers produce physical-chemical effects, thus resulting in the creation of an alloy with the desired microstructure. In this work, we propose to study the Ti-6Al-4V, the most commonly used titanium alloy as it is significantly stronger than commercially pure titanium while having similar thermal properties. This alloy is composed of 6% aluminum, 4% vanadium, 0.25% (maximum) iron, 0.2% (maximum) oxygen, and the remainder is titanium. At room temperature, this alloy presents 91% of Alpha phase and 9% of Beta phase in its microstructure [6, 10].

Fig. 1.
figure 1

Metallography of Alpha (light) and Beta (dark) microstructure. Left: Alpha+Beta; Right: Alpha and Beta (images provided by the authors of the paper [6]). (Color figure online)

3 Texture Analysis for Texture Classification

3.1 Bouligand-Minkowski Fractal Dimension

Complexity is an important tool for texture analysis and characterization. Although its importance in many areas and its use in many image based applications [11,12,13,14], it is a term that lacks a formal definition in the literature. Complexity is commonly understood as a measure of object irregularity. For shapes, this irregularity is presented as small variations in the contour of the object; for image textures, the irregularity is characterized by variations of the gray levels in a specific region [3, 15].

There exist many different approaches to estimate the complexity of an object in the literature. Among these approaches, a successful one is the fractal dimension, D. Introduced in the 1970s by Benoit Mandelbrot, fractals are objects which present great complexity although they are generated from iteration of simple rules. Fractal geometry enables us to model many natural phenomena and surfaces (e.g. coastlines, brick, skin, rocks etc.). An interesting property of fractal objects is their non-integer dimension (non-Euclidean geometry) called fractal dimension. It is a property related to the complexity and space occupation of the fractal [4, 5].

A texture image is not a fractal object. Real fractals present self-similarity at infinite scales. Images, on the other hand, present a limited self-similarity. Nevertheless, fractal dimension can be used to characterize these objects. Many methods have been proposed over the years to compute the fractal dimension of shapes and textures. One of the most accurate methods to estimate the fractal dimension is the Bouligand-Minkowski method [3, 4]. Initially used for shape analysis and later expanded to include texture analysis, this method uses the influence area of the object to compute its irregularity. This approach makes this method very sensitive to even small structural changes of the object.

To compute the Bouligand-Minkowski fractal dimension from a texture image I, we must first model the image as a surface \(S \in R^{3}\). To accomplish that, we consider each element \(s \in S\), \(s = (y,x,z)\), as defined by the pixel coordinates (y and x) in the image texture I and the intensity \(I(x,y) = z\) at this point. Next, we perform the dilation of the surface S using a sphere of radius r [3, 4, 16]. Through dilation of each point \(s \in S\) by a radius r, we are able to compute the surface’s influence volume, V(r). Next, we estimate the fractal dimension D as the (continuous) plot of \(\log (V(r))\) versus \(\log (r)\):

$$\begin{aligned} D = 3 - \lim _{r \rightarrow 0} \frac{\log {V(r)}}{\log {(r)}} \end{aligned}$$
(1)

with

$$\begin{aligned} V(r) = \left\{ p \in R^3 | \exists p' \in S: \left| p - p' \right| \le r \right\} . \end{aligned}$$
(2)

Notice that the estimation of the fractal dimension D involves the calculus of a limit. Nevertheless, this limit can be estimated as the slope a of the line regression of the log-log curve \(\log (r) \times \log (V(r))\):

$$\begin{aligned} D = 3 - a. \end{aligned}$$
(3)

3.2 Error-Based Fractal Descriptors

According to Mandelbrot [5], fractal dimension is a property of fractal objects and it is related to the self-similarity of the fractal at infinite scales. Unlike fractals objects, real world objects (such images) have limited resolution and finite size. In this case, self-similarity is not present at infinite scales, but only at some few scales. As a result, the complexity measured for an image changes its value according to the visualization scale. This effect is clearly noticed when analyzing the log-log curve computed by the Bouligand-Minkowski method. Small variations in the image produce a large set of variations in the curve, resulting in a richness of details that cannot be represented by a single fractal dimension value as computed using the line regression approach, which is the common estimation process for classical fractal dimension.

In order to overcome this problem, we propose to use a set of descriptors which explores the curve details instead of a single fractal dimension value, so that we are able to perform a more accurate texture characterization, as proposed in [3]. We start by computing the log-log curve using the Bouligand-Minkowski method for a dilation radius r. Next, we compute the line regression \(y = ax + b\) that best fits the log-log curve, where x and y are, respectively, the log of the radius r and the influence volume V(r), a is the slope and b gives the y-intercept of the line. According to Sect. 3.1, the fractal dimension of the image is estimated as \(D = 3 - a\).

Due to the richness of details in the log-log curve, the calculated line is a rough approximation of its true behavior. There is a small error between the points of log-log curve and the value predicted by the line regression. This error is due to the small variation in the log-log curve, a result of the aspect of the image. Variations in pixel position and intensity depend on image context and influence the resulting log-log curve, so that it cannot be described using a simple line regression. Because of this, we propose to use this difference between line regression and the computed curve as an image descriptor. This simple difference, \(e_i\), is defined as

$$\begin{aligned} e_i = a\log {r_i} + b - \log {V(r_i)}, \end{aligned}$$
(4)

where \(r_i \in \left[ 1,r\right] \) is a radius value which exists in the log-log curve and r is the dilation radius used to compute the log-log curve. To properly characterize a texture pattern, we select n equidistant radius values from the curve, thus composing a feature vector \(\psi (n)\):

$$\begin{aligned} \psi (n) = \left[ e_1, e_2, \dots , e_n\right] . \end{aligned}$$
(5)

4 Experiments

For the experiments, we built a dataset of texture samples of “pure” Alpha and Beta and “pure” Alpha+Beta phase. For this, we used 15 images of size \(1079\,\times \,816\) pixels size for each material. Then, we divided each image into blocks of \(80\,\times \,80\) pixels size. As the image size is not a multiple of 80, residual pixels are discarded. We chose this block size as it is “the nearest value to the size of a microstructure in an Alpha+Beta phase” [6]. This process resulted in a dataset composed of 3900 texture samples, 1950 representing the “pure” Alpha and Beta and 1950 the “pure” Alpha+Beta phase. It is important to emphasize that we discarded all color information of the images and considered only its luminance.

To improve our analysis, we also compared our error-based fractal descriptors with traditional texture analysis methods. They are: Fourier descriptors [17], Co-occurrence matrices [18], Wavelet descriptors [19], Tourist walk [20] and Lacunarity [21, 22]. For classification, we used Linear Discriminant Analysis (LDA)[23] with the leave-one-out cross-validation scheme.

5 Results and Discussion

Before applying the proposed fractal approach to texture analysis, some considerations are necessary. We must define the maximum dilation radius, r, used by Bouligand-Minkowski method and the number of error based descriptors selected, n.

The dilation radius r is directly related to the computational cost and discrimination ability of the method. The Bouligand-Minkowski method requires a 3D matrix in order to compute the influence volume of a texture pattern [3]. For a \(N\,\times \,N\) pixels image with L gray levels, the size of this 3D matrix will be \((N+2r)\,\times \,(N+2r)\,\times \,(L+2r+1)\). Thus, large values of r will increase the computational cost. On the other hand, small values of r result in a log-log curve with few points, thus limiting the discrimination ability of the method. During the experiments, we have decided to use \(r = 10\). This radius value achieves a good balance between computational cost and discrimination ability of the method.

Next, we evaluated the number of descriptors n extracted from the log-log curve using the error based approach. Figure 2 shows the success rate achieved for different values of n. We notice an increase in the success rate as the number of selected descriptors increases. The method yields the best performance when using \(n = 78\), which results in a success rate of 95.21%.

Fig. 2.
figure 2

Classification accuracy observed for different values of n.

Table 1. Results yielded by the proposed approach and traditional texture analysis methods.

After defining the parameters radius, r, and number of descriptors, n, we performed a comparison experiment with other traditional texture discrimination methods. Table 1 shows the results obtained by each method evaluated. For each compared approach, we used the configuration based on the authors’ paper or the common use in the literature. The results show that our approach surpasses all the other methods in discriminating the Titanium alloy phases, i.e., our approach provides a more precise characterization of the Titanium alloy phases. Besides the ability to discriminate different phases of the Titanium alloy with considerable quality, our approach holds potential for many applications in Metallography, where physical properties are expressed in different metal microstructures with different reflectance properties.

6 Conclusion

In this paper, we proposed the use of complexity analysis methods to automatically classify metal microstructures. We investigated the potential of fractal dimension to discriminate the three different phases of a Titanium alloy, Ti-6Al-4V: Alpha, Beta, and Alpha+Beta. We used an error based approach to compute fractal descriptors from the Bouligand-Minkowski fractal dimension method. This approach enables us to explore the details in the microstructure’s influence volume, thus resulting in a more precise characterization of the sample. The results indicated that our proposed approach is capable of discriminating the different phases of the Titanium alloy with considerable quality, as it surpasses traditional texture analysis methods in a comparison experiment. In this sense, our approach holds great potential for applications involving the evaluation of metal microstructures and their physical properties as it is able to distinguish regions with different reflectance characteristics.