Skip to content

ephemerides installation

David Keitel edited this page Jun 5, 2023 · 2 revisions

PyFstat requires paths to earth and sun ephemerides files in order to use the lalpulsar.ComputeFstat module and various lalapps tools. Historically, this was a bit of a tricky business. But recent releases of the lal and lalpulsar dependencies from conda, or lalsuite from PyPI, include (or pull in) a sufficient minimal set of such files (the [earth/sun]00-40-DE405 default versions) and no further setup should be needed from the user side. The same should be true if you have built and installed LALSuite from source, and set your paths up properly through something like source $MYLALPATH/etc/lalsuite-user-env.sh.

To be more specific, as of early June 2023:

  • The latest PyFstat stable releases (up to 2.0.0) always pull in ephemerides directly from LALSuite/lalpulsar, both via pip or conda.
  • With the latest master version of PyFstat:
    • Via pip, we install the dependency as lalsuite[lalpulsar].
      • The latest PyPI stable releases (lalsuite <= 7.15) carry their own ephemerides and ignore that optional dependency flag.
      • Nightly (dev) versions of LALSuite no longer contain ephemerides and instead pull in, through that optional dependency, the package solar-system-ephemerides.
    • The conda lalpulsar dependency still carries its own ephemerides.
  • When building and installing LALSuite from source, ephemerides are provided via the LALSuite git.

Here we also preserve the following fallback information if you run into any trouble of the "file not found" type, or want to use different versions of ephemerides. You can manually download files from solar-system-ephemerides or from this directory. You then need to tell PyFstat where to find these files, by creating a ~/.pyfstat.conf file in your home directory which looks like

earth_ephem = '/home/<USER>/lalsuite-install/share/lalpulsar/earth00-19-DE405.dat.gz'
sun_ephem = '/home/<USER>/lalsuite-install/share/lalpulsar/sun00-19-DE405.dat.gz'

Paths set in this way will take precedence over lal's default resolution logic.

You can also manually specify ephemerides files when initialising each PyFstat class with the earth_ephem and sun_ephem arguments.

NOTE: The alternative of relying on environment variables (as previously recommended by PyFstat's documentation) is considered deprecated by LALSuite maintainers and is no longer supported by current PyFstat versions.

Clone this wiki locally