optados-developers / optados

Official Repository of the Optados code
http://www.optados.org
20 stars 22 forks source link

Lifetime broadening makes calculation run 180 times slower #52

Open ajm143 opened 2 years ago

ajm143 commented 2 years ago

Describe the bug Whilst working on the MZ correction we found that lifetime broadening make the NaGe core-loss calculation take minutes, rather than seconds. I need to investigate if there's something that can speed it up. Is there something sub-optimal in the loops?

To Reproduce Add LAI broadening to a CORE calc.

Expected behavior it should be faster!

ajm143 commented 2 years ago

Bin Spacing. Time w/o LAI. Time w. LAI 0.1. 1.1s 2.7s 0.05 2.2s 9.2s 0.025 4.3s 35.0s

Makes sense as we're doing nbin*nbin operations for the convolution