Archive for the ‘radiative transfer’ tag
GPU meets spacedust
Dust can be a pain if you’re an astronomer. In the same way that clouds obscure a view of the night-sky, interstellar dust can distort an astronomer’s view (even if through the Hubble telescope) of interesting astronomical phenomena. This problem is compounded when you consider that stars and planets tend to form in dense interstellar dust clouds.
The distortions caused by spacedust are caused by radiative transfer – a process of light absorption and scattering which also explains why the sky is blue and why sunsets/sunrises look red. Astronomers have built highly sophisticated models to understand radiative transfer across a wide range of different dust backgrounds. These models have enabled researchers to build very cool simulations, such as this one of two galaxies colliding:
Interestingly, greater sophistication in our understanding of spacedust and a greater desire for precision and resolution in the modeling has meant that more and more of the computational processing of these radiative transfer models has been spent on calculating dust grain temperatures rather than the math behind the actual radiation transfer (a product of the fact that you need to calculate across many points in the “dust cloud”, across many types/sizes of dust particles, and because you need to iterate many times to find an equilibrium) – something on the order of 1011-1012 exponentials per simulation!
That traditional processors are not well suited for calculating exponentials and that there were simply so many calculations which needed to be done in parallel convinced researchers to turn to NVIDIA’s CUDA as a potential solution. As we’ve noted before with using raytracing as a means to accelerate radiotherapy dosage calculations, NVIDIA’s CUDA is a standard programming toolset which lets programmers more easily use the power of (NVIDIA) graphics cards for calculations. Because the calculations needed to do high-performance graphics for a game of Modern Warfare 2 are similar to the calculations that supercomputers crunch through, NVIDIA’s CUDA has been demonstrated to be able to accelerate calculation speed by orders of magnitude!
In the case of dust grain temperature calculation, the results were equally impressive. Not only were the researchers able to accelerate dust grain calculation using a NVIDIA Tesla C1060 (with 4 GB of memory) over an 8-core Intel Xeon E5420 processor (with 32 GB of RAM) alone by a factor of 55, they were able to do this despite:
- the fact that 17% of processing time on the GPU solution was dedicated to data transfer (something the CPU-only solution has to worry about less)
- the maximum theoretical capacity of the GPU was only 6 times greater than that of the CPU, highlighting a big difference between the CUDA philosophy (crank up performance) and the CPU compiler philosophy (abstract but flexible)
Amazingly, the researchers found that even if the CPU were to run an interpolation scheme (requires less processing power, but introduces a little more error and makes it harder to do more sophisticated calculations vs. the equilibrium calculations done here), the GPU solution is still faster by a factor of 16 times!
So: spacedust – 0. GPU – 1. Now let’s see if they can tackle the flexible dust temperature problem…
Paper: “Accelerating Dust Temperature Calculations with Graphics Processing Units”, submitted to New Astronomy; ArXiV link