flaresimulations / synthesizer

Synthesizer - a code for creating synthetic astrophysical observables
https://flaresimulations.github.io/synthesizer/
GNU General Public License v3.0
17 stars 9 forks source link

Introduces threading in imaging module #703

Closed WillJRoper closed 3 months ago

WillJRoper commented 3 months ago

As the title says, the imaging (and spectral data cube) calculation can now be distributed over threads.

The wins are less big here since cache clashes are all but guaranteed when assigning into the image/data cube. This could be alleviated by allocating an image per thread but that could quickly lead to huge memory footprints. That said there's still an improvement.

I created a worst-case scenario concentrated galaxy (which will guarantee the same pixels are assigned to repeatedly) and got the following scaling for imaging:

img_scaling

and spectral data cubes:

datacube_scaling

These are far off the perfect scaling but there is still a win. A real situation will perform better due to the less uniform layout of particles.

Issue Type

Checklist