The Journal of Supercomputing

, Volume 65, Issue 3, pp 1327–1352

Box-counting algorithm on GPU and multi-core CPU: an OpenCL cross-platform study


DOI: 10.1007/s11227-013-0885-z

Cite this article as:
Jiménez, J. & Ruiz de Miras, J. J Supercomput (2013) 65: 1327. doi:10.1007/s11227-013-0885-z


In this paper, we present the analysis and development of a cross-platform OpenCL implementation of the box-counting algorithm, which is one of the most widely-used methods for estimating the Fractal Dimension. The Fractal Dimension is a relevant image analysis method used in several disciplines, but computing it is in general a time consuming process, especially when working with 3D images. Unlike parallel programming models that strictly depend on the hardware type and manufacturer, like CUDA, OpenCL allows us to provide an implementation suitable for execution on both GPUs and multi-core CPUs, whatever the hardware manufacturer. Sorting is a key part of the fast box-counting algorithm and the final speedup is highly conditioned by the efficiency of the sorting algorithm used. Our study reveals that current OpenCL implementations of sorting algorithms are clearly slower when compared with both CUDA for GPU and specific multi-core CPU implementations. Our OpenCL algorithm has been specifically optimized according the type of the target device and the results show an average speedup of up to 7.46× and 4×, when executed on the GPU and the multi-core CPU respectively, both compared with the single-threaded (sequential) CPU implementation.


Box-counting OpenCL GPU CPU Fractal dimension 

Copyright information

© Springer Science+Business Media New York 2013

Authors and Affiliations

  1. 1.Department of Computer ScienceUniversity of JaénJaénSpain

Personalised recommendations