zblz / naima

Derivation of non-thermal particle distributions through MCMC spectral fitting
http://naima.readthedocs.io
BSD 3-Clause "New" or "Revised" License
45 stars 54 forks source link

Improve performance of sync calculation #138

Closed tibaldo closed 7 years ago

tibaldo commented 7 years ago

Calculating cube root only once reduces computation time by ~40%, see discussion in #135.

zblz commented 7 years ago

Looks good to me. Thanks!

zblz commented 7 years ago

@tibaldo : You can see in the plot below the performance improvement from this PR: http://zblz.github.io/naima-benchmarks/#benchmarks.TimeRadSy.time_Sy_2run

Thanks!