Accelerating Monte Carlo simulations with an NVIDIA® graphics processor

Abstract Modern graphics cards, commonly used in desktop computers, have evolved beyond a simple interface between processor and display to incorporate sophisticated calculation engines that can be applied to general purpose computing. The Monte Carlo algorithm for modelling photon transport in turbid media has been implemented on an NVIDIA ® 8800 gt graphics card using the CUDA toolkit. The Monte Carlo method relies on following the trajectory of millions of photons through the sample, often taking hours or days to complete. The graphics-processor implementation, processing roughly 110 million scattering events per second, was found to run more than 70 times faster than a similar, single-threaded implementation on a 2.67 GHz desktop computer. Program summary Program title: Phoogle-C/Phoogle-G Catalogue identifier: AEEB_v1_0 Program summary URL: http://cpc.cs.qub.ac.uk/summaries/AEEB_v1_0.html Program obtainable from: CPC Program Library, Queen's University, Belfast, N. Ireland Licensing provisions: Standard CPC licence, http://cpc.cs.qub.ac.uk/licence/licence.html No. of lines in distributed program, including test data, etc.: 51 264 No. of bytes in distributed program, including test data, etc.: 2 238 805 Distribution format: tar.gz Programming language: C++ Computer: Designed for Intel PCs. Phoogle-G requires a NVIDIA graphics card with support for CUDA 1.1 Operating system: Windows XP Has the code been vectorised or parallelized?: Phoogle-G is written for SIMD architectures RAM: 1 GB Classification: 21.1 External routines: Charles Karney Random number library. Microsoft Foundation Class library. NVIDA CUDA library [1]. Nature of problem: The Monte Carlo technique is an effective algorithm for exploring the propagation of light in turbid media. However, accurate results require tracing the path of many photons within the media. The independence of photons naturally lends the Monte Carlo technique to implementation on parallel architectures. Generally, parallel computing can be expensive, but recent advances in consumer grade graphics cards have opened the possibility of high-performance desktop parallel-computing. Solution method: In this pair of programmes we have implemented the Monte Carlo algorithm described by Prahl et al. [2] for photon transport in infinite scattering media to compare the performance of two readily accessible architectures: a standard desktop PC and a consumer grade graphics card from NVIDIA. Restrictions: The graphics card implementation uses single precision floating point numbers for all calculations. Only photon transport from an isotropic point-source is supported. The graphics-card version has no user interface. The simulation parameters must be set in the source code. The desktop version has a simple user interface; however some properties can only be accessed through an ActiveX client (such as Matlab). Additional comments: The random number library used has a LGPL ( http://www.gnu.org/copyleft/lesser.html ) licence. Running time: Runtime can range from minutes to months depending on the number of photons simulated and the optical properties of the medium. References: [1] http://www.nvidia.com/object/cuda_home.html . [2] S. Prahl, M. Keijzer, Sl. Jacques, A. Welch, SPIE Institute Series 5 (1989) 102.

[1]  V. Mcglone,et al.  Light distribution inside mandarin fruit during internal quality assessment by NIR spectroscopy , 2003 .

[2]  F Martelli,et al.  Accuracy of the diffusion equation to describe photon migration through an infinite medium: numerical and experimental investigation. , 2000, Physics in medicine and biology.

[3]  D T Delpy,et al.  Parallel operation of Monte Carlo simulations on a diverse network of computers. , 1997, Physics in medicine and biology.

[4]  J. Spanier,et al.  Perturbation Monte Carlo methods to solve inverse photon migration problems in heterogeneous tissues. , 2001, Optics letters.

[5]  B. Wilson,et al.  Monte Carlo modeling of light propagation in highly scattering tissues. II. Comparison with measurements in phantoms , 1989, IEEE Transactions on Biomedical Engineering.

[6]  J. Wood,et al.  Monte Carlo photon transport for multilayer shields on the AMT DAP parallel computer , 1990 .

[7]  Annamaria Kisslinger,et al.  Multiple processor version of a Monte Carlo code for photon transport in turbid media , 2000 .

[8]  Harald Niederreiter,et al.  Monte-Carlo and Quasi-Monte Carlo Methods 1998 , 2000 .

[9]  Feng Gao,et al.  An inverse Monte-Carlo method for determining tissue optical properties , 2007, SPIE BiOS.

[10]  N. Ramanujam,et al.  Monte Carlo-based inverse model for calculating tissue optical properties. Part I: Theory and validation on synthetic phantoms. , 2006, Applied optics.

[11]  Hubert Nguyen,et al.  GPU Gems 3 , 2007 .

[12]  Gisela Anton,et al.  ROSI—an object-oriented and parallel-computing Monte Carlo simulation for X-ray imaging , 2003 .

[13]  Ross T. Whitaker,et al.  Interactive Visualization of Volumetric White Matter Connectivity in DT-MRI Using a Parallel-Hardware Hamilton-Jacobi Solver , 2007, IEEE Transactions on Visualization and Computer Graphics.

[14]  Rainer Künnemeyer,et al.  Measuring optical temperature coefficients of Intralipid. , 2007, Physics in medicine and biology.

[15]  Yuni K. Dewaraja,et al.  A parallel Monte Carlo code for planar and SPECT imaging: implementation, verification and applications in 131I SPECT , 2002, Comput. Methods Programs Biomed..

[16]  M. Nichols,et al.  Design and testing of a white-light, steady-state diffuse reflectance spectrometer for determination of optical properties of highly scattering systems. , 1997, Applied optics.

[17]  D. Rogers Fifty years of Monte Carlo simulations for medical physics , 2006, Physics in medicine and biology.

[18]  John N. Porter,et al.  AO3D: A Monte Carlo code for modeling of environmental light propagation , 2008 .

[19]  Peter Schröder,et al.  Quantum Monte Carlo on graphical processing units , 2007, Comput. Phys. Commun..

[20]  Nirmala Ramanujam,et al.  Monte Carlo-based inverse model for calculating tissue optical properties. Part II: Application to breast cancer diagnosis. , 2006, Applied optics.

[21]  Antonio Ruiz,et al.  Non-rigid Registration for Large Sets of Microscopic Images on Graphics Processors , 2009, J. Signal Process. Syst..

[22]  R. Caflisch Monte Carlo and quasi-Monte Carlo methods , 1998, Acta Numerica.

[23]  Jens Gregor,et al.  Simulation of emission tomography using grid middleware for distributed computing , 2004, Comput. Methods Programs Biomed..

[24]  Ashleyj . Welch,et al.  Optical-Thermal Response of Laser-Irradiated Tissue , 1995 .

[25]  Takuji Nishimura,et al.  Mersenne twister: a 623-dimensionally equidistributed uniform pseudo-random number generator , 1998, TOMC.

[26]  Harald Niederreiter,et al.  Monte Carlo and Quasi-Monte Carlo Methods 2006 , 2007 .