The Fractal Dimension (FD) of an image defines the roughness using a real number which is highly associated with the human perception of surface roughness. It has been applied successfully for many computer vision applications such as texture analysis, segmentation and classification. Several techniques can be found in literature to estimate FD. One such technique is Differential Box Counting (DBC). Its performance is influenced by many parameters. In particular, the box height is directly related to the gray-level variations over image grid, which badly affects the performance of DBC. In this work, a new method for estimating box height is proposed without changing the other parameters of DBC. The proposed box height has been determined empirically and depends only on the image size. All the experiments have been performed on simulated Fractal Brownian Motion (FBM) Database and Brodatz Database. It has been proved experimentally that the proposed box height allow to improve the performance of DBC, Shifting DBC, Improved DBC and Improved Triangle DBC, which are closer to actual FD values of the simulated FBM images.
A natural scene could be treated as complex objects that could be represented using Fractal Geometry, which was introduced by Mandelbrot  in 1983. Fractal Geometry is used to define self-similar elements independent of scale, known as fractal set. FD is a measure to quantify the roughness or irregularities present in that set. Nowadays, researchers have been using FD in various computer vision applications such as texture, image segmentation , shape identification , palm print recognition , time series analysis , classification  and spatial variability analysis . Interested readers can find more application areas in .
Mandelbrot  first gave an idea to compute FD which was further advanced by Peleg et al. , Pentland , Keller et al. , Gagnepain et al.  etc. In , Sarkar et al. proposed a method known as DBC to compute FD using box counting (BC) technique, which became popular in research community because it is simple, easy to interpret and implement. However, it suffers from various drawbacks like over-counting of boxes along z-direction (quantization-computation), over-counting of boxes along xy-direction, lack of a proper box height, inappropriate use of grid sizes. Several modifications of DBC have been done to yield accurate FD values. Jin et al.  restricted the allowed range of grid sizes to avoid distortions occurred during line fitting to compute FD. Chen et al.  noticed that DBC suffers from over-counting of boxes along z-direction and proposed a new formula to compute the number of boxes required to cover rough surface over a grid , but authors used cubes to represent boxes. In [16,17], Li et al. used a new -plane partitioning mechanism to consider the gray-level variations between two adjacent grids that overlaps two adjacent grids by one row and one column. Authors also proposed a new formula to compute and two finer box heights. However, these box heights are too small, which increase the number of box counts significantly. As a result, more memory is required to store the large number of boxes. Liu et al. in  proposed a novel -plane shifting mechanism to solve the problem of under-counting. Authors used the grid sizes as only the divisors of the image size. In , Kaewaramsri et al. partitioned the square grid into two triangular grids to obtain better precision of box count. Interested readers can find various modifications of DBC in [20,21,22,23].
Out of different parameters of DBC, box height, which is directly related to computing the number of boxes required to represent the gray-level variations over a grid and badly affects the estimation of FD values. Larger box height incurs high error. While lower box heights require more computation. Some box heights depend only on the grid size on the contrary some depend on the image characteristics, whose values change according to the degree of roughness present in an image. It was observed that the box height is always directly proportional to grid size in order to preserve the scale of boxes. Different box heights used by different authors are defined in Section 2.4. Box height used by DBC method is directly proportional to number of gray-levels and inversely proportional to image size . Authors in  used cubes to represent a box. It means that the height is directly proportional to grid size. Some of the authors used maximum and minimum gray-level of an image as box height in their works [16,23] respectively. Authors in  used standard deviation () of an image as box height. Box heights proposed in [16,17] are very small and accurate in estimating FD but are not dependent on image size. The impact of box heights have been studied thoroughly and proposed a new box height as a function of image size based using Brodatz Database , which is also validated using simulated FBM Database. Results show that the new box height allows to better estimate FD value with a less Distance Error (DE) than the box height used by DBC method. Rest of the paper is organized as follows: Section 2 discusses the traditional DBC method and its variants. Section 3 depicts experimental results, which help to propose a new box height as a function of image size. The validation of the proposed box height has been done on gray-scale images from simulated FBM Database and Brodatz Database in Section 3. The conclusion has been drawn in Section 4.
2. Materials and Methods
All the experiments have been performed on one publicly available Brodatz Database  and one generated FBM Database using random mid-point displacement algorithm . The Brodatz Database contains 112 textured images of size pixels. This database is used to propose a novel box height for calculating FD values because this database is very much popular and used by most of the researchers in this context. Some of the textured images from Brodatz Database and generated FBM images with their actual FD values that could be generated using Hurst component (H) by 3-H are shown in Figure 1 and Figure 2 respectively. The H varies from 0 to 1 with step size 0.1 and it is used to validate the proposed method in this work.
2.2. Fractal Dimension
Standard formula for computing FD of an ideal bounded fractal set, B, using BC method is expressed by Equation (1) .
where, is the number of distinct boxes of scale r that are required to cover the B. If the B is not an ideal fractal set then Equation (1) will give different FD values for different values of r. In that case the slope of the line obtained by fitting the points is known as the FD of the non-ideal fractal set. The detail description of the DBC method is given in Section 2.3.
2.3. The DBC Method
In 1992 Sarkar et al.  proposed an straightforward approach to estimate FD of a gray-scale image. Their methodology is as follows: a square image (I) of size pixels is partitioned into non-overlapping grids of size pixels where s is an integer and s varies from 2 to . The related scale (r) of a grid with size pixels with respect to an image size M is denoted by an expression, . If s is not a divisor of M then non-image pixels of the grids on the boundary are treated as zero.
On each grid, there are a number of boxes of size , to cover the rough gray-level image intensity surface over that grid and these boxes are assigned with a number as shown in Figure 3, where, denotes the floor function and
The G is the total number of gray-levels in a gray-scale image i.e., 256. The total number of boxes of size , required to represent the rough surface over a (i, j)th grid of size pixels, (i,j) is
where, denotes the ceiling function. The and are the maximum and minimum gray-levels present on (i, j)th grid respectively. The represents the box number, which contains . On the other hand, located in a box, which is denoted by box number .
The total number of boxes, , at scale r is required to cover the rough intensity surface of an image can be computed by Equation (4).
Then the FD of an image or the slope of a line is computed by fitting all the points using Linear Least Squares as shown in Figure 4.
The corresponding Distance Error (DE) incurred while computing FD can be estimated using Equation (5) defined as follows:
where, m is slope of the line i.e., FD, b is the y-intercept and N is the total number of points used in fitting.
Box height is directly related to an image gray-level intensity variations which is characterized by z-axis in a 3D plane. It is clear that a larger value of box height is unable to compute accurate number of boxes. Whereas a lower value of box height is capable of finding out FD of an image accurately. However, it requires more memory to store box counts. Therefore, extensive study on the impact of different box heights have been done in this work to compute FD values.
2.4. Box Height
Box height is directly proportional to grid size s. It means that the ratio of box height and grid size is equal to a constant value. The box height should not exceed the size of a grid otherwise, it leads to an inaccurate FD. Moreover, box height should not be constant because in that case the scale of boxes (r) on different grids will not be maintained. Let us assume that 23 gray-levels are required to represent the rough surface over a particular grid. If the box height is 11 then 3 boxes are required to represent the rough surface. Out of these three boxes, first two boxes are completely filled up by 11 gray-levels and the third box contains only one gray-level. But, if the box height is 2 then 12 boxes are required with 11 full boxes and 1 box is added for one gray-level count. Again if the box height is 0.5 then a total of 46 full boxes are required to cover the rough image intensity surface. Therefore, is more accurate and is less accurate. Hence, a smaller box height is preferable and we have proposed a method to compute box height in Section 3.2. Different existing definitions for computing box heights are as follows:
A: In [13,14,18,19,20,21,22], authors used a box height, , for their work. When then this box height becomes very large hence fails in providing accurate FD.
B: Chen et al. considered in their work  to compute FD. Sometimes it may happen that the box height is greater than the number of gray-levels in an image (); in that case only one box is required to represent the rough surface of a particular grid. Consequently, it leads to an inaccurate FD.
C: Li et al. proposed to be their box height in , where , are the maximum and minimum gray-level intensities present in an image respectively. The box height will be very small when an image is having a large texture variation. On the other hand, when gray-level differences () will be small then the box height will be high as a result inaccurate FD value will be produced.
D: Same authors proposed another formula for box height, , where is the standard deviation of an image and is a constant in . But, the proposed box height is too small and it requires more memory space for storage. The value of this box height is almost same to the box height used in  and like C this box height is dependent on image gray-levels.
E: In , Lai et al. used as box height. Sometimes , which is almost same to the box height used in [13,14,18,19,20,21,22].
3. Experimental Results and Discussion
3.1. Impact of Box Heights
Firstly, three box heights namely, A: , B: and D: (B>A>D) are selected for further experiment from A, B, C, D and E described in Section 2.4 because box height A is almost same to E for texture images and box height C is nearly equal to D. These box heights have been considered separately with DBC method by keeping other parameters same. The FD values along with DE values are then computed on Brodatz Database and they have been depicted in Figure 5 and Figure 6. However, all the images are scaled down to standard pixels before computation. Because for , A = B, hence these two box heights cannot be distinguished and simultaneously is not selected since it is not a standard image size i.e., not a power of 2. The list of parameters of DBC method are reported in Table 1. It is clear from both Figure 5 and Figure 6 that FD value increases when box height decreases. On the other hand, DE values increases while box height increases.
3.2. A Novel Method to Estimate Box Height
We can conclude from Section 2.4 that the standard expression for box height is as follows:
where, R is any real number () and R must be greater than or equal to one () because if the value of R is less than one and the value of s is large then h will be more than G in that case the obtained value of FD will be inaccurate. Most of the authors have considered R as a positive natural number for their works. Thus, a series of natural numbers 1 to 100 have been chosen for the value of R to compute FD value in order to find out a R value for an image, which satisfies Equation (7) in this work. Bicubic interpolation method is applied on each of these images of size pixels to resize them into , , and pixels for further experiments. FD of ideal fractal sets are invariant to size of the set i.e., for any value of s in Equation (1), the value of will remain same. Since texture images are not ideal fractals, their FD value changes with the size of the image though the difference in FD values are less but not equal to zero. Hence we have used different image sizes in-order to relate their FD value and using their relation a new box height is proposed in this paper.
The Equation (6) is applied as box height with other parameters of DBC described in Table 1 on 112 textured images from Brodatz Database at different image sizes , , , and pixels. Figure 7 and Figure 8 show different FD values and DE values for different values of R respectively, which has started from 1 to 100 with step size 1. Figure 7 contains the FD values of images, which are shown in Figure 2. The similar experiments have been performed on 112 images with different image sizes , , and pixels. It is observed that the same trend persist between these experiments as shown in Figure 7. Moreover, it is clear from Figure 7 that for all images when box height decreases i.e., R in Equation (6) increases then the computed FD value increases, but after some higher value of R the estimated FD value almost remains the same as R increases. Similarly Figure 8 shows that as box height decreases, incurred error i.e., DE, decreases. Though decreasing of DE values are not fully monotonic but eventually after some lower box height, i.e., for higher R values, the DE values remain almost the same. So, we have to find out a proper value of R for a particular image size in such a way that there is no significant change in the difference of two successive FD values for two successive values of R.
Let, be a FD value of an image numbered as p from Brodatz Database having pixels with a particular value of R where, R starts from one and . Now, smallest integer value, R, has to be found that satisfies Equation (7) for each image p at a particular image size .
It is observed from the experiments that the value of FD up-to four decimal places is enough to distinguish textures. Moreover, floating point arithmetic is very expensive. So, a threshold value 0.0001 is chosen for our work. Table 2 shows the number of images having the same R value for different image size that satisfy Equation (7). Here, is marked using red color in Table 2, which represents the smallest R value for an M, after which FD value does not change significantly for all the images.
Then all the points are plotted into a 2D plane to get a line using linear least square, where x-axis represents M i.e., image size and y-axis denotes of a particular image size M. Here, corresponds to , , , and that have been obtained from Table 2. The expression of the plotted line is represented by Equation (8).
Now, this line is validated by putting different values of M (128, 256, 512, 640 and 1024) and the obtained R values are shown in Table 3. It is clear from Table 3 that the obtained R value is not always greater than or equal to . So, the next task is to find out an exact equation, which can replace Equation (8). In other words, an exact equation is expected in this work, which can find out R after putting M, where the value of R will be always greater than or equal to without performing the above analysis. However, this analysis helps us to propose a novel box height, which depends on image size. The expression of R in Equation (8) is approximated by , which is shown in Equation (9). Initially we started with because it is the nearest multiple of to satisfy for least image size M = 128 and its .
This expression is again validated using different values of M (128, 256, 512, 640 and 1024). Unfortunately, it fails for image size 640 and 1024 as shown in Table 3. Equation (9) has two parts and 1 has been added to the second part, . New formula is shown in Equation (10).
Again, Equation (10) has been validated for all image size M (128, 256, 512, 640 and 1024) and this time Equation (10) works fine for all image sizes M. The ceil function, is used to deal with the image sizes, M which are not a power of 2 like when M = 640 i.e., to obtain an integer value. Hence, Equation (10) is used to fix the value of R. Therefore using Equations (6) and (10), the new box height proposed in this paper for DBC  is as follows:
Hence when , we need to restrict R. Hence if then . Therefore the final proposed formula to compute box height is as follows:
Eleven generated FBM images as shown in Figure 2 have been used for the first set of experiment to validate the proposed box height as denoted in Equation (12). The FBM images are generated using random mid-point displacement algorithm with different Hurst components. The value of Hurst component varies from 0 to 1 with step size 0.1 in this work. So, we have altogether 11 Hurst values, which help to create eleven FBM images. Moreover, Hurst component defines the actual FD value of an image. The different Hurst values and their acutal FD values are shown in 1st column and 2nd column of Table 4 respectively. The 3rd column of Table 4 depicts the FD values obtained using original DBC method. Table 1 shows different parameters of DBC, SDBC , IDBC  and ITDBC . Now, the proposed box height have been used and the achieved FD values for all the above mentioned images are shown in column number 4 of Table 4. The 5th and 6th columns of Table 4 show the difference of the FD values obtained by DBC method and new box height from actual FD values respectively. The DE values using both the methods are also reported in Table 4. It is clear from the columns 5th and 6th of Table 4 that the proposed box height allows to better estimate FD values, which are closer to actual FD values with less DE values. The same set of experiments using both the methods have been done on sixteen textured images from Brodatz Database as shown in Figure 1 and the results are shown in Table 5. We do not have actual FD values for these textured images. So, the actual FD values are missing in Table 5. However, the obtained FD values using the proposed box height of DBC are larger than the achieved FD values by the original DBC method. Thus, we can conclude that new box height of DBC estimates better FD values than the original DBC method.
In the next set of experiment, original SDBC  and SDBC with proposed box height have been considered on eleven generated FBM images and sixteen textured images from Brodatz Database and the obtained results are shown in Table 6 and Table 7 respectively.
Then IDBC  method and the proposed box height have been used for the next set of experiments on eleven generated FBM images and sixteen textured images from Brodatz Database and the achieved results are shown in Table 8 and Table 9 respectively.
Again, similar experiments using ITDBC method  and proposed box height have been considered on both set of images i.e., on generated FBM, textured images and the gained results are reported in Table 10 and Table 11 respectively.
To know the impact of the new box height for different methods such as DBC, SDBC, IDBC and ITDBC, we have also plotted the results of these methods obtained using their original parameters and the results obtained with the proposed box height as shown in Figure 9. While plotting, the actual FD values are represented in x-axis and the corresponding computed FD values in y-axis. It is clear from Figure 9 that for all the cases the proposed box height allows the four existing methods to compute better FD values compare to their original methods. Moreover, we can conclude from Figure 9 that the proposed box height together with ITDBC estimate better FD values for maximum set of experiments.
We have also plotted a similar graph for Brodatz Database in Figure 10. In x-axis of Figure 10 represents image number and y-axis denotes computed FD values using all the above mentioned methods. We can easily determine that the proposed box height along with ITDBC outperforms than other methods shown in Figure 10.
FD is the main factor that indicates image roughness. DE is merely a secondary component of FD values and if less DE is generated than it is good but slightly high DE is acceptable and that does not mean that the method is entirely bad. The main priority lies in better estimating FD values, Hence we relaxed DE value while defining proposed box height i.e., not all DE values generated by proposed box height for DBC, SDBC, IDBC and ITDBC are less when compared with their original box heights as shown in last columns of Table 8, Table 9, Table 10 and Table 11.
In this work, the impact of box height in estimating FD values using DBC method has been studied thoroughly. It is clear from the literature that a larger box height is unable to compute FD value correctly. In other words, a lower box height produces better FD value with relatively less error. Thus, an equation for a new box height is proposed in this work based on 112 textured images of Brodatz Database. However, the new box height depends on image size and it generates relatively smaller box height compare to some of the existing methods in literature. The new box height is also validated on generated FBM images, which have been created using random mid-point displacement algorithm.
Several experiments have been performed on generated FBM images and images from Brodatz Database using DBC, SDBC, IDBC and ITDBC along with proposed box height. It was observed from the obtained results that the proposed box height allows to estimate better FD values with less errors in most of the cases with DBC, SDBC, IDBC and ITDBC methods. Moreover, it was observed that the proposed box height with ITDBC method outperforms other methods for all but only two FBM tested images. There are still some aspects of different parameters of DBC method that deserve further study. We have tested our proposed algorithm on gray-scale images only. So, we would like to work on color images. In future works, the behavior of the proposed method will be studied. We would also like to focus in the application areas of FD such as image segmentation, object recognition.
Chinmaya Panigrahy would like to thank Erasmus+ Programme (KA107) for financial support through project 2015-1-ES01-KA107-015460, which makes this paper possible. This work has been partially funded by the Agencia Estatal de Investigación (AEI) of Spain and the European Regional Development Fund (ERDF) through the project ARTeMISat-2: Advanced Processing of Remote Sensing Data for Monitoring and Sustainable Management of Marine and Terrestrial Resources in Vulnerable Ecosystems (CTM2016-77733-R). Ayan Seal is grateful to Media Lab Asia, Ministry of Electronics and Information Technology, Government of India for providing him young faculty research fellowship. Finally. the authors would like to thank the anonymous reviewers for their constructive advice.
Authors make substantial contributions such as data collection, conception, design, analysis and interpretation of data to the work reported in this manuscript. Authors participate in initial drafting of article and revising it critically for important intellectual content. Authors also give final approval of the version to be submitted.
Conflicts of Interest
The authors declare no conflict of interest.
Mandelbrot, B.B. The Fractal Geometry of Nature/Revised and Enlarged Edition; WH Freeman and Co.: New York, NY, USA, 1983; Volume 495, p. 1. [Google Scholar]
Chaudhuri, B.B.; Sarkar, N. Texture segmentation using fractal dimension. IEEE Trans. Pattern Anal. Mach. Intell.1995, 17, 72–77. [Google Scholar] [CrossRef]
Hong, D.; Pan, Z.; Wu, X. Improved differential box counting with multi-scale and multi-direction: A new palmprint recognition method. Opt. Int. J. Light Electron Opt.2014, 125, 4154–4160. [Google Scholar] [CrossRef]
Cervantes-De la Torre, F.; González-Trejo, J.; Real-Ramírez, C.; Hoyos-Reyes, L. Fractal dimension algorithms and their application to time series associated with natural phenomena. J. Phys.2013, 475, 012002. [Google Scholar]
Yu, L.; Zhang, D.; Wang, K.; Yang, W. Coarse iris classification using box-counting to estimate fractal dimensions. Pattern Recognit.2005, 38, 1791–1798. [Google Scholar] [CrossRef]
Lillo-Saavedra, M.; Gonzalo, C.; Lagos, O. Toward reduction of artifacts in fused images. Int. J. Appl. Earth Obs. Geoinf.2011, 13, 368–375. [Google Scholar] [CrossRef][Green Version]
Edrees, M. Application of fractal dimension. Iraqi J. Stat. Sci.2006, 10, 54–73. [Google Scholar]
Gagnepain, J.; Roques-Carmes, C. Fractal approach to two-dimensional and three-dimensional surface roughness. Wear1986, 109, 119–126. [Google Scholar] [CrossRef]
Sarkar, N.; Chaudhuri, B. An efficient differential box-counting approach to compute fractal dimension of image. IEEE Trans. Syst. Man Cybern.1994, 24, 115–120. [Google Scholar] [CrossRef]
Jin, X.; Ong, S.; Jayasooriah. A practical method for estimating fractal dimension. Pattern Recognit. Lett.1995, 16, 457–464. [Google Scholar] [CrossRef]
Chen, W.S.; Yuan, S.Y.; Hsieh, C.M. Two algorithms to estimate fractal dimension of gray-level images. Opt. Eng.2003, 42, 2452–2464. [Google Scholar] [CrossRef]
Li, J.; Sun, C.; Du, Q. A new box-counting method for estimation of image fractal dimension. In Proceedings of the 2006 IEEE International Conference on Image, Atlanta, GA, USA, 8–11 October 2006; pp. 3029–3032. [Google Scholar]
Li, J.; Du, Q.; Sun, C. An improved box-counting method for image fractal dimension estimation. Pattern Recognit.2009, 42, 2460–2469. [Google Scholar] [CrossRef]
Liu, Y.; Chen, L.; Wang, H.; Jiang, L.; Zhang, Y.; Zhao, J.; Wang, D.; Zhao, Y.; Song, Y. An improved differential box-counting method to estimate fractal dimensions of gray-level images. J. Vis. Commun. Image Represent.2014, 25, 1102–1111. [Google Scholar] [CrossRef]
Kaewaramsri, Y.; Woraratpanya, K. Improved Triangle Box-Counting Method for Fractal Dimension Estimation. In Recent Advances in Information and Communication Technology 2015; Springer: New York, NY, USA, 2015; pp. 53–61. [Google Scholar]
Liu, S. An improved differential box-counting approach to compute fractal dimension of gray-level image. In Proceedings of the IEEE International Symposium on Information Science and Engineering (ISISE’08), Shanghai, China, 20–22 December 2008; Volume 1, pp. 303–306. [Google Scholar]
Long, M.; Peng, F. A box-counting method with adaptable box height for measuring the fractal feature of images. Radioengineering2013, 22, 208–213. [Google Scholar]
Nunsong, W.; Woraratpanya, K. Modified differential box-counting method using weighted triangle-box partition. In Proceedings of the IEEE 7th International Conference on Information Technology and Electrical Engineering (ICITEE), Chiang Mai, Thailand, 29–30 October 2015; pp. 221–226. [Google Scholar]
Lai, K.; Li, C.; He, T.; Chen, L.; Yu, K.; Zhou, W. Study on an improved differential box-counting approach for gray-level variation of images. In Proceedings of the IEEE 10th International Conference on Sensing Technology (ICST), Nanjing, China, 11–13 November 2016; pp. 1–6. [Google Scholar]
The statements, opinions and data contained in the journal Entropy are solely
those of the individual authors and contributors and not of the publisher and the editor(s).
MDPI stays neutral with regard to jurisdictional claims in published maps and institutional affiliations.
The statements, opinions and data contained in the journals are solely
those of the individual authors and contributors and not of the publisher and the editor(s).
MDPI stays neutral with regard to jurisdictional claims in published maps and institutional affiliations.