nanograv / enterprise

ENTERPRISE (Enhanced Numerical Toolbox Enabling a Robust PulsaR Inference SuitE) is a pulsar timing analysis code, aimed at noise analysis, gravitational-wave searches, and timing model analysis.
https://enterprise.readthedocs.io
MIT License
64 stars 65 forks source link

Merge dev to master #385

Open vhaasteren opened 3 months ago

vhaasteren commented 3 months ago

Let's merge dev into master and do a new Enterprise release. @AaronDJohnson, @vallis, others, what would you like to get added/modified before then?

AaronDJohnson commented 3 months ago

Removing the dependency on timing packages would really help M* Mac installation. Enterprise is pure Python, so the only thing stopping native installation without --no-deps are the Cython packages.

AaronDJohnson commented 3 months ago

I think moving to support Python 3.12 should be trivial too, so we might as well get that going.

vhaasteren commented 3 months ago

On my M1 macbook pro, healpy is not a problem. Pip chokes on scikit-sparse and libstempo. Realistically, we don't need either. Sparse matrix operations actually don't help that much either.

vhaasteren commented 3 months ago

@AaronDJohnson, pip/python allows optional dependencies with extras_require, such as this way:

# Core requirements
requirements = [
    "numpy>=1.16.3",
    "scipy>=1.2.0",
    "ephem>=3.7.6.0",
]

# Optional dependencies
extras_require = {
    'full': [
        "healpy>=1.14.0",
        "scikit-sparse>=0.4.5",
        "pint-pulsar>=0.8.3",
        "libstempo>=2.4.4",
    ]
}

Perhaps healpy, which is less problematic, can be in a separate extra also. Then you can install with either:

pip install enterprise-pulsar

or

pip install enterprise-pulsar[full]

Problem with this is backward compatibility in, say, Dockerfiles, which might not have full selected. But optional dependencies cannot be on by default.

AaronDJohnson commented 3 months ago

Hopefully they pinned the enterprise version in those old Dockerfiles...