-
-
Notifications
You must be signed in to change notification settings - Fork 5.1k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
ENH: Fast Lomb-Scargle Periodogram #17384
Comments
extra materials: |
Thanks for raising this issue! Adding one small piece: here is how astropy wraps the scipy |
(and as an additional side note, https://github.com/astropy/astropy/tree/main/astropy/timeseries/periodograms/lombscargle/implementations is also where the faster implementations are available :) ). |
I am broadly supportive of this, yes. |
PS: and this could be a good opportunity for making sure that the API of the corresponding functionalities is as polished / easy to use / "logical" / similar to APIs for related functions such as "normal" FFT and IFFT provided by scipy as possible, to make life easier for the users. |
Is your feature request related to a problem? Please describe.
The current implementation of the Lomb-Scargle Periodogram available in scipy has a number of issues / quirks; according to https://jakevdp.github.io/blog/2015/06/13/lomb-scargle-in-python/ :
Describe the solution you'd like.
There are some faster and less quirky implementations available in other packages. However, these packages are often "subfield specific / tainted", and it would be great to have a high quality implementation that is shared across all fields and provided by scipy, rather than by a specific repo and package from the astonomy community, or the life science community, etc.
According to https://jakevdp.github.io/blog/2017/03/30/practical-lomb-scargle/ :
and https://docs.astropy.org/en/stable/timeseries/lombscargle.html does look very good and detailed, with several algorithmic implementations (see "Summary" section there).
Would it be possible to pull the implementation(s) from there into scipy, and remove all astronomy specific aspects (should be none in the code itself, and come mostly from the documentation / blogs etc), to help diffuse these algorithms to a wider community?
The motivation for this is that, for many of us, scipy is the "default goto" solution, and if a method / functionality is available in scipy, we often use it and trust that it is good / high quality / as optimal as it should be and use it without digging further. Pulling the better implementations from astropy into scipy would allow people like me (and many others around me) who default to scipy when scipy provides a functionality, to have access to the better solution by default, without the need to use some hours to search the web and make their mind about what alternative solution is best.
Describe alternatives you've considered.
After some time making my mind, I think that https://docs.astropy.org/en/stable/timeseries/lombscargle.html is the best available, and I will use it for now.
Additional context (e.g. screenshots, GIFs)
No response
The text was updated successfully, but these errors were encountered: